Codex CLI 0.128.0 adds /goal

AI-generated summary of reporting by Simon Willison’s Weblog. Read the original for the full story.

Why it matters

Codex CLI users can now hand the agent an unattended long-running objective that it loops on until done or until a token budget runs out, competing with the Ralph loop pattern.

Read this as

OpenAI has updated its Codex CLI, a command-line tool where an AI writes and edits code for you, to version 0.128.0. The update adds a /goal command: you tell the tool an objective and it keeps working in a loop until it decides the goal is met or until it runs out of a set budget of tokens. This copies a popular do-it-yourself technique called the 'Ralph loop' that developers had been improvising themselves. It matters mainly to developers who use Codex and want the tool to keep grinding on a task without supervision.

OpenAI's Codex CLI 0.128.0 adds a /goal command that lets the coding agent loop autonomously on an objective until complete, capped by a configured token budget. This formalises the 'Ralph loop' pattern popularised by developer Geoffrey Huntley. Teams using coding agents gain hands-off execution of larger tasks, but should watch token spend, since the budget limit is the only circuit breaker. The article omits any usage pricing or benchmark data.

Codex CLI 0.128.0 implements /goal largely via two prompt templates in codex-rs/core/templates/goals, continuation.md and budget_limit.md, which are automatically injected at the end of a turn. The agent evaluates goal completion each turn and re-loops until satisfied or the token budget is exhausted, mirroring the Ralph loop pattern. The feature is thus prompt-driven rather than a new control-flow mechanism. Simon Willison notes no benchmarks or cost figures accompany the release.

Read the original

This summary exists to save you time, not to replace the source.

Key terms

Codex CLI OpenAI Ralph loop Simon Willison

Was this summary useful?

One click, anonymous. It tells us which summaries to re-run.

Related reading