The Last Commit:讓棄置的開源項目説出自己的故事
The Last Commit 👻: Giving Abandoned Open-Source Projects a Voice
The Last Commit 是一款以 AI 驅動的工具,分析棄置 Git 儲存庫的提交記錄、README、原始碼及未完成的 TODO,並生成可供用戶對話的項目角色。它使用 Ollama 在本機運行開放權重模型 Qwen3 1.7B,讓用戶探索開發時間線、查看儲存庫證據及生成復活路線圖。此設計毋須把原始碼上載至外部 AI API,並可在下載模型和依賴項後離線使用。
This is a submission for the Hacktoberfest Open-Source AI Challenge Week 4: Ghost in the Machine
What I Built
What happens when a software project is abandoned?
The developer stops committing code. Issues remain unanswered. TODO comments stay buried in source files. Eventually, the repository becomes another forgotten corner of GitHub.
But what if that project could tell us its story?
Introducing The Last Commit — an AI-powered digital archaeologist that brings abandoned software repositories back to life.
The idea is simple: every repository has a history, and every history has a story.
You provide a local Git repository, and The Last Commit examines its commit history, README, source code, and unfinished TODOs. It then creates an interactive ghost persona that you can talk to.
You can ask questions like:
- "Who created you?"
- "What were you originally supposed to do?"
- "What happened during your final days?"
- "Why did development stop?"
- "What was left unfinished?"
- "How can I bring you back?"
The ghost uses actual repository information to answer questions, rather than simply inventing a spooky story.
The project interprets Ghost in the Machine quite literally: the ghost is the history of software that nobody remembers anymore.
How I Built It
I wanted the AI to be more than a chatbot with a Halloween-themed interface. The actual intelligence and functionality needed to come from open technology.
Here's the stack I'm using:
| Technology | Purpose |
|---|---|
| Python | Repository analysis and backend logic |
| FastAPI | Backend API |
| React + Vite | Interactive frontend |
| Ollama | Local model inference |
| Qwen3 1.7B | Open-weight language model |
| Git | Repository history extraction |
| SQLite | Local data storage |
1. Understanding the repository
The backend uses Git to examine a repository's history.
It extracts information such as:
- Commit messages and timestamps.
- Development activity.
- README content.
- TODO and FIXME comments.
- Relevant source-code information.
This information becomes the ghost's memories.
2. Giving the repository a voice
I'm using Qwen3 through Ollama to power the ghost.
Instead of sending repository information to an external AI API, the application communicates with a locally running model.
The model receives repository context and responds in the personality of the abandoned project.
For example, a repository with years of development history followed by a sudden stop might respond:
"I remember when everything was moving so quickly. New features every week, bugs disappearing, and plans for the future. Then came my final commit. Nobody returned after that."
The personality is generated by the model, while the underlying memories are grounded in repository evidence.
3. Building the experience
The frontend provides a haunted terminal-inspired interface where users can:
- Summon a repository.
- Talk to its ghost.
- Explore its development timeline.
- Inspect repository evidence.
- Generate a resurrection roadmap.
The goal is to make software archaeology feel like an interactive experience rather than reading Git logs.
Why Does Open Innovation Matter?
This is probably the most important part of the project.
I could have connected a commercial AI API and built a chatbot around it. That would have been easier in some ways, but it would have missed the point.
I wanted the project to be independent of a closed AI service.
Using an open-weight model and local inference makes several things possible:
1. Privacy
Source code can contain sensitive information. Keeping repository analysis and inference on the user's own machine means the application doesn't need to upload that code to an external inference provider.
2. Offline operation
Once the model and dependencies are downloaded, the intended workflow can run without an internet connection. You can explore a repository and talk to its ghost without depending on a cloud AI service.
3. Freedom to experiment
I can replace Qwen3 with another compatible open-weight model, experiment with different prompts, and change the ghost's personality without rebuilding the entire application around a proprietary API.
4. Accessibility
There is no required per-request commercial inference API fee. Users can run the model using their own hardware.
For me, open innovation isn't simply about using free software. It's about being able to understand, modify, control, and preserve the technology that powers something you build.
A project about preserving forgotten software should itself be built using technology that people can preserve and modify.
The Spirit of It
There is something interesting about abandoned software.
A repository can contain thousands of lines of code, hundreds of commits, and months or years of someone's effort. Yet one day, nobody remembers why it was created.
The code remains. The commit history remains. The comments remain.
But the voice behind the project disappears.
I wanted to build something that gives that history a voice again.
Maybe the project was abandoned because its developer ran out of time. Maybe the original idea became irrelevant. Maybe there was simply nobody left to maintain it.
The Last Commit doesn't claim to know why someone disappeared. Instead, it helps us discover what they left behind.
Every repository has a last commit. But does that really have to be the end of its story?
來源:DEV Community · dev.to