v1.10.0 — goal loop (loop engineering / /goal)
Loop engineering comes to glue. Agent.PursueGoal turns one persistent objective into an autonomous loop — the /goal pattern (Codex, pi-goal), as a reusable library primitive.
How it works
- Plan — a planner decomposes the objective into a verifiable checklist.
- Maker — a fresh session (Ralph-style, seeded from the durable checklist so memory lives in state, not a growing transcript) works the open items.
- Checker — a separate session with its own model + verifier prompt audits each item against real evidence via structured output, and decides completion. The writer never grades its own homework.
- Decide — stop on
achieved,blocked(no progress),budget_limited, ormax_iterations.
Guardrails are first-class (MaxIterations, NoProgressLimit, TokenBudget); GoalSpec.Emit streams progress.
Built entirely on existing primitives (Session.Prompt, Session.PromptJSON, loop.Run/MaxTurns, Agent.Session) — no new dependencies.
This is Phase 1: the headless primitive. The TUI /goal command (Phase 2) and durable resume + branch isolation (Phase 3) follow. Designed in ADR-0016.
Verified
go build/vet/test ./... green; 7 tests cover every terminal status, the maker/checker call sequence, and event emission.
Full Changelog: v1.9.0...v1.10.0