DEV Community

Cover image for πŸ‘» GhostDocs: Bringing Forgotten Knowledge Back to Life
neitherGalax
neitherGalax

Posted on

πŸ‘» GhostDocs: Bringing Forgotten Knowledge Back to Life

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

GhostDocs is a local-first documentation analysis tool that uncovers forgotten knowledge in software repositories using open-weight AI models.

I interpreted the Ghost in the Machine theme as a problem that exists in many software projects: over time, important knowledge gets lost, forgotten, or never properly documented.

A repository might contain code that nobody remembers how to use, decisions that were never recorded or functionality that has become difficult to understand because its documentation no longer tells the whole story.

I wanted to explore whether AI could help uncover these hidden pieces of knowledge.

Instead of building another documentation linter or broken-link checker, I created GhostDocs to investigate a different question:

What important knowledge has this repository lost, forgotten, or failed to document?

GhostDocs scans a project, analyzes its documentation and repository context using a local AI model, and generates a report with three main sections:

  • Lost Knowledge: Important information that appears to be missing or undocumented.

  • Ghost Sightings: Potential inconsistencies, forgotten context, and documentation gaps.

  • Resurrection Plan: Suggested actions to bring that knowledge back into the documentation.

The goal is not to automatically rewrite documentation, but to help developers recognize what might be missing and decide what deserves attention.

Demo

GhostDocs currently runs locally through a command-line interface (CLI).

You can try it with:

# Scan the current repository
ghostdocs .

# Scan a project and save the report
ghostdocs examples/haunted-project --output report.md
Enter fullscreen mode Exit fullscreen mode

Code

GitHub Repo Link

How I Built It

I built GhostDocs with Python and Ollama, using open-weight gemma4:e4b model for local inference.

The project follows a simple architecture:

  1. Repository Scanner
  2. AI Analyzer
  3. Report Generator

I deliberately kept the implementation lightweight. GhostDocs does not modify the original repository files, and the analysis runs locally rather than relying on a hosted AI API.

Why Does Open Innovation Matter?

Open innovation made it possible to build GhostDocs around local AI inference rather than depending on a closed, hosted API.

Using Ollama and an open-weight model gave me more control over how the model runs, which model to use, and where repository content is processed.

This matters for a documentation analysis tool because software repositories can contain internal implementation details and project knowledge that developers may not want to send to external services.

It also makes experimentation more accessible. Developers can explore the project, inspect its prompts and implementation, change the model, and adapt it to their own workflows.

For me, open innovation is not just about making the source code available. It is also about giving people the freedom to understand, experiment with, and build upon the technology.

The Spirit of It

Every repository has a history.

Some knowledge survives in documentation, some remains buried in code, and some eventually disappears as the people who created it move on.

GhostDocs is a small experiment in using AI to help recover some of that forgotten knowledge.

Sometimes, the most interesting things in a repository are not the things that are documented, but the things that are missing.

Prize Categories

  • Best use of Gemma

Top comments (0)