codebase-knowledge-graph
Skill4 starsChanged 4 months agoMITView on GitHub
Router skill for graph-based codebase/corpus queries. Picks the right tool: code-review-graph (CRG, MCP-native, Tree-sitter, 23 langs, auto-update) for code structure; graphify for mixed corpora (docs + papers + images + tweets). Use when: onboarding, mapping architecture, tracing dependencies, blast-radius analysis, user says 'graph this', 'map the codebase', 'show dependencies'.
- Installs packages
1 other project uses a version of this.
Adopted by
Most recently taken up by
- lensetek/Research-Agent-Skills-Collectiontheir own version, first seen Jun 18, 2026
Other versions1 project uses a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 1
- lensetek/Research-Agent-Skills-Collection★ 1same name
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository162 other files it gives its agents.
- agents/AGENTS.mdAGENTS.md
- skills/compound-engineering/AGENTS.mdAGENTS.md
- skills/trailofbits-security/AGENTS.mdAGENTS.md
- CLAUDE.mdCLAUDE.md
- examples/CLAUDE.mdCLAUDE.md
- skills/compound-engineering/CLAUDE.mdCLAUDE.md
- skills/trailofbits-security/CLAUDE.mdCLAUDE.md
- app-store-reviewSkill
- advanced-javascriptSkill
- ai-native-uiSkill
- anime-jsSkill
- app-l100Skill
- barba-jsSkill
- brand-guidelinesSkill
- cinematic-web-engineSkill
- crossplatform-monorepoSkill
- css-first-uiSkill
- design-auditSkill
- design-critiqueSkill
- dev-cycleSkill
- device-hardware-bridgeSkill
- discovery-docSkill
- docxSkill
- edge-intelligenceSkill
- graph-aware-reviewSkill
- linkedin-posterSkill
- local-first-architectureSkill
- modern-build-pipelineSkill
- motion-nativeSkill
- nano-bananaSkill
- playwrightSkill
- pptxSkill
- project-initSkill
- remotionSkill
- sensory-nativeSkill
- spline-3dSkill
- streaming-cacheSkill
- tanstack-ecosystemSkill
- design-taste-frontendSkill
- tauri-desktopSkill
- threejsSkill
- transition-nativeSkill
- ui-design-stackSkill
- visual-nativeSkill
- web-l100Skill
- web-platform-apisSkill
- xlsxSkill
- better-authSkill
- claude-real-videoSkill
- clone-websiteSkill
- css-keyframe-animationsSkill
- design-checkSkill
- design-dnaSkill
- design-polishSkill
- drizzle-neonSkill
- fastlaneSkill
- angular-architectSkill
- api-designerSkill
- architecture-designerSkill
- atlassian-mcpSkill
- The first 60 shown.
The file
We split this skill into the rules it gives an agent
3 rules. About 0 are common, 2 are distinctive, and 1 is very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈2
Distinctive · estimate
This author's own choices. Worth a look.
1
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 48
Follow the next_tool_suggestions field in every response — it's the optimal next step.
- Distinctive: line 121
Prefer CRG MCP tools for code queries (no LLM extraction cost, auto-updates).
- Distinctive: line 122
Use graphify for discovery questions that span docs + code + research notes.
≈ “Common” is an estimate: at least 1 in 5 of the 213,895 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Codebase Knowledge Graph (Router)
Two graph tools live in this system. They are complementary, not redundant — this skill routes tasks to the right one.
Decision tree
Is the corpus code-only (Python, TS, Go, Rust, Java, etc.)?
├── YES → code-review-graph (CRG) — MCP-native, Tree-sitter, 23 langs
└── NO (docs + papers + images + tweets, or research corpus)?
└── graphify — LLM-assisted semantic extraction
Already have .code-review-graph/graph.db? → CRG (query via MCP)
Already have graphify-out/graph.json? → graphify (query via CLI)Tool A — code-review-graph (primary for code)
MCP-native. Tree-sitter. 22 tools. Auto-updates on Write/Edit. Registered at user scope via claude mcp add -s user code-review-graph uvx code-review-graph serve (stored in ~/.claude.json).
When to use
- Onboarding to a codebase (Python, TS, TSX, Go, Rust, Java, Scala, C#, Ruby, Kotlin, Swift, PHP, Solidity, C/C++, Dart, R, Perl, Lua, Zig, PowerShell, Julia, Vue, Svelte, Jupyter
.ipynb) - Mapping architecture before a refactor
- Blast-radius analysis: "what breaks if I change
login()?" - Risk-scored PR/commit review
- Finding hub nodes, bridges, surprise couplings
- Pre-loading context for Flow
/flow:mapor/flow:discover
Core usage via MCP tools
| Task | Tool |
| "Give me just enough context to start" | get_minimal_context(task="...") — ~100 tokens |
| "What calls this function?" | query_graph(pattern="callers_of", node="...") |
| "What does this call?" | query_graph(pattern="callees_of", node="...") |
| "What's affected if I change X?" | get_impact_radius(node="...") |
| "Find classes/functions by name" | semantic_search_nodes_tool(query="...") |
| "Full review context for a PR" | get_review_context(diff="...") |
| "Architecture overview" | prompt: architecture_map |
| "Pre-merge check" | prompt: pre_merge_check |
Follow the next_tool_suggestions field in every response — it's the optimal next step.
CLI (when MCP isn't available)
uvx code-review-graph build # parse codebase (~10s for 500 files)
uvx code-review-graph update # incremental (~2s, auto via hook)
uvx code-review-graph status # graph stats
uvx code-review-graph detect-changes # risk-scored diff impact
uvx code-review-graph visualize # D3.js HTML graph
uvx code-review-graph wiki # export Obsidian vault
uvx code-review-graph register <path> # multi-repo registryAuto-update
PostToolUse hook fires code-review-graph update on Write/Edit/MultiEdit if .code-review-graph/graph.db exists. No manual updates needed.
Output
.code-review-graph/graph.db— SQLite WAL store- Via
visualize: interactive D3.js HTML - Via
wiki: Obsidian vault with wikilinks - Via exports: GraphML (Gephi/yEd), Neo4j Cypher, SVG
Tool B — graphify (for mixed corpora)
LLM-assisted semantic extraction. Handles docs, papers, images, tweets, code together.
When to use
- Research corpus (PDFs + tweets + screenshots + notes)
- Karpathy-style
/rawfolder workflow - Cross-document concept mining
- Any corpus where LLM vision/semantic matters (e.g. chart images, handwritten notes)
- Code corpora where you want
INFERRED/AMBIGUOUSedge tagging and Q&A memory loop
Core usage (slash command)
/graphify # current dir → Obsidian vault
/graphify <path> # specific path
/graphify <path> --update # incremental
/graphify query "<question>" # BFS traversal
/graphify path "A" "B" # shortest path
/graphify explain "Node" # node explanation
/graphify --mcp # MCP stdio serverOutput
graphify-out/graph.json— persistent graphgraphify-out/GRAPH_REPORT.md— god nodes, surprises, suggested questionsgraphify-out/graph.html— interactive viz- Optional: Obsidian vault, SVG, GraphML, Neo4j push
Confidence-Scored Relationships (graphify only)
| Tag | Meaning | Confidence |
EXTRACTED | Found directly in source (import, call, inheritance, citation) | 1.0 |
INFERRED | Reasonable deduction from patterns | 0.4–0.9 |
AMBIGUOUS | Flagged for human review | 0.1–0.3 |
CRG uses a simpler three-tier edge confidence (EXTRACTED / INFERRED / AMBIGUOUS) plus float scores.
Integration with Flow
With /flow:map
For code-heavy repos, build CRG first → use get_minimal_context to guide mapping agents.
For mixed corpora, build graphify first → GRAPH_REPORT.md guides mapping.
With /flow:discover
Prefer CRG MCP tools for code queries (no LLM extraction cost, auto-updates). Use graphify for discovery questions that span docs + code + research notes.
When NOT to use graph tools
- Single-file tasks (overhead exceeds benefit)
- Already familiar with the codebase
- Quick lookups where Grep/Glob is faster
Performance
| Tool | Corpus | Reduction | Build time |
| CRG | Code-only, 500 files | 8.2× avg, up to 49× monorepo | ~10s |
| CRG | Incremental (auto) | N/A | <2s |
| graphify | Mixed, 50+ files | ~71.5× | Minutes (LLM) |
| graphify | Incremental | N/A | <2s code, minutes docs |
Retired: graphify install prerequisite
Previous versions of this skill required pip install graphifyy && graphify install as prereq. Now:
graphifyyis already installed (pip).code-review-graphis installed viauv tool install code-review-graph.- CRG is registered at user scope via
claude mcp add -s user code-review-graph uvx code-review-graph serve(writes to~/.claude.json— the authoritative MCP registry). Graphify is invoked as a CLI (python -m graphify) rather than a persistent MCP server. - No
graphify installorcode-review-graph installneeded — ATLAS wires them manually to preserve settings harmony. Do NOT usecode-review-graph install(it injects its own skills/hooks/CLAUDE.md text and clobbers the ATLAS layout).
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

