Replies: 2 comments
|
Quick update on the ship-now bugfix from the original post — it's now implemented and merged on our fork ( What it does, independent of the larger proposal:
It stands entirely on its own — happy to open it as a standalone PR here whenever you'd like, separate from the bridge proposal. Still very interested in your read on questions 1–3 above (especially: is the terminal-dispatch-in-one-worktree model intentional, and do you want the two systems unified?) before we invest in the larger change. We're prototyping the bridge on the fork and can bring a working demo. |
|
Update — this is now built and up for review as #6293. Rather than wait on direction for the bridge, we built the unified version on our fork and have opened it as a single, cohesive PR: #6293. It implements items 1–5 from the proposal (coordinator-created worktrees with director lineage, Mission Control reading the live DAG, coordinator resume-on-boot, the renderer→main One deliberate divergence from the proposal: we dropped the token-free recipe director (Question 3). In practice the director is a small fraction of a run's tokens, so the determinism argument didn't justify a second backend — the shipped version is recipe-free, LLM-director only. The only residual Happy to take direction on the open questions directly on the PR. Closing this out as resolved. |
Uh oh!
There was an error while loading. Please reload this page.
Status: design proposal + a standalone bugfix, prototyped on a fork behind
experimentalOrchestrators. Seeking direction before investing in the larger change.TL;DR
Orca currently has two orchestration systems that share a name but don't compose:
orchestrator-launch.ts,OrchestratorMissionControl.tsx): a hidden worktree runs a Claude session that plans work and creates child worktrees per PR-track. Mission Control discovers workers purely by worktree lineage and reads.orcastrate/log.jsonl. It never calls the orchestration backend.src/main/runtime/orchestration/): a main-process coordinator runs a SQLite task DAG and dispatches tasks to terminals inside a single worktree. It never creates worktrees, and nothing in the Orcastrator UI reads its DB (OrchestratorMissionControl.tsxeven comments "no orchestration RPC yet").We'd like to unify them so the coordinator can drive worktree-based workers that Mission Control can see — which unlocks a live DAG "Control Panel" and an optional token-free "recipe" director. Before we build that, a few questions for maintainers (below), and one bugfix we'd send regardless.
Ship-now bugfix (independent of the proposal)
Multiple coordinators sharing one orchestration DB poach each other's work. The orchestration DB is a single global namespace:
tasks,dispatch_contexts,messages,decision_gateshave no run scoping, the coordinator handle defaults to the literal'coordinator', and run-start (getActiveCoordinatorRun→createCoordinatorRuninorchestration-gates.ts) is a TOCTOU race. Two coordinators consume each other'sworker_donemessages (silent hang) and trip the per-assignee dispatch guard ("already working on the same thing").Fix: per-run isolation (per-run DB file or
coordinator_run_idon all run-scoped tables) + per-run coordinator handle + atomic run-start. We have this in progress on our fork and would send it as its own PR, independent of the proposal below.The proposal (the part we want direction on)
Make the Orcastrator a director with two backends over the same coordinator/DAG:
Both feed one Control Panel that renders the live DAG using Orca's existing visual vocabulary (
WorkspaceCard/AgentRow/AgentStateDot).Required changes, all of which appear additive/targeted:
createWorktreetoCoordinatorRuntime, implemented onOrcaRuntimeServiceby wrapping the existingaddWorktree(src/main/git/worktree.ts). Workers run in their own worktrees with lineage parent = director, so Mission Control sees them.listTasksWithDispatch(already exists indb.ts) instead of pure lineage.coordinator_runs WHERE status='running'— today the loop is in-memory with no resume (fine while a human-driven agent re-issuesrun, but not for a headless director).orchestration.runbinding (today CLI-only).Questions for maintainers
CoordinatorRuntime.createWorktree?Happy to build it on a fork and bring a working demo — we'd just rather align on (1)–(3) before investing in the bridge.
All reactions