Mines git history for file co-change patterns into a queryable knowledge graph via MCP.
Copy the AI prompt to install this server into Claude Code, Cursor, or another agent β or use 1-click editor setup below.
π‘ Paste the JSON block into your client's configuration file under mcpServers, then restart the application.
Install β’ Quickstart β’ CLI Reference β’ Comparison β’ FAQ
A local-only CLI that mines your git log for which files actually change
together, then hands an AI coding agent a queryable answer instead of a
grep across the whole history.

(Real output from running GraphKeeper against its own repo, this early in its history. Co-change counts grow as a codebase accumulates more commits.)
No server, no account, no embeddings API. Every byte of output comes from
git log on the repo you already have checked out.
GraphKeeper ships two independent, equally first-class packages. Pick
whichever fits your toolchain, or install both. Both mine the same git log co-change signal and share one on-disk .graphkeeper/graph.json
schema, so a store built by either can be read back by the other.
The npm package requires Node.js 18 or later; the Python package requires
Python 3.9 or later. Both require git on your PATH. The Python
package's CLI entry point is also graphkeeper (e.g. graphkeeper build).
See python/README.md for the Python-specific
walkthrough, and CHANGELOG.md for each distribution's
version history.
Run it against any git repo, including this one:
Now query it:
If graphify is installed
(uv tool install graphifyy), graphkeeper build automatically shells out to
its local, no-API-key graphify extract --code-only and merges its
symbol/call-graph into the same store, unlocking call-graph queries:
(Also real output, from running graphkeeper build against this repo with
graphify installed.)

Without graphify installed, that same command explains exactly why the answer isn't available instead of crashing or returning an empty result:
Every command also supports --json for scripts and agents:

graphkeeper build
runs git log --no-merges --name-only across the full history of the
repo and counts every file pair that changed together in the same
commit. There's no guessing at coupling from folder structure or import
statements alone; the answer comes from how the codebase actually got
edited over time.--max-files-per-commit protects the signal. A single vendoring
commit or mass reformat that touches 400 files would otherwise pollute
every pair in that commit. The default cap (100 files) skips commits
above that threshold so real coupling doesn't drown in noise.PATH,
graphkeeper build shells out to its local graphify extract --code-only --no-cluster and merges the resulting symbol/call edges into
the same store, unlocking graphkeeper query calls. Without graphify,
GraphKeeper still works in co-change-only mode and says so plainly
instead of failing.--json mode. graphkeeper query co-change <file> --json and the equivalents return machine-readable output, so an
agent's calling code parses a real data structure instead of scraping
text.src/, TypeScript) and the PyPI package (python/src/graphkeeper/,
Python) are independent ports, not a wrapper of one around the other.
Both read and write the same .graphkeeper/graph.json, so a store built
with one CLI is queryable from the other.spawnSync/subprocess.run with
a list of arguments, so a crafted commit message or filename in the repo
being analyzed can't be interpreted as shell syntax.graphkeeper build [path]Walks path (default: current directory), runs git log --no-merges --name-only across the whole history, and counts how often each pair of
files was touched in the same commit. Writes the result to
.graphkeeper/graph.json.
| Option | Description |
|---|---|
--json | emit machine-readable JSON instead of human-readable text |
--max-files-per-commit <n> | skip commits touching more than this many files (default: 100), keeping a single mass-reformat or vendoring commit from drowning out real co-change signal |
--no-graphify | skip graphify enrichment even if graphify is installed |
If graphify is detected on
PATH, build also runs graphify extract <path> --code-only --no-cluster
(graphify's own headless, local, no-API-key AST extraction path) into a
directory inside .graphkeeper/, and merges its nodes/edges into the same
store. The build output always states plainly whether that enrichment was
included, and why it was skipped if not.
graphkeeper query co-change <file>Lists files that historically changed alongside <file>, ranked by how many
commits touched both.
| Option | Description |
|---|---|
--json | emit machine-readable JSON instead of human-readable text |
--limit <n> | cap the number of results |
--graph <path> | path to a specific graph.json (default: <cwd>/.graphkeeper/graph.json) |
Exit code 0 when results are found, 1 when there's no co-change data for
that file yet, 2 on a usage or filesystem error.
graphkeeper query calls <symbol>Shows callers and callees of <symbol>, using graphify's calls edges from
the most recent build. Only meaningful when that build included graphify
enrichment; if it didn't, this prints a clear explanation of why instead of
a crash or a silent empty result.
| Option | Description |
|---|---|
--json | emit machine-readable JSON instead of human-readable text |
--graph <path> | path to a specific graph.json (default: <cwd>/.graphkeeper/graph.json) |
Exit code 0 when the symbol is found, 1 when it isn't (or enrichment
wasn't available), 2 on a usage or filesystem error.
No reviews yet β be the first to share how this listing worked for you.
Showcase your server listing on GitHub or your project documentation. Embed this dynamic SVG badge to highlight official listing status and live engagement.
[](https://allmcps.com/mcp/graphkeeper)<a href="https://allmcps.com/mcp/graphkeeper"><img src="https://allmcps.com/api/badge/graphkeeper?style=directory" alt="Graphkeeper on AllMCPs" /></a>