Skill v1.0.0
currentAutomated scan100/100name: mission-spec description: Use when a mission starts from a natural-language request, a draft canonical spec, or a Markdown document without mission frontmatter and the agent must discuss requirements, write an approvable spec, record explicit approval, and hand the approved document to execution. metadata: version: "1.0.0"
Mission Spec
Own requirement discussion and the draft -> approved spec transition. Do not implement the work and do not write a separate implementation plan.
Declare: 使用 mission-spec skill,讨论并生成可批准的 canonical spec。
Workflow
- Read the request and the relevant repository context.
- If
lite-arch-recallis installed, run it before an architecture-bearing decision against applicabledocs/adr/records. Otherwise record that architecture recall was unavailable and continue. - Ask one question at a time only while a material goal, constraint, scope boundary, or acceptance condition remains unresolved.
- Present alternatives only when real alternatives exist. Recommend one and state concrete tradeoffs.
- Once the design is determined, write a draft to
docs/specs/<YYYY-MM-DD>-<topic>.md. - Run
python scripts/validate_spec.py <spec> --allow-uncommitted-approvedand fix every error. - Show the final draft and require explicit user approval of that exact content. Do not implement before approval.
- After approval, set
status: approvedand add the current RFC 3339approved_attimestamp with timezone. Do not change the approved body in the same edit. - If
lite-archis installed, run itsrecorddecision gate and print the required three-line block before creating, amending, superseding, or skipping an ADR. Withoutlite-arch, state that the optional ADR gate was skipped. - Commit the approved spec and any draft ADR created by the optional gate before execution. Then run
validate_spec.pywithout the allow flag to prove the approved file is committed and unchanged fromHEAD. - Route the committed spec to
mission-approved-doc, unless the user explicitly chooses ordinary direct implementation.
Canonical format
Use exactly one scalar frontmatter block:
---mission: specstatus: draftcreated: YYYY-MM-DD---
After approval:
---mission: specstatus: approvedcreated: YYYY-MM-DDapproved_at: YYYY-MM-DDTHH:MM:SS+08:00---
Required sections:
GoalScopeDesignAcceptance Criteria
Add Non-goals, Alternatives, Compatibility, Security, Rollout, or Rollback only when they carry real information.
The validator accepts only unique key: scalar entries for the four declared fields. It rejects nested values, arrays, aliases, tags, duplicate keys, unknown states, invalid dates, missing fields, and additional frontmatter blocks.
Approval integrity
- Approval applies to the exact draft the user saw.
- Any later content change invalidates approval. Change the status back to
draft, removeapproved_at, and ask for approval again. - A later session may trust an approved spec only when
validate_spec.pyconfirms that it exists inHEADand the working copy is unchanged. - Never infer approval from positive discussion, implementation permission for another artifact, or a previous version of the document.
Writing boundary
Run humanizer-zh on prose before presenting or committing the spec. Do not let it rewrite frontmatter, code identifiers, paths, commands, dates, or machine-checked fields.
mission-spec produces and approves the spec. mission-approved-doc maps an approved spec into execution artifacts. mission-csv-execute owns execution state. Keep those responsibilities separate.