Foreword¶
DSH plugins are used to extend the capabilities of the current environment. In DSH scenarios, multiple sessions may exist simultaneously; when a session gets stuck in the running state, or when one needs to view the records of another session and continue sending messages, a set of diagnostic and operational tools centered around sessions is required.
Below introduces dsh-session-doctor, which is used to diagnose, unblock, and read DeepSeek Harness sessions.
What is it¶
dsh-session-doctor is a DSH plugin released by maintainer mayf3, positioned as a “Session Doctor”.
It bundles five capabilities into one set of tools: listing sessions, reading session records, diagnosing session status, recovering stuck sessions, and sending messages to target sessions.
The current version is 1.0.0, with an MIT license.
Core Features¶
The following are the five tools provided by the plugin:
list_sessions
List all sessions, including id, title, working directory, persistence status, agent running status, and queued message count.
read_session
Read user/assistant text messages for a specified session, returned sequentially, with limit support.
session_status
Diagnose the target session's online status, running/idle state, inbox queue count, and last event.
session_recover
Send a cancellation signal (keepInbox: true) to a deadlocked running agent, abort the stuck activity, and retain queued messages.
send_session_message
Send a message to a target session, delivering it directly if online, or delivering it after automatic recovery if offline.
Installation and Activation¶
The following command is used to add dsh-session-doctor:
dsh plugin --profile web add dsh-session-doctor
After installation, the above functions can be called by tool name.
Typical Usage¶
The following examples are listed according to the plugin description:
-
List all sessions. Corresponds tolist_sessions, returns each session’sid, title, working directory, persistence status, agent running status, and queued message count. -
Check the status of session <id>. Corresponds tosession_status, checks if online,running/idle,inboxqueue count, and last event. -
Unblock session <id>. Corresponds tosession_recover, sends a cancellation signal to a live agent inrunningstate, preserving queued messages. -
See what session <id> has been doing recently. Corresponds toread_session, reads user/assistant text messages sequentially. -
Send a message to session <id>: .... Corresponds tosend_session_message, delivers directly if online, or delivers after automatic recovery if offline.
Applicable Scenarios and Notes¶
Suitable for users who need to view DSH session records, diagnose stuck running sessions, and continue sending messages to target sessions.
Precautions before use:
- The plugin runs in the DSH plugin environment, invoking session capabilities visible to the current dsh process with the permissions of the current dsh process; source code, license, and dependency versions should be checked before installation.
session_recoveronly acts on live agents (runningstate).- Offline recovery for
send_session_messagestarts the target session using the default model. - Inter-process and inter-machine communication are not within the scope of this plugin.
Version and Dependency Information:
version: 1.0.0
license: MIT
peerDependencies: @deepseek-ai/cordis ^4.0.1; @deepseek-ai/dsh-tools >=0.1.0-rc.5 <0.2.0
engines: node >=22.19; dsh >=0.1.0-rc.5 <0.2.0
Related Links¶
The value of dsh-session-doctor lies in grouping session diagnosis, recovery, and message delivery into one set of tools.
Directory page (from plugin information, not representing the official app store): https://www.skillhub.cn/plugins/mayf3/dsh-session-doctor