This is a submission for the Hacktoberfest Open-Source AI Challenge Week 4: Ghost in the Machine
What I Built
GhostWriter AI is a horror story generator that turns a simple idea into an atmospheric nightmare.
What if the machine you trusted was hiding something? What if an abandoned computer suddenly started communicating with you? Or what if the technology surrounding you knew things it should never know?
I built GhostWriter AI to explore the unsettling boundary between artificial intelligence and horror storytelling. Users provide a story seed, choose a horror genre, select a length, and let AI bring their idea to life.
Features include:
👻 Five horror genres: Supernatural, Psychological, Cosmic, Gothic, and Tech Horror.
✍️ Custom story prompts: Turn a simple premise into an original horror story.
📖 Story continuation: Extend an existing story while maintaining continuity.
📋 Copy and download: Keep your generated stories as plain-text files.
🎃 Halloween theme switch: A circular pumpkin toggles between light and dark modes. The pumpkin glows when light mode is active.
🌫️ Atmospheric UI: A haunted-library background, drifting particles, translucent panels, and responsive layouts.
The goal was to build more than a basic AI wrapper. I wanted the experience itself to feel like entering a mysterious digital manuscript.
Demo
👻 Try GhostWriter AI: https://ghostwriterai-hectoberfect.netlify.app/ The frontend and serverless backend are deployed together on Netlify.
Try this prompt: A thief breaks into an abandoned smart city to steal its central AI core. At midnight, every locked building announces his full name—even though he has never been there before.
Select Tech Horror, choose Short, and generate your own nightmare. Code
🔗 GitHub repository: https://github.com/Shivam-Sharma2009/GhostWriterAI The project is built with React, Vite, JavaScript, CSS, Netlify Functions, and the Google Gemini Developer API.
The backend handles AI requests server-side so the API key is not exposed in the browser.
How I Built It
I built GhostWriter AI using React and Vite for the interface, with Netlify Functions handling the backend requests.
The application follows this architecture:
React + Vite → Netlify Functions → Gemini Developer API
Here is how the main pieces work:
Frontend: React manages the story prompt, genre and length selections, manuscript display, states, and user feedback.
Serverless backend: Netlify Functions validate the input and send the generation request to Gemini.
AI generation: Gemini generates the story according to the supplied premise and selected horror style.
Story continuation: The existing story is passed to the backend so the AI can continue it with new material.
Secure configuration: The API key is stored in Netlify environment variables rather than embedded in frontend code.
Deployment: Netlify hosts the frontend and backend functions, while GitHub stores the source code.
For this implementation, I used the Gemini Developer API rather than running an open-weight model locally. The surrounding development stack uses open-source tools, but I am not claiming local inference or that Gemini itself is open-source. Why Does Open Innovation Matter?
Open innovation makes it possible for individual developers to experiment, learn from existing tools, and turn ideas into working applications without building every component from scratch.
For GhostWriter AI, I could focus on the experience—story generation, genre-specific prompts, continuity, and the interface—while relying on established frontend frameworks, serverless infrastructure, and version control.
Public source code also makes the project easier for other developers to inspect, learn from, improve, and extend.
There is still room to take this project further: integrating an open-weight language model, adding configurable inference providers, improving rate limiting, and enabling community contributions.
I see this project as a starting point for experimentation, not the end of the journey.
The Spirit of It
The scariest part of technology is not always what it can do. Sometimes, it is what we do not understand about it.
some image are
I wanted GhostWriter AI to capture that feeling: an ordinary prompt becoming a story about a machine, a hidden presence, or something that should not exist.
And the small Halloween pumpkin? It is a reminder that even a simple interface detail can make a project feel like its own little world.
Every story starts with an idea. The machine supplies the nightmare. 🎃
Prize Categories
Primary submission: Hacktoberfest Open-Source AI Challenge — Week 4: Ghost in the Machine.
I am not claiming an additional partner prize category without verifying its eligibility requirements.
Built with curiosity, code, and a little darkness. 👻
Live demo: [https://ghostwriterai-hectoberfect.netlify.app/](https://ghostwriterai-hectoberfect.netlify.app/)
Source code: [https://github.com/Shivam-Sharma2009/GhostWriterAI](https://github.com/Shivam-Sharma2009/GhostWriterAI)