cmux pi orchestration
Owner controls immutable SPEC.json, atomic STATE.json, per-attempt exchange, routes, and acceptance under $HOME/.cmux-pi-orchestration/. Worktrees contain project code only.
References
Read contract, artifact store, and route profile; after selecting cmux, read runbook and live cmux <group> --help.
Gates
Non-trivial work requires accepted $kickoff; trivial work needs ledger skip_reason. Use SKILL.state: immutable P, current Σt, latest ot. Pin digest/base; reject unresolved, stale, untraceable, or mismatched input. Workers cannot amend P; invalidation reopens Kickoff.
SSH_CONNECTION or SSH_TTY means cmux is client-local while work is remote. Worker tabs MUST SSH to the exact live-derived host and canonical worktree. Failed non-interactive directory/HEAD proof disables cmux dispatch.
Resolve task → project role → user role → allowed default. Require exact alias, auth, and runtime identity. Billing/no-fallback proof applies only when requested. Human approval remains mandatory for permission expansion and destructive, production, or irreversible actions.
Execute
Invariant: P + Σt + ot → validate → atomic Σt+1 → archive ot.
- Prove cmux/cwd; create central run with
SPEC.jsonandSTATE.jsonrecording main worktree. - Create worker worktree/tab; atomically add attempt, worktree, route, surface, and cleanup facts to
STATE.json. - Dispatch central
TASK.md; worker publishes centralREPORT.mdthenDONE. - Fresh-audit central files plus live Git/cmux, required checks, scope, route, base, HEAD, and state version.
- Create verified
candidate.bundle; checksum attempt evidence; atomically replaceSTATE.json. - Re-evaluate DAG; close/remove exact runtime resources and record cleanup in
STATE.json.
Never append old observations/reasoning. Central SPEC.json/STATE.json and live runtime beat prose, titles, refs, and memory. Workers cannot promote or widen scope. Restart from these minimal files plus live Git/cmux—not transcripts.