dsh-web-search-ddg
aooyoo
Zero-token DuckDuckGo search provider for the DeepSeek Harness (DSH) web seam — local headless browser, no API key, no m…
PROJECT TOPICS
PROJECT README
简体中文 | English
DSH WebUI 文件输入增强插件:Ctrl+V 粘贴 + 全页面拖拽 + 选择文件/文件夹,发送时复制进会话工作区临时附件目录,并把对话气泡里的附件文本块折叠为文件 chip。
派生自 dsh-external/dsh-multimedia-webui-input(MIT),在其基础上新增剪贴板粘贴输入、首次告知弹窗与气泡附件折叠。
兼容 DSH snapshot0808(snapshots/20260808T121140Z)、snapshot0809(snapshots/20260809T140917Z)、snapshot0810(snapshots/20260810T155924Z)、snapshot0811(snapshots/20260811T152241Z)与最终快照 snapshot0812(snapshots/20260812T172954Z-final):注册的槽位(conversation.input.left / conversation.input.dock / settings.section)在 0808~0812 上均保持声明;依赖服务在 0812 经历官方更名——slash → inputTriggers(client 侧,随包名 @deepseek-ai/dsh-client-ui-slash → @deepseek-ai/dsh-client-ui-input-trigger 一并迁移)、host 侧 httpServer → webServer,本插件 v0.1.3 已同步迁移(lib 两半 + dsh.client 元数据,见下)。0809 实机验证——粘贴 → 复制进工作区附件目录 → 气泡折叠 chip 全链路可用;0811 与 0812 最终快照实机 boot 验证通过(见下)。
npm 发版兼容:兼容 DSH npm 发版 @deepseek-ai/dsh@0.0.1-rc.5(dist-tag next,即最终快照 snapshot0812 的 npm 发版;npm exec -p @deepseek-ai/dsh@0.0.1-rc.5 -- dsh --profile web --port <port> 可访问指定版本并启动,lib 生产模式),同时保持兼容 @deepseek-ai/dsh@0.0.1-rc.2(snapshot0811 的 npm 发版)。实测(npm rc.5 基线):dsh web 启动后 window.__DSH_BOOT__ 清单包含 @dsh-community/dsh-paste-input(inject: dsh-client-runtime/dsh-client-ui-input-trigger/dsh-client-ui-conversation/dsh-client-ui-settings),/plugins/@dsh-community/dsh-paste-input/client.js 返回 200;client 半经 window.__ModuleLoader__.load 正确注册,host 半的 webServer 上传路由在 rc.5 consumer 中加载成功。本插件无任何 cordis 依赖(无 peerDependencies;lib 构建产物无 cordis 导入)——0811 的 cordis 更名(cordis → @deepseek-ai/cordis)与本插件零影响,npm install 无需额外参数。
dsh.plugin.json 清单 + resolveClientPath(packages/plugin/plugin)已删除,改为 package.json 的 dshClient 声明(platform: 'web',可选 inject/immediately)+ exports["./client"] 指向构建产物;宿主扫描 loader 条目组成 boot 图,Web 端从 /plugins/<id>/client.js 拉取。本插件 package.json 已满足该声明,无需改动。==== DSH_PASTE_INPUT_V1 ==== 标记)与 .dsh/tmp/attachments/<session>/<send>/ 目录逻辑不依赖快照内部实现,0809 实测全链路成功。dshClient 包的构建产物,缺失会抛 ClientPackageCompositionError 并拒绝启动 dsh web——升级快照或改源码后必须重新 pnpm run build 再启动,否则浏览器拉到的是旧 lib/client.js。dsh.client(packages/client/modules/src/index.ts 的 resolveMeta,pkg.dsh.client);顶层 dshClient 字段读不到会静默丢出 boot 图——无日志、无报错,"启动顺利但插件全没"。本插件已从顶层 dshClient 迁移为嵌套 dsh.client(inject 原样保留);lib/client.js 构建产物不变(package.json 不参与编译),symlink 安装改源仓库即生效,无需重装。cordis@4.0.0-rc.7 更名为 @deepseek-ai/cordis@4.0.1-rc.1(官方 client 包随之全部改从 @deepseek-ai/cordis 导入)。本插件不导入 cordis(无 peerDependencies、lib 构建产物无 cordis 引用),无需任何迁移。snapshots/20260811T152241Z)web 启动后 window.__DSH_BOOT__ 清单包含 @dsh-community/dsh-paste-input(inject: dsh-client-runtime/dsh-client-ui-slash/dsh-client-ui-conversation/dsh-client-ui-settings),/plugins/@dsh-community/dsh-paste-input/client.js 返回 200。本插件使用的槽位 conversation.input.left/conversation.input.dock(ui-conversation 声明)与 settings.section(ui-settings 声明)在 0811 上保持声明;slash 服务与 window.__ModuleLoader__ 加载协议不变。slash → inputTriggers:最终快照将输入触发服务由 slash 更名为 inputTriggers(随官方包 @deepseek-ai/dsh-client-ui-slash → @deepseek-ai/dsh-client-ui-input-trigger 一并改名,服务与 registerSource API 本身不变)。本插件 lib/client.js 已同步迁移 4 处(两个 inject 数组 + ctx.get + registerSource 调用),dsh.client 元数据的 inject 列表同步由 dsh-client-ui-slash 迁移为 dsh-client-ui-input-trigger。httpServer → webServer:最终快照将 host 侧 HTTP 路由注册服务由 httpServer 更名为 webServer(packages/host/webserver 提供,register({ kind: 'prefix', path, handler }) API 不变)。本插件 lib/index.js 已同步迁移 2 处(inject 数组 + ctx.webServer.register 调用),上传路由照常注册。cordis → @deepseek-ai/cordis 更名(npm rc.5 基线上为 4.0.1-rc.4)零影响,npm install 无需额外参数。snapshots/20260812T172954Z-final)web 启动后 window.__DSH_BOOT__ 清单包含 @dsh-community/dsh-paste-input;npm rc.5 consumer dsh web 启动后 boot 清单同样包含本插件(inject 已显示 dsh-client-ui-input-trigger),/plugins/@dsh-community/dsh-paste-input/client.js 返回 200,host 半 webServer 上传路由加载成功。本插件使用的槽位 conversation.input.left/conversation.input.dock(ui-conversation 声明)与 settings.section(ui-settings 声明)在最终快照与 rc.5 上保持声明;inputTriggers 服务与 window.__ModuleLoader__ 加载协议不变。slash → inputTriggers(lib/client.js 4 处:inject 数组 ×2 + ctx.get + registerSource 调用),dsh.client 元数据 inject 由 @deepseek-ai/dsh-client-ui-slash 迁移为 @deepseek-ai/dsh-client-ui-input-trigger——最终快照将输入触发服务与官方包一并更名,服务与 registerSource API 不变httpServer → webServer(lib/index.js 2 处:inject 数组 + ctx.webServer.register 调用)——最终快照将 host 侧 HTTP 路由服务更名,register({ kind: 'prefix', path, handler }) API 不变snapshots/20260812T172954Z-final)与 npm rc.5(@deepseek-ai/dsh@0.0.1-rc.5)consumer 实机 boot 验证通过(boot 清单包含本插件、client.js 返回 200、webServer 上传路由加载成功)dshClient 声明迁移为嵌套 dsh.client(inject 原样保留)——0810 的 ClientModuleHostService 只读 pkg.dsh.client,旧字段会被静默忽略导致插件不进 boot 图==== DSH_PASTE_INPUT_V1 ==== 标记协议)自动折叠为 📎 文件 chip;你在 chip 前后输入的文字按原顺序穿插保留(多文件发送时文字与各文件的 chip 逐段交错,chip 独占一行),悬停 chip 显示完整原始附件块(路径/清单/文件列表),点击 chip 复制完整路径<会话工作区>/.dsh/tmp/attachments/<session>/<send>/,绝对路径随消息前置给模型,无权限问题配合 dsh-external/dsh-vision 插件(注册 view_image 工具,桥接任意 OpenAI 兼容 VLM,默认智谱免费 glm-4.6v-flash),本插件的粘贴/拖拽截图可以直接识别:
view_image → VLM 返回图片内容(OCR 提取文字、读图表、识别 UI 布局等)两个插件零耦合:本插件负责"文件进对话",dsh-vision 负责"看图",通过工作区附件路径衔接。
附件块以显式标记界定(模型可见文本,气泡折叠识别用):
==== DSH_PASTE_INPUT_V1 ====
<附件根目录绝对路径>
Files: N
Manifest: .dsh-paste-input.json
Attached files (paths are relative to the root above):
- "file.txt" (2.0 KiB)
==== END DSH_PASTE_INPUT ====
仅支持标记格式(历史无标记消息不折叠)。标记前后各带空行,保证用户输入的文字与标记不在同一行。
文件名 作为相对路径存储——需要原路径的场景请使用拖拽或选择文件/文件夹按钮dsh plugin --profile web add link:E:\deepseek-harness\dsh-paste-input
# 并在 ~/.dsh/profiles/web/cordis.patch.yml 追加:
# - insert:
# - id: dsh-paste-input
# name: '@dsh-community/dsh-paste-input'
重启 dsh web 生效。
MIT(含 dsh-multimedia-webui-input 派生声明)
CLASSIFICATION EVIDENCE
系统优先读取 GitHub Topics,再与站内分类词典和词根规则比对。