SEP-2640 Skill Authoring (cross-cutting/sep2640/skill-authoring)
Use when the task is authoring a new conformant SKILL.md: building the frontmatter template, checking the kebab-case name rule, writing the router description, and running the pre-publish conformance check.
Domain quick reference
- SEP-2640 delivery is skills over MCP in the agentskills.io content form; the spec is emerging, so authoring targets the stable conformance surface: required frontmatter fields, name shape, description discipline, license, compliance, standards, gated, and metadata.
- The required top-level fields are name, description, license, compliance, standards, gated, and metadata. A candidate missing any of them fails the pre-publish check.
- The name must be kebab-case (lowercase letters, digits, single hyphens) and equal the leaf folder name; the description must carry an action clause, a 'Use when' clause, and a 'Trigger' keyword with at least two trigger keywords, within the 50-150 word and 1024 char budgets.
- The license must equal Apache-2.0; compliance must be one of none, ITAR-GATED, EAR-GATED, STANDARDS-REF; standards must be non-empty; gated must be a boolean; metadata must carry version and author.
- The pre-publish conformance check is deterministic, offline, and stdlib-only: same candidate, same findings.
Workflow
- Draft the frontmatter from the template: name (kebab-case, matching the folder), description (action + use-when + trigger), license, compliance, standards, gated, metadata.
- Run the conformance check on the candidate SKILL.md text.
- Read the findings list: every problem is a missing or invalid required field (name shape, folder match, description budgets and clauses, license, compliance, standards, gated, metadata).
- Fix the candidate until the findings list is empty.
- Publish only a candidate with zero findings.
Pitfalls
- A name that is not kebab-case (uppercase, spaces, double hyphens).
- A name that does not match the leaf folder (the router resolves skills by folder path).
- A description without a 'Use when' clause or fewer than two trigger keywords (the description is the router; a weak one routes poorly).
- Claiming conformance while a required field is missing; the check is boolean per field and one failure fails the candidate.
Behavior contract (gate 3)
The authoring logic is exercised by the gate 3 contract test: scripts/test_authoring.py against scripts/authoring_logic.py (stdlib unittest, offline). Run:
python3 scripts/test_authoring.py