workflow pipeline
Write Specs
Transform story.md into a spec pack, strictly adhering to the findings in planning/context-brief.md.
Write Specs Skill
Prerequisites
STOP. Have you run analyze-context?
- Check for
planning/context-brief.md. - If missing: ABORT. Run
analyze-contextfirst. - If present: Read it. You MUST use the "Reference Pattern" listed there as your guide.
Use this skill after the story description and acceptance criteria are available (from a bead via bd show, a story.md file, or the user's prompt) AND after analyze-context has generated planning/context-brief.md.
Inputs
- Story description and acceptance criteria (required) — from a bead (
bd show), astory.mdfile, or the user's prompt planning/context-brief.md(required; the research)
Outputs (created/updated in the same story folder)
spec.mddesign.mdedge-cases.mdplanning/requirements.md- Ensure directories from config
ensureDirsexist (defaults includeplanning/,planning/visuals/,implementation/,verification/).
Workflow
- Load Context: Read the
planning/context-brief.md. - Verify Patterns: Open the "Reference Pattern" file found in the brief. Your
design.mdmust mimic its structure. - Generate Artifacts: Use the templates in this folder.
Templates (authoritative)
- Template filenames are defined in config.json under
templates(defaults map to spec/design/edge-cases/requirements templates in this folder). - The "Reference Pattern" from
context-brief.mdgoverns the architectural approach indesign.md.
Configuration
- Defaults live in config.json. Adjust template filenames (
templates), required inputs, andensureDirswhen porting to other repositories.
Behavior Rules
- Citation Required: Every design decision in
design.mdmust cite the Reference Pattern or an Instruction. - No Novelty: Do not invent new architectural patterns. Copy the reference.
- Visuals: Do not generate images. Create
planning/visuals/directory only. - Keep scope tight to the story acceptance criteria and existing repo architecture.
- Ask concise, numbered clarifying questions before writing if required details are missing.
- Treat this as greenfield with zero active users: avoid backward-compat shims, migration scaffolding, feature flags, or defensive toggles unless explicitly requested.
- Do not create
tasks.mdin this skill.