Agent Skills Doctor
Validate an existing Agent Skill against the agentskills.io specification
and best practices, report every finding with its check ID, and — when the
user asks — fix the findings and re-verify. Read-only by default: never
modify a skill unless the user explicitly asks for fixes.
Workflow
Step 1: Gather input
You need one input: the path to a skill directory (or a SKILL.md
file). If the user has not provided one, ask. Do not guess which skill to
validate when several exist.
Step 2: Detect
Run every check that is available, collecting findings with their check IDs:
- skillscheck — primary linter. If
uvx is installed, run
uvx skillscheck <skills-parent-dir> (e.g. uvx skillscheck skills for
skills/<name>/); otherwise run a skillscheck binary on PATH. Use
--format json when you need to parse output programmatically. Exit code
0 = no errors, 1 = errors. If neither is available, note the skip.
- skills-ref — second automated check. If installed, run
skills-ref validate ./<name> to verify frontmatter validity and naming
conventions. Skip silently when not installed.
- Manual checklist — re-read the target
SKILL.md and check what the
linters do not cover:
For exact field constraints, naming rules, and token budgets, read
references/specification.md.
Step 3: Report
Present findings grouped by severity — errors, then warnings, then info.
For each finding give:
- The check ID (e.g.
[2a.description.user-centric]) when one exists
- The file and line
- What the rule is
- A concrete suggested fix
End the report by telling the user you can fix the findings on request.
Do not fix anything yet.
Step 4: Fix
Only when the user explicitly asks ("fix it", "fix all", "fix the
description finding"). Read references/fix-rules.md
for per-finding fix guidance, then apply fixes in two tiers:
- Safe tier — auto-apply without per-item confirmation. Mechanical
fixes: lowercase a
name, collapse consecutive hyphens, rename a
directory to match name, convert user-centric description phrasing to
agent-directed form, trim an over-length description. Prefer
uvx skillscheck --fix for what it covers, then hand-fix the rest.
- Judgment tier — confirm before changing. Rewrites and removals:
rewriting a description, deleting orphaned files, moving content out of
an over-long body into
references/, changing metadata. Present the
proposed change and get a "yes" per finding or a blanket "fix all".
Never touch files outside the target skill directory.
Step 5: Re-verify
After fixing, re-run skillscheck (and skills-ref when available) on the
skill. Confirm every fixed finding is gone and no new findings appeared.
Report the final lint result and the list of applied changes to the user.
Reference
- references/specification.md — full
agentskills.io field-by-field specification, script design rules, and
eval guidance. Load when you need exact constraints.
- references/fix-rules.md — per-finding fix
guidance keyed by skillscheck check ID. Load when the user asks to fix
findings.
1---2name: agentskills-doctor3description: Validate an existing Agent Skill against the agentskills.io specification and best practices, and fix the findings on request. Use when validating, linting, checking, auditing, reviewing, or fixing a SKILL.md or skill directory — e.g. "validate this skill", "is my skill spec-compliant", "lint my SKILL.md", "fix the findings in my skill". Do NOT use for creating new skills (that is the agentskills-creator skill).4---56# Agent Skills Doctor78Validate an existing Agent Skill against the agentskills.io specification9and best practices, report every finding with its check ID, and — when the10user asks — fix the findings and re-verify. Read-only by default: never11modify a skill unless the user explicitly asks for fixes.1213## Workflow1415- [ ] Step 1: Gather input — the path to the skill to validate.16- [ ] Step 2: Detect — run skillscheck and skills-ref when available, then17 the manual checklist.18- [ ] Step 3: Report — present findings grouped by severity with suggested19 fixes.20- [ ] Step 4: Fix — only when the user asks; auto-apply safe fixes, confirm21 judgment fixes.22- [ ] Step 5: Re-verify — re-run the linters and confirm findings are gone.2324### Step 1: Gather input2526You need one input: the **path to a skill directory** (or a `SKILL.md`27file). If the user has not provided one, ask. Do not guess which skill to28validate when several exist.2930### Step 2: Detect3132Run every check that is available, collecting findings with their check IDs:33341. **skillscheck** — primary linter. If `uvx` is installed, run35 `uvx skillscheck <skills-parent-dir>` (e.g. `uvx skillscheck skills` for36 `skills/<name>/`); otherwise run a `skillscheck` binary on `PATH`. Use37 `--format json` when you need to parse output programmatically. Exit code38 0 = no errors, 1 = errors. If neither is available, note the skip.392. **skills-ref** — second automated check. If installed, run40 `skills-ref validate ./<name>` to verify frontmatter validity and naming41 conventions. Skip silently when not installed.423. **Manual checklist** — re-read the target `SKILL.md` and check what the43 linters do not cover:44 - [ ] `name` matches the directory name and follows all naming rules45 - [ ] `description` is present, ≤ 1024 characters, states what + when,46 and uses agent-directed phrasing ("Use when <verb>ing...", not47 "when the user asks/wants/mentions")48 - [ ] Frontmatter is valid YAML with only spec-defined fields49 - [ ] Body is under 500 lines; detail lives in `references/` with50 explicit load triggers51 - [ ] Referenced file paths are relative and exist5253For exact field constraints, naming rules, and token budgets, read54[references/specification.md](references/specification.md).5556### Step 3: Report5758Present findings grouped by severity — errors, then warnings, then info.59For each finding give:6061- The check ID (e.g. `[2a.description.user-centric]`) when one exists62- The file and line63- What the rule is64- A concrete suggested fix6566End the report by telling the user you can fix the findings on request.67Do not fix anything yet.6869### Step 4: Fix7071Only when the user explicitly asks ("fix it", "fix all", "fix the72description finding"). Read [references/fix-rules.md](references/fix-rules.md)73for per-finding fix guidance, then apply fixes in two tiers:7475- **Safe tier — auto-apply without per-item confirmation.** Mechanical76 fixes: lowercase a `name`, collapse consecutive hyphens, rename a77 directory to match `name`, convert user-centric description phrasing to78 agent-directed form, trim an over-length `description`. Prefer79 `uvx skillscheck --fix` for what it covers, then hand-fix the rest.80- **Judgment tier — confirm before changing.** Rewrites and removals:81 rewriting a description, deleting orphaned files, moving content out of82 an over-long body into `references/`, changing metadata. Present the83 proposed change and get a "yes" per finding or a blanket "fix all".8485Never touch files outside the target skill directory.8687### Step 5: Re-verify8889After fixing, re-run skillscheck (and skills-ref when available) on the90skill. Confirm every fixed finding is gone and no new findings appeared.91Report the final lint result and the list of applied changes to the user.9293## Reference9495- [references/specification.md](references/specification.md) — full96 agentskills.io field-by-field specification, script design rules, and97 eval guidance. Load when you need exact constraints.98- [references/fix-rules.md](references/fix-rules.md) — per-finding fix99 guidance keyed by skillscheck check ID. Load when the user asks to fix100 findings.