Harness support¶
A harness is the program around an Agent: it manages conversations, calls models, runs tools, and delivers new messages. Reins integration covers starting the harness as a child Agent and returning task results to its original conversation.
This page reflects the current main implementation and repository validation records, checked on 2026-10-12. The quickstart uses stable 0.7.0; newer integrations use the 0.7.1 preview.
Native integrations¶
| Harness / client | Child Agent | Results in the original conversation | Version and validation |
|---|---|---|---|
| Codex CLI | reins agent codex |
Bind through CODEX_THREAD_ID and resume through the CLI |
0.7.0; see the release and platform records below |
| Claude Code CLI | reins agent claude |
Background reins wait for live delivery; standalone CLI for session resume |
Child and CLI resume support from 0.7.0; live delivery in the 0.7.1 preview, verified on Linux/macOS |
| Claude desktop app, Code sessions | Child tasks use a signed-in standalone Claude CLI | Run reins wait through background Bash |
0.7.1 preview; verified with macOS local sessions and Linux SSH sessions |
| Pi | reins agent pi |
Extension sends a steer message to the live process; reins pi adds recovery after closing |
0.7.1 preview; recorded validation on Linux with Pi 0.87.1; macOS/Windows validation pending |
| DeepSeek Harness (DSH) | reins agent dsh |
Background reins wait runs as a DSH job; its completion notification wakes the same conversation; no headless resume |
Real sessions verified for submit, job notification and ACK on macOS desktop and Linux (dsh 0.2.1-rc.5, ACP and web UI); Windows not yet verified with a real DSH |
| Codex Desktop | Child tasks use Codex CLI | Start Desktop normally; auto selects the native codex queue |
Verified with macOS Desktop and real Codex on Linux; Windows Desktop pending |
You can combine child and receiving Agents. For example, reins agent claude in Codex runs the task with Claude and returns the result to Codex. Follow the Codex, Claude, Pi, or Desktop guide.
Claude also has a reins claude channel research preview. The repository records live receipt and ACK on Linux with Claude Code 2.1.296. See the channel setup.
Other harnesses and orchestration frameworks¶
| Name | Current integration route | Work for native integration |
|---|---|---|
| Gemini CLI, OpenCode, Aider, Goose | Run a configured command-line task through reins run -- <command> and return results to an existing receiver |
Implement child arguments, session detection, and callback transport; validate each end to end |
| LangGraph, AutoGen, CrewAI, custom Agent SDK programs | Save the workflow in a script and use reins run, or call reins done at the end of an existing job |
Implement a session adapter and wakeup channel for the receiving harness |
These frameworks currently use the generic command interface. The native adapter registry contains codex, claude, pi, and dsh. Begin with a script that prints a result and exits, check the log, callback, and ACK, then connect the actual workflow. See the custom workflow example.
Execution environments¶
| Environment | Task backend | Setup conditions |
|---|---|---|
| Linux | systemd user services, GNU screen | Desktop or server; screen is useful in containers and SSH environments |
| macOS | launchd, GNU screen | launchd uses the logged-in user's GUI session |
| Windows 10+ | Task Scheduler, Job Object | Keep the user logged in; use local NTFS storage for task state |
These task backends ship in 0.7.0. Configure the callback route for your chosen harness using the native integration table. Windows validation for Claude live callbacks is pending.
Add a harness¶
Start with harness/base.py and harness/registry.py:
- Implement child startup: locate the executable, build its command, pass the prompt, and choose file or standard-output result capture.
- Define session binding: read the session identifier and retain the profile and directory needed for recovery.
- Add delivery: construct a resume command for a closed session and a message channel for a running session.
- Register the adapter and add CLI selection, installation entry points, and a usage skill for that harness.
- Use an isolated session to validate submission, logs, results, receipt, and ACK. Check busy-session, exit, and retry behavior.
ChildAgentAdapter describes the child-task interface. AgentAdapter adds session detection and resume. Organizing the implementation around these interfaces lets you validate execution and delivery separately.