All examples are ordinary steps.yaml files. Read them before running them;
command nodes execute with your user permissions. Runs are written to
examples/runs/, which is gitignored—the demos never dirty the clone.
piw run examples/hello.steps.yaml --input Ada --strict --jsonpiw graph examples/branching.steps.yaml
piw run examples/branching.steps.yaml --input '! investigate outage' --strict --json
piw run examples/branching.steps.yaml --input 'write documentation' --strict --jsonThe urgent input runs escalate; the normal input records it as skipped.
The first run intentionally fails at a file-backed human checkpoint:
piw run examples/recovery.steps.yaml --input release --strict --json
mkdir -p examples/approvals
touch examples/approvals/continue.ok
piw resume examples/recovery.steps.yaml RUN_ID --jsonReplace RUN_ID with the run id from the first receipt. Remove the approval
file before repeating the demonstration. Both examples/runs/ and
examples/approvals/*.ok are gitignored, so the checkpoint demo leaves no
tracked changes behind.
Requires the claude and codex CLIs authenticated on PATH; both nodes may
incur provider cost:
piw run examples/any-agent.steps.yaml --input 'deterministic workflows' --strict --jsonEach agent writes one sentence; deterministic gates check both outputs, and a final command node combines them. Swap in any non-interactive agent CLI the same way.
This example requires Pi authentication and may incur provider cost:
piw run examples/agent-review.steps.yaml \
--input 'Review whether this migration has a rollback plan.' --strict --json