DaydayupV/claude-foreman
About
A Claude Code plugin that makes Claude Code the foreman: it plans and reviews, and hands coding work to Codex, opencode, pi and other CLI agents.
Developer ToolsWhat you can do
- Claude Code guards quality. Every change an agent returns is reviewed diff-by-diff and verified with real test runs — anything short of the mark goes back for rework. Discussion points and review findings are verified against the source code, false positives are dropped, and decisions go by evidence rather than majority vote.
- Multiple models in one conversation. Bring models from different providers into the same Claude Code session to weigh designs or review changes in parallel — with topic-derived role assignments, round-2 cross-critique, and gap-finding seats for high-risk reviews.
- Spend your own quotas, save Claude's. Delegated coding, discussions, and reviews draw on your existing Codex plan, opencode / pi / Agy / CodeBuddy accounts, or API credits instead of your Claude Code allowance.
- Level 0–3 routing by difficulty and model strengths. Every step is levelled on judgement and risk: small edits stay with Claude Code, while larger pieces are routed using your config, scene routing, and personal "model notes" — with parallel splitting for large tasks.
Measured star growth
- in 24h
- 0
- in 7 days
- Collecting history
- in 15 days
- Collecting history
- in 1 month
- Collecting history
Net star changes over overlapping periods, not daily totals. Missing measurements are left blank. Stars measure attention, not software quality.
README.md
Originalclaude-foreman
Make Claude Code the foreman of every AI coding tool you use.
Claude Code plans the work and checks every result, while hands-on coding, multi-model discussions, and independent code reviews go to GPT, Gemini, DeepSeek, and more.

foreman is an open-source Claude Code plugin. It isn't a thin prompt router that passes tasks blindly to other models — it keeps Claude Code in the driver's seat. Claude Code plans, levels each step, checks every result, and makes the final calls; heavy coding, second opinions, independent reviews, and image generation go to Codex, opencode, pi, Agy, CodeBuddy, or any OpenAI-compatible API model, according to your config.
You keep talking to Claude Code as usual — no new commands to learn.
Features
- Claude Code guards quality. Every change an agent returns is reviewed diff-by-diff and verified with real test runs — anything short of the mark goes back for rework. Discussion points and review findings are verified against the source code, false positives are dropped, and decisions go by evidence rather than majority vote.
- Multiple models in one conversation. Bring models from different providers into the same Claude Code session to weigh designs or review changes in parallel — with topic-derived role assignments, round-2 cross-critique, and gap-finding seats for high-risk reviews.
- Spend your own quotas, save Claude's. Delegated coding, discussions, and reviews draw on your existing Codex plan, opencode / pi / Agy / CodeBuddy accounts, or API credits instead of your Claude Code allowance.
- Level 0–3 routing by difficulty and model strengths. Every step is levelled on judgement and risk: small edits stay with Claude Code, while larger pieces are routed using your config, scene routing, and personal "model notes" — with parallel splitting for large tasks.
- Control and safety boundaries stay with you. Seven configurable pause points decide when Claude Code stops to ask you; discussions and reviews are strictly read-only; hands-on execution is isolated by sandbox or explicit
edit/shelltiers, with an independent git snapshot tracking every change. - Full transparency + live visual board. Every handoff states the model, reasoning effort, and rationale; follow progress in a live split-pane terminal view or the real-time web board ("star map + single conversation"), complete with live speed, token usage, and estimated API cost.

Expand: Web board star-map view (live multi-conversation overview)
Every Claude Code conversation on your machine from the last 24 hours appears as a galaxy, with active agents orbiting in real time so you can monitor status, usage, and cost across every session at a glance.

How it works
Rather than forcing every request through a rigid pipeline, Claude Code breaks work into steps and enters whichever module fits next (Discuss, Run, and Review can combine and loop in any order — e.g. "Discuss → Run → Review → Discuss a design flaw found in review → Run again"):
Legend: Purple = Claude Code (planning / ruling / verification) | Green = External agents | Amber = Flow control & pause points
flowchart TD
User(["You: ask as usual<br/>No new commands to learn"]) --> CC["Claude Code (Foreman · In charge)<br/>Breaks work into steps & levels each (0–3)"]
CC -->|"Level 0 · DIY"| Self["Claude Code handles it<br/>No external model called"]
CC -->|"Levels 1–3 · Design"| D1
CC -->|"Levels 1–3 · Build"| R1
CC -->|"Levels 1–3 · Verify risk"| V1
subgraph Discuss ["① Discuss · Read-only"]
D1["Models propose independently<br/>L2–3: role mode & cross-critique"] --> D2["Claude Code rules on evidence<br/>Writes decision record"]
end
subgraph Run ["② Run · Guarded writes"]
R1["Delegated by config & strengths<br/>Supports parallel splits & images"] --> R2["Claude Code reads diff & runs tests<br/>Sends back if not right"]
R2 -.->|"Rework"| R1
end
subgraph Review ["③ Review · Fresh read-only session"]
V1["External models review fresh<br/>High-risk adds a gap seat"] --> V2["Claude Code verifies in source<br/>Drops false positives & fixes"]
end
Self --> Gate
D2 --> Gate
R2 --> Gate
V2 --> Gate
Gate{"More steps needed?<br/>(Pause points ask when configured)"}
Gate -->|"Next stage<br/>(Any order)"| CC
Gate -->|"All done"| Done(["Summary report<br/>Who did what · Checks · Tokens & cost"])
style Discuss fill:transparent,stroke:#94A3B8,stroke-dasharray: 4 3
style Run fill:transparent,stroke:#94A3B8,stroke-dasharray: 4 3
style Review fill:transparent,stroke:#94A3B8,stroke-dasharray: 4 3
classDef io fill:#E0F2FE,stroke:#0284C7,color:#0C4A6E,stroke-width:1.5px
classDef claude fill:#EDE9FE,stroke:#6D28D9,color:#2E1065,stroke-width:1.5px
classDef agent fill:#D1FAE5,stroke:#059669,color:#064E3B,stroke-width:1.5px
classDef gate fill:#FEF3C7,stroke:#D97706,color:#78350F,stroke-width:1.5px
class User,Done io
class CC,Self,D2,R2,V2 claude
class D1,R1,V1 agent
class Gate gate
Level 0–3 quick reference
Levelling is based on judgement and risk, not raw line count (renaming across 20 files from a list is Level 1; changing cross-module contracts or chasing an unknown root cause is Level 3):
| Level | Discuss (uncertainty & cost of a wrong call) | Run (judgement & design complexity) | Review (risk of the change) |
|---|---|---|---|
| Level 0 | Approach is clear or already decided → DIY | Single small edit, faster to make than brief → DIY | Docs, styling, small or low-risk tested changes → Check only |
Level 1 simple |
One-off question needing a second opinion | Settled method, little judgement needed | Large but mechanical edits |
Level 2 normal |
Several options to weigh, bounded impact | Clear spec, local details to design | Larger ordinary features and bug fixes |
Level 3 complex |
Complex, uncertain, costly to get wrong | Unknown root cause, cross-module, high stakes | Touches money, data, concurrency, auth, or security |
Which agents serve each level, how many seats join, who is required, and which levels stay with Claude Code are all defined in your config.
Expand: Detailed flows inside each module (including role mode & image pipeline)
① Discuss
flowchart TD
D0{"Level by uncertainty<br/>& cost of a wrong call"}
D0 -->|"Level 0"| DSelf["Claude Code decides directly"]
D0 -->|"Level 1 · simple"| D1["Ask 1 model for a second opinion"]
D0 -->|"Levels 2–3 · normal / complex"| DMode{"Choose discussion mode"}
DMode -->|"Normal mode"| DNorm["Same brief in parallel<br/>Independent proposals"]
DMode -->|"Role mode"| DRole["Derive roles from topic<br/>Assign seats by ability"] --> DCard["Each model proposes<br/>from its role's angle"]
D1 --> DDecide
DNorm --> DCross["When real disagreements exist<br/>Round 2 cross-critique"]
DCard --> DCross
DCross --> DDecide["Claude Code verifies evidence & rules<br/>(Decision record for multi-model talks)"]
classDef claude fill:#EDE9FE,stroke:#6D28D9,color:#2E1065,stroke-width:1.5px
classDef agent fill:#D1FAE5,stroke:#059669,color:#064E3B,stroke-width:1.5px
class D0,DSelf,DMode,DRole,DDecide claude
class D1,DNorm,DCard,DCross agent
② Run (code execution & image pipeline)
flowchart TD
R0{"Determine type of work"}
R0 -->|"Planning / checks / rulings"| RHost["Claude Code handles directly"]
R0 -->|"Code / scripts / UI / copy"| RLevel
R0 -->|"Illustrations / sprites / vectors"| IRoute
subgraph CodeFlow ["Code & general execution"]
RLevel{"Level by judgement<br/>& cost of mistakes"}
RLevel -->|"Level 0"| RZero["Claude Code edits directly"]
RLevel -->|"Levels 1–3"| RPick{"Pick from config<br/>using model notes"}
RPick -->|"Claude Code selected"| RZero
RPick -->|"Outside agent"| RRun["Hand off to agent<br/>Split in parallel if large"]
RRun --> RCheck["Claude Code reads diff<br/>& runs real verification"]
RCheck -.->|"Not right: 1 rework<br/>then Claude takes over"| RRun
end
subgraph ImgFlow ["Image pipeline (unlevelled)"]
IRoute["Pop-up lets you pick route<br/>Bitmap / Hybrid / Vector / Code"] --> IGen["Image module generates / draws<br/>(Final image approved before slicing)"]
IGen --> IAsset["assets removes bg, slices parts<br/>builds manifest & contact sheet"]
IAsset --> ICheck["Claude Code inspects sheet & captures<br/>Full playback check for animations"]
ICheck -.->|"Not right: adjust & redo<br/>Your call after 3 stalled tries"| IGen
end
style CodeFlow fill:transparent,stroke:#94A3B8,stroke-dasharray: 4 3
style ImgFlow fill:transparent,stroke:#94A3B8,stroke-dasharray: 4 3
classDef claude fill:#EDE9FE,stroke:#6D28D9,color:#2E1065,stroke-width:1.5px
classDef agent fill:#D1FAE5,stroke:#059669,color:#064E3B,stroke-width:1.5px
class R0,RHost,RLevel,RZero,RPick,RCheck,IRoute,IAsset,ICheck claude
class RRun,IGen agent
③ Review
flowchart LR
V0{"Level by change risk"}
V0 -->|"Level 0 (low risk)"| VSelf["Claude Code's check is enough<br/>No external review"]
V0 -->|"Levels 1–3"| VNew["Other models review in a fresh session<br/>Complex level adds a gap seat"]
VNew --> VFix["Claude Code verifies against source<br/>Drops false positives · fixes & re-tests"]
classDef claude fill:#EDE9FE,stroke:#6D28D9,color:#2E1065,stroke-width:1.5px
classDef agent fill:#D1FAE5,stroke:#059669,color:#064E3B,stroke-width:1.5px
class V0,VSelf,VFix claude
class VNew agent
See User guide · How it works for the full scheduling model, role mode, and scene routing.
Supported agents
| Agent | Discussions & reviews | Hands-on work | Notes |
|---|---|---|---|
| Codex CLI | ✅ read-only | ✅ sandboxed | Recommended; handles every task type and is the only agent for image generation |
| opencode 2.x | ✅ read-only | ✅ edit / shell |
Reaches models from many providers (including OpenCode Go) |
| pi | ✅ read-only | ✅ edit / shell |
Reaches models from many providers, with a project-scoped file guard |
| Agy CLI (Google Antigravity) | ✅ read-only | ✅ edit / shell |
Controlled via a global hook guard; verified on Windows 11 |
| CodeBuddy CLI | ✅ read-only | ✅ edit / shell |
Controlled via an injected guard hook; verified on Windows 11 with Git for Windows |
| OpenAI-compatible API | ✅ | — | DeepSeek, Kimi, GLM, Qwen, MiMo, and more (Claude Code attaches relevant files) |
You can configure multiple models of the same agent type; with no agents set up at all, the plugin still works and Claude Code handles everything itself.
Quick start
Requirements: Claude Code, Node.js 18+, Git 2.25+, plus any of the agents above installed and signed in.
1. Install the plugin
Since 1.4 there is a single plugin, foreman, with both English and Simplified Chinese built in (chosen during setup). Coming from foreman-en? See Upgrading to 1.4.
Claude desktop app (recommended): download
foreman.pluginfrom the latest release and upload it as a plugin (the live view opens automatically in the terminal panel after each handoff).Marketplace / Claude Code CLI:
/plugin marketplace add DaydayupV/claude-foreman /plugin install foreman@claude-foreman
2. Run the setup wizard
Run inside Claude Code:
/foreman:setup
It asks for your preferred language, scans the tools, models, and reasoning efforts available on your machine, generates a suggested config and model notes file, and lists every file you can edit yourself.
3. Work as usual
Talk to Claude Code the way you always do, for example:
"Add a date filter to the order export, and cover it with tests."
At each step it decides whether to discuss, delegate, or review, and reports who did what, how it was verified, and what it cost.
Whenever you want to invoke a step explicitly, you can also use /foreman:discuss, /foreman:run, /foreman:review, /foreman:watch, /foreman:status, and /foreman:config.
Documentation & resources
- Complete user guide (简体中文): agents, configuration, pause points, role-mode discussions, scene routing, model notes, image pipeline, web board, safety, and upgrading
- Release notes
- Intro video (Bilibili)
Contributing
Issues and pull requests are welcome.
Skill instructions are maintained in both English and Simplified Chinese under foreman/locales/: update both languages in the same pull request, and run the checks before sending it:
npm test
node tools/check-package.mjs
See Development in the user guide and tests/README.md.
License
Explore related projects
Loading…