What inspired us
We were brainstorming project ideas and started thinking about how every person in an event remembers the same incident differently. Each person has their own version of what happened, their own limited knowledge, and their own bias. That idea became much more interesting when we placed it inside a high-pressure setting like a murder investigation.
That is where Cold Case came from.
We liked the idea of building a mystery where every suspect has a different knowledge base and can only answer from their own perspective. Instead of making a static story, we wanted to create a system where the player has to interrogate characters, compare contradictions, and slowly uncover the truth. The hackathon setting made it even more fun because it let us mix suspense, absurdity, and tech culture into one experience.
How we built it
We built the project as an AI-powered mystery game with a backend and frontend working together.
On the backend, we used Neo4j as a knowledge graph. The graph acts as the structured memory for the whole story. It stores facts, relationships, characters, evidence, and contradictions. Each persona does not get access to the full truth. Instead, when the player asks a question, we retrieve the most relevant facts from the knowledge graph for that specific character and use them to build the prompt. This way, each suspect responds only from their own perspective and hidden knowledge.
We also built a cache layer on top of the LLM flow. This helped us store and reuse responses for repeated scenarios, which was especially useful during testing.
On the frontend, we created multiple screens such as the opening scene, corkboard, interview room, evidence board, and accusation screen. We also built interactive UI elements like contradiction alerts, a progress meter, a hint system, animated portraits, and evidence unlocking flow. The goal was to make the player feel like they were actively investigating, not just reading dialogue.
Overall, the project combines:
- Neo4j knowledge graph for structured story memory
- persona-based prompting for different suspect viewpoints
- LLM-backed dialogue
- cache-based fallbacks
- React frontend for the interactive detective experience
What we learned
This project taught us a lot about designing AI systems beyond just calling a model API.
First, we learned how important structured knowledge is when building believable AI characters. If every character is given the same context, they all sound the same. By separating facts inside a knowledge graph, we were able to make each character feel more distinct and more realistic.
Second, we learned how difficult it is to design a system where the AI is not just answering questions, but answering them in character, with the right limits, hidden facts, and contradictions.
We also learned a lot about:
- prompt design for multi-agent or multi-persona systems
- using a knowledge graph as a retrieval layer
- managing frontend state across a story-driven application
- handling API limits and building caches/fallbacks for testing
- designing a full end-to-end interactive demo under hackathon time pressure
Challenges we faced
One of the biggest challenges was the LLM API usage during testing. Since we were using the Google ADK / Gemini flow, the API key quota kept getting exhausted while testing different branches, personas, and edge cases. This made it hard to do repeated end-to-end testing and forced us to think carefully about caching and mock responses.
Another major challenge was the creation of the knowledge graph itself. Designing the KG was not simple because we had to decide:
- what facts belong to which character
- what should stay hidden
- how contradictions should emerge naturally
- how evidence should unlock later parts of the story
In other words, the graph was not just data storage. It was the backbone of the mystery logic.
We also had the challenge of connecting everything together in a smooth way:
- backend retrieval
- persona prompts
- contradiction detection
- evidence progression
- frontend interactions
Making all those systems feel like one coherent game experience was one of the hardest but most rewarding parts of the project.
Final thoughts
This project started from a simple question: what if every suspect had their own version of the truth? From there, it became a full AI-powered detective experience built on knowledge graphs, persona reasoning, evidence flow, and interactive interrogation.
In the end, we did not just build a mystery story. We built a system where the truth has to be reconstructed from fragmented perspectives, and that is what made the project exciting for us.
Log in or sign up for Devpost to join the conversation.