Agent Conductor ⚡
Run Codex CLI, OpenCode CLI and Claude Code simultaneously on the same project — frontend and backend in parallel, zero file conflicts.
pip install agent-conductor
agent-conductor "build a weather app: React frontend, FastAPI backend"
One command splits your goal into two independent workstreams, gives each agent its own isolated git worktree, runs both CLIs headlessly at the same time, and merges the work back.
Install
From PyPI (once published):
pip install agent-conductor
agent-conductor "build a todo app: React frontend, FastAPI backend"
From source:
git clone https://github.com/a18-n03/agent-conductor
cd agent-conductor
pip install -e .
cp .env.example .env # add ZEN_API_KEY (planner) + OMNIROUTE_API_KEY (codex via gateway)
Examples
# default: Codex + OpenCode
agent-conductor "build a todo app: React frontend, FastAPI backend"
# Codex (via OmniRoute, free) + ox-alpha (free) - the proven combo
agent-conductor "build a joke app: static HTML frontend, FastAPI backend" \
--agents "codex@omniroute/auto,opencode@opencode/x-preview-f-free"
# Claude + OpenCode
agent-conductor "landing page + contact API" \
--agents "claude@auto/best-coding,opencode@opencode/x-preview-f-free"
# custom project dir + timeout
agent-conductor "build a scraper + dashboard" --dir C:\dev\myproject --timeout 20
How it works
you: python agent-conductor "build a todo app: React frontend, FastAPI backend"
|
[1] LLM PLANNER (splits goal into 2 isolated workstreams)
|
┌─────────────────┴──────────────────┐
▼ ▼
[2] git worktree [2] git worktree
.conductor/codex-… .conductor/opencode-…
▼ ▼
[3] codex exec … [3] opencode run … (or claude -p …)
frontend/ (parallel) backend/ (parallel)
▼ ▼
└────────────► [4] MERGE ◄───────────┘
|
[5] REPORT (commits, timings, conflicts)
- Isolation: each agent works in its own git worktree + branch → it physically cannot touch the other agent's files
- Contract: the planner writes a shared interface contract (API endpoints/types) into both prompts so the two halves fit together
- Headless: uses
codex exec -C <dir> -s workspace-write,opencode run --dir <dir>andclaude -pwith per-agent model overrides - Merge: branches merged back to
mainautomatically; conflicts are aborted and reported
Requirements
- Python 3.10+
- At least TWO of these CLIs installed and authenticated:
- Codex CLI (
npm i -g @openai/codex) - OpenCode CLI (
npm i -g opencode-ai) - Claude Code (
npm i -g @anthropic-ai/claude-code)
- Codex CLI (
- An OpenAI-compatible API key for the planner (default: OpenCode Zen — free)
- Optional: OmniRoute (
npm i -g omniroute) — free gateway so any of the CLIs run on free models
Model setup (tested working)
| Agent spec | Routes to | Needs |
|---|---|---|
codex |
your ChatGPT plan via Codex | codex login |
codex@omniroute/auto |
OmniRoute gateway → free models | omniroute serve + OMNIROUTE_API_KEY in .env |
opencode |
OpenCode default model | opencode auth |
opencode@opencode/x-preview-f-free |
ox-alpha (free) | nothing |
opencode@opencode/glm-5 |
GLM-5 via OpenCode Zen | OpenCode Zen billing |
claude |
Claude Code default (Anthropic plan or ANTHROPIC_MODEL) |
claude login / env |
claude@auto/best-coding |
OmniRoute → free Claude routing | ANTHROPIC_BASE_URL + ANTHROPIC_AUTH_TOKEN env |
For the OmniRoute path, add this block once to ~/.codex/config.toml:
[model_providers.omniroute]
name = "OmniRoute"
base_url = "http://localhost:20128/v1"
wire_api = "responses"
env_key = "OMNIROUTE_API_KEY"
Usage
pip install -r requirements.txt
cp .env.example .env # add ZEN_API_KEY (planner) + OMNIROUTE_API_KEY (codex via gateway)
# ox-alpha frontend + ox-alpha backend (two free instances)
python conductor.py "build a joke app: static HTML frontend, FastAPI backend" \
--agents "opencode@opencode/x-preview-f-free,opencode@opencode/x-preview-f-free"
# Codex (via OmniRoute) frontend + ox-alpha backend
python conductor.py "build a joke app: static HTML frontend, FastAPI backend" \
--agents "codex@omniroute/auto,opencode@opencode/x-preview-f-free"
# default: your Codex plan + OpenCode default
python conductor.py "build a todo app"
What you get
CONDUCTOR REPORT
[OK ] codex frontend done (6.2 min)
[OK ] opencode backend done (4.8 min)
[OK ] merge conductor/codex-frontend merged
[OK ] merge conductor/opencode-backend merged
Full agent transcripts land in logs/ — every tool call both agents made.
Architecture
| Module | Role |
|---|---|
src/planner.py |
LLM splits goal into 2 file-disjoint workstreams with an interface contract |
src/worktrees.py |
git worktree + branch lifecycle, base commit handling |
src/runners.py |
Parallel headless runners (threads), live logs, per-agent timeouts |
src/merger.py |
Branch merging with conflict abort + final report |
Notes & limits
- Two agents is the sweet spot; more agents = more merge risk
- Agents can't see each other mid-run — that's a feature (isolation), the interface contract in their prompts is what keeps the halves compatible
- Conflicts are intentionally aborted, never auto-resolved — you decide
Proven result
Real run on this machine (2026-08-25): Codex (via OmniRoute, free models) built the frontend in 4.0 min while OpenCode (ox-alpha, free) built the backend in 0.7 min — in parallel, zero conflicts. Merged app passed a live endpoint test:
{"joke": "What does a cloud wear under its raincoat? Thunderwear."}
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file agent_conductor-0.2.0.tar.gz.
File metadata
- Download URL: agent_conductor-0.2.0.tar.gz
- Upload date:
- Size: 13.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via:
twine/7.0.0 CPython/3.13.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
7c2e5f4a774be9fa0d2c992652056e6d11c70c44e86b14d06e4b88cca918c0cf
|
|
| MD5 |
00f1899b60906799e36a54513d7ad4df
|
|
| BLAKE2b-256 |
8fc6687fd0d2db679e39df332e053c92319a38cf6b3545a741a309ee01bacd03
|
File details
Details for the file agent_conductor-0.2.0-py3-none-any.whl.
File metadata
- Download URL: agent_conductor-0.2.0-py3-none-any.whl
- Upload date:
- Size: 12.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via:
twine/7.0.0 CPython/3.13.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
45c4f5872619e1ae07e2006c31829a5f6c89568a818fef517fd6e7048456f87f
|
|
| MD5 |
38920fe4393b837d45dd68c83808fd8c
|
|
| BLAKE2b-256 |
e6a88bd61f9d571e7781fae050ccc683d34fc435d5d8b4bfddebb940c03e762e
|