For agents · MCP server

Give your agent the blast radius.

AI agents plan on the three files they grepped, then miss the cross-cutting effects. CodeTrawl exposes the code graph as an MCP server — so Claude Code, Cursor, or anything that speaks MCP can ask “what breaks if I change this?” before it edits. Verdicts, not queries. No LLM in the analysis path.

The idea

Verdicts, not queries

Raw graph access over MCP measurably degrades agent answers — a graph dump is just more tokens to get lost in. CodeTrawl ships ranked verdicts instead: the blast radius of a change, the untested files it would break, the duplicated code it would leave stale. It’s pre-planning context — repo-at-commit, deterministic, cited to the call graph — not a live view of unsaved edits.

Ten tools

What your agent can call

analyze_repoDownload + parse a GitHub repo → a session id and a compact summary. Always first.
locate_symbolWhere is a symbol defined? A bare function, method, or class name → every definition's file and line. The lookup blast_radius needs first.
blast_radiusWhat breaks if you change a file or function — cross-file reach via imports + calls, 3 hops.
simulate_changeSimulate a proposed diff BEFORE you commit → a deterministic blast + a pass/block conscience gate. The pre-commit check.
untested_hotspotsProduction functions with no test caller, ranked by complexity — test the risky paths first.
find_duplicatesStructurally identical functions (AST hash) across the codebase — refactor candidates.
signalsDeterministic health verdict: what works, what needs work, what needs human judgment.
compare_sessionsHigh-level diff of two analyses — verify a refactor actually moved the needle.
analyze_diffFunction-level diff, PR-comment-grade: every change classified with a complexity delta.
review_changesPrioritized verification suggestions on a diff, each with severity + evidence.
Install

Wire it to your client

One command. Published on npm as codetrawl-mcp — nothing to clone and nothing to build. The analysis runs on your machine; no CodeTrawl-controlled server sees your repos.

Claude Code
claude mcp add codetrawl npx codetrawl-mcp
Cursor / Cline / others (JSON config)
{
  "mcpServers": {
    "codetrawl": {
      "command": "npx",
      "args": ["-y", "codetrawl-mcp"]
    }
  }
}
Pre-flight recipe

Make the agent actually use it

Agents that grep don’t call tools they don’t know they need. Drop this into your project’s AGENTS.md / CLAUDE.md so it reaches for the blast radius before touching load-bearing code.

## Before you change code — and before you call it done

This repo is connected to the CodeTrawl MCP server.

Before you edit:
1. Call analyze_repo once with the repo URL to get a session id.
2. Call blast_radius on the file/function you're about to change — read
   the dependents and how many are untested before you commit to the edit.

Before you finish — the conscience loop:
3. Call simulate_change with your FULL proposed diff.
4. If gate.pass is false, resolve each gate.blocking item (load-bearing
   code with no guarding test, a hollow test) or justify it, then
   re-simulate. Repeat until gate.pass is true.

The verdict is deterministic — computed from the real import + call graph,
cited to concrete files. Treat gate.pass:false as a stop, not a warning.
(Or invoke the "conscience" prompt to load this loop verbatim.)
Try the analysis in the browser first.
Paste a repo, see the blast radius the tools return — then wire it to your agent.
Analyze a repo →