Supported harnesses
Patterm runs three agent CLIs, Claude Code, Codex and OpenCode, plus a raw terminal, and leaves each CLI's own login, permissions and resume behaviour in place.
A harness is the CLI Patterm hosts. Patterm does not call any model API itself. Every agent is the real CLI, running under your user account.
Summary##
| Harness | Command on PATH |
Presets | Resume |
|---|---|---|---|
| Claude Code | claude |
Yes | claude --resume <id> |
| Codex | codex |
Yes, including speed | codex resume <id> |
| OpenCode | opencode |
Yes | opencode --session <id> |
| Raw terminal | Your $SHELL |
No | Not resumable |
Both the TUI and Integrated interfaces work with Claude Code, Codex and OpenCode. The raw terminal has TUI only.
What you need installed##
Install each CLI you want separately and sign in to it, the same way you would outside Patterm. Patterm does not store or manage your CLI credentials.
Patterm finds a CLI by searching the PATH of the account running it for the commands above, then runs --version to confirm it works. If the Launch agent menu says No agent CLIs found on PATH, Patterm could not find any. In Settings › Harnesses, each CLI shows its version when it was found, or Not discovered.
Tip
If you run Patterm as a background service, the service has its own PATH, recorded when you installed it. Put the CLIs somewhere that PATH includes, and keep their logins available to the same account. See Linux server.
The raw terminal needs nothing. It starts your shell.
Models and presets##
Each CLI uses its own configured model unless you choose a preset. A preset is a name, a model, a reasoning effort and, for Codex, a speed. Add them in Settings › Harnesses. Discover models reads the model list from each installed CLI:
- Claude Code: the CLI's model list, falling back to aliases for the latest model in each family. Reasoning levels are
low,medium,high,xhighandmax. - Codex: the models Codex lists for its model picker, with their reasoning levels and speed tiers.
- OpenCode: the models its server offers, named
provider/model.
You can also enter a model ID by hand with Custom model ID…, which is how you use a model that is too new for the list.
The raw terminal has no model, so presets do not apply to it.
How resume works##
Every harness keeps its own conversation ID. Patterm records it and uses the CLI's native resume command, listed in the table above, when you resume a conversation.
A resumed conversation keeps the model it had, unless you choose a preset when resuming. See Resume behaviour for how to resume and what survives a restart.
How Patterm connects each CLI to its tools##
Each agent gets Patterm's MCP server, so it can use tools such as spawn_agent, report_to_parent and the todo and worktree tools. Patterm adds the server for each launch and leaves the CLI's own configuration alone. It does not edit ~/.claude.json, ~/.codex/config.toml or your OpenCode settings.
| Harness | How the launch gets Patterm's tools |
|---|---|
| Claude Code | A per-launch MCP config file in Patterm's own runtime directory, passed with --mcp-config. |
| Codex | Inline configuration overrides on the command line, using -c. |
| OpenCode | A registration with OpenCode's shared server for that session, made when the agent starts and not written to any config file. |
The same launch also gives the agent Patterm's startup instructions: through --append-system-prompt for Claude Code, developer_instructions for Codex, and the session API for OpenCode.
The MCP servers you add under Settings › MCP servers are delivered the same way, only to the harnesses you assign them to. Secrets such as tokens and headers never go on a command line, where ps would show them. Patterm passes them through helper commands that fetch them at run time. See Your MCP servers.
Permission prompts stay native##
Patterm does not add its own approval layer and does not auto-approve anything for you. Each CLI asks for permission the way it normally does:
- In TUI mode, you answer the CLI's own prompt in its terminal.
- In Integrated mode, the CLI's request appears as a card in the conversation, and your answer goes back to the CLI.
The agent's tab shows Needs permission while it waits. Routines have no permission setting of their own, so unattended runs keep the CLI's native prompts.
Note
Patterm starts Claude Code with --permission-mode auto, which is Claude Code's own mode. Anything that mode asks about still reaches you.
Notes for each CLI##
Claude Code##
Sign in with claude as you normally would. Each launch gets its own MCP config file, so agents started together keep separate identities.
Codex##
Codex keeps its own saved logins for MCP servers, and it uses those instead of the headers Patterm supplies. If Codex reports that an MCP server's login failed to refresh, remove Codex's saved login for that server and restart the agent. If it reports the server as not logged in, sign in to the server under Settings › MCP servers, then restart the agent. Patterm shows a notification that explains which applies.
OpenCode##
Patterm launches the native OpenCode terminal interface against OpenCode's shared background server. Before attaching, it creates or finds the session, adds its instructions, and registers its MCP bridge for that directory. Stopping or closing an agent, and a normal Patterm shutdown, interrupt the OpenCode sessions Patterm attached, but not the shared server or other OpenCode sessions. If Patterm crashes, check OpenCode for work still running before you resume.
If a launch fails because the shared server is older than the CLI, Patterm offers to restart the server and launch again. The restart interrupts any running OpenCode turns, so it only happens when you click it.
Patterm keeps a copy of OpenCode's cli.json for its terminal preferences. It merges in changes from your main OpenCode config, and settings you change inside Patterm win a conflict. Resuming needs the session to still exist in the OpenCode server.
Raw terminal##
The raw terminal starts your shell in the project with none of Patterm's tools. In the app it is offered as a process (New terminal in the command palette), not as an agent.