doctor

doctor is a skill for Claude Code from ewebdzine/canonify. It costs 117 tokens per session (1,870 once invoked), scanned A, original, MIT.

A health check for a repository's canonical pattern documents and their links to source code.

In plain words
What is it for?
Use it to review documentation integrity and identify patterns that need updating. It can also check whether the installed Canonify plugin is behind its GitHub version.
Why use it?
It finds missing files, unregistered documents, and documentation that may no longer match the code.

Skill for Claude Code

Written for Claude Code: Claude Code plugin machinery. Also seen: reads .claude/ paths; mentions Claude Code.

Part of the canonify plugin — 8 skills shipped together

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/ewebdzine/canonify/doctor
Any agent
npx skills add ewebdzine/canonify --skill doctor
Clone the repo
git clone --depth 1 https://github.com/ewebdzine/canonify

Made for: Claude Code.

Or install canonify, the plugin that ships this one along with the rest of its 8 skills.

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 doctor

README.md
[![agentmods](https://agentmods.dev/badge/skills/ewebdzine/canonify/doctor.svg)](https://agentmods.dev/skills/ewebdzine/canonify/doctor)
Your own site
<a href="https://agentmods.dev/skills/ewebdzine/canonify/doctor"><img src="https://agentmods.dev/badge/skills/ewebdzine/canonify/doctor.svg" alt="Measured on agentmods" height="20"></a>
Per session 117 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,870 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.00117 $0.01870
Opus 5 $0.00059 $0.00935
Sonnet 5 $0.00023 $0.00374
Haiku 4.5 $0.00012 $0.00187

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

Security

Grade A, and why

doctor 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 6d 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.

skills/doctor/SKILL.md · 110 lines

How it starts

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

Doctor - keep the canon honest

The health gate. It runs two checks over every canon - plus an optional third check on whether the installed Canonify plugin itself is behind its GitHub source - and reports a worklist; it does not auto-fix. Run it as a full-repo sweep (manually, or on a schedule set by /canonify:kickoff); the incremental version of the staleness check also runs inside /canonify:commit on the diff.

A canon is one canonical-pattern doc; CANONIFY.md indexes them. This gate checks that the canons still point at real code (reference integrity) and still match it (staleness).

How to run

  1. Load the manifest. Read CANONIFY.md and enumerate every canon it lists, plus each category docs/<area>/INDEX.md.

  2. Check 1 - reference integrity (structural). For each canon:

    • Every file:line path it cites still exists in the repo (flag broken paths).
    • It is registered: a one-line block in CANONIFY.md AND a row in its category INDEX.md.
    • No orphans (a canon file with no manifest entry) and no dangling entries (a manifest line pointing at a canon file that no longer exists).
  3. Check 2 - staleness (temporal). Git holds the dates - do not hand-log them. For each canon:

    • baseline = the canon's verified: <git-sha> frontmatter marker (the commit at which it was last confirmed against the code). If absent, fall back to the canon's own last-commit SHA and flag it as unmarked.
    • refs = the source files the canon cites (its file:line references + its References section).
    • For each ref: run git log <baseline>..HEAD -- <ref>. If non-empty, flag - the canon references code that moved since it was verified.
    • Use git, never file mtime (checkout resets mtime). Use the platform git the repo requires (read-only git log); on a Windows working tree, the Windows git, not a WSL git.
  4. Check 3 - plugin freshness (optional, best-effort - about the tooling, not the canons). Also surface when the installed Canonify plugin is behind its GitHub source, so a scheduled sweep catches an out-of-date toolchain too. Skip cleanly when it does not apply:

    • Installed version: read Claude Code's plugin state (~/.claude/plugins/installed_plugins.json) for this plugin's entry (canonify@<marketplace>) and note its recorded version (and gitCommitSha). If there is no install record - the plugin is loaded locally for development (e.g. you are running inside its own source repo) - SKIP; a local checkout is its own latest.
    • Source version (resolve it the way Claude Code does): a plugin's effective version is the version in its .claude-plugin/plugin.json, else the marketplace entry's version, else the commit SHA. Resolve the marketplace's git URL (from ~/.claude/plugins/known_marketplaces.json or the plugin's marketplace.json source - do not hardcode a repo), then read the source's current effective version: fetch .claude-plugin/plugin.json version from the default branch (raw file fetch, or git ls-remote <url> HEAD for the tip SHA when no version is published). If offline or unresolvable, SKIP and say so.
    • Compare effective versions, not raw commits: flag only when the source's effective version differs from the installed one - Canonify plugin behind source: installed v<installed>, latest v<latest> - run /plugin update canonify@<marketplace>, then /reload-plugins. Comparing versions (not raw HEAD) means an unreleased commit - a doc tweak with no version bump - does NOT false-flag.
    • Caveat to state: /plugin update only pulls when the published version moves (or, for a SHA-tracked plugin with no version field, on any new commit). If a maintainer ships changes without bumping the published version, neither this check nor /plugin update will see them - that is maintainer discipline, not a consumer problem. Never run the update yourself - report only.

Read the full file on GitHub · 110 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. 6d ago First seen · 110 lines · 117 tokens per session scan A 576b3bc42168

Subscribe to this mod's changes

doctor is a skill published in the GitHub repository ewebdzine/canonify (23 stars, last pushed 2mo ago), licensed MIT. It adds 117 tokens to every session and 1,870 once invoked, about $0.0006 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-08-30.

Related

Other skills, from other repositories

systematic-debugging

Use when encountering any bug, test failure, or unexpected behavior, before proposing fixes.

obra/superpowers · 21 tokens

local-ai-agents

Build local-first AI agents that run entirely on a developer workstation with Microsoft Foundry Local and Qwen function-calling models. Covers Small Language Models (SLMs), the OpenAI-compatible local endpoint, sandboxed local tools, local RAG with Chroma, local MCP servers, hybrid cloud/local routing, and the…

microsoft/ai-agents-for-beginners · 200 tokens

next-cache-components-adoption

Turn on Cache Components in a Next.js app and resolve the blocking routes it surfaces. Use when the user wants to enable, adopt, or migrate to Cache Components, flip the cacheComponents flag, work through a flood of blocking-prerender / instant validation errors, run the cache-components-instant-false codemod, or…

vercel/next.js · 95 tokens

next-partial-prefetching-adoption

Turn on Partial Prefetching in a Next.js app and work through the insights it surfaces. Use when the user wants to enable or adopt Partial Prefetching, flip the partialPrefetching flag, opt routes in with export const prefetch = 'partial', audit Link prefetch={true} behavior, preserve existing prefetched UI with…

vercel/next.js · 103 tokens

chronicle

Analyze Copilot session history for standup reports, usage tips, session search, and session reindexing. Use when the user asks for a standup, daily summary, usage tips, workflow recommendations, wants to search or find past sessions by keyword/file/PR, wants to reindex their session store, or asks about deleting…

microsoft/vscode · 72 tokens

imagegen

Generate or edit raster images when the task benefits from AI-created bitmap visuals such as photos, illustrations, textures, sprites, mockups, or transparent-background cutouts. Use when Codex should create a brand-new image, transform an existing image, or derive visual variants from references, and the output…

openai/codex · 113 tokens