Skip to main content
MCP server CX Codex

CodeCartographer — Claude Code MCP server: map any codebase

Turns an unfamiliar repository into layered architecture, behavioral contracts and a reimplementation spec. Each phase is validated before the next one starts.

Install into Claude Code · Platform CLI All methods and platforms ↓
claude mcp add codecartographer -- npx -y codecartographer-pi
Open on GitHub

What CodeCartographer does

The server walks an agent through phases: architecture, defect scan, behavioral contracts, protocols, porting, and a reimplementation spec. Every phase drops a templated artifact into .codecarto/findings/ instead of leaving results in the chat. A fresh session or a context compaction resumes from status.yaml.

Before moving on, the pipeline checks the phase. Each output carries a ## Validation table where the phase marks its criteria PASS, PARTIAL or FAIL with supporting notes, and two mechanical checks compare the evidence against the actions and the declared secondary outputs. A FAIL, a missing file or an unreadable verdict stops the run. The model grades itself, and the checks keep that honest.

The final reimplementation-spec.md is language-agnostic and lists modules, acceptance scenarios and open questions. Hand it to another agent to rebuild from. Running it needs Node.js 20 or newer, since the package starts through npx.

What it helps with

  • map an unfamiliar repository into layers
  • catch defects before users hit them
  • extract behavioral contracts from server code
  • produce a spec for rebuilding in another language
  • keep analysis progress across context compaction

Example prompts for the agent

  • Run the CodeCartographer pipeline over this repo and show me the architecture
  • Start the defect scan phase and write findings to .codecarto/findings/
  • Build reimplementation-spec.md from the finished phases

How to install CodeCartographer

Platform CLI

claude mcp add codecartographer -- npx -y codecartographer-pi

Step by step, with commands for each platform: How to add an MCP server to Claude Code, Codex, Cursor, VS Code, Gemini CLI and more

Questions about CodeCartographer

How do I install CodeCartographer in Claude Code?

Run claude mcp add codecartographer -- npx -y codecartographer-pi. The server then shows up to the agent over MCP.

What does CodeCartographer do?

It runs a repository through analysis phases and stores the results under .codecarto/. You end up with a spec you can rebuild the code from.

What do I need to run it?

Node.js 20 or newer, because the package launches via npx. The authors recommend the Pi extension for interactive work; the MCP server is for agents such as Claude, Codex or Cursor.

Similar MCP servers

All MCP servers for Agent setup: memory, context, orchestration →

Project sponsors

Companies that keep this analytics open
Gold sponsor

Impressions, clicks and code copies — open statistics. We keep the numbers public for the same reason NeBlask itself is public. Become a sponsor