amaar-mc/graft
Local-first codebase context engine for AI coding tools via MCP
Platform-specific configuration:
{
"mcpServers": {
"graft": {
"command": "npx",
"args": [
"-y",
"graft"
]
}
}
}Add the config above to .claude/settings.json under the mcpServers key.
<p align="center"> </p>
<h1 align="center">Graft</h1>
<p align="center"> <strong>Local-first codebase context engine for AI coding tools</strong> </p>
<p align="center"> Parse any codebase into a ranked dependency graph. Serve it to AI tools via MCP.<br/> Zero config. Zero cloud. Nothing leaves your machine. </p>
<p align="center"> <a href="https://www.npmjs.com/package/graftmap"></a> <a href="https://github.com/amaar-mc/graft/actions"></a> <a href="https://github.com/amaar-mc/graft/blob/main/LICENSE"></a> <a href="https://nodejs.org"></a> </p>
---
AI coding tools are only as good as the context they receive. Most tools either have no codebase understanding, or use proprietary indexing locked to a single editor.
Graft gives any MCP-compatible AI tool deep structural understanding of your codebase:
$ npx graftmap map
src/indexer/pipeline.ts [score: 0.0842]
function buildIndex (L19)
src/graph/pagerank.ts [score: 0.0731]
function computePageRank (L52)
function buildTeleportVector (L11)
src/parser/index.ts [score: 0.0654]
function parseFiles (L28)
src/mcp/server.ts [score: 0.0612]
function createGraftServer (L238)
function startMcpServer (L327)
Loading reviews...