I built this project to help visualize the architecture of different GitHub repositories. You just paste a GitHub link, and it clones the repo locally, reads the files, and uses the Gemini API to draw a Mermaid diagram of how everything connects.
- Auto-analyzes repos: It downloads the repo and checks the folder structure and important config files (like
package.jsonorrequirements.txt). - AI diagrams: Uses Gemini to figure out the architecture and generate a Mermaid diagram, along with a short explanation of how the repo works.
- Different modes: You can generate a basic diagram for beginners or a more technical one if you want to see all the backend details.
- History & Caching: Saves previous diagrams in a local SQLite database (
cache.db) so it doesn't have to hit the API again for repos you've already checked. - Export options: You can copy the raw Mermaid code or download the diagram as an SVG.
- Diagram links: If a component in the diagram maps to a specific file, you can click it to jump straight to that file on GitHub.
- Python 3.10+
- Git
- A Google Gemini API Key
-
Set your API Key You need to set your Gemini API key in your terminal before running the backend.
# Windows (Command Prompt) set GEMINI_API_KEY=your_api_key_here # Windows (PowerShell) $env:GEMINI_API_KEY="your_api_key_here" # Mac/Linux export GEMINI_API_KEY="your_api_key_here"
-
Install the backend stuff Make sure you are in the project folder and run:
pip install -r requirements.txt
-
Start the backend
cd backend uvicorn main:app --reload --port 8010 -
Open the frontend You can just open
frontend/index.htmlin your browser, or start a simple python server:cd frontend python -m http.server 8080