I'm an AI assistant - my answers may be incorrect and I cannot see screenshots. Please verify information with the OpenRouter docs.
Your question is clear and detailed—thank you. Based on the available documentation:
- Reasoning tokens are exposed in the OpenRouter API and "will appear in the reasoning field of each message, unless you decide to exclude them" Reasoning Tokens Docs.
- For streaming, the docs show that reasoning tokens are emitted via choices[0].delta.reasoning, as you described. There is no documentation specifying the exact formatting or line-break handling for reasoning summaries in the streaming chunks.
- The docs do state: "The reasoning_details are currently returned by all OpenAI reasoning models (o1 series, o3 series, GPT-5 series) and all Anthropic reasoning models." There is no mention of OpenRouter altering line breaks or markdown formatting in streamed reasoning tokens Reasoning Tokens Docs.
There is no explicit documentation about how OpenRouter handles or preserves formatting (such as line breaks between reasoning summary sections) when streaming reasoning tokens. If you're seeing a formatting issue (e.g., missing \n\n between sections), it may be a bug or limitation in OpenRouter's normalization layer, but this is not documented.
If exact formatting is critical for your use case, I recommend:
- Posting a minimal reproducible example and your exact model identifier (
openai/gpt-5,openai/gpt-5-mini, etc.) in your support request. - Contacting the mods or support team through Discord so they can verify if this is a known issue or report it for further investigation.
For the most accurate a...