AI-powered GitHub repo analyzer CLI — analyze, chat, and visualize any codebase. Run 'gitputra info' to see all commands and features.
Project description
🔍 GitPutra
AI-powered GitHub repository analyzer CLI.
Clone any repo, generate a structured analysis report, visualize architecture, and chat with your codebase — all from the terminal.
✨ Features
- 🔍 Deep Repo Analysis — AI-generated structured report covering Summary, Architecture, Tech Stack, Issues, and Suggested Improvements
- 💬 RAG Chat — Ask questions about any codebase using Retrieval-Augmented Generation (ChromaDB + embeddings)
- 🤖 Multi-AI Support — Works with Google Gemini, OpenAI, and Anthropic Claude
- 📊 Dependency Diagrams — Auto-generates NetworkX graph diagram + Mermaid flowchart
- 📄 Multilingual PDF Reports — Exports analysis as a styled PDF in ~110 languages
- 🗂️ Smart Indexing — Skips re-embedding if a repo is already indexed; run
clear-dbto reset - 📁 48+ File Types — Supports Python, C/C++, Java, Go, Rust, JS/TS, and many more
📦 Installation
pip install gitputra
Requires Python 3.10+
🚀 Usage & Examples
Analyze a Repository
gitputra analyze https://github.com/user/repo --ai gemini --key YOUR_API_KEY
With options:
# Use OpenAI, output in Bengali, skip diagram
gitputra analyze https://github.com/user/repo --ai openai --key YOUR_KEY --lang Bengali --no-diagram
# Use Claude, skip PDF
gitputra analyze https://github.com/user/repo --ai claude --key YOUR_KEY --no-pdf
Outputs saved to ./output/:
report.pdf— Full analysis reportdiagram.png— Dependency graphmermaid.txt— Mermaid flowchart source
Chat with a Repository
gitputra chat https://github.com/user/repo --ai gemini --key YOUR_API_KEY
💬 Chat mode [repo] — ask anything about the repo. Type 'exit' to quit.
>> What does the main.py file do?
>> How is authentication handled?
>> exit
If
analyzewas already run on the repo,chatreuses the existing index automatically.
Clear the Local Index
gitputra clear-db
Show Info & Capabilities
gitputra info
Check Version
gitputra --version
🤖 AI Providers
| Flag | Provider | Text Model | Embedding Model |
|---|---|---|---|
--ai gemini |
Google Gemini | gemini-2.5-flash | text-embedding-004 |
--ai openai |
OpenAI | gpt-4o-mini | text-embedding-3-large |
--ai claude |
Anthropic Claude | claude-sonnet-4-5 | via GEMINI_API_KEY fallback |
Note: Claude has no embedding API. For RAG/chat with
--ai claude, setGEMINI_API_KEYin your.envfile to enable embeddings.
Setting up your API Key
Option 1 — .env file (recommended):
API_KEY=your_api_key_here
GEMINI_API_KEY=your_gemini_key # only needed for --ai claude with chat
Option 2 — CLI flag:
gitputra analyze https://github.com/user/repo --key YOUR_API_KEY
Avoid Option 2 in shared environments — CLI flags appear in shell history.
🌍 Supported Languages (PDF Output)
GitPutra can generate PDF reports in ~110 languages across 3 scripts:
Latin Script (~100 languages)
English, French, Spanish, Portuguese, Italian, German, Dutch, Swedish, Norwegian, Danish, Finnish, Polish, Czech, Slovak, Hungarian, Romanian, Croatian, Serbian (Latin), Slovenian, Albanian, Lithuanian, Latvian, Estonian, Turkish, Azerbaijani, Uzbek, Kazakh (Latin), Turkmen, Indonesian, Malay, Filipino, Swahili, Zulu, Xhosa, Afrikaans, Yoruba, Igbo, Hausa, Somali, Kinyarwanda, Welsh, Irish, Basque, Catalan, Galician, Maltese, Icelandic, Faroese, Vietnamese, Hawaiian, Maori, and more.
Bengali Script
Bengali, Assamese
Devanagari Script
Hindi, Marathi, Nepali, Sanskrit, Maithili, Konkani, Bodo, Dogri
The AI response language depends on the chosen model's capability. Use
--langto set the output language.
gitputra analyze https://github.com/user/repo --ai gemini --key KEY --lang Bengali
📁 Supported File Extensions (48 types)
| Category | Extensions |
|---|---|
| Python | .py, .ipynb |
| C/C++ | .c, .h, .cpp |
| Web | .js, .ts, .jsx, .tsx, .html, .css, .vue |
| JVM | .java, .kt, .kts, .scala, .groovy, .clj, .cljs |
| Systems | .go, .rs, .swift, .dart |
| Scripting | .sh, .bat, .ps1, .pl, .lua, .r, .m, .rb, .php, .coffee, .elm |
| Config | .json, .yaml, .yml, .xml, .ini, .cfg, .conf, .gradle, .makefile |
| Docs | .md, .txt, .log, .sql |
| Special | Dockerfile, Makefile |
👨💻 Author
Adityava Gangopadhyay
- 📧 Email: adityava49cse@gmail.com
- 🔗 LinkedIn: adityava-gangopadhyay
- 📦 PyPI: pypi.org/project/gitputra
Feel free to reach out for any suggestions or issues!
📄 License
MIT License — free to use, modify, and distribute.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file gitputra-0.1.7.tar.gz.
File metadata
- Download URL: gitputra-0.1.7.tar.gz
- Upload date:
- Size: 473.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
2378f8862cbd17e5067fde5089a759d72b012a4dc421a9f241ec08813c66400d
|
|
| MD5 |
b48182333f38672a477a62fe848a5dd9
|
|
| BLAKE2b-256 |
1667d4a6802eefb9f48d60506d9fc0a707fd2499719798c416f97bfb02bf5028
|
File details
Details for the file gitputra-0.1.7-py3-none-any.whl.
File metadata
- Download URL: gitputra-0.1.7-py3-none-any.whl
- Upload date:
- Size: 471.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
9b625ff6e1a7a9960f81e26d0f9112c5b5c4f1afd76e8bc180e6b8f080d8e249
|
|
| MD5 |
bded24182b52fe20b37f295e26d57fc0
|
|
| BLAKE2b-256 |
bcf3aed49eaa913c4427fff8bec68ac63f232ce2fe943981a58e183dbc9de4ad
|