openrig — multi-agent Claude Code/Codex orchestration
OpenRig is an open-source local daemon, CLI, TUI and MCP server (built on tmux + SQLite) that manages teams of Claude Code and Codex agent sessions as a single persistent system rather than a pile of terminal windows. Topologies (pods, seats, edges) are defined declaratively in YAML (RigSpec/AgentSpec), booted with `rig up`, inspected via a topology TUI, and can be snapshotted/restored, discovered from existing tmux sessions, and messaged across agents (`rig send`, `rig broadcast`, `rig chatroom`). It ships starter topologies (first-project, conveyor, product-team, secrets-manager using HashiCorp Vault) and documents in detail what it writes to Claude/Codex config, trust and telemetry state on the host machine.
What it claims
OpenRig manages a team of Claude Code and Codex sessions as one system. Each agent is a seat: a stable address such as dev-owner@first-project. The conversation in a seat can change while its identity and authored context stay. You talk to a lead or owner seat, which coordinates other seats and records work in a queue. The project is Apache 2.0 and self-hosted. You still pay the selected providers' model usage, but you need no second subscription. You only need an account for the provider you pick.
How it works
- Stack: a CLI, TUI and MCP server sit on a Hono HTTP daemon, which sits on SQLite, tmux and runtime adapters.
- Runtimes: native Claude Code and Codex sessions, plain terminal nodes, and a Pi adapter that runs an RPC runner inside a terminal pane.
- Kernel: a separate rig that starts automatically. It runs the shared dashboard and picks its provider from whichever authenticated providers are available.
- Context: pods share guidance, but each agent keeps its own context window.
CULTURE.mdsets coordination norms for a rig: exploratory for research rigs, conservative "trust-but-verify" for implementation rigs. - Sharing: RigBundles are portable archives with vendored AgentSpecs and SHA-256 integrity checks.
- Restore: results are reported per node as resumed, fresh or failed.
- Typing guard:
rig seat set-typing-guardholds automatic messages for a seat you type into by hand. It is off by default. - Slack: experimental, through an app you create in your own workspace.
Permission policy decides how agents are launched:
flowchart LR P[Seat permission policy] -->|default floor| D[Claude: acceptEdits<br/>Codex: -s workspace-write] P -->|explicit full_bypass| Y[Claude: --dangerously-skip-permissions<br/>Codex: danger-full-access -a never] E[OPENRIG_YOLO=1 legacy] -->|Codex sandbox only| Y P -.resolved policy overrides env.-> E
Fresh Codex launches also get --add-dir write access to the workspace's .git and to the shared queue-state directory (~/.openrig/shared-docs by default).
How to use it
Requirements:
- Node.js 22 or 24. Node 20 is refused, Node 26 is untested, and Apple silicon should use Node 22.
- tmux.
- macOS or Linux.
- Docker, only for service-backed rigs such as
secrets-manager. - herdr or cmux, optionally, for side-by-side terminal views.
npm install -g @openrig/cli
rig setup --dry-runFirst run, inside your repository:
cd /path/to/your/repository
starter=first-project # or first-project-claude or first-project-mixed
rig specs preview "$starter" --kind rig
rig up "$starter" --cwd . --plan
rig up "$starter" --cwd .
rig tui --sharedCheck that seats are ready with rig ps --nodes --rig "$starter", then hand the owner one task with rig send "dev-owner@$starter" '...'. Sending a message does not create a queue item; the owner agent records the task. rig doctor diagnoses problems after setup, and both rig setup and rig doctor support --json.
Starter rigs:
| Starter | Shape |
|---|---|
first-project | Two seats, owner and checker |
conveyor | Four seats: intake, planning, build, review |
product-team | Two orchestrators, implementation, QA, design, two reviewers |
implementation-pair, adversarial-review and research-team also ship.
Limits
Host writes:
- Claude: writes workspace trust and onboarding state to
~/.claude.json. Writes hooks and astatusLineto.claude/settings.local.json. The shared settings resource setspermissions.defaultModetoacceptEditsand enables the Exa and Context7 MCP entries. - Codex: edits
~/.codex/config.tomlto enable hooks, pre-trust its relay commands and settrust_level = "trusted"for the workspace. - Relocation:
OPENRIG_HOMEdoes not isolate any of this, and a customCLAUDE_CONFIG_DIRdoes not fully relocate the trust writes. - Overwrites: an existing Claude status-line command, trust entries and selected resource keys can be replaced. Unreadable settings files may be reset to empty objects.
- No full safeguards: the project says there is no full preservation or rollback guarantee, and
--dry-rundoes not preview every later startup effect. Back up these files first.
Data flows:
- Activity relays send event types, seat identity, timestamps and session IDs to the local daemon. They do not send prompt text or tool arguments.
- The Claude collector records token usage, transcript paths and rate-limit data.
- The daemon checks a GitHub release endpoint.
Platform and enforcement:
- Native Windows is unsupported and WSL2 is untested.
- Adopted sessions that are already running may need a restart before they pick up new config.
rig seat statusshows the desired and last-launched permission settings. The project states that neither proves the setting is actually enforced.
Upgrades:
- Do not use
rig downas an upgrade step. - Instances older than 0.5.9 need a multi-phase telemetry migration script with explicit plan, apply, verify, finalize and rollback steps.
- The older React web UI is in maintenance mode only.
- Repository docs can be ahead of the npm package, so check
rig --version.
Organisations named here
- HashiCorp
- GitHub
- Claude Code
Technologies named here
- OpenRig
- Claude Code
- Codex
- tmux
- herdr
- cmux
- HashiCorp Vault
- Exa
- Context7
- SQLite
- Hono
- Docker
- Bun
- Node.js
- Model Context Protocol
- React
- pi
Techniques named here
- RigSpec
- AgentSpec
- Seat
- Pod
- Discovery/Adoption
- Snapshot/Restore
- RigBundle
- Culture
- Agent-Operated Migration
Related in coding-agents
