Basics
stdout. Progress messages go to stderr so piping stays clean.
Useful flags
| Flag | What it does |
|---|---|
--model <id> | Override the default model |
--max-steps <n> | Stop after N steps |
--timeout <ms> | Kill after N ms |
--system "..." | Add custom system instructions |
--include <file> | Pre-load a file into context (repeatable) |
--no-repomap | Skip the startup scan (faster for quick questions) |
--diff | List files changed after the run |
--save-session | Save conversation so you can resume later |
--session <id> | Resume a saved session |
--chat | Interactive multi-turn chat |
--quiet | Suppress stderr progress |
0 success, 1 error, 2 timeout, 130 abort.
CI example
Resume a session
Parse events
start, text, tool-call, tool-result, step, error, done, session-saved.
What’s disabled
- TUI, editor panel, splash screen.
- Interactive approvals — destructive actions auto-allow in headless mode.
- User steering — no stdin during the run.
Security in CI
SetSOULFORGE_NO_REPOMAP=1 to skip the startup scan on tiny CI jobs. Store API keys as CI secrets. Use --max-steps and --timeout to cap runaway runs.
