graphify
Skill4 starsChanged 5 months agoMITView on GitHub
Builds a compact JSON knowledge graph for a software project, enabling ~70x token savings compared to scanning source files. Creates knowledge_graph.json (meta + architecture + critical_rules + clusters) and per-cluster Obsidian .md files for RAG-style access. Triggers on: 'graphify', 'knowledge graph', 'map the project', 'build graph', 'create graph', 'граф на проекта', 'знания граф', or when starting work on a new project without an existing graph.
51 other projects use a version of this.
Adopted by
Most recently taken up by
- hahuyhungdev/ai-coding-configtheir own version, first seen Oct 2, 2026
- uniskela/adhd-hubtheir own version, first seen Sep 28, 2026
- Graphify-Labs/graphifytheir own version, first seen Sep 27, 2026
- cailleachzou/skillstheir own version, first seen Sep 27, 2026
- ivuorinen/skillstheir own version, first seen Sep 24, 2026
- buildomator/buildomatortheir own version, first seen Sep 20, 2026
Used with
Projects with it also use defuddle, json-canvas and 10 more.
Other files people use alongside this one.
Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
joeseesunSkilldefuddle
Extract clean article content from web pages or local HTML files. Removes clutter (ads, sidebars, nav) and returns readable content with metadata.
Also in 5 projects that use this
KKodiacSkilljson-canvas
Create and edit JSON Canvas files (.canvas) with nodes, edges, groups, and connections. Use when working with .canvas files, creating visual canvases, mind maps, flowcharts, or when the user mentions Canvas files in Obsidian.
Also in 4 projects that use this
jorgeasaurusSkillponytail-review
Code review focused exclusively on over-engineering. Finds what to delete: reinvented standard library, unneeded dependencies, speculative abstractions, dead flexibility. One line per finding: location, what to cut, what replaces it. Use when the user says "review for over-engineering", "what can we delete", "is this over-engineered", "simplify review", or invokes /ponytail-review. Complements correctness-focused review, this one only hunts complexity.
Also in 3 projects that use this
OpenAISkillplaywright
Use when the task requires automating a real browser from the terminal (navigation, form filling, snapshots, screenshots, data extraction, UI-flow debugging) via `playwright-cli` or the bundled wrapper script.
Also in 3 projects that use this
gcpdevSkillllm-council
Multi-LLM collaborative brainstorming and planning. Use when user explicitly requests consultation with multiple AI models (ChatGPT, Gemini, other LLMs) before presenting an implementation plan, or asks to "consult the council", "ask other models", or "get perspectives from other AIs". Queries external LLM APIs, synthesizes their perspectives, and presents an adapted implementation plan.
Also in 3 projects that use this
StrayDragonSkillui-ux-pro-max
UI/UX design intelligence. 50 styles, 21 palettes, 50 font pairings, 20 charts, 8 stacks (React, Next.js, Vue, Svelte, SwiftUI, React Native, Flutter, Tailwind). Actions: plan, build, create, design, implement, review, fix, improve, optimize, enhance, refactor, check UI/UX code. Projects: website, landing page, dashboard, admin panel, e-commerce, SaaS, portfolio, blog, mobile app, .html, .tsx, .vue, .svelte. Elements: button, modal, navbar, sidebar, card, table, form, chart. Styles: glassmorphism, claymorphism, minimalism, brutalism, neumorphism, bento grid, dark mode, responsive, skeuomorphism, flat design. Topics: color palette, accessibility, animation, layout, typography, font pairing, spacing, hover, shadow, gradient.
Also in 6 projects that use this
Other versions51 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 51
- Graphify-Labs/graphify★ 124ksame name
- ZaxbyHub/opencode-swarm★ 485same name
- EBISPOT/ols4★ 104same name
- buildomator/buildomator★ 90same name
- gavishap/omnia-vault★ 80same name
- mycelium-hq/ai-brain-starter★ 38same name
- IgorGanapolsky/ThumbGate★ 27same name
- ItsssssJack/seven-skills★ 19same name
- PanPanFR/oh-my-kilo★ 12same name
- PanPanFR/oh-my-openkilo★ 9same name
41 more not listed
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 repository8 other files it gives its agents.
- CLAUDE.mdCLAUDE.md
- dev-wikiSkill
- fix-flowSkill
- four-layer-initSkill
- improve-loopSkill
- kb-ingestSkill
- skill-creatorSkill
- token-optimizerSkill
The file
Show its rules and text
We split this skill into the rules it gives an agent
14 rules. 0 are common, 6 are distinctive, and 8 are very specific to this project.
0
Common
Most of the 50 edited versions we read keep these.
6
Distinctive
This author's own choices. Worth a look.
8
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 27
If the project is a collection of scripts (e.g.
- Very specific: line 34
Every file on disk should land in *some* cluster (Step 3).
- Distinctive: line 40
Read the entry point first (80% of architecture info lives here):
- Very specific: line 56
Do NOT read all files — entry point + 2-3 ls commands are enough for Step 2.
- Very specific: line 71
Use references/graph-template.json as the structure guide.
- Very specific: line 95
Add an edges array to the JSON: typed relationships between clusters so an AI can decide "go deeper or skip" from the edge type alone — …
- Distinctive: line 109
Add 3-10 edges for the non-obvious cross-cluster relationships.
- Very specific: line 113
Use references/cluster-template.md as structure guide.
- Very specific: line 123
Run ONLY after the new .md files exist (Step 5) — never before, or a crash mid-write could delete files with no replacement.
- Distinctive: line 137
Add (or update) this section in the project's CLAUDE.md:
- Distinctive: line 152
Check: FastAPI-Router-Pattern, Multi-tenant-Isolation, SaaS-Plan-Gating, Soft-Delete-Audit-Pattern
- Very specific: line 165
After writing knowledge_graph.json, READ IT BACK FROM DISK and compare the actual counts against what you intended.
- Distinctive: line 180
Only declare done when the printed numbers match what you intended to write.
- Distinctive: line 195
Rule: If entry point + ls gives enough to write the graph — stop reading.
“Common” is measured: kept by at least 6 in 10 of the 50 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Graphify
Build a compact JSON knowledge graph for a software project. Result: knowledge_graph.json +
per-cluster .md files readable in ~70x fewer tokens than scanning source files directly.
When to Use
- New project — no graph exists yet
- Project has changed significantly — graph is stale
- User says "graphify", "build graph", "граф на проекта"
Step 1 — Initialize Output Directory
python skills/graphify/scripts/init_graph.py "<ProjectName>" "<{{WIKI_PATH}}/Project/graph>"This creates placeholder files. Proceed to fill them in.
Step 1b — Audit Script Completeness (for script-collection projects)
If the project is a collection of scripts (e.g. scripts/*.py), the graph must
not silently omit files. Count them and record the number for the meta block:
ls scripts/ | grep '\.py$' | wc -l # total .py files on diskEvery file on disk should land in some cluster (Step 3). Any file not placed
in a cluster is invisible to every agent that trusts the graph as the map.
Record the disk count — it becomes meta.script_count in Step 4.
Step 2 — Discover Project Structure
Read the entry point first (80% of architecture info lives here):
# Python/FastAPI
head -120 backend/main.py # app.include_router() calls -> all domains
grep "include_router" backend/main.py # full list of routers
# Node.js/Express
head -80 src/app.js # app.use() calls -> all route domains
grep "app.use\|require.*router" src/app.js
# Then list top-level directories only
ls backend/
ls src/Do NOT read all files — entry point + 2-3 ls commands are enough for Step 2.
Step 3 — Identify Clusters
From the entry point, group related routers/modules into 6-14 domain clusters.
Cluster naming (use these standard names when they fit):
auth | invoicing | expenses | accounting | tax_compliance | hr_payroll |
clients | platform | ai | frontend | core | api | ml | tasks |
queue_workers | crawler | graph | identity
Each cluster = one .md file + one entry in clusters{} in the JSON.
Step 4 — Fill knowledge_graph.json
Use references/graph-template.json as the structure guide.
Add these self-auditing fields to meta (so staleness is detectable —
integrity_guard.py compares them against disk and FLAGS drift):
script_count— the integer from Step 1b (total.pyfiles on disk).test_count— frompython -m pytest tests/ --collect-only -q 2>&1 | grep "tests collected"(use a hidden-window subprocess; setnullif pytest is unavailable).graph_updated— today's date.
critical_rules is the most valuable section — add 5-15 rules that are:
- Non-obvious (NOT derivable just by reading the code)
- Actionable (tell what TO DO or NOT TO DO)
- Specific (include field names, method names, error symptoms)
Example rules worth capturing:
"Expense IDs = UUID strings — NOT integers"
"Login = form-encoded: POST /auth/login expects form data, NOT JSON"
"Static routes BEFORE /{id} — /suggest-category before /{expense_id}"
"predict_proba: do NOT pass cat_features (causes runtime error)"
"exitClientContext() — correct method. NOT stopActingAsClient"Step 4b — Typed Edges (optional but high-value)
Add an edges array to the JSON: typed relationships between clusters so an AI
can decide "go deeper or skip" from the edge type alone — without reading file
contents (the Infinite Brain insight: typed edges cut traversal tokens ~15x).
"edges": [
{"from": "frontend", "to": "auth", "type": "depends_on", "note": "UI gates on session"},
{"from": "queue_workers", "to": "api", "type": "followed_by", "note": "API enqueues, worker consumes"}
]Edge types: depends_on · part_of · preceded_by/followed_by (pipeline order) ·
derived_from · supports · contradicts · related_to · authored.
Add 3-10 edges for the non-obvious cross-cluster relationships. Skip for trivial projects.
Step 5 — Fill Cluster .md Files
Use references/cluster-template.md as structure guide.
For each cluster, read only:
- The router/module file (endpoints + key functions)
- The model definition (fields, constraints)
Fill in: files list, endpoints, data model, critical rules specific to this cluster.
Step 5b — Clean Orphaned Cluster Files
Run ONLY after the new .md files exist (Step 5) — never before, or a crash
mid-write could delete files with no replacement. Delete .md files that no
longer correspond to a current cluster (a renamed/removed cluster leaves a stale
file that misleads agents into seeing clusters the JSON does not have):
$graphDir = '{{WIKI_PATH}}\ProjectName\graph'
$keys = (Get-Content "$graphDir\knowledge_graph.json" -Raw | ConvertFrom-Json).clusters.PSObject.Properties.Name
$keep = $keys + @('index','shared-patterns','cross_project')
Get-ChildItem $graphDir -Filter '*.md' | Where-Object { $_.BaseName -notin $keep } | Remove-Item -Confirm:$falseStep 6 — Update CLAUDE.md
Add (or update) this section in the project's CLAUDE.md:
## Knowledge Graph (RAG)
**Before searching files — read the graph first (~70x fewer tokens):**
`{{WIKI_PATH}}\ProjectName\graph\knowledge_graph.json`
Obsidian visualization: `{{WIKI_PATH}}\ProjectName\graph\`Find the right insertion point — before "On-Demand Reference" or at the end of Architecture section.
Step 7 — shared-patterns.md
Fill graph/shared-patterns.md with which cross-project patterns apply:
{{RESEARCH_PATH}}\Claude Code Resurch\wiki\concepts\— available patterns- Check: FastAPI-Router-Pattern, Multi-tenant-Isolation, SaaS-Plan-Gating, Soft-Delete-Audit-Pattern
Output Checklist
knowledge_graph.json— meta (incl. script_count + test_count), architecture, critical_rules (5-15), clustersindex.md— navigation table with all clusters- One
.mdper cluster — files, endpoints, data model, rules shared-patterns.md— applicable cross-project patterns- Project
CLAUDE.md— Knowledge Graph RAG section added - Step 7b post-write verification run — printed counts match intent
Step 7b — Post-Write Verification (MANDATORY before reporting done)
After writing knowledge_graph.json, READ IT BACK FROM DISK and compare the
actual counts against what you intended. This guards against the failure mode
where an agent reports "updated to N clusters / M rules" while the file on disk
holds different values (the graph generated in memory but never persisted, or a
later regen clobbered a manual edit).
import json
d = json.load(open(r"{{WIKI_PATH}}\ProjectName\graph\knowledge_graph.json", encoding="utf-8"))
print("clusters:", len(d["clusters"]),
"| critical_rules:", len(d["critical_rules"]),
"| script_count:", d["meta"].get("script_count"),
"| test_count:", d["meta"].get("test_count"))Only declare done when the printed numbers match what you intended to write. If they differ, the write failed or was overwritten — re-write and re-verify. Never report counts from memory; report only what this read-back prints.
Token Budget
| Action | Tokens |
| Read entry point (head -120) | ~800 |
| grep include_router | ~200 |
| ls top-level dirs | ~100 |
| Read 1-2 key router files | ~1,500 |
| Total discovery | ~2,600 |
| vs. scanning all files | ~180,000+ |
Rule: If entry point + ls gives enough to write the graph — stop reading. Do NOT read every file.
Existing Graphs (Projects with Graphs)
| Project | Graph Path |
| Fakturka.bg | {{WIKI_PATH}}\Fakturka.bg\graph\ |
| CasinoScore AI | {{WIKI_PATH}}\CasinoScore\graph\ |
| Autoagency | {{WIKI_PATH}}\Autoagency\graph\ |
| StroyOffice Pro | {{WIKI_PATH}}\StroyOffice\graph\ |
| Cinemind | {{WIKI_PATH}}\Cinemind\graph\ |
| DaVinci Plugin (DCTL) | {{WIKI_PATH}}\DCTL\graph\ |
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.

