Fix agent output parsing for current Codex, Gemini, and Copilot CLIs#50
Fix agent output parsing for current Codex, Gemini, and Copilot CLIs#50enhung wants to merge 1 commit into
Conversation
|
Heads-up: there are already open PRs covering parts of this same area. PR #27 touches This PR appears to bundle those slices with broader Gemini/Copilot parser support and waiting logs, so the authors and reviewer may want to compare scope before the maintainer team chooses what lands. |
|
Hey @enhung — a quick update since my note last week. PRs #27 (Codex 0.130 The parts of this PR that are still uniquely yours and haven't landed yet:
A rebase on main + trimming the now-landed Codex/ConvertChip hunks should get you to a clean, focused PR for those three additions. PR #30 (ConvertChip layout-mode guard) is still open too, so worth keeping an eye on the |
Summary
Fixes output parsing for current versions of several local coding-agent CLIs.
What changed
item.type = "agent_message"andturn.completedusage events.init,message, andresultstream events.assistant.message_delta,assistant.message, and usage events.ConvertChiphook ordering when switching layout modes.Why
The existing parser worked for Claude-style JSONL, but current Codex/Gemini/Copilot schemas could be dropped as noise. In the UI this looked like a stuck run with
TTFB —and0.0 KB, even though the CLI was installed and able to respond.Codex can also take a long time before first output for full HTML generation, so the extra waiting logs make that state explicit instead of looking dead.
Verification
pnpm build/api/draftsmoke-tested with:/api/convertsmoke test with Codex +article-magazineconfirmed first HTML delta after about 74s.