DSH Plugins Marketplace

DSH Plugins

Plugins

/

dsh-add-files

p

dsh-add-files

Manifest valid

DSH chat composer file/folder picker: add files or folders to a message as readable references Browse the filesystem and attach files/folders to DSH chat messages as <file>path</file> references the m

UI (client)

dsh-add-files

在 DeepSeek Harness 聊天输入框中,点击「+」右侧新增的 📁 按钮,浏览本机文件系统并把文件或文件夹作为引用芯片加入消息;发送时序列化为 <file>绝对路径</file> 交给模型,模型可直接用文件工具读取。

解决原版输入框「+」只能添加命令、无法选择目录添加文件/文件夹的问题。

特性

  • 工具行新按钮:输入框 + 号右侧新增 📁 按钮(位于加号与工作权限之间),与内置按钮同风格。
  • 打开即浏览:点击后直接打开内置文件浏览器,文件与文件夹都可勾选(支持多选),双击文件夹进入下一级。
  • 完整文件系统导航:面包屑从盘符根开始,支持上级、回到工作区、刷新;可自由跳转到任意磁盘目录。
  • 系统目录选择器:header 按钮「选择目录定位…」调用系统原生目录选择对话框快速定位到任意目录。
  • 记住上次位置:按会话记住最后浏览的目录,再次打开直接定位;目录失效自动回退到工作区根。
  • 引用芯片:选中项作为引用芯片(occurrence)插入输入草稿,可随消息发送、可用退格删除。
  • 斜杠菜单分组:输入 / 时菜单新增「文件」分组,可直接选工作区根目录下的文件/文件夹。
  • 模型可见路径:发送时每个引用序列化为 <file>路径</file>,模型可直接用 read/glob 等工具读取。

安装(挂载到 DSH)

插件由 DSH 的 loader 通过包名解析,因此包需要位于 Node 可解析的 node_modules 中,并在 web profile 的补丁层声明。

1. 放置包

方式 A:直接拷贝/软链到部署的 node_modules(推荐用目录链接,便于随源码更新):

# 把本仓库作为链接挂到部署的 node_modules(以 Windows junction 为例)
Remove-Item "D:\Deepseek_Harness\node_modules\@deepseek-ai\dsh-add-files" -Recurse -Force
New-Item -ItemType Junction -Path "D:\Deepseek_Harness\node_modules\@deepseek-ai\dsh-add-files" -Target "<本仓库绝对路径>"

方式 B:把 dsh-add-files 目录复制到 node_modules\@deepseek-ai\ 下(升级/重装依赖时可能被清理,注意备份)。

2. 在补丁层注册

编辑 web profile 的用户补丁文件(默认 %DSH_HOME%\profiles\web\cordis.patch.yml),追加:

- insert:
    - id: dsh-add-files
      name: '@deepseek-ai/dsh-add-files'

补丁层支持 HMR 热重载;若未生效,重启 DSH 即可。

3. 生效

刷新浏览器页面(F5 / Ctrl+Shift+R)。输入框工具行应出现 + → 📁 → 工作权限。

使用

  1. 点击输入框 + 右侧的 📁 按钮;
  2. 在文件浏览器中导航到目标目录(双击文件夹进入、面包屑/上级跳转、系统选择器快速定位);
  3. 勾选需要的文件或文件夹(可多选),或点「添加当前目录」把当前目录整体加入;
  4. 点「添加 (N)」,选中项以引用芯片形式出现在输入草稿末尾;
  5. 输入指令并发送——模型会收到 <file>路径</file> 形式的引用,可读取对应文件。

也可以直接在输入框输入 /,从「文件」分组中选择工作区根目录下的文件/文件夹。

目录结构

dsh-add-files/
├── package.json        # 包清单 + dsh.client web 声明
├── lib/
│   ├── index.js        # Host 端:/addfiles/list、/addfiles/root 两个 JSON 路由
│   └── client.js       # Web 端:浏览器 bundle(模块加载器格式)
  • Host 端(lib/index.js):通过 webServer.register 提供
    • GET /addfiles/list?path=<绝对目录> —— 列出一级目录(文件+文件夹、完整面包屑、父目录)
    • GET /addfiles/root?session=<会话id> —— 解析会话工作区根目录
  • Web 端(lib/client.js):注册到 conversation.input.left(按钮)与 conversation.input.overlay(弹窗),并注册 / 触发器的「文件」分组;引用插入复用平台原生的 slash/input-insert-reference 输入事件与 codec 序列化。

开发

  • 改 lib/index.js 或 lib/client.js 后,刷新页面 / 重启 DSH 即可生效(补丁层 HMR)。
  • 语法自检:node --check lib/index.js && node --check lib/client.js
  • Web bundle 是手写的模块加载器格式(window.__ModuleLoader__.load),不依赖构建步骤;如需 TypeScript 化请自行迁移构建。

License

MIT

Comments

Loading…

Similar plugins

dsh-files-to-chat

by ruaibeite

Right-click a file or folder in the DSH right sidebar file tree to add it to the conversation as an @ reference, with multi-select batch insertion.

UI & ExperienceManifest valid

★ 0

MIT

JavaScript

Nov 6, 2026

dsh plugin --profile web add @ruaibeite/dsh-files-to-chat

by zhousun55-byte

Upload files and folders straight into the conversation — images attach as real message blocks, text content is written into the composer draft, folders land by directory structure.

UI & ExperienceManifest valid

★ 0

MIT

JavaScript

Aug 16, 2026

dsh plugin --profile web add dsh-postman

by whyzsm

Attach files/folders in the DSH composer: clipboard paste, native picker, @-mention path search, paged Markdown conversion

Tools & CapabilitiesManifest valid

★ 0

MIT

JavaScript

Sep 28, 2026

dsh plugin --profile web add dsh-clipfile

by jidekaixin2dian

Right-click any file reference in the chat to open it, open it with an associated application, reveal it in the file manager, copy its path or contents, and save it.

UI & ExperienceDevelopment & InfrastructureManifest valid

★ 8

↓ 654/wk

MIT

JavaScript

Nov 17, 2026

dsh plugin --profile web add @jidekaixin2dian/dsh-file-actions

by sixzjd

Add folder references to the DeepSeek Harness web composer: host folder dialog, /folder command, and folder drag/paste resolved into @path mentions.

UI & ExperienceManifest valid

★ 0

MIT

JavaScript

Oct 12, 2026

dsh plugin --profile web add dsh-folder-attach

by weibaohui

dsh 插件 · 目录共享:任意可配置目录经 HTTP 在线浏览/上传/下载 + 对话框 @ 文件给 agent 处理

Tools & CapabilitiesDevelopment & InfrastructureManifest valid

★ 1

MIT

JavaScript

Oct 29, 2026

dsh plugin --profile web add @weibaohui/dsh-file-share