fix: no /no_think for qwen3 anymore if provider is dashscope (#8616)

fix(openai): 修复Qwen思考模式在dashscope提供商下的错误判断
This commit is contained in:
Phantom 2025-07-29 09:30:08 +08:00 committed by GitHub
parent eea9f7a1f6
commit f599bc80a1
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -519,7 +519,7 @@ export class OpenAIAPIClient extends OpenAIBaseClient<
}
const lastUserMsg = userMessages.findLast((m) => m.role === 'user')
if (lastUserMsg && isSupportedThinkingTokenQwenModel(model)) {
if (lastUserMsg && isSupportedThinkingTokenQwenModel(model) && model.provider !== 'dashscope') {
const postsuffix = '/no_think'
const qwenThinkModeEnabled = assistant.settings?.qwenThinkMode === true
const currentContent = lastUserMsg.content