Serveur MCP Codemap
Commit 1 nov. 2026Enables AI agents to query codebase structure, symbols, and imports using a local SQLite index to reduce token usage and file reads.
Aussi connu sous stainless-code/codemap
- Étoiles
- 8
- Outils
- —
- Téléchargements, 30 jours
- —
- Dernière version
- —
- Dernier commit
- 1 nov. 2026
- Licence
- MIT
Qu'est-ce que Codemap MCP ?
Codemap est un serveur MCP. Enables AI agents to query codebase structure, symbols, and imports using a local SQLite index to reduce token usage and file reads.
Résumé généré à partir du README du projet
À propos du MCP server Codemap
Navigating complex codebases by querying structural metadata instead of scanning entire file trees is what codemap enables for AI agents. It creates a local SQLite index containing symbols, imports, calls, and other structural information to help agents answer questions about where specific components or definitions reside. This approach reduces token consumption and the number of file reads required by an AI client during a session.
Developers can set this up locally using Node or Bun to index a repository. The server supports both direct SQL queries and pre-defined recipes, such as find-symbol-definitions, to simplify common tasks. While it is not a replacement for grep or ripgrep for raw text searches, users can opt-in to FTS5 for full-text search capabilities when they need to join body matches with structural data. It works through a CLI or a programmatic ESM API for integration into custom workflows.
Ce que vous pouvez faire avec
- 1Locating symbol definitionsAn AI agent can find exactly where a specific function or variable is defined using a single SQL command.
- 2Analyzing import directionsDevelopers can use the index to understand how different parts of a codebase interact through their imports.
Extrait du README du projet. Chaque cas d'utilisation est vérifié par rapport à une citation du document.
Vérifications automatisées
Exécuté le 15 nov. 2026Rapport complet →Pas encore vérifié. Un serveur nécessite un score de 80, aucune faille sérieuse et suffisamment de données pour que nous puissions effectuer les vérifications. Fonctionnement des vérifications · Ce qu'il faut corriger pour gagner des points
- Dépôt source lié et accessiblestainless-code/codemap is public and reachablegithub.com/stainless-code/codemap ↗Réussi
- Le nom du package correspond au dépôt sourceNon vérifié
- Provenance du build (attestation Sigstore)Non vérifié
- Licence open source (OSI)MITspdx.org/licenses/MIT.html ↗Réussi
- Commit ou version publiée au cours de l'année écouléeLast commit or release 2026-11-01github.com/stainless-code/codemap ↗Réussi
- OpenSSF ScorecardNon vérifié
- Nom du package non proche d'un package populaireNon vérifié
- Aucun avis critique dans le package ou ses dépendancesNon vérifié
- Aucune instruction cachée destinée au modèle0 tool descriptions and the README read; no override phrases, credential paths or hidden charactersRéussi
- Les outils destructifs sont étiquetésNon vérifié
- Le point de terminaison distant répond à la poignée de main MCPNon vérifié
README
Voir sur GitHubCodemap
Query your codebase. Local codebase intelligence for AI agents — a SQLite index of symbols, imports, calls, and more structural metadata so agents answer “where / what / who” with SQL and recipes instead of scanning the tree.
- Not grep by default — use ripgrep / your IDE for raw text. Opt-in FTS5 (
--with-fts/fts5: true) when body matches need to JOIN with structure. - Is a fast, token-efficient way to navigate structure.
Docs: https://stainless-code.com/codemap
What you get
Structural questions in one SQL round-trip instead of 3–5 file reads — symbol definitions, import direction, components, CSS tokens, @deprecated symbols, and more. Named patterns ship as recipes (codemap query --recipe …); full catalog and schema live in the docs.
Install
bun add @stainless-code/codemap
# or: npm install @stainless-code/codemap
Engines: Node >=22.12.0 and/or Bun >=1.0.31.
CLI
codemap # incremental index
codemap query --json --recipe find-symbol-definitions --params name=foo
codemap query --json "SELECT name, file_path FROM symbols WHERE name = 'foo'"
codemap show foo
codemap agents init --mcp # agent templates + MCP
Full command reference, recipes, MCP/HTTP, config, and the GitHub Action: docs site.
Programmatic API (ESM)
import { createCodemap } from "@stainless-code/codemap";
const cm = await createCodemap({ root: "/path/to/repo" });
await cm.index({ mode: "incremental" });
const rows = cm.query("SELECT name FROM symbols LIMIT 5");
API reference: https://stainless-code.com/codemap/reference/api.
Development
Contributor workflow, checks, and conventions: .github/CONTRIBUTING.md.
bun install
bun run check
Maintainer hub: docs/README.md.
License
MIT — see LICENSE.
Questions sur Codemap MCP
How does Codemap differ from grep?
Codemap is not grep by default; you should use ripgrep or your IDE for raw text searches, whereas Codemap is designed for navigating structural metadata.
What kind of information can I query?
You can query symbol definitions, import directions, components, CSS tokens, deprecated symbols, and more via SQL.
What are the engine requirements for installation?
The tool requires Node version 22.12.0 or higher, or Bun version 1.0.31 or higher.