DeepSeek Harness Hub
← 返回列表

免密钥网页搜索simonegasperoni/dsh-free-search-plugin

DeepSeek Harnessspec-screened在 GitHub 查看 ↗
未验证

无需 API 密钥直连搜索引擎,完成网页搜索与抓取

尚未跑自动兼容性验证,可查看页面内的依赖与入口分析。 · 最近上游提交 2026/8/21 · 已提供中文文档

DeepSeek harness 上的本地搜索

综合分
27.3
GitHub 分
27.3
用户评分
★ Stars
0
周下载量
安装插件(需先安装 dsh CLI 引擎:npm install -g @deepseek-ai/dsh)
dsh plugin --profile web add simonegasperoni/dsh-free-search-plugin
该插件未发布到 npm,走 GitHub 源安装(pnpm 若拦截 prepare 脚本,按其提示在 pnpm-workspace.yaml 的 allowBuilds 中放行后重跑)
数据截至 2026/9/16(元数据每日更新 · 实装验证按队列轮转,单条结论的验证时间见上方)
用户评分
还没有人投票,来当第一个
订阅周报,不错过优质插件更新
每周一封 · 高评分插件 + 新用户活动

README

dsh-web-search-free

为 DeepSeek Harness(DSH)提供免费、无需密钥的网页访问。这是一个 DSH bundle,它将两个本地 provider 注册到 web seam(ctx.web)中:

| Provider | Id | 作用 |
|---|---|---|
| FreeSearchProvider | free-local | 通过直接查询公共搜索引擎为 web_search 工具提供支持(无需 DeepSeek 云服务,无需 API 密钥) |
| LocalFetchProvider | free-local-fetch | 通过直接从你的机器获取任意 HTTP(S) URL 为 web_fetch 工具提供支持 |

它替代了 @deepseek-ai/dsh-web-search-deepseek,后者需要付费的 DEEPSEEK_API_KEY。请求直接从你的机器发往搜索引擎站点:没有中间方。

搜索引擎

该 provider 会按顺序逐个尝试各引擎,并使用第一个返回结果的引擎:

| 引擎 | 端点 | 备注 |
|---|---|---|
| ddg-lite | lite.duckduckgo.com | 极简 HTML 端点,通常最稳定 |
| ddg-html | html.duckduckgo.com(POST) | 经典的 DuckDuckGo HTML 端点 |
| mojeek | www.mojeek.com | 独立、注重隐私的索引;对突发请求有严格速率限制 |
| bing | www.bing.com | 最后手段:可疑客户端可能会收到看似合理但实为伪造的 SERP,且不会报告任何错误 |

当某个引擎返回机器人挑战页面(HTTP 202/403/429 或验证码页面)时,该 provider 会自动降级到下一个引擎。如果所有引擎都返回零结果,web_search 会回答“No results found”;如果所有引擎都失败,错误信息会报告每个引擎的原因。

注意:引擎行为因 IP 和网络而异——哪个引擎响应最佳取决于你的连接。顺序是可配置的(见下文)。抓取是被容忍的,而非被保证的:引擎可能随时引入机器人拦截。

安装

该插件是一个 DSH bundle:它被安装到 web profile(~/.dsh/profiles/web)中,其 cordis.patch.yml 层会在每次启动时被组合进该 profile。

要求:
- 已安装 DeepSeek Harness(dsh 命令)。
- PATH 中有 pnpm,用于下面的官方命令(brew install pnpm)。选项 B 不需要 pnpm。

选项 A — 官方命令(推荐)

从任意位置运行,指向插件目录:

dsh plugin --profile web add /absolute/path/to/dsh-free-search-plugin

(或者 cd 进入插件检出目录并运行 dsh plugin --profile web add . —— 相对路径是相对于你启动命令时所在的目录解析的,而不是相对于 profile)。

会发生什么:
1. pnpm 将该包作为 file: 依赖安装到 web profile 中;
2. dsh reconciler 发现该包声明了 dsh.bundle.patch,并将 dsh-web-search-free 追加到 profile package.json 中的 dsh.profile.bundles;
3. 在下次启动时,profile 组合会包含此 bundle 的层,该层会插入 provider 行并将 web seam 指向它们。

选项 B — 手动安装(无需 pnpm)
该包没有任何 npm 依赖,因此你可以手动生成完全相同的最终状态:

1. 将依赖项和 bundle 条目添加到 ~/.dsh/profiles/web/package.json(保留现有的 dependencies 和 bundles 值,只需添加以下内容):

{
"dependencies": {
"dsh-web-search-free": "file:/absolute/path/to/dsh-free-search-plugin"
},
"dsh": {
"profile": {
"bundles": [
"@deepseek-ai/dsh-base",
"@deepseek-ai/dsh-web-app",
"dsh-web-search-free"
]
}
}
}

2. 将该包链接到配置文件的 node_modules 中,以便加载器可以导入它:

mkdir -p ~/.dsh/profiles/web/node_modules
ln -s /absolute/path/to/dsh-free-search-plugin \
~/.dsh/profiles/web/node_modules/dsh-web-search-free

激活:重启服务器

Bundle 仅在启动时加载。安装不会影响正在运行的服务器;请停止它(Ctrl+C)并重新启动:

dsh web

bundle 层在组合中改变了什么

- 插入一个 web-search-free 加载器行,用于挂载插件并注册这两个 provider;
- 覆盖 seam 的 web 行:searchProvider: free-local、fetchProvider: free-local-fetch(基础层指向 deepseek-official)。

验证

node test/smoke.mjs                       # 实时引擎测试,需要网络
dsh --profile web --dump-config | grep -B2 -A10 "web-search-free"

在 dump 中,你应该会看到 web 行带有 searchProvider: free-local(标注为 patched by dsh-web-search-free),以及插入的 web-search-free 行及其引擎列表。重启后,向 agent 询问类似 “search the web for the latest MLX news” 的内容:web_search 工具应返回真实来源。

配置

在 cordis.patch.yml(bundle 行)中,或在你配置文件的 cordis.patch.yml 中:

- id: web-search-free
config:
engines: [ddg-lite, ddg-html, mojeek, bing]  # fallback order
timeoutMs: 15000        # HTTP budget per engine
maxResults: 10          # sources per search (the tool applies its own cap too)
userAgent: '...'        # optional: custom browser user agent
fetch:
maxBodyBytes: 4000000 # body cap for web_fetch

同时启用 web_fetch(可选)

standard agent 预设(默认预设)注册 tool-web 时使用 fetch: false,因此即使 provider 已挂载,web_fetch 工具仍对 agent 隐藏。要启用它:

1. 在预设设置中(或通过匹配的 UI 命令),将 standard 预设复制为个人预设(例如 standard-web)——随附的预设是只读的;
2. 在 ~/.dsh/.agent-presets/standard-web/agent.cordis.yml 中,修改:

- id: tool-web
name: '@deepseek-ai/dsh-tool-web'
config:
fetch: true          # changed from false
searchTimeoutMs: 60000

3. 将新预设选为默认预设(或按会话选择)。

从那时起,agent 还可以读取它找到的页面的完整内容。

卸载
选项 A — 官方命令

dsh plugin --profile web remove dsh-web-search-free

pnpm 会从 profile 中移除该依赖,dsh reconciler 会将 dsh-web-search-free 从 dsh.profile.bundles 中移除。

选项 B — 手动(如果你手动安装)

1. 在 ~/.dsh/profiles/web/package.json 中,从 dependencies 删除 dsh-web-search-free 键,并从 dsh.profile.bundles 中删除其条目。
2. 移除链接:

rm ~/.dsh/profiles/web/node_modules/dsh-web-search-free

移除之后

重启 dsh web(bundles 在启动时加载)。没有此 bundle,seam 会回退到基础配置:searchProvider: deepseek-official。官方 DeepSeek provider 仍保持注册,因此只有在有付费的 DEEPSEEK_API_KEY 可用时(凭据存储或环境变量),web_search 才能再次工作;否则搜索会因缺少凭据错误而失败。该插件在磁盘上的源目录不受影响——如果你想彻底删除它,请单独删除。

布局

lib/index.js          # Cordis 插件(apply/inject/name):将 providers 注册到 ctx.web
lib/engines.js        # 搜索引擎 + 回退链
lib/fetch-provider.js # 本地 HTTP(S) fetch provider
lib/html.js           # 实体解码、标签剥离、重定向解包(uddg、bing ck/a)
cordis.patch.yml      # bundle 层
test/smoke.mjs        # 实时冒烟测试:node test/smoke.mjs [query]

零 npm 依赖:仅需 Node >= 20(全局 fetch)。

隐私

无遥测、无 API 密钥、无账户。每次搜索都是从你的机器向所选引擎发出的普通 HTTPS 请求。引擎会看到你的 IP 和查询内容,与浏览器完全一样。

上游仓库有新提交时邮件通知你(每天最多一封,无更新不打扰),随时一键退订。

💬 加入 DPharness 群聊

插件用法、部署报错、新插件第一时间同步——群里问,比一个人翻文档快。

点击加入 QQ 群
DPharness 群聊二维码,手机 QQ 扫码进群
扫码进群