File tree Expand file tree Collapse file tree 1 file changed +2
-11
lines changed
packages/opencode/src/provider Expand file tree Collapse file tree 1 file changed +2
-11
lines changed Original file line number Diff line number Diff line change @@ -223,21 +223,12 @@ export namespace ProviderTransform {
223223 result [ "promptCacheKey" ] = sessionID
224224 }
225225
226- // Enable thinking mode for Gemini models
227- const isGemini3 = model . api . id . includes ( "gemini-3" )
228- const isGoogle = model . providerID === "google"
229- const isOpencode = model . providerID . startsWith ( "opencode" ) && isGemini3
230- const isOpenRouter = model . api . npm === "@openrouter/ai-sdk-provider" && isGemini3
231-
232- if ( isOpenRouter ) {
233- // OpenRouter expects OpenAI-compatible reasoning format, not Gemini-native thinkingConfig
226+ if ( model . api . npm === "@openrouter/ai-sdk-provider" && model . api . id . includes ( "gemini-3" ) ) {
234227 result [ "reasoning" ] = { effort : "high" }
235228 }
236- if ( isGoogle || isOpencode ) {
237- // Gemini 3 requires thinkingLevel, Gemini 2.5 only needs includeThoughts
229+ if ( model . api . npm === "@ai-sdk/google" || model . api . npm === "@ai-sdk/google-vertex" ) {
238230 result [ "thinkingConfig" ] = {
239231 includeThoughts : true ,
240- ...( isGemini3 && { thinkingLevel : "HIGH" } ) ,
241232 }
242233 }
243234
You can’t perform that action at this time.
0 commit comments