mirror of
https://github.com/CherryHQ/cherry-studio.git
synced 2025-12-25 03:10:08 +08:00
hotfix: gemini-2.5-pro-preview-06-05 using error (#6870)
This commit is contained in:
parent
c4c1e2fca1
commit
cbe00d54b2
@ -291,8 +291,7 @@ export default class GeminiProvider extends BaseProvider {
|
||||
if (reasoningEffort === undefined) {
|
||||
return {
|
||||
thinkingConfig: {
|
||||
includeThoughts: false,
|
||||
thinkingBudget: 0
|
||||
includeThoughts: false
|
||||
} as ThinkingConfig
|
||||
}
|
||||
}
|
||||
@ -308,11 +307,11 @@ export default class GeminiProvider extends BaseProvider {
|
||||
}
|
||||
|
||||
const { max } = findTokenLimit(model.id) || { max: 0 }
|
||||
const budget = Math.floor(max * effortRatio)
|
||||
|
||||
// 如果thinking_budget是明确设置的值(包括0),使用该值
|
||||
return {
|
||||
thinkingConfig: {
|
||||
thinkingBudget: Math.floor(max * effortRatio),
|
||||
...(budget > 0 ? { thinkingBudget: budget } : {}),
|
||||
includeThoughts: true
|
||||
} as ThinkingConfig
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user