openai / openai/codex

Desktop app: raw reasoning streams (non-OpenAI providers) collapse each reasoning block on item completion instead of staying expanded until the final answer

Open
#46,360 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

app bug custom-model
Dominant language
Rust
Stars
125k
Forks
19.4k
PR merge metrics
PR metrics pending

Description

Summary

When a custom provider streams reasoning through the Responses API's raw reasoning events (response.reasoning_text.delta — e.g. DeepSeek's /v1/responses), the macOS desktop app renders each reasoning segment as an independent collapsible block that collapses as soon as that item completes. During a multi-step agent turn, blocks fold one by one while the turn is still running, and each new segment briefly re-expands.

With OpenAI models (which stream response.reasoning_summary_* events), the thinking disclosure stays expanded through the whole intermediate phase and only collapses when the final answer arrives — which is the behavior users expect from raw streams too.

Environment

  • Codex desktop app 26.908.70816 (macOS, com.openai.codex / ChatGPT.app bundle)
  • Bundled app-server: codex-cli 0.154.0-alpha.6.2
  • Custom provider: DeepSeek, https://api.deepseek.com/responses, wire_api = "responses", model deepseek-flash
  • Model catalog from DeepSeek's official Codex integration template (supports_reasoning_summaries: true, reasoning_summary_format: "experimental", default_reasoning_summary: "none")

Observed behavior

  • Every reasoning segment folds immediately when its item completes, even while the turn is still in progress.
  • A newly streamed reasoning segment briefly expands, then folds again.
  • No knob controls this: codex features list (140 flags) has nothing for raw-reasoning display policy, and the catalog flags above only affect request parameters, not rendering. Removing the catalog flags changes nothing user-visible in the fold lifecycle.

Expected behavior

Raw reasoning blocks should follow the same disclosure lifecycle as summary-based reasoning: stay expanded while the turn is active (including while later segments and tool calls stream), and collapse when the final answer / turn completes. Alternatively, expose a setting for the raw-stream collapse policy.

Root-cause notes (inference from inspecting the renderer bundle)

  • DeepSeek's Responses implementation streams only response.reasoning_text.delta / response.reasoning_text.done and never response.reasoning_summary_text.delta / response.reasoning_summary_part.*. Verified by capturing the SSE stream directly, with several reasoning.summary parameter values — the summary events simply never appear.
  • The renderer therefore receives agent_reasoning_raw_content_delta rather than agent_reasoning_delta, and renders raw reasoning as per-item collapsibles whose collapsed default is derived from item completion (defaultCollapsed: !item.completed in the minified bundle). Summary-based reasoning appears to attach to a turn-level thinking disclosure that persists until the turn ends.

Related issues

  • #43679 — thinking disclosure stays collapsed when the first summary arrives (summary path, different lifecycle bug)
  • #22334 — request for a setting to auto-expand the Working section
  • #30793 — VS Code extension hides reasoning summaries even when app-server emits them

This report differs from the above in that it is specifically about the raw reasoning content path used by non-OpenAI providers.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by inspecting the renderer bundle's handling of agent_reasoning_raw_content_delta and compare it with the agent_reasoning_delta summary path. Reproduce a multi-step turn with DeepSeek's Responses API raw reasoning events, then trace item completion and turn completion. Done means raw reasoning blocks remain expanded while the turn and later segments or tool calls are active, then collapse when the final answer arrives.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust
Domain
desktop
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Active
Clarity
Mostly clear
Newbie friendliness
48/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.