zerorigin-studio/dsh-deepseek-chat
Project Overview项目介绍
DSH plugin that adds a "Web Chat" button directly below the sidebar's "New Chat" control, opening chat.deepseek.com with matching width, height, and hover behavior. When run under dsh-desktop, the button uses a loopback bridge API with a per-instance token to open a separate chat sub-window, keeping the main harness page available for multitasking; in plain browsers or third-party shells, it gracefully degrades to in-page navigation so the entry never breaks. The entry can be toggled in settings (on by default). Note: the published build does not yet include the TypeScript source; only the compiled artifact is available.
DSH 插件,在侧边栏"新对话"按钮正下方新增"网页对话"入口,点击跳转 chat.deepseek.com,宽度、悬停动效与原生控件一致。配合 dsh-desktop 时,通过 loopback 桥接 API 打开独立子窗口,避免主页面被导航占用;在纯 Web 或第三方桌面壳中自动降级为原 webview 跳转,插件不会失效。设置页可开关该入口(默认开启)。注意:仅随官方 harness 侧边栏注入使用,编译产物中 TypeScript 源文件尚未发布。
请帮我了解并安装插件:【dsh-deepseek-chat】【https://github.com/zerorigin-studio/dsh-deepseek-chat】
Send this message to DSH in your current session. CLI install commands may not be accurate across systems — DSH will figure it out for you.把上面这条消息直接发给当前会话里的 DSH,让它帮你了解并安装。安装命令不一定准确,发给 DSH 更稳。
Or use CLI install (for developers)或使用命令行安装(适合开发者)
CLI Install命令行安装
dsh plugin --profile web add @zerorigin-studio/dsh-deepseek-chat
把 zerorigin-studio/dsh-deepseek-chat 加入你的 DSH 配置(web profile)即可启用。
READMEREADME
@zerorigin-studio/dsh-deepseek-chat
DeepSeek Harness 网页对话入口插件 —— 在侧边栏"新对话"按钮正下方显示一个"网页对话"按钮,点击打开 chat.deepseek.com。
✨ 特性
- 位置自然:按钮位于侧边栏新对话按钮正下方,宽度/高度/悬停动效与 harness 原生控件完全一致,展开态显示「网页对话」,收起态为 36px 图标(响应即时,无轮询延迟)
- 桌面独立窗口:在 dsh-desktop(Wails v3 启动器)下运行时,点击按钮通过本地桥接 API(
127.0.0.1随机端口 + 每实例随机 token)让启动器打开独立聊天子窗口——主窗口(harness 页面)不再被导航霸占,可同时多任务 - Web 环境降级:纯浏览器 / 官方浏览器模式(无
window.__DSH_DESKTOP_API__桥接)时自动降级为打开新标签页(chat.deepseek.com 在新标签页打开,当前 harness 页面不被整页跳转走),插件功能永不失效 - 持久化开关:设置页可开关入口(
dsh-deepseek-chat.showEntry,默认开)
📦 安装
# 方式一:npm 官方安装(推荐)
dsh plugin --profile web add @zerorigin-studio/dsh-deepseek-chat
# 方式二:Gitee Release tgz(无 npm registry 时)
# https://gitee.com/coldcgh/dsh-deepseek-chat/releases/download/0.3.4/zerorigin-studio-dsh-deepseek-chat-0.3.4.tgz
curl -L -o dsh-deepseek-chat.tgz https://gitee.com/coldcgh/dsh-deepseek-chat/releases/download/0.3.4/zerorigin-studio-dsh-deepseek-chat-0.3.4.tgz
dsh plugin --profile web add ./dsh-deepseek-chat.tgz
# 方式三:从源码构建安装(开发测试)
cd dsh-deepseek-chat && npm pack
dsh plugin --profile web add ./zerorigin-studio-dsh-deepseek-chat-0.3.4.tgz
重启 harness 后,侧边栏"新对话"按钮正下方出现「网页对话」按钮。
🖥️ 桌面多窗口(标准 SDK,可选增强)
dsh-desktop-shell 客户端(≥0.2.9)向托管页面注入标准桌面 SDK window.dsh.desktop:
await window.dsh.desktop.openWindow({ url: CHAT_URL, title: "DeepSeek 网页对话" });
- 底层走 WebView2 宿主消息(
window.chrome.webview.postMessage→{ type: "dsh.desktop.openWindow", ... }),无跨端口 fetch/CORS; - 无宿主(纯 web / 官方浏览器模式):自动降级为打开 chat.deepseek.com 的新标签页(当前 harness 页面不被整页跳转走),插件永不失效;
- 兼容旧桥接:宿主仍注入
window.__DSH_DESKTOP_API__(HTTP 桥接,loopback + token),老协议路径继续可用。
📁 结构
lib/index.js server 端:settings 注册(showEntry 开关,ctx 由宿主注入)
lib/client.js client 端:侧边栏入口按钮 + 布局/降级逻辑(编译产物)
cordis.patch.yml bundle patch:把插件加入 web roster
当前分发编译产物;源文件(tsx)与构建脚本在后续版本补齐(tsdown 构建)。
🔧 开发
npm pack # 构建本地 tgz
dsh plugin --profile web add ./zerorigin-studio-dsh-deepseek-chat-0.3.4.tgz
📝 License
MIT © caoganghui
aa2246740/dsh-watcher
chushixixin/dsh-harness-mcp-server
lehhair/dsh-split-panes
kongdexu/dsh-nav-pointer