Flows and gates
Steps a golem follows, and the points where it waits for your approval.
A flow is a list of steps a golem follows. A gate is a step that holds the golem until you approve it.
Flows you start with
| Flow | For |
|---|---|
| Standard task | The built-in flow, used when a workspace has no default |
| Change in a repo | A code change in its own worktree, tested, opened as a pull request |
| Research and write up | A question answered from sources and written up |
| Quick task | A small, clear job done and checked |
The last three are added by first-time setup. None of these four has a gate until you add one.
Use a flow
Pick it in "Flow" when you press "Launch Golem", or choose "None". On a running golem's card, use "Start flow" or "Change flow", and choose a starting step or "Let the golem decide". "Pause flow", "Resume flow" and "Open flow" are on the card too. To take a flow off, press "Change flow", then "Remove flow". The card shows the step the golem is on.
Make or change one
Open the Flows page. Use "New flow" or "New step", or "Edit", "Duplicate" and "Delete" on a row. A flow has a name, a description, an optional workspace and its steps in order. Flows share steps, so editing a step changes every flow that uses it. A golem already running keeps the version it started with.
| Step field | Use |
|---|---|
| What the step does | Instructions, One skill, Skills in order, Loop, or Gate |
| Instructions | What to do. For a gate, what you are approving |
| Done when | How the golem knows the step is finished |
| Warn after | Minutes before the step's time is highlighted. Empty means 30 |
| Check command | Optional. The step is done only when this command succeeds. Run from the golem's starting folder, it runs in the golem's worktree. Not for gates |
Add a gate
- Create a step and set "What the step does" to "Gate (the operator approves)". The operator is you.
- Say in "Instructions" what you want to approve.
- Add it to a flow where the golem should stop, such as before it pushes.
Answer a gate
The golem stops and its card shows the gate. It cannot approve its own gate.
| Where | Approve | Send back |
|---|---|---|
| The card | "Approve" | "Reject", then say what to change |
| Waiting on you | "Approve" | Type the reason and press "Send" |
| A terminal | gw flow <golem> approve |
gw flow <golem> reject --note "<what to change>" |
After a rejection the golem reworks the step and asks again. See Asks and approvals.
Go back or skip a step
A golem that has to redo earlier work, such as a follow-up pull request asked for after merge, moves back with gw step self <n> --reason "<why>". The reason is kept with the flow's history.
A golem can skip only a step it added to its own run. To skip one of the flow's own steps, such as the live check when you close a golem out before its merge, run gw steps <golem> --skip <n> --reason "<why>" yourself. The step shows as skipped, not done. Skipping a step behind or ahead of the golem leaves it where it is; skipping the step it is on moves it to the next one. A gate is never skipped: approve or reject it instead.
Share flows
gw flows export <file> saves your flows and gw flows import <file> adds them.