hotfix: github models check error (#6128)

This commit is contained in:
自由的世界人 2025-05-18 20:16:33 +08:00 committed by kangfenmao
parent b17326d8f9
commit 462f31e839

View File

@ -1136,13 +1136,16 @@ export default class OpenAIProvider extends BaseOpenAIProvider {
return { valid: false, error: new Error('No model found') } return { valid: false, error: new Error('No model found') }
} }
const body = { const body: any = {
model: model.id, model: model.id,
messages: [{ role: 'user', content: 'hi' }], messages: [{ role: 'user', content: 'hi' }],
enable_thinking: false, // qwen3
stream stream
} }
if (this.provider.id !== 'github') {
body.enable_thinking = false; // qwen3
}
try { try {
await this.checkIsCopilot() await this.checkIsCopilot()
if (!stream) { if (!stream) {