Skip to content

Write path serializes thinking as reasoning_content which some providers don't support #1004

@thisisnic

Description

@thisisnic

In #981, reasoning effort was enabled for Ollama, which also updated the read path to check both reasoning and reasoning_content fields.

However, when preserve_thinking = TRUE, the multi-turn write path in ProviderOpenAICompatible serializes ContentThinking back as reasoning_content. Providers like vLLM only recognize reasoning (removed reasoning_content entirely in vllm-project/vllm#33402).

The ecosystem is split on field naming:

  • OpenAI and OpenRouter recommend reasoning as primary (with reasoning_content as alias)
  • LM Studio uses only reasoning_content
  • vLLM uses only reasoning

One option is a field on ProviderOpenAICompatible to configure which field name to use. See discussion in #981 for more context.

Not currently biting anyone since preserve_thinking defaults to FALSE for Ollama, but worth addressing.

Metadata

Metadata

Assignees

No one assigned

    Labels

    featurea feature request or enhancement

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions