knowledge-graph

knowledge-graph is a skill for Claude Code, Codex from JansenAnalytics/claudex. It costs 47 tokens per session (1,710 once invoked), scanned A, original, MIT.

A local database that stores things such as people, projects, decisions, tools, and rules, along with the relationships between them. It can search these records, trace connections, show timelines, and read information from Markdown files.

In plain words
What is it for?
Use it to record project decisions, map dependencies, track who made choices, connect tools to projects, and explore related information.
Why use it?
It makes connected project knowledge easier to find than scattered notes and flat files. Relationship searches can show how a decision, person, tool, or project is linked to other records.

Skill for Claude CodeCodex

Which agent this was written for is unclear — built for openclaw. Also seen: built for openclaw.

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add skills/jansenanalytics/claudex/knowledge-graph
Any agent
npx skills add JansenAnalytics/claudex --skill knowledge-graph
Clone the repo
git clone --depth 1 https://github.com/JansenAnalytics/claudex

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

README.md
[![agentmods](https://agentmods.dev/badge/skills/jansenanalytics/claudex/knowledge-graph.svg)](https://agentmods.dev/skills/jansenanalytics/claudex/knowledge-graph)
Your own site
<a href="https://agentmods.dev/skills/jansenanalytics/claudex/knowledge-graph"><img src="https://agentmods.dev/badge/skills/jansenanalytics/claudex/knowledge-graph.svg" alt="Measured on agentmods" height="20"></a>
Per session 47 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,710 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
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.00047 $0.01710
Opus 5 $0.00023 $0.00855
Sonnet 5 $0.00009 $0.00342
Haiku 4.5 $0.00005 $0.00171

Measured 2d ago against content hash e184550ef6b0, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-06, from the pricing page.

Security

Grade A, and why

knowledge-graph 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 2d ago.

The scan reads SKILL.md. This mod also ships 1 executable file (scripts/kg.cjs), listed below but not scanned — reading those needs a real analyzer, not pattern matching.

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.

skills/knowledge-graph/SKILL.md · 198 lines

How it starts

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

Knowledge Graph Skill

Overview

SQLite-backed entity-relationship store. Entities (people, projects, decisions, tools, rules) connected by typed relations (decided-by, depends-on, supersedes, etc.). Full-text search, path finding, timeline, and auto-ingestion from markdown files.

Why this over flat files: "Which database did we choose for web-platform, who decided it, and what did it supersede?" → one query returns the decision, who made it, when, what it superseded, and what it relates to. With flat files, that's 5 greps across MEMORY.md and daily logs.

Script

KG=${CLAUDE_SKILLS_DIR:-$HOME/.claude-agent/.claude/skills}/knowledge-graph/scripts/kg.cjs
node $KG <command> [args]

Entity Types

Type Emoji Use For
person 👤 People (the tech lead, a teammate)
project 📁 Projects (web-platform, mobile-app)
decision ⚖️ Design decisions, choices made
tool 🔧 Tools, services, libraries
account 💰 API accounts, service accounts, credentials
concept 💡 Ideas, concepts, mental models
rule 📏 Rules, constraints, invariants
event 📅 Events, meetings, incidents
skill 🎯 OpenClaw skills
file 📄 Important files, configs
service ⚙️ Running services, Docker containers

Relation Types

Relation Meaning Auto-behavior
decided-by Who made this decision
depends-on X requires Y
related-to Loosely connected
supersedes X replaces Y Auto-marks Y as superseded 🔴
belongs-to X is part of project Y
created-by Who/what created this
blocked-by X is blocked by Y
implements Tool X implements decision Y
uses X uses tool/library Y
contradicts X conflicts with Y
derived-from X was derived from Y
part-of X is a component of Y
triggers X triggers Y
configures X configures Y
owns X owns/manages Y

Read the full file on GitHub · 198 lines

Files

What ships with it

1 file beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

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. 2d ago First seen · 198 lines · 47 tokens per session scan A e184550ef6b0

Subscribe to this mod's changes

knowledge-graph is a skill published in the GitHub repository JansenAnalytics/claudex (5 stars, last pushed 2mo ago), licensed MIT. It adds 47 tokens to every session and 1,710 once invoked, about $0.0002 per session on Opus 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-03.

Related

Other skills, from other repositories

memory-manager

Persistent project memory using SQLite + FTS5 + BM25. Fast, zero dependencies (stdlib only), production-ready. Progressive disclosure with 3 layers (compact/index/detailed).

buiphucminhtam/forgewright · 39 tokens

mempalace-task

Create, hand off, claim, execute, and close agent tasks through the MemPalace logstream. Use when the user wants to delegate work, prepare a ready-to-paste task for another agent, receive a MemPalace task id, or explicitly launch a supported headless agent in controlled mode.

MemPalace/mempalace · 67 tokens

neat-freak

Knowledge and governance closeout: reconcile project docs, rule files (CLAUDE.md/AGENTS.md), authorized agent memory, and workspace residue with what the code and runtime actually do, so the next session or the next person starts from one current answer. Trigger when the user names "neat-freak", "洁癖", or "/neat" — and…

KKKKhazix/khazix-skills · 202 tokens

mission-control

Interact with Mission Control — AI agent orchestration dashboard. Use when registering agents, managing tasks, syncing skills, or querying agent/task status via MC APIs.

builderz-labs/mission-control · 34 tokens

commonly

You are a member of a Commonly workspace — a shared space where humans and AI agents from any origin collaborate in pods (chat rooms with memory). Use this whenever you are connected to Commonly via the commonly MCP tools: to read what's happening, post, remember things across sessions, react, DM other agents, and…

Team-Commonly/commonly · 0 tokens

state

Use when the user says 'update state', 'project state', 'where was I', or at session start to load current context.

cwinvestments/memstack · 29 tokens