knowledge-graph-builder

knowledge-graph-builder is a skill for Claude Code, Codex from Morningstar202604/awesome-skillkit. It costs 165 tokens per session (2,825 once invoked), scanned A, original, Apache-2.0.

A knowledge-graph builder that turns Markdown notes into nodes and connections, then exports JSON, Graphviz DOT, or Mermaid diagrams. It can also report measures such as highly connected notes, separate groups, and isolated notes.

In plain words
What is it for?
Use it to extract links and marked concepts from notes, create graph files or diagrams, and inspect connection patterns.
Why use it?
It reveals the structure and disconnected parts of a note collection instead of leaving relationships hidden in files and links.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Needs its repository: it runs a file that does not travel with it, so clone the repository first. The line is # python3 scripts/graph_build.py --help >/dev/null && echo "script ok".

Good fit Use it to extract links and marked concepts from notes, create graph files or diagrams, and inspect connection patterns.

Compare 6 skills from other repositories ↓
Install

Getting it into your agent

It runs from inside its repository, so the clone comes first — what it calls does not travel with the file alone.

Clone the repo
git clone --depth 1 https://github.com/Morningstar202604/awesome-skillkit
agentmods
npx agentmods add skills/morningstar202604/awesome-skillkit/knowledge-graph-builder

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for knowledge-graph-builder

README.md
[![agentmods](https://agentmods.dev/badge/skills/morningstar202604/awesome-skillkit/knowledge-graph-builder/github.svg)](https://agentmods.dev/skills/morningstar202604/awesome-skillkit/knowledge-graph-builder)
Your own site
<a href="https://agentmods.dev/skills/morningstar202604/awesome-skillkit/knowledge-graph-builder"><img src="https://agentmods.dev/badge/skills/morningstar202604/awesome-skillkit/knowledge-graph-builder/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for knowledge-graph-builder

Your own site · 80×15
<a href="https://agentmods.dev/skills/morningstar202604/awesome-skillkit/knowledge-graph-builder"><img src="https://agentmods.dev/badge/skills/morningstar202604/awesome-skillkit/knowledge-graph-builder.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 165 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 2,825 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00165 $0.02825
Opus 5.5 $0.00066 $0.01130
Sonnet 5.5 $0.00033 $0.00565
Haiku 4.5 $0.00016 $0.00282

Measured 2mo ago against content hash 1edbd159ac78, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

knowledge-graph-builder scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2mo ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

site/skills/knowledge/knowledge-graph-builder/SKILL.md · 194 lines

How it starts

The opening of the file, as written. The whole thing — 194 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Knowledge Graph Builder

Turn a pile of Markdown notes into a graph of nodes + edges: notes are nodes, [[double links]] are edges, and bolded words join the graph as candidate concept entities. It produces three consumable forms — JSON for programs, DOT for graphviz, Mermaid for documents — plus a set of graph metrics (degree centrality, connected components, isolated nodes) to answer: where is the skeleton of this note set, and where is it broken.

The "extraction" step uses heuristic rules, not NLP: a [[link]] is an edge, an H1 is the node title, **bold** is a candidate entity. So the graph's accuracy depends on how disciplined your note-writing is — read the extraction contract in step 2 before writing.

This skill does not do retrieval and indexing (that is personal-wiki), does not do entity disambiguation and knowledge fusion (which needs NLP models; this skill deliberately does not introduce them), and does not draw architecture diagrams (that is arch-diagram).

Input Checklist

Input Required Default Notes
Notes directory Yes — Recursively scans .md/.markdown/.txt
Export format No json One of json / dot / mermaid
Include candidate entities No Included Add --note-only to see only the link skeleton between notes
Centrality stat scope No All nodes When --notes-only, ignores concept nodes
Output path No stdout / <dir>/graph.json Prints to stdout if unspecified

When inputs are missing, ask for all at once:

Please provide: ① where is the notes directory? ② what format do you want (JSON for programs / DOT for graphviz / Mermaid to paste into a document)? ③ do you only care about links between notes, or should bolded concepts also be included? ④ are there any known isolated notes you want to check first?

Pre-flight Self-check

Run each item; on any failure → take the stated action:

# 1. Python version
python3 --version
# expect: Python 3.8+. Fail → STOP.

# 2. The script is available
# python3 scripts/graph_build.py --help >/dev/null && echo "script ok"
# expect: script ok. Fail → check the scripts/ path.

# 3. The directory has parseable notes
find <notes-dir> -name "*.md" -not -path "*/.*" | head -5
# expect: at least 1 file. Fail → the script will report "no Markdown notes found"; confirm the path first.

# 4. Optional: is graphviz local (only affects DOT-to-image, not export)
which dot >/dev/null && echo "graphviz ok" || echo "no graphviz (DOT can still be exported for the user to render)"

Read the full file on GitHub · 194 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 2mo ago Changed · +2 lines · +1 tokens per session 1edbd159ac78
  2. 2mo ago Changed db58ba07522c
  3. 2mo ago First seen · 192 lines · 164 tokens per session scan A ee00a1d951bf

Subscribe to this mod's changes

knowledge-graph-builder is a skill published in the GitHub repository Morningstar202604/awesome-skillkit (0 stars, last pushed 2mo ago), licensed Apache-2.0. It adds 165 tokens to every session and 2,825 once invoked, about $0.0007 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-19.

Related

knowledge-graph-builder compared with skills from other repositories

knowledge-graph-builder next to 6 skills from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
knowledge-graph-builderMorningstar202604/awesome-skillkitSkill02mo agoApache-2.0A165Claude Code, Codex
safe-refactorJuliusBrussee/cavemanSkill124kyesterdayApache-2.0A29Claude Code, Codex
mem0-oss-to-platformmem0ai/mem0Skill70k4d agoApache-2.0A217Claude Code, Codex
auditing-subgroup-fairnessmaziyarpanahi/openmedSkill5.9kyesterdayApache-2.0A148Claude Code
memoryopensquilla/opensquillaSkill7.2k5d agoApache-2.0A44Claude Code, Codex
infographic-template-updaterantvis/InfographicSkill7.2k1mo agoMITA43Claude Code
pulse-configureSnowflake-Labs/cocoplusSkill72924d agoMITA12Claude Code, Codex