deepseek-harness
deepseek-ai
DeepSeek Harness: Everything is a Plugin.
PROJECT TOPICS
PROJECT README
English | 中文
An Electron desktop shell for the DeepSeek Harness (dsh) Web GUI: it spawns dsh web, waits for the server's readiness line, and hosts the GUI in a standalone window with tray residency.
The shell targets the public @deepseek-ai/dsh package. It relies only on the maintained dsh web --host <host> --port <port> arguments and the dsh web: <URL> readiness line.
This repository is an independently maintained DSH desktop-shell project. It carries no harness source code; the backend is provided by a
dshinstallation on the host.
The Web GUI is the harness's richest surface but normally lives in a browser tab: no taskbar presence, no tray, and every launch means opening a terminal and keeping the tab alive. This shell makes it a real desktop window.
It is a shell only. It bundles no Node runtime and no harness closure — it runs whatever dsh web your machine already provides, so it stays correct across harness upgrades instead of pinning a snapshot.
| Window | Sandboxed renderer (sandbox: true, contextIsolation: true, nodeIntegration: false, no preload) — the GUI is a normal web application |
| Tray residency | Closing the window hides it; the server keeps running. Only Quit terminates the server |
| Single instance | A second launch focuses the existing window instead of starting a second server |
| No orphans | Quit tree-kills the server; a reaper child also tree-kills it if the main process is ever hard-killed |
| Platforms | Windows, macOS, Linux — pure Node/npm toolchain, no Rust/Go/Swift |
A working dsh web, resolved in this order:
DSH_BIN — an explicit path to a dsh executable;DSH_HOME — a harness checkout root (~/.dsh/source/current for an install.sh install). Its built apps/cli/lib/bin.js is preferred; otherwise the tsx source launch is used, exactly as the checkout's own pnpm run dsh does;dsh on PATH.On Windows, the spawn boundary automatically resolves npm command shims reached through either DSH_BIN or PATH, including .cmd files. Arguments remain a separate vector: the shell does not enable a general command shell and does not require users to locate the package's JavaScript entry point.
The server always listens on 127.0.0.1 with an OS-assigned port (--port 0), so it can never collide with an existing dsh web — a browser instance and this shell can run side by side.
npm install
DSH_HOME=~/.dsh/source/current npm run dev
npm run dist # installers under release/
npm run dist:dir # unpacked dir only, for a quick smoke
Installers are unsigned, so Windows SmartScreen and macOS Gatekeeper will warn on first run. The packaged app still needs a dsh on the host — see Requirements.
workspace-write mode cannot boot there. When DSH_PERMISSION_MODE is unset the shell falls back to danger-full-access (approval prompts disabled) and logs a warning. Set DSH_PERMISSION_MODE explicitly to override.taskkill /T /F, because child.kill() is TerminateProcess of the direct child only. On POSIX the server is spawned detached and the whole process group is signalled, SIGTERM then SIGKILL after a grace period. The server does not run a graceful-dispose path; session data is written per event to JSONL, so a killed server loses nothing already logged.http(s); unparsable targets are dropped.[dsh web] prefix; run the app from a terminal to see both streams.npm test # 31 keyless cases: command resolution/spawn, readiness parsing, HTTP polling
npm run test:electron:windows # built Electron lifecycle through a Windows npm .cmd shim
npm run typecheck
npm run dist:dir # unpacked app plus packaged production-closure verification
The shell, the launcher, and the process-tree primitive were developed in a harness fork and contributed upstream; this repository is the standalone extraction. Related standalone shells: dsh-desktop (Go/Wails, Windows), dsh-desktop-mac (Swift/WKWebView), deepseek-harness-desktop (Wails + Node SEA).
MIT, matching the harness.
CLASSIFICATION EVIDENCE
系统优先读取 GitHub Topics,再与站内分类词典和词根规则比对。当前命中: 无有效分类标签。