Technology RadarTechnology Radar

Codebase Memory MCP

agentprotocolragopen-source
Assess

Codebase Memory MCP is a local code-intelligence server that parses repositories into a persistent SQLite knowledge graph and exposes structural queries to coding agents through MCP. It gives an agent a precomputed map of functions, classes, calls, routes, and dependencies instead of making the agent rediscover those relationships through repeated grep-and-read loops.

Why It's in Assess

The project has strong early signals: active development, a portable single-binary design, an MIT licence, a public benchmark harness, and unusually rapid community growth. GitHub reported more than 37,000 stars and 2,900 forks on August 4, 2026, while the v0.9.0 release documents substantial work on Windows support, memory safety, indexing resilience, and extraction accuracy.

The evidence does not yet justify Trial. The published evaluation is a maintainer-authored preprint using one model and first-author grading, the stable API is still pre-1.0, and the reviewed sources do not identify a named organisation using it in production. A practitioner report found the tool useful on a real repository, but one individual deployment is not production-scale validation.

How It Works

  1. Parse: vendored Tree-sitter grammars extract definitions, calls, imports, routes, and other structural relationships.
  2. Resolve: language-specific type-resolution passes refine call edges beyond syntax-only matching.
  3. Store: nodes and edges persist in a local SQLite graph and update incrementally as files change.
  4. Serve: MCP tools answer architecture, call-path, impact-analysis, dead-code, code-search, and Cypher-like graph queries.

The current project documentation advertises 158 parsed languages and 15 MCP tools. The v0.5.5 research snapshot evaluated an earlier 66-language, 14-tool system, so the published benchmark should not be treated as validation of every newer parser and feature.

What the Benchmark Actually Shows

The project's preprint compares Codebase Memory with file-by-file exploration across 31 repositories using Claude Opus 4.6. It reports 0.83 answer quality versus 0.92 for the explorer, while using roughly 10 times fewer tokens and 2.1 times fewer tool calls. Graph retrieval performs best on structural questions such as caller ranking and dependency traversal; direct file exploration remains stronger when full source context or exhaustive text matching matters.

That trade-off is the reason to assess it as a complement to file tools, not a replacement. Use the graph to localise and map a change, then read the relevant source before editing or making a precision-sensitive claim.

Strengths

  • Local and model-agnostic: the indexer contains no LLM and keeps repository analysis on the host.
  • Low operational overhead: a static C binary and SQLite avoid a separate graph database or embedding service.
  • Agent-native interface: MCP exposes typed structural operations rather than a human-only code browser.
  • Polyglot and cross-service: the graph includes calls, imports, HTTP routes, infrastructure files, and cross-repository relationships.
  • Incremental state: the index persists between sessions and refreshes changed files rather than rebuilding from scratch.

Limitations and When NOT to Use

  • Do not trust graph edges as compiler truth. Dynamic dispatch, metaprogramming, macros, generated code, and weakly supported languages can produce incomplete or ambiguous relationships.
  • Do not use it for text search. Error strings, comments, configuration values, and exact source context still belong to grep and file reads.
  • Do not install it blindly on a locked-down workstation. The installer can modify agent configuration, skills, instructions, and hooks; audit the source or install the binary without automatic client configuration.
  • Do not commit the optional shared graph artifact without review. It is generated from repository structure and may create size, freshness, or information-disclosure concerns.
  • Expect churn. The stable release remains v0.x, and the gap between the paper's 66-language snapshot and the current 158-language claim shows how quickly the implementation is changing.

Cost and Economics

The software is open source and runs locally, so its direct cost is compute, storage, and maintenance rather than API or seat fees. The economic case is reduced agent context and fewer discovery calls on large repositories. Teams should benchmark their own languages and question mix: a graph that saves tokens but misses critical dynamic edges can increase review cost rather than reduce it.

Key Characteristics

Property Value
License MIT
Provider DeusData / community
Language C
GitHub DeusData/codebase-memory-mcp
Website deusdata.github.io/codebase-memory-mcp
Docs README and project documentation
Version v0.9.0 stable; v0.9.1-rc.1 prerelease (reviewed August 4, 2026)
Storage Local SQLite knowledge graph
Interface MCP server, CLI, optional graph UI

Related Entries

  • Tree-sitter — the parsing foundation used to build the graph
  • RAG for Codebases — the broader retrieval pattern; structural graph lookup complements semantic and lexical retrieval
  • Model Context Protocol — the agent-facing transport for graph tools

Further Reading