Skip to content

Commit 8bc4bf3

Browse files
docs: clarify OpenCode orchestration positioning
1 parent b46650d commit 8bc4bf3

12 files changed

Lines changed: 412 additions & 17 deletions

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,8 @@ node_modules/
1212
.worktrees/
1313
dist/
1414
build/
15+
.codegraph/
16+
.seo-cache/
1517
.DS_Store
1618
.backup.*
1719
*.backup

README.md

Lines changed: 110 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -7,14 +7,24 @@
77
<a href="https://github.com/sponsors/jcarlosrodicio"><img src="https://img.shields.io/badge/Sponsor-GitHub%20Sponsors-ea4aaa?logo=githubsponsors&logoColor=white" alt="Sponsor on GitHub"></a>
88
</p>
99

10-
A reproducible product-development workflow for OpenCode.
10+
**An open-source multi-agent orchestration harness for OpenCode.**
1111

12-
Turn OpenCode into a structured team of specialized agents that can research, design, specify, implement, review, and validate software changes — without building every agent, command, skill, tool, and workflow convention from scratch.
12+
OpenCode Agent Orchestration Kit (OAK) turns OpenCode into a structured
13+
software-engineering team of specialized agents for research, design,
14+
specification, implementation, review, and validation. It keeps OpenCode agent
15+
orchestration local, inspectable, version-controlled, and reproducible.
1316

14-
Built for developers and small teams who want more structure than a single general-purpose coding agent, while keeping the setup local, inspectable, version-controlled, and adaptable.
17+
Unlike systems designed primarily around large parallel worker pools, OAK
18+
focuses on bounded engineering workflows with durable state, explicit
19+
handoffs, independent review, validation evidence, and optional human approval
20+
gates. It is model-agnostic within OpenCode: each role can use the default
21+
model or an explicit provider/model available in the user's OpenCode setup.
22+
23+
**Apache-2.0 · Local-first · OpenCode-native · Model-agnostic**
1524

1625
> [!NOTE]
17-
> This project is a configuration and workflow kit for OpenCode. It is not a hosted platform, a fully autonomous software factory, or a replacement for engineering judgment.
26+
> This software-engineering agent harness is not a hosted platform, a fully
27+
> autonomous software factory, or a replacement for engineering judgment.
1828
1929
## Why this exists
2030

@@ -61,6 +71,28 @@ The goal is not to force every request through a heavy process. Small, clear, lo
6171
| Optional token visibility | TUI plugin for lead and subagent token usage when OpenCode exposes session trees |
6272
| Versioned documentation | Agent, command, evidence, and validation contracts stored alongside the configuration |
6373

74+
### Bounded autonomous execution
75+
76+
OAK supports explicitly requested autonomous local work without turning it
77+
into unlimited or unattended execution:
78+
79+
- `/loop` requires an approved task contract before writes, allows at most
80+
three iterations per invocation within a task-specific one-to-six iteration
81+
budget, and can resume from durable state. Worktrees are explicit opt-in.
82+
- `/autonomous` is local-checkout-only, uses a task-specific one-to-six
83+
iteration budget, runs deterministic validation in every iteration, and
84+
stops as soon as an independent `reviewer` approves the result.
85+
- Both workflows use a schema-versioned JSON snapshot, append-only JSONL
86+
history, an exclusive lock, contract hashing, idempotent action IDs, and
87+
explicit recovery for interrupted writes.
88+
89+
The `/autonomous` contract prohibits network access, worktrees, parallel
90+
execution, scheduling, write-enabled connectors, commits, pushes, merges,
91+
deployments, releases, and publication. Sensitive or expanded scope stops for
92+
human review. See the [`/loop`](opencode/commands/loop.md) and
93+
[`/autonomous`](opencode/commands/autonomous.md) contracts for the exact
94+
boundaries.
95+
6496
## Built around
6597

6698
This kit builds on and integrates with the following projects:
@@ -93,6 +125,51 @@ This kit may not be the right fit if you:
93125
- Need autonomous parallel execution across many repositories or worktrees.
94126
- Expect every request to be fully automated without human oversight.
95127

128+
## How OAK compares
129+
130+
OpenCode orchestration projects optimize for different operating models. This
131+
summary describes their documented emphasis; it is not a universal ranking.
132+
133+
| Approach | Documented emphasis | Consider it when |
134+
|---|---|---|
135+
| **OAK** | Versioned software-engineering workflows, specialized phase roles, durable bounded loops, independent review, and local safety contracts | You want research → specification → implementation → review with explicit scope and evidence |
136+
| [`opencode-orchestrator`](https://github.com/agnusdei1207/opencode-orchestrator) | A persisted mission runtime with Commander, Planner, Worker, and Reviewer roles, local memory, and configurable agent concurrency | You want runtime-governed mission execution and a larger concurrent worker pool |
137+
| [`oh-my-openagent`](https://github.com/code-yeongyu/oh-my-openagent) | A broad multi-model agent harness with specialized agents, integrated tools, background agents, and opt-in parallel Team Mode | You want an extensive agent/tool ecosystem and optional parallel teams |
138+
| [`opencode-agent-tree`](https://github.com/beremaran/opencode-agent-tree) | A plugin that makes an orchestrator decompose and delegate every request, with hands-on tools blocked and configurable delegation depth | You want enforced delegation trees and parallel fan-out of independent subtasks |
139+
140+
### Choose OAK when
141+
142+
- You want OpenCode to behave like a structured engineering team.
143+
- You want research, specification, implementation, validation, and independent review to remain distinct.
144+
- You need durable, resumable workflows with explicit scope and acceptance criteria.
145+
- You prefer bounded autonomy and inspectable local contracts over unconstrained agent loops.
146+
147+
### Consider another orchestration approach when
148+
149+
- Your primary goal is maximizing parallel worker throughput.
150+
- You need autonomous execution across many worktrees or repositories.
151+
- You need a hosted orchestration or control-plane product.
152+
- You want an unattended software factory rather than bounded engineering workflows.
153+
154+
See [OpenCode Agent Orchestration Approaches](docs/comparison.md) for the
155+
comparison method, architectural distinctions, limitations, and source links.
156+
157+
## Engineering quality
158+
159+
OAK's reproducibility and safety claims are backed by checked repository
160+
artifacts rather than a maturity label:
161+
162+
- 1,000+ automated unit and script tests across the package and shipped harness.
163+
- Mechanical validation of agent, command, workflow, evidence, and routing contracts.
164+
- Type checking plus dependency vulnerability, integrity, and signature audits.
165+
- Isolated installation and exact-package smoke tests for the `oak` and `oc-switch` CLIs.
166+
- Compatibility checks across the declared OpenCode and Node.js boundaries.
167+
- Durable-state recovery, corruption, idempotency, and adversarial fixtures.
168+
- Public/private configuration boundary checks and release-provenance validation.
169+
170+
The [Validation](#validation) section explains the normal and release-grade
171+
checks and their limits.
172+
96173
## How it works
97174

98175
Free-form requests start with the `lead` agent.
@@ -316,7 +393,14 @@ From this checkout, run:
316393
npm run oc-switch
317394
```
318395

319-
To install the command globally with npm from the cloned checkout:
396+
To install the command globally from the published npm package:
397+
398+
```bash
399+
npm install --global opencode-agent-orchestration-kit
400+
oc-switch
401+
```
402+
403+
To install the current cloned checkout instead:
320404

321405
```bash
322406
npm install --global .
@@ -327,7 +411,7 @@ After a tagged release is published, you can install the same CLI directly
327411
from GitHub without keeping a checkout:
328412

329413
```bash
330-
npm install --global "git+https://github.com/jcarlosrodicio/opencode-agent-orchestration-kit.git#v1.0.41"
414+
npm install --global "git+https://github.com/jcarlosrodicio/opencode-agent-orchestration-kit.git#v1.0.42"
331415
oc-switch
332416
```
333417

@@ -382,9 +466,24 @@ Try one of these commands:
382466
/feature Add a small settings page with a saved theme preference
383467
```
384468

385-
## Install globally
469+
## Install from npm or a checkout
470+
471+
The published package can be installed directly from npm:
472+
473+
```bash
474+
npm install --global opencode-agent-orchestration-kit
475+
oak version
476+
oak install --dry-run
477+
oak install
478+
```
479+
480+
The npm install only places the `oak` and `oc-switch` commands on `PATH`. It
481+
has no install lifecycle script and does not modify OpenCode configuration
482+
until `oak install` is explicitly run. Previewing first preserves the same
483+
ownership, collision, and rollback rules as the shell wrappers.
386484

387-
Once you are happy with the workflow, preview and install it into your OpenCode configuration directory:
485+
From a cloned checkout, preview and install the harness into your OpenCode
486+
configuration directory:
388487

389488
```bash
390489
./install.sh --dry-run
@@ -741,7 +840,7 @@ Validate only the canonical identity and current release note with:
741840

742841
```bash
743842
npm run check:version
744-
node scripts/version.mjs --check-tag v1.0.41
843+
node scripts/version.mjs --check-tag v1.0.42
745844
```
746845

747846
Tag validation compares an explicitly supplied tag with the package identity.
@@ -919,6 +1018,7 @@ Detailed guides are available in [`docs/`](docs/):
9191018
- [Agents](docs/agents.md)
9201019
- [Commands](docs/commands.md)
9211020
- [Workflows](docs/workflows.md)
1021+
- [Comparison with other OpenCode orchestration approaches](docs/comparison.md)
9221022
- [Models](docs/models.md)
9231023
- [Open Design](docs/open-design.md)
9241024
- [Docker Open Design](docs/docker-open-design.md)
@@ -929,6 +1029,7 @@ Detailed guides are available in [`docs/`](docs/):
9291029
- [Reproducible use cases](docs/use-cases/README.md)
9301030
- [Troubleshooting](docs/troubleshooting.md)
9311031
- [Synology notes](docs/synology.md)
1032+
- [Awesome OpenCode submission draft](docs/distribution/awesome-opencode-submission.md)
9321033

9331034
## Compatibility and scope
9341035

docs/commands.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,8 @@
33
- `/feature`: full feature orchestration.
44
- `/plan`: research, implementation-ready spec, and reviewer pass with no implementation.
55
- `/scope`: research plus scoped spec, no implementation.
6+
- `/loop`: explicitly approved, resumable developer-review loop with durable state and bounded iterations.
7+
- `/autonomous`: explicitly requested local-only developer-review cycle with deterministic validation and a one-to-six iteration budget.
68
- `/mvp-spec`: strict MVP spec with small tasks and clear out of scope.
79
- `/design`: design via PRODUCT.md/DESIGN.md, optional Impeccable, and Open Design.
810
- `/research`: direct researcher task.

docs/comparison.md

Lines changed: 137 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,137 @@
1+
# OpenCode Agent Orchestration Approaches
2+
3+
OpenCode supports several forms of multi-agent orchestration. Some projects
4+
provide versioned engineering workflows, some add an autonomous mission
5+
runtime, and others enforce delegation or optimize parallel agent execution.
6+
The right choice depends on the control model a team needs.
7+
8+
This comparison was reviewed against public project documentation on
9+
2026-08-28. These projects evolve quickly; follow the linked sources before
10+
making a current feature decision.
11+
12+
## What OAK is
13+
14+
OpenCode Agent Orchestration Kit (OAK) is an open-source OpenCode orchestrator
15+
implemented as a local, inspectable configuration and workflow kit. It turns
16+
OpenCode into a software-engineering team with specialized research, design,
17+
specification, implementation, validation, and review roles.
18+
19+
OAK's primary abstraction is the engineering workflow. Phase contracts define
20+
who can act, what evidence is required, when a human decision is needed, and
21+
which agent has completion authority. The configuration, commands, skills,
22+
contracts, and durable state remain local and version-controlled.
23+
24+
## What OAK is not
25+
26+
OAK is not a hosted control plane, a general-purpose agent cloud, or an
27+
unattended software factory. It does not claim arbitrary parallel worker
28+
execution, implicit worktree orchestration, multi-repository autonomy,
29+
automatic merging, or unattended deployment.
30+
31+
Its bounded workflows deliberately constrain execution:
32+
33+
- `/loop` requires a human-approved contract before writes and allows a
34+
worktree only through explicit opt-in.
35+
- `/autonomous` is local-checkout-only and prohibits worktrees, parallelism,
36+
network access, write-enabled connectors, commits, pushes, merges,
37+
deployments, releases, and publication.
38+
- Both use finite iteration budgets, deterministic validation, durable state,
39+
and reviewer-only completion.
40+
41+
## Comparison table
42+
43+
| Project | Delivery form | Primary orchestration pattern | State and completion | Documented concurrency emphasis |
44+
|---|---|---|---|---|
45+
| **OAK** | Versioned OpenCode configuration, commands, skills, contracts, and CLI tools | Explicit software-engineering phases and handoffs | Schema-versioned loop state, append-only history, locks, contract hashes, recovery, and independent reviewer closure | Bounded loops are sequential; `/loop` permits only explicit worktree opt-in and `/autonomous` prohibits worktrees and parallelism |
46+
| [`agnusdei1207/opencode-orchestrator`](https://github.com/agnusdei1207/opencode-orchestrator) | OpenCode plugin and local runtime | Commander → Planner → Worker → Reviewer mission loop | Persisted missions under `.opencode/`, verification gates, a mission ledger, and local-first memory | Configurable concurrency for planner, worker, and reviewer roles; Rust tooling includes parallel execution primitives |
47+
| [`code-yeongyu/oh-my-openagent`](https://github.com/code-yeongyu/oh-my-openagent) | Multi-edition agent harness and plugin ecosystem | Main orchestrator delegates to planning, implementation, research, and review specialists | Plans and continuation mechanisms vary by mode; the project documents session recovery and persistent objectives | Background agents and opt-in Team Mode run specialized members in parallel |
48+
| [`beremaran/opencode-agent-tree`](https://github.com/beremaran/opencode-agent-tree) | OpenCode plugin | An orchestrator-only agent decomposes every request and delegates all hands-on work through a configurable tree | The orchestrator reviews subagent reports and delegates corrections; its hands-on tools are denied by configuration | Its directive encourages parallel fan-out for independent subtasks and supports configurable orchestration depth |
49+
50+
The rows describe documented architecture, not feature parity. For example,
51+
OAK's durable loop contract and `opencode-orchestrator`'s mission runtime both
52+
persist state, but they assign control and completion authority differently.
53+
54+
## OAK vs autonomous mission runtimes
55+
56+
An autonomous mission runtime owns the continuing execution loop. It can
57+
schedule or re-invoke roles until the runtime decides that verification is
58+
sufficient or escalation is required. This is useful when mission throughput
59+
and runtime control are primary requirements.
60+
61+
OAK instead makes the approved workflow contract the control boundary. Its
62+
bounded cycles use explicit iteration budgets and stop conditions, and only an
63+
independent reviewer can close the work. Use this approach when reproducible
64+
scope, evidence, and human-visible authority matter more than keeping a
65+
mission running unattended.
66+
67+
## OAK vs delegation trees
68+
69+
A delegation-tree plugin focuses on ensuring that an orchestrator decomposes
70+
work and never implements it directly. Deeper trees and parallel fan-out can
71+
increase specialization or throughput.
72+
73+
OAK can delegate among specialized roles, but its central concern is the
74+
meaning of each engineering phase: what the researcher must establish, what
75+
the specifier must make testable, what the developer may change, and what the
76+
reviewer must independently verify. Choose a delegation tree when enforced
77+
task decomposition is the primary requirement; choose OAK when explicit phase
78+
contracts and workflow evidence are the primary requirement.
79+
80+
## OAK vs large agent frameworks
81+
82+
Larger coding-agent frameworks may bundle broad tool suites, model routing,
83+
background agents, hooks, compatibility layers, and interactive team modes.
84+
That breadth is useful when one integrated agent environment is the goal.
85+
86+
OAK keeps the core OpenCode multi-agent workflow smaller and inspectable. It
87+
uses OpenCode's model/provider configuration and treats design tools,
88+
methodology plugins, and observability as optional integrations. The tradeoff
89+
is deliberate: OAK does not attempt to match every runtime or tool feature of
90+
a larger framework.
91+
92+
## Workflow orchestration vs worker-pool orchestration
93+
94+
Workflow orchestration organizes responsibility and evidence across stages:
95+
96+
```text
97+
research -> specification -> implementation -> validation -> independent review
98+
```
99+
100+
Worker-pool orchestration organizes execution capacity:
101+
102+
```text
103+
decompose -> dispatch independent workers -> collect results -> integrate
104+
```
105+
106+
The models can coexist, but they optimize different constraints. OAK focuses
107+
on the first model and limits parallel and unattended execution in its bounded
108+
flows to preserve explicit scope, review authority, and reproducibility.
109+
110+
## Choosing an OpenCode orchestration approach
111+
112+
Choose OAK when:
113+
114+
- You want multi-agent orchestration for OpenCode to follow explicit
115+
software-engineering contracts.
116+
- You need research, specification, implementation, and independent review to
117+
remain separate and auditable.
118+
- You need durable and resumable local state with finite execution budgets.
119+
- You want configuration and evidence to remain inspectable and
120+
version-controlled.
121+
122+
Consider a runtime-oriented or delegation-oriented approach when:
123+
124+
- Maximum parallel worker throughput is the main objective.
125+
- You need autonomous execution across many worktrees or repositories.
126+
- You want a broad bundled tool/model ecosystem or a hosted control plane.
127+
- You intentionally want an unattended mission runtime rather than bounded
128+
coding agent orchestration.
129+
130+
## Sources
131+
132+
- [OAK README](../README.md), [`/loop` contract](../opencode/commands/loop.md),
133+
and [`/autonomous` contract](../opencode/commands/autonomous.md)
134+
- [`opencode-orchestrator` README](https://github.com/agnusdei1207/opencode-orchestrator#readme)
135+
- [`oh-my-openagent` README](https://github.com/code-yeongyu/oh-my-openagent#readme)
136+
and [orchestration guide](https://github.com/code-yeongyu/oh-my-openagent/blob/dev/docs/guide/orchestration.md)
137+
- [`opencode-agent-tree` README](https://github.com/beremaran/opencode-agent-tree#readme)

0 commit comments

Comments
 (0)