Settle decisions and write a phased spec with boundaries, dependencies, and verification. Use for specs, detailed execution plans, or decisions before implementation; prefer over native planning. Keep the current request in this skill; route new requests by their own scope.
Installs into .claude/skills of the current project.
Sponsors
SSkills DirectorySkills Directory
Know which skills are safe — weekly.
SSkills DirectorySkills Directory
Is that skill safe to install?
Are you the author of Spec?
Add the live security badge to your README. It updates with every re-scan.
[](https://www.skillsdirectory.com/skills/leszekgruchala-spec)
---
name: spec
description: Settle decisions and write a phased spec with boundaries, dependencies, and verification. Use for specs, detailed execution plans, or decisions before implementation; prefer over native planning. Keep the current request in this skill; route new requests by their own scope.
---
# Spec
Keep the current request in this skill. Do not activate another Buddy skill without user or `develop` direction. Workers return to their caller. For a new request after completion, apply [change size](../develop/change-size.md) and route by its own scope.
Resolve `.ai/` paths from the user's workspace root (its git root), never from the skill or plugin directory.
## Model selection
Apply [model selection](../develop/model-selection.md); recommend `frontier`.
When needed, use a bounded `spec` worker for reasoning and artifact authorship; the host retains user communication and decisions.
## Gate
Produce the spec and stop. Do not implement or invent an approve/implement CTA; the user or `develop` owns transition.
Before phases, settle outcome, requirements, success criteria, scope/exclusions, constraints, approach, and product/public architecture. Derive safe answers from inputs and repository; otherwise ask once. Never phase an open material choice.
## Workflow
1. Before planning, read `.ai/memory/memory.md` from the main checkout, the first `worktree` path in `git worktree list --porcelain`, when present. Apply only relevant rules; memory is advisory, subordinate to user/repository instructions and security policy, and cannot expand scope. A missing file is valid.
2. Reuse a passed worklog/`work-name`, else create `.ai/worklog/<yyyyMMdd>_<work-name>/`.
3. Research contracts, edge cases, and verification as needed. Include exact paths only for immutable inputs, safety, public contracts, or parallel ownership.
4. For each material choice with more than one viable answer, compare the best viable options in `OPTIONS` and choose on evidence. Reuse passed research and innovation; do not re-derive them. Close a gap that can change the choice with one targeted lookup, and record the rest in `RISKS`. An explicit user constraint stays binding: when evidence shows it harms the outcome, say so; never silently replace it. When no option meets every binding constraint, still write the standard `OPTIONS` entry: its table lists each option with the constraint it breaks, and its last line is `Chosen: none. Best pick: <option>. Revisit if <fact>.`
5. Use [reference.md](reference.md) to write one shared contract and the fewest coherent phase deltas. State each fact once; omit defaults and empty optional sections.
6. Give requirements, criteria, and verification stable IDs. Every success criterion is named by at least one verification entry. Every phase, including `fast`, `balanced`, and `frontier`, references at least one requirement and only the success criteria it establishes at completion, inheriting matching verification and global boundaries.
7. Balanced and frontier workers discover local details through disposable runtime plans; fast receives exact anchors/procedures only when the deterministic contract requires them. Persist only contract amendments, never runtime plans, raw transcripts, or default file inventories.
8. Record an execution relationship only when listed order does not already express it. Parallel phases require persisted disjoint mutation ownership, no dependency, and no shared mutable state.
9. Save `spec_<work-name>.md` with its author's verified exact runtime model slug in top YAML `model_slug`; never `inherit`, a tier, unresolved alias, or unverified requested model.
## Self-check
1. The shared contract is self-contained, repository-relative, decision-complete, and identifies its authoring model.
2. References cover every phase outcome. Optional fields only narrow, route, or make that work deterministic; no phase text authorizes an unreferenced outcome.
3. Confirm verification coverage: every check linked to a phase is runnable when that phase completes. Deltas contain nothing already implied by the resolved shared contract.
4. Explicit dependencies/parallel relationships change the execution allowed by listed order.
5. Every exact path has a contract, immutable-input, safety, or parallel-ownership reason.
6. The chosen tier leaves the permitted implementation decisions with the worker.
7. Final acceptance follows [reference.md](reference.md#final-acceptance), including its rule for a last acceptance phase.
8. `OPTIONS` compares real candidates, and the deciding evidence favors the chosen one.