DEV Community

Cover image for 👻 RepoGhost: Bringing Forgotten Codebases Back to Life with Local AI
Sourodip Mahato
Sourodip Mahato

Posted on Edited on AI-assisted

👻 RepoGhost: Bringing Forgotten Codebases Back to Life with Local AI

This is a submission for the Hacktoberfest Open-Source AI Challenge Week 4: Ghost in the Machine.

What I Built

I built RepoGhost, a local AI-powered repository analyzer designed to bring forgotten and abandoned codebases back to life.

Every repository has a story, but understanding an unfamiliar project can sometimes feel like exploring a haunted house. There may be unfinished tasks, confusing file structures, undocumented functions, and code that nobody remembers writing.

That's where RepoGhost comes in! 👻

Users can upload a repository as a ZIP file, and RepoGhost scans it to discover:

  • Repository Overview: Detects source files, programming languages, and project structure.
  • Forgotten Tasks: Finds TODO, FIXME, and HACK comments that may have been left behind.
  • Python Syntax Findings: Identifies basic Python syntax issues.
  • Chat with the Ghost: Ask questions about the repository and get AI-powered explanations.
  • Haunted Project Report: Generates an AI-assisted report to help developers understand their codebase.

I interpreted the theme Ghost in the Machine as giving a voice to forgotten codebases. RepoGhost acts like a friendly ghost that helps developers understand what is happening inside a project, even when its original developers are no longer around.

Demo

🎥 Video Demo:

Note: RepoGhost is designed primarily for local execution, so the demo can showcase the application running on your machine.

Code

💻 GitHub Repository: https://github.com/Sourodip1804/RepoGhost

Contributions, feedback, and suggestions are welcome!

How I Built It

I built RepoGhost using a combination of open-source technologies and local AI inference.

AI Model:

  • Qwen2.5:3B – An open-weight language model used to understand repository context, answer questions, explain code, and generate reports.
  • Ollama – Runs the model locally, allowing RepoGhost to communicate with the AI without depending on a hosted AI API.

Backend:

  • Python
  • FastAPI
  • Repository scanning and file analysis
  • ZIP extraction and processing
  • REST API endpoints for uploading repositories, chatting, and generating reports

Frontend:

  • React.js
  • Vite
  • CSS
  • Lucide React icons

How it works:

  1. The developer uploads a repository ZIP file.
  2. The FastAPI backend safely extracts and scans the repository.
  3. RepoGhost identifies programming languages, source files, and unfinished task markers.
  4. Relevant repository context is prepared for the AI model.
  5. Qwen2.5:3B processes the context through Ollama and generates explanations or answers.
  6. The frontend displays scan results, AI conversations, and the generated project report.

One of my main goals was to keep the AI workflow local. The project does not need a paid cloud AI API to perform its core AI tasks.

Why Does Open Innovation Matter?

Open innovation made this project possible in a way that would have been difficult to achieve with a closed AI API alone.

Using an open-weight model like Qwen2.5:3B with Ollama gave me the opportunity to experiment with local AI inference, understand how models interact with application backends, and build an AI-powered tool without depending on paid API access.

It also offers some important advantages:

  • Privacy: Repository source code can remain on the developer's machine when using the local setup.
  • Accessibility: Developers can experiment without needing a paid AI API subscription.
  • Customization: The model and AI workflow can be modified according to project requirements.
  • Transparency: Developers have more control over the tools and infrastructure powering their AI applications.
  • Community: Open-source models and frameworks make it easier for developers to learn, contribute, and build on existing work.

For me, open innovation is not just about using free tools. It is about having the freedom to understand, experiment, modify, and build something useful.

The Spirit of It

The most interesting part of building RepoGhost was thinking about how much knowledge gets trapped inside old repositories.

A developer might leave a project unfinished, forget how a particular function works, or return to an old codebase after months or years.

Instead of manually exploring every file, imagine asking:

"Hey Ghost, what is this project actually doing?"

And getting an explanation from the code itself.

That is the idea behind RepoGhost: every codebase deserves a second life.

Prize Categories

  • Open-Source AI Challenge – Ghost in the Machine (Week 4)

Building RepoGhost has been a great learning experience. I explored local LLM integration, Ollama, FastAPI, React, repository analysis, and the practical challenges of connecting an AI model with a real application.

There is still plenty of room to improve, and I would love to hear your feedback and suggestions!

Let's bring forgotten codebases back to life. 👻

Hacktoberfest #OpenSourceAI #Ollama #Qwen #React #Python #FastAPI #OpenSource #AI

Top comments (0)