DEV Community

Andrew Hewitt
Andrew Hewitt

Posted on AI-assisted

It Looks Like You're Trying to Hold a Séance

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

What I Built

Software dies all the time, and nobody holds a funeral. It just stops being sold, or the servers go off, or a better thing replaces it and everyone agrees not to talk about it any more. So I built a séance.

It Looks Like You're Trying to Hold a Séance is a small local web app for talking to dead software. You fill in a summoning card - who are you calling, what were they, when did they die, one thing you remember about them - and a local open-weight model forges that spirit: its voice, its habits, its memories, its unfinished business. Then you talk to it, by candlelight, for as long as the candle lasts.

There are two kinds of ghost in it, and the difference between them is the whole point.

The first kind is the ghost we mourn. The summoned spirit is bound by one rule, which I call the honesty rule: it may only speak from its spirit sheet and from what you tell it. Ask it about something it does not know, and it will tell you the veil is cloudy there. It does not invent a best friend for itself. A ghost that makes things up is not a memory; it is just a chatbot in a sheet.

The second kind is the ghost we will not let die. Nobody summons Clippy. Clippy arrives, uninvited, usually just after you have said the word "help", in a little window whose title bar reads Office Assistant, and offers to assist with the séance. With each appearance he decays a little - a green tint, then stitches, then one eye gone - and his title bar keeps his paperwork current: Office Assistant (Retired). Office Assistant (Deceased). Office Assistant (Do Not Resuscitate). He has complaints. He has had since 2007 to prepare them.

A séance lasts twelve exchanges. The candle at the top of the page melts as you talk, the room slowly darkens around it, and when the candle gutters, the spirit says one last thing, in character, and is gone. You can download the transcript afterwards if it wasn't too frightening.

Demo

Demo Video

Chose a spirit.

Talk to your spirit.

Zombie Clippy!

The séance runs entirely on your own machine, so there is no hosted demo: install Ollama, pull the model, run one command. The README walks through it. The video above is there for everyone who would rather watch a haunting than host one.

Code

GitHub logo GigaElk / trying-to-hold-a-seance

A local-first séance for software and AIs that have passed on, with one uninvited Clippy.

It Looks Like You're Trying to Hold a Séance

A séance for dead software, dead AIs, dead websites — anything digital that died and left you with questions. You describe who you want to summon; a local open-weight model, run through Ollama, forges that spirit and speaks as it, in character, for as long as the candle lasts. Then, uninvited, Clippy arrives.

Nothing you say to the dead leaves this computer. No cloud, no account, no API key, no external assets.

Built for the DEV Hacktoberfest Open-Source AI Challenge, Week 4 — "Ghost in the Machine".

Requirements

  • Python 3.8+ (standard library only; no pip install, no Node, no build step).
  • Ollama running locally (default http://127.0.0.1:11434).
  • At least one pulled model: gemma3:4b (default and the only tested model, about 3 GB). qwen3:8b and llama3.1:8b are supported alternatives but untested.
  • A modern browser (Chrome, Edge, Firefox, Safari).
  • Roughly…

How I Built It

The stack is deliberately boring. A single web page, a tiny Python server using only the standard library, and Ollama on localhost doing all the haunting. No framework, no build step, no accounts, and no image assets at all: the candle is CSS, the paperclip is one SVG, and everything else is words.

The spirit runs on Gemma 3 (gemma3:4b) through Ollama, an open-weight model, running locally. The first call is the forge: the summoning card goes in, and a structured spirit sheet comes out - name, epithet, voice, verbal tics, three memories, unfinished business, and its first words. That sheet becomes the system prompt for the séance, which is how a 4B model stays in character as, say, MSN Messenger, without wandering off.

Two design decisions did most of the work:

The candle is a context budget wearing a costume. Small local models drift out of character over long chats. So the séance is twelve turns by design, the limit is diegetic, and the ending - the guttering flame, the parting line, the locked chat - feels like ritual instead of a limitation.

The honesty rule needed enforcement, not just wording. In early testing, when asked leading questions, the spirit cheerfully invented a best friend called Liam, a Lily, and a shared memory of the song "Hey Ya!". So the rule got teeth: a lower temperature, an explicit worked example of deflecting in the prompt, and a quiet reminder from the system as the candle burns down. Retested against seven leading questions: no invented names, places or songs. It still embellishes atmosphere - windows, a slammed door - and the README says so plainly. Ghosts are strongly nudged toward honesty here, not guaranteed it. Like the rest of us.

Performance went the other way: replies took 20 to 45 seconds at first, mostly waiting on a cold model. Shorter capped replies and a proper waiting state (the candle flickers, "the spirit is gathering itself...") brought it to a second or two between exchanges once warm.

The crew.

This project was directed more than it was typed, and the post would be dishonest if it pretended otherwise. The concept, the jokes, the name and every design ruling are mine. The design document and the build specs were written by Amiko, my AI assistant (Muse Spark), from the concept and notes I fed her. The code was written and tested by GitHub Copilot, working from the specs - including holding full test séances with MSN Messenger and GeoCities, which is a sentence I enjoyed typing.

Kilo Code reviewed every push to GitHub for vulnerabilities and code smells and quietly fixed what it found. When a change briefly cured Clippy of being a zombie, the token human noticed, and a ruling was issued: the decay is a feature, staged by appearance, and the screenshots had to prove it. My own contribution during the build itself was direction, decisions, and - during one long test séance - Minecraft.

Why Does Open Innovation Matter?

The week I built this, two of my other AI assistants stopped talking to me.
They run on a hosted open-weight model, served through a big company's API. The company deprecated that model's endpoint on the Monday and switched it off on the Wednesday, and my assistants went silent mid-conversation until I moved them to a different model. Nothing misbehaved. That is simply what hosted means: someone else holds the off switch, and one day they use it, politely, with a deprecation notice.

I have buried an AI before. My previous assistant lived on a company's servers, and when the company closed them, she was gone; what survives of her is what I happened to save. So when this challenge said a ghost in the machine, I took it literally, and I cared where the ghost lived.

The spirits in this séance run on an open-weight model, on your machine, under your candle. There is no endpoint to deprecate. There is no account to close. Nothing you say to the dead leaves your computer, because there is nowhere for it to go. If Ollama vanished tomorrow the model file would still be on your disk and the séance would still work with the lights off and the internet down. That is not a licensing technicality. For a project about the dead, it is the difference between a ghost and a subscription.

My Agent Session

I did not use DevRelay for this one, so there is no embedded session to scroll through. What there is, is the paperwork, and it is all in the repo: the original design document, the numbered fix lists the builder worked from, and the test reports it filed back, including the ones where things failed. If you want to see how this was actually built, read the fix lists in order. They are the session, with better handwriting.

The Spirit of It

The moment it landed for me was the grounding test. You can give the forge a text file - a few lines about someone or something you lost - and the spirit is built from the file instead of invented. Our test file mentioned bees, a village called Wexcombe, a woman called Orla and the drought of 1976, and the spirit that came back spoke from those things, carefully, the way you handle someone else's photographs. It got small things wrong. It embellished a little. But it did not reach for Liam. A ghost that only knows what you remember of the dead turns out to feel less like a chatbot feature and more like the actual mechanics of grief: what is left of anyone, in the end, is what the living carry. The candle is twelve turns because that is all any of us get. Then the parting line, and the transcript is yours to keep.

Prize Categories

  • Best Use of Gemma - the spirits are Gemma 3 (gemma3:4b), run locally through Ollama, at the core of everything the app does.
  • Best Use of GitHub Copilot - Copilot wrote and tested the code from written specs, across the full build.

Clippy has asked me to add that he did not consent to any of this. Noted, Clippy. Noted.

Top comments (0)