v1.1.0
project-brain
A CLI-first developer intelligence tool for analyzing codebases, tracking Git changes at function level, generating structured exports for AI systems, and explaining code changes — running entirely on your machine.
30-Second Quick Start
pip install project-brain-cli
brain project init # create .brain/ + brain.yaml
brain project analyze . # scan repo → .brain/data.json
brain diff show # HEAD~1 → HEAD function-level diff
brain export full_code # pack repo → .brain/exports/full_code.txtCommand Map
| Command | What it does |
|---|---|
brain project init | Create .brain/ directory and brain.yaml config |
brain project analyze [path] | Recursive AST scan → .brain/data.json |
brain project summary | Show file/function/class counts and architecture hints |
brain project doctor | Validate environment (Git, config, provider, API keys) |
brain diff show [from] [to] | Function-level diff between Git refs (default HEAD~1→HEAD) |
brain diff review [from] [to] | LLM semantic diff explanation → HTML + JSON reports |
brain diff explain <target> | Explain a file or function (src/api.py:create_user) |
brain export full_code | Pack entire repo → .brain/exports/full_code.txt |
brain export file <path> | Add single file to export |
brain export dir <path> | Add directory to export |
brain export code_changes A B | Export changed functions between two Git refs |
brain testllm test | Test LLM provider connectivity |
brain community | Show GitHub, PyPI, Discussions links |
brain --version / -v | Print installed version |
brain --feedback | Open GitHub Discussions in browser |
Requirements
- • Python >= 3.10
- • Git installed and accessible in PATH
- • Optional: Ollama / OpenAI / Gemini / HuggingFace for LLM features
Note
Both
brain and project-brain aliases are registered after install.