ultra-builder-pro-cli 0.26.1 → 3.0.2

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 (75) hide show
  1. package/.ultra-template/contexts/TEMPLATE.md +64 -29
  2. package/.ultra-template/north-star.md +36 -30
  3. package/.ultra-template/project-brief.md +28 -0
  4. package/.ultra-template/specs/product.md +4 -0
  5. package/.ultra-template/specs/research-distillate.md +8 -0
  6. package/.ultra-template/tasks.json +1 -0
  7. package/.ultra-template/test-report.json +18 -1
  8. package/CHANGELOG.md +227 -1
  9. package/README.md +161 -59
  10. package/adapters/_shared/host-profile.cjs +68 -12
  11. package/adapters/_shared/plugin-core.cjs +4 -5
  12. package/adapters/_shared/runtime-assets.cjs +11 -2
  13. package/adapters/zcode.js +375 -0
  14. package/bin/delegate-worker.cjs +20 -0
  15. package/bin/delegate.cjs +94 -25
  16. package/bin/install.js +11 -6
  17. package/docs/ARCHITECTURE.md +109 -25
  18. package/docs/ARTIFACT-AUTHORITY.md +204 -30
  19. package/docs/DECISIONS.md +141 -10
  20. package/docs/PHILOSOPHY.md +61 -8
  21. package/docs/PLUGIN-ISOLATION-CONTRACT.md +6 -0
  22. package/docs/RUNTIME-COMPAT-MATRIX.md +106 -13
  23. package/docs/SKILL-AUTHORING.md +14 -9
  24. package/docs/WORKFLOW-LIFECYCLE.md +211 -53
  25. package/docs/evals/adversarial-review-2026-08-14.md +84 -0
  26. package/docs/evals/zcode-automation-2026-08-14.md +103 -0
  27. package/hooks/README.md +31 -3
  28. package/hooks/_common.py +1699 -33
  29. package/hooks/adapters/zcode.py +227 -0
  30. package/hooks/compact_context.py +176 -17
  31. package/hooks/mid_workflow_recall.py +27 -5
  32. package/hooks/post_edit_guard.py +133 -23
  33. package/hooks/session_context.py +722 -11
  34. package/package.json +6 -3
  35. package/skills/ultra-change/SKILL.md +84 -64
  36. package/skills/ultra-change/references/change-contract.md +130 -32
  37. package/skills/ultra-change/references/execution-grant.md +109 -0
  38. package/skills/ultra-change/references/primary-transfer.md +273 -0
  39. package/skills/ultra-change/scripts/validate_primary_transfer.cjs +1928 -0
  40. package/skills/ultra-delegate/SKILL.md +38 -5
  41. package/skills/ultra-delegate/references/delegation-contract.md +21 -1
  42. package/skills/ultra-deliver/SKILL.md +123 -44
  43. package/skills/ultra-deliver/references/baseline-reconciliation.md +5 -3
  44. package/skills/ultra-dev/SKILL.md +173 -43
  45. package/skills/ultra-grilling/SKILL.md +19 -16
  46. package/skills/ultra-grilling/references/reframing.md +7 -3
  47. package/skills/ultra-init/SKILL.md +99 -87
  48. package/skills/ultra-init/references/brownfield-adoption.md +23 -40
  49. package/skills/ultra-init/scripts/init_project.cjs +968 -21
  50. package/skills/ultra-plan/SKILL.md +83 -46
  51. package/skills/ultra-plan/references/task-evidence-v2.md +300 -0
  52. package/skills/ultra-plan/scripts/validate_task_evidence.cjs +859 -0
  53. package/skills/ultra-research/SKILL.md +119 -68
  54. package/skills/ultra-research/references/{03-competitive-landscape.md → 03-alternatives.md} +6 -6
  55. package/skills/ultra-research/references/04-product-strategy.md +11 -2
  56. package/skills/ultra-research/references/21-features-scope.md +8 -0
  57. package/skills/ultra-research/references/22-success-metrics.md +9 -4
  58. package/skills/ultra-research/references/99-synthesis.md +25 -1
  59. package/skills/ultra-research/references/north-star-v2.md +168 -0
  60. package/skills/ultra-research/references/wayfinding.md +50 -0
  61. package/skills/ultra-research/scripts/validate_north_star.cjs +1174 -0
  62. package/skills/ultra-review/SKILL.md +201 -24
  63. package/skills/ultra-review/references/adversarial-evaluation.md +31 -0
  64. package/skills/ultra-review/references/spec.md +5 -0
  65. package/skills/ultra-review/references/unified-schema.md +146 -11
  66. package/skills/ultra-review/references/worker-packet.md +151 -8
  67. package/skills/ultra-review/scripts/review_wait.py +2653 -63
  68. package/skills/ultra-status/SKILL.md +146 -32
  69. package/skills/ultra-tdd/SKILL.md +14 -4
  70. package/skills/ultra-tdd/references/test-execution.md +6 -1
  71. package/skills/ultra-test/SKILL.md +157 -15
  72. package/skills/ultra-test/scripts/validate_review_transport.cjs +549 -0
  73. package/skills/ultra-test/scripts/worktree_digest.cjs +551 -29
  74. package/skills/ultra-think/SKILL.md +5 -10
  75. package/skills/ultra-think/references/interaction-boundary.md +2 -1
@@ -5,29 +5,81 @@ description: Carry one planned task from a written implementation plan through r
5
5
 
6
6
  # Take one task from plan to recorded evidence
7
7
 
8
- The model owns the code reasoning and the edits. The repository owns the task
9
- contract, the evidence, and everything needed to resume.
8
+ The model owns code reasoning and edits; repository files own the resumable contract.
10
9
 
11
10
  ## Before you start
12
11
 
13
- 1. Read `.ultra/tasks.json` and pick the task; read its `context_file` end to
14
- end, above all the closing `## Resume Note` — that line says where to pick up.
15
- 2. Read `CONTEXT.md` for vocabulary, and the `.ultra/decisions/` entries the task
12
+ 1. If model-selected, verify the live execution grant in `../ultra-change/references/execution-grant.md` — a current session-local activation or a stably verified durable work-package grant; without either, stop.
13
+ 2. Read `../ultra-change/references/change-contract.md` and apply its **Active Change
14
+ authority resolution** before reading any active `intent.md` or resolving a current
15
+ `change_id`. Require its one valid authority; otherwise stop with its typed repair.
16
+ Then read `.ultra/tasks.json`. Without an exact task id in the owner invocation,
17
+ select only the uniquely current `in_progress` task and read its full
18
+ `context_file`, especially `## Resume Note`; if none exists, stop and ask
19
+ the owner to invoke Dev naming one exact task id — a `pending` row is a frontier
20
+ candidate, not active work, and Hooks will not have injected its acceptance or
21
+ Resume. An invocation that names one exact task id supplies invocation-local
22
+ selection authority for this Dev run only. If more than one row claims
23
+ `in_progress`, do not manufacture a unique current task; use the explicit recovery
24
+ below or stop with the Hook diagnostic. The ledger is the sole task-status authority;
25
+ legacy Status or Complexity never overrides it. A `completed` task with a current
26
+ invalidation observation may be selected only for the explicit reopen below; record
27
+ and read back that transition before repair.
28
+ 3. Read `CONTEXT.md` for vocabulary, and the `.ultra/decisions/` entries the task
16
29
  context names.
17
- 3. Read `.ultra/north-star.md` and the task's acceptance criteria. If you cannot
18
- state that acceptance in one sentence, you are not ready to start.
30
+ 4. Validate `.ultra/north-star.md` with the shipped Research structural sensor. Resolve
31
+ every listed `FP-*`, `NS-*`, and `HC-*` in the task and active Change against that
32
+ accepted authority. Compare the active Change's recorded **North Star revision** and
33
+ **North Star digest** with the accepted file's revision and current Git blob digest.
34
+ A missing ID, revision mismatch, or digest mismatch is a stale-plan observation: stop
35
+ before editing and recommend explicit owner invocation of `ultra-change` to reconcile
36
+ the active Change. Never inherit approval or silently rewrite the trace.
37
+ 5. Read the task's acceptance criteria. If you cannot state that acceptance in one
38
+ sentence, you are not ready to start.
39
+
40
+ ### Activating one named pending task
41
+
42
+ When the owner invocation names a dependency-ready `pending` task, perform its
43
+ canonical activation before any implementation work: write that row from
44
+ `pending` to `in_progress` in `.ultra/tasks.json` and read the row back before
45
+ the first implementation edit. This one canonical ledger write is what makes
46
+ the named task live for the task-aware Hooks; without it Hooks correctly remain
47
+ task-silent while you edit, because a trusted invocation is visible only to the
48
+ invocation that carried it. The activation adds no selector, activation flag,
49
+ or workflow state — the ledger row is the only authority — and it must respect
50
+ the single-writer boundary: resolve any conflicting `in_progress` rows through
51
+ the recovery below or an owner decision before writing.
52
+
53
+ ### Recover one exact task from an ambiguous ledger
54
+
55
+ An explicit owner invocation with one exact task id supplies invocation-local selection
56
+ authority for this Dev run even when multiple ledger rows claim `in_progress`. Before
57
+ editing, read that exact canonical ledger row and context, especially its Resume Note,
58
+ then inspect current Git/worktree evidence for the named task. Do not persist a new
59
+ current-task selector, status, or workflow state to manufacture uniqueness. Hooks remain
60
+ task-silent and progress-silent while the ledger is ambiguous.
61
+
62
+ Only an explicit owner/Plan correction that establishes a conflicting task never started
63
+ may return that row to `pending`. If multiple tasks contain real partial work, keep every
64
+ task with real partial work `in_progress` and preserve each task's bytes. Recover them by
65
+ separate exact task-id owner invocations or obtain owner-authorized Plan reconciliation;
66
+ use a separate worktree when needed to keep their writes isolated. Completing the
67
+ selected task still requires final review, canonical v2 evidence, context publication,
68
+ ledger write, and readback.
19
69
 
20
70
  When this task starts from an observed error, failing check or unexpected behavior,
21
71
  read `references/debugging.md` and establish the earliest incorrect state before editing.
22
72
 
23
73
  ## Definition of done
24
74
 
25
- - All six evidence dimensions are answered for this task, each against the
26
- checkable rule below rather than an impression.
27
- - `tasks.json` and the context file's header state the same status, each written
28
- and then read back — a one-sided write breaks resume on another host.
75
+ - All six evidence dimensions carry honest, current observations under the typed v2
76
+ evidence contract; a real limitation remains a gap rather than becoming a pass.
77
+ - `.ultra/tasks.json` remains the sole task-status authority after write/read-back.
78
+ - The task still names the active `change_id`; historical unfinished work stays out.
29
79
  - The context file carries a Completion entry and a rewritten Resume Note.
30
- - A task-level review has run and its blocking findings are resolved.
80
+ - A task-level review runs while the ledger task remains `in_progress`; its blocking
81
+ findings are resolved or owner-dispositioned as required and affected evidence is
82
+ refreshed before the model writes `completed` to the ledger.
31
83
 
32
84
  ## Write the implementation plan before the code
33
85
 
@@ -39,29 +91,54 @@ buries the design decisions in the details.
39
91
  ## Develop through red then green
40
92
 
41
93
  Follow `../ultra-tdd/SKILL.md`, writing tests only on the seams the plan already
42
- confirmed, one slice at a time. Do no refactoring here — `ultra-review` owns it,
43
- because what is worth restructuring only becomes visible after several slices.
94
+ confirmed, one slice at a time. `ultra-review` owns evidence-backed refactoring when
95
+ observed duplication, coupling, or a boundary defect justifies it; a slice count does
96
+ not make that decision.
44
97
 
45
98
  ## Converge on the task-scoped acceptance set
46
99
 
47
- Development ends when the task's acceptance commands pass, not when the code looks
100
+ Development ends when every task-scoped criterion has its required current evidence and
101
+ responsible semantic disposition, not merely when commands pass or the code looks
48
102
  finished. Resolve the context's **Change Acceptance IDs** against the active `intent.md`
49
- and use each named row's executable `Verification`. Commands under the context's
50
- Acceptance Criteria may add task-local checks; they do not replace the Change mapping.
51
-
52
- Run one baseline before repairing anything. Track the best-ever passing set of mapped
53
- IDs and task-local commands, the total repair rounds, and consecutive rounds that add
54
- nothing to that set. The loop has three explicit exits:
103
+ for `<change_id>`. For each named row consume its exact `Verification type` and
104
+ `Required evidence`. When one outcome needs more than one authority, split it into
105
+ independent criteria with unique IDs and preserve each authority separately; every row
106
+ has exactly one verification type. Task-local acceptance may add evidence requirements,
107
+ but it does not replace or narrow the Change mapping.
108
+
109
+ Handle the four verification types without converting one authority into another:
110
+
111
+ - Execute only `command` observations. Record the exact command, working directory,
112
+ exit status, retained raw output reference, and its exact SHA-256.
113
+ - For `inspection`, cite the exact source and revision or digest, then refresh the
114
+ observation after any touched source changes.
115
+ - For `owner-judgment`, preserve the cited owner decision. The owner alone supplies its
116
+ semantic result; a model statement, validator, score, or command cannot proxy it.
117
+ - For `external-observation`, preserve the provider or system receipt without proxying it
118
+ with a local command, model claim, or synthetic fixture, and bind its exact bytes by
119
+ SHA-256.
120
+
121
+ - Missing `owner-judgment` stops at its named owner gate.
122
+ - Missing `external-observation` stops at its named external or authorization gate.
123
+ - If an inspection exists but its semantic implication is unresolved, stop at the
124
+ responsible model or owner gate; a structural citation is not an automatic acceptance
125
+ verdict.
126
+
127
+ Run one baseline before repairing anything. Track a best-ever evidence set keyed by
128
+ criterion, verification type, and source identity to make progress visible, plus the
129
+ current evidence set used for convergence. Stale or regressed evidence remains history
130
+ but cannot satisfy the current set. Do not infer semantic progress or failure from a
131
+ round count. The loop has three explicit exits:
55
132
 
56
133
  | Exit | Condition | Action |
57
134
  |---|---|---|
58
- | Converged | Every mapped Change verification and task-local command exits zero | Close out below |
59
- | Stalled | Two consecutive repair rounds add no new item to the best-ever passing set, or three repair rounds finish without convergence | Stop; report the remaining criteria and what each repair tried |
60
- | Unreachable | A command did not start because its executable, fixture, service or declared environment prerequisite is unavailable | Stop that criterion; report the missing prerequisite and its repair path |
135
+ | Converged | Every mapped and task-local criterion has current required evidence of every named type, and the responsible model or owner has made any semantic disposition | Close out below |
136
+ | Stalled | An in-scope repair yields no new or refreshed evidence and no further evidence-producing repair is justified inside the approved task | Stop; report the missing evidence, the attempted repair, and the responsible next gate |
137
+ | Unreachable | Required evidence cannot be observed because an executable, fixture, provider, service, declared environment prerequisite, or required authorization is unavailable | Stop that criterion; report the unavailable prerequisite or gate and its reachable repair path |
61
138
 
62
- A nonzero exit normally means a failing criterion, not an unreachable one; inspect its
63
- output. A regression never shrinks the best-ever set, and the total round limit stops
64
- oscillation where different criteria alternate between pass and fail.
139
+ A nonzero command exit is an observation, not automatically `Unreachable`; inspect its
140
+ output and repair within scope when justified. None of these exits mechanically decides
141
+ semantic sufficiency, owner acceptance, or external truth.
65
142
 
66
143
  ## Answer the six evidence dimensions
67
144
 
@@ -76,14 +153,15 @@ Each has a rule you can check against the work rather than assert:
76
153
  | `vertical_slice` | One test's execution path runs from the entry point through to persistence |
77
154
  | `spec_trace` | The anchor the task's `trace_to` names exists in the specification |
78
155
 
79
- Record one canonical `.ultra/evidence/<task-id>/evidence.json` with
80
- `$schema: "ultra-task-evidence-v1"`, `task_id`, `git_head`, `commands`, the six-key
81
- `dimensions` object, `artifacts`, `limitations`, and `timestamp`. Raw logs and cited
82
- files stay beside it; no second summary restates the same evidence. Each command has
83
- `command`, `exit_code`, and `evidence_ref`. Each dimension has `status` (`satisfied`,
84
- `gap`, or `not_applicable`), `evidence_refs`, and a non-empty `rationale`. Evidence is a
85
- sensor, not a gate: a gap is reported and handed over, never used to block the work — a
86
- gate that can be escaped by damaging the work gets escaped by damaging the work.
156
+ Before task review, retain the actual criterion evidence, raw logs, owner records,
157
+ external receipts, and cited artifacts without inventing another completion record.
158
+ Do not write `evidence.json` before the task's validated final `SUMMARY.json` exists.
159
+ The review packet admits those actual pre-review observations together with the ledger,
160
+ context acceptance, and packet-defined task scope. A structural validator may check
161
+ exact fields, types, digests, paths, and freshness observations. It never supplies an
162
+ acceptance disposition, turns a model claim into command evidence, or decides semantic pass.
163
+ Evidence is a sensor: a gap or legacy v1 record is reported with a migration
164
+ diagnostic, never rewritten as v2 truth.
87
165
 
88
166
  ## When implementation and the specification disagree
89
167
 
@@ -95,10 +173,60 @@ classification in the context file's Change Log.
95
173
 
96
174
  ## Close out
97
175
 
98
- Write the status to both places and read both back. Add the Completion entry and
99
- rewrite the Resume Note to say where the next session picks up. Then run the
100
- task-level review through `../ultra-review/SKILL.md`, resolve blocking findings, and refresh
101
- the evidence they touched.
176
+ Keep the ledger row `in_progress` while running task review through
177
+ `../ultra-review/SKILL.md`. Build its immutable packet from the ledger, task context,
178
+ packet-defined task scope, and actual pre-review evidence; the final v2 record is not an
179
+ admission prerequisite. Route only the exact current P0/P1 findings (or a P2 the owner
180
+ explicitly promoted) as one in-scope repair set, followed by one affected-lens delta
181
+ review per repair set inside the active review budget — an exact current owner grant
182
+ overrides the versioned product default of one initial review plus at most two
183
+ P0/P1 delta reviews per package. When another `REQUEST_CHANGES` would exceed the
184
+ active budget, return to the owner checkpoint with the exact blocking set instead of
185
+ an automatic repair; the same root surviving three failed fixes stops point-patching
186
+ and reports an architecture problem. Budget exhaustion stops execution at `owner checkpoint` /
187
+ `budget_exhausted` and keeps the ledger row `in_progress`.
188
+ It never yields `APPROVE`, `REQUEST_CHANGES`, `INCOMPLETE`, pass, fail, accept, or
189
+ abandon. If a repair changes implementation or evidence in review scope, use a new
190
+ immutable packet and validated review summary before closeout rather than rebinding the
191
+ old review. Worker Packet v1 and its summary do not bind a task worktree digest.
192
+
193
+ After the final validated `SUMMARY.json`, write one canonical `ultra-task-evidence-v2` record only after completing the raw-receipt binding below.
194
+ When the task's owner-designated review mode is external manual, the final review
195
+ product is instead the external reviewer's real receipt, bound through the
196
+ `review_mode: "external-manual"` branch of
197
+ `../ultra-plan/references/task-evidence-v2.md`: publish that receipt under
198
+ `.ultra/evidence/<task-id>/`, record its exact stable-byte SHA-256, and verify it
199
+ with the sensor's `--verify-external-receipt` mode instead of inventing a strict
200
+ session. Never fabricate one branch's artifacts to satisfy the other's shape.
201
+ The `subject` is an independently captured completion-snapshot freshness observation.
202
+ Before writing `evidence.json`, resolve every
203
+ command and external-observation `raw_evidence_ref` below the real repository root and
204
+ take bounded stable repository-contained bytes from an ordinary regular non-symlink file
205
+ opened nonblocking and no-follow. Reject a missing, escaped, symlinked, special,
206
+ oversized, or replaced file; otherwise compute `raw_evidence_sha256` from that one byte
207
+ snapshot. Publish that canonical record at `.ultra/evidence/<task-id>/evidence.json`,
208
+ read back the stable record and each raw ref,
209
+ and require the same ref bytes and digest before continuing.
210
+ Follow `../ultra-plan/references/task-evidence-v2.md`: `task_review` separately binds the retained strict summary; record one typed acceptance entry per criterion, all
211
+ six dimensions, the exact Execution Packet and review identities, blocking-finding
212
+ dispositions, evidence refresh refs, artifacts, limitations, and retention without
213
+ claiming that the review summary proves `subject.worktree_digest`. Read the record back, then update context
214
+ `## Task Review`, Completion, and `## Resume Note`; the context has no second status.
215
+ Only after those facts are durable may the primary model write `completed` to the
216
+ ledger and read the row back. When the task's work package sits under an
217
+ ACK-ready primary transfer whose newest terminal receipt is a completed v2
218
+ RESULT, this sequence is that contract's prescribed closeout: publish the
219
+ handoff's `CLOSEOUT.json` beside the frozen RESULT — citing the review receipt,
220
+ the closeout-start/end observations, and any recorded owner-authorized
221
+ continuation — instead of refreshing the RESULT or opening a new handoff; the
222
+ closeout starts no review and no repair round
223
+ (`../ultra-change/references/primary-transfer.md`).
224
+
225
+ If later work invalidates a completed task's criterion evidence, Dev performs an
226
+ explicit reopen. A reopen changes the ledger row from `completed` to `in_progress`;
227
+ Dev must never silently demote the row. Before that write, record the affected criterion IDs and reason in both the context Change Log and Resume Note, preserve the prior review as
228
+ historical evidence, then write and read back the ledger transition. Refresh the named
229
+ evidence, run task review for the new snapshot, and repeat this closeout sequence.
102
230
 
103
231
  Report the changed paths, the seam, the exact checks run, the review result, the
104
232
  evidence gaps and the residual risk. Recommend the next capability from what the
@@ -106,14 +234,16 @@ files now say; do not invoke it.
106
234
 
107
235
  ## When the owner decides
108
236
 
109
- Any REDUCTION, and each external effect separately.
110
- At most one authorized local task commit happens here; push, tag, publish and
111
- deploy each need their own authorization. An interrupted task leaves its worktree
112
- as it stands and says so in the Resume Note instead of tidying it away.
237
+ The owner decides any REDUCTION and each external effect separately. At most one
238
+ authorized local task commit happens here; push, tag, publish and deploy need separate
239
+ authority. An interruption leaves the worktree as-is and names it in the Resume Note.
113
240
 
114
241
  ## References
115
242
 
243
+ - `../ultra-change/references/change-contract.md` — canonical Active Change authority resolution.
116
244
  - `../ultra-tdd/SKILL.md` — read before the first test, for the seam and mock boundary.
117
245
  - `../ultra-think/references/autonomy-boundary.md` — read when spec and code disagree.
118
246
  - `../ultra-review/SKILL.md` — read when implementation evidence is ready for review.
247
+ - `../ultra-change/references/execution-grant.md` — read only for grant-activated continuation.
248
+ - `../ultra-plan/references/task-evidence-v2.md` — canonical evidence, disposition, and task-review shape.
119
249
  - `references/debugging.md` — read for a reproduced failure before selecting a repair.
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  name: ultra-grilling
3
- description: Interrogate an owner request until every branch of its decision tree is resolved, one question per turn, each carrying a recommended answer. Use when another skill needs the owner's intent specific enough to build from — a new project's north star, a Change boundary, or an ask whose acceptance criteria are still implicit.
3
+ description: Turn caller-named missing owner decisions into confirmed answers, one question per turn and each carrying a recommendation. Use when Init needs a raw brief field, Research needs an owner decision, or Change and Plan need an explicit boundary or acceptance criterion.
4
4
  ---
5
5
 
6
6
  # Turn a vague ask into a decision list the owner has explicitly confirmed
@@ -12,8 +12,8 @@ finished work proves otherwise. It serves Goal 1, Intent Fidelity.
12
12
  ## Before you start
13
13
 
14
14
  1. Reread what the owner said in the current request, verbatim.
15
- 2. Read `.ultra/north-star.md` and `CONTEXT.md` where they exist. Established
16
- wording and vocabulary are decisions that were already made.
15
+ 2. Read `.ultra/project-brief.md`, `.ultra/north-star.md`, and `CONTEXT.md` where they
16
+ exist. Raw intake is reusable input; accepted wording must not be re-asked.
17
17
  3. Look up every fact you can reach on your own: repository files, Git history,
18
18
  installed dependencies, tool output.
19
19
 
@@ -29,8 +29,8 @@ have answered by reading the repository spends the one input only they can give.
29
29
  never skipped because the original wording sounded clear.
30
30
  - Each answer carries the owner's confirmation, rather than something that
31
31
  sounded like agreement.
32
- - The calling skill holds a decision list it can write to a file: one line per
33
- decision, each with the options rejected and why.
32
+ - The caller owns the final artifact and receives a decision list it can write: one
33
+ line per decision, each with the options rejected and why.
34
34
 
35
35
  ## Extract, reframe, then ask
36
36
 
@@ -52,7 +52,7 @@ product. Offer the reframe, never assert it, and treat a correction as the bette
52
52
  outcome — "no, it really is just the briefing" is a constraint you did not have a
53
53
  minute ago. Read `references/reframing.md` for when it applies and how it fails.
54
54
 
55
- **Then ask** only what the confirmed reframe leaves open.
55
+ **Then ask** only what the confirmed reframe leaves open; the caller sets the semantic depth, so Init stops at the raw outline and leaves baseline questions to Research.
56
56
 
57
57
  ## One question per turn
58
58
 
@@ -67,10 +67,11 @@ Order questions so that answering one unlocks the next. Ask the framing question
67
67
  before the detail questions — a detail settled inside the wrong frame has to be
68
68
  asked again.
69
69
 
70
- **Framing questions** come first — at most five, from the table in
71
- `references/reframing.md`. They refuse the owner's framing on purpose, which is
72
- how they surface what the request left out. Stop early once the frame stops
73
- moving.
70
+ **Framing questions** come first, selecting only prompts from
71
+ `references/reframing.md` that can change the current frame. They refuse the owner's
72
+ framing on purpose, which is how they surface what the request left out. Stop once the
73
+ owner confirms the frame or further prompts cannot distinguish a materially different
74
+ build; a question count never decides that.
74
75
 
75
76
  **Detail questions** fill in the confirmed frame:
76
77
 
@@ -95,13 +96,15 @@ inferred consensus.
95
96
 
96
97
  ## How the loop ends
97
98
 
98
- Every ending hands back the same artifact: the decisions written one per line,
99
- each with the options rejected and the reason they lost. The caller chooses where
100
- it lands — `north-star.md`, `discovery.md`, a Change intent, or a decision file.
99
+ Every ending hands back the same result: decisions written one per line, each with
100
+ the options rejected and the reason they lost. The caller alone chooses the canonical
101
+ destination; Grilling never promotes an answer into project authority by itself.
101
102
 
102
103
  - **Resolved** — every required field answered or explicitly deferred.
103
- - **Stalled** — two consecutive turns add no newly confirmed decision. Hand back
104
- the open fields and what each one blocks.
104
+ - **Stalled** — the evidence shows that another in-scope question cannot produce a new
105
+ decision without unavailable owner input or a newly framed choice. Hand back the open
106
+ fields, the attempted distinctions, and what each one blocks; do not infer this from
107
+ a turn count.
105
108
  - **Unavailable** — the host cannot ask, or the owner stopped answering. Hand back
106
109
  the last confirmed state, every unanswered field named.
107
110
 
@@ -113,6 +116,6 @@ question per turn instead.
113
116
  ## References
114
117
 
115
118
  - `references/reframing.md` — read before the first question: when to reframe,
116
- how it fails, the five framing questions, and what counts as an answer.
119
+ how it fails, the framing prompts, and what counts as an answer.
117
120
  - `../ultra-think/references/autonomy-boundary.md` — read when an answer removes
118
121
  something the specification already promised, or otherwise crosses C5.
@@ -36,13 +36,17 @@ Rules that keep this honest:
36
36
  a constraint you did not have a minute ago. Record it as a decision.
37
37
  - **Never reframe toward what is easier to build.** If your reinterpretation
38
38
  happens to shrink the work, say that out loud and let the owner weigh it.
39
- - **Stop after two rejected reframes.** A third is no longer listening. Take the
40
- owner's framing as given and move to the framing questions below.
39
+ - **Stop when the owner rejects the proposed role and confirms their original frame.**
40
+ Do not keep producing cosmetic reinterpretations. If a materially different reading
41
+ later becomes evidenced, present that new distinction rather than counting prior
42
+ attempts.
41
43
 
42
44
  ## Framing questions
43
45
 
44
46
  These refuse the owner's framing on purpose, which is how they surface what the
45
- request left out. Ask at most five, and stop early once the frame stops moving.
47
+ request left out. Ask only the prompts that can distinguish a materially different
48
+ build, and stop when the owner confirms the frame or the remaining prompts cannot
49
+ change it.
46
50
 
47
51
  | Question | What it recovers |
48
52
  |---|---|