yanglaofish/dsh-proxy-pro

Project Overview项目介绍

This is a native proxy manager plugin built exclusively for DeepSeek Harness (DSH). It routes all runtime network traffic through your configured proxy, including model requests, web search, web fetch, and all spawned tool calls, fixing the common issue where web fetch calls fail to use the proxy in older DSH proxy plugins. You can install it via two official DSH plugin commands: either pull the published npm package directly, or install it directly from the GitHub source repository, and no local building or extra authorization is required to get it working after installation.

This plugin is built for DSH users running Windows who need to route network traffic through a proxy to access DeepSeek models or external web resources. After you install it and start DSH, you will see a small capsule toggle button at the top of every conversation session, with green indicating an active proxy and red indicating the proxy is turned off. Clicking the button toggles the proxy state immediately, and toggling from off to on also triggers a fresh reload of your system proxy settings to fix any unexpected state issues. You can also access the full settings panel from DSH’s settings menu to adjust options and run connectivity diagnostics.

This project is released under the open source MIT license, so it is free to use and modify for any personal or commercial purpose. It does not include a direct dependency on the undici HTTP library, which avoids common version conflicts between multiple instances of the library that caused avoidable errors in older DSH proxy plugins. It natively supports reading Windows system proxy settings, while custom proxy mode works across all operating systems supported by DSH. When you uninstall the plugin, it automatically restores all original DSH network settings and leaves no residual modifications to your local user environment.

这是一款专为DeepSeek Harness(DSH)开发的原生代理管理插件,核心功能是将DSH运行时的所有网络请求,包括模型调用、web_search网页搜索、web_fetch网页获取和衍生工具调用,统一路由至Windows系统代理或用户自定义的代理地址,根治了旧版代理插件常见的web_fetch请求不走代理导致连接失败的问题。安装可通过DSH官方的插件命令直接拉取npm包或GitHub源码,无需本地构建。

它面向需要通过代理访问DeepSeek模型或外部网络资源的Windows平台DSH用户,使用流程非常简洁:安装完成启动DSH后,即可在每个对话会话的头部看到一键切换的胶囊开关,绿色代表代理已启用,红色代表关闭。点击开关即可切换状态,从关闭切到开启还会自动重新读取系统代理配置,快速修复代理异常状态。用户也可进入DSH设置页的代理配置面板查看生效状态、调整参数和诊断路由问题。

该插件采用MIT开源许可,无需付费使用,核心逻辑层无额外直接依赖,不会和DSH自带的undici库产生版本冲突。它仅原生支持读取Windows系统的代理配置,自定义代理模式可在任意平台正常使用。卸载时会自动恢复DSH原始网络配置,不会留下残留修改,项目还提供了详细的设计踩坑文档和完整单测用例保证稳定性。

Pre-install check安装前体检Compatibility · Security兼容性 · 安全性 1 warning1 项注意
  • Only 5 stars - very few users, little community feedback星标只有 5,几乎没人在用,遇到问题缺少社区反馈
DSH walks through these 9 checksDSH 会逐条核对这 9 项

Compatibility兼容性

  • DSH, Node, OS and profile requirementsDSH 版本 / Node 版本 / 操作系统 / profile 是否满足要求
  • External dependencies and runtimes (Electron / Python / Docker, ...)外部依赖与运行时(Electron / Python / Docker 等)是否齐备
  • Conflicts with installed plugins: command names, skill / tool names, ports, duplicate MCP registration与已装插件是否冲突:命令名、skill / tool 重名、端口占用、重复 MCP 注册

Security安全性

  • Repo matches the facts registered here; archived or abandoned?仓库是否与页面登记一致,是否归档或长期停更
  • Safety of preinstall / install / postinstall and install.sh / setup.ps1preinstall / install / postinstall 与 install.sh、setup.ps1 是否安全
  • curl|bash, download-then-execute, obfuscation, unrelated domains → stop immediatelycurl|bash、下载即执行、混淆代码、无关域名 → 立刻停止
  • Typosquatting or unmaintained packages among the new dependencies新增依赖里有没有 typosquatting 或无人维护的包
  • Requested permissions vs. what the feature actually needs申请了哪些权限、是否超出功能所需(filesystem / network / shell / clipboard)
  • Any sudo / admin requirement, plus uninstall and rollback是否要求 sudo / 管理员权限,以及卸载与回滚方式

Anything uncertain must be marked unknown with a note on how to confirm it. This site's signal screen is a static snapshot, not a security audit.拿不准的必须标「未知」并说明要我怎么确认。本站的信号筛查是静态快照,不能替代安全审计。

Or use CLI install (for developers)或使用命令行安装(适合开发者)

CLI Install命令行安装

dsh plugin --profile web add @yanglaofish/dsh-proxy-pro

把 yanglaofish/dsh-proxy-pro 加入你的 DSH 配置(web profile)即可启用。

READMEREADME

dsh-proxy-pro

一个 DeepSeek Harness(DSH)插件的代理管理器:把整个运行时(模型请求、web_search / web_fetch、spawned 工具)统一路由到 Windows 系统代理或自定义地址,并提供随时可见、一键切换、可诊断的体验。

区别于原 dsh-plugin-proxy 的核心差异:

  • web_fetch / web_search 真正走代理。原插件只换 undici 全局 dispatcher + env,而 dsh-web-fetch-http 的 proxyRouteFor() 只读 @deepseek-ai/dsh-http-proxy 的模块级策略——本插件通过 installProxyFromEnvironment() 纳入这条通道,web_fetch 的网络故障(fetch failed)被根治。
  • 对话头部一键开关:每会话头部胶囊按钮(绿 = ON / 红 = OFF),点击即切换;「关→开」兼作手动重检——触发 host 现读注册表并重新应用,代理出问题时直接在头部拨一下即可。
  • 设置页「代理配置」:显示运行时事实(生效地址 / 原因 / 直连名单)而非设置推断;模式仅「系统代理(Windows)/ 自定义地址」两个选项;内置按 URL 的路由诊断(PROXIED / DIRECT 判定 + 强制走代理 / 强制直连双通道探测 + NTLM 提示)。
  • 单一传输通道:env + dispatcher + 策略由 dsh-http-proxy 一体管理,插件不直接触碰 undici,杜绝双实例错版(UND_ERR_INVALID_ARG)。
  • 幂等内核:effKey 相同只刷快照、绝不重装 dispatcher——读型 API 与轮询永不触发重组(修复过"每次拉都重装导致桌面卡顿"的根因);「拉时现读」让页面看到的永远是新鲜事实而无需任何定时器。
  • 干净卸载:卸除时恢复 env / dispatcher / 策略,fire-and-forget 后台排空 keep-alive。

全部踩坑与设计决策见 docs/LESSONS.md(必读),规格与验收清单见 docs/SPEC.md。

安装

两种方式任选其一(npm 包已发布,拉取即用、免构建授权):

方式 A:npm 安装(推荐)

dsh plugin --profile web add @yanglaofish/dsh-proxy-pro
dsh plugin --profile test add @yanglaofish/dsh-proxy-pro

方式 B:GitHub 源安装

dsh plugin --profile web add github:yanglaofish/dsh-proxy-pro

安装完成后直接启动:

dsh web

使用

对话头部胶囊按钮 —— 每会话头部右侧的「代理 · ON system / OFF」:绿点 = 代理生效、红点 = 关闭;一点切换总开关。头部按钮为配置驱动(打开即绿、零轮询),「关→开」操作触发 host 现读系统注册表并重新应用——代理状态异常时,直接在头部拨一下即可重检修复。

设置 → 代理配置 ——

  • 状态行(置顶):生效地址 + 原因说明;右侧短小启用开关,切换立即生效。
  • 代理地址来源:仅「系统代理(Windows)」与「自定义地址」两个选项。「不使用代理」模式已从界面与 proxy_config 工具移除(scheme 保留 none 仅解析旧配置残留)。
  • 自定义地址:http://host:port 或裸 host:port。
  • 直连名单(NO_PROXY):编辑框下方显示当前生效名单;system 模式自动并入 Windows 系统 ProxyOverride(标注「含并入」),custom 模式只保留你自己的名单(不并入系统白名单)。
  • 路由诊断:输入 URL,勾选「使用代理」= 强制走代理探测 / 不勾 = 强制直连探测;对比两次结果即可判断该域名该不该加进直连名单。

模型侧 —— 系统提示实时标注代理状态;四个工具:

  • proxy_status — 查询当前状态:是否走代理、生效地址、NO_PROXY 名单、来源。
  • proxy_set — 一键开/关整个运行时(改配置持久化并立即生效)。
  • proxy_test — 单 URL 路由诊断:PROXIED / DIRECT 判定、NO_PROXY 命中、连通探测;HTTP 407 归类为 NTLM 认证失败并给出 keepalive 提示。
  • proxy_config — 读/改配置:开关、模式(system / custom)、自定义地址、NO_PROXY;可只传任意子集。

Showing the opening section of the README — the full document lives in the repository以上为 README 开头摘要,完整文档在仓库内 · View the full README on GitHub →在 GitHub 查看完整 README →

← 上一个 Prev dsh-code-review 下一个 Next dsh-coding-workspace →