speckit.md-doctor.apply

speckit.md-doctor.apply is a command for Claude Code from arrrrny/zuraffa. It costs 28 tokens per session (843 once invoked), scanned A, original, MIT.

A command that applies documentation fixes found by an earlier scan. It can create missing document stubs, mark checked documents, or delete files only when explicitly requested.

In plain words
What is it for?
Use it after a documentation scan or drift check to create missing files and mark verified documentation.
Why use it?
It removes repetitive manual edits while keeping the default actions safe and non-destructive.

Command for Claude Code

Written for Claude Code: $ARGUMENTS substitution.

Needs its repository: it runs a file that does not travel with it, so clone the repository first. The line is bash .specify/extensions/md-doctor/scripts/bash/md-doctor.sh apply [--delete] [--action <a>] [--all].

Good fit Use it after a documentation scan or drift check to create missing files and mark verified documentation.

Compare 6 commands from other repositories ↓
Install

Getting it into your agent

It runs from inside its repository, so the clone comes first — what it calls does not travel with the file alone.

Clone the repo
git clone --depth 1 https://github.com/arrrrny/zuraffa
agentmods
npx agentmods add commands/arrrrny/zuraffa/speckit.md-doctor.apply

Made for: Claude Code.

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 speckit.md-doctor.apply

README.md
[![agentmods](https://agentmods.dev/badge/commands/arrrrny/zuraffa/speckit.md-doctor.apply/github.svg)](https://agentmods.dev/commands/arrrrny/zuraffa/speckit.md-doctor.apply)
Your own site
<a href="https://agentmods.dev/commands/arrrrny/zuraffa/speckit.md-doctor.apply"><img src="https://agentmods.dev/badge/commands/arrrrny/zuraffa/speckit.md-doctor.apply/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 speckit.md-doctor.apply

Your own site · 80×15
<a href="https://agentmods.dev/commands/arrrrny/zuraffa/speckit.md-doctor.apply"><img src="https://agentmods.dev/badge/commands/arrrrny/zuraffa/speckit.md-doctor.apply.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 28 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 843 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.00028 $0.00843
Opus 5.5 $0.00011 $0.00337
Sonnet 5.5 $0.00006 $0.00169
Haiku 4.5 $0.00003 $0.00084

Measured 1mo ago against content hash 7e9f99acbd43, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

speckit.md-doctor.apply 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 1mo 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.

.specify/extensions/md-doctor/commands/speckit.md-doctor.apply.md · 86 lines

How it starts

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

MD Doctor — Apply

Mechanically act on the suggestions MD Doctor recorded during scan/drift. It is deliberately conservative: by default it only does safe things (create stubs for missing docs, stamp verified docs). Deletion is destructive and requires an explicit flag.

User Input

$ARGUMENTS

Recognized modifiers:

  • --action create — only create the missing-doc stubs.
  • --action stamp — only append a "verified" footer to keep/update docs.
  • --action delete — show the delete plan (destructive; see --delete).
  • --delete — actually delete files the engine marked delete. Destructive.
  • --all — do everything (create + stamp + delete); implies --delete.

With no flag, the safe default runs: create stubs + stamp verified docs. No deletes.

Preconditions

A scan (or drift) must have run so .specify/md-doctor/state/facts.json exists with action fields. If missing, stop and tell the user to run /speckit.md-doctor.scan first.

Workflow

Phase 1: Run the engine

bash .specify/extensions/md-doctor/scripts/bash/md-doctor.sh apply [--delete] [--action <a>] [--all]

(Dev fallback: bash <extension-root>/md-doctor/scripts/bash/md-doctor.sh apply ....)

What it does, by flag:

  • default — for each create fact, write a stub at proposed_path; for each keep/update fact, append a footer > Verified by md-doctor on <date> — truthfulness <n>/100. (idempotent: skips files stamped today).
  • --action create — stubs only.
  • --action stamp — footers only.
  • --action delete (no --delete) — prints the files it would delete; changes nothing.
  • --delete — also removes files marked delete.
  • --all — create + stamp + delete.

Phase 2: Review the engine output

The engine prints created=N stamped=N deleted=N and the affected paths. Read them.

If --delete was used, confirm the deleted paths are exactly the false/obsolete docs from the last report and nothing else. If something looks wrong, you may restore from git (git checkout -- <path> / git restore) since deletes are working-tree only until committed.

Read the full file on GitHub · 86 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. 1mo ago First seen · 86 lines · 28 tokens per session scan A 7e9f99acbd43

Subscribe to this mod's changes

speckit.md-doctor.apply is a command published in the GitHub repository arrrrny/zuraffa (5 stars, last pushed yesterday), licensed MIT. It adds 28 tokens to every session and 843 once invoked, about $0.0001 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-09-03.