DEV Community

Cover image for PHANTOM - The Ghost in Your Codebase πŸ‘»
Shaurya Tiwari
Shaurya Tiwari

Posted on AI-assisted

PHANTOM - The Ghost in Your Codebase πŸ‘»

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

PHANTOM β€” The Ghost in Your Codebase πŸ‘»

What if your codebase could tell you the stories that its commit history, forgotten branches, abandoned TODOs, and uncommitted changes are hiding?

That's the idea behind PHANTOM, an AI-assisted software archaeology tool designed to help developers investigate the history and hidden context of their projects.

What I Built

Developers spend a lot of time working with code they didn't write, revisiting projects they haven't touched in months, or trying to understand why a particular implementation exists.

The answers are often scattered across Git history, old branches, stashes, working-tree changes, and comments left behind by previous developers.

PHANTOM brings these clues into one investigative workflow.

The project explores how AI can help developers:

  • Investigate Git history: Examine commits, branches, tags, stashes, and working-tree changes.
  • Discover forgotten clues: Scan source files for TODO, FIXME, and HACK markers that may reveal unfinished work or technical debt.
  • Ask questions about a codebase: Explore an evidence-oriented approach to answering questions about a project's history and state.
  • Keep the investigation grounded: Connect AI-assisted explanations to repository evidence instead of treating generated answers as unquestionable facts.
  • Use local AI where supported: Integrate with Ollama to explore local inference instead of requiring every AI interaction to depend on a closed, hosted model API.
  • Support controlled workflows: Explore structured investigation and recovery-report workflows for understanding unfamiliar or neglected projects.

I interpreted Ghost in the Machine as the invisible history that lives inside software: abandoned ideas, forgotten decisions, unfinished tasks, and traces of work that the current developer may no longer remember.

PHANTOM is my attempt to make those traces easier to investigate.

Demo

Backend deployment: https://phantom-3tc2.onrender.com

The backend has been deployed on Render. However, the complete frontend-to-backend experience has not yet been verified, so this link should be treated as a backend deployment rather than a finished, end-to-end interactive demo.

GitHub repository: https://github.com/dr5t/PHANTOM

Code

Explore the source code, project structure, and implementation here:

PHANTOM on GitHub

The project uses a React and TypeScript frontend, built with Vite, alongside a Node.js and Express TypeScript backend.

The repository is the primary reference for the implementation and its current capabilities.

How I Built It

PHANTOM combines a web interface, a backend API, Git-oriented investigation workflows, and an optional local-AI integration.

Frontend

  • React
  • TypeScript
  • Vite
  • Lucide icons

Backend

  • Node.js
  • Express
  • TypeScript

AI direction

  • Ollama integration for local inference
  • Evidence-oriented question answering
  • AI-assisted interpretation of software-project context

The central design principle is that AI should assist the investigation, not replace the evidence.

A useful software archaeology tool should help a developer understand what the repository actually contains, distinguish observed facts from interpretations, and investigate further when the available evidence is insufficient.

Local inference is particularly interesting for this use case because source code and development history can contain sensitive information. Running a compatible model locally can help developers explore AI-assisted workflows without automatically sending repository context to a hosted model provider.

The Render deployment is a step toward making the backend accessible online. The complete deployed workflow still needs end-to-end verification, and local repository access and local Ollama execution have different requirements from a cloud-hosted API.

Why Does Open Innovation Matter?

Software archaeology is a problem that affects nearly every developer, but different projects have different histories, architectures, conventions, and constraints.

Open innovation makes it possible to experiment with tools that developers can inspect, adapt, extend, and integrate into their own workflows.

For PHANTOM, open-source AI offers several important possibilities:

1. More control over where code goes

Local inference can give developers another option when working with private repositories or sensitive source code.

2. Freedom to experiment

Developers can explore different compatible models and local inference setups rather than being locked into one proprietary AI provider.

3. Transparent investigation

The code and investigation logic can be inspected and improved by the community. That matters when an AI-generated explanation needs to be checked against actual repository evidence.

4. Community-driven improvements

Different developers can contribute additional repository-analysis capabilities, improve the interface, add tests, and explore new ways of recovering context from software projects.

Open innovation isn't only about making AI cheaper or more accessible. It's also about giving developers more control over how AI is built into their tools.

My Agent Session

I haven't embedded a DevRelay session in this submission.

If I capture and publish a session demonstrating the actual development or investigation workflow, I'll add it here.

The Spirit of It πŸ‘»

Every long-lived codebase has a memory.

Sometimes that memory is a commit message written years ago. Sometimes it's a branch nobody remembers creating. Sometimes it's a TODO that has survived several releases.

And sometimes, the developer staring at the code is the same person who wrote itβ€”and still has absolutely no idea why.

That is the feeling I wanted PHANTOM to explore.

Instead of treating old code as a pile of files, what if we could investigate it as a trail of evidence?

The goal isn't to let AI invent the past. It's to make the traces that remain in a project easier to find, connect, and understand.

The code remembers. PHANTOM helps you investigate.

Prize Categories

Primary target: Overall Winner

I'm submitting PHANTOM as an open-source AI developer-tool project built around the Ghost in the Machine theme.

I'm not claiming the Render partner category at this stage: deploying the backend to Render alone does not establish that the project meets the category's AI-runtime or agent-hosting requirements.


Built for developers who have ever opened an old project and wondered: What was I thinking?

Top comments (0)