OpenAI provider response contains many empty thoughts blocks
Describe the bug
When using GPT5 via OpenAI then I see many empty thoughts block.
I don't see this problem with any other provider.
To Reproduce Give GPT5 any more complicated and multi-step prompt.
Expected behavior 0 empty thought blocks
Screenshots
yeah that happens because for some reasoning blocks openai just don't send the summary, I agree, maybe we should drop the reason started and leave only the text and finished one, similar to how we do for toolCalls
Sounds good! I found a dicussion about the problem, maybe it will be fixed: https://community.openai.com/t/o3-model-in-api-often-omits-reasoning-summary-despite-reasoning-summary-detailed/1307301/31
Good, we can have lower priority on that and see how that is fixed, but doing what I mention is ok by me too, it may require change in clients tho, as emacs at least is not ready to create the thoughts block on text, it needs a start, easy to fix tho
I'm closing this, there was improvements for openai-chat that I did that I believe fixed this issue and for openai-responses it's way more concise, almost always add blocks, LMK otherwise