Workflow YAML Spec
Complete reference for every field in a Gump workflow file.Root fields
| Field | Type | Required | Description |
|---|---|---|---|
name | string | yes | Workflow identifier, used with --workflow |
description | string | no | Human-readable description |
max_budget | float | no | Maximum cost in USD for the entire run |
inputs | object | no | Declared inputs for sub-workflow composition |
steps | list | yes | Ordered list of steps |
Inputs (for sub-workflows)
| Field | Type | Description |
|---|---|---|
required | bool | Must be provided by the caller via with: |
default | string | Used if the caller doesn’t provide a value |
Agent step fields
A step with anagent field.
| Field | Type | Required | Description |
|---|---|---|---|
name | string | yes | Unique identifier within the workflow |
agent | string | yes | Agent to use (e.g., claude-sonnet, qwen, gemini) |
prompt | string or object | no | Prompt template. String for inline, file: path for external |
output | string | no | diff (default), plan, artifact, review |
context | list | no | Additional context: file: "path" or bash: "command" |
session | string | no | fresh (default), reuse, reuse-on-retry, reuse: <step> |
timeout | string | no | Kill after duration (e.g., "5m", "30s") |
max_budget | float | no | Cost limit in USD for this step |
hitl | bool | no | Pause for human review after execution |
guard | object | no | Live breakers during execution |
gate | list | no | Post-execution checks |
on_failure | object | no | Recovery strategy on gate/guard/review failure |
Gate step fields
A step withgate but no agent, steps, or workflow.
| Field | Type | Required | Description |
|---|---|---|---|
name | string | yes | Unique identifier |
gate | list | yes | Checks to run on the worktree |
on_failure | object | no | Recovery strategy |
Orchestration step fields
A step with childsteps.
| Field | Type | Required | Description |
|---|---|---|---|
name | string | yes | Unique identifier |
steps | list | yes | Child steps |
foreach | string | no | Name of a plan step to iterate over |
parallel | bool | no | Run items/steps concurrently |
workflow | string | no | Sub-workflow to call for each item (in foreach) |
gate | list | no | Post-group check |
on_failure | object | no | Group-level recovery |
Workflow step fields
A step withworkflow but no agent or steps.
| Field | Type | Required | Description |
|---|---|---|---|
name | string | yes | Unique identifier |
workflow | string | yes | Workflow to call |
with | object | no | Inputs passed to the sub-workflow |
Guard fields
| Field | Type | Description |
|---|---|---|
max_turns | int | Kill if turns exceed this count |
max_budget | float | Kill if step cost exceeds this (USD) |
no_write | bool | Kill if the agent writes files outside .gump/out/ |
no_write is implicitly true for output: plan, output: artifact, and output: review. Override with guard: { no_write: false }.
Gate values
| Value | Description |
|---|---|
compile | Run the compile command (auto-detected or from config) |
test | Run the test command |
lint | Run the lint command (skipped if not available) |
schema | Validate plan JSON output format |
tests_found | Verify the test runner finds tests |
"touched: glob" | At least one file matching the glob was modified |
"untouched: glob" | No file matching the glob was modified |
"coverage: N" | Test coverage meets or exceeds N% |
"bash: command" | Run a custom shell command. Exit 0 = pass |
on_failure fields
Simple form:| Field | Type | Description |
|---|---|---|
retry | int | Maximum additional attempts |
strategy | list | What to do on each attempt |
restart_from | string | Step to restart from (in the same group) |
same, "same: N" (shorthand for N repeats), "escalate: agent-name".
Conditional form:
gate_fail. Missing gate_fail = fatal.
Detection rules
Gump infers step type from fields present. Invalid combinations:| Combination | Result |
|---|---|
agent + steps | Error |
agent + workflow (without foreach) | Error |
workflow + steps (without foreach) | Error |
guard on a non-agent step | Error |
with without workflow | Error |