Skip to content

Commit 2dea374

Browse files
committed
feat: removed support for the DeepSeek official Responses API, as the official Responses API is no longer available.
1 parent 8d7b2d7 commit 2dea374

11 files changed

Lines changed: 107 additions & 263 deletions

File tree

‎README-en.md‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -129,7 +129,7 @@ Write a shell notification script that calls a Slack webhook, then set the `noti
129129

130130
### How do I enable web search?
131131

132-
Deep Code now supports native web search through the [DeepSeek Responses API](https://api-docs.deepseek.com/guides/responses_api/#tools). If you prefer to use a custom script for web search, set the `webSearchTool` field in `~/.deepcode/settings.json` to the full path of your script. For detailed steps, refer to: https://github.com/qorzj/web_search_cli
132+
Deep Code comes with a built-in, free Web Search tool that works well for most use cases. If you prefer to use a custom script for web search, set the `webSearchTool` field in `~/.deepcode/settings.json` to the full path of your script. For detailed steps, refer to: https://github.com/qorzj/web_search_cli
133133

134134
### Does it support Coding Plan?
135135

‎README-zh_CN.md‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -128,7 +128,7 @@ Deep Code 的收益来自于工具约束、上下文管理、Agent Skills 和权
128128

129129
### 怎样启用联网搜索功能?
130130

131-
Deep Code 已支持 [DeepSeek Responses API](https://api-docs.deepseek.com/zh-cn/guides/responses_api/#tools) 的原生联网搜索能力。如果你希望使用自定义脚本进行联网搜索,可以在 `~/.deepcode/settings.json` 中将 `webSearchTool` 设为脚本的完整路径即可。详细步骤可参考:https://github.com/qorzj/web_search_cli
131+
Deep Code自带免费的、且大部分情况够用的Web Search工具。如果你希望使用自定义脚本进行联网搜索,可以在 `~/.deepcode/settings.json` 中将 `webSearchTool` 设为脚本的完整路径即可。详细步骤可参考:https://github.com/qorzj/web_search_cli
132132

133133
### 如何配置 MCP?
134134

‎README.md‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -128,7 +128,7 @@ Deep Code 的收益来自于工具约束、上下文管理、Agent Skills 和权
128128

129129
### 怎样启用联网搜索功能?
130130

131-
Deep Code 已支持 [DeepSeek Responses API](https://api-docs.deepseek.com/zh-cn/guides/responses_api/#tools) 的原生联网搜索能力。如果你希望使用自定义脚本进行联网搜索,可以在 `~/.deepcode/settings.json` 中将 `webSearchTool` 设为脚本的完整路径即可。详细步骤可参考:https://github.com/qorzj/web_search_cli
131+
Deep Code自带免费的、且大部分情况够用的Web Search工具。如果你希望使用自定义脚本进行联网搜索,可以在 `~/.deepcode/settings.json` 中将 `webSearchTool` 设为脚本的完整路径即可。详细步骤可参考:https://github.com/qorzj/web_search_cli
132132

133133
### 如何配置 MCP?
134134

‎docs/configuration.md‎

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -147,9 +147,7 @@ Deep Code 使用 `settings.json` 设置文件进行持久化配置,支持两
147147
148148
#### `webSearchTool` — 自定义联网搜索
149149

150-
未配置 `webSearchTool` 时,如果 `BASE_URL` 是 `https://api.deepseek.com`,Deep Code 会调用 DeepSeek Responses API 的 `web_search` 工具,并固定使用 `deepseek-v4-flash`,不受 `MODEL` 配置影响。其他 API 地址仍使用 Deep Code Web Search API。
151-
152-
如果需要自定义搜索逻辑,可将 `webSearchTool` 设为一个可执行脚本的完整路径。自定义脚本始终优先于内置搜索:
150+
Deep Code 内置免费可用的 Web Search 工具。如果需要自定义搜索逻辑,可将 `webSearchTool` 设为一个可执行脚本的完整路径:
153151

154152
```json
155153
{

‎docs/configuration_en.md‎

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -147,9 +147,7 @@ The following context is injected as environment variables when the notify scrip
147147
148148
#### `webSearchTool` — Custom Web Search
149149

150-
When `webSearchTool` is not configured and `BASE_URL` is `https://api.deepseek.com`, Deep Code calls the `web_search` tool through the DeepSeek Responses API with the fixed `deepseek-v4-flash` model, regardless of the `MODEL` setting. Other API endpoints continue to use the Deep Code Web Search API.
151-
152-
For custom search logic, set `webSearchTool` to the full path of an executable script. A custom script always takes precedence over the built-in search:
150+
Deep Code has a built-in, free-to-use Web Search tool. If you need custom search logic, set `webSearchTool` to the full path of an executable script:
153151

154152
```json
155153
{

‎packages/core/src/tests/tool-cancellation.test.ts‎

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ function setup(t: TestContext) {
2424
return { root, controller, context };
2525
}
2626

27-
for (const stage of ["diagnosis", "escape", "language", "translation", "search", "image", "responses"] as const) {
27+
for (const stage of ["diagnosis", "escape", "language", "translation", "search", "image", "search-deepseek"] as const) {
2828
test(`cancellation reaches pending ${stage} request`, { timeout: 3000 }, async (t) => {
2929
const { root, controller, context } = setup(t);
3030
let calls = 0;
@@ -42,21 +42,23 @@ for (const stage of ["diagnosis", "escape", "language", "translation", "search",
4242
completions: {
4343
create: (body: unknown, options: { signal?: AbortSignal }) => {
4444
chatCalls++;
45-
if (["search", "image", "responses"].includes(stage) || (stage === "translation" && chatCalls === 1)) {
45+
if (
46+
["search", "image", "search-deepseek"].includes(stage) ||
47+
(stage === "translation" && chatCalls === 1)
48+
) {
4649
return Promise.resolve({ choices: [{ message: { content: '{"dominant_language":"en"}' } }] });
4750
}
4851
return pending(body, options);
4952
},
5053
},
5154
},
52-
responses: { create: pending },
5355
} as unknown as OpenAI;
5456
context.createOpenAIClient = () => ({
5557
client,
5658
model: "test",
5759
machineId: "test-machine",
5860
thinkingEnabled: false,
59-
baseURL: stage === "responses" ? "https://api.deepseek.com" : "https://example.com",
61+
baseURL: stage === "search-deepseek" ? "https://api.deepseek.com" : "https://example.com",
6062
});
6163
const originalFetch = globalThis.fetch;
6264
t.after(() => {

0 commit comments

Comments
 (0)