dsh-job-progress: View Background Job Progress in DSH Sessions

Preface

When running downloads, model conversions, or batch rendering in DeepSeek Harness (DSH), tasks are often executed in the background. While output is visible in the terminal, it is difficult to gauge “how much time is left” or “how much has been completed” at a glance after returning to the Web chat interface. The common practice of switching back to the terminal repeatedly or having the Agent poll logs interrupts the conversation and makes monitoring multiple tasks simultaneously inconvenient.

Here we introduce the client plugin dsh-job-progress (maintainer: Rice00). In sessions with observable background tasks, a draggable floating ball appears. Upon expansion, the panel displays the progress, speed, and ETA for each task. Task data is sourced from the DSH job registry and progress protocol files within the session, requiring no additional configuration credentials or external network calls.

What is this

dsh-job-progress is a client plugin for DSH Web, positioned as a “real-time progress bar for long-running background jobs.” It reads the job registry on the host side and progress JSON files from the session directory, pulling snapshots approximately every 2 seconds to render the floating ball and task panel in the browser. The license is MIT, and it requires Node 22+ at runtime (consistent with the engines in package.json).

Core Features

The capabilities explicitly listed in the documentation are as follows:

  1. Floating Ball: Appears only in sessions with visible tasks; the badge displays the number of running tasks, showing 9+ if more than 9.
  2. Draggable: The position can be adjusted and persists after a page refresh (stored in localStorage).
  3. Real-time Panel: One row per job, including a status dot, label, progress bar, percentage, done/total, speed, ETA, and elapsed time.
  4. Clear Completed: Allows deletion of progress files for finished tasks within the current session; running entries are not deleted.
  5. Decoupled from Producers: Jobs that do not report progress still appear in the list (sourced from the registry), simply without a progress bar.
  6. Session Isolation: Only displays jobs under the current DSH_SESSION_ID; tasks from other sessions are not visible.
  7. Zero Configuration: Does not read tokens or make additional network requests; it only reads the job registry and the session progress directory.
  8. Agent-Discoverable Protocol: The host side registers the progress protocol as a session-visible skill, allowing the Agent to report speed and ETA when starting long downloads or coding tasks.

Installation and Activation

The installation command follows the repository README. Choose either the npm or GitHub source, replacing <profile> with the profile you actually use (commonly web for the Web interface):

dsh plugin --profile <profile> add dsh-job-progress
dsh plugin --profile <profile> add github:Rice00/dsh-job-progress

The bundle patch inserts a line job-progress into the profile. Restart the profile after installation: Host plugin modules are cached within the process, and a running Harness will not hot-reload the new line; however, if only UI code is changed, a browser refresh is sufficient.

For verification, refer to the README: the preflight script should output ALL PASS (12); mounting information such as job-progress: mounted, progress root … should appear in the host logs. On Windows, the host log path is %APPDATA%\DSH Desktop\logs\host\.

Typical Usage

Works without configuration

No configuration file needs to be written first. Run any background command using run_in_background in the session, and the floating ball will appear when there are observable jobs. Example from the README:

node download.mjs https://example.com/model.safetensors    # run_in_background

Report progress to display progress bars

Use the track API exported by the plugin in your script (speed and ETA are estimated by the library based on update intervals):

import { track } from 'dsh-job-progress/progress';

const t = track({ label: 'model.safetensors', total: 66000000 });
t.update(bytesSoFar);
t.phase('verifying');
t.finish('done');            // or t.finish('failed', 'sha256 mismatch')

On the Shell side, you can avoid importing and directly call the CLI provided by the plugin (replace <plugin> in the path with the local plugin directory):

node <plugin>/lib/dsh-progress.mjs set --label model.safetensors --done 12 --total 100
node <plugin>/lib/dsh-progress.mjs done --key model.safetensors

Progress File Protocol (Brief)

Producers write one JSON file per task to the directory:

<DSH_HOME>/job-progress/<DSH_SESSION_ID>/<key>.json

DSH_HOME and DSH_SESSION_ID are already available in the Agent shell, so manual entry of absolute paths is generally unnecessary. Fields include label, done/total, unit (bytes or count), optional speed/eta, phase, status (running | done | failed), etc. updatedAt must be refreshed periodically while running (at least once every 15 seconds), otherwise it will be considered disappeared; writes should be done by writing to .tmp first and then renaming to avoid reading partial files.

The data flow can be summarized as: Producer writes JSON → Host plugin reads directory and registry → Client polls jobProgress/snapshot and renders the interface.

Use Cases and Notes

Target Audience: Developers who frequently run background downloads, conversions, ComfyUI rendering, or batch shells in DSH Web and wish to centrally view progress and ETA within the current session.

Permissions and Security: The plugin runs with the current DSH process and user privileges, possessing the same read/write scope as the Harness. Before installation, it is recommended to review the source code and MIT license on the GitHub repository to ensure compliance with your environment policies.

Ecosystem Note: The DSH community plugin directory (such as entry pages on SkillHub) is an independent site and has no official affiliation with DeepSeek / High-Flyer; the installation and usage instructions in this article follow the repository README.

Conclusion

dsh-job-progress consolidates “where the background task stands” into a floating ball and panel within the session. Combined with the progress protocol or CLI, long tasks no longer rely on guessing or frequent terminal checks. Directory page: SkillHub - dsh-job-progress; Source code and full protocol documentation: GitHub - Rice00/dsh-job-progress.

羽毛球分组比赛记分
小程序二维码

欢迎使用《羽毛球分组比赛记分》微信小程序

Xiaoye