Introduction

The plugin system in DeepSeek Harness (DSH) allows developers to extend core behavior. dsh-llm-retry-settings is a plugin that provides a settings card, enabling users to directly adjust the automatic LLM retry policy (including retry count, backoff time, and jitter) in DSH’s “Settings -> General” interface, as well as handle automatic continuation after output truncation. It implements these controls by overriding the agent/request-error retry policy.

Core Features

The plugin provides a card in the settings interface for configuring retry and continuation behavior.

  • Settings UI Integration: The plugin injects UI via client bundle lib/client.js and displays an “LLM Auto-Retry” card in DSH’s “Settings -> General”.
  • Retry Parameter Overrides: When overrides are enabled, you can adjust maxRetries (maximum retry count), initialDelayMs (initial delay), maxDelayMs (maximum delay), and jitterRatio (jitter ratio).
  • Error Code Management: Supports selecting from a list of known error codes, or entering new error codes directly in the “Custom” group (must match the A-Z 0-9 _ - . format). These codes will be merged into the retry lists for each provider.
  • Automatic Continuation After Output Truncation: Compatible with core 0.1.7-alpha.1. When a response is truncated due to the output token limit, it can automatically trigger continuation (disabled by default).
  • Fine-Grained Overrides: Supports separate policy overrides by provider and model, with priority-based matching rules and * wildcard support.
  • Observability Panel: The bottom of the card includes a read-only panel that displays statistics for retry failures, automatic continuation records, and rounds that reached the limit in real time.
  • Core Compatibility: Compatible with the new DSH core 0.1.7-alpha.1.

Installation and Enablement

Before installing, make sure you have a DSH Desktop profile (the web profile is located at ~/.dsh/profiles/web).

Use the dsh plugin command to install:

dsh plugin --profile web add github:zeng6125-rgb/dsh-llm-retry-settings

After installation, you need to register the plugin in the profile. Add "dsh-llm-retry-settings" to the corresponding dsh.profile.bundles configuration entry, then restart DSH.

Typical Usage

  1. Open DSH’s Settings -> General.
  2. Find the LLM Auto-Retry card.
  3. Toggle the Enable Override switch to apply the policy.
  4. Set parameters such as maxRetries and initialDelayMs, and select or add specific error codes in the error code list.
  5. (Optional) Enable Automatic Continuation After Output Truncation and set the maxContinuations limit. If you want to customize the continuation prompt, enter it in Continuation Prompt; if left empty, the built-in prompt is used.

Use Cases and Notes

This plugin is suitable for scenarios requiring fine-grained control over retry policies for LLM calls, or for handling interruptions caused by output token limits.

  • Default Behavior: By default enabled: false, the plugin is in full bypass mode and does not modify any default behavior until overrides are manually enabled.
  • Command Distinction: Use dsh plugin (a subcommand of the DSH CLI), not dsh-plugin.
  • Source Code Review: Before installing the plugin, it is recommended to review the source code and license.

Conclusion

This plugin moves retry policy configuration into the settings interface, allowing developers to manage fault-tolerance mechanisms for LLM calls more intuitively. For detailed configuration items and table-of-contents information, refer to the GitHub repository.