Skip to content

Gemini 3 models hang due to conflicting thinkingConfig in smallOptions() #6886

Closed as not planned

Description

@kevoconnell

Description

When using gemini-3-pro-preview via the SDK, requests hang indefinitely. The same code works fine with gemini-2.0-flash.

Root cause: In packages/opencode/src/provider/transform.ts, smallOptions() returns { thinkingConfig: { thinkingBudget: 0 } } for all Google models (line 477-478). But options() sets { thinkingConfig: { thinkingLevel: "high" } } for gemini-3 models. When merged, Gemini 3 receives both parameters, which the API rejects.

Suggested fix:

if (model.providerID === "google") {
  if (model.api.id.includes("gemini-3")) {
    return { thinkingConfig: { thinkingLevel: "low" } }
  }
  return { thinkingConfig: { thinkingBudget: 0 } }
}

Plugins

None (using the sdk)

OpenCode version

1.0.223

Steps to reproduce

  1. Use createOpencode() from @opencode-ai/sdk
  2. Configure model as gemini-3-pro-preview
  3. Send a prompt
  4. Request hangs indefinitely

Operating System

macOS

Terminal

N/A (using the sdk)

Activity

  1. rekram1-node commented on Jan 5, 2026

    @rekram1-node
    Collaborator

    I just merged a fox for this earlier today, think its fixed in next release

  2. kevoconnell commented on Jan 5, 2026

    @kevoconnell
    Author

    ok sick sounds good @rekram1-node 🫡 , jw when do you think the next release will be?

  3. rekram1-node commented on Jan 5, 2026

    @rekram1-node
    Collaborator

    later today or tmr morn

  4. kevoconnell commented on Jan 5, 2026

    @kevoconnell
    Author

    sounds great thank you so much @rekram1-node 😄

  5. github-actions commented on Mar 25, 2026

    @github-actions
    Contributor

    To stay organized issues are automatically closed after 90 days of no activity. If the issue is still relevant please open a new one.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

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