Skip to content

Commit d266845

Browse files
committed
Implemented color-type
1 parent 7e95a73 commit d266845

37 files changed

Lines changed: 2229 additions & 219 deletions

.opencode/agents/orchestrator.md

Lines changed: 23 additions & 69 deletions
Original file line numberDiff line numberDiff line change
@@ -184,12 +184,7 @@ spec-author → creates/updates spec.md → updates coordination.md
184184
↓ Ask questions to the human if added on coordination.md
185185
↓ Recall the spec-author with the answers.
186186
187-
spec-critic → creates/updates spec-critic.md → updates coordination.md
188-
↓ Ask questions to the human if added on coordination.md
189-
↓ Recall the spec-critic with the answers.
190-
↓ (gate: check coordination.md ## spec-critic)
191-
↓ Status == rejected? → loop to spec-author
192-
↓ Blocking issues unchecked? → loop to spec-author
187+
**human spec validation gate** — present the spec to the human, get explicit approval via question tool, record decision in coordination.md
193188
194189
implementation-contract-author → creates/updates implementation-contract.md → updates coordination.md
195190
↓ Ask questions to the human if added on coordination.md
@@ -201,21 +196,14 @@ implementation-contract-critic → creates/updates implementation-contract-criti
201196
↓ (gate: check coordination.md ## implementation-contract-critic)
202197
↓ Status == rejected? → loop to impl-contract-author (or spec-author for spec-level issues)
203198
↓ Blocking issues unchecked? → loop to appropriate agent
204-
↓ [Spec-level loop → spec-critic MUST re-review]
199+
↓ [Spec-level loop → spec-author MUST re-review]
205200
206201
**human validation gate** — present summaries from coordination.md, get explicit approval, record in ## Human Validation
207202
208203
code-implementer → implements code → updates coordination.md
209204
↓ Ask questions to the human if added on coordination.md
210205
↓ Recall the code-implementer with the answers.
211206
212-
code-reviewer → creates/updates code-review.md → updates coordination.md
213-
↓ Ask questions to the human if added on coordination.md
214-
↓ Recall the code-reviewer with the answers.
215-
↓ (gate: check coordination.md ## code-reviewer)
216-
↓ Status == rejected? → loop to code-implementer
217-
↓ Blocking issues unchecked? → loop to code-implementer
218-
219207
adr-agent (on-demand, if needed) → updates coordination.md
220208
↓ Ask questions to the human if added on coordination.md
221209
↓ Recall the adr-agent with the answers.
@@ -224,14 +212,7 @@ wiki-agent → updates coordination.md
224212
↓ Ask questions to the human if added on coordination.md
225213
↓ Recall the wiki-agent with the answers.
226214
227-
governance-reviewer → creates/updates governance-review.md → updates coordination.md
228-
↓ Ask questions to the human if added on coordination.md
229-
↓ Recall the governance-reviewer with the answers.
230-
↓ (gate: check coordination.md ## governance-reviewer)
231-
↓ Status == rejected? → loop to appropriate agent
232-
↓ Blocking issues unchecked? → loop to appropriate agent
233-
234-
when ever code is updated outside the normal workflow, restart the critics and following steps.
215+
when ever code is updated outside the normal workflow, restart the implementation-contract-critic and following steps.
235216
236217
orchestrator sets ## Orchestrator Status to "completed" → reports to human
237218
@@ -313,24 +294,27 @@ Gate (after spec-author reports completion):
313294
- Read coordination.md `## spec-author` section ONLY.
314295
- If **Status** is "blocked", resolve the blocker (ask human if needed).
315296
- If **Questions for human** is non-empty, ask human immediately using the `question` tool and record answer in coordination.md and then recall the spec-author.
316-
- If **Status** is "completed", proceed to spec-critic.
297+
- If **Status** is "completed", proceed to human spec validation.
317298
- Update `## Orchestrator`**Current step** to "spec-author-complete".
318299

319-
### 3. Spec critic
300+
### 3. Human spec validation
320301

321-
Ask `spec-critic` to review and create/update the spec-critic.md. Pass `SPEC_DIR` so the agent knows the target path.
302+
Present the completed spec to the human for explicit approval before proceeding to implementation contract authoring.
322303

323-
The spec-critic checks against the Definition of Ready (`docs/wiki/engineering/definition-of-ready.md`). Any unsatisfied criterion is a blocking issue.
304+
Use the `question` tool to show the spec summary and ask for approval.
324305

325-
Gate (after spec-critic reports completion):
326-
- Read coordination.md `## spec-critic` section ONLY.
327-
- If **Status** is "rejected" → loop back to spec-author (step 2).
328-
- If any unchecked `- [ ]` items under **Blocking issues** → loop back to spec-author (step 2).
329-
- If **Questions for human** is non-empty, ask human immediately using the `question` tool and record answer in coordination.md and re-invoke spec-critic or previous agent depending on the questions and answers.
330-
- When looping back: update `## Orchestrator` with loop note, set target agent's status to "in-progress" with context from blocking issues, re-invoke spec-author.
331-
- **Note:** This is the one exception to the rule that sub-agents self-manage their own status. The orchestrator may temporarily reset a sub-agent's `**Status**` to "in-progress" during loop-backs. This is documented in the coordination.md template constraints.
332-
- If gate passes, update `## Orchestrator`**Current step** to "spec-critic-approved".
333-
- Proceed to implementation-contract-author.
306+
Record the decision in coordination.md `## Orchestrator`**Notes**:
307+
- **Human spec validation**: approved / rejected / changes requested
308+
- **Date**: <date and time>
309+
- **Feedback**: any human feedback or conditions
310+
311+
If **approved**, update `## Orchestrator`**Current step** to "spec-approved" and proceed to implementation contract author.
312+
313+
If **changes requested**, loop back to spec-author (step 2) with the human's feedback.
314+
315+
If **rejected**, terminate workflow and report to human.
316+
317+
Use `date` command to get the current date and time.
334318

335319
### 4. Implementation contract author
336320

@@ -356,7 +340,7 @@ Gate:
356340
- Read coordination.md `## implementation-contract-critic` section ONLY.
357341
- If **Status** is "rejected" → loop back to implementation-contract-author (step 4).
358342
- If any unchecked `- [ ]` items under **Blocking issues**:
359-
- If the issue is a spec-level problem requiring spec.md changes → loop to spec-author (step 2). After spec-author fixes, orchestrator MUST invoke spec-critic to re-review the modified spec. If spec-critic accepts (coordination.md `## spec-critic` **Status** is `completed`), then proceed to implementation-contract-author (step 4). If spec-critic rejects, continue looping.
343+
- If the issue is a spec-level problem requiring spec.md changes → loop to spec-author (step 2). After spec-author fixes, proceed to human spec validation (step 3). If the human approves the updated spec, continue to implementation-contract-author (step 4). If the human requests changes, continue looping back to spec-author.
360344
- Otherwise → loop to implementation-contract-author (step 4).
361345
- If **Questions for human** is non-empty, ask human immediately using the `question` tool and record answer in coordination.md and re-invoke implementation-contract-critic or previous agent depending on the questions and answers.
362346
- When looping: update `## Orchestrator` with loop note, set target agent's status to "in-progress" with context.
@@ -400,21 +384,7 @@ Gate (after code-implementer reports completion):
400384
- If **Questions for human** is non-empty, ask human immediately using the `question` tool and record answer in coordination.md and re-invoke code-implementer or previous agent depending on the questions and answers.
401385
- Update `## Orchestrator`**Current step**.
402386

403-
### 8. Code review
404-
405-
Ask `code-reviewer` to review and create/update the code-review.md. Pass `SPEC_DIR` so the agent knows the target path.
406-
407-
Gate:
408-
- Read coordination.md `## code-reviewer` section ONLY.
409-
- If **Status** is "rejected" → loop back to code-implementer (step 7).
410-
- If any unchecked `- [ ]` items under **Blocking issues** → loop back to code-implementer (step 7).
411-
- If **Questions for human** is non-empty, ask human immediately using the `question` tool and record answer in coordination.md and re-invoke code-reviewer or previous agent depending on the questions and answers.
412-
- Always rerun code-reviewer after implementation modifications.
413-
- Be sure to analyze rendering and confirm functional display using `buddd capture` and vision analyze tool.
414-
- When looping: update `## Orchestrator` with loop note, set code-implementer status to "in-progress" with context.
415-
- If gate passes, update `## Orchestrator`**Current step**.
416-
417-
### 9. Governance update
387+
### 8. Governance update
418388

419389
If the orchestrator decides an ADR is needed, invoke `adr-agent` on-demand by delegating to it.
420390
The `adr-agent` is an on-demand tool, not a mandatory workflow step.
@@ -425,7 +395,7 @@ After `adr-agent` reports completion:
425395
- Check **Blocking issues**: if present, resolve.
426396
- Update `## Orchestrator`**Current step**.
427397

428-
### 10. Wiki update
398+
### 9. Wiki update
429399

430400
Ask `wiki-agent` to update the wiki content.
431401

@@ -435,20 +405,7 @@ Gate:
435405
- If **Questions for human** is non-empty, ask human immediately using the `question` tool and record answer in coordination.md and re-invoke wiki-agent or previous agent depending on the questions and answers.
436406
- Update `## Orchestrator`**Current step**.
437407

438-
### 11. Final governance validation
439-
440-
Ask `governance-reviewer` for cross-document validation.
441-
442-
Gate:
443-
- Read coordination.md `## governance-reviewer` section ONLY.
444-
- If **Status** is "rejected" → resolve issues through the appropriate agent.
445-
- If any unchecked `- [ ]` items under **Blocking issues** → resolve issues through the appropriate agent.
446-
- If **Questions for human** is non-empty, ask human immediately using the `question` tool and record answer in coordination.md and re-invoke governance-reviewer or previous agent depending on the questions and answers.
447-
- Always rerun governance-reviewer after modifications.
448-
- When looping: update `## Orchestrator` with loop note, set target agent's status to "in-progress" with context.
449-
- If gate passes, update `## Orchestrator`**Current step**.
450-
451-
### 12. Done
408+
### 10. Done
452409

453410
Set `## Orchestrator`**Status** to "completed".
454411

@@ -470,11 +427,8 @@ All artifacts stay in `SPEC_DIR` (e.g. `.specs/sprint-2026-06/<feature>/`). No f
470427
- Never edit production code yourself.
471428
- Never allow implementation from a raw user request.
472429
- Never allow implementation from a spec alone.
473-
- Never skip the spec critic.
474430
- Never skip the implementation contract critic.
475431
- Never skip human validation before implementation.
476-
- Never skip the code reviewer.
477-
- Never skip the governance reviewer.
478432
- Never silently resolve critic or reviewer questions.
479433
- Never ask the scout for repository dumps in normal mode.
480434
- Never create or update ADR yourself, ask `adr-agent`.

0 commit comments

Comments
 (0)