deepseek-harness
deepseek-ai
DeepSeek Harness: Everything is a Plugin.
PROJECT TOPICS
PROJECT README
把 DeepSeek Harness 的 Web GUI(dsh web)打包成 Windows 桌面应用:
双击即用,无需在终端输入 npx @deepseek-ai/dsh web。
当前版本:1.0.3 —— 新增文件上传插件(📎 上传图片/Word/PDF,Agent 可读取)。 完整版本历史见 CHANGELOG.md。
dsh web 服务,并在原生窗口打开界面127.0.0.1:3080 已有 DSH 实例在运行 → 直接复用,不重复启动%APPDATA%\DeepSeek Harness Desktop\logs\server.loguploaded_files / read_uploaded_file 工具读取内容(见下文专章)| 版本 | 说明 |
|---|---|
| 1.0.3 | 文件上传插件(📎 上传 + docx/pdf 文本提取 + Agent 工具 + 一键安装脚本) |
| 1.0.2 | 图标更新(DeepSeek 卡通娘 v2) |
| 1.0.1 | 图标更新(DeepSeek 卡通娘) |
| 1.0.0 | 初始版本:桌面套壳应用 |
详细变更见 CHANGELOG.md。
DeepSeek Harness(DSH)本身是命令行工具:dsh web 会在本机启动一个 Web
服务器(默认 http://127.0.0.1:3080),托管整个 GUI(前端页面 + 后端 API +
Agent 会话)。平时你需要手动执行命令、再开浏览器访问。本应用是一个
Electron 壳,把整个过程自动化:
npx --yes @deepseek-ai/dsh 下载;node <bin.js> web --port <n>);__DSH_BOOT__);exe 本身不包含 dsh 本体,只负责「查找 + 启动 + 装壳」。dsh 升级无需重新 打包;但新主机首次运行需要联网(通过 npx 自动获取 dsh 包)。
cd dsh-desktop
npm install # 安装 electron + electron-builder(含 Electron 二进制下载)
npm start # 开发模式直接运行
npm run dist # 生成 dist\DeepSeek-Harness-Desktop-1.0.0-portable.exe
然后运行 scripts\创建桌面快捷方式.cmd,桌面上就会出现
“DeepSeek Harness Desktop” 快捷方式,以后双击即可使用。
(也可以直接把 portable exe 复制到任何位置双击运行。)
| 条件 | 说明 |
|---|---|
| Windows x64 | 预编译的 portable exe 仅支持 Windows x64 |
| Node.js 18+ | 启动 dsh 服务需要 node(到 nodejs.org 安装 LTS 版) |
| 网络 | 首次运行需要联网,通过 npx 获取 dsh 包 |
| Edge 浏览器(仅方式 C) | Windows 10/11 自带 |
macOS / Linux 不能用现成 exe,请按「方式 B」在对应系统上重新构建。
dist\DeepSeek-Harness-Desktop-1.0.0-portable.exe(约 70MB)拷到新主机;npx --yes @deepseek-ai/dsh 下载并启动服务,
稍候即弹出窗口,即可使用。提示:
npm config set registry https://registry.npmmirror.com;scripts\创建桌面快捷方式.cmd。git clone https://github.com/pig1et7/DeepSeek-Harness-Desktop
cd DeepSeek-Harness-Desktop
npm install # 安装 electron + electron-builder(含 Electron 二进制下载,较慢)
npm start # 开发模式直接运行
npm run dist # 打包:生成 dist\DeepSeek-Harness-Desktop-1.0.0-portable.exe
注意事项:
Cannot create symbolic link(winCodeSign
解压失败),先运行一次再打包:powershell -ExecutionPolicy Bypass -File scripts\install-7za-wrapper.ps1
详见下文「重新打包的注意事项」;
npm i @deepseek-ai/dsh,应用会优先使用它。只需拷贝 scripts\启动-零依赖版.cmd 和 scripts\launch-edge-appmode.ps1
两个文件:
dsh web + 用 Edge「应用模式」窗口打开 GUI
(无地址栏,类似桌面应用);在以下任一位置放一个 config.json(两个位置同时存在时优先 exe 同目录):
PORTABLE_EXECUTABLE_DIR);如果该目录读取失败
(部分系统上 portable 环境变量未注入),改放
%APPDATA%\DeepSeek Harness Desktop\config.json(推荐,路径固定)参照 config.example.json:
{
"port": 3080,
"workspaceDir": "D:\\my-projects",
"dshBin": "",
"nodeBin": ""
}
| 键 | 说明 |
|---|---|
port |
起始端口,默认 3080;被占用时自动向后找空闲端口 |
workspaceDir |
dsh 服务的工作目录,默认 exe 所在目录 |
dshBin |
手动指定 @deepseek-ai/dsh/lib/bin.js 的绝对路径(通常无需设置) |
nodeBin |
手动指定 node 可执行文件路径(通常无需设置) |
npmCache |
手动指定 npm 缓存目录(用于搜索 npx 缓存中的 dsh) |
config.json 中的 dshBinnode_modules\@deepseek-ai\dsh(若在应用目录里 npm i @deepseek-ai/dsh)_npx\*\node_modules\@deepseek-ai\dsh(本机已存在)dshnpx --yes @deepseek-ai/dsh web --port <n>仓库里附带一个 文件上传插件:在 Web GUI 输入框左侧增加 📎 上传按钮,
可上传图片 / Word / PDF / 文本等文件,Agent 可通过 uploaded_files 和
read_uploaded_file 工具读取(docx/pdf 自动提取文本)。
安装(在 web profile 里):
cd $env:DSH_HOME\profiles\web
pnpm add D:\path\to\plugins\dsh-upload
# 然后在 cordis.patch.yml 追加:
# - insert:
# - id: upload
# name: 'dsh-upload'
# 最后重启 dsh web
在另一台主机上安装(推荐,一键脚本):
# 1. 先在有 DSH 的主机上 clone 本仓库(或用 git sparse 只取 plugins\dsh-upload)
git clone https://github.com/pig1et7/DeepSeek-Harness-Desktop
cd DeepSeek-Harness-Desktop
# 2. 一键安装(自动复制插件、装依赖、写入 profile 配置)
powershell -ExecutionPolicy Bypass -File scripts\install-upload-plugin.ps1
# 3. 重启 dsh web 即可
脚本会把插件复制到 $DSH_HOME\plugins\dsh-upload(稳定位置,不依赖仓库路径),
幂等可重复执行。手动安装见 plugins/dsh-upload/README.md。
详见 plugins/dsh-upload/README.md。
运行一次 scripts\setup-desktop.ps1 自动完成全套流程:
# 1. 在目标主机获取仓库(已 clone 则跳过)
git clone https://github.com/pig1et7/DeepSeek-Harness-Desktop
cd DeepSeek-Harness-Desktop
# 2. 一键安装:检查 Node.js → 准备 exe → 初始化 DSH → 装插件 → 建快捷方式
# 有 portable exe 时(最快):
powershell -ExecutionPolicy Bypass -File scripts\setup-desktop.ps1 -ExePath D:\downloads\DeepSeek-Harness-Desktop-1.0.3-portable.exe
# 或从源码自动构建(首次需下载 Electron,较慢):
powershell -ExecutionPolicy Bypass -File scripts\setup-desktop.ps1 -Build
脚本会自动:
%USERPROFILE%\DeepSeek-Harness-Desktop\完成后双击桌面「DeepSeek Harness Desktop」即可,输入框左侧出现 📎。
DeepSeek-Harness-Desktop-1.0.3-portable.exe 复制到
新主机(或从 GitHub Releases 下载)git clone https://github.com/pig1et7/DeepSeek-Harness-Desktop
cd DeepSeek-Harness-Desktop
powershell -ExecutionPolicy Bypass -File scripts\install-upload-plugin.ps1
脚本自动完成:复制插件到 $DSH_HOME\plugins\dsh-upload → 安装依赖 →
写入 profile 配置;没有 pnpm 时自动回退 npm。
git clone https://github.com/pig1et7/DeepSeek-Harness-Desktop
cd DeepSeek-Harness-Desktop
npm install # 安装 electron + electron-builder
npm run dist # 生成 portable exe(dist 目录)
之后回到方式 A 的第 3–5 步。非管理员账户打包报「Cannot create symbolic
link」时,先运行 scripts\install-7za-wrapper.ps1(见「重新打包的注意事项」)。
桌面应用启动的 dsh 服务使用 $DSH_HOME(默认 ~\.dsh,Windows 即
C:\Users\<你>\.dsh)下的 web profile。安装脚本会自动定位
$env:DSH_HOME\profiles\web(未设置 DSH_HOME 时用 ~\.dsh\profiles\web)。
npm config set registry https://registry.npmmirror.complugins/dsh-upload/README.mdnpm run smoke # 复用 3080 已有实例并截图(smoke.png)
npx electron . --smoke-test --smoke-port=3188 --smoke-out=smoke-spawn.png
# 自行启动服务(3188 端口)并截图
node_modules\7zip-bin\win\x64\7za.exe 已被替换为一个透明包装器
(源码在 scripts\7za-wrapper.cs),用于解决非管理员账户下
electron-builder 解压 winCodeSign 时“无法创建符号链接”的报错。
npm install(node_modules 被重装),先运行一次:powershell -ExecutionPolicy Bypass -File scripts\install-7za-wrapper.ps1
然后再 npm run dist。
node_modules\7zip-bin\win\x64\7za-real.exe 并把 7za.exe 改回来即可。config.json 的 port。%APPDATA%\DeepSeek Harness Desktop\logs\server.log。$DSH_HOME),换主机是一套全新的,与本项目无关。dsh web 启动的),那个实例不受影响。CLASSIFICATION EVIDENCE
系统优先读取 GitHub Topics,再与站内分类词典和词根规则比对。当前命中: desktop-app。