ワンクリックで
health
Validate knowledge base quality, check freshness, analyze coverage gaps, and generate health reports
Codex または Claude でインストール この Prompt をコピーして Codex、Claude、または他のアシスタントに貼り付けると、Skill ページを確認してインストールできます。
メニュー
Validate knowledge base quality, check freshness, analyze coverage gaps, and generate health reports
Codex または Claude でインストール この Prompt をコピーして Codex、Claude、または他のアシスタントに貼り付けると、Skill ページを確認してインストールできます。
SOC 職業分類に基づく
Add, update, or manage content in a knowledge base — triggered by command or natural-language curation intent like "save this to my knowledge base"
Submit bug reports, feature ideas, or general feedback for the Dewey plugin to the project's GitHub issue tracker
| name | health |
| description | Validate knowledge base quality, check freshness, analyze coverage gaps, and generate health reports |
check_knowledge_base.py. 18 per-file validators (frontmatter, sections, size bounds, readability, sources, freshness, and more) plus 6 cross-file validators (manifest sync, curation plan sync, proposal integrity, link graph, duplicate detection, naming conventions). Auto-fix available for common issues. No LLM required. CI-friendly.last_validated dates. Assesses source drift, depth label accuracy, "Why This Matters" quality, and "In Practice" concreteness.<quick_start>
Run Tier 1 checks (default): /dewey:health or /dewey:health check
Run full audit (Tier 1 + 2): /dewey:health audit
Surface human decisions: /dewey:health review
Check coverage gaps: /dewey:health coverage
Check staleness: /dewey:health freshness
</quick_start>
Before routing, check if a curation plan exists:
/dewey:curate first. Do not proceed..dewey/curation-plan.md -- Pause and build a plan:
.dewey/curation-plan.md with the confirmed topics (use the format from the curate-plan workflow)Default behavior: Run Tier 1 deterministic checks only (fast, CI-friendly).
Available actions:
check -- Tier 1 deterministic validation (default)audit -- Tier 1 + Tier 2 LLM-assisted assessmentreview -- Tier 1 + Tier 2 + surface Tier 3 decision queuecoverage -- Gap analysis against AGENTS.md responsibilitiesfreshness -- Staleness report sorted by urgencyParse the action from $ARGUMENTS. If no arguments provided, run check (Tier 1 only).
check or no arguments provided -> Route to workflows/health-check.mdaudit -> Route to workflows/health-audit.mdreview -> Route to workflows/health-review.mdcoverage -> Route to workflows/health-coverage.mdfreshness -> Route to workflows/health-freshness.md
<workflows_index>
All workflows in workflows/:
| Workflow | Purpose |
|---|---|
| health-check.md | Tier 1 deterministic validation -- fast, CI-friendly |
| health-audit.md | Tier 1 + Tier 2 LLM-assisted quality assessment |
| health-review.md | Full assessment + Tier 3 human decision queue |
| health-coverage.md | Gap analysis comparing AGENTS.md responsibilities to knowledge base contents |
| health-freshness.md | Staleness report grouped by urgency |
| </workflows_index> |
<references_index>
All references in references/:
| Reference | Content |
|---|---|
| validation-rules.md | Complete list of Tier 1 checks with fields, thresholds, and severities |
| quality-dimensions.md | Three quality dimensions: what each means, how measured, which checks apply |
| design-principles.md | Twelve design principles grounded in agent context research and cognitive science |
| </references_index> |
<scripts_integration>
Located in scripts/:
check_knowledge_base.py -- Health check runner
Usage:
python3 ${CLAUDE_PLUGIN_ROOT}/skills/health/scripts/check_knowledge_base.py --knowledge-base-root <knowledge_base_root>
validators.py -- Tier 1 deterministic validators
Structural checks:
check_frontmatter -- Required fields: sources, last_validated, relevance, depthcheck_section_ordering -- "In Practice" before "Key Guidance" in working-depth filescheck_section_completeness -- Required sections present for each depth levelcheck_heading_hierarchy -- No skipped heading levels (e.g., h1 to h3)check_cross_references -- Internal markdown links resolve to existing filescheck_size_bounds -- Line counts within range for each depth levelcheck_readability -- Flesch-Kincaid grade level within bounds per depth (overview 8-14, working 10-16)Coverage and sync checks:
check_coverage -- Every area has overview.md; every topic has .ref.md companioncheck_index_sync -- index.md references all topic files on disk; warns on stale indexcheck_inventory_regression -- Detects topics that disappeared between runsSource and link checks:
check_source_urls -- Source URLs are well-formed (http/https)check_freshness -- last_validated within threshold (default 90 days)check_go_deeper_links -- Working files link to their reference companionscheck_ref_see_also -- Reference files include a "See Also" section linking backcheck_placeholder_comments -- Flags TODO/FIXME/placeholder markers left in contentcheck_source_diversity -- Warns when all sources come from a single domaincheck_citation_grounding -- Working files have inline citations near key claimscheck_source_accessibility -- Source URLs return HTTP 200 (opt-in via --check-links)Every validator returns a list of issue dicts: {"file": str, "message": str, "severity": "fail" | "warn"}
Tier 2 pre-screening only:
python3 ${CLAUDE_PLUGIN_ROOT}/skills/health/scripts/check_knowledge_base.py --knowledge-base-root <knowledge_base_root> --tier2
Combined Tier 1 + Tier 2:
python3 ${CLAUDE_PLUGIN_ROOT}/skills/health/scripts/check_knowledge_base.py --knowledge-base-root <knowledge_base_root> --both
Returns {"tier1": {...}, "tier2": {...}} with both Tier 1 issues/summary and Tier 2 queue/summary.
tier2_triggers.py -- Tier 2 deterministic pre-screener
Content quality triggers:
trigger_source_drift -- Flags files with stale or missing last_validatedtrigger_depth_accuracy -- Flags files where word count or prose ratio mismatches depthtrigger_source_primacy -- Flags working files with low inline citation densitytrigger_why_quality -- Flags working files with missing or thin "Why This Matters"trigger_concrete_examples -- Flags working files with missing or abstract "In Practice"trigger_citation_quality -- Flags files with weak or missing inline citationsSource quality triggers:
trigger_source_authority -- Flags files whose sources lack authoritative domainstrigger_provenance_completeness -- Flags files with incomplete provenance metadatatrigger_recommendation_coverage -- Flags files lacking actionable recommendationsEvery trigger returns: {"file": str, "trigger": str, "reason": str, "context": dict}
history.py -- Health score history tracking
record_snapshot(knowledge_base_root, tier1_summary, tier2_summary) -- Appends timestamped snapshot to .dewey/history/health-log.jsonlread_history(knowledge_base_root, limit=10) -- Returns the last N snapshots in chronological ordercheck_knowledge_base.py after each runutilization.py -- Topic reference tracking
record_reference(knowledge_base_root, file_path, context="user") -- Appends to .dewey/utilization/log.jsonlread_utilization(knowledge_base_root) -- Returns per-file stats: {file: {count, first_referenced, last_referenced}}log_access.py -- Hook-driven utilization logging
log_if_knowledge_file(knowledge_base_root, file_path) -- Logs access if file is a .md under the knowledge directoryhook_log_access.py (Claude Code PostToolUse hook entry point)hook_log_access.py -- CLI entry point for Claude Code PostToolUse hook
log_if_knowledge_file to conditionally log the accesscross_validators.py -- Cross-file consistency validators
check_manifest_sync -- AGENTS.md topic list matches files on diskcheck_curation_plan_sync -- Curation plan checkmarks match actual file presencecheck_proposal_integrity -- Proposals have required frontmatter and valid target areascheck_link_graph -- Internal links between knowledge files all resolvecheck_duplicate_content -- Detects duplicate paragraphs and high Jaccard similarity across files (skips companion pairs)check_naming_conventions -- Validates directory and file names against slug conventionsEvery cross-validator returns: {"file": str, "message": str, "severity": "fail" | "warn"}
auto_fix.py -- Automated fixes for common issues
fix_missing_sections -- Adds missing required sections with placeholder contentfix_missing_cross_links -- Adds "Go Deeper" / "See Also" links between companion filesfix_curation_plan_checkmarks -- Updates curation plan checkmarks to match files on disk
</scripts_integration><success_criteria> Health assessment is successful when: