Workflow
End-to-end flow
/orchestrator <task-id>
└─► architect ← design + ADR
└─► [human approves ADR]
└─► developer ← implement scoped FR
└─► architect (review)
└─► staff (optional deep analysis)
The Orchestrator runs the full Architect → Developer flow when the user explicitly requests design before implementation (e.g. "design and implement", "write an ADR then build it"). Step by step:
- Architect route — repo intel (hard gate, see below), design, and an ADR. After approval it writes
.tmp/<task-id>/handoff.json. - ADR approval gate — the Orchestrator presents the ADR URL and sub-task list, then stops and waits for an explicit
APPROVEDreply. On approval it recordsadr_approved_atin the handoff file. - Developer route — one Developer subagent per FR (asking before each). Developer implements only its assigned FR.
- Architect review — after each Developer run, the Architect is invoked in review mode with the PR URL and returns a verdict.
- Staff (optional) — deep cross-source analysis when requested.
The four slash commands that drive this flow are covered in Commands.
Hard gates
These are never bypassed:
- Repo intel before ADR.
architect-github-repo-intelmust complete before any ADR authoring — the language, framework, build tool, test framework, and layout must be confirmed from the actual repo, never guessed. - Human
APPROVEDbefore Developer. Per rules/approval-gate.md, work halts after the ADR is published until the human explicitly approves (anAPPROVEDreply in the session; the rule's documentation-status alternative is only available under opencode when a provider is bound to thedocumentationcategory). Architect must never write a handoff before approval; Orchestrator must never invoke Developer beforeadr_approved_atis present. - Developer halts without a handoff. Developer halts if
.tmp/<task-id>/handoff.jsonis missing oradr_urlis absent: "Developer halted:adr_urlis missing from handoff. ADR must be created and approved before implementation."
Branch naming
scripts/new-worktree.shgeneratesagent/<task-id>/<role>(e.g.agent/RTD-541/architect,agent/RTD-541/developer), appending-<timestamp>if the branch already exists.- Developer FR branches use
agent/<task-id>/<fr-label>(e.g.agent/RTD-541/fr1), taken from the handoff'ssub_tasks[].branch.