fix: 移除错误的模型ID映射,直接使用qwen3-vl-plus
This commit is contained in:
parent
2c8bcd14cd
commit
1e557c620a
@ -64,15 +64,9 @@ export async function POST(request: NextRequest) {
|
||||
baseURL: provider.baseUrl,
|
||||
});
|
||||
|
||||
// 🆕 模型 ID 映射(处理数据库中的别名到实际 API 模型 ID)
|
||||
const modelIdMapping: Record<string, string> = {
|
||||
'qwen3-vl-plus': 'qwen-vl-plus', // 映射到阿里云实际模型
|
||||
'qwen3-vl-max': 'qwen-vl-max',
|
||||
'qwen2.5-vl-plus': 'qwen-vl-plus',
|
||||
};
|
||||
|
||||
const actualModelId = modelIdMapping[visionModel.modelId] || visionModel.modelId;
|
||||
console.log("[Auto-title] Model ID mapping:", visionModel.modelId, "->", actualModelId);
|
||||
// 直接使用数据库中的模型 ID(阿里云支持 qwen3-vl-plus 等新模型 ID)
|
||||
const actualModelId = visionModel.modelId;
|
||||
console.log("[Auto-title] Using model ID:", actualModelId);
|
||||
|
||||
const { text } = await generateText({
|
||||
model: openai(actualModelId),
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user