Skip to content
    Back to Open Source
    Agent Think Map cover
    Claude
    MCP
    Codex
    React
    MIT

    Agent Think Map

    Your agent took 40 steps. Find the one that matters.

    Agent Think Map is a visual debugger for AI agents. It runs beside Claude Code or Codex and draws the route each run took: prompt, skill, tool call, MCP server, subagent, answer. Click any node to see what went in, what came out, how long it took, and what it cost. Every run is stored locally, so you can search it, label it, and come back to it. Open source under MIT.

    What you get

    • Live capture beside Claude Code or Codex. Hooks record the run as it happens, and if the connection drops the viewer resumes without losing the run.
    • Local run history in SQLite. Search past runs, filter by provider, status, or outcome, and bookmark the ones worth keeping.
    • Outcome labels. Mark a run Worked or Needs work, and choose a baseline run explicitly when you want a reference point for the next one.
    • Problems view. Groups recurring operation and error pairs across your recorded runs and suggests checks for each group. Suggested checks are starting points for your own investigation, not verified root causes.
    • Node-level inspection. Inputs, outputs, duration, and token or cost usage for every step. Reasoning steps appear only when the runtime exposes them.

    Who it’s for

    Individual developers who use Claude Code or Codex and want to see what the agent actually did: which skill loaded, which tool ran, which MCP server answered, and where the run went sideways. No 4,000-line log after the fact.

    Install

    Requires Node.js 22.13 or newer. One command per agent:

    For Claude Code

    npx agent-think-map claude --install

    This adds hooks to the current project's .claude/settings.local.json. Install it in each project you want to trace. Hooks from other tools are preserved.

    For Codex

    npx agent-think-map codex --install

    This installs hooks at the user level (~/.codex/hooks.json) and covers future sessions across projects. To scope it to one project, run "npx agent-think-map codex --install --project" from that project.

    Everything runs and stays on your machine. Run history lives in a local SQLite database at ~/.agent-think-map/runs.db.

    Embed in your own chat UI

    The debugger canvas is also a component you can ship. Add four lines of CDN HTML or a React component, point it at your agent's SSE endpoint or pass events to it directly, and the same map renders inside your product. Secrets in tool arguments are redacted. Reasoning steps appear only when the runtime exposes them.

    Star it, fork it, use it

    Open source under MIT — contributions welcome.