Ever find yourself doing the same thing over and over with AI agents?
You construct the plan. You tell it to execute the plan, then you have another agent check the first agent's work. It finds issues, so you tell it to fix those issues. Any time a new blocker comes up, you ask it to troubleshoot the issue and fix it before moving on. You rinse and repeat until there's no more bugs and everything matches the initial plan.
All you did was manage which agent performs which role at which time. If you sketched out the entire process on paper, you'd find it's just a manually-driven decision tree. An agent can generally be relied upon to execute any single step on its own, but owning the entire workflow end to end? No agent is owning that reliably (yet). And this is where Millrace comes in.
flowchart TD
W["Workflow package<br/>stages, routes, rules"] --> C["Compiler<br/>validate and freeze"]
C --> P["Selected plan<br/>immutable authority"]
P --> R["Durable runtime<br/>queues, runs, waits"]
R -->|"bounded dispatch"| A["Agent runner<br/>Codex, Claude Code, Millforge"]
A -->|"candidate evidence"| V{"Valid under<br/>selected plan?"}
P -.->|"governs"| V
V -->|"yes"| T["Commit state transition"]
T --> R
V -->|"no"| X["Refuse, retry,<br/>or wait for operator"]
X --> R
If your workflow can be described as a decision tree, it can be turned into a plan by Millrace. Completion moves to the next step, failure moves to bugfixing, and a hard blocker escalates to automated recovery. You can have as many recovery mechanisms or branching paths as you like, and the compiler makes sure you're only running valid plans.
For more information, check out the FAQ.
Millrace is agent-first. Give this repository to a capable local agent:
Install Millrace for me in this workspace using https://github.com/tim-osterhus/millrace. Read its README and instruction manual first. Check the CLI, workspace, workflows, and runners. Report what you installed and what you need next. Do not store credentials in workflow assets or start unattended work.
Then delegate work:
Use Millrace to govern this work:
<goal and constraints>. Choose an official workflow, explain why, start with a bounded run, and report the selected plan, state, waits, and evidence.
Manual setup is documented in Getting started.
- The selected plan defines legal stages, routes, assets, runners, and outcomes.
- Queues, runs, waits, traces, and artifacts survive restarts.
- Each stage receives only its selected assets and context.
- Model output is evidence, not runtime truth.
- Retries, reroutes, pauses, and operator decisions remain on record.
- Supported commands change state; direct file edits do not.
millrace-plus provides:
simple_loop: plan, run, review, and bounded recovery;lean_agentic_development: full end-to-end autonomous agentic engineering;vendor_selection: policy checks, parallel evaluation, and an operator gate.
These are package data, not hard-coded kernel behavior.
Getting started · How Millrace works · Runner-session architecture · Daemon lifecycle · Workflow packages · Millforge runner · Codex runner · Errors · Migrating from v0.21 · v0.22 support
Millrace v0.22 is local and single-operator. It supports Linux, macOS, and WSL.