dsh-session-progress: DeepSeek Harness Session Progress Sidebar

Preface

In long-turn, long-session conversations, the dialogue scrolls by, the input box shows a token count at the bottom, and the right sidebar is collapsed by default. When you need to know “how far along this session is,” you can only rely on the conversation context and your own memory. This plugin puts the session’s progress into the right sidebar, automatically opens when the current session starts a new turn or enters a waiting state, and provides a numbered list of the entire session along with a purpose description for each shell command.

What It Is

dsh-session-progress is a DeepSeek Harness client plugin. It renders the entire session as a numbered list: each user prompt (1, 2, 3……) and each agent step beneath it (1.1, 1.2, 2.1……). Every step displays the purpose it serves for that request, its local start time, and its status. Shell commands themselves are not shown directly; instead, a short purpose phrase (e.g., “Run tests”) is generated via a small model call. The panel is mounted as a tab type in the right sidebar, alongside other tabs such as Workspace files and the terminal.

What the Panel Displays

The top of the panel is a fixed header containing a current-status capsule (Running, Waiting for you, Turn complete, Turn failed, Idle), the current turn number and elapsed time, a two-line truncated display of the current prompt, and the step track for the current turn. The step track uses colors and animations to indicate completed (green), errored (red), and in-progress (sweeping highlight), conveying the shape of the work rather than a percentage.

Below is the full session list, covering everything from the first prompt onward. Each user prompt is a numbered block with a “You” label and a background tint, visually distinguished from agent steps. Each step is numbered under its parent prompt, e.g., 1.1, 1.2, 2.1……, with a small timestamp showing the local start time below the number. Completed steps show a checkmark, in-progress steps show a spinner and follow streaming text, and errored steps show a cross.

A step must state a purpose or it will not be displayed. The title prefers the agent’s own words; if none exist, it shows the file the agent wrote or modified (e.g., “Wrote notes.md”); if that’s also absent, it falls back to the shell command’s purpose (generated by a small model call). Steps that are only a tool call and have none of the three (e.g., just a read or skill) are dropped; file-writing activity is never dropped; and steps that both wrote a file and produced text list the file in the sub-line. Earlier rows are never silently discarded—when an ultra-long session hits the render limit, a “N more earlier items” notice appears above the list. The list follows the latest row: it scrolls to the bottom when opened and continues to follow as new steps and streaming text appear; if the user scrolls up, it holds position, and resuming follow when the user scrolls back to the bottom.

Where Shell Command Purposes Come From

Shell commands themselves are hard to read, e.g., docker run --rm -v … image pnpm test --filter core. The panel asks the host for intent and generates a short phrase via a single small model call. The route is POST /api/dsh-session-progress/purposes on the web server, restricted to loopback addresses, requested once per panel update—never per row.

Each distinct command triggers the model at most once per lifetime. describeProvider/describeModel, when set, use that route; otherwise the first provider route the host publishes and its first model are used. A single call allows at most 64 output tokens, a 6-second timeout, temperature 0, and at most 3 concurrent calls. Per page load, each command is asked about only once, and a single request pays for at most the four most recent unseen commands. Opening the panel on a 300-step session costs 4 calls, not 300.

Descriptions are held in memory during mount and persisted across restarts to $DSH_HOME/cache/dsh-session-progress/command-purposes.json. The file stores only the SHA-256 of each command and never stores the command text. Failed commands are not retried for two minutes, preventing a provider outage from becoming a retry storm.

When there is no route, a provider error, a timeout, or the response echoes back the command, the panel falls back to a locally selected phrase based on the command’s shape (e.g., “Run tests,” “Install dependencies”), and ultimately to “Execute command.” The panel is never blank and never prints the command. Phrases are requested in the current UI language; switching languages triggers a re-request on the next update.

How It Opens

The panel is a tab type, not a page exclusive to this plugin. It opens automatically in the following cases: when a new turn begins (the watcher is session-scoped, sees only the current session, and opens when the right sidebar is collapsed, empty, or showing the onboarding page; it does not intrude when another tab is displayed, and focus is returned to the input box); when a pending approval or question appears (autoOpenOnWaiting); and manually via the “Session Progress” card on the onboarding page or the “+” button in the tab bar. It can be collapsed when idle (autoCollapseOnIdle, default off), and only takes effect when the panel is still showing this tab.

Configuration

The plugin displays row configuration on the “Plugins” page, injected at page load.

Field Default Meaning
autoOpen focus focus = only open when the right sidebar is collapsed, empty, or showing the onboarding page; always = may also preempt from other tabs; off = open manually only
autoOpenOnWaiting true Open when the session is waiting for approval or a question
autoCollapseOnIdle false Collapse the panel again after the turn that opened it (via this plugin) ends
showToolDetails true Show details of in-progress calls in the activity card (shell calls show purpose, other tools show a parameter hint)
describeCommands true Use a small model call to describe shell command purposes; when false, all descriptions are resolved locally
describeProvider "" Provider route for that call; leave empty to auto-discover the first route the host publishes
describeModel "" Model ID for that call; set together with describeProvider

Environment Requirements

  • DeepSeek Harness 0.2.2-rc.3
  • Node.js ≥ 24.9 and pnpm 11 (for building from source; corepack enable reads the pinned version in packageManager)
  • A web profile: the panel requires the Harness web server; the purpose route also requires the host’s LLM service; when no model route is registered, the panel will always use local phrases

Installation

pnpm check
pnpm run pack                 # dist/dsh-session-progress-0.3.5.tgz

Install the tarball into your profile (Settings → Plugins, or the plugin manager). The manager returns application: applied, after which the client runner loads the bundle into the current page. If the tab still doesn’t appear after refreshing, restart Harness.

Iteration without modifying the online configuration:

scripts/dev-profile.sh boot 19499   # private .dev-home, link: install, dedicated port
scripts/dev-profile.sh remove       # remove when done

What It Reads, and What It Absolutely Does Not Do

  • Host side: declares the Config schema, injects the parsed settings as a single global row into webserver/index-inject, and provides the loopback-only “purposes” route. This route emits the plugin’s only auxiliary model call, with its own timeout, caching, and byte cap. No tools, no session writes, no conversation copying.
  • Browser side: registers the tab type into ctx.sidebarRightTabs, registers the panel body into sidebar.right.pane.tab, and registers the watcher into conversation.composer.dock. The panel body retains the session (ctx.sessions.retain), requests earlier pages of history from the host until the first event, then folds the event log into prompts and steps. The activity card reads the tail of the same log: a tool/call with no result is an in-progress call, and assistant/live-chunk is streaming text.

The watcher only uses useChat to detect whether a new turn has started; waiting state comes from the state projection. It does not write to the session, send prompts, or answer any questions. The only model call is for command purpose description, and that command already exists in the session log.

Use Cases and Caveats

Suitable for DSH users who need to monitor overall session progress, especially in long-turn, multi-step agent development scenarios. The plugin runs with the current dsh process permissions; review the source code and license before installing.

Closing Note

This plugin makes long-session progress visible at a glance, reducing reliance on context. Further details are available on the catalog page and the GitHub repository.

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

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

Xiaoye