dsh-recent-tasks: Recent Tasks Panel in the DSH Sidebar

Introduction

The DeepSeek Harness (DSH) sidebar only lists session titles by default, so you can’t tell at a glance whether a session is running, has finished but hasn’t been viewed, or has already been processed. This status information is critical for multi-turn conversations and long-running projects. dsh-recent-tasks adds a persistent “Recent Tasks” panel to the sidebar, grouping sessions into four status sections, and attaches three small pills to the sidebar entry so you can tell at a glance whether anything needs your attention.

The plugin is developed by maintainer lnqxyz. It is a client-side plugin with 0 stars at the time of writing. It does one thing: presents DSH session status and progress intuitively in the sidebar and panel, and supports creating new sessions directly in a remembered folder.

Core Features

Four Status Sections

The panel is divided into four sections from top to bottom, each with a fixed visual style and entry condition:

  • Running: Light blue cards with an animated light dot orbiting the border, a breathing blue dot in the top-left corner, and a light band sweeping across the card surface. Sessions waiting for your confirmation are sorted to the front, with a flashing red title showing prompts like “Awaiting your confirmation / Awaiting your decision / Awaiting your answer.” The section header displays “N awaiting your action” on the right side.
  • Favorites: Amber cards with a 30px solid amber star at the right center. Clicking the star moves the session into the favorites section; unfavoriting sends it back to its original section immediately. The favorites section is hidden entirely when empty. Four statuses are mixed within this section — each card shows its own status: running (blue badge), unread (green badge), completed (gray badge), or awaiting confirmation (red badge).
  • Unread: Green cards. When a turn completes and you didn’t watch it, the session lands here. Opening it clears the unread mark; re-running removes it from unread; starring does not count as “viewed.”
  • Completed: Gray cards with two buttons at the right center: Archive (box icon) and Favorite (star icon). Expanded to 15 items by default; resets to 15 each time the panel is entered. Clicking a card or the section header toggles the entire section open/closed.

Cards are larger overall: title 16px, description 12.5px, minimum height 100px. A row holds up to three columns, automatically dropping to two or one column as the window narrows. Each card has a star at the right center with a 56×56px hit area; unfavored stars appear as 34% opacity gray outlines and only become clearly visible on hover.

Three Pills on the Sidebar Entry

Three small pills follow the “Recent Tasks” icon in the sidebar, each color-coded to a status:

  • Red: Awaiting your action (confirm / decide / answer). Hidden when the count is 0.
  • Light blue: Currently running. Hidden when the count is 0.
  • Green: Completed but not yet opened. Hidden when the count is 0.

The three pills are arranged left to right in the order: red, light blue, green. Favorited sessions and unread favorites still count toward their respective pills; the unread section does not include favorites. When the sidebar collapses to an icon-only strip, the pills are not rendered. Pill counts are tracked from plugin load time and are not persisted to local storage.

Collapse and Expand

The Favorites and Running sections can be collapsed; the Unread section is always expanded. When first entering the panel, Favorites and Running are collapsed while Completed is expanded.

  • Clicking anywhere on the section header toggles the state, not just the small triangle on the right.
  • When collapsed, only the header row remains; cards and the “Expand remaining N conversations” link are hidden together.
  • Counts are still shown when collapsed: the header still displays “Running N,” “Favorites N,” “Completed N.”
  • The Unread section is always expanded and has no collapse triangle.
  • Collapse/expand state is not persisted to local storage; it is recalculated according to the rules each time the panel is entered.

One exception: if any session in a section is awaiting your action (card shows a red badge reading “Awaiting your confirmation / Awaiting your decision / Awaiting your answer”), that section automatically expands. This exception only triggers when the panel is first opened, when re-entering via the sidebar entry, or on a page refresh. If a session transitions to awaiting-action while the panel is already open, only the red “N awaiting your action” text appears on the header — the section does not auto-expand.

Keep Only N Days (Archive Older Sessions)

A [“Keep Only N Days”] button appears at the top-right of the panel header. Clicking it opens a confirmation dialog showing the number of sessions to be archived; archiving proceeds only after confirmation.

  • Archiving does not delete. It calls the host’s uiWorkspace.archiveSession and can be restored from the Archive Manager.
  • Favorited sessions are not archived; favorites older than N days remain in the Favorites section.
  • Running sessions are not archived; they are only counted.
  • Sessions within the last N days are never archived.
  • If there are no archivable sessions, a toast notification is shown instead of a dialog.

After archiving completes, an undo bar appears at the top of the page showing “Archived N sessions” with a countdown. Clicking [Undo] within 30 seconds restores that batch. The undo bar covers only the most recent batch; clicking [“Keep Only N Days”] again replaces the previous undo bar. The undo bar disappears when the page is closed or refreshed.

Single Archive and Undo

Each card in the Completed section has two buttons at the right center: Archive (box) and Favorite (star). Clicking Archive does not show a confirmation dialog and uses the same uiWorkspace.archiveSession interface. After archiving, the card disappears from the list, a message “1 session archived.” appears at the top, and the same 30-second undo bar is shown. The undo bar always refers only to the most recent single archive action. All box buttons are disabled while an archive operation is in progress.

Configuring Retention Days

The retention period (Keep Only N Days) is no longer hardcoded on the button. It is now a plugin setting:

  • Location: Settings → Plugins → Recent Tasks → Configuration (the plugins.row.config cell). Card title: “Keep days,” with a numeric input (1–365, integer) and a [Save] button.
  • Stored as the Host-side config field keepDays, declared as a volatile field in index.js. Changes go through the host’s hot-reload channel without restarting the plugin or rebuilding the page.
  • There is no in-page entry to change this value; all UI text follows the setting.
  • If the setting cannot be read (older interface without configForms service or the row not registered), the page falls back to the default of 7 days and continues to work.

Click [+] to Create a New Session

Clicking the [+] button in the top-right of the panel behaves based on whether a folder has been previously selected:

  1. First click: A picker dialog appears, listing existing workspaces, with an additional “Select another folder…” option that invokes the system folder picker (host uiWorkspace.pickDirectory).
  2. The selected folder is remembered. If it’s an existing workspace, a new session is created and opened directly in that group. If it’s not a workspace, it is first registered as one via workspaces.create, then a session is created via connectWorkspace and opened. The session is placed in that group and won’t end up in “Ungrouped.”
  3. Subsequent clicks on [+] skip the dialog and use the remembered folder directly.
  4. If the remembered folder is deleted or renamed, it becomes unavailable and the next click on [+] reverts to step 1 for a fresh selection.

There is currently no dedicated “Change folder” button. To proactively switch, you must wait for the remembered folder to become invalid and reselect, or clear the local key dsh.recent-tasks.folder.v1.

Data Sources

  • Session list: Host sessions.list — only sessions active in the last 10 days, sorted by last message timestamp (newest first). subagent-derived sessions are excluded; archived sessions are excluded.
  • Status determination: Running / Awaiting confirmation / Unread come from the host’s uiSession.sessionStatus (running, pendingInteraction, completionUnread). The three pending-confirmation prompt texts are read directly from pendingInteraction.kind.
  • “Viewed” is determined by visibility: a session counts as viewed only when it actually occupies the main area. Opening it and then returning to Recent Tasks (or the panel covering the conversation) does not count as viewed.
  • Favorites / Unread / Remembered folder: Stored only in the browser’s local storage. Not uploaded, not synced across devices.
  • Favorites older than 10 days remain in the Favorites section but are excluded from the panel’s Unread and Completed windows; unfavoriting them in this state causes the session to disappear entirely.

Local Storage

The plugin stores three keys in the browser’s localStorage:

  • dsh.recent-tasks.folder.v1: The absolute path of the folder remembered when clicking [+].
  • dsh.recent-tasks.favorites.v1: List of favorited session IDs.
  • dsh.recent-tasks.unread.v1: List of unread session IDs.

The retention days value is not in these keys; it lives in the Host-side plugin config (keepDays). Clearing these keys resets to the initial state: no favorites, no unread, and the next [+] click will prompt for folder selection again.

Installation and Activation

Install from the GitHub repository:

  1. Open https://github.com/lnqxyz/dsh-recent-tasks
  2. Click “Code” → “Download ZIP” or clone via Git
  3. Place the extracted files into the DSH plugin directory
  4. Enable the plugin in the DSH interface

(The directory page does not provide a dsh plugin add command, so none is listed here.)

Typical Usage

  • Open DSH; three small pills appear after the “Recent Tasks” icon in the sidebar, reflecting the current number of sessions needing attention.
  • Click “Recent Tasks” to enter the panel and see the four status sections. Running, unread, favorited, and completed sessions are arranged by status.
  • Click the star in the Favorites section to bookmark a session; the Favorites section is hidden when empty.
  • Click the box button in the Completed section to archive a single session; an undo bar appears at the top, valid for 30 seconds.
  • Click [+] in the top-right of the panel, select a workspace or folder, and subsequent new sessions will be automatically placed in that group.
  • Change “Keep days” in Settings; the panel will archive older sessions and show an undo bar at the top.

Use Cases and Notes

  • Suited for users who frequently handle multi-turn conversations and long-running projects and want a quick overview of which sessions are running, which are awaiting confirmation, and which are done but unviewed.
  • The plugin runs with the current DSH process’s permissions. It is recommended to review the source code and license before installing.
  • Archive operations actually modify the host’s archive state; they are not purely local cleanup. The undo window is 30 seconds.

In Short

dsh-recent-tasks presents DSH session status intuitively through four status sections and three pills in the sidebar and panel, supports creating new sessions directly in a remembered folder, and provides archive and undo capabilities. For more details:

  • Plugin directory page: https://www.skillhub.cn/plugins/lnqxyz/dsh-recent-tasks
  • GitHub repository: https://github.com/lnqxyz/dsh-recent-tasks
羽毛球分组比赛记分
小程序二维码

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

Xiaoye