How to use deepseek-harness-desktop
Add an agent mode switch dropdown at the top of DSH Web chat sessions. Blank sessions switch in place. Sessions with history open a new session in the same workspace before switching, so the original conversation remains uninterrupted.
This article is auto-derived from indexed fields (wiki / faq / compatibility_json), not freshly AI-generated.
This article is derived from the plugin's already-indexed fields (wiki / faq / compatibility_json / readme), not freshly generated by AI. Source field is noted at the end of each section.
Quick start
dsh-mode-switcher
— source: plugin_wiki.wiki_content
Install & verify
dsh plugin --profile web add --allow-build=@linxin666/dsh-client-ui-mode-switcher github:ningbainb/deepseek-harness-desktop#path:packages/dsh-mode-switcher
Run the command above in your DSH Web Profile. Then enable the plugin in the plugin list.
— source: plugins.install
Key points
- 可靠 Windows 启动:移除 PowerShell 5.1
-WindowStyle Hidden与 Electron Node 模式的冲突,隐藏窗口仍由spawn的windowsHide处理;空旧补丁、状态订阅竞态和 IPC 错误不会再把启动页永久留在 8%。 - 验证过的 Runtime 组合:内置
@deepseek-ai/dsh0.1.0-rc.7、dshmarket1.15.0、Web UI 聚合0.2.3、兼容 rc.7 的 Codex Connect 与dsh-live-stats0.1.20,Stable 继续精确锁定而非追随latest。 - 托盘与后台自动化需显式选择:默认关闭仍会退出。选择“最小化到托盘并启用后台自动化”后,关闭主窗口才保留 Runtime 和到期任务;显式退出、更新、安全模式和崩溃路径一律完整停止。
- Host 持久任务调度:Task Board 保存时区、cron 槽位、租约、misfire/running 策略和确定性运行键;启用后台自动化时通过真实 DSH Session 执行并回写 Task Run,Host 不可用时仍回退浏览器调度。
- 可审计的扩展边界:扩展坞校验
dsh.compatibility的版本、Desktop API、能力、Surface 与运行时证据,并在 profile 写入desktop-plugins.lock.json。browser-safe SDK 不导入 Electron 或私有 DSH 模块;预览的外部打开仅传工作区根和相对路径,Host 验证后才交给系统。
— source: plugin_wiki.readme_en (fallback readme_raw)
FAQ
What can be seen after installation?
At the top of any session opened with dsh web, there will be a capsule-style dropdown listing all available agent modes exposed by the current DSH runtime (such as Plan / Code / etc.); selecting one will immediately switch the current session's working mode. The dropdown auto-hides when there are fewer than two available presets, avoiding meaningless UI controls (packages/dsh-mode-switcher/src/client/ModeSwitcher.tsx:26, README.md:14).
Will switching modes clear the current conversation history?
It depends. For an empty session (no messages yet), it switches in place on the original session; if the current session already has messages, the plugin first clears the current client's session view, then calls the workspace service to create a brand new empty session under the same path, and applies the selected mode to the new session (packages/dsh-mode-switcher/src/client/mode-controller.ts:53-70, tests/mode-controller.spec.ts:41-49). The historical data ends up in the host process's real session list and won't be deleted because of this—only the current chat view switches to the new session.
Which modes will be listed?
The list comes from the DSH official runtime (packages/dsh-mode-switcher/src/client/mode-controller.ts:39-51 calls api.agentPresets.list). Any preset with a broken field is filtered out; if a preset has no name, it falls back to using its id as the display text (packages/dsh-mode-switcher/src/client/mode-controller.ts:44-50).
How is a failed switch prompted?
Errors won't block the UI, but will be displayed in the dropdown's tooltip (title attribute); the next time you switch, the tooltip will be cleared (packages/dsh-mode-switcher/src/client/ModeSwitcher.tsx:30-40). Meanwhile, during the switching process, the dropdown is disabled and the mouse becomes a wait cursor to prevent duplicate clicks.
What if the new session doesn't appear?
The controller has a default 10-second timeout (timeoutMs default value, packages/dsh-mode-switcher/src/client/mode-controller.ts:73). After timeout, it throws "timed out while starting the new mode session", and the same error handling logic writes it to the tooltip; users can retry or refresh the page.
Does it conflict with official DSH mode management?
No conflict. This plugin is a pure browser-side slot injector that hangs the "mode switch" action on the conversation.session.header.actions slot (packages/dsh-mode-switcher/src/client/index.ts:20-25), and does not modify the official session data model or runtime. After uninstallation, the dropdown won't appear the next time dsh web starts.
Can this plugin only be used on DSH Web? What about Headless / CLI mode?
Yes, only DSH Web GUI (profile=web). package.json#dsh.client.platform declares web, and cordis.patch.yml inserts the plugin row into the web profile roster; the host side is an empty no-op (packages/dsh-mode-switcher/src/index.ts:5-6), all behavior is in the browser side, so this dropdown won't be injected in CLI/headless mode.
Is extra configuration needed?
No extra config needed. The plugin doesn't read ctx.config, doesn't expose cordis Schema, doesn't read environment variables; the on/off is entirely via DSH plugin market enable/disable.
How to uninstall?
dsh plugin --profile web remove @linxin666/dsh-client-ui-mode-switcher (npm package name see packages/dsh-mode-switcher/package.json:2). After uninstallation, the dropdown won't render the next time dsh web starts.
— source: plugin_wiki.faq_json
Compatibility
- DSH: 0.1.0-rc.7 ~ <0.2.0(peerDependencies 锁定 @deepseek-ai/dsh-* ^0.1.0-rc.7,packages/dsh-mode-switcher/package.json:34-40)
- Node: ^22.19.0 || >=24.0.0(包内未独立声明 engines;与根 package.json#engines 全仓一致)
— source: plugin_wiki.compatibility_json
Pitfalls
Review the upstream repo before installing. This guide is auto-derived from indexed fields and may lag the latest release. If anything contradicts the official docs, treat the upstream source as authoritative.
— source: general rule