doc-graph-health

doc-graph-health is a skill for Claude Code from ryanzhao1011/workframe. It costs 204 tokens per session (1,569 once invoked), scanned A, original, MIT.

A knowledge-base health checker for finding broken links, isolated documents, heavily referenced pages, stale information, and other documentation problems. It writes a report describing the findings.

In plain words
What is it for?
Use it to inspect a knowledge graph or documentation repository. It can check links, orphaned pages, central reference pages, update dates, mismatched requirement documents, and other listed health signals.
Why use it?
It reveals when a documentation system has missing connections, outdated pages, or inconsistent related documents. This gives maintainers a concrete list of issues to fix or archive.

Skill for Claude Code

Written for Claude Code: allowed-tools in frontmatter. Also seen: names the AskUserQuestion tool.

Part of the core plugin — 38 skills, 4 agents, 13 hooks shipped together

Good fit Use it to inspect a knowledge graph or documentation repository. It can check links, orphaned pages, central reference pages, update dates, mismatched requirement documents, and other listed health signals.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/ryanzhao1011/workframe/doc-graph-health
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.

Any agent
npx skills add ryanzhao1011/workframe --skill doc-graph-health
Clone the repo
git clone --depth 1 https://github.com/ryanzhao1011/workframe

Made for: Claude Code.

Or install core, the plugin that ships this one along with the rest of its 38 skills, 4 agents, 13 hooks.

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 doc-graph-health

README.md
[![agentmods](https://agentmods.dev/badge/skills/ryanzhao1011/workframe/doc-graph-health/github.svg)](https://agentmods.dev/skills/ryanzhao1011/workframe/doc-graph-health)
Your own site
<a href="https://agentmods.dev/skills/ryanzhao1011/workframe/doc-graph-health"><img src="https://agentmods.dev/badge/skills/ryanzhao1011/workframe/doc-graph-health/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 doc-graph-health

Your own site · 80×15
<a href="https://agentmods.dev/skills/ryanzhao1011/workframe/doc-graph-health"><img src="https://agentmods.dev/badge/skills/ryanzhao1011/workframe/doc-graph-health.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 204 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,569 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.00204 $0.01569
Opus 5.5 $0.00082 $0.00628
Sonnet 5.5 $0.00041 $0.00314
Haiku 4.5 $0.00020 $0.00157

Measured today against content hash 79f1d49cd42e, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

doc-graph-health 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 today.

The scan reads SKILL.md. This mod also ships 1 executable file (scripts/graph_health.py), 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.

plugins/core/skills/doc-graph-health/SKILL.md · 73 lines

How it starts

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

Doc Graph Health 知识网健康巡检

定位

对应 LLM Wiki 闭环的「Audit 体检」阶段:让知识库能自我发现断链、孤岛、过期与缺口。

事实源分工:检测逻辑与阈值在本 skill scripts/graph_health.py;报告 projects/modules/graph-health.md 由脚本重算,勿手改正文;本 SKILL.md 只管「何时跑、怎么读、如何处置」。

怎么跑

从项目根目录执行(插件根路径由 SessionStart hook 写入 plugin-root.txt,不依赖 PATH):

python "$(cat .workframe/state/plugin-root.txt)/skills/doc-graph-health/scripts/graph_health.py"          # 全量巡检 + 覆写报告
python "$(cat .workframe/state/plugin-root.txt)/skills/doc-graph-health/scripts/graph_health.py" --dry    # 只看摘要不写报告

跑完对比上次:git diff -- projects/modules/graph-health.md(收敛趋势比绝对数字重要)。

七项检测与处置

检测 含义 处置
断链 wikilink / md 链接 / frontmatter related 目标不存在;报告单列「模块记忆断链」段全部列出,总表只列前 50 条 少量直接修;成批查根因(改名未同步等);模块记忆断链按 librarian 复查处置
孤儿 入链=0 的文档(三源计入度;结构性文件已豁免) 有价值 → 补上级 related / 正文链接;过时 → 归档 projects/archive/;两者都不做时留在报告里可见
Hub 被引 top10 只读参考——横向核心资产,重构/改名时优先评估影响面
stale current-state 超 45 天未同步 stub 形态 → 排期 code-to-doc;有内容 → 让 @dev 核对代码后刷新
姊妹时差 req overview 落后同 req prd >7 天 必须逐对抽读确认:比对 overview 定位段与 prd「变更与决策记录」,确认口径矛盾(如字段列数、规则枚举)→ 修 overview 正文(bump updated);无矛盾 → 报告中该对会随 overview 下次更新自然消失
updated 缺失/格式错 有 frontmatter 但 updated 不可解析——这些文件游离在 stale 判定之外 按 document-norms §2.7 补齐(实时 ISO-8601)
概念热点 词表词高频提及但未链接 织网候选(补 wikilink)或评估是否立跨模块 spec

概念热点的词表来源(项目自配)

优先级:.workframe-config.json 的 graph_health.hotspot_words(显式覆盖)→ projects/specs/_meta/taxonomy.md「## 能力域」表格(推荐正源:词表随项目 tags 纪律自然生长)→ 两者皆无则跳过本维度并在报告中给启用指引。

报告会标注词表来源与 taxonomy 的 updated 时间——词表停更 = 本维度漏检新概念,看到来源时间明显陈旧时先更新词表再看结论。

排除纪律(与巡检口径一致,勿放宽)

  • 基线排除目录:prototypes/(含 demo 整仓)、node_modules/、.claude/、tmp/、_draft/、assets/;项目可经 config graph_health.extra_exclude_dirs 追加
  • 结构性豁免:current-state/ 四件套、requirements/overview.md 清单页、module-memory.md(位置约定即入口,不计孤儿)
  • 行级噪声:骨架模板的固定 checklist 行会虚增热点计数——把该行的特征子串配进 config graph_health.noise_line_markers,命中行不计热点

矛盾确认后的修复边界

  • 修 overview 正文 = 实质变化 → 实时 bump updated(document-norms §2.7)
  • 修完重跑脚本,确认该时差对从报告消失
  • 跨 PRD 的口径矛盾(同一规则两处定义打架)超出本 skill 自动能力,发现后走 Issue / board 任务由 owner 处理

Read the full file on GitHub · 73 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. today Changed 79f1d49cd42e
  2. 1mo ago Changed · -5 lines · +93 tokens per session scan B → A f3b495f2e551
  3. 2mo ago First seen · 78 lines · 111 tokens per session scan B b524ce8c1c8d

Subscribe to this mod's changes

doc-graph-health is a skill published in the GitHub repository ryanzhao1011/workframe (8 stars, last pushed yesterday), licensed MIT. It adds 204 tokens to every session and 1,569 once invoked, about $0.0008 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-08-31.

Related

doc-graph-health compared with skills from other repositories

doc-graph-health next to 6 skills from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
doc-graph-healthryanzhao1011/workframeSkill8yesterdayMITA204Claude Code
knowledge-structuresjtprogru/bear-skillsSkill1yesterdayMITA84Claude Code
html-prototypemayuemarsha-del/pm-skillsSkill45mo agoMITA97Claude Code
feature-acceptancemayuemarsha-del/pm-skillsSkill45mo agoMITA192Claude Code
prdmayuemarsha-del/pm-skillsSkill45mo agoMITA202Claude Code
ui-walkthroughmayuemarsha-del/pm-skillsSkill45mo agoMITA231Claude Code
gbgcielebak/goal-by-goalSkill14mo agoMITA150Claude Code