# deepseek-harness-desktop

> Package the official DSH as a Windows desktop EXE, pre-installed with 13 functional plugins and 10 skins.

## Metadata

- Author: [@ningbainb](https://github.com/ningbainb)
- Repo: <https://github.com/ningbainb/deepseek-harness-desktop.git>
- GitHub: [ningbainb/deepseek-harness-desktop](https://github.com/ningbainb/deepseek-harness-desktop)
- Stars: 156
- Language: TypeScript
- License: [BSD-3-Clause](https://spdx.org/licenses/BSD-3-Clause.html)
- Homepage: <https://ningbainb.github.io/deepseek-harness-desktop/>
- Topics: `ai-agent`, `ai-coding-assistant`, `codex`, `deepseek`, `deepseek-harness`, `desktop-app`, `dsh`, `dsh-plugin`, `electron`, `electron-app`, `gui`, `open-source`, `plugin-system`, `plugins`, `remote-access`, `skills`, `ssh-client`, `windows`, `windows-desktop`
- Forks: 5
- Open Issues: 6
- Last push: 2026-08-20T05:29:52.000Z
- Added: 2026-08-17T00:00:00.000Z

## Install

```bash
dsh plugin --profile web add github:ningbainb/deepseek-harness-desktop
```

## Wiki

## One-Line Description

DeepSeek Harness Desktop is an Electron wrapper that packages the official DSH Web interface into a Windows desktop EXE, preloaded with 13 feature plugins and 10 skins. It is not a DSH plugin itself, but packages the same DSH experience into a double-clickable desktop application. It also serves as the distribution repository for the dsh-web-ui suite (including Task Board, Git Graph, Desktop Pet, SSH, Mobile Remote, and more).

## Core Features

- **DSH in Windows EXE**: Electron launches `@deepseek-ai/dsh` locally (profile=desktop, port=0), waits for readiness via HTTP health probe, then loads the loopback URL in a native window; DSH subprocess only listens on 127.0.0.1, and navigation policy blocks non-loopback/non-https redirects.
- **Pre-installed 13 Feature Plugins and 10 Skins**: Task Board, Git Graph, Desktop Pet, Mobile Remote, Real-time Token Stats, SSH, Skin Center, Image Description, Custom Agent (Liang Shen), Web UI Settings, Codex Connect, QQ Bot, Reasoning Slider plus Windows XP, Minecraft Block World, Blue Fantasy, Whale Song, Hatsune Miku, Trading Terminal, QQ2008 Retro, Tonghuashun Style, Descendant of the Dragon, Harbor — all loaded on a single install, with skin try-on/revert/one-click apply support.
- **QQ Bot QR Code Integration**: Scan to bind QQ private chats and group chats in the Extension Dock using the official `@tencent-connect/dsh-qqbot`; plugin remains disabled when unbound, and after binding, AppSecret is encrypted via Electron safeStorage + Windows Credential Manager, injected only through DSH subprocess environment, never written to renderer, cordis.patch.yml, or logs.
- **Auto-Update with Domestic Mirror Speed Fallback**: First GitHub Releases check 15 seconds after launch, then every 6 hours; default speed test of gh-proxy.com, ghproxy.net, ghfast.top mirrors as download sources, version metadata still from GitHub official; new version downloads in background, shows bilingual (Chinese/English) update notes, restarts only after user confirmation and installer replaces files; upgrade preserves DSH_HOME, desktop profile, community bundles, desktop pet state, skin config, and encrypted credentials.
- **Three-Layer Plugin Disaster Recovery**: Snapshot before changes, auto-isolation of faulty plugins, safe mode after consecutive failures; Shift launch / `--safe-mode` / `DSH_DESKTOP_SAFE_MODE=1` environment variable enters safe mode with one-click plugin restore and restart.

## Technical Implementation

- **Language**: TypeScript / JavaScript (Electron main process is Node ESM, renderer layer provided by upstream DSH Web)
- **Key Dependencies**: electron 43.4.0 (host runtime, devDependencies), @deepseek-ai/dsh 0.1.0-rc.6 and a set of official DSH SDK packages (dependencies), electron-updater 6.8.9 (auto-update), koffi 3.1.4 (Windows Shift key detection)
- **Architecture Pattern**: Electron main process + Cordis bundle injection; `apps/dsh-desktop/src/main.mjs` claims instance lock, loads preload, registers IPC; `apps/dsh-desktop/src/profile.mjs` writes isolated profile under `~/.dsh/profiles/desktop`, links all feature subpackages, and maintains cordis.patch.yml; build output is Windows NSIS x64 installer package (asar packed, extraResources injected icons)
- **Entry Files**: `apps/dsh-desktop/src/main.mjs` (Electron bootstrap), `apps/dsh-desktop/src/electron-app.mjs` (window, runtime, profile coordination), `apps/dsh-desktop/src/runtime-controller.mjs` (DSH subprocess lifecycle), `apps/dsh-desktop/src/profile.mjs` (profile and cordis.patch.yml management)

## Use Cases

Users who want to launch DSH on Windows like regular software without manually running `dsh` command each time, and don't want to handle Node and pnpm installation themselves. Also suitable for users who want the complete dsh-web-ui enhancement suite in one go (Task Board, Git Graph, Desktop Pet, SSH, Mobile Remote, Skin Center, QQ Bot, etc.). Users who only need the web experience or work on other platforms can directly use upstream DSH without requiring this desktop EXE.

## Prerequisites and Compatibility

| Dependency | Minimum Version | Description |
|---|---|---|
| DSH | 0.1.0-rc.6 | Desktop app implicitly locks via `@deepseek-ai/dsh` and 27 official SDK packages (apps/dsh-desktop/package.json:33-83) |
| Node.js | ^22.19.0 \|\| >=24.0.0 | Declared by root package.json#engines (package.json:33-35); end users of desktop EXE don't need to install |
| pnpm | 11.22.0 | Declared by packageManager field, used for source development (package.json:36) |
| Electron | 43.4.0 | devDependencies; precompiled binaries shipped with installer (apps/dsh-desktop/package.json:78-82) |
| Platform | Windows x64 | electron-builder.yml#win.target only declares nsis/arch=x64, no macOS/Linux build targets (electron-builder.yml:25-31) |
| Native Modules | electron / koffi / ssh2 / electron-updater | Precompiled with installer, no runtime redownload |

## Installation

```bash
dsh plugin --profile web add github:ningbainb/deepseek-harness-desktop
```

For desktop EXE, download the installer from GitHub Releases:

```text
https://github.com/ningbainb/deepseek-harness-desktop/releases/latest
```

## Configuration

This desktop app requires no extra configuration. Profile, cordis.patch.yml, skin selection, QQ Bot enabled state, etc. are all auto-managed by the desktop app (apps/dsh-desktop/src/profile.mjs:190-213, apps/dsh-desktop/src/extensions/qqbot.mjs:52-79). If installing community DSH bundles via Extension Dock, it will automatically determine compatibility based on current DSH runtime, Electron Node.js, Desktop version, and installed peer versions, providing reasons when incompatible.

## FAQ

**Q: What does this repository install into DSH?**

A: The repository root (`apps/dsh-desktop`) is a Windows desktop app, not the same as the `dsh plugin` installation mechanism; when installing via `dsh plugin` command, DSH parser identifies individual cordis bundle subpackages under `packages/` (`@linxin666/dsh-client-ui-task-board`, `@linxin666/dsh-web-ui-all`, etc.), and these subpackages are what actually take effect. For desktop EXE, download from GitHub Releases.

**Q: Do I need to install Node.js or pnpm separately?**

A: Not needed for desktop EXE; the installer includes official DSH, pnpm, and native dependencies. Source development requires Node 22.19+ and pnpm 11.22+.

**Q: SmartScreen shows "Unknown Publisher" when opening the installer, is that normal?**

A: Yes, normal. The installer is not commercially code-signed, so Windows SmartScreen will show unknown publisher. Only use installers from the project Release page and verify against SHA-256 checksums in `SHA256SUMS.txt`.

**Q: How is QQ Bot integrated? Is it secure?**

A: Scan to bind in the desktop Extension Dock (Tools > Extension Dock) QQ Bot card. Plugin stays disabled when unbound; after binding, AppSecret is encrypted via Electron safeStorage + Windows Credential Manager, injected only through environment variables to DSH subprocess, never appearing in renderer, cordis.patch.yml, or logs.

**Q: How does the desktop version upgrade?**

A: App checks GitHub Releases 15 seconds after launch, then every 6 hours; new version downloads in background, shows bilingual (Chinese/English) update notes, restarts only after user confirmation and installer replaces files. Upgrade preserves DSH_HOME, desktop profile, community bundles, desktop pet state, skin config, and encrypted QQ Bot credentials.

**Q: Anything to note about installation path?**

A: Use default path when possible; don't make custom installation root path too long, some native tools still have Win32 260 character path limit.

**Q: What happens when holding Shift during startup or adding `--safe-mode`?**

A: Startup enters safe mode: all third-party plugins disabled, only official and self-managed bundles kept; Extension Dock plugin restore page provides "One-Click Restore All Plugins and Restart". Unknown fault safe mode mistakenly written due to 120-second timeout misjudgment before 2.1 will also be recognized and reverted on first startup.

**Q: Does desktop version listen on external network?**

A: DSH subprocess only listens on 127.0.0.1 random port, browser renderer loads that loopback address via Electron window; navigation policy blocks redirects to non-loopback, non-https targets.

## Difficulty Level

Beginner — just download EXE and double-click to install; one main path via Extension Dock scan to bind QQ Bot. Source development requires familiarity with pnpm workspaces, Electron, and Cordis bundle mechanism, but end users don't need this.

## Known Issues and Limitations

- Currently only releases Windows x64 NSIS installer, no macOS / Linux build targets (electron-builder.yml:25-31).
- Installer not commercially code-signed, Windows SmartScreen shows unknown publisher; only trust installers from project Release page (README.md:206).
- Custom installation root path shouldn't be too long; some native toolchains still have Win32 260 character path limit (README.md:206).
- If old process still runs during upgrade and files are locked, installer may falsely report file占用; starting from 2.1, automatically terminates old app and background processes under `resources` via parent-child process relationship (CHANGELOG.md:9-27).
- Pre-launch runtime integrity check; missing critical files directly reports error (`DSH_DESKTOP_INSTALLATION_INCOMPLETE`) instead of entering crash-reboot loop; reinstall or check security software quarantine (apps/dsh-desktop/src/runtime-integrity.mjs:8-47).
- On Windows, DSH subprocess runs in hidden PowerShell; depends on PowerShell availability; startup will fail on极少数精简 Windows images lacking PowerShell (apps/dsh-desktop/src/runtime-controller.mjs:40-62).
- Mobile remote defaults to LAN; public access requires enabling cloudflared tunnel, introduces additional network dependency (README.md:128).
- Installing via `dsh plugin add github:ningbainb/deepseek-harness-desktop` is a different path from desktop EXE: the former only activates cordis bundle subpackages under `packages/`, won't create Electron desktop window; the latter is the complete desktop application.

---

This document is auto-generated by [deepseek-plugin.org](https://deepseek-plugin.org). HTML page: [deepseek-harness-desktop](https://deepseek-plugin.org/plugins/ningbainb/deepseek-harness-desktop)
Wiki generated by AI (model: `MiniMax-M2.5`)
