- 🚀 Live Demo on Render: https://pitr-smriti-eternal-diya.onrender.com
title: "Pitr Smriti: Channeling Ancestral Wisdom Through 14 Diyas and Open-Weight AI"
published: false
description: "An Indian sacred memorial shrine honoring ancestors on Bhoot Chaturdashi with glowing diyas, marigold garlands, and private open-weight AI (Gemma)."
tags: ["hf26challenge", "devchallenge", "ai", "opensource"]
canonical_url: "https://github.com/Mustafa1765/Mustafa_hactoberfest4"
cover_image: "https://raw.githubusercontent.com/Mustafa1765/Mustafa_hactoberfest4/main/public/assets/shrine.jpg"
This is a submission for the Hacktoberfest Open-Source AI Challenge Week 4: Ghost in the Machine.
🪔 The Spark: What I Built
Every autumn, as the moon wanes into the darkest night of the Hindu month of Kartik, millions of homes across India celebrate Bhoot Chaturdashi (the eve of Diwali).
Legend tells that on this mystical night, the veil separating the realm of the living from the spirit world thins to a whisper. Families light 14 clay oil lamps (Choddo Pradip) in every quiet corner of their homes to honor 14 generations of departed ancestors, dispelling shadows and guiding their benevolent spirits (Pitrus) back home with prayers, fragrant marigolds (genda phool), and sweets.
When I read this week's Hacktoberfest prompt—"Ghost in the Machine", asking us to build something that honors the past in the spirit of Día de los Muertos and Halloween using open-source AI—I knew immediately what had to be built.
I built Pitr Smriti (पितृ स्मृति): an interactive, sacred Indian ancestral memorial shrine and digital ofrenda.
At its heart, Pitr Smriti transforms open-weight artificial intelligence into a vessel for cultural memory:
- Interactive 3-Tier Altar: An ornate teakwood & brass shrine featuring custom ancestor portraits, traditional offering thali (Motichoor Ladoo, Kheer, Tulsi, Ganga Jal, and fragrant burning Agarbatti smoke), and an interactive grid of the 14 Diyas of Bhoot Chaturdashi.
- Pitr Vaani (Gemma Open-Weight AI Core): A remembrance engine powered by Google's open-weight Gemma model architecture that synthesizes authentic ancestral blessings (Aashirwad), heartfelt life eulogies (Smriti Gatha), or eerie midnight folklore.
- Voice of the Forefathers: Recites blessings aloud through an ElevenLabs speech synthesis engine (with seamless browser Web Speech API offline fallback).
- Offline Procedural Indian Soundscape: Generates an authentic meditative Tanpura drone (in Key of D) and temple bell chimes using the Web Audio API in real-time—requiring zero external audio downloads and operating 100% offline.
- Pitr Patra Keepsake Card: An HTML5 Canvas generator that composes the framed photo, Sanskrit invocation ("॥ ॐ पितृभ्यो नमः स्वधा नमः ॥"), and the AI-crafted blessing into an archival digital parchment ready for printing.
📸 Demo & Experience
The Sacred Altar & 14 Diyas
The application greets the visitor in a serene temple sanctuary:
- Gentle marigold petals drift lazily across the screen.
- A central framed ancestral portrait glows with an interactive halo.
- Lighting all 14 clay diyas illuminates the entire altar with a warm golden blessing aura.
[ Tier I: Pitr Sthaan — Ancestor Portrait & Glowing Halos ]
🪔
[ Tier II: Naivedya — Motichoor Ladoo, Kheer, Tulsi & Agarbatti ]
🪔
[ Tier III: Choddo Pradip — 14 Diyas of Bhoot Chaturdashi ]
Try it Yourself:
- 🔗 GitHub Repository: Mustafa1765/Mustafa_hactoberfest4
- 🚀 Live Demo on Render: Deployable in 1-click via the included
render.yamlblueprint!
🛠️ How It Works / Technical Execution
The architectural philosophy of Pitr Smriti was guided by simplicity, resilience, and complete data sovereignty.
graph TD
User([User Details: Memory, Traits, Photo]) --> UI[Interactive Sacred Altar]
subgraph Altar_Experience [Sacred Visuals & Audio]
UI --> Diyas[14 Diyas of Bhoot Chaturdashi]
UI --> Thali[Offering Thali: Sweets, Kheer, Agarbatti]
UI --> Petals[HTML5 Canvas: Floating Marigold Petal Physics]
UI --> Sound[Web Audio API: Procedural Tanpura Drone]
end
subgraph Open_Source_AI [Gemma Open-Weight Core]
UI --> GemmaHarness[Gemma Prompt Harness]
GemmaHarness --> LocalEngine[Client-Side Heuristic Generator]
GemmaHarness --> Ollama[Local Gemma Endpoint: 11434]
GemmaHarness --> CloudProxy[Render API Endpoint: /api/gemma/generate]
end
subgraph Voice_and_Export [Recitation & Keepsake]
LocalEngine & Ollama & CloudProxy --> TextOutput[Synthesized Blessing]
TextOutput --> ElevenLabs[ElevenLabs Ethereal Voice / Web Speech]
TextOutput --> CanvasExport[Pitr Patra 1200x1500 Canvas Poster]
end
1. Core AI: Google Gemma Open Weights
The core intelligence runs on prompts tailored for Google's open-weight Gemma model (gemma:2b / gemma-2-9b-it).
- Offline Client-Side Mode: Uses structured contextual heuristics to synthesize authentic blessings without requiring an API key or internet access.
-
Local GPU Mode: Seamlessly connects to any local Ollama server (
ollama run gemma:2b) or OpenAI-compatible endpoint. -
Render API Proxy: Includes a secure server-side proxy route in
server.jsfor production deployments.
2. Partner Technologies Used:
-
Render (Featured Partner - $200 Category):
The project includes a native
render.yamlInfrastructure-as-Code blueprint. It configures the Node.js runtime, builds dependencies, and serves the static assets with sub-second response times on Render's global infrastructure. - Google Gemma (Featured Partner - $200 Category): Google's open-weight model acts as the intellectual engine of the remembrance chamber, formatting emotional nuance into traditional Indian lyrical prose.
-
ElevenLabs (Partner Category - $100 Category):
Integrated into the speech recitation pipeline via
/api/voice/generateto provide deep, resonant, elder vocal delivery, with a zero-friction fallback to the browser's nativeSpeechSynthesisUtterance.
💡 Why Open Innovation Matters Here
The Hacktoberfest prompt challenges us:
"In your post, tell us why open innovation matters for what you built. Does it run on a laptop with no internet? Keep someone's data off a server they don't control? Tell us where your open-based approach worked better than a closed one."
This is the pivotal question of modern AI. When dealing with commercial chatbots or customer service agents, cloud APIs are convenient. But when dealing with the memory of our dead ancestors, closed proprietary AI is fundamentally flawed:
1. Sacred Data Sovereignty & Radical Privacy
Photographs of our late grandmothers, personal eulogies, and family memories are the most intimate, sacred data a human being possesses. Feeding grandma’s portrait and father’s dying words into a closed commercial AI means handing that data over to a corporate cloud to be mined for advertising profiles, stored indefinitely on corporate disks, or used to train next year's monetization models.
With open-weight AI (Gemma running client-side or on a local machine), not a single byte leaves the user's computer. The family sanctuary remains untouched.
2. Running With the Lights (and Internet) Off
In many ancestral towns and villages across India, festival nights frequently coincide with electrical load-shedding and spotty mobile data. Because Pitr Smriti relies on open-weight inference and native browser Web Audio synthesis, the entire application works in complete darkness on a disconnected laptop powered by battery. You can sit in the dark, light a clay diya on your desk, and commune with your ancestors with zero Wi-Fi bars.
3. Immune to Corporate Deprecation
Proprietary cloud APIs suffer from the corporate lifecycle: price hikes, sudden deprecations, altered terms of service, and eventual shutdowns. A digital shrine dedicated to your forebears must not become a 404 error when a venture-backed startup pivots. Because Pitr Smriti is open-source under the MIT license and built on open weights, it belongs to the global community forever.
4. Zero-Cost Universal Access
Commemorating those who gave us life should never require a credit card or a $20/month SaaS subscription. Open weights democratize spiritual and emotional technology for everyone, regardless of geography or income.
🌺 Reflections: The Ghost in the Machine
We often speak of artificial intelligence as something cold, robotic, and unfeeling. But during Bhoot Chaturdashi and Día de los Muertos, we are reminded that technology is ultimately what we pour into it.
The "ghost" in Pitr Smriti is not a phantom of fear, nor is it synthetic illusion. It is the living memory of our elders, rekindled through the open-source community, kept alive by the light of fourteen clay lamps.
॥ ॐ पितृभ्यो नमः स्वधा नमः ॥
(Salutations to the ancestors; may their wisdom guide our steps forever.)
Built with deep reverence for Hacktoberfest 2026. Star the project on GitHub. 🪔
Top comments (0)