Ghostwriter AI: What if the AI Storyteller Remembers Every Mistake You Make?
This is a submission for the Hacktoberfest Open-Source AI Challenge Week 4: Ghost in the Machine What I Built Ghostwriter AI — Every Choice Leaves a Scar is an interactive, unscripted gothic horror storytelling generator designed to give players genuine narrative agency while confronting them with

Hacktoberfest Open-Source AI Challenge: Ghost in the Machine Submission 👻🌼
This is a submission for the Hacktoberfest Open-Source AI Challenge Week 4: Ghost in the Machine
Ghostwriter AI — Every Choice Leaves a Scar is an interactive, unscripted gothic horror storytelling generator designed to give players genuine narrative agency while confronting them with the indelible consequences of their decisions.
Traditional text adventures rely on static, pre-written decision branches: choose option A or B to jump to passage 12 or 13. Conversely, modern conversational AI chatbots often suffer from narrative amnesia, abrupt tonal drift, or cheerful assistant personas that completely dissolve suspense.
In gothic folklore, a haunting is an unresolved echo of past trauma trapped inside an environment. In Ghostwriter AI, the "Ghost" is the persistent memory ledger trapped within the machine.
The machine does not just generate words— it holds a grudge. As you explore eerie domains (from the decaying halls of Blackwood Manor to abandoned sanitariums and cursed hamlets), the engine continuously tracks your discovered clues, psychological wounds, unprompted actions, and fateful decisions. Every choice leaves an irreversible scar on the narrative ledger, culminating in a climactic autopsy ending ( Escape, Survival with a cost, Tragic ending, Supernatural revelation, or Hidden ending ).
The application features a dark gothic aesthetic inspired by classic horror literature:
An unscripted interactive horror-story generator where the machine remembers your decisions, powered by Google's open-weight Gemma model via the Gemini API. Built for the DEV.to Hacktoberfest Week 4 2026 Challenge: "Ghost in the Machine".
Traditional text adventures and branching narrative games rely on pre-written decision trees. If you choose Door A, you get pre-baked Paragraph 12; if you choose Door B, you get pre-baked Paragraph 13. While predictable, this approach limits player agency and quickly loses tension once branches are discovered.
On the other hand, unstructured conversational AI chatbots lack memory discipline: they frequently suffer from tone drift, forget past decisions within a few turns, and lack pacing or stakes.
Ghostwriter AI bridges this gap It acts as an intelligent, literary storyteller that weaves genuine gothic horror. Every choice you select—or custom unscripted action you…