You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Thread goal updates are flattened to agent message text; expose structured goal state #260
codex emits structured thread-goal events, but codex-acp forwards them only as free-text agent_message_chunks, so ACP clients can't consume the goal's structured state (status/objective/token budget) — they'd have to regex the prose.
Details
codex 0.142 emits:
thread/goal/updated — goal = { objective, status, tokenBudget }, where status is active | paused | budgetLimited | blocked | usageLimited | complete
thread/goal/cleared
In src/CodexEventHandler.ts, these map to text-only updates:
The structured status enum and tokenBudget are dropped. Notably, other thread metadata (name, status, archived) is exposed structurally via createCodexSessionInfoUpdate → session_info_update with _meta.codex. Goal state is the odd one out.
Impact
A client can't reliably detect goal start (active) / end (complete) / clear, or surface the token budget, without parsing localized/format-fragile text.
Suggested fix
Route goal updates through the same structured channel already used for thread status/archived/name, e.g.:
(and a cleared signal on thread/goal/cleared). The human-readable agent_message_chunk can stay for display; the ask is to also expose the structured state so clients can react to the goal lifecycle programmatically.
Activity