code-review-graph
MCP : Standardises the connection between an AI application and systems that expose tools or data
A local code graph, exposed over MCP, so the agent reads only the files touched by a change.
code-review-graph parses the repository with Tree-sitter, stores functions, classes, imports, calls and tests in a SQLite database, and updates it as changes are made. The agent queries the graph to learn the impact of a change before reviewing. The installation configures about fifteen tools, sets up hooks and adds four skills. The project is unusually honest about its numbers: it calls its own perfect recall circular, states that its best result covers only one repository, and acknowledges that the graph costs more than a direct read on a small change. No telemetry.
Security reflects where data goes, requested permissions and incidents on record at the verification date. It is not a guarantee of zero risk: check the deployment mode and the connections you enable.
What it does, concretely
When a coding assistant reviews a change, it tends to re-read large parts of the project to understand what the change affects. code-review-graph cuts down that reading: it builds a local map of the code and gives the assistant only the files the change touches.
In practice, the repository is parsed with Tree-sitter. Functions, classes, imports, calls and tests become a graph stored in a SQLite file. The assistant queries this graph over MCP to get the callers, dependents and reachable tests, with a risk score. Hooks and a watch mode re-parse only the files whose SHA-256 hash has changed.
The tool is for people who have a coding agent review their changes (Claude Code, Codex, Cursor, Gemini CLI, OpenCode and others) on a project large enough that reading everything is costly. It requires Python 3.10 or later and some comfort with the command line.
It is less useful on a very small change: the project itself acknowledges that the graph then costs more than a direct read. If you do not want a tool adding an MCP server, Git hooks and instructions to your rules files, skip it or first inspect the installation with --dry-run.
What it offers
- ·Builds a code graph with Tree-sitter (functions, classes, imports, calls, inheritance, tests) in a local SQLite database.
- ·Computes the blast radius of a change: callers, dependents and reachable tests, with a risk score.
- ·Updates the graph incrementally through editor hooks, Git hooks (pre-commit, post-checkout, post-merge, post-rewrite) or watch mode.
- ·Summarizes your latest change from the command line with detect-changes --brief, including against a base branch with --base.
- ·Sets up the AI tools detected on the machine in one command: MCP server entry, hooks, skills and instructions in the rules file.
- ·Offers optional semantic search, with local embeddings or a cloud provider, and a fallback to keyword search.
- ·Generates an interactive visualization of the graph, with export to JSON, GraphML, SVG, Obsidian or Cypher.
- ·Lets you undo everything with uninstall, with a preview available through --dry-run.
In practice
- Price
- Free
- Commercial use
- Commercial use: yes
- Available on
- claude-code, codex, cursor, any-agent, gemini-cli, opencode
- FR interface
- No
Security and data
- Rating
- Security: one caveat, see the card
- Your data
- Data stays local
- Maintenance
- Active
- Last release
- 11 November 2026
Links and repository checked on 30 November 2026 · added on 30 November 2026
How to install code-review-graph
uv tool install code-review-graph