code-review-graph indexes repositories into a SQLite knowledge graph and serves blast-radius context to AI coding tools over MCP. Incremental updates keep the map current after edits.
Overview
code-review-graph parses source with Tree-sitter into a persistent graph of functions, classes, imports, calls, and tests. AI assistants connected through MCP receive compact slices of that graph instead of rereading entire trees when reviewing a change.
An install command detects supported editors and agents, writes MCP entries, hooks, and optional rule snippets, then builds the graph locally. Changed files trigger incremental re-indexing via editor hooks, git hooks, or watch mode, targeting only hashes that differ.
At review time the tool traces callers, dependents, and related tests for touched symbols and can score risk. It supports dozens of languages plus notebooks, with optional custom grammars via languages.toml. A GitHub Action posts risk summaries on pull requests without sending code to a third party.
Benchmarks reported on several open repositories show large token reductions when models query the graph versus dumping full corpora. Optional cloud embeddings remain off by default; the default posture stores one local database file on the developer machine.
Key features
- Tree-sitter structural indexing
- MCP context tools
- Blast-radius change analysis
- Incremental hash-based updates
- Multi-editor install command
- Git hook integrations
- GitHub Action PR comments
- Custom language mappings
Use cases
- Token-efficient AI code review
- Finding impact of a local edit
- CI risk comments on pull requests
- Large-repo navigation for agents
- Cross-language monorepo intelligence
Does the same job as
code-review-graph doesn't name these products itself, but its own description shows it does the same job.