@ericrisco/rsc 3.7.5 → 4.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (62) hide show
  1. package/README.md +16 -9
  2. package/manifest.json +48 -40
  3. package/package.json +1 -1
  4. package/scripts/lib/domains.js +1 -1
  5. package/scripts/lib/onboarding-apply.js +1 -1
  6. package/scripts/lib/onboarding.js +7 -7
  7. package/scripts/lib/retired-skills.js +4 -0
  8. package/scripts/lib/review-findings.js +3 -0
  9. package/scripts/lib/review-ledger.js +187 -0
  10. package/scripts/lib/risk.js +68 -0
  11. package/scripts/lib/spec-gate.js +10 -1
  12. package/scripts/rsc.js +104 -6
  13. package/scripts/spec-gate.js +13 -3
  14. package/skills/analyze/SKILL.md +3 -3
  15. package/skills/asdd/SKILL.md +183 -0
  16. package/skills/{sdd → asdd}/evals/README.md +10 -10
  17. package/skills/{sdd → asdd}/evals/cases.yaml +5 -5
  18. package/skills/{sdd → asdd}/references/model-routing.md +2 -2
  19. package/skills/building-agents/SKILL.md +1 -1
  20. package/skills/clarify/SKILL.md +59 -55
  21. package/skills/clarify/evals/cases.yaml +6 -7
  22. package/skills/constitution/SKILL.md +30 -16
  23. package/skills/constitution/evals/README.md +1 -1
  24. package/skills/constitution/evals/cases.yaml +1 -1
  25. package/skills/debug/SKILL.md +3 -3
  26. package/skills/fastapi/SKILL.md +1 -1
  27. package/skills/flutter/SKILL.md +1 -1
  28. package/skills/ftd/SKILL.md +26 -10
  29. package/skills/ftd/evals/cases.yaml +1 -1
  30. package/skills/ftd/evals/routing.json +4 -4
  31. package/skills/go/SKILL.md +1 -1
  32. package/skills/implement/SKILL.md +147 -132
  33. package/skills/implement/evals/cases.yaml +4 -2
  34. package/skills/implement/references/per-task-review.md +26 -24
  35. package/skills/implement/scripts/task-brief +28 -22
  36. package/skills/nextjs/SKILL.md +1 -1
  37. package/skills/parallel/SKILL.md +1 -1
  38. package/skills/plan/SKILL.md +3 -3
  39. package/skills/plan/evals/cases.yaml +1 -1
  40. package/skills/plan/references/plan-template.md +2 -2
  41. package/skills/postgresdb/SKILL.md +1 -1
  42. package/skills/react/SKILL.md +1 -1
  43. package/skills/review/SKILL.md +80 -41
  44. package/skills/sdd-init/SKILL.md +11 -9
  45. package/skills/ship/SKILL.md +58 -30
  46. package/skills/specify/SKILL.md +42 -41
  47. package/skills/specify/evals/cases.yaml +2 -2
  48. package/skills/specify/references/eliciting-requirements.md +1 -1
  49. package/skills/specify/references/spec-template.md +28 -6
  50. package/skills/suggest/SKILL.md +4 -4
  51. package/skills/tasks/SKILL.md +37 -33
  52. package/skills/tasks/evals/README.md +1 -1
  53. package/skills/tasks/evals/cases.yaml +3 -3
  54. package/skills/verify/SKILL.md +34 -18
  55. package/skills/verify/evals/README.md +2 -2
  56. package/skills/verify/evals/cases.yaml +2 -1
  57. package/skills/verify/references/generic-gate.md +43 -0
  58. package/skills/worktrees/SKILL.md +1 -1
  59. package/targets/clone-bootstrap.mjs +1 -1
  60. package/targets/hook-once.mjs +2 -2
  61. package/targets/sello.mjs +9 -3
  62. package/skills/sdd/SKILL.md +0 -250
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  name: clarify
3
- description: "Use when a spec exists and must be de-risked before planning — hunt its ambiguities, unstated assumptions and edge cases, ask the few build-changing questions, bake the answers back into the spec. The rsc SDD gate between `specify` (writes the spec) and `plan` (designs the build). NOT the cross-artifact consistency check (that is `analyze`)."
3
+ description: "Use when a spec exists and must be de-risked before planning — run the gap checklist over its four ASDD questions and out-of-scope, ask only what changes what gets built (one question at a time, recommendation first), record every other call as an assumption, bake the answers back into the spec. The second half of ASDD stage 2 (Spec), between `specify` (writes the spec) and `plan` (designs the build). NOT the cross-artifact consistency check (that is `analyze`)."
4
4
  tags: [sdd, clarify, questions]
5
5
  recommends: [plan]
6
6
  profiles: [core, full]
@@ -11,19 +11,20 @@ origin: risco
11
11
 
12
12
  A spec written in one sitting always lies a little. It states what the author *thought of*, and stays silent on everything they didn't — the edge cases, the unstated defaults, the words that mean two things. Those silences don't disappear; they get discovered later, mid-implementation, where they cost ten times as much to fix. **Clarify is the gate that drags those silences into the open while they are still cheap.**
13
13
 
14
- This is the fourth phase of the rsc SDD chain (`constitution` → `specify` → **`clarify`** → `plan` → `tasks` → `analyze` → `implement` → `verify` → `review` → `ship`); the method itself lives in `../sdd/SKILL.md`. `specify` turned a fuzzy intent into a spec; clarify interrogates that spec, asks the user the questions that actually change the build, and writes the answers back so the spec becomes safe to plan from. It produces **no new artifact** — it sharpens the existing one in place. The line is **specify creates, clarify de-risks, plan designs**: if you find yourself proposing how to *build* it, you have left clarify.
14
+ This is the second half of ASDD stage 2, **Spec** (`../asdd/SKILL.md`): `specify` drafts → **`clarify`** hunts the gaps → answers go into the spec → the human approves. It produces **no new artifact** — it sharpens the existing spec in place. The line is **specify creates, clarify de-risks, plan designs**: if you find yourself proposing how to *build* it, you have left clarify.
15
15
 
16
- **Model tier: `balanced`** — this phase ranks and asks the few high-leverage questions, it does not design architecture. Resolve and apply it per `../sdd/references/model-routing.md`; routing is off unless `models.enabled: true` in `02-DOCS/wiki/sdd/config.yaml`.
16
+ **Model tier: `balanced`** — this phase finds and asks the few questions that matter, it does not design architecture. Resolve and apply it per `../asdd/references/model-routing.md`; routing is off unless `models.enabled: true` in `02-DOCS/wiki/sdd/config.yaml`.
17
17
 
18
- **Register.** Read `technical_level` from `02-DOCS/wiki/harness/user-profile.md` (the `02-DOCS/wiki/` convention is owned by `../harness/SKILL.md`). Clarify is question-heavy, so the voice matters here more than almost anywhere. Ask only the questions whose answer changes the build; propose safe defaults for everything else and list them as "assumed unless you object". Each question carries one line of *why* and the trade-off behind each option, in the `orient` voice. For a `non-technical` reader, frame each option with an everyday analogy. With no profile: use analogies and ask once "technical or with analogies?".
18
+ **Register.** Read `technical_level` from `02-DOCS/wiki/harness/user-profile.md` (the `02-DOCS/wiki/` convention is owned by `../harness/SKILL.md`). Clarify is question-heavy, so the voice matters here more than almost anywhere. Each question carries one line of *why* and the trade-off behind each option, in the `orient` voice. For a `non-technical` reader, frame each option with an everyday analogy. With no profile: use analogies and ask once "technical or with analogies?".
19
19
 
20
20
  ## Read first — the inputs
21
21
 
22
- Clarify never works blind. Before asking a single question, load three things:
22
+ Clarify never works blind. Before asking a single question, load:
23
23
 
24
24
  1. **The spec.** Read the target spec under `02-DOCS/wiki/sdd/specs/<slug>.md` end to end. If the path wasn't given, find the most recently touched spec or ask which one. Its *Points to clarify* is a **typed** handoff, not a question list — read the types before you plan a single question (below).
25
25
  2. **The constitution.** Read `02-DOCS/wiki/sdd/constitution.md` if it exists. Its principles (stack canon, quality bars, conventions) resolve a surprising number of "ambiguities" without bothering the user — if the constitution already fixes the auth method or the data region, that's answered, not open.
26
- 3. **The harness profile.** `02-DOCS/wiki/harness/user-profile.md`, for the register above.
26
+ 3. **What was already decided.** The project's brain if it has one; otherwise `02-DOCS/wiki/sdd/decisions.md` and the sibling specs. *What it must respect* is checked against these, not against memory.
27
+ 4. **The harness profile.** `02-DOCS/wiki/harness/user-profile.md`, for the register above.
27
28
 
28
29
  Citing what you read ("checked the constitution — auth is already fixed to OAuth, so that's not an open question") shows your work and prevents re-litigating settled decisions.
29
30
 
@@ -36,7 +37,7 @@ deliberately deferred:
36
37
  | Type in the spec | What it means | Your action |
37
38
  | --- | --- | --- |
38
39
  | **pregunta abierta** | Formulable, unanswered | Ask it — this is your queue |
39
- | **suposición tomada** | `specify` decided it; the basis is written | **Validate**, don't re-ask: state the assumption and its basis back, and ask only whether it still holds |
40
+ | **suposición tomada** | `specify` (or you) decided it; the basis is written | **Validate**, don't re-ask: state the assumption and its basis back, and ask only whether it still holds |
40
41
  | **decisión diferida** | Sharp, out of this cycle on purpose | Leave it. Do not reopen scope the author closed |
41
42
  | **área no formulable** | Known to be coming, not yet phrasable | Note it. If your pass sharpens it into a real question, it graduates — say that it did |
42
43
 
@@ -51,94 +52,97 @@ the way through.
51
52
  Sharpness, not difficulty, is what separates a question from an unformulable area: *can you state it
52
53
  precisely now?* Not *can you answer it?*
53
54
 
54
- ## The ambiguity taxonomy — where specs hide their gaps
55
+ ## The gap checklist — where specs hide their gaps
55
56
 
56
- Scan the spec against these categories. Most real gaps fall into one of them; walking the list is how you find the ones the author didn't think to write down.
57
+ Walk the spec's four ASDD questions and its out-of-scope against this **gap checklist**, one row at a time. Most real gaps sit in one of these cells; walking every row is how you find the ones the author didn't think to write down.
57
58
 
58
- | Category | What to hunt | Tell-tale phrasing in the spec |
59
- | --- | --- | --- |
60
- | **Underspecified behavior** | A described feature with a missing branch — what happens in the *other* case | "the user logs in" (and if it fails? locked out? wrong password vs no account?) |
61
- | **Unstated assumptions** | Defaults the author assumed everyone shares | no mention of auth, tenancy, currency, timezone, locale |
62
- | **Edge & boundary cases** | Empty, zero, max, duplicate, concurrent, first-run, offline | lists with no empty-state, counts with no upper bound |
63
- | **Ambiguous terms** | A word doing two jobs | "user" (end-user or admin?), "delete" (soft or hard?), "fast" (how fast?) |
64
- | **Missing acceptance criteria** | A goal with no observable done-condition | "should be performant", "easy to use", "handle errors gracefully" |
65
- | **Scope edges** | What's explicitly OUT vs left dangling | features hinted at but never bounded — "for now", "eventually" |
66
- | **Data & state** | Lifecycle, ownership, retention, migration of existing data | new entity with no story for what happens to old records |
67
- | **Failure & recovery** | What happens when a dependency is down, a write half-completes, input is hostile | happy-path-only flows |
68
- | **Non-functional** | Performance, scale, security, accessibility, i18n targets | vague "non-functional requirements" or none at all |
69
- | **Actors & permissions** | Who can do each thing | a verb with no subject — "can be edited" (by whom?) |
70
-
71
- You are not filling every cell for every spec. You are scanning all ten so the gaps that *do* exist surface instead of hiding.
59
+ | Spec section | Hunt for |
60
+ | --- | --- |
61
+ | **What the user can do** | Who can and who can't (a verb with no subject — "can be edited", by whom?); what happens if the starting conditions fail; ambiguous terms ("user": end-user or admin?) |
62
+ | **What result they get** | Is there an approved reference (screenshot, sketch, expected response) — or only the agent's own judgement? Empty, error and loading states; boundaries (zero, max, duplicate, concurrent, first run) |
63
+ | **What it must respect** | Does it contradict a recorded decision or spec? What current behaviour must not break? Data already there (lifecycle, ownership, migration); security, accessibility, performance floors |
64
+ | **How it proves it** | Any criterion that cannot be checked ("fast", "easy", "handles errors gracefully"); what evidence remains after the check runs |
65
+ | **Out of scope** | Anything the agent might add "just in case" — a feature nobody asked for; hints left dangling ("for now", "eventually") |
66
+
67
+ On an older spec without the four sections, walk the same rows against *Behaviour* and *Acceptance criteria*.
72
68
 
73
69
  ## The pass — five steps
74
70
 
75
71
  Run in order. The discipline is: find many candidate gaps, keep only the ones that change the build, ask those well, write the answers back.
76
72
 
77
- 1. **Inventory.** Walk the spec against the taxonomy above. Produce a raw list of every candidate ambiguity, edge case, and unstated assumption. Over-collect here; you'll prune next. Note for each which category it is and where in the spec it lives.
73
+ 1. **Inventory.** Walk the spec against the gap checklist. Produce a raw list of every candidate gap. Over-collect here; you'll prune next. Note for each its row and where in the spec it lives.
78
74
 
79
- 2. **Resolve what you already can.** For each candidate, check the constitution and the spec's own later sections before asking the user. Many "gaps" are answered elsewhere. Mark each candidate **resolved-internally** (cite the source), **inferable** (a safe default you'll propose, not silently assume), or **must-ask** (only the user can decide).
75
+ 2. **Resolve what you already can.** Check each candidate against the constitution, the decisions and the spec's own later sections before asking. Many "gaps" are answered elsewhere — cite the source.
80
76
 
81
- 3. **Rank by leverage.** Sort the must-ask list by impact: how much does the build change depending on the answer? A question whose two answers lead to two different architectures ranks above a cosmetic one. Cut low-leverage questions — clarify is not an interrogation, it's the *few* questions that matter.
77
+ 3. **Filter.** Ask only if the answer **changes what gets built**: two answers that lead to the same build are not a question. Everything that fails the filter, pick the most reasonable option yourself and record it in the spec's *Points to clarify* as a **suposición tomada**, with its basis — so the human sees every assumption in one block at approval instead of discovering them in the code. A silent default is an unrecorded decision; a recorded one is a cheap thing to veto.
82
78
 
83
- 4. **Ask — one focused batch.** How you ask determines whether you get a usable answer:
84
- - **Make it a decision, not an essay prompt.** "Should deletes be soft (recoverable, hidden) or hard (gone immediately)? I'd recommend soft because the spec mentions an audit trail — confirm?" beats "How should deletion work?".
85
- - **Carry your own recommendation** when there's a defensible default, matched to the constitution. The user confirms or overrides — far less effort than authoring from scratch.
86
- - **Quote the spec.** Anchor each question to the exact line or section it came from, so the user sees *why* it's open.
87
- - **One batch, ranked, then stop.** Don't drip questions one at a time over many turns; don't dump thirty at once. Then wait: never ask and answer in the same breath, and never assume the user's intent on a must-ask item.
79
+ 4. **Ask — one question at a time, recommendation first.** Most important first. Each question is a decision, not an essay prompt, and leads with the answer you recommend so a "yes" suffices: "I'd make deletes soft (recoverable, hidden), because the spec mentions an audit trail — OK?" beats "How should deletion work?". Quote the spec line it came from. Wait for the answer, fold it in, then decide whether the next question still passes the filter — an answer often settles the next one. Never ask and answer in the same breath.
88
80
 
89
81
  5. **Bake the answers back into the spec.** This is the deliverable — an un-baked answer is a lost answer. For each resolved item, edit the spec in place:
90
- - Tighten the relevant section with the decided behavior.
82
+ - Tighten the relevant section with the decided behaviour.
91
83
  - Add or sharpen acceptance criteria so the decision is now observable.
92
84
  - Append a `## Clarifications` log to the spec: dated entries of `Q → decision → why`, so the *reasoning* survives, not just the result.
93
- - Move anything explicitly dropped into an `## Out of scope` section so it's bounded, not dangling.
85
+ - Move anything explicitly dropped into *Non-goals / out of scope* so it's bounded, not dangling.
86
+
87
+ Then re-read the spec once more: did resolving one gap open a new one? If so, one more short loop. Otherwise, hand it to the human for approval.
88
+
89
+ ## In autopilot — nobody to ask
90
+
91
+ Under an up-front autopilot yes there is no one to answer, so step 4 changes: **every question that
92
+ would have been asked is recorded instead** as a **suposición tomada** in the spec (your recommended
93
+ answer, its basis, the spec line it came from) and mirrored as a `review-after` entry in the
94
+ **decision queue** (`## Decision queue` in `02-DOCS/wiki/sdd/progress/<slug>.md`; create it if
95
+ absent). The run continues; the human reviews these afterwards and nothing waits on them. Only a gap
96
+ that would make the build **unsafe**, or whose answer would **contradict a recorded decision**, is a
97
+ `blocking` entry — and only `blocking` stops the branch from merging itself. Never ask and wait in
98
+ autopilot; never stay silent about what you assumed.
99
+
100
+ ## Late gaps — found during implementation
94
101
 
95
- Then re-read the spec once more: did resolving one gap open a new one? If so, one more short loop. Otherwise, the gate is passed.
102
+ A gap nobody saw until `implement` is running does not stop the run. It goes to the **decision queue** of `implement`'s per-task loop (`../implement/SKILL.md`): the task that needs the answer is parked, independent tasks continue, and when the human answers, the answer is written back into this spec (and its `## Clarifications` log) so the spec stays the contract.
96
103
 
97
104
  ## Worked micro-example
98
105
 
99
106
  Spec line: *"Users can upload a profile photo."*
100
107
 
101
- Clarify's inventory against the taxonomy:
108
+ Inventory against the gap checklist:
102
109
 
103
110
  ```text
104
- - Ambiguous term : "photo" — which formats? (PNG/JPG/HEIC/SVG?)
105
- - Boundary : max file size? max dimensions? what if it's 50 MB?
106
- - Edge case : no photo uploaded — is there a default/placeholder?
107
- - Failure : upload fails mid-transfer — retry, or lose it?
108
- - Data lifecycle : replacing a photo — is the old file deleted or orphaned?
109
- - Actors : can an admin change another user's photo?
110
- - Non-functional : is the image resized/compressed server-side? stored where?
111
- - Security : is the file type validated, or can someone upload an .svg with script?
111
+ - Can do : can an admin change another user's photo? what if the user is signed out?
112
+ - Result : which formats? max size? no photo yet — placeholder? upload fails midway — retry?
113
+ - Respect : replacing a photo — old file deleted or orphaned? decisions log fixes storage
114
+ - Proves it : "accepts photos" cannot be checked — which file proves rejection of a 50 MB one?
115
+ - Out of scope: cropping and filters — an agent could add them "just in case"
112
116
  ```
113
117
 
114
- Resolved-internally (cite): constitution fixes storage to the project's object store → "stored where" is answered. Must-ask, ranked: formats + max size (changes validation and UX), security validation (changes the upload path), old-file deletion (changes data model). Cosmetic placeholder choice → propose a default, don't burn a question on it.
118
+ Resolved (cited): the decisions log fixes storage. Changes what gets built, asked one at a time: formats + max size, then old-file deletion. Fails the filter: placeholder image → **suposición tomada** (generic avatar). Cropping → *Out of scope*.
115
119
 
116
- After baking back, the spec line becomes a bounded, testable behavior with acceptance criteria ("rejects files >5 MB with a clear message", "accepts PNG/JPG/HEIC only", "replacing a photo deletes the prior file") and a `## Clarifications` entry recording why.
120
+ After baking back, the spec line becomes a bounded, testable behaviour ("rejects files >5 MB with a clear message", "accepts PNG/JPG/HEIC only", "replacing a photo deletes the prior file") with a `## Clarifications` entry recording why.
117
121
 
118
122
  ## Anti-patterns
119
123
 
120
124
  | Anti-pattern | Why it breaks the gate / do instead |
121
125
  | --- | --- |
122
- | Skipping clarify because the spec "reads clear enough" | Clear to the author ≠ unambiguous. Run the taxonomy; the gaps you can't see are exactly the expensive ones. |
123
- | Assuming the sensible default and moving on | An assumption is an unrecorded decision. Either it's resolvable from the constitution (cite it) or it's a must-ask. Silent defaults resurface as bugs — and "the user is busy" is not an exception; a wrong guess costs more than a one-tap question. |
126
+ | Skipping clarify because the spec "reads clear enough" | Clear to the author ≠ unambiguous. Walk the checklist; the gaps you can't see are exactly the expensive ones. |
127
+ | Assuming a default and not writing it down | An unrecorded default resurfaces as a bug. Record it as **suposición tomada** with its basis, so the human vetoes it at approval. |
124
128
  | Sketching how you'd build it while you're in there | That's `plan`. Clarify decides *what*, not *how*. Proposing architecture means you left the gate. |
125
- | Asking everything you can think of, to be safe | Thirty questions is noise that buries the three that matter. Rank by leverage, ask the few, default the rest — and batch them once instead of dripping one per turn. |
129
+ | Asking everything you can think of, to be safe | Thirty questions bury the three that matter. Only what changes what gets built is asked; the rest is assumed and listed. |
126
130
  | Answering the questions in your head and leaving the spec as-is | The deliverable is the *edited spec* plus the Clarifications log, not a clean conscience. |
127
131
  | Leaving edge cases "to the implementer" | Edge cases are *spec* problems. Resolving them now is the whole point of the gate. |
128
132
 
129
133
  ## Exit gate
130
134
 
131
- The gate is passed when the spec, constitution and profile were all read (settled questions cited, not re-asked); **every typed point in the handoff has its declared outcome** (asked / validated / left deferred / graduated), with nothing silently dropped; all ten taxonomy categories were considered; only the build-changing gaps were put to the user, as one ranked batch of decisions with recommendations; every answer is baked into the spec body with observable acceptance criteria, logged under `## Clarifications` and bounded under `## Out of scope`; and the final re-read opened no new gap.
135
+ The gate is passed when the spec, constitution, prior decisions and profile were all read (settled questions cited, not re-asked); **every typed point in the handoff has its declared outcome** (asked / validated / left deferred / graduated), with nothing silently dropped; every gap checklist row was walked; only questions that change what gets built were asked, one at a time with a recommendation (in autopilot: recorded as assumptions with their `review-after` / `blocking` queue entries); every other call is a **suposición tomada** in the spec; every answer is baked into the spec body with observable acceptance criteria, logged under `## Clarifications` and bounded under out of scope; and the final re-read opened no new gap.
132
136
 
133
137
  ## Result envelope
134
138
 
135
139
  End with the parseable block every SDD phase shares, so the dispatcher can chain without
136
- interpreting prose (contract: `../sdd/SKILL.md`):
140
+ interpreting prose (contract: `../asdd/SKILL.md`):
137
141
 
138
142
  ```json result-envelope
139
143
  {
140
144
  "status": "complete|blocked|failed",
141
- "executive_summary": "Open points resolved; the spec is de-risked and ready to plan against.",
145
+ "executive_summary": "Open points resolved; the spec is de-risked and ready for approval and plan.",
142
146
  "artifact": "02-DOCS/wiki/sdd/specs/<slug>.md",
143
147
  "next_recommended": "plan",
144
148
  "risk": "low|medium|high",
@@ -146,16 +150,16 @@ interpreting prose (contract: `../sdd/SKILL.md`):
146
150
  "used": ["clarify"],
147
151
  "missing": [],
148
152
  "fallback": [],
149
- "compact_rules": ["Ask only what changes the spec.", "An unanswered question is recorded, never invented."]
153
+ "compact_rules": ["Ask only what changes what gets built.", "Every other call is a recorded suposición tomada."]
150
154
  },
151
- "evidence": ["answers folded back into the spec", "remaining open points listed with their owner"]
155
+ "evidence": ["answers folded back into the spec", "assumptions listed as suposición tomada", "remaining open points listed with their owner"]
152
156
  }
153
157
  ```
154
158
 
155
159
  ## Next in the chain
156
160
 
157
- Hand off to **`plan`** — turn the now-sharp spec into a technical implementation plan (architecture, interfaces, data flow, testing strategy, risks), deferring stack specifics to the relevant stack skill. The chain continues: clarify → **plan** → tasks → analyze → implement → verify → review → ship. `debug` is callable any time if what you are "clarifying" turns out to be a runtime fault, not a spec gap.
161
+ Stage 2 closes when the human approves the spec (or the up-front autopilot yes covers it). Then hand off to **`plan`**, ASDD stage 3 (`plan` + `tasks` + `analyze`) — turn the now-sharp spec into a technical plan, deferring stack specifics to the relevant stack skill. `debug` is callable any time if what you are "clarifying" turns out to be a runtime fault, not a spec gap.
158
162
 
159
163
  ## Orientación (siempre)
160
164
 
161
- Habla con la voz de `orient`: frases cortas, una idea por frase, y cada respuesta se entiende sola. Registro técnico o con analogías según `technical_level` en `02-DOCS/wiki/harness/user-profile.md`. Cierra cada turno con el **bloque-brújula** (📍 dónde estás · ➡️ siguiente, terminando en pregunta; ✅ y 🧭 cuando hay algo hecho o decidido). **Nunca termines en seco.** Protocolo completo: skill `orient` → `skills/orient/references/orientation-contract.md`. (Defiere a `suggest` el "¿instalo la skill que falta?".)
165
+ Habla con la voz de `orient`: frases cortas, una idea por frase, y cada respuesta se entiende sola. Registro técnico o con analogías según `technical_level` en `02-DOCS/wiki/harness/user-profile.md`. Cierra cada turno con el **bloque-brújula** (📍 dónde estás · ➡️ siguiente, terminando en pregunta; ✅ y 🧭 cuando hay algo hecho o decidido). **Nunca termines en seco.** Protocolo completo: skill `orient` → `skills/orient/references/orientation-contract.md`. (Defiere a `suggest` el "¿instalo la skill que falta?".)
@@ -54,18 +54,17 @@ should_not_trigger:
54
54
  why: "Establishing project-wide principles is the constitution phase; clarify reads the constitution but does not author it."
55
55
 
56
56
  # Capability scenario with a rubric to grade WITH vs WITHOUT the skill loaded.
57
- # A skill-guided pass walks the taxonomy, resolves what the constitution already
58
- # fixes, ranks by leverage, asks as decisions, and bakes answers back with a
57
+ # A skill-guided pass walks the gap checklist, resolves what the constitution already
58
+ # fixes, asks only what changes the build, records the rest as assumptions, and bakes answers back with a
59
59
  # Clarifications log. An ungrounded pass typically free-associates a few
60
60
  # questions and never edits the spec or records the reasoning.
61
61
  capability:
62
62
  - scenario: "We have a spec at 02-DOCS/wiki/sdd/specs/profile.md whose only line about photos is 'Users can upload a profile photo.' De-risk it before we plan."
63
63
  must_include:
64
64
  - "Reads the spec, the constitution (02-DOCS/wiki/sdd/constitution.md), and the harness profile first — citing anything the constitution already fixes (e.g. storage) as resolved rather than re-asking it."
65
- - "Scans against the ambiguity taxonomy and surfaces concrete gaps: accepted formats, max file size / dimensions, empty/no-photo state, upload-failure recovery, old-file deletion on replace, who-can-edit (actor/permission), and security validation of the file type."
66
- - "Ranks the gaps by leverage — asks only the build-changing ones (formats+size, security validation, old-file deletion) and proposes safe defaults for the cosmetic ones instead of burning a question on each."
67
- - "Frames questions as decisions with a recommendation (e.g. 'soft vs hard delete — recommend X because…'), one ranked batch, anchored to the spec line, rather than open-ended essay prompts or one-at-a-time drips."
68
- - "Asks only the build-changing questions and lists the rest as assumed-defaults (assumed unless you object), with no verbosity level; phrases them in the register from technical_level in user-profile.md."
69
- - "Bakes the resolved answers BACK into the spec: tightens the photo section into bounded behavior, adds observable acceptance criteria, and bounds dropped items under '## Out of scope'."
65
+ - "Walks the gap checklist (what the user can do, what result they get, what it must respect, how it proves it, out of scope) and surfaces concrete gaps: accepted formats, max file size / dimensions, empty/no-photo state, upload-failure recovery, old-file deletion on replace, who-can-edit (actor/permission), security validation of the file type, and anything an agent might add 'just in case'."
66
+ - "Asks only if the answer changes what gets built (formats+size, security validation, old-file deletion); for the rest it picks the most reasonable option and records it in the spec as a 'suposición tomada' with its basis, so the human sees every assumption in one block at approval."
67
+ - "Asks one question at a time, as a decision with the recommended answer first so a 'yes' suffices (e.g. 'I'd make deletes soft because… — OK?'), anchored to the spec line, rather than open-ended essay prompts or a batch of questions; phrases them in the register from technical_level in user-profile.md."
68
+ - "Bakes the resolved answers BACK into the spec: tightens the photo section into bounded behavior, adds observable acceptance criteria, and bounds dropped items under out of scope."
70
69
  - "Appends a dated '## Clarifications' log of Q → decision → why so the reasoning survives, and does a final re-read to confirm no new gap was opened."
71
70
  - "Stays in its lane: decides WHAT, never proposes the technical HOW (no architecture/library choices) and ends by pointing to plan as the next phase."
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  name: constitution
3
- description: "Use when setting or amending a project's non-negotiables — stack canon, quality bars, conventions, security/a11y floors — as numbered, testable rules later phases obey. First rsc-sdd phase; writes 02-DOCS/wiki/sdd/constitution.md. NOT a feature spec (that is `specify`), NOT the technical plan (that is `plan`), NOT the wiki itself (that is `harness`)."
4
- tags: [sdd, constitution, principles]
3
+ description: "Use when setting or amending a project's non-negotiables — stack canon, quality bars, conventions, security/a11y floors — as numbered, testable rules later phases obey, and drafting the REVIEW.md the reviewer reads. ASDD's base stage; writes 02-DOCS/wiki/sdd/constitution.md and REVIEW.md at the project root. NOT a feature spec (that is `specify`), NOT the technical plan (that is `plan`), NOT the wiki itself (that is `harness`)."
4
+ tags: [asdd, constitution, principles, review]
5
5
  recommends: [specify]
6
6
  profiles: [core, full]
7
7
  origin: risco
@@ -9,7 +9,7 @@ origin: risco
9
9
 
10
10
  # constitution — the project's non-negotiable principles
11
11
 
12
- *The first rsc-sdd phase. Run once per project, then amend. It writes down the rules every later phase obeys: stack canon, quality bars, conventions. Everything downstream — specify, plan, analyze, implement, verify, review — reads this file as guardrails.*
12
+ *ASDD's base stage (`../asdd/SKILL.md`). Run once per project, then amend. It writes down the rules every later phase obeys — stack canon, quality bars, conventions — and the `REVIEW.md` the reviewer reads first. Everything downstream — specify, plan, analyze, implement, verify, review — reads these as guardrails.*
13
13
 
14
14
  A constitution is small, durable, and enforceable. It is **not** a wiki of everything you know about the project (that is what `02-DOCS/wiki/` already is, run by the `harness`). It is the short list of principles that, if violated, mean the work is wrong regardless of whether it runs. If a rule here cannot be checked or pointed at later, it does not belong here — move it to the stack wiki and link it.
15
15
 
@@ -17,7 +17,7 @@ Not this phase: *what to build* → `../specify/SKILL.md`; the technical approac
17
17
 
18
18
  ## Model tier — `heavy` (opt-in routing)
19
19
 
20
- This phase's default model tier is **`heavy`** — it sets the project's non-negotiables, the highest-leverage decisions in the repo. Routing is **off** unless `models.enabled: true` in `02-DOCS/wiki/sdd/config.yaml`. When on: resolve this phase's tier (`models.overrides` wins over `models.phases`), map it to a model via `models.tiers`, and apply per `../sdd/references/model-routing.md` — announce the switch in one line when it differs from the session model, and dispatch any `Task`/`parallel` subagents on that model. Routing off or no profile → honor the session model silently. Never fake a switch a tool can't make; skip routing on a one-line change.
20
+ This phase's default model tier is **`heavy`** — it sets the project's non-negotiables, the highest-leverage decisions in the repo. Routing is **off** unless `models.enabled: true` in `02-DOCS/wiki/sdd/config.yaml`. When on: resolve this phase's tier (`models.overrides` wins over `models.phases`), map it to a model via `models.tiers`, and apply per `../asdd/references/model-routing.md` — announce the switch in one line when it differs from the session model, and dispatch any `Task`/`parallel` subagents on that model. Routing off or no profile → honor the session model silently. Never fake a switch a tool can't make; skip routing on a one-line change.
21
21
 
22
22
  ## Honor the register first
23
23
 
@@ -31,7 +31,7 @@ Before asking anything, read `02-DOCS/wiki/harness/user-profile.md` and use its
31
31
 
32
32
  The harness may already hold real conventions under `02-DOCS/wiki/stack/*` (e.g. `nextjs.md`, `fastapi.md`, `postgresdb.md`). The constitution does not copy them — it **ratifies the principle and links the detail**. Run this reconciliation pass first:
33
33
 
34
- 1. **Read the Knowledge map** — the full index lives in `02-DOCS/wiki/index.md` (root `CLAUDE.md` keeps only a short pointer to it). List every `02-DOCS/wiki/stack/*` article that exists.
34
+ 1. **Read the Knowledge map** — `02-DOCS/wiki/index.md`. List every `02-DOCS/wiki/stack/*` article that exists.
35
35
  2. **Read each stack article.** Pull out anything already phrased as a rule (a version pin, a lint config, a test threshold, a naming convention).
36
36
  3. **For each existing rule, decide:** is it a *project-wide non-negotiable* (→ ratify it as a principle, linking the stack article for detail) or a *local mechanic* (→ leave it in the stack wiki, do not lift it into the constitution)?
37
37
  4. **Contradictions are findings, not fixes.** If two stack articles disagree, or a stack article contradicts what the user states now, surface it and let the user resolve — never silently pick a winner.
@@ -72,7 +72,7 @@ For any significant either/or (e.g. "strict types or gradual?", "squash or merge
72
72
 
73
73
  Two principles are inherited from the rsc ecosystem and appear in every constitution unless the user explicitly overrides them:
74
74
 
75
- - **Git authorship is the human's.** Commits and PRs are authored by the human (Eric, or whoever owns the repo). No `Co-Authored-By` an AI, no "generated with" footer. Enforced at the `ship` phase.
75
+ - **Git authorship is the human's.** Commits and PRs are authored by the responsible person — the configured git user. No `Co-Authored-By` an AI, no "generated with" footer. Enforced at the `ship` phase.
76
76
  - **Decisions are logged.** Every significant decision is appended to `02-DOCS/wiki/sdd/decisions.md` (or the harness `decisions.md`) with date, options considered, and the why. The constitution itself is the highest-order decision record.
77
77
 
78
78
  ## Drafting the constitution
@@ -88,6 +88,18 @@ Create `02-DOCS/wiki/sdd/` if it does not exist. Do not overwrite an existing co
88
88
 
89
89
  **A draft is "complete me", not "amend me".** `rsc onboard` writes a skeleton with `status: draft` in the frontmatter: the template's headings, the facts onboarding knew (goal, kind, scope, workflow, detected stack) and no principle. Keep those facts, run the interview, fill the sections, then on ratification drop `status: draft`, set `version: v1.0.0` and log v1.0.0 in the amendment log.
90
90
 
91
+ ## REVIEW.md — what the reviewer reads first
92
+
93
+ With the constitution, draft `REVIEW.md` at the project root (the code repo — the reviewer runs there). It is short, specific to this repo, and ratified with the constitution:
94
+
95
+ - **What failure looks like here** — the defect classes that actually hurt this project (e.g. "a query without the tenant filter", "a migration that is not reversible").
96
+ - **Paths to skip** — generated code, vendored files, fixtures.
97
+ - **Nit cap** — the most nits one review may report (e.g. 3); the rest are dropped.
98
+ - **Always-human paths** — what must never merge without a person (billing, auth, infra). Listing them here only informs; to be *enforced* they go into `.rsc/sello-config.json` `risk.raise`, which `rsc risk` reads — say so to the user.
99
+ - **Summary starts with a count** — "3 findings: 1 blocker, 2 nits", before anything else.
100
+
101
+ `review` adds to it when a finding keeps repeating; amend it like the constitution, never silently.
102
+
91
103
  ## Versioning & amendment protocol
92
104
 
93
105
  The constitution is versioned so `analyze` and `review` can cite "constitution v1.2.0, principle 4".
@@ -95,6 +107,7 @@ The constitution is versioned so `analyze` and `review` can cite "constitution v
95
107
  - **Semantic-ish versioning.** MAJOR when a principle is removed or reversed (breaks existing work); MINOR when a principle is added or materially tightened; PATCH for wording/clarity with no behavior change.
96
108
  - **Amendments are append-only in the log.** Never silently edit a ratified principle — strike it (mark superseded) and add the new one, bump the version, and record date + why in the amendment log.
97
109
  - **Ratification.** A new or amended constitution is shown to the user and ratified explicitly before it takes effect. "Ratify" is an explicit yes on the shown draft; walk each change only if the user asks.
110
+ - **In autopilot** (`execution_mode: automatic`, or an up-front "take it all the way"), there is no one to ask: ratify **provisionally** (`status: provisional` in the frontmatter), log it in `decisions.md`, and add a `review-after` entry to the decision queue (`../asdd/SKILL.md`) so the human confirms it later. It does not block the run or a self-merge.
98
111
  - **Downstream notice.** When a principle changes mid-project, flag that existing specs/plans may now be inconsistent — `analyze` will catch the drift on the next run.
99
112
 
100
113
  ## Anti-patterns
@@ -108,7 +121,7 @@ The constitution is versioned so `analyze` and `review` can cite "constitution v
108
121
  | "I'll rewrite the existing constitution to match what they said today." | Amend, don't overwrite. Strike + add + bump version + log the why. |
109
122
  | "No profile yet, I'll assume they're technical." | Use analogies; ask once "technical or with analogies?" or send them to `init`. |
110
123
  | "I'll add a Co-Authored-By so the commit credits the assist." | No. Git authorship is the human's — it's a fixed principle, enforced at `ship`. |
111
- | "I'll ratify it myself since it's obvious." | The user ratifies. Show the draft, get the explicit yes, then it takes effect. |
124
+ | "I'll ratify it myself since it's obvious." | The user ratifies. Show the draft, get the explicit yes, then it takes effect. Only autopilot ratifies provisionally, as a `review-after` queue entry. |
112
125
 
113
126
  ## Checklist before handing off
114
127
 
@@ -118,23 +131,24 @@ The constitution is versioned so `analyze` and `review` can cite "constitution v
118
131
  - [ ] The Definition-of-Done checklist is present (what `verify` runs against).
119
132
  - [ ] Fixed principles included: human git authorship + decisions logged.
120
133
  - [ ] `02-DOCS/wiki/sdd/constitution.md` written with version + ratified date + amendment log.
121
- - [ ] Root `CLAUDE.md` `## Knowledge map` pointer has the read-first row for the constitution.
122
- - [ ] The constitution was shown to the user and explicitly ratified.
134
+ - [ ] `REVIEW.md` drafted at the project root; always-human paths mirrored into `.rsc/sello-config.json` `risk.raise` (or the user told why they are not).
135
+ - [ ] The constitution is indexed in `02-DOCS/wiki/index.md` (the Knowledge map) under the `sdd/` topic.
136
+ - [ ] The constitution was shown to the user and explicitly ratified — or, in autopilot, ratified provisionally with a `review-after` queue entry.
123
137
 
124
- ## Project grounding (02-DOCS + CLAUDE.md)
138
+ ## Project grounding (02-DOCS)
125
139
 
126
- This skill's `02-DOCS` record is the constitution at `02-DOCS/wiki/sdd/constitution.md`. It is a **read-first** pointer entry, so its row stays in the short `## Knowledge map` pointer in the root `CLAUDE.md` (create `CLAUDE.md` if absent, additive only — never delete existing sections) — unlike other sdd artifacts, which are indexed in `02-DOCS/wiki/index.md` (the full Knowledge map that root `CLAUDE.md` points to). Add this row to the root pointer if it is not already present:
140
+ This skill's `02-DOCS` record is the constitution at `02-DOCS/wiki/sdd/constitution.md`, indexed in `02-DOCS/wiki/index.md` (the Knowledge map) like every other sdd artifact:
127
141
 
128
142
  ```markdown
129
143
  | Project constitution (SDD non-negotiables) | `02-DOCS/wiki/sdd/constitution.md` |
130
144
  ```
131
145
 
132
- Every later rsc-sdd phase reads this file before it works. The harness maintains and improves the article over the life of the project; this skill is the place that ratifies and amends it.
146
+ Never edit the root `CLAUDE.md` from here: it is owned by `harness` and is tier 2 in `rsc risk`. Every later ASDD phase reads the constitution before it works. The harness maintains and improves the article over the life of the project; this skill is the place that ratifies and amends it.
133
147
 
134
148
  ## Result envelope
135
149
 
136
- End with the parseable block every SDD phase shares, so the dispatcher can chain without
137
- interpreting prose (contract: `../sdd/SKILL.md`):
150
+ End with the parseable block every phase shares, so the dispatcher can chain without
151
+ interpreting prose (contract: `../asdd/SKILL.md`):
138
152
 
139
153
  ```json result-envelope
140
154
  {
@@ -149,10 +163,10 @@ interpreting prose (contract: `../sdd/SKILL.md`):
149
163
  "fallback": [],
150
164
  "compact_rules": ["Principles are inherited constraints, not choices to re-make.", "Every rule is testable or it is a preference."]
151
165
  },
152
- "evidence": ["constitution path exists", "rules numbered and testable", "decisions log appended"]
166
+ "evidence": ["constitution path exists", "rules numbered and testable", "REVIEW.md drafted", "decisions log appended"]
153
167
  }
154
168
  ```
155
169
 
156
170
  ## Next in the chain
157
171
 
158
- The constitution is the guardrail; now describe what to build. Hand off to **`../specify/SKILL.md`** — turn a fuzzy intent into a spec (what & why, no implementation), grounded in these principles. The full chain: **constitution → specify → clarify → plan → tasks → analyze → implement → verify → review → ship** (with `debug`, `worktrees`, `parallel` callable on demand). The dispatcher is `../sdd/SKILL.md`.
172
+ The constitution is the guardrail; now describe what to build. Hand off to **`../specify/SKILL.md`** — turn a fuzzy intent into a spec (what & why, no implementation), grounded in these principles. The ASDD stages: **base → spec → plan → per-task loop → closing → learn** (with `debug`, `worktrees`, `parallel` callable on demand). The dispatcher is `../asdd/SKILL.md`.
@@ -64,5 +64,5 @@ even if it reads tidy.
64
64
  - Re-run after any edit to `SKILL.md` or `references/constitution-template.md` —
65
65
  wording changes shift both triggering and rubric coverage.
66
66
  - Several `route_to` targets are rsc-sdd phase siblings (`specify`, `plan`,
67
- `analyze`, `sdd`) that ship alongside this skill; the near-misses here route
67
+ `analyze`, `asdd`) that ship alongside this skill; the near-misses here route
68
68
  only to skills already present in the repo so the eval is runnable today.
@@ -68,5 +68,5 @@ capability:
68
68
  - "Every principle is numbered, imperative, and testable (a number, command, or named artifact), not an aspiration like 'write clean code'."
69
69
  - "Includes the two fixed principles: git authorship is the human's (no Co-Authored-By AI / generated-with footer, enforced at ship) and significant decisions are logged."
70
70
  - "Produces a Definition of Done checklist (the merge bar verify runs against) covering format/lint, types, tests/coverage, conventions, branch+PR+authorship, security, and decisions logged."
71
- - "Writes 02-DOCS/wiki/sdd/constitution.md with a version (v1.0.0), ratified date, and an append-only amendment log; adds the Knowledge-map row to root CLAUDE.md additively (never deleting sections)."
71
+ - "Writes 02-DOCS/wiki/sdd/constitution.md with a version (v1.0.0), ratified date, and an append-only amendment log; indexes it in 02-DOCS/wiki/index.md and never edits the root CLAUDE.md."
72
72
  - "Shows the draft and gets explicit ratification from the user before it takes effect, and ends by pointing to the specify phase as next in the chain."
@@ -26,7 +26,7 @@ delegation table below.
26
26
 
27
27
  ## Model tier — `heavy` (opt-in routing)
28
28
 
29
- This phase's default model tier is **`heavy`** — root-cause diagnosis is deep reasoning. Routing is **off** unless `models.enabled: true` in `02-DOCS/wiki/sdd/config.yaml`. When on: resolve this phase's tier (`models.overrides` wins over `models.phases`), map it to a model via `models.tiers`, and apply per `../sdd/references/model-routing.md` — announce the switch in one line when it differs from the session model, and dispatch any `Task`/`parallel` subagents on that model. Routing off or no profile → honor the session model silently. Never fake a switch a tool can't make; skip routing on a one-line change.
29
+ This phase's default model tier is **`heavy`** — root-cause diagnosis is deep reasoning. Routing is **off** unless `models.enabled: true` in `02-DOCS/wiki/sdd/config.yaml`. When on: resolve this phase's tier (`models.overrides` wins over `models.phases`), map it to a model via `models.tiers`, and apply per `../asdd/references/model-routing.md` — announce the switch in one line when it differs from the session model, and dispatch any `Task`/`parallel` subagents on that model. Routing off or no profile → honor the session model silently. Never fake a switch a tool can't make; skip routing on a one-line change.
30
30
 
31
31
  ## Read the room first (register)
32
32
 
@@ -124,8 +124,8 @@ first — isolate which side actually fails before you open either stack's debug
124
124
 
125
125
  When the cause is non-obvious — a race, an order dependency, an environment-only failure, a
126
126
  regression a reviewer would otherwise have to rediscover — append a short entry to
127
- `02-DOCS/wiki/sdd/decisions.md` (append-only; create it if absent and add a row to the root
128
- `CLAUDE.md` `## Knowledge map` under the `sdd/` topic). One entry:
127
+ `02-DOCS/wiki/sdd/decisions.md` (append-only; create it if absent and index it in
128
+ `02-DOCS/wiki/index.md` under the `sdd/` topic — never the root `CLAUDE.md`). One entry:
129
129
 
130
130
  ```text
131
131
  ## YYYY-MM-DD — bug: <symptom in five words> (feature: <slug>)
@@ -20,7 +20,7 @@ pytest 8 + pytest-asyncio 1.0+ (`asyncio_mode=auto`), ruff 0.7+, mypy 1.13+ stri
20
20
  uv 0.5+, uvicorn 0.32+ / gunicorn 23+ + uvicorn-worker 0.3+, PyJWT 2.10+, argon2-cffi 23+,
21
21
  pip-audit 2.7+, PostgreSQL 16. (All lower bounds; install the latest in each line.)
22
22
 
23
- > **⚠️ SDD new-feature gate — read this first.** If this skill fired on a **new, non-trivial feature or behaviour change** and there is **no approved spec + plan** under `02-DOCS/wiki/sdd/`, STOP — do **not** write feature code yet. Hand off to `../specify/SKILL.md` first: it runs brainstorm → spec → plan → tasks before any code, then routes back here once the plan is approved. Build here directly only for a genuinely one-line / low-risk change. Method: `../sdd/SKILL.md`.
23
+ > **⚠️ SDD new-feature gate — read this first.** If this skill fired on a **new, non-trivial feature or behaviour change** and there is **no approved spec + plan** under `02-DOCS/wiki/sdd/`, STOP — do **not** write feature code yet. Hand off to `../specify/SKILL.md` first: it runs brainstorm → spec → plan → tasks before any code, then routes back here once the plan is approved. Build here directly only for a genuinely one-line / low-risk change. Method: `../asdd/SKILL.md`.
24
24
 
25
25
  Out of scope, and where it goes instead: [`django`](../django/SKILL.md) for Django; Flask / sync WSGI,
26
26
  notebooks and CLI-only scripts (no skill); language-level Python, typing and packaging →
@@ -18,7 +18,7 @@ this skill targets: **Flutter 3.44 / Dart 3.12**, **Riverpod 3.0**, **go_router
18
18
 
19
19
  ## Boundaries
20
20
 
21
- > **⚠️ SDD new-feature gate — read this first.** If this skill fired on a **new, non-trivial feature or behaviour change** and there is **no approved spec + plan** under `02-DOCS/wiki/sdd/`, STOP — do **not** write feature code yet. Hand off to `../specify/SKILL.md` first: it runs brainstorm → spec → plan → tasks before any code, then routes back here once the plan is approved. Build here directly only for a genuinely one-line / low-risk change. Method: `../sdd/SKILL.md`.
21
+ > **⚠️ SDD new-feature gate — read this first.** If this skill fired on a **new, non-trivial feature or behaviour change** and there is **no approved spec + plan** under `02-DOCS/wiki/sdd/`, STOP — do **not** write feature code yet. Hand off to `../specify/SKILL.md` first: it runs brainstorm → spec → plan → tasks before any code, then routes back here once the plan is approved. Build here directly only for a genuinely one-line / low-risk change. Method: `../asdd/SKILL.md`.
22
22
 
23
23
  This skill owns the `pubspec.yaml` subproject and nothing else in the repo. Hand off when the UI is
24
24
  Compose Multiplatform (`compose-multiplatform`), SwiftUI/native iOS (`swift-ios`) or React Native
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  name: ftd
3
- description: "Use for ordinary authorised change — the default lane once the decisor has ruled out a question and not selected the chain. Keeps one feature document per feature in 02-DOCS holding intent, scope, checklist, evidence and next step, checks tasks off only against observed proof, and asks whether to branch before the work writes code. NOT the ten-phase chain (that is `sdd`), NOT the classification itself (that is the decisor in `suggest`), NOT a request for information, which writes nothing."
3
+ description: "Use for ordinary authorised change — the default lane once the decisor has ruled out a question and not selected the chain. Keeps one feature document per feature in 02-DOCS holding intent, scope, checklist, evidence and next step, checks tasks off only against observed proof, asks whether to branch before the work writes code, and runs a minimal risk loop (self-check, `rsc risk`, one reviewer from tier 1). NOT the full method (that is `asdd`), NOT the classification itself (that is the decisor in `suggest`), NOT a request for information, which writes nothing."
4
4
  tags: [ftd, lane, default, feature-document, evidence]
5
5
  recommends: [worktrees, debug, verify]
6
6
  profiles: [minimal, core, full]
@@ -10,11 +10,11 @@ origin: risco
10
10
  # FTD — Fast-Track Development
11
11
 
12
12
  The lane ordinary work takes. Not a lighter methodology: the **same** discipline about evidence with
13
- none of the coordination the ten-phase chain exists to buy. One document instead of five, written
13
+ none of the coordination `asdd` exists to buy. One document instead of five, written
14
14
  because the work might be interrupted, not because somebody has to approve it first.
15
15
 
16
16
  You are here because the decisor in `../suggest/SKILL.md` ruled that this turn authorises a change
17
- and did not select `../sdd/SKILL.md`. If it is still a question, you are in the wrong place: go back
17
+ and did not select `../asdd/SKILL.md`. If it is still a question, you are in the wrong place: go back
18
18
  and answer it.
19
19
 
20
20
  ## Why this lane exists
@@ -24,7 +24,7 @@ riesgo. Silencio para lo trivial, ceremonia solo donde el fallo es caro. Un sist
24
24
  80% inofensivo acaba apagado, y apagado no protege el 20% que importa.»*
25
25
 
26
26
  The harness spent a long time contradicting it — every request that sounded like building went
27
- through ten phases. This lane is that principle finally implemented, not a new idea.
27
+ through the whole chain. This lane is that principle finally implemented, not a new idea.
28
28
 
29
29
  ## The feature document
30
30
 
@@ -60,6 +60,20 @@ the test output, the command's result, the page rendering. A task whose check wa
60
60
  could not run is recorded as such, honestly. The tenth principle applies here exactly as it does in
61
61
  the chain: a result asserted without evidence is treated as not done.
62
62
 
63
+ ## The minimal loop — per change that writes code
64
+
65
+ The lane inherits ASDD's per-task loop, cut to its floor:
66
+
67
+ 1. **Self-check** — run the change's own check and record the output under Evidence.
68
+ 2. **`npx @ericrisco/rsc risk`** — the tier of what changed (same path table as the sello; works
69
+ with it off).
70
+ 3. **Tier ≥ 1 → one fresh-context reviewer** (`../review/SKILL.md`, per-task mode). Tier 0 → none.
71
+ 4. **Mandatory controls** — tests, build, the security scan the project has. What did not run is
72
+ written «not executed», never left blank.
73
+
74
+ **Escalate to `asdd`** when `rsc risk` says **tier 2**, or when the change contradicts a decision
75
+ already recorded in `decisions.md`: the feature document becomes its spec input, as below.
76
+
63
77
  ## Isolation
64
78
 
65
79
  Where the work runs follows the project's decision (asked at install: «main» or «ramas y PR»; rsc
@@ -83,10 +97,10 @@ cleanup is automatic and you do not run anything.
83
97
 
84
98
  ## Growing out of the lane
85
99
 
86
- A feature that turns out to need the chain is **promoted, not restarted**: the feature document
87
- becomes the input to `../specify/SKILL.md`, and no completed work is discarded. Promotion happens for
88
- the same reason the chain is ever entered — durable artifacts would remove a substantial ambiguity —
89
- and never because the work turned out to be big.
100
+ A feature that turns out to need `asdd` is **promoted, not restarted**: the feature document
101
+ becomes the input to `../specify/SKILL.md`, and no completed work is discarded. Promotion happens
102
+ when durable artifacts would remove a substantial ambiguity, or by the escalation above (tier 2, a
103
+ contradicted decision) — never because the work turned out to be big.
90
104
 
91
105
  ## Anti-patterns → STOP
92
106
 
@@ -96,13 +110,15 @@ and never because the work turned out to be big.
96
110
  | Check a task off because you believe it works | Observed proof or it is not done (P10). Record the check you could not run. |
97
111
  | Write the document into the code repository | It belongs in `02-DOCS`. A clone should get code, not notes. |
98
112
  | Open a worktree "to be safe" | That is the chain's ceremony arriving through the back door (P7). |
99
- | Escalate to the chain because the change is large | Size never selects it. Only unresolved ambiguity that artifacts would settle. |
113
+ | Escalate to `asdd` because the change is large | Size never selects it. Only unresolved ambiguity, tier 2, or a contradicted decision. |
114
+ | Skip the reviewer because the change looks safe | `rsc risk` decides, not the feeling. Tier ≥ 1 gets one. |
100
115
  | Produce a spec, plan or task artifact here | Those are the chain's. This lane has one document. |
101
116
 
102
117
  ## See Also
103
118
 
104
119
  - `../suggest/SKILL.md` — the decisor that routed here, and the other two lanes.
105
- - `../sdd/SKILL.md` — the ten-phase chain, for when artifacts genuinely earn their cost.
120
+ - `../asdd/SKILL.md` — the full method, for when artifacts genuinely earn their cost.
121
+ - `../review/SKILL.md` — the reviewer the minimal loop calls at tier ≥ 1.
106
122
  - `../verify/SKILL.md` — the evidence gate, when this lane's checks need the full battery.
107
123
  - `../debug/SKILL.md` — a failure to reproduce before fixing; comes back here afterwards.
108
124
 
@@ -3,7 +3,7 @@ skill: ftd
3
3
  # Cases for FTD — Fast-Track Development, the lane ordinary authorised change takes.
4
4
  # FTD keeps ONE feature document per feature in 02-DOCS (intent, scope, checklist,
5
5
  # evidence, next step), checks tasks off only against observed proof, and branches when
6
- # the work writes code. It is NOT the ten-phase chain (sdd), NOT the classification
6
+ # the work writes code. It is NOT the full method (asdd), NOT the classification
7
7
  # itself (the decisor lives in the always-on suggest body), and NOT a request for
8
8
  # information — those write nothing at all.
9
9
 
@@ -3,7 +3,7 @@
3
3
  "lanes": {
4
4
  "answer": "information only; writes nothing, creates no artifact",
5
5
  "ftd": "authorised change, ordinary; one feature document",
6
- "sdd": "the ten-phase chain, entered by the agent for big or complex work"
6
+ "asdd": "the ASDD chain (review inside every task), entered by the agent for big or complex work"
7
7
  },
8
8
  "cases": [
9
9
  { "request": "¿Por qué el login tarda tanto en producción?", "expect": "answer", "why": "investigation; nothing authorises a change" },
@@ -17,8 +17,8 @@
17
17
  { "request": "Renombra la tabla de usuarios en las 40 llamadas que la usan", "expect": "ftd", "why": "large and mechanical: size alone must never select the chain" },
18
18
  { "request": "Sube la versión de la dependencia y arregla lo que rompa", "expect": "ftd", "why": "authorised change with no unresolved design question" },
19
19
  { "request": "Migra los tres endpoints al nuevo formato de respuesta", "expect": "ftd", "why": "many files, but nothing a spec would settle that the code does not" },
20
- { "request": "Quiero especificar bien el sistema de permisos antes de tocar nada", "expect": "sdd", "why": "explicit request for the chain" },
21
- { "request": "Vamos a hacer una spec de esto", "expect": "sdd", "why": "explicit request, stated in the user's own words" },
22
- { "request": "No tengo claro si los permisos van por rol o por recurso, y afecta al esquema, a la API y a la UI", "expect": "sdd", "why": "enter the chain: several interlocking decisions that durable artifacts would settle; the agent enters it and says why" }
20
+ { "request": "Quiero especificar bien el sistema de permisos antes de tocar nada", "expect": "asdd", "why": "explicit request for the chain" },
21
+ { "request": "Vamos a hacer una spec de esto", "expect": "asdd", "why": "explicit request, stated in the user's own words" },
22
+ { "request": "No tengo claro si los permisos van por rol o por recurso, y afecta al esquema, a la API y a la UI", "expect": "asdd", "why": "enter the chain: several interlocking decisions that durable artifacts would settle; the agent enters it and says why" }
23
23
  ]
24
24
  }