fix: update DeepSeek direct models to v4
Memind CI / Test, build, and release guards (pull_request) Successful in 1m51s
Memind CI / Test, build, and release guards (pull_request) Successful in 1m51s
This commit is contained in:
@@ -40,14 +40,14 @@ const CONFIG_NAME = 'DeepSeek 直连';
|
||||
async function testDirectDeepSeek() {
|
||||
const dispatcher = new Agent({ connect: { rejectUnauthorized: true } });
|
||||
const started = Date.now();
|
||||
const res = await fetch('https://api.deepseek.com/chat/completions', {
|
||||
const res = await fetch('https://api.deepseek.com/v1/chat/completions', {
|
||||
method: 'POST',
|
||||
headers: {
|
||||
'Content-Type': 'application/json',
|
||||
Authorization: `Bearer ${apiKey}`,
|
||||
},
|
||||
body: JSON.stringify({
|
||||
model: 'deepseek-chat',
|
||||
model: 'deepseek-v4-pro',
|
||||
messages: [{ role: 'user', content: 'Hello' }],
|
||||
stream: false,
|
||||
}),
|
||||
@@ -78,7 +78,7 @@ if (rowId) {
|
||||
const updated = await svc.updateKey(rowId, {
|
||||
name: CONFIG_NAME,
|
||||
apiKey,
|
||||
defaultModel: 'deepseek-chat',
|
||||
defaultModel: 'deepseek-v4-pro',
|
||||
});
|
||||
if (!updated.ok) {
|
||||
console.error('更新 DeepSeek 配置失败:', updated.message);
|
||||
@@ -90,7 +90,7 @@ if (rowId) {
|
||||
providerId: 'custom_deepseek',
|
||||
name: CONFIG_NAME,
|
||||
apiKey,
|
||||
defaultModel: 'deepseek-chat',
|
||||
defaultModel: 'deepseek-v4-pro',
|
||||
});
|
||||
if (!created.ok) {
|
||||
console.error('创建 DeepSeek 配置失败:', created.message);
|
||||
|
||||
Reference in New Issue
Block a user