Skip to content

bug(provider): GPT-5.6 *-pro models do not send reasoning.mode "pro" on Responses API #36392

Description

@tlerbao

Summary

For GPT-5.6, OpenAI documents reasoning.mode: "pro" as a Responses API option that is orthogonal to reasoning.effort. In OpenCode/models.dev, derived *-pro model entries appear intended to represent the same base model plus reasoning.mode: "pro".

However, OpenCode's OpenAI Responses wire path appears to only forward reasoning.effort and reasoning.summary, dropping reasoning.mode. If so, selecting a GPT-5.6 *-pro model behaves like standard reasoning at the selected effort instead of Pro mode.

Environment

  • Provider: built-in openai / @ai-sdk/openai
  • Models: openai/gpt-5.6-pro, openai/gpt-5.6-sol-pro, openai/gpt-5.6-terra-pro, openai/gpt-5.6-luna-pro
  • API path: OpenAI Responses API

Steps to reproduce

  1. Select openai/gpt-5.6-sol-pro or another GPT-5.6 *-pro entry.
  2. Set a reasoning variant, for example medium, via Ctrl+T.
  3. Send any prompt and inspect the outbound /v1/responses JSON.

Expected behavior

The derived *-pro entry should keep the base model slug and send reasoning.mode: "pro" alongside the selected effort. For example:

{
  "model": "gpt-5.6-sol",
  "reasoning": {
    "mode": "pro",
    "effort": "medium",
    "summary": "auto"
  }
}

reasoning.mode and reasoning.effort are separate dimensions in the OpenAI GPT-5.6 Responses API; pro is not the same as xhigh or max.

Actual behavior

The request appears to include only effort/summary, for example:

{
  "model": "gpt-5.6-sol",
  "reasoning": {
    "effort": "medium",
    "summary": "auto"
  }
}

reasoning.mode is absent, so the request likely runs as standard reasoning.

Suspected implementation details

The high-level model/options merge appears able to preserve model options from derived model modes, but the OpenAI Responses lowering layer seems to only construct reasoning from reasoningEffort / reasoningSummary.

Relevant areas:

  • packages/opencode/src/provider/provider.ts (fromModelsDevProvider, derived experimental modes)
  • packages/opencode/src/session/llm/request.ts (options merge order)
  • packages/llm/src/protocols/openai-responses.ts (Responses body/lowering)
  • packages/llm/src/protocols/utils/openai-options.ts

Related issues

This is related to older Pro model discussions but the GPT-5.6 semantics are different: GPT-5.6 Pro is not a separate gpt-5.6-pro API model slug; it is the base GPT-5.6 model plus reasoning.mode: "pro".

Related, but not a duplicate:

Notes

This may require either:

  • adding first-class support for reasoning.mode in OpenCode's OpenAI Responses options/lowering, and/or
  • coordinating with the upstream AI SDK path if that layer also drops reasoning.mode.

It would also be useful for the model picker/help text to make clear that *-pro means reasoning.mode: "pro", while Ctrl+T controls reasoning.effort independently.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions