lint-skill
Lint a single SKILL.md against the six principles Christian Dussol distilled from Anthropic's official Skills guide. This skill itself was linted with /lint-skill — see references/dussol-principles.md for the full doctrine.
When to invoke
- The user typed
/lint-skill <path>or/lint-skillwith a recently-discussed skill in context. - The user asks to "audit", "review", "score", or "check" a skill file.
- The user just generated a new skill with
skill-creatoror by hand and wants a sanity check before shipping.
When NOT to invoke
- General Markdown linting (use markdownlint).
- Code review of source files inside a skill's
scripts/folder (use/simplifyor/security-review). - Linting MCP server manifests — those follow a different spec, not Dussol's six.
Workflow
Step 1 — Locate the target SKILL.md
Read the path the user provided. If they did not provide one, look for the nearest SKILL.md walking up from the current working directory; if multiple exist, ask which one.
Step 2 — Run the deterministic script
Execute the bundled Python script. It checks the things that do not need an LLM:
Loading code…
The script outputs a per-principle report ([PASS] / [WARN] / [FAIL]) plus exit code 0 on full pass, 1 on any FAIL, 2 on any WARN-but-no-FAIL.
Step 3 — Add the judgment-required principles
Three principles need an LLM eye on top of the script:
- P1 fine-grain check — read the
description:and confirm the WHAT, WHEN, and NEGATIVE TRIGGER are each meaningful sentences, not regex bait that the user inserted just to pass the lint. A description like "Use when… Do NOT use for…" with no real content fails. - P4 example quality — confirm at least one example actually has the three sub-parts (input → expected reasoning → output structure). A bullet list of "examples" with no chain of reasoning does not count.
- P6 trigger harness diversity — if
tests/triggers.yml(or equivalent) is present, scan it for at least 10 should-trigger and 10 should-not-trigger entries. If short, surface as WARN.
Step 4 — Print the structured report
Print the script's output verbatim, then your three judgment-based additions. End with one concrete fix suggestion per FAIL/WARN, ranked by impact. Imperative voice: "Add a NEGATIVE TRIGGER sentence to the description", not "It would be good if there were a negative trigger."
Step 5 — Optional auto-fix
If the user says "fix it" or "apply suggestions", apply the smallest safe edits. NEVER rewrite the whole SKILL.md. Touch only the failing field. After editing, re-run the script and confirm green.
Example reasoning chain
Input
/lint-skill ~/projects/myapp/.claude/skills/deploy-helper/SKILL.md
Expected reasoning
- Read the file at
~/projects/myapp/.claude/skills/deploy-helper/SKILL.md. - Run
python public/skills/mcpflix-skills-linter/scripts/lint-skill.py ~/projects/myapp/.claude/skills/deploy-helper/SKILL.md. - Script reports:
[PASS] P1 description,[WARN] P2 body is 6,200 tokens,[FAIL] P5 README.md found alongside SKILL.md,[PASS] P6 triggers.yml present with 12 + 11. - Manually inspect
description:— confirm it has a real WHAT/WHEN/NEGATIVE, not just the marker words. - Open the
examplessection — verify at least one chain is concrete.
Output
deploy-helper • lint report
[PASS] P1 Description (Dussol) — WHAT/WHEN/NEGATIVE all present and substantive.
[WARN] P2 Progressive disclosure — body is 6,200 tokens (>5K). Extract the "Cloud provider matrix" section to references/cloud-providers.md.
[FAIL] P5 No README collision — README.md found at ~/projects/myapp/.claude/skills/deploy-helper/README.md. Rename to references/overview.md or delete.
[PASS] P3 Deterministic scripts — scripts/validate-env.sh referenced.
[PASS] P4 Concrete example — "blue-green rollout" chain has input/reasoning/output.
[PASS] P6 Trigger harness — tests/triggers.yml has 12 positive + 11 negative.
Suggested fixes (most impactful first):
1. Delete or rename README.md (blocks Claude from loading the right instructions).
2. Extract the "Cloud provider matrix" section to references/cloud-providers.md.
Principles checked
The six principles are documented in detail in references/dussol-principles.md with before/after examples in references/examples-good-vs-bad.md. At a glance:
- Description field — WHAT + WHEN + NEGATIVE TRIGGERS.
- Progressive disclosure — body ≤ 5K tokens, deep dives in
references/. - Deterministic scripts — non-LLM checks live in
scripts/. - Concrete examples — at least one input → reasoning → output chain.
- No README.md in the skill folder.
- Triggering harness — 10+ should-trigger and 10+ should-not-trigger prompts under
tests/.
Self-lint
This skill was checked with itself. The bundled triggering harness lives in tests/triggers.yml (relative to this folder). To verify:
Loading code…
Expected: all six principles [PASS], exit code 0.