Run agent work as a flow you can check.
Orchy runs steps you define in a file. A step can run a command, ask an agent, or wait for a person.
Orchy checks the flow, starts each step when its needs pass, and records what each step did.
The first-run guide starts with one step and needs no model.
Define. Check. Run.
Start with one step. Add more when the work needs them. The same flow runs from the command line or the local page.
Write the flow.
Each step names its work and the value it must return.
Find a bad flow early.
orchy check reads the flow before a step starts.
Keep the record.
Orchy checks each result and writes the run state to disk.
Review can send the work back.
The code step writes a change. The review step reads it and returns a value. A failed review sends the work back.
# The same flow as flow.ts. A test keeps the two the same, because the API, a
# file, and a graphical editor must all produce one flow.
name: code-and-review
harness: claude
model: sonnet
steps:
- id: code
kind: agent
prompt: prompts/code.md
tools: [read, write, edit, grep, find, ls]
returns:
type: object
required: [summary, files]
properties:
summary: { type: string }
files:
type: array
items: { type: string }
- id: review
kind: agent
needs: [code]
prompt: prompts/review.md
tools: [read, grep, find, ls]
returns:
type: object
required: [approved, findings]
properties:
approved: { type: boolean }
findings:
type: array
items: { type: string }
cycle:
to: code
when: { approved: false }
limit: 3
policy: escalate
What happens on a failed review?
code → review → code again
Review waits for code. If review returns approved: false, the cycle sends the work back. The limit is three cycles. At the limit, a gate asks a person.
This flow needs the Claude command and a code workspace. Start with the model-free guide if you are new.
Open this flow on GitHub →