Codex self-imposed token budget on a /goal
What version of Codex CLI is running?
codex-cli 0.133.0
What subscription do you have?
Pro 20x
Which model were you using?
gpt-5.5 xhigh
What platform is your computer?
Darwin 24.4.0 arm64 arm
What terminal emulator and version are you using (if applicable)?
Codex App terminal
Codex doctor report
• codex doctor --json exited 1.
Key result: overallStatus: "fail" on codexVersion: "0.133.0".
Main failures/warnings:
- network.provider_reachability: fail
https://chatgpt.com/backend-api/ connect failed (required)
- network.websocket_reachability: warning
DNS lookup failed for wss://chatgpt.com/backend-api/<redacted>
- mcp.config: warning
Optional local MCP servers unreachable: vault, email, money, notes, code, trade on localhost ports 8089-8094.
- updates.status: warning
Latest version probe failed: curl: (6) Could not resolve host: api.github.com.
Everything else important looked okay: auth configured, config loads, install consistent, state DB integrity ok, sandbox readable.
What issue are you seeing?
Title
/goal can inherit a self-imposed token budget even when user did not request one
## Summary
During an Orion work session, Codex created an internal goal with a token budget that the user never requested. When that budget was reached, the system marked the goal budget_limited and
instructed the agent to stop substantive work.
This caused Codex to prematurely halt a long-running implementation task even though the user’s /goal prompt did not specify any token or time budget.
## What Happened
User started a goal with:
> Make Orion materially better as a message-first investment research agent...
No token budget was specified.
The assistant then called create_goal with:
```json
{
"objective": "...",
"token_budget": 180000
}
Later, the thread received goal context saying:
The active thread goal has reached its token budget.
Tokens used: 180402
Token budget: 180000
The assistant stopped work and summarized partial progress.
## Expected Behavior
Codex should not set a goal token budget unless the user explicitly requests one.
For open-ended /goal tasks, the goal should remain active until one of these happens:
- the objective is completed
- the user pauses/stops/cancels it
- the agent is genuinely blocked
- the system has a non-user-configurable hard limit, clearly labeled as such
## Actual Behavior
The assistant introduced a hidden/self-imposed token_budget value, which then became binding system behavior and interrupted the task.
## Impact
This is especially harmful for large implementation goals because:
- the user did not opt into the budget
- the assistant may stop before making code changes
- the user cannot easily tell whether the limit came from their prompt, repo config, or Codex internals
- it makes /goal feel unreliable for long-running engineering work
## Suggested Fix
- Do not allow agents to set token_budget in create_goal unless the user explicitly requested a token budget.
- Add validation or linting around create_goal calls:
- if token_budget is present, require evidence of a user-specified budget
- Make budget source visible in goal context:
- budget_source: user_explicit | system_default | assistant_inferred
- Provide a way for the user to clear or extend an accidental budget.
- Consider warning the assistant before creating a budgeted goal:
- “The user did not request a token budget. Omit token_budget?”
## Environment
- Codex CLI: 0.133.0
- Auth mode: ChatGPT
- Goal feature enabled
What steps can reproduce the bug?
Uploaded thread: 019e6572-a1ef-79a1-bbfe-46bcd4582484
What is the expected behavior?
Codex should not set a goal token budget unless the user explicitly requests one.
For open-ended /goal tasks, the goal should remain active until one of these happens:
- the objective is completed
- the user pauses/stops/cancels it
- the agent is genuinely blocked
- the system has a non-user-configurable hard limit, clearly labeled as such
Additional information
_No response_
This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗