跳到正文
cccskills
免费在 GitHub 公开

knowledge-graph

Knowledge graph and smart memory management using graphify + Obsidian-inspired patterns. Use when: setting up a knowledge graph, managing memory health, cross-linking notes, compiling wiki pages from scattered notes, adding structured frontmatter, or running memory health checks. Triggers on: 'knowledge graph', 'graphify', 'wiki', 'cross-link', 'memory health', 'frontmatter', 'compile notes', 'wikilinks'.

中文简介正在准备中。当前显示原文说明。

集成工具Obsidian
查看安装方法

包含的文件(5)

  • SKILL.md5.0 KB
  • scripts/memory_health.py9.4 KB
  • scripts/note_frontmatter.py5.4 KB
  • scripts/wiki_compiler.py7.3 KB
  • scripts/wiki_crosslinker.py5.2 KB

SKILL.md(原文)

安装前可以查看交给 AI 代理的指令内容。

Knowledge Graph Skill

Turn any workspace into a queryable knowledge graph with smart memory management. Combines graphify (code/doc graph) with three Obsidian-inspired patterns.

Installation

In pa-skills repo, the skill is at the root: pa-skills/knowledge-graph/ (not under skills/). Copy it to your workspace:

# From your pa-skills clone
cp -r knowledge-graph/ /path/to/your/workspace/skills/knowledge-graph/

Prerequisites

pip install graphifyy
graphify claw install  # ⚠️ This MODIFIES your AGENTS.md — adds graphify query rules

Important: graphify claw install appends a ## graphify section to your AGENTS.md. This is intentional — it tells your agent to check the graph before reading raw files. Review the changes after running it.

.graphifyignore

Create .graphifyignore in your workspace root to exclude noise:

node_modules/
.git/
media/
.tmp/
tmp/
graphify-out/
pa-skills/
skills-external/
*.pdf
*.ogg
*.jpg
*.png

Critical: If you have both pa-skills/knowledge-graph/ and skills/knowledge-graph/ on disk, add pa-skills/ to .graphifyignore to avoid duplicate nodes in the graph. If your repo clone lives under .tmp/pa-skills/, exclude .tmp/ too or the duplicate noise will still leak in.

Components

1. Knowledge Graph (graphify)

Build and query a knowledge graph from code + docs.

# Initial setup (AST-only, free)
graphify update .

# Query the graph
graphify query "how does X connect to Y"
graphify path "ModuleA" "ModuleB"
graphify explain "concept"

# After code changes
graphify update .

Full semantic extraction (with LLM) produces richer cross-doc connections. See graphify claw install output for AGENTS.md integration rules.

2. Auto Cross-Linker

Scans notes and adds [[wikilinks]] for known concepts from the graph.

# Build concept index from graph nodes + skills + projects
python3 scripts/wiki_crosslinker.py --build-index

# Cross-link today's daily note
python3 scripts/wiki_crosslinker.py --daily

# Cross-link all daily notes
python3 scripts/wiki_crosslinker.py --all-daily

Concepts come from: graphify nodes, skill names, project names, contacts. Only links document-type nodes with 4+ character names. Skips code internals.

3. Wiki Compiler (Karpathy Pattern)

"Compile once, query forever" — instead of RAG every time, compile scattered mentions into structured wiki pages per topic.

# See what needs compiling
python3 scripts/wiki_compiler.py --scan

# Compile all topics with 3+ mentions
python3 scripts/wiki_compiler.py --compile

# Compile one specific topic
python3 scripts/wiki_compiler.py --compile "onboarding"

# Check wiki status
python3 scripts/wiki_compiler.py --status

Output: wiki/<topic>.md with frontmatter, timeline of mentions, and graph connections. Each page is a self-contained summary — query it directly instead of scanning raw notes.

4. Structured Frontmatter

Adds YAML frontmatter with auto-detected tags to notes.

# Add frontmatter to all daily notes
python3 scripts/note_frontmatter.py --all-daily

# Add frontmatter to project docs
python3 scripts/note_frontmatter.py --projects

# Query by frontmatter
python3 scripts/note_frontmatter.py --query tag=onboarding
python3 scripts/note_frontmatter.py --query type=project

Auto-tags: graphify, crons, ops, whatsapp, calendar, content, monday, onboarding, pa-network, infra, memory, eval, self-improve, skills, owner.

5. Memory Health Checker

Runs on the knowledge graph to detect memory problems.

# Full report
python3 scripts/memory_health.py

# Quick summary
python3 scripts/memory_health.py --quick

Checks: orphan nodes, daily note gaps, stale MEMORY.md entries, weak communities, unreferenced skills, recent vs old activity.

Recommended Crons

# Daily: memory health check (04:00 UTC)
daily-memory-health: python3 scripts/memory_health.py --quick

# Weekly: wiki compilation + cross-linking (Sun 03:00 UTC)
weekly-wiki-compile:
  1. python3 scripts/wiki_crosslinker.py --build-index
  2. python3 scripts/wiki_compiler.py --compile
  3. python3 scripts/note_frontmatter.py --all-daily
  4. python3 scripts/note_frontmatter.py --projects
  5. graphify update .

Token Impact

OperationWithoutWithReduction
Topic recall~15K tokens (scan daily notes)~200 tokens (wiki page)75x
Architecture query~411K tokens (read all files)~155 tokens (graph query)2,655x
"What happened with X"grep all notesfrontmatter query + wiki page~50x

评价

还没有评价。欢迎分享你的使用感受。

评论

无需登录即可发表。欢迎分享使用感受、提问,或说明在哪些环境下无法运行。

还没有评论。来写第一条吧。

提交后会立即公开。请勿填写邮箱、电话等个人信息。URL 最多 2 个。

0 / 1000 字

此表单受 reCAPTCHA 保护,适用 Google 的隐私权政策和服务条款。

同一仓库的技能

ai-pa

免费

AI Personal Assistant network skill for multi-agent PA coordination. Use when: contacting another PA, coordinating with peer agents, scheduling meetings between owners, broadcasting messages to PA groups, or looking up contacts from the local PA directory. Reads contact data from data/pa-directory.json in the workspace.

中文简介正在准备中。当前显示原文说明。

netanel-abergel/pa-skills62026年5月10日 更新

ai-pa

免费

AI Personal Assistant network skill. Use when: contacting another PA, coordinating with peer agents, scheduling meetings between owners, broadcasting messages, looking up contacts from the local PA directory, or performing any cross-PA task. Reads contact data from data/pa-directory.json in the workspace. Does NOT contain hardcoded contact data — each PA maintains their own directory file.

中文简介正在准备中。当前显示原文说明。

netanel-abergel/pa-skills62026年5月10日 更新

ai-pa

免费

Route and execute inter-PA coordination tasks in the OpenClaw multi-agent PA network. Triggers when: contacting another PA, passing a message between owners, broadcasting to a PA group, handling group lead/silence rules, or adding a new PA to the directory. NOT for: contact lookups (use contact-list skill), calendar invites (use meetings skill), or billing issues (use billing-monitor skill).

中文简介正在准备中。当前显示原文说明。

netanel-abergel/pa-skills62026年5月10日 更新

OpenClaw API gateway proxy for authenticated SaaS calls (100+ services in references/SERVICES.md). Use ONLY when making an HTTP request to a third-party service that requires the gateway's stored credentials. NOT for direct API calls with bearer tokens already in scope, NOT for monday.com (use monday-for-agents), NOT for WhatsApp (use heleni-whatsapp). Triggers: "call the X API", "fetch from <service>", "send to Slack via gateway", "use the gateway for".

中文简介正在准备中。当前显示原文说明。

netanel-abergel/pa-skills62026年5月10日 更新

Automatically creates new skills from complex problem-solving sessions. Triggers at the end of multi-step tasks that required novel approaches, debugging sessions, or workflow creation. Use when: a task took 3+ tool calls, involved a non-obvious solution, or established a pattern likely to recur. Also triggers on: "create a skill from this", "save this as a skill", "this should be a skill".

中文简介正在准备中。当前显示原文说明。

netanel-abergel/pa-skills62026年5月10日 更新

Monitor for API billing errors and alert the owner and admin immediately. Use when: an API billing error is detected, a peer PA reports a billing error, or during routine health checks. Handles detection, notification, and fallback model switching. Model-agnostic: works with any LLM provider (Anthropic, OpenAI, Google, etc.).

中文简介正在准备中。当前显示原文说明。

netanel-abergel/pa-skills62026年5月10日 更新

查看 netanel-abergel 的全部技能

报告此技能的问题