feat(openai): GPT-5 previous_response_id, phase, and verbosity support#385
feat(openai): GPT-5 previous_response_id, phase, and verbosity support#385luosc wants to merge 3 commits intoChevey339:masterfrom
Conversation
Add previous_response_id chaining for tool-call follow-up requests when using OpenAI's Responses API directly, preserving reasoning items and avoiding re-reasoning across tool rounds. Add phase annotations (commentary/final_answer) on assistant messages for GPT-5.4 to prevent early stopping in long tool-calling chains. Ref Chevey339#384 Signed-off-by: Shuchen Luo <nemo0806@gmail.com>
Add configurable verbosity (low/medium/high) for GPT-5 family models, controlling output length. Passes text.verbosity for Responses API and top-level verbosity for Chat Completions API. Adds a verbosity button (message-circle-more icon) in the chat input bar, visible only when a GPT-5 model is active, with mobile bottom sheet and desktop popover. Signed-off-by: Shuchen Luo <nemo0806@gmail.com>
|
这周会比较忙,就让AI看了一下,你可以先看下
|
|
@Chevey339 感谢详细回复,我去对齐一下OpenRouter测试一下。 |
Decouple input-bar verbosity from global settings so edits apply only to the current assistant, add an explicit Default option, and treat picker dismissal as no-op. Preserve verbosity across initial and follow-up tool-call rounds for both Responses and Chat Completions, and include phase for gpt-5.4* plus gpt-5.3-codex. Explicitly narrow request emission scope: send verbosity only for OpenAI host + GPT-5 family with valid values (low|medium|high), deferring broader OpenAI-compatible provider support (e.g. OpenRouter) to follow-up compatibility testing.
Summary
GPT-5.4 stably truncates during complex multi-tool-call chains, failing to produce a final answer (see #384). Per OpenAI docs, this is caused by missing
phaseannotations and lack of
previous_response_idchaining, which leads to lost reasoning state and preambles being treated as final answers.previous_response_idfor tool-call follow-ups in the Responses API, preserving reasoning items and avoiding re-reasoning across roundsphaseannotations (commentary/final_answer) on assistant messages for GPT-5.4 to prevent early stopping in long tool chainsverbosity(low/medium/high) for GPT-5 family models, with input bar button (mobile sheet + desktop popover)Closes #384