You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+25-6Lines changed: 25 additions & 6 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -55,7 +55,7 @@ cd your-project
55
55
codegraph build
56
56
```
57
57
58
-
That's it. No config files, no Docker, no JVM, no API keys, no accounts. The graph is ready to query. Add `codegraph mcp` to your AI agent's config and it has full access to your dependency graph through 18 MCP tools.
58
+
That's it. No config files, no Docker, no JVM, no API keys, no accounts. The graph is ready to query. Add `codegraph mcp` to your AI agent's config and it has full access to your dependency graph through 19 MCP tools.
59
59
60
60
### Why it matters
61
61
@@ -78,6 +78,7 @@ That's it. No config files, no Docker, no JVM, no API keys, no accounts. The gra
@@ -96,9 +97,9 @@ That's it. No config files, no Docker, no JVM, no API keys, no accounts. The gra
96
97
|**🔓**|**Zero-cost core, LLM-enhanced when you want**| Full graph analysis with no API keys, no accounts, no cost. Optionally bring your own LLM provider — your code only goes where you choose |
97
98
|**🔬**|**Function-level, not just files**| Traces `handleAuth()` → `validateToken()` → `decryptJWT()` and shows 14 callers across 9 files break if `decryptJWT` changes |
98
99
|**🏷️**|**Role classification**| Every symbol auto-tagged as `entry`/`core`/`utility`/`adapter`/`dead`/`leaf` — agents instantly know what they're looking at |
99
-
|**🤖**|**Built for AI agents**|18-tool [MCP server](https://modelcontextprotocol.io/) — AI assistants query your graph directly. Single-repo by default |
100
+
|**🤖**|**Built for AI agents**|19-tool [MCP server](https://modelcontextprotocol.io/) — AI assistants query your graph directly. Single-repo by default |
100
101
|**🌐**|**Multi-language, one CLI**| JS/TS + Python + Go + Rust + Java + C# + PHP + Ruby + HCL in a single graph |
101
-
|**💥**|**Git diff impact**|`codegraph diff-impact` shows changed functions, their callers, and full blast radius — ships with a GitHub Actions workflow |
102
+
|**💥**|**Git diff impact**|`codegraph diff-impact` shows changed functions, their callers, and full blast radius — enriched with historically coupled files from git co-change analysis. Ships with a GitHub Actions workflow |
102
103
|**🧠**|**Semantic search**| Local embeddings by default, LLM-powered when opted in — multi-query with RRF ranking via `"auth; token; JWT"`|
103
104
104
105
---
@@ -143,7 +144,7 @@ After modifying code:
143
144
Or connect directly via MCP:
144
145
145
146
```bash
146
-
codegraph mcp #18-tool MCP server — AI queries the graph directly
147
+
codegraph mcp #19-tool MCP server — AI queries the graph directly
147
148
```
148
149
149
150
Full agent setup: [AI Agent Guide](docs/guides/ai-agent-guide.md)·[CLAUDE.md template](docs/guides/ai-agent-guide.md#claudemd-template)
| 🎯 |**Deep context**|`context` gives AI agents source, deps, callers, signature, and tests for a function in one call; `explain` gives structural summaries of files or functions |
162
163
| 📍 |**Fast lookup**|`where` shows exactly where a symbol is defined and used — minimal, fast |
| 🔗 |**Co-change analysis**| Analyze git history for files that always change together — surfaces hidden coupling the static graph can't see; enriches `diff-impact` with historically coupled files |
164
166
| 🗺️ |**Module map**| Bird's-eye view of your most-connected files |
| 🏷️ |**Node role classification**| Every symbol auto-tagged as `entry`/`core`/`utility`/`adapter`/`dead`/`leaf` based on connectivity patterns — agents instantly know architectural role |
167
169
| 🔄 |**Cycle detection**| Find circular dependencies at file or function level |
Co-change data also enriches `diff-impact` — historically coupled files appear in a `historicallyCoupled` section alongside the static dependency analysis.
Codegraph includes a built-in [Model Context Protocol](https://modelcontextprotocol.io/) server with 18 tools, so AI assistants can query your dependency graph directly:
429
+
Codegraph includes a built-in [Model Context Protocol](https://modelcontextprotocol.io/) server with 19 tools, so AI assistants can query your dependency graph directly:
412
430
413
431
```bash
414
432
codegraph mcp # Single-repo mode (default) — only local project
| 4 |~~Node classification~~|~~Auto-tag symbols as Entry Point / Core / Utility / Adapter based on in-degree/out-degree patterns. High fan-in + low fan-out = Core. Zero fan-in + non-export = Dead. Inspired by arbor.~~| Intelligence |~~Agents immediately understand architectural role of any symbol without reading surrounding code — fewer orientation tokens~~| ✓ | ✓ | 5 | No |**DONE** — `classifyNodeRoles()` in `structure.js` auto-tags every symbol as `entry`/`core`/`utility`/`adapter`/`dead`/`leaf` using median-based fan-in/fan-out thresholds. Roles stored in DB (`role` column, migration v5), surfaced in `where`/`explain`/`context`/`stats`/`list-functions`, new `roles` CLI command, new `node_roles` MCP tool (18 tools total). Includes `--role` and `--file` filters. |
30
-
| 9 | Git change coupling | Analyze git history for files/functions that always change together. Surfaces hidden dependencies that the static graph can't see. Enhances `diff-impact` with historical co-change data. Inspired by axon. | Analysis |`diff-impact` catches more breakage by including historically coupled files; agents get a more complete blast radius picture | ✓ | ✓ | 5 | No |
30
+
| 9 |~~Git change coupling~~|~~Analyze git history for files/functions that always change together. Surfaces hidden dependencies that the static graph can't see. Enhances `diff-impact` with historical co-change data. Inspired by axon.~~| Analysis |~~`diff-impact` catches more breakage by including historically coupled files; agents get a more complete blast radius picture~~| ✓ | ✓ | 5 | No|**DONE** — `src/cochange.js` module with scan, compute, analyze, and query functions. DB migration v5 adds `co_changes` + `co_change_meta` tables. CLI command `codegraph co-change [file]` with `--analyze`, `--since`, `--min-support`, `--min-jaccard`, `--full` options. Integrates into `diff-impact` output via `historicallyCoupled` section. New `co_changes` MCP tool (19 tools total). Uses Jaccard similarity on commit history.|
31
31
| 1 |~~Dead code detection~~|~~Find symbols with zero incoming edges (excluding entry points and exports). Agents constantly ask "is this used?" — the graph already has the data, we just need to surface it. Inspired by narsil-mcp, axon, codexray, CKB.~~| Analysis |~~Agents stop wasting tokens investigating dead code; developers get actionable cleanup lists without external tools~~| ✓ | ✓ | 4 | No |**DONE** — Delivered as part of node classification (ID 4). `codegraph roles --role dead -T` lists all symbols with zero fan-in that aren't exported. |
32
32
| 2 | Shortest path A→B | BFS/Dijkstra on the existing edges table to find how symbol A reaches symbol B. We have `fn` for single-node chains but no A→B pathfinding. Inspired by codexray, arbor. | Navigation | Agents can answer "how does this function reach that one?" in one call instead of manually tracing chains | ✓ | ✓ | 4 | No |
33
33
| 12 | Execution flow tracing | Framework-aware entry point detection (Express routes, CLI commands, event handlers) + BFS flow tracing from entry to leaf. Inspired by axon, GitNexus, code-context-mcp. | Navigation | Agents can answer "what happens when a user hits POST /login?" by tracing the full execution path in one query | ✓ | ✓ | 4 | No |
0 commit comments