zeng6125-rgb/dsh-llm-retry-settings
DSH 插件:LLM 自动重试设置卡片——调整重试次数与退避时间实时生效,可勾选额外可重试错误码(默认补入 INVALID_REQUEST:OpenAI thinking 模式 HTTP 400 自动重试)。npm: dsh-llm-retry-settings
项目介绍Project Overview
dsh-llm-retry-settings 是 DSH 的 LLM 自动重试引擎设置卡片插件,在“设置→通用”中调整重试次数、退避延迟、抖动比例及额外可重试错误码,保存后即时生效。需要自定义请求失败重试策略时使用;默认 enabled 为 false,需手动开启覆盖,且依赖宿主插件 @deepseek-ai/dsh-llm-retry。
dsh-llm-retry-settings is a DSH plugin that adds a settings card for the LLM auto-retry engine. In Settings → General, it lets you configure retry count, backoff delay, jitter, and extra retryable error codes, with changes applied live. Use it when you need to customize request-failure retry behavior. It is disabled by default and requires the host plugin @deepseek-ai/dsh-llm-retry.
请帮我了解并安装插件:【dsh-llm-retry-settings】【https://github.com/zeng6125-rgb/dsh-llm-retry-settings】
把上面这条消息直接发给当前会话里的 DSH,让它帮你了解并安装。安装命令不一定准确,发给 DSH 更稳。Send this message to DSH in your current session. CLI install commands may not be accurate across systems — DSH will figure it out for you.
或使用命令行安装(适合开发者)Or use CLI install (for developers)
命令行安装CLI Install
dsh plugin --profile web add github:zeng6125-rgb/dsh-llm-retry-settings
把 zeng6125-rgb/dsh-llm-retry-settings 加入你的 DSH 配置(web profile)即可启用。
READMEREADME
dsh-llm-retry-settings
A settings card for the DSH LLM auto-retry engine (@deepseek-ai/dsh-llm-retry). Tune the retry count and backoff from Settings → General; changes take effect immediately.
Features
- Includes the settings UI (client bundle
lib/client.js): a card in Settings → General — no separate UI package needed. - Overrides
maxRetries,initialDelayMs,maxDelayMs, andjitterRatioon theagent/request-errorretry policy. - New in 0.1.3 — configurable
retryableCodes: extra failure codes to retry on, merged into each provider's own list (never replaces it). Defaults toINVALID_REQUEST+PI_AI_ERROR, so OpenAI-style HTTP 400 errors (thinking-modereasoning_text) and generic stream failures get retried out of the box. - Default
enabled: false= fully bypassed; nothing changes until you enable the override.
Install
Prerequisite: a DSH Desktop profile (the web profile lives at ~/.dsh/profiles/web).
Option A — GitHub Release package (recommended)
# 1. download the packaged plugin tgz from the v0.1.4 release
gh release download v0.1.4 -R zeng6125-rgb/dsh-llm-retry-settings
# 2. unpack it into the profile's node_modules
mkdir -p ~/.dsh/profiles/web/node_modules
tar -xzf dsh-llm-retry-settings-0.1.4.tgz -C ~/.dsh/profiles/web/node_modules/
mv ~/.dsh/profiles/web/node_modules/package \
~/.dsh/profiles/web/node_modules/dsh-llm-retry-settings
# 3. register the bundle in the profile, then restart DSH
# add "dsh-llm-retry-settings" to dsh.profile.bundles
# in ~/.dsh/profiles/web/package.json
Option B — dsh CLI / pnpm (requires git + network)
The dsh plugin command forwards its arguments to pnpm in the profile directory:
# from a git repo (pnpm clones it; the committed lib/ means no build needed)
dsh plugin --profile web add github:zeng6125-rgb/dsh-llm-retry-settings
# or from the release tarball URL
dsh plugin --profile web add https://github.com/zeng6125-rgb/dsh-llm-retry-settings/releases/download/v0.1.4/dsh-llm-retry-settings-0.1.4.tgz
Then enable the plugin in the profile: add "dsh-llm-retry-settings" to dsh.profile.bundles (or use the Desktop plugin-inventory UI) and restart DSH.
Note: the command is
dsh plugin(a subcommand of thedshCLI), notdsh-plugin. ThedshCLI is bundled with the Desktop app; if it is not on yourPATH, invoke it via the app'snode_modulesbin, e.g.node "<app>/node_modules/@deepseek-ai/dsh/lib/bin.js" plugin --profile web ....
Option C — from source
git clone https://github.com/zeng6125-rgb/dsh-llm-retry-settings.git
cd dsh-llm-retry-settings
npm run build # bash scripts/build.sh (requires DSH_CHECKOUT)
Link the local build into the profile and register the bundle:
dsh plugin --profile web link "$PWD"
# then add "dsh-llm-retry-settings" to dsh.profile.bundles and restart DSH
Usage
- Open DSH Settings → General.
- Find the LLM 自动重试 card.
- Toggle 开启覆盖 (
enabled) to apply the override. - Set
maxRetries/initialDelayMs/maxDelayMs/jitterRatio, pick extra retryable codes (chips), and click 保存.
Changes are written to the dsh-llm-retry settings namespace and picked up live by the retry engine.
Configuration
| Key | Type | Default | Description |
|---|---|---|---|
enabled |
boolean | false |
Enable the retry-policy override. |
maxRetries |
integer (≥ 0) | 2 |
Maximum retry count (0 = do not retry). |
initialDelayMs |
integer (≥ 1) | 500 |
Initial backoff before the first retry (ms). |
maxDelayMs |
integer (≥ 1) | 10000 |
Upper bound for backoff (ms). |
jitterRatio |
number (0–1) | 0.1 |
Random jitter applied to backoff (0 = none). |
retryableCodes |
string[] | ["INVALID_REQUEST", "PI_AI_ERROR"] |
Extra failure codes treated as retryable, merged into each provider's own list. |
How it works
The host half registers the dsh-llm-retry settings namespace (schema validation + persistence + live sync) and prepends an agent/request-error listener that rewrites retryPolicy before the official @deepseek-ai/dsh-llm-retry recover runs:
agent/request-error → [this plugin: override count/backoff] → dsh-llm-retry recover
UI
Settings → General → LLM 自动重试 card. Edits are draft-based: click 保存 to commit or 放弃 to discard. After saving, the card verifies the write against the settings snapshot and shows 已保存 ✓ / 保存失败 ✗.
Requirements
- Host plugin:
@deepseek-ai/dsh-llm-retry - Client runtime:
@deepseek-ai/dsh-client-web-react - DSH
settingsservice
Build
npm run build # bash scripts/build.sh (requires DSH_CHECKOUT)
npm run typecheck # tsc --noEmit
nexu-io/open-design
freestylefly/awesome-gpt-image-2
anywhere-labs/dsh-desktop
walkinglabs/learn-harness-engineering
awesome-dsh-plugin/awesome-dsh-plugin
MemTensor/MemOS