diff --git a/src/api/providers/__tests__/deepseek.test.ts b/src/api/providers/__tests__/deepseek.test.ts index fe5fa7787e..483552efe0 100644 --- a/src/api/providers/__tests__/deepseek.test.ts +++ b/src/api/providers/__tests__/deepseek.test.ts @@ -72,7 +72,7 @@ describe("DeepSeekHandler", () => { mockOptions = { deepSeekApiKey: "test-api-key", apiModelId: "deepseek-chat", - deepSeekBaseUrl: "https://api.deepseek.com/v1", + deepSeekBaseUrl: "https://api.deepseek.com", } handler = new DeepSeekHandler(mockOptions) mockCreate.mockClear() @@ -110,7 +110,7 @@ describe("DeepSeekHandler", () => { // The base URL is passed to OpenAI client internally expect(OpenAI).toHaveBeenCalledWith( expect.objectContaining({ - baseURL: "https://api.deepseek.com/v1", + baseURL: "https://api.deepseek.com", }), ) }) diff --git a/src/api/providers/deepseek.ts b/src/api/providers/deepseek.ts index 267a41bfff..9ba19aa5db 100644 --- a/src/api/providers/deepseek.ts +++ b/src/api/providers/deepseek.ts @@ -8,7 +8,7 @@ export class DeepSeekHandler extends OpenAiHandler { ...options, openAiApiKey: options.deepSeekApiKey ?? "not-provided", openAiModelId: options.apiModelId ?? deepSeekDefaultModelId, - openAiBaseUrl: options.deepSeekBaseUrl ?? "https://api.deepseek.com/v1", + openAiBaseUrl: options.deepSeekBaseUrl ?? "https://api.deepseek.com", openAiStreamingEnabled: true, includeMaxTokens: true, })