dsh-audio-cue: DSH Host Plugin - Approval and Conversation-End Audio Cues

In DSH (DeepSeek Harness) agent development, there is typically a lack of auditory feedback for critical states such as “approval requests” and “conversation end.” This plugin monitors host events and plays sound cues at these moments to reduce the time cost of manual checks.

Plugin Positioning

This is a DSH host plugin designed to play sound cues when approval inquiries occur or when a conversation turn ends. Maintained by anne43983959 and licensed under MIT. It is a pure-host semi-module with zero external dependencies; it registers no tools, registers no services, and modifies no existing files.

Core Functions

The plugin achieves state awareness by listening to the following events and playing preset sound effects:

  1. Approval Inquiry: Listens for the approval/request event. Note that this event belongs to the cordis waterfall type; the listener must call next() to proceed, otherwise it will veto the entire approval chain.
  2. Conversation End (Main Path): Listens for events where event.type === "turn/end" within session/event. This path utilizes a scope carrier to filter out sub-agents, preventing sound triggers from sub-agent sessions.
  3. Conversation End (Fallback): Listens for the agent/turn-stopping event. This path does not rely on scope and acts as a fallback mechanism, playing the sound after a 2-second delay to ensure feedback even if the main path is not triggered.
  4. Question Cue: Listens for the ask_user_question event within tools/execute and plays a notification sound.

Installation

Execute the following command in your host environment:

dsh plugin --profile web add github:anne43983959/dsh-audio-cue

After installation, you must restart the host instance for the module and assets to take effect.

Configuration

Configuration items should be written into the profile’s cordis.patch.yml (either via the plugin’s built-in config or profile overrides):

Key Default Value Description
enabled true Master switch
approval true Switch for approval inquiry sound
ask true Switch for question sound
turnEnd true Switch for turn end sound
ignoreSubagents true Ignore turn end sounds from sub-agents
fallbackTurnStopping true Switch for fallback mechanism
fallbackDelayMs 2000 Fallback delay (milliseconds)
selfTest false Switch for self-test sound
selfTestMs 2500 Self-test sound delay (milliseconds)

Asset Requirements

The plugin requires the following asset files to be present in the host directory:

  • assets/approval.wav: Approval notification sound
  • assets/turn-end.wav: Conversation end notification sound

Both assets must be in 44.1 kHz / 16-bit / Stereo WAV format.

Compatibility & Notes

  • Compatibility: Requires dsh.compatibility.runtime >=0.1.1-rc.1 <0.3.0.
  • Permissions: The plugin only reads host events and requires no additional permissions.
  • Self-Test: During development, you can run node scripts/smoke.mjs for a local self-test.

Ecosystem Background

DSH adopts an “everything is a plugin” architecture. This plugin is hosted in the community directory and has no official affiliation with DeepSeek or High-Flyer (幻方).

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

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

Xiaoye