mvschwarz / openrig
mvschwarz / openrig
OpenRig A harness wraps a model. A rig wraps your harnesses. Define your agent team in YAML, boot it with one command. Claude Code and Codex in the same rig, managed as one system. OpenRig turns AI coding agents from a pile of terminal sessions into a persistent, organized team. Talk to a lead agent about the outcome you want; it can coordinate specialists across teams and bring you results and decisions that need your attention. Start with a repository and one useful change, then keep the team’s work and context at the same addresses.
OpenRig 是一个模型封装工具。Rig(装备)则将你的这些封装工具整合在一起。你只需在 YAML 中定义你的智能体团队,即可通过一条命令启动。它能将 Claude Code 和 Codex 整合在同一个 Rig 中,并作为统一系统进行管理。OpenRig 将 AI 编程智能体从一堆杂乱的终端会话转变为一个持久、有序的团队。你可以与首席智能体沟通你想要的结果;它能够协调各团队的专家,并为你提供需要关注的结果和决策。从一个代码仓库和一个有用的变更开始,让团队的工作和上下文始终保持在同一地址。
Install and first run
安装与首次运行
Requires Node.js 20, 22 or 24 and tmux. Launching a rig writes provider hooks and workspace trust settings. Before running the commands below, read what OpenRig changes on your machine and back up the relevant files.
需要 Node.js 20、22 或 24 以及 tmux。启动 Rig 会写入提供程序钩子(hooks)和工作区信任设置。在运行以下命令之前,请阅读 OpenRig 对你机器所做的更改,并备份相关文件。
npm install -g @openrig/cli
rig setup --dry-run
To install with Bun instead, run bun add -g @openrig/cli. OpenRig still runs on Node.js, so install Node.js 22 as well. Bun may block this package’s postinstall script, in which case the Node.js and SQLite check described under what OpenRig changes on your machine does not run at install time.
如果想改用 Bun 安装,请运行 bun add -g @openrig/cli。OpenRig 仍然运行在 Node.js 上,因此也请安装 Node.js 22。Bun 可能会阻止此包的安装后脚本(postinstall script),在这种情况下,“OpenRig 对你机器所做的更改”一节中描述的 Node.js 和 SQLite 检查将不会在安装时运行。
Review setup’s plan before applying rig setup: it checks both native harnesses and cmux. This starter requires tmux and authenticated Codex; the other harness and terminal provider are optional for its repository task. Before launching, ask your agent to configure your chosen permissions: keep prompts, remember selected commands, or deliberately choose broader access. The agent handles setup and verification; OpenRig’s shipped defaults stay unchanged.
在应用 rig setup 之前,请检查设置计划:它会检查原生封装工具和 cmux。此入门配置需要 tmux 和已认证的 Codex;对于其仓库任务而言,其他封装工具和终端提供程序是可选的。在启动之前,请让你的智能体配置你选择的权限:保留提示、记住选定的命令,或主动选择更广泛的访问权限。智能体负责处理设置和验证;OpenRig 提供的默认设置保持不变。
Check prerequisites in your launch shell: 在启动 shell 中检查先决条件:
tmux -V
codex --version
codex login status
Resolve missing tools or login before continuing. From your repository, inspect the plan before launching the two Codex seats, an owner and a checker: 在继续之前,请解决缺失的工具或登录问题。在你的仓库中,在启动两个 Codex 席位(一个负责人和一个检查员)之前,请检查计划:
cd /path/to/your/repository
rig up first-project --cwd . --plan
rig up first-project --cwd .
rig tui --shared
The kernel provides separate operational support and the shared dashboard. To detach without stopping the dashboard, press Ctrl-b then d; rig tui --shared returns to that view. Plain rig tui opens an independent view. Closing a viewing terminal does not mean you should relaunch the team. Check project-seat readiness with rig ps --nodes --rig first-project and resolve any authentication, trust or permission prompt before assigning work.
内核提供独立的操作支持和共享仪表板。要断开连接而不停止仪表板,请按 Ctrl-b 然后按 d;rig tui --shared 可返回该视图。普通的 rig tui 会打开一个独立的视图。关闭查看终端并不意味着你需要重新启动团队。请使用 rig ps --nodes --rig first-project 检查项目席位的就绪状态,并在分配工作前解决任何身份验证、信任或权限提示。
Then give the owner one bounded outcome from your repository: 然后给负责人一个来自你仓库的明确结果目标:
rig send dev-owner@first-project 'Implement <one useful change>. Track the task in the queue and return its ID. Keep it local, verify the behavior, ask dev-check@first-project to check the exact candidate, and record the result and how I can try it.'
rig queue list --destination dev-owner@first-project --limit 1000
Sending a message does not itself create a queue item; the owner records the task. Read the final artifact and the review of its exact candidate, then return to the same owner for the next change. The guided first-use path covers readiness, a useful task, a reviewed result, Herdr/cmux terminals and recovery.
发送消息本身不会创建队列项;负责人会记录任务。阅读最终产物及其候选版本的审查结果,然后返回给同一负责人进行下一次变更。引导式的首次使用路径涵盖了就绪状态、有用任务、审查结果、Herdr/cmux 终端和恢复。
What OpenRig changes on your machine
OpenRig 对你机器所做的更改
OpenRig writes instance state, provider integration and workspace files as part of setup and operation. These include trust settings and executable hooks. The summary below follows this source revision; check rig --version when using a published package, since repository guidance can be ahead of npm.
OpenRig 在设置和运行过程中会写入实例状态、提供程序集成和工作区文件。这些包括信任设置和可执行钩子。以下摘要基于此源代码版本;使用已发布的包时,请检查 rig --version,因为仓库指南可能领先于 npm 版本。
| When | What changes and why |
|---|---|
| 何时 | 更改内容及原因 |
| npm installation | Installs the CLI, bundled components and dependencies under your npm prefix (with Bun, under Bun’s global directory). OpenRig’s postinstall checks the Node.js version and that the SQLite module loads; Bun may block this script. It does not run daemon or provider setup. |
| npm 安装 | 在你的 npm 前缀下安装 CLI、捆绑组件和依赖项(使用 Bun 时,安装在 Bun 的全局目录下)。OpenRig 的安装后脚本会检查 Node.js 版本以及 SQLite 模块是否加载;Bun 可能会阻止此脚本。它不会运行守护进程或提供程序设置。 |
| rig setup | Attempts missing tools and writes an OpenRig block in ~/.tmux.conf for mouse support and scrollback. On macOS it can install cmux and enable its automation socket control in ~/.config/cmux/settings.json. —full adds workstation tools. —dry-run shows setup’s plan without applying it. |
| rig setup | 尝试安装缺失的工具,并在 ~/.tmux.conf 中写入一个 OpenRig 块以支持鼠标和回滚。在 macOS 上,它可以安装 cmux 并在 ~/.config/cmux/settings.json 中启用其自动化套接字控制。--full 会添加工作站工具。--dry-run 显示设置计划而不应用它。 |
| Daemon startup | Creates/updates instance state under OPENRIG_HOME (normally ~/.openrig), including its database and managed plugin resources. Seeds the openrig-skills discovery skill in ~/.claude/skills and ~/.agents/skills, subject to existing version ownership. With runtime.codex.hooks_enabled enabled (the default), writes Codex hook configuration and trust records as described below—even before a rig launches. |
| 守护进程启动 | 在 OPENRIG_HOME(通常为 ~/.openrig)下创建/更新实例状态,包括其数据库和托管插件资源。在 ~/.claude/skills 和 ~/.agents/skills 中植入 openrig-skills 发现技能(受现有版本所有权限制)。如果启用了 runtime.codex.hooks_enabled(默认),则会写入 Codex 钩子配置和信任记录(如下所述)——即使在 Rig 启动之前也是如此。 |
| Rig/seat launch | Creates tmux sessions, supplies seat identity and daemon connection environment, and projects selected guidance, skills, plugins and runtime resources into the workspace. Managed startup pre-trusts the workspace. Claude context collection can also be provisioned for attached sessions and refreshed during monitoring. |
| Rig/席位启动 | 创建 tmux 会话,提供席位身份和守护进程连接环境,并将选定的指南、技能、插件和运行时资源投影到工作区中。托管启动会预先信任工作区。Claude 上下文收集也可以为附加会话进行配置,并在监控期间刷新。 |