Preface¶
When building local agents in DeepSeek Harness (DSH), models often need to know the current machine load, disk, and process status, and occasionally need to help users clean up safely deletable caches and temporary files. If relying on hand-written shell commands or temporary scripts every time, it is difficult to reuse them, and there is often a lack of a unified safety boundary between “scanning” and “actual deletion.” The dsh-pc-manager introduced below (repository maoqizhen/dsh-pc-manager) integrates into the DSH web profile as an official bundle plugin: it provides read-only system snapshots, a sidebar dashboard, junk scanning, and cleanup capabilities that execute only after explicit configuration and validation pass. The maintainer is maoqizhen, and the SkillHub category is Client.
What is this¶
dsh-pc-manager (PC Manager) is a plugin for DeepSeek Harness. The current version is 0.0.1, licensed under MIT, requiring Node >= 22.19 and dsh >= 0.2.0-rc.1 (marked as compatible with 0.2.0-rc.1 / rc.2 in the README and package.json).
Its positioning can be summarized in three points:
- System Status Monitoring: The model tool
pc_statusplus the “System Monitor” dashboard in the web right sidebar. - Junk Cleaning:
pc_junk_scan(always dry-run) andpc_junk_clean(requires configuration to enable), along with a zero-LLM direct execution cleanup window. - Application Uninstalling (Planned):
pc_apps_listandpc_app_uninstallare marked as Stubs in the README, part of milestone M3.
Monitoring and junk cleaning are available on macOS, Linux, and Windows; on other platforms, related tools will return unsupported_platform. On Windows, metrics are derived from Node’s built-in capabilities plus batch PowerShell probing; junk targets use JUNK_TARGETS_WIN32, and deletion paths can go to the system Recycle Bin.
Core Functions¶
Model-Visible Tools (5 total)¶
| Tool | Function | Status |
|---|---|---|
pc_status |
Read-only snapshot: CPU/GPU, load, temperature (capability-gated), memory & swap, disk I/O & partitions, battery/power, network counters, sortable process table, etc. | Released |
pc_junk_scan |
Enumerate reclaimable junk (per-platform Trash/cache/temp dirs, package manager caches, etc.) with size and safety markers; parameters kinds, minItemBytes; always dry-run. |
Released |
pc_junk_clean |
Clean by ID returned by scan; if any part of the validation chain fails, the entire request is rejected with zero deletions; requires config opt-in by default. | Released |
pc_apps_list |
List of installed applications. | Stub (M3) |
pc_app_uninstall |
Uninstall by ID, moves to Trash by default. | Stub (M3) |
Right Sidebar Dashboard¶
Open the narrow bar card in the web profile’s right sidebar “System Monitor” (order 30): Host/OS, uptime, CPU/GPU, Memory, Disk, Battery (hidden if absent), Network, Process Table (default Top 10), etc. Some rows/columns are shown or hidden based on platform capabilities (e.g., Windows does not fabricate a 0 for load average when unavailable; GPU/temperature are capability-gated). The interface is hand-written SVG with no third-party chart libraries.
Security Design (Emphasized in README)¶
The plugin describes itself as a security-first system tool:
- Scanning is always a dry-run.
- The two destructive tools (
pc_junk_clean,pc_app_uninstall) aredisabled_by_configby default; they may only execute after the host explicitly enables them in the configuration. Per-call host approval gating still applies (README still notes per-call approval whenenableJunkClean: true). - Default
moveToTrash: true, attempting to put deletions into a recoverable Trash/Recycle Bin. - ID validation chain (format, root directory containment, realpath, blocked, safeToClean, etc.): if any check fails, the entire call is rejected with zero deletions; deletion is refused if the size cannot be verified.
Installation and Enablement¶
One-line Install (Official Bundle Method)¶
The repository is an official bundle plugin (the root package.json contains dsh.bundle and dsh.client). lib/ has committed build artifacts, so git installation requires no local build.
dsh plugin --profile web add "github:maoqizhen/dsh-pc-manager#main"
After installation, you must restart dsh web (the bundle layer is synthesized at startup). Updates and uninstalls also require a restart to take effect:
dsh plugin --profile web update dsh-pc-manager
dsh plugin --profile web remove dsh-pc-manager
pnpm Required: dsh plugin forwards to pnpm; it will fail directly if pnpm is not in the PATH. You can install it via npm i -g pnpm, and the pnpm major version must match the profile’s existing store. On servers running in non-login shells, ensure node/pnpm are visible to that process.
Optional: Enabling Junk Cleanup¶
The default installation is safe-by-default: read-only tools are immediately available; pc_junk_clean / pc_app_uninstall refuse to execute due to configuration. To allow cleaning at the config layer, you need to write a back-layer patch (profile’s cordis.patch.yml or ~/.dsh/cordis.patch.yml; note that the back layer replaces the entire line of config, so all keys must be rewritten):
- insert:
- id: pc-manager
name: dsh-pc-manager
config:
enableJunkClean: true # Per-call host approval gating still applies
moveToTrash: true # Default to Trash (recoverable)
Manual Mounting (Mutually Exclusive with Bundle Install)¶
When not running dsh plugin add, a dual entry is required: a package name entry for the client half to be discovered by clientModules; an absolute path entry for the host half to apply. Steps are detailed in the README “Manual mounting”: symlink to the profile’s node_modules/dsh-pc-manager, edit cordis.patch.yml, and restart dsh web.
Typical Usage¶
- Read-only Monitoring: Ask the model to call
pc_statusin the conversation, or open the right sidebar System Monitor for continuous viewing. - Safe Junk Assessment: Call
pc_junk_scanfirst (you can passkinds,minItemBytes). Decide whether to clean based on the returned item size andsafeToCleanfields; scan does not modify the disk. - Cleaning (Requires Config + Validation): After setting
enableJunkClean: truein the patch, callpc_junk_cleanonly for IDs returned by scan; you can also use the zero-LLM direct execution cleanup window described in the README (bypassing the model inference chain). - Updating the Plugin: Run
dsh plugin --profile web update dsh-pc-managerand restartdsh web.
For specific per-platform junk target registries, Windows data sources, and deployments behind reverse proxies, please refer to the appendix of the repository README.
Scenarios and Caveats¶
Suitable for: Developers or advanced users who want the model and UI to share the same set of system monitoring and controlled cleanup capabilities in a local/self-hosted DSH web environment. The main paths for monitoring and cleaning are covered on all three desktop platforms.
Important Notes:
- The plugin runs with the user and permissions of the current
dshprocess. Accessible paths and deletable files are subject to these limits; please read the GitHub Source and the MIT license before installation, and assess the risks yourself. - Destructive capabilities are disabled by default; even if configuration is enabled, rely on the scan → clean ID chain and Trash default policy. Do not skip the scan to specify paths directly (the tool design does not support this).
pc_apps_list/pc_app_uninstallare not fully delivered before M3 and should not be relied upon as a production uninstall solution.- The DSH ecosystem is “everything is a plugin”; the SkillHub Directory Page is a community site and has no official affiliation with DeepSeek / High-Flyer.
Conclusion¶
dsh-pc-manager consolidates system monitoring (tools + sidebar), read-only junk scanning, and configurable controlled cleaning into a single bundle plugin, emphasizing dry-runs, configuration gating, and zero-deletion on validation failure. If you need to “check the machine, scan junk, and finally clean under gating” within DSH, you can install it via the commands above and write enableJunkClean as needed.
- Directory Page: https://www.skillhub.cn/plugins/maoqizhen/dsh-pc-manager
- GitHub: https://github.com/maoqizhen/dsh-pc-manager