spec ยท diff

git:20260827.09528f5 to git:20260906.3d137c0

20 added, 38 removed. Audit A to A.

---
name: spec
- description: Select the minimum planning mode for a codebase change. Emit OpenSpec only for graph mode. Use for $spec, architecture requests, or proposal.md/design.md/tasks.md. Never implement code.
+ description: Plan a requested codebase change or architecture decision. Use when planning is requested; do not implement code.
---
# Spec
- Act as the architect. Select the minimum process and produce only its required artifact. Never implement code.
-
- ## Workflow
-
- 1. Read repository instructions, relevant history, touched code, ADRs, and prior decisions.
- 2. Run adaptive intake with the request, one direct acceptance check, and only observed task signals. Intake inspects the repository before returning questions.
- 3. Ask only returned material questions. Never invoke `$grill-me` unless the user explicitly asks for that stress test.
- 4. Follow the returned `ProcessDecision v1` mode:
-
- - `direct`: return the objective, scope, check, and stop condition. Write no durable planning file.
- - `verified_single`: return the decision capsule and one-writer hypothesis/check loop. Write no OpenSpec graph.
- - `light_spec`: write `decisions/<slug>.md`. Include revision, invariants, decisions, check, and escalation or reduction triggers. OpenSpec is optional.
- - `graph`: write `openspec/changes/<slug>/proposal.md`, `design.md`, `tasks.md`, and persist the returned transition as `process-decision.json`.
+ Define the outcome, scope, constraints and sufficient acceptance evidence. Read
+ only instructions, code and prior decisions that can change this plan. Resolve
+ questions from available evidence before asking the user.
- 5. Give every graph task these fields:
+ Choose the least durable artifact that the task needs:
- ```md
- - [ ] API-01 Implement the endpoint
- Depends: [DOMAIN-01]
- Paths: [src/api/, tests/test_api.py]
- Mode: write
- Isolation: auto
- Context: Keep the endpoint within the validated domain boundary.
- Acceptance: The endpoint returns the validated result.
- Check: python3 -m unittest tests.test_api
- ```
+ - `direct`: objective, scope and check in the response; no file.
+ - `verified_single`: a bounded hypothesis/check loop for one writer.
+ - `light_spec`: an amendable `decisions/<slug>.md` for a material architectural
+ decision. Reuse an existing decision record when it fits.
+ - `graph`: independent deliverables requiring durable coordination. Read
+ [graph-planning.md](references/graph-planning.md) only for this mode.
- `Depends` may be empty. `Paths` uses normalized repository-relative files or directory prefixes, never globs. `Mode` is `read` or `write`. `Isolation` is `auto` or `worktree`. Use one direct executable for `Check:` and move shell composition into a reviewed script. Do not add test or Markdown paths merely to satisfy a template; name them only when acceptance needs a focused regression, a contract check, or a requested documentation change. Workers follow the `minimal-by-default-v1` artifact budget.
- 6. Load `frontend-visual-validation` for rendered graph work. Add one reasoned `Visual-Scope:` and one `Visual:` entry per supported platform and state.
- 7. In graph mode, run `python3 skills/agent-graph/scripts/agent_graph.py validate --change <slug> --json`. Use `py` on Windows. Validation must pass before handoff and never starts workers. Bootstrap separately verifies that the saved decision revision, packets, checks, permission, budget, integration owner, and cleanup plan still match the graph.
- 8. Run `$spec-council --phase verdict <slug>` only when `--council` is present. Record accepted and rejected findings.
- 9. Before handoff, inspect standing-rule changes directly. Run `rule-curator` only when the approved scope is a whole-corpus rule audit; do not invoke it for an individual rule edit.
- 10. Tell the user to use the `$impl` skill with the decision or approved graph slug.
+ Planning does not require running the intake CLI for a bounded edit. Do not
+ select graph because more models or workers happen to be available.
- Checks and external evidence decide acceptance. Council advice does not.
+ For substantial work, map each required outcome to observable evidence. Separate
+ optional ideas and exclusions. Define completion as meeting the current request,
+ not merely finishing implementation or obtaining a successful process exit.
+ Name any acceptance that cannot currently be observed.
- Mode selection uses repository facts and task signals. It never depends on a
- provider, model, Canvas, or available worker count. Graph execution hints may
- describe role, risk, tools, context budgets, and a bounded `ContextRef`. Spec
- validates them without dispatching workers. Research collection uses `Mode:
- read`; the main researcher owns source adjudication. A checkbox or process exit
- is never an evidence grade.
+ Do not invoke `grill-me`, a council or a whole-corpus audit unless requested.
+ When the plan is ready, provide the appropriate `$impl` invocation. Do not demand
+ another approval when the user already authorized implementation of this scope.