为 DeepSeek Harness Web 版提供工作区文件树面板,可在对话页头一键开关,支持新建、重命名文件目录以及把路径加入对话草稿。
ⓘ This plugin is a sub-package of the op7418/pilot-harness monorepo — stars and activity count the whole repository.
- Language
- TypeScript
- License
- MIT
- Branch
- main
Install
$ dsh plugin --profile web add github:op7418/pilot-harness/packages/workspace/ui-worktreeRun the command above in your terminal to install this plugin via the dsh CLI. You can switch Profile in the top-right corner. New to dsh? Read the beginner tutorial
Install via your agent
Install the DeepSeek Harness plugin op7418/pilot-harness/packages/workspace/ui-worktree for me: review the repository at https://github.com/op7418/pilot-harness.git first, then run the install command and verify the plugin loads successfully.
Paste this instruction to the DSH Web GUI assistant — it will install and verify for you.
一句话定位
pilot-harness(包名 @deepseek-ai/dsh-ui-worktree,Cordis 插件 ID pilot-worktree)是 DeepSeek Harness Web 版的工作区文件树面板。在对话页头多出一个 "Files" 切换按钮,点开后右侧出现一栏真实布局的文件目录树,方便浏览当前项目、创建/重命名文件/目录,以及把文件路径以 @路径 形式快速加入对话草稿。
核心能力
- 在会话头新增 "Files" 切换按钮,弹出右侧文件树侧栏并自动收窄对话区宽度
- 列出当前 Workspace 的目录树,支持嵌套展开与目录/文件排序
- 显示 Workspace 根目录的可见文件数(自动跳过
.git、.DS_Store、node_modules、符号链接) - 每个文件/文件夹行提供三点菜单:用本机应用打开、把
@路径追加到当前会话草稿、重命名 - 工具栏支持新建文件、新建目录和整体刷新
- 通过
summary=branch路径直接读取.git/HEAD,在工作区侧栏概要里展示当前 Git 分支(游离 HEAD 显示短提交前缀,非 Git 项目不显示这一行)
技术实现
- 语言: TypeScript + React(TSX 组件)
- 关键依赖:
@deepseek-ai/cordis、@deepseek-ai/dsh-client-runtime、@deepseek-ai/dsh-client-connection、@deepseek-ai/dsh-workspace - 架构模式: 双面插件 ——
src/index.ts注册 Host 端/pilot-worktreeRPC(loopback 授权),src/client/index.ts注册浏览器端 React 组件并通过 cordis patch 注入宿主 - 入口文件:
src/index.ts(Host RPC 注册)/src/client/index.ts(浏览器组件注册)/cordis.patch.yml(cordis 装配 patch)
适用场景
想在和 AI 对话时直接浏览工作区文件、引用多个路径或快速新建/整理项目目录的人。比如开发者跟 AI 讨论代码时想引用 src/auth/login.ts 这种具体路径,或者要在不离开对话页的前提下新建文件/目录并立即让 AI 看到。
前置依赖与兼容性
| 依赖 | 最低版本 | 说明 |
|---|---|---|
| DSH(宿主) | 未声明(需 Pilot Harness v0.1.0+) | 宿主必须公开 conversation.session.header.utilities、shell.right-sidebar、sidebar.workspaces.session.detail 三个呈现槽位 |
| Node.js | ^22.19.0 || >=24.0.0 | 来自根 package.json 的 engines.node |
| 平台 | 跨平台 | 源码头部只引用 node:fs/promises 等内置模块,未声明 os/cpu 限制 |
| 原生模块 | 无 | 仅使用 Node 内置 fs/promises、path,无 node-pty 等原生依赖 |
安装方式
dsh plugin --profile web add github:op7418/pilot-harness/packages/workspace/ui-worktree
配置项
本插件无需额外配置。所有交互参数(工作区 ID、相对路径、操作类型)都通过 RPC 请求动态传入,源码中未暴露可由用户在 cordis.yml 调整的 Config 字段。
常见问题
Q: 这个插件依赖 Electron 或桌面客户端吗?
A: 不依赖。它是普通 Web profile 插件,浏览器端和 Host 端通过 loopback 授权的 Connection RPC 通信,不依赖 Electron。原生"打开文件"调用走的是宿主运行时受 loopback 保护的 openPath 路径,不绕过浏览器安全边界。
Q: 安装后看不到 Files 按钮或右侧栏怎么办?
A: 上游 Harness 版本必须支持三个呈现槽位契约 —— conversation.session.header.utilities、shell.right-sidebar、sidebar.workspaces.session.detail。Pilot Harness v0.1.0 已包含这些契约;旧版 Harness 可以加载插件但无法渲染 UI。
Q: 能删除文件吗?
A: 不能。删除属于不可逆操作,插件有意只暴露新建文件、新建目录、重命名三种目录操作。需要删除文件请使用系统文件管理器或命令行工具。
Q: 面板里看不到某些文件?
A: 插件主动跳过 .git、.DS_Store、node_modules、符号链接,以及非常规的文件类型(如 socket、块设备)。单个目录的列举上限是 5,000 项、Workspace 根目录的递归计数上限是 20,000 个可见文件,超出会显示为"截断"提示而不是无限制读取。
Q: 可以远程访问文件吗?
A: 不可以。RPC 通道使用严格 loopback 授权,不提供 trusted-host 例外。即使把 LAN origin 加到 Harness 的 trustedHosts 设置也不会获得远程文件系统访问权限 —— 远程 Web 场景需要插件未提供的独立认证传输层。
Q: 如何确认安装成功?
A: 安装后重启 Web profile,然后运行 dsh --profile web --dump-config,确认输出里列出 pilot-worktree 条目。
Q: 如何卸载?
A: 运行 dsh plugin --profile web remove @deepseek-ai/dsh-ui-worktree,重启 Web profile 后标题栏的 Files 控件和右侧栏会一起消失。
Q: 把文件加到对话草稿时,AI 真的会"看到"这个路径吗?
A: 只是把 @路径 文本追加到用户草稿里,是否发送由 conversation 包决定;插件不注入隐藏模型上下文、不添加工具 Schema、也不写 Session 事件。
上手难度
入门 —— 安装一条命令后无需任何配置,会话头即出现 Files 按钮;普通用户也能直接使用浏览、新建、重命名和路径引用。
已知问题与限制
- Workspace 根目录递归统计在达到 20,000 个可见文件后停止,并标记为截断计数
- 单个目录列举在 5,000 项后停止并标记为截断,避免一次性缓冲整个超大目录
- 故意不提供删除操作(不可逆),目前支持的目录变更只有新建文件、新建目录、重命名
- 名称校验会拒绝 Windows 保留设备名(CON/PRN/AUX/NUL/COM1-9/LPT1-9 等)、备用数据流语法、末尾带点的名称;重命名不会覆盖已有条目,目标冲突时报错
- 原生标题栏拖动和原生目录选择框是桌面外壳能力,纯浏览器组合无法获得
- 文件 RPC 严格 loopback 授权,没有 trusted-host 例外;LAN 远程访问不被支持
- 不暴露 Git 子目录详情、依赖目录、平台元数据和符号链接
- 旧版上游 Harness(缺少三个呈现槽位契约)可以加载 bundle 但无法显示 Files 控件或右侧栏
Pilot Harness
English | 中文
A CodePilot-inspired desktop client and plugin suite for DeepSeek Harness.
Run the DeepSeek Harness plugin runtime as a focused native app, manage providers and multimodal models visually, and keep desktop additions isolated as ordinary Harness plugins.
Quick start · Plugins · Architecture · MIT License
Why Pilot Harness
DeepSeek Harness has a powerful “everything is a plugin” architecture, but its default experience is designed around a CLI-launched Web UI. Pilot Harness keeps that runtime model and adds the parts expected from a daily desktop product:
- A real desktop app — Electron packages the local Harness runtime for macOS, Windows, and Linux, owns native window behavior, and provides a recovery screen when startup needs attention.
- A calmer CodePilot-inspired interface — consistent tokens, radii, menus, hover states, settings cards, Markdown, conversation/trajectory navigation, and platform-aware title bars.
- Provider and model management — connect supported providers, declare an OpenAI-compatible endpoint, manage credentials separately from settings, browse the live model catalog, and identify image-capable models.
- Workspace context without clutter — project-aware conversation rows show branch, state, reminder summary, mode, and model details, while Files opens as a true right sidebar.
- Plugin-first extensions — the theme, Worktree sidebar, Schedule summary, and Session-log export remain Cordis/DeepSeek Harness rows rather than desktop-only business logic.
- Reversible customization — disabling the CodePilot theme row removes its product mark and visual overrides so the stock Harness presentation can take over again.
Pilot Harness does not replace the DeepSeek Harness agent loop, Session log, tool pipeline, provider contracts, or RPC implementation. Electron owns packaging and native integration; the composed Harness plugin tree remains the application runtime.
Quick Start
Download the installer for your system from GitHub Releases:
| Platform | Download | Install and handle the security prompt |
|---|---|---|
| macOS (Apple Silicon) | DMG installer ZIP app | Open the DMG, drag pilot-harness.app into Applications, and launch it normally. A formal Release is published only after its Developer ID signature has been verified. Because notarization is not enabled yet, Gatekeeper may still block the first launch; in that case open System Settings → Privacy & Security, click Open Anyway, then confirm Open. Do not run xattr or disable Gatekeeper for a formal Release. If macOS reports that the signed app is damaged, delete it, verify the Release checksum, and download it again instead of bypassing the warning. Apple's security instructions. |
| Windows (x64) | EXE installer | Run the EXE. If Microsoft Defender SmartScreen says Windows protected your PC, first confirm that the file came from this Release, then choose More info → Run anyway. Do not disable SmartScreen globally. A managed computer may hide this option; contact its administrator instead. Microsoft's SmartScreen explanation. |
| Linux (x64) | AppImage DEB RPM | DEB: sudo apt install ./Pilot-Harness-Linux-amd64.debRPM: sudo dnf install ./Pilot-Harness-Linux-x86_64.rpmAppImage: chmod +x Pilot-Harness-Linux-x86_64.AppImage, then ./Pilot-Harness-Linux-x86_64.AppImage. If the file manager blocks execution, enable Allow executing file as program in file properties. The preview packages are unsigned, so only accept a package-manager warning after confirming the official Release source. |
The table links to formal end-user Releases, not the seven-day Actions preview artifacts. Formal macOS files must pass Developer ID verification before publication; while they remain unnotarized, the only expected extra step is Open Anyway in System Settings. Preview macOS artifacts are ad-hoc signed for CI verification and are not the normal installation path. Once notarization is enabled, the Open Anyway step should normally disappear and this guide must be updated with the release pipeline. Windows and Linux preview installers remain unsigned. Only override an operating-system warning for files downloaded from this repository's official GitHub Release; do not turn off platform security globally.
After installation, open Pilot Harness, select a Workspace, then go to Settings → Providers to connect a provider and choose one of its available models. No separate DeepSeek Harness installation is required for the desktop app. Source setup and packaging instructions live in Development, not in the user installation path.
What is included
| Area | What Pilot Harness adds | Ownership |
|---|---|---|
| Desktop shell | Native window, local runtime lifecycle, directory dialog, recovery, installers, and platform icons | Electron app |
| Visual system | CodePilot-inspired design tokens and component contracts | @deepseek-ai/dsh-client-ui-codepilot-theme |
| Workspace Files | Right sidebar, file count, branch summary, row actions, and @path insertion | @deepseek-ai/dsh-ui-worktree |
| Reminder summary | Active reminder count and nearest scheduled time in Session hover details | @deepseek-ai/dsh-ui-schedule-summary |
| Session export | Per-Session ZIP export from the Trajectory toolbar and /export | @deepseek-ai/dsh-session-log-export |
| Providers and models | Configurable adapter, credential/settings UI, live catalog, and multimodal labels | Existing Harness plugins plus the Pilot Harness desktop profile |
The provider/model experience is deliberately a profile composition, not a new provider implementation. It mounts existing adapter, Settings, and Credentials contracts, then replaces the desktop placeholder only after a real provider advertises a usable model.
Use the plugins independently
The desktop client already includes every plugin below. If you use a local DeepSeek Harness Web profile instead, install only the feature you want with one command; each release asset is a prebuilt dsh.bundle, so no repository clone, YAML patch, or local build is required.
CodePilot theme
dsh plugin --profile web add https://github.com/op7418/pilot-harness/releases/latest/download/deepseek-ai-dsh-client-ui-codepilot-theme-0.1.0-rc.5.tgz
Applies the Pilot Harness visual system and product mark. Removing the plugin restores the stock Harness presentation. See theme details.
Files sidebar
dsh plugin --profile web add https://github.com/op7418/pilot-harness/releases/latest/download/deepseek-ai-dsh-ui-worktree-0.1.0-rc.5.tgz
Adds the Workspace-confined right file sidebar, file count, branch summary, row actions, and @path insertion. See Files plugin details.
Reminder summary
dsh plugin --profile web add https://github.com/op7418/pilot-harness/releases/latest/download/deepseek-ai-dsh-ui-schedule-summary-0.1.0-rc.5.tgz
Adds active-reminder metadata to Session hover details while the upstream Schedule plugin remains the reminder authority. See reminder plugin details.
Session-log export
dsh plugin --profile web add https://github.com/op7418/pilot-harness/releases/latest/download/deepseek-ai-dsh-session-log-export-0.1.0-rc.7.tgz
Adds per-Session ZIP export to the Trajectory toolbar and the /export command. See export plugin details.
Restart the Web profile after installation and use dsh --profile web --dump-config to confirm the added row. Files and Reminder summary require the Pilot Harness UI slot contracts included in Pilot Harness v0.1.0; older upstream Harness builds can install their bundles but cannot render those two UI contributions.
Remove a plugin with the same package name shown in its details page, for example:
dsh plugin --profile web remove @deepseek-ai/dsh-ui-worktree
Development
git clone https://github.com/op7418/pilot-harness.git
cd pilot-harness
pnpm install
pnpm run desktop:dev
Run the desktop checks with:
pnpm run desktop:test
pnpm --filter @deepseek-ai/dsh-desktop run typecheck
pnpm --filter @deepseek-ai/dsh-desktop run test:e2e
Official installers are never built or uploaded from a developer machine. Every verified push to main, and a manual workflow dispatch without a release tag, produces seven-day Actions preview artifacts on native macOS, Windows, and Linux runners. A version-matched v* tag starts the formal path, verifies the platform artifacts and macOS Developer ID signature, generates SHA256SUMS.txt, and publishes the GitHub Release.
The Sync DeepSeek Harness upstream workflow checks the newest non-draft official release every day at 09:00 Asia/Shanghai. A clean update is merged without force-pushing, verified, committed to main, and dispatched to the same native release pipeline as v<upstream-version>-pilot.1. A merge conflict opens or refreshes a GitHub Issue and stops before changing main; missing macOS signing secrets also open an issue and leave the verified source synchronized without publishing an unsigned release. Rerunning the workflow after resolving either condition resumes the pending release.
For the underlying system, read the DeepSeek Harness architecture, development guide, and desktop architecture.
Upstream, attribution, and trademark notice
Pilot Harness is an independent community project derived from the MIT-licensed DeepSeek Harness and visually inspired by CodePilot. It is not an official DeepSeek product and is not endorsed by or affiliated with DeepSeek. “DeepSeek”, “DeepSeek Harness”, and “CodePilot” remain the property of their respective owners.
License
Pilot Harness is available under the MIT License. Third-party software and licenses are listed in THIRD_PARTY_NOTICES.md.
Listing badge
[](https://deepseek-plugin.org/plugins/op7418/pilot-harness/packages/workspace/ui-worktree)Paste this markdown into your GitHub README to link back to this listing. The badge only states the listing — not a security endorsement.