kg_statusLABSCO SUMMARY
Every rule traces to a commit, and the whole store is greppable.
The design decision that pays off is storing knowledge as files in the repo: it versions, it reviews, it shares by push, and you can read it without the tool. Co-change prediction is the part that does something a plain file store cannot — it surfaces the implicit dependency between two directories that nobody documented. The published token budget for each component is a good sign about where the author's attention went.
What it is
A memory layer that lives inside your repository as plain files. It turns file operations and git history into evidence-backed knowledge nodes stored next to the code they describe, so rules trace to a commit hash or a recorded error rather than to something the model inferred. Claude Code gets automatic tracking through hooks; every other agent reads the same state through the bundled MCP stdio server.
What you get
- Coverage, pending events, blind-spot count, hot zones and recent failures in one status read —
kg_status - Full-text search across every canonical knowledge node, returning
path:line:excerptso a claim points at a line —kg_query - The complete knowledge node for a specific module —
kg_read_node - A current work snapshot: active modules, uncommitted changes and recent commits, so the agent knows what is still in progress and not only what was committed —
kg_recent_work - The modules a file path tends to change alongside, from real co-change history —
kg_predict - The top co-change directory pairs, which surface dependencies nobody wrote down —
kg_cochange - Modules with activity but no knowledge node, so gaps in coverage are visible —
kg_blind_spots - 7 tools and 22 resources exposed to any MCP client, alongside the Claude Code hook path
- A snapshot that survives
clearandcompact, and a Read size-guard that warns before a large read hits its ceiling so the agent greps instead
Requirements
jq, and that is the dependency list — no Docker, no Neo4j, no Python, no vector store, no daemon. Install with one bash line against your project directory on macOS, Linux or WSL, or the PowerShell installer on Windows. Then restart Claude Code so the hooks activate, or point an MCP-aware agent at the .mcp.json the installer wrote. KG_PROJECT_DIR is what the Codex-facing AGENTS.md section points at. Everything it stores is plain files in your repo, so sharing with a team is git push and inspecting it is opening a file.
Setup effort
One command — bash <(curl -fsSL https://raw.githubusercontent.com/hilyfux/knowledge-graph/main/standalone/install.sh) <YOUR_PATH_TO_PROJECT>
USE CASES
Picking up where you left off after a compaction
Read the work snapshot — active modules, uncommitted changes, recent commits — instead of re-describing the project.
Finding the rule that governs a module
Search the knowledge nodes and read the one that matches, with the result pointing at a file and line.
Not breaking the thing next door
Ask which modules this file tends to change with, based on real co-change history rather than the import graph.
Finding out what the memory does not cover
List the modules with activity but no knowledge node, and fill the ones that matter.
Sharing project knowledge with the team
Commit the nodes and push — there is no database to export and no service for anyone to run.
7 tools
Listed in project docs. Your client may show a different list.
kg_querykg_read_nodekg_recent_workkg_predictkg_cochangekg_blind_spotsBEFORE YOU INSTALL
What to know first
Tools you get
7 tools named in the project's documentation.
Requires
- bash (macOS/Linux: native; Windows: Git Bash or WSL)
- jq
INSTALLATION
Connect your client
Server setup
Setup
git clone https://github.com/hilyfux/knowledge-graph.git
cd knowledge-graph
bash standalone/install.sh <YOUR_PATH_TO_PROJECT>Restart Claude Code so hooks reload, if you use Claude Code.
In Codex, read AGENTS.md and connect the knowledge-graph MCP server from .mcp.json.
Or run the install script
Claude Code, Codex
bash <(curl -fsSL https://raw.githubusercontent.com/hilyfux/knowledge-graph/main/standalone/install.sh) <YOUR_PATH_TO_PROJECT>MCP Clients
Claude Code — Windows, Codex — Windows
git clone https://github.com/hilyfux/knowledge-graph.git
cd knowledge-graph
.\standalone\install.ps1 <YOUR_PATH_TO_PROJECT>