okstra 0.123.0 → 0.125.0

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 (98) hide show
  1. package/README.md +1 -0
  2. package/docs/architecture/storage-model.md +3 -1
  3. package/docs/architecture.md +16 -2
  4. package/docs/cli.md +3 -1
  5. package/docs/for-ai/README.md +41 -35
  6. package/docs/for-ai/skills/okstra-brief-gen.md +105 -105
  7. package/docs/for-ai/skills/okstra-container-build.md +61 -61
  8. package/docs/for-ai/skills/okstra-graphify.md +64 -0
  9. package/docs/for-ai/skills/okstra-inspect.md +87 -86
  10. package/docs/for-ai/skills/okstra-manager.md +32 -32
  11. package/docs/for-ai/skills/okstra-memory.md +49 -50
  12. package/docs/for-ai/skills/okstra-pr-gen.md +48 -0
  13. package/docs/for-ai/skills/okstra-rollup.md +58 -58
  14. package/docs/for-ai/skills/okstra-run.md +95 -95
  15. package/docs/for-ai/skills/okstra-schedule-gen.md +106 -106
  16. package/docs/for-ai/skills/okstra-setup.md +63 -64
  17. package/docs/for-ai/skills/okstra-user-response.md +48 -0
  18. package/docs/performance-improvement-plan-v2.md +6 -6
  19. package/docs/pr-template-usage.md +34 -34
  20. package/docs/project-structure-overview.md +91 -70
  21. package/docs/task-process/README.md +33 -33
  22. package/docs/task-process/common-flow.md +26 -26
  23. package/docs/task-process/error-analysis.md +20 -21
  24. package/docs/task-process/final-verification.md +41 -41
  25. package/docs/task-process/implementation-planning.md +33 -33
  26. package/docs/task-process/implementation.md +38 -38
  27. package/docs/task-process/release-handoff.md +46 -46
  28. package/docs/task-process/requirements-discovery.md +22 -23
  29. package/package.json +1 -1
  30. package/runtime/BUILD.json +2 -2
  31. package/runtime/agents/workers/antigravity-worker.md +4 -4
  32. package/runtime/agents/workers/claude-worker.md +2 -2
  33. package/runtime/agents/workers/codex-worker.md +4 -4
  34. package/runtime/agents/workers/report-writer-worker.md +4 -4
  35. package/runtime/bin/lib/okstra/usage.sh +1 -1
  36. package/runtime/prompts/coding-preflight/frameworks/node-server.md +1 -1
  37. package/runtime/prompts/launch.template.md +1 -1
  38. package/runtime/prompts/lead/convergence.md +10 -20
  39. package/runtime/prompts/lead/okstra-lead-contract.md +15 -17
  40. package/runtime/prompts/lead/plan-body-verification.md +18 -18
  41. package/runtime/prompts/lead/report-writer.md +46 -44
  42. package/runtime/prompts/lead/team-contract.md +11 -122
  43. package/runtime/prompts/profiles/_common-contract.md +15 -22
  44. package/runtime/prompts/profiles/_implementation-deliverable.md +1 -1
  45. package/runtime/prompts/profiles/_implementation-executor.md +1 -1
  46. package/runtime/prompts/profiles/_implementation-verifier.md +28 -2
  47. package/runtime/prompts/profiles/error-analysis.md +2 -2
  48. package/runtime/prompts/profiles/final-verification.md +1 -1
  49. package/runtime/prompts/profiles/implementation-planning.md +13 -13
  50. package/runtime/prompts/profiles/implementation.md +2 -1
  51. package/runtime/prompts/profiles/improvement-discovery.md +1 -1
  52. package/runtime/prompts/profiles/release-handoff.md +3 -3
  53. package/runtime/prompts/profiles/requirements-discovery.md +17 -18
  54. package/runtime/python/okstra_ctl/models.py +4 -2
  55. package/runtime/python/okstra_ctl/run.py +8 -2
  56. package/runtime/python/okstra_ctl/stage_fix_carry.py +112 -0
  57. package/runtime/schemas/final-report-v1.0.schema.json +6 -6
  58. package/runtime/skills/_fragments/bash-invocation-rule.md +1 -0
  59. package/runtime/skills/_fragments/preflight-outdated-cli.md +1 -0
  60. package/runtime/skills/_fragments/python-bootstrap-note.md +1 -0
  61. package/runtime/skills/okstra-brief-gen/SKILL.md +117 -122
  62. package/runtime/skills/okstra-container-build/SKILL.md +24 -14
  63. package/runtime/skills/okstra-graphify/SKILL.md +12 -4
  64. package/runtime/skills/okstra-inspect/SKILL.md +39 -747
  65. package/runtime/skills/okstra-inspect/facets/cost.md +84 -0
  66. package/runtime/skills/okstra-inspect/facets/error-zip.md +41 -0
  67. package/runtime/skills/okstra-inspect/facets/errors.md +69 -0
  68. package/runtime/skills/okstra-inspect/facets/history.md +90 -0
  69. package/runtime/skills/okstra-inspect/facets/logs.md +89 -0
  70. package/runtime/skills/okstra-inspect/facets/recap.md +96 -0
  71. package/runtime/skills/okstra-inspect/facets/report.md +61 -0
  72. package/runtime/skills/okstra-inspect/facets/status.md +145 -0
  73. package/runtime/skills/okstra-inspect/facets/time.md +56 -0
  74. package/runtime/skills/okstra-manager/SKILL.md +1 -1
  75. package/runtime/skills/okstra-memory/SKILL.md +3 -3
  76. package/runtime/skills/okstra-pr-gen/SKILL.md +3 -3
  77. package/runtime/skills/okstra-rollup/SKILL.md +12 -6
  78. package/runtime/skills/okstra-run/SKILL.md +49 -88
  79. package/runtime/skills/okstra-schedule-gen/SKILL.md +36 -30
  80. package/runtime/skills/okstra-setup/SKILL.md +1 -1
  81. package/runtime/skills/okstra-setup/references/project-config.md +17 -16
  82. package/runtime/skills/okstra-usage/SKILL.md +5 -2
  83. package/runtime/skills/okstra-user-response/SKILL.md +15 -3
  84. package/runtime/templates/prd/brief.template.md +92 -92
  85. package/runtime/templates/project-docs/task-index.template.md +1 -1
  86. package/runtime/templates/reports/error-analysis-input.template.md +1 -1
  87. package/runtime/templates/reports/fan-out-unit.template.md +6 -6
  88. package/runtime/templates/reports/final-verification-input.template.md +6 -6
  89. package/runtime/templates/reports/implementation-input.template.md +1 -1
  90. package/runtime/templates/reports/implementation-planning-input.template.md +1 -1
  91. package/runtime/templates/reports/improvement-discovery-input.template.md +1 -1
  92. package/runtime/templates/reports/quick-input.template.md +1 -1
  93. package/runtime/templates/reports/release-handoff-input.template.md +1 -1
  94. package/runtime/templates/reports/schedule.template.md +22 -22
  95. package/runtime/templates/reports/task-brief.template.md +3 -3
  96. package/runtime/templates/reports/user-response.template.md +20 -20
  97. package/runtime/templates/worker-prompt-preamble.md +111 -13
  98. package/runtime/validators/validate-schedule.py +1 -1
@@ -1,52 +1,52 @@
1
1
  # okstra-run AI Manual
2
2
 
3
- ## 원천
3
+ ## Source
4
4
 
5
- - 스킬 원문: [`skills/okstra-run/SKILL.md`](../../../skills/okstra-run/SKILL.md)
5
+ - Skill source: [`skills/okstra-run/SKILL.md`](../../../skills/okstra-run/SKILL.md)
6
6
  - wizard CLI wrapper: [`src/commands/execute/wizard.mjs`](../../../src/commands/execute/wizard.mjs)
7
7
  - wizard state machine: [`scripts/okstra_ctl/wizard.py`](../../../scripts/okstra_ctl/wizard.py)
8
8
  - render-bundle CLI: [`src/commands/execute/render-bundle.mjs`](../../../src/commands/execute/render-bundle.mjs)
9
9
  - prepare entrypoint: [`scripts/okstra_ctl/run.py`](../../../scripts/okstra_ctl/run.py)
10
10
 
11
- ## 목적
11
+ ## Purpose
12
12
 
13
- `okstra-run`은 현재 Claude Code 세션 안에서 okstra task run을 시작한다. 입력 수집은 `okstra wizard` state machine 전담하고, 스킬은 wizard prompt를 사용자에게 relay한 `okstra render-bundle`로 task bundle 준비한다. bundle이 준비되면 현재 세션이 Claude lead로 전환된다.
13
+ `okstra-run` starts an okstra task run inside the current Claude Code session. Input collection is owned entirely by the `okstra wizard` state machine; the skill relays the wizard prompts to the user and then prepares the task bundle via `okstra render-bundle`. Once the bundle is ready, the current session takes over as Claude lead.
14
14
 
15
- 단일 권위:
15
+ Single authority:
16
16
 
17
- - 질문 순서, 분기, validation: `scripts/okstra_ctl/wizard.py`
17
+ - Question order, branching, validation: `scripts/okstra_ctl/wizard.py`
18
18
  - task bundle materialization: `prepare_task_bundle()`
19
- - 스킬 문서: thin prompt-relay loop
19
+ - Skill document: thin prompt-relay loop
20
20
 
21
- ## 사용 조건
21
+ ## When to Use
22
22
 
23
- 사용한다:
23
+ Use it when:
24
24
 
25
- - 사용자가 현재 세션에서 okstra task 시작하려고 한다.
26
- - 기존 task의 다음 phase 이어서 실행하려고 한다.
27
- - "okstra run", "okstra start", " 세션에서 okstra 시작", "다음 단계 실행" 등.
25
+ - The user wants to start an okstra task in the current session.
26
+ - The user wants to continue the next phase of an existing task.
27
+ - "okstra run", "okstra start", "start okstra in this session", "run the next phase", etc.
28
28
 
29
- 사용하지 않는다:
29
+ Do not use it when:
30
30
 
31
- - 상태만 보려는 경우: `okstra-inspect status`
32
- - 과거 run이나 resume command 보려는 경우: `okstra-inspect history`
33
- - 사용자가 terminal/new claude process 명시한 경우: inspect history/resume 안내
31
+ - The user only wants status: `okstra-inspect status`
32
+ - The user wants past runs or a resume command: `okstra-inspect history`
33
+ - The user explicitly named a new terminal / new claude process: point them to inspect history/resume
34
34
 
35
35
  ## Preflight
36
36
 
37
- 단일 Bash 호출:
37
+ A single Bash call:
38
38
 
39
39
  ```bash
40
40
  okstra preflight --runtime claude-code --json
41
41
  ```
42
42
 
43
- runtime이나 project setup 없으면(`ok:false`) `/okstra-setup`을 안내하고 멈춘다. `export PYTHONPATH`를 만들지 않는다.
43
+ If there is no runtime or project setup (`ok:false`), point the user to `/okstra-setup` and stop. Do not create an `export PYTHONPATH`.
44
44
 
45
- ## Bash 호출 규칙
45
+ ## Bash invocation rule
46
46
 
47
- 모든 okstra 호출은 literal token `okstra`로 시작한다. `--state-file`, `--answer`, path, model, worker 값은 이전 JSON/tool output에서 읽어 literal string으로 붙인다.
47
+ Every okstra call begins with the literal token `okstra`. Read the `--state-file`, `--answer`, path, model, and worker values from the prior JSON/tool output and paste them as literal strings.
48
48
 
49
- 피해야 한다:
49
+ Avoid:
50
50
 
51
51
  - `$STATE_FILE`, `$ANSWER`
52
52
  - `$(...)`
@@ -54,21 +54,21 @@ runtime이나 project setup이 없으면(`ok:false`) `/okstra-setup`을 안내
54
54
  - `eval`, `export`
55
55
  - `okstra ... && okstra ...`
56
56
 
57
- empty answer도 flag 생략하지 않는다.
57
+ Do not drop the flag even for an empty answer.
58
58
 
59
59
  ```bash
60
60
  okstra wizard step --state-file /tmp/okstra-wizard/state.json --answer ""
61
61
  ```
62
62
 
63
- ## wizard 초기화
63
+ ## wizard initialization
64
64
 
65
- state file 생성:
65
+ Create the state file:
66
66
 
67
67
  ```bash
68
68
  okstra wizard new-state-file
69
69
  ```
70
70
 
71
- 출력 absolute path 그대로 들고 간다.
71
+ Carry the printed absolute path verbatim.
72
72
 
73
73
  wizard init:
74
74
 
@@ -76,61 +76,61 @@ wizard init:
76
76
  okstra wizard init --state-file /tmp/okstra-wizard/state.json --project-root /abs/project --project-id project-id
77
77
  ```
78
78
 
79
- 결과는 `{ok, next}` JSON이다. step `task_pick`이다.
79
+ The result is `{ok, next}` JSON. The first step is `task_pick`.
80
80
 
81
- ## wizard JSON 해석
81
+ ## Interpreting the wizard JSON
82
82
 
83
- `next.kind`에 따라 UI를 고른다.
83
+ Pick the UI according to `next.kind`.
84
84
 
85
- | kind | 처리 |
85
+ | kind | Handling |
86
86
  |---|---|
87
- | `pick`, `multi: false` | 모든 `options[]`를 그대로 selectable choice 렌더. 선택 option `value` 제출 |
88
- | `pick`, `multi: true` | 모든 선택 value를 comma-separated string으로 제출. 선택 없음도 `--answer ""` 제출 |
89
- | `pick_group` | wizard `questions[]`를 번의 multi-question UI 렌더. step별 value를 JSON object 만들어 번에 제출 |
90
- | `text` | picker를 쓰지 않고 plain text label 보여준 다음 사용자 메시지를 verbatim 제출 |
91
- | `done` | 입력 수집 종료. render-args 이동 |
92
- | `aborted` | state file 지우고 중단. render-args/render-bundle 호출 금지 |
87
+ | `pick`, `multi: false` | Render every `options[]` verbatim as a selectable choice. Submit the chosen option's `value` |
88
+ | `pick`, `multi: true` | Submit all chosen values as a comma-separated string. An empty selection still submits `--answer ""` |
89
+ | `pick_group` | Render the wizard's `questions[]` as a single multi-question UI. Build a JSON object of per-step values and submit it in one shot |
90
+ | `text` | Show a plain text label without a picker, then submit the user's next message verbatim |
91
+ | `done` | Input collection finished. Move to render-args |
92
+ | `aborted` | Delete the state file and stop. Do not call render-args/render-bundle |
93
93
 
94
- `progress.label`은 wizard 만든 문자열이다. UI prompt 뒤에 그대로 붙이고, 직접 계산하지 않는다.
94
+ `progress.label` is a string the wizard composed. Append it verbatim after the UI prompt; do not compute it yourself.
95
95
 
96
96
  ## wizard loop
97
97
 
98
- 1. prompt 렌더.
99
- 2. 사용자 답변을 literal `--answer`로 제출.
100
- 3. `ok: true`: `result.echo`를 줄로 사용자에게 보여주고 다음 step.
101
- 4. `ok: false`: `result.error`를 그대로 보여주고 `result.current`로 같은 step 재시도.
102
- 5. `current: null`: prompt 재구성할 없는 terminal 오류다. 에러를 보여주고 멈춘다.
98
+ 1. Render the prompt.
99
+ 2. Submit the user's answer as a literal `--answer`.
100
+ 3. `ok: true`: show `result.echo` to the user on one line and advance to the next step.
101
+ 4. `ok: false`: show `result.error` verbatim and retry the same step via `result.current`.
102
+ 5. `current: null`: a terminal error where the prompt cannot be reconstructed. Show the error and stop.
103
103
 
104
- 중요: wizard 제공한 option을 줄이거나 숨기거나 "추천 + 직접 입력"으로 재구성하지 않는다. wizard `options[]`가 완전한 선택지다.
104
+ Important: never trim, hide, or restructure the wizard-provided options into a "recommended + Enter directly" form. The wizard's `options[]` is the complete choice set.
105
105
 
106
- ## brief 후보 정렬
106
+ ## brief candidate ordering
107
107
 
108
- entry phase(`requirements-discovery`, `error-analysis`, `improvement-discovery`) brief 선택은 wizard가 처리한다.
108
+ The brief selection for entry phases (`requirements-discovery`, `error-analysis`, `improvement-discovery`) is handled by the wizard.
109
109
 
110
- - task-group 후보는 task catalog의 최근 사용 이력과 `.okstra/briefs/<group>/` 아래 최근 brief 생성/수정 시각을 합산해 최신순으로 보여준다.
111
- - brief 파일 후보는 선택된 group `.okstra/briefs/<task-group>/**/*.md` 안에서 고른다.
112
- - brief 파일 정렬 키는 `max(파일 생성/수정 시각, 해당 brief를 사용한 task catalog updatedAt)`이다.
113
- - direct input 항상 마지막이다.
110
+ - task-group candidates are shown newest-first by combining recent task-catalog use with the recent brief creation/modification times under `.okstra/briefs/<group>/`.
111
+ - brief file candidates are chosen from within the selected group's `.okstra/briefs/<task-group>/**/*.md`.
112
+ - The brief-file sort key is `max(file created/modified time, task-catalog updatedAt of the task that used this brief)`.
113
+ - direct input is always last.
114
114
 
115
115
  ## confirm step
116
116
 
117
- `next.step == "confirm"`이면 먼저 confirmation summary를 가져온다.
117
+ When `next.step == "confirm"`, first fetch the confirmation summary.
118
118
 
119
119
  ```bash
120
120
  okstra wizard confirmation --state-file /tmp/okstra-wizard/state.json
121
121
  ```
122
122
 
123
- `text`를 사용자에게 보여준 Proceed/Edit/중단 picker 렌더한다. `Edit`은 wizard 이전 step으로 rewind한다.
123
+ Show `text` to the user, then render the Proceed/Edit/Abort picker. `Edit` rewinds the wizard to an earlier step.
124
124
 
125
- ## outcome render-bundle
125
+ ## outcome and render-bundle
126
126
 
127
- `next.kind == "done"`이면:
127
+ When `next.kind == "done"`:
128
128
 
129
129
  ```bash
130
130
  okstra wizard outcome --state-file /tmp/okstra-wizard/state.json
131
131
  ```
132
132
 
133
- `outcome.persistActions[]`를 먼저 실행한 `outcome.renderArgs` object key를 `okstra render-bundle` flag 전달한다. string 값도 명시적으로 전달한다. 예외: `chain-stages` key render-bundle flag 아니다 — Step 7 무인 연쇄 루프를 구동하는 값이라 flag 넘기지 않는다(`run.py`는 `--stage`/`--stages`만 받는다). render-bundle block `--stage`는 implementation·final-verification 전용, `--stages`는 release-handoff 전용( = whole-task)이다.
133
+ Run `outcome.persistActions[]` first, then pass each key of the `outcome.renderArgs` object as an `okstra render-bundle` flag. Pass empty string values explicitly too. Exception: the `chain-stages` key is not a render-bundle flag — it drives the Step 7 unattended-chaining loop, so do not pass it as a flag (`run.py` accepts only `--stage`/`--stages`). In the render-bundle block, `--stage` is implementation·final-verification only, and `--stages` is release-handoff only (empty value = whole-task).
134
134
 
135
135
  ```bash
136
136
  okstra render-bundle \
@@ -160,52 +160,52 @@ okstra render-bundle \
160
160
  --fix-cycle "<args.fix-cycle>"
161
161
  ```
162
162
 
163
- stdout에서 다음 labeled line을 파싱한다.
163
+ Parse the following labeled lines from stdout.
164
164
 
165
165
  - `okstra task root:`
166
166
  - `okstra instruction-set:`
167
- - 선택적으로 `okstra concurrent-run stages:`
167
+ - optionally `okstra concurrent-run stages:`
168
168
 
169
- render-bundle `prepare_task_bundle()`을 render-only 호출해 manifests, run context, instruction set, discovery files 준비하고 `~/.okstra/recent.jsonl`에 `prepared`로 등록한다.
169
+ render-bundle calls `prepare_task_bundle()` in render-only mode to prepare the manifests, run context, instruction set, and discovery files, and registers the run as `prepared` in `~/.okstra/recent.jsonl`.
170
170
 
171
171
  ## conformance waiver
172
172
 
173
- implementation에서 Tier 3 conformance 환경상 불가능할 때만 사용자에게 waiver를 제안한다. waiver 사용자 승인과 verbatim reason 있어야 한다. AI lead worker 자체 면제를 만들지 않는다.
173
+ Offer a waiver to the user only when Tier 3 conformance is genuinely impossible in the environment during implementation. A waiver requires user approval and a verbatim reason. Neither the AI lead nor a worker creates a self-exemption.
174
174
 
175
- 선택 `render-bundle`에만 추가한다.
175
+ When chosen, add it to `render-bundle` only.
176
176
 
177
177
  ```bash
178
178
  --qa-waiver "<stageKey>:<reason>"
179
179
  ```
180
180
 
181
- 값이 없으면 flag 자체를 생략한다.
181
+ Omit the flag entirely when there is no value.
182
182
 
183
- ## concurrent-run 분기
183
+ ## concurrent-run branch
184
184
 
185
- `render-bundle` stdout `okstra concurrent-run stages:`가 있으면 이미 no-team background gate prompt에 반영된 상태다.
185
+ If `render-bundle` stdout carries `okstra concurrent-run stages:`, the no-team background gate is already reflected in the prompt.
186
186
 
187
- 사용자에게 선택지를 준다.
187
+ Give the user three options.
188
188
 
189
- 1. no-team background로 진행.
190
- 2. 대기 — dispatch 보류, stage worktree·run context 보존. 점유 run 종료 같은 stage를 resume으로 재개하도록 resume 명령(`okstra-inspect` history → resume) 사용자에게 출력한다.
191
- 3. 직접 입력.
189
+ 1. Proceed as no-team background.
190
+ 2. Waithold the dispatch, preserve the stage worktree·run context. After the occupying run finishes, print the resume command (`okstra-inspect` history → resume) so the user can resume the same stage.
191
+ 3. Enter directly.
192
192
 
193
- picker 스킬이 만드는 것이므로 wizard option 축약 금지 규칙과 별개다.
193
+ This picker is authored by the skill, so it is separate from the wizard-option-abbreviation ban.
194
194
 
195
195
  ## stale git SHA recovery
196
196
 
197
- `Recorded stage SHAs no longer match the git history`류 `PrepareError`가 나오면 registry/consumers 수동 수정하지 않는다.
197
+ When a `PrepareError` such as `Recorded stage SHAs no longer match the git history` appears, do not fix the registry/consumers by hand.
198
198
 
199
- 1. 에러 메시지에 나온 `okstra git-reconcile ... --check --json`을 그대로 실행한다.
200
- 2. confirm 항목마다 사용자에게 current branch tip, 다른 ref, 중단을 묻는다.
201
- 3. 선택 ref로 `okstra git-reconcile ... --apply --stage <N> --use-ref <ref>`를 실행한다.
202
- 4. 실패했던 render-bundle 같은 인자로 재시도한다.
199
+ 1. Run the `okstra git-reconcile ... --check --json` printed in the error message verbatim.
200
+ 2. For each confirm item, ask the user for the current branch tip, a different ref, or abort.
201
+ 3. Run `okstra git-reconcile ... --apply --stage <N> --use-ref <ref>` with the chosen ref.
202
+ 4. Retry the failed render-bundle with the same arguments.
203
203
 
204
- anchor unresolvable이면 `--reset-anchor <ref>`는 사용자 확인 후 실행한다.
204
+ If the anchor is unresolvable, run `--reset-anchor <ref>` after user confirmation.
205
205
 
206
206
  ## PR template persistence
207
207
 
208
- release-handoff에서 `outcome.persistActions[]`가 `config.set` / `pr-template-path` action 반환하면 render-bundle 전에 config를 저장한다.
208
+ In release-handoff, when `outcome.persistActions[]` returns a `config.set` / `pr-template-path` action, save the config before render-bundle.
209
209
 
210
210
  ```bash
211
211
  # action.scope == "project"
@@ -214,40 +214,40 @@ okstra config set pr-template-path "<path>" --scope project
214
214
  okstra config set pr-template-path "<path>" --scope global
215
215
  ```
216
216
 
217
- scope path wizard state file이 아니라 `okstra wizard outcome`의 persist action에서 읽는다. raw state file 직접 읽지 않는다.
217
+ Read the scope and path from the persist action of `okstra wizard outcome`, not from the wizard state file. Do not read the raw state file directly.
218
218
 
219
- ## Claude lead 전환
219
+ ## Claude lead takeover
220
220
 
221
- render-bundle `<INSTRUCTION_SET_PATH>/claude-execution-prompt.md`를 verbatim으로 읽고, prompt 순서대로 Phase 1부터 진행한다.
221
+ After render-bundle, read `<INSTRUCTION_SET_PATH>/claude-execution-prompt.md` verbatim and proceed from Phase 1 in that prompt's order.
222
222
 
223
- 사용자에게 줄로 알린다.
223
+ Inform the user on one line.
224
224
 
225
225
  ```text
226
226
  Took over as Claude lead for `<taskKey>` (`<task-type>`). Run dir: `<RUN_DIR_RELATIVE_PATH>`. Beginning Phase 1 (context loading).
227
227
  ```
228
228
 
229
- 단일 원소 chain이면 Step 6 종료가 run 종료다. 아래 Step 7 `chain-stages` CSV 2 이상일 때만 적용된다.
229
+ For a single-element chain, the end of Step 6 is the end of the run. Step 7 below applies only when the `chain-stages` CSV has 2 or more elements.
230
230
 
231
- ## implementation 무인 연쇄 (chain-stages)
231
+ ## implementation unattended chaining (chain-stages)
232
232
 
233
- `task-type == implementation`이고 render-args `chain-stages` CSV 원소 2 이상이면, 현재 세션이 오케스트레이터로서 stage를 의존성 순서대로 무인 연쇄 실행한다. = `chain-stages`를 `,`로 분해한 위상정렬 stage 리스트. 큐의 stage `N`에 대해 순서대로:
233
+ When `task-type == implementation` and the render-args `chain-stages` CSV has 2 or more elements, the current session acts as the orchestrator and runs the stages as an unattended chain in dependency order. Queue = the topologically-sorted stage list from splitting `chain-stages` on `,`. For each stage `N` in the queue, in order:
234
234
 
235
- 1. render-bundle 같은 인자로, `--stage N`으로 재호출한다(base commit prepare predecessor done `head_commit`으로 자동 계산 손으로 넘기지 않는다). conformance waiver·concurrent-run·git-reconcile 게이트는 stage render-bundle마다 동일 적용.
236
- 2. Step 6대로 Claude lead 되어 stage Phase 1~7 인라인 실행한다. Phase 6 lead persistence `runs/<plan-task-key>/consumers.jsonl`에 stage `status:"done"` 행을 append한다.
237
- 3. `done` 기록을 확인한 다음 stage로 넘어간다. stage 경계마다 컨텍스트(잔여 pane·완료 teammate) 정리한다.
238
- 4. stage 시작/완료마다 보고: `stage N/<총개수> 시작` / `stage N done → 다음 K`.
235
+ 1. Re-call render-bundle with the same arguments but `--stage N` (the base commit is auto-computed by prepare from the predecessor's done `head_commit` do not pass it by hand). The conformance waiver·concurrent-run·git-reconcile gates apply identically to each stage's render-bundle.
236
+ 2. As in Step 6, become Claude lead and run that stage's Phase 17 inline. Phase 6's lead persistence appends that stage's `status:"done"` row to `runs/<plan-task-key>/consumers.jsonl`.
237
+ 3. After confirming the `done` row was written, move to the next stage. Clean up context (leftover panes·finished teammates) at each stage boundary.
238
+ 4. One-line report at each stage start/finish: `stage N/<total> start` / `stage N done → next K`.
239
239
 
240
- 큐를 모두 소화하면 연쇄를 종료하고 완료를 보고한다.
240
+ Once the whole queue is consumed, end the chain and report completion.
241
241
 
242
- - **다음 stage 아직 ready 아님 정상 종료:** 큐의 stage 다른 implementation run started/reserved 점유돼 render-bundle `--stage N already in progress or reserved by another run`(StageTargetError)으로 거부되면, 이는 예외가 아니다연쇄를 **정상 종료**하고 남은 큐를 보고한다(예: `남은 큐: stage 4, 5 — 점유 해제 okstra-run으로 재개`).
243
- - **연쇄 예외 게이트:** render-bundle concurrent-run 충돌이나 git stale-SHA 재조정을 띄우면 **그 stage에서 연쇄를 멈추고** 게이트를 Step 5 절차대로 사용자에게 제시한다. 사용자가 해소하면 자리에서 남은 큐를 이어 재개한다. 데이터 손상·동시 점유 충돌은 사람이 확인무인 연쇄의 안전 경계다.
242
+ - **Next stage not yet ready — normal termination:** When a stage in the queue is occupied by another implementation run as started/reserved and render-bundle is rejected with `--stage N already in progress or reserved by another run` (StageTargetError), this is not an exception **terminate the chain normally** and report the remaining queue (e.g. `remaining queue: stage 4, 5 — resume with okstra-run after occupancy is released`).
243
+ - **Exception gate during chaining:** If render-bundle raises a concurrent-run conflict or git stale-SHA reconciliation, **stop the chain at that stage** and present the gate to the user per the Step 5 procedure. Once the user resolves it, resume the remaining queue in place. Data corruption·concurrent-occupancy conflicts are confirmed by a human this is the safety boundary of unattended chaining.
244
244
 
245
- ## 금지 패턴
245
+ ## Forbidden patterns
246
246
 
247
- - wizard가 내준 질문 순서를 바꾸기.
248
- - wizard option을 숨기거나 추천만 남기기.
249
- - `text` prompt picker로 바꾸기.
250
- - empty answer에서 `--answer` flag 생략하기.
251
- - `okstra.sh`를 호출해 wizard/render-bundle 경로를 우회하기.
252
- - render-bundle 전에 사용자가 abort한 state render-args를 호출하기.
253
- - Claude lead prompt를 읽기 전에 phase 작업을 임의로 시작하기.
247
+ - Changing the question order the wizard emitted.
248
+ - Hiding wizard options or keeping only the recommendations.
249
+ - Turning a `text` prompt into a picker.
250
+ - Dropping the `--answer` flag on an empty answer.
251
+ - Bypassing the wizard/render-bundle path by calling `okstra.sh`.
252
+ - Calling render-args on a state the user aborted before render-bundle.
253
+ - Starting phase work arbitrarily before reading the Claude lead prompt.