From ed0aeccf2985f324fea50ed889fafd5b62cc369e Mon Sep 17 00:00:00 2001 From: Johnson-LYS Date: Mon, 10 Aug 2026 17:10:47 +0800 Subject: [PATCH] feat: add qwen3.8 max preview (#67) --- __tests__/validate.test.mjs | 28 +++++++++++++++ .../coding-plans/dashscope-token-plan.json | 36 +++++++++++++++++++ manifest.json | 2 +- 3 files changed, 65 insertions(+), 1 deletion(-) diff --git a/__tests__/validate.test.mjs b/__tests__/validate.test.mjs index cb3f871..93a243e 100644 --- a/__tests__/validate.test.mjs +++ b/__tests__/validate.test.mjs @@ -271,6 +271,34 @@ describe('真实数据全量校验', () => { assert.equal(pro.serviceType.includes('vision'), false) }) + it('Qwen3.8 Max Preview 应在 Token Plan 中提供完整的推理与视觉规格', () => { + const tokenPlan = JSON.parse(readFileSync(join(ROOT, 'compute', 'coding-plans', 'dashscope-token-plan.json'), 'utf8')) + const specFile = JSON.parse(readFileSync(join(ROOT, 'compute', 'model-specs', 'qwen.json'), 'utf8')) + const modelId = 'qwen3.8-max-preview' + const model = tokenPlan.models.find((item) => item.modelName === modelId) + + assert.ok(model, `Token Plan 缺少 ${modelId}`) + assert.equal(model.contextWindow, 983616) + assert.equal(model.defaultTemperature, 0.6) + assert.ok(model.capabilities.includes('reasoning')) + assert.ok(model.capabilities.includes('vision')) + assert.ok(model.serviceType.includes('reasoning')) + assert.ok(model.serviceType.includes('vision')) + assert.deepEqual(model.extra.reasoning.supportedEfforts, ['low', 'high', 'xhigh']) + assert.equal(model.extra.reasoning.defaultEffort, 'xhigh') + assert.equal(model.extra.thinkingOnly, true) + assert.equal(model.extra.thinkingMaxTokens, 262144) + assert.equal(model.extra.preserveThinkingDefault, true) + assert.equal(model.extra.supportsParallelToolCalls, false) + + const specs = specFile.specs.filter((item) => item.id === modelId) + assert.equal(specs.length, 1, `model-specs 中 ${modelId} 应且仅应有一条规格`) + assert.equal(specs[0].spec.contextWindow, 1000000) + assert.equal(specs[0].spec.defaultTemperature, 0.6) + assert.equal(specs[0].spec.supportsReasoning, true) + assert.ok(specs[0].spec.capabilities.includes('vision')) + }) + it('所有 Provider 应按供应商归属计价,模型来源不覆盖供应商币种', () => { const expectedCurrencies = { anthropic: 'USD', diff --git a/compute/coding-plans/dashscope-token-plan.json b/compute/coding-plans/dashscope-token-plan.json index 01d7f6b..fa86501 100644 --- a/compute/coding-plans/dashscope-token-plan.json +++ b/compute/coding-plans/dashscope-token-plan.json @@ -26,6 +26,42 @@ } }, "models": [ + { + "modelName": "qwen3.8-max-preview", + "displayName": "Qwen3.8 Max Preview (Token Plan)", + "serviceType": [ + "chat", + "reasoning", + "vision" + ], + "description": "百炼 Token Plan,通义千问 3.8 Max 预览版,支持文本与视觉输入,始终开启深度思考", + "contextWindow": 983616, + "maxOutputTokens": 65536, + "capabilities": [ + "chat", + "reasoning", + "deep_thinking", + "code", + "vision", + "tool_use", + "agent", + "long_context" + ], + "defaultTemperature": 0.6, + "extra": { + "reasoning": { + "supportedEfforts": ["low", "high", "xhigh"], + "defaultEffort": "xhigh" + }, + "supportsThinking": true, + "thinkingDefault": true, + "thinkingOnly": true, + "thinkingMaxTokens": 262144, + "preserveThinkingDefault": true, + "supportsParallelToolCalls": false + }, + "source": "preset" + }, { "modelName": "qwen3.7-max", "displayName": "Qwen3.7 Max (Token Plan)", diff --git a/manifest.json b/manifest.json index 6caed51..b811b83 100644 --- a/manifest.json +++ b/manifest.json @@ -1,6 +1,6 @@ { "version": "1.0.0", - "presetDataVersion": 88, + "presetDataVersion": 89, "updatedAt": "2026-08-10", "description": "DesireCore 官方配置中心" }