dsh-client-auto-continue 0.11.8 → 0.12.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -44,6 +44,8 @@ For [DeepSeek Harness](https://github.com/deepseek-ai/deepseek-harness) (`dsh we
44
44
  - **English / Chinese localization** — the settings card, built-in resume / guard / loop text, and browser notifications follow DSH's active UI language (initially selected from the browser language). Only `en` and `zh` are supported; other languages fall back to Chinese. Switching languages updates built-in defaults without overwriting custom text
45
45
  - **Templated continue text** — `continueText` supports `{code}` `{message}` `{status}` `{tool}` `{turn}` `{errorCount}` `{sessionTitle}` `{elapsed}` placeholders, so the resume message can carry the failure context ("Continue ({tool} failed: {code})"); a **separate template** fires on `max-tokens` (e.g. "Continue the output without repeating anything already generated")
46
46
  - **Idempotency guard** — before resuming, the plugin inspects the last tool call: if its result is unconfirmed (the turn died mid-tool, e.g. a `git push` that may have gone through), the resume message tells the model to check state first and not to rerun; if the tool is confirmed done, it says so and asks not to repeat it; a failed tool gets no guard (retrying it is the point). Both guard texts are configurable (`{tool}` / `{result}` placeholders)
47
+ - **Silent turn resume** — recover an observed model step or reasoning-only response that completes without visible output. A no-op turn with no model activity is left alone. Text, tool calls, images and extension blocks count as visible, including streamed output. Unobserved turns are not guessed to be silent. Explicit `no-visible-output` markers also recover after restart. Disabling **Resume silent turns** cancels queued silent sends; silent turns never reset the retry cap, even while the option is off.
48
+ - **Autonomous loop** — when enabled, resumes after every normally completed turn, looping until stopped manually. Successful resumes do not count toward the consecutive cap; only failures do — a turn that completes with no visible output counts as a failure, so a stuck model still stops at the cap instead of retrying forever. Global and per-session pause still apply, and the loop text is configurable (defaults to `Continue`).
47
49
  - **Pause** — a global **Pause auto-continue** toggle in the settings card stops everything (live + scan) instantly; per-session pauses (e.g. via a notification button) suspend only one session until they expire. The **Resume now** notification button is the one explicit exception: pressing it is the user asking for exactly one send, pause or not
48
50
  - **Notification buttons** — notifications carry **Resume now** (send immediately, ignoring cooldown, the consecutive cap and any pause) and **Pause this session 1h** actions
49
51
  - **Loop guard** — watches **running** turns too. Four signals trip the guard, which cancels the turn and restarts it with a configurable loop text ("stop repeating, try another way"): the model repeating the **exact same message** several times (any length — e.g. "Let me test variants of the regex…" ×7), repeated near-duplicate paragraphs **inside one streamed assistant message**, many short messages inside a short time window with no tool call in between (the "Let me read…" spin), or the same tool called repeatedly with the **same arguments and the same results** (a changed argument or result counts as progress). The cancel carries an internal marker so it is never confused with a user stop — the restart only happens for guard-initiated cancels. Thresholds, the time window and the loop text are configurable
@@ -57,6 +59,7 @@ It watches the live event streams and reacts to:
57
59
  | `turn/end` → `error` | Turn failed (model / network / timeout, …) |
58
60
  | `turn/end` → `interrupted` | Crash-orphaned turn left behind by a host restart (recovered by the startup scan) |
59
61
  | `turn/end` → `max-tokens` | Output token ceiling reached |
62
+ | `turn/end` → `completed` / `no-visible-output` with no visible output | Turn ended normally with reasoning only: no text, no tool call |
60
63
  | `host/agent-error` | Agent failure with no turn position (only network/timeout-class messages auto-resume) |
61
64
 
62
65
  **Never auto-continues:** user-aborted turns (`aborted`) or policy rejections (`blocked`); live `interrupted` turn-ends too — that marker is only written by crash repair when the host reloads, so orphaned turns are recovered by the startup scan, not the live path; sessions the host already resumed itself; running sessions; subagent sessions; anything inside the cooldown / consecutive-cap windows (configurable in the settings card, below). If an interrupted session already has queued turns, the continuation runs first and the existing turns retain their order behind it.
@@ -79,11 +82,13 @@ The diagram summarizes the automatic recovery path, the loop-guard restart path,
79
82
 
80
83
  ## Quick Start
81
84
 
82
- DSH plugins install into a **profile** (`dsh web` → `web` profile). Install, restart `dsh web`, done.
85
+ DSH plugins install into a **profile** (`dsh web` → `web` profile). The commands below install into the web profile; restart `dsh web` after installation. In the desktop app, install through its **Plugins** page instead.
83
86
 
84
- > **Use the latest DSH (recommended: 0.1.2-alpha.4 or newer).** Run `dsh --version` before installing. Plugin v0.11.1 supports the settings API used by DSH 0.1.2-alpha.2+ (including alpha.3 and alpha.4) while retaining compatibility with DSH 0.1.0-rc.7 through 0.1.1; rc.6 and earlier remain unsupported (`list slot ... requires options.id`). Preview releases may appear on the [official DSH releases page](https://github.com/deepseek-ai/deepseek-harness/releases) before the public npm tag catches up.
87
+ > **For DSH 0.1.7, use plugin v0.11.9 or newer.** This guide and its screenshots use DSH **0.1.7-rc.2** with plugin **0.11.9**. Run `dsh --version` before installing and check the [official DSH releases](https://github.com/deepseek-ai/deepseek-harness/releases): preview releases may arrive before the public npm `latest` tag catches up.
85
88
 
86
- Plugin v0.11.8 also supports DSH 0.1.7-alpha.2's `configForms` API. Open **Plugins → dsh-client-auto-continue** for its settings; older DSH versions retain **Settings → Plugins**. This fixes the startup error `pending (waiting for service: settingsScope)` on the newer API.
89
+ On DSH 0.1.7, open **Plugins → dsh-client-auto-continue → Auto continue** to configure the plugin. **Settings → Built-in plugins** only shows component status; it has no editable configuration fields.
90
+
91
+ Older hosts retain **Settings → Plugins → Plugin configuration**. DSH 0.1.0-rc.6 and earlier are unsupported. If you previously installed with a symlink or edited the loader config by hand, follow [Migrating an older installation](#migrating-an-older-installation).
87
92
 
88
93
  ### From npm (recommended)
89
94
 
@@ -122,32 +127,37 @@ dsh plugin --profile web add link:$(pwd)
122
127
  dsh web
123
128
  ```
124
129
 
125
- ### Manual (no pnpm / dsh plugin needed)
130
+ ### Migrating an older installation
126
131
 
127
- ```bash
128
- ln -sfn "$(pwd)" ~/.dsh/profiles/node_modules/dsh-client-auto-continue
129
- # then append to ~/.dsh/profiles/web/cordis.patch.yml:
130
- # - insert:
131
- # - id: auto-continue
132
- # name: 'dsh-client-auto-continue'
133
- dsh web
134
- ```
132
+ A manual loader entry can start the engine without registering a bundle in the **Plugins** page. Use the profile's package manager to install the bundle; a symlink and `insert` entry alone are no longer the recommended setup.
133
+
134
+ 1. Let active work finish, then stop `dsh web`. Back up `package.json`, `cordis.patch.yml` and `pnpm-lock.yaml` in `~/.dsh/profiles/web/`, plus `~/.dsh/settings.yaml` if it exists. If you set `DSH_HOME`, use that directory instead of `~/.dsh`.
135
+ 2. Keep your existing auto-continue values. Remove only the manually added `auto-continue` row **inside an `insert` list** (and the list if it becomes empty). The installed bundle supplies that row. A top-level `- id: auto-continue` with `config:` is a configuration override: **keep it**.
136
+ 3. Install with either the npm or GitHub command above. In the profile's `package.json`, `dsh.profile.bundles` should now include `dsh-client-auto-continue`, alongside the existing DSH bundles. If it already does and the plugin appears in **Plugins**, this part is already complete.
137
+ 4. On DSH 0.1.7, merge any saved values from the old `settings.yaml` → `auto-continue` section or the removed row's `config` into the profile's `cordis.patch.yml`. For example, a custom cooldown becomes:
138
+
139
+ ```yaml
140
+ - id: auto-continue
141
+ config:
142
+ cooldownMs: 45000 # example: preserve your own saved value
143
+ ```
135
144
 
136
- > Switching from a manual install to `dsh plugin add`? Remove the manual `insert` entry first — the bundle patch registers the row and a duplicate would conflict.
145
+ Merge into an existing override instead of adding another one. Keep unrelated settings intact. DSH 0.1.7 reads this entry config; editing the old `settings.yaml` section will not update the new form.
146
+ 5. Start `dsh web` again and reload the browser. Open **Plugins → dsh-client-auto-continue**, expand **Auto continue**, and check that your values are present. Save a change and reload to confirm it persists.
137
147
 
138
- > **Settings exposure:** since DSH 0.1.0-rc.7 the web settings surface is **registry-driven** — every namespace a plugin registers is served, so the settings card works out of the box, no vendor patch needed (the plugin requires rc.7+, see Quick Start).
148
+ The `include:auto-continue` label in **Built-in plugins** is a normal loader prefix. It does not, by itself, indicate a legacy install or a duplicate engine.
139
149
 
140
150
  ### Verify & uninstall
141
151
 
142
152
  ```bash
143
- dsh --profile web --dump-config | grep auto-continue # config layer mounted
153
+ dsh --profile web --dump-config | grep -A 4 'id: auto-continue'
144
154
  ```
145
155
 
146
- In the browser console (Ctrl/Cmd+Shift+I): `[auto-continue] 已启动(文本="继续", …)` — every detection and auto-send is logged.
156
+ The composed config should contain one `id: auto-continue` entry. In **Plugins → dsh-client-auto-continue**, check that the component is **Running** and that expanding **Auto continue** shows editable fields. With verbose logging enabled, engine activity appears in the terminal running DSH.
147
157
 
148
158
  ```bash
149
159
  dsh plugin --profile web remove dsh-client-auto-continue # npm / repo install
150
- # or remove the symlink + the insert entry # manual install
160
+ # also remove this plugin's config override from cordis.patch.yml, if present
151
161
  dsh web
152
162
  ```
153
163
 
@@ -155,60 +165,96 @@ dsh web
155
165
 
156
166
  ## Configuration
157
167
 
158
- Everything is configurable from the GUI — no file or console edits needed. Open **Settings → Plugins → Plugin configuration**. **Auto Continue** appears as a collapsed card alongside the other plugins; click the card or its right-hand chevron to expand the full configuration in place. Besides the fields below, the expanded card shows a live **stats panel** (today's activity with a reset button) and the list of **paused sessions** (each with a per-session resume button).
168
+ On **DSH 0.1.7**, open **Plugins** from the main sidebar, choose **dsh-client-auto-continue**, then expand the **Auto continue** card. This is separate from **Settings → Built-in plugins**, which only lists component status. Older DSH versions use **Settings → Plugins → Plugin configuration**.
169
+
170
+ ![DSH 0.1.7 Plugins page with the Auto continue card collapsed](docs/screenshots/01-settings-section.png)
171
+
172
+ Click the card header or its right-hand chevron to show the fields. The expanded card also contains a live **stats panel** (today's activity with a reset button) and **paused sessions** (each with a resume button).
159
173
 
160
174
  The settings card groups controls by handoff, safety, recovery, loop breaking, and live status. Its header also keeps the open-source repository and a **Star on GitHub** shortcut within reach.
161
175
 
162
- **Or skip the GUI and edit the config file directly** — the engine reads the plugin's section from `~/.dsh/settings.yaml` (one shared file for every plugin's sections), so this works in any install, patched or not. The file is watched and re-read automatically, so changes apply live; restart `dsh web` if a page that was already open doesn't pick them up. Fields you leave out fall back to the defaults in the table below.
176
+ DSH 0.1.7 stores these values in the `auto-continue` entry's config in the active profile patch (`~/.dsh/profiles/web/cordis.patch.yml` for the default web profile). **Save** applies changes live without restarting the engine. Omitted fields use the defaults below.
177
+
178
+ Startup recovery polls every three seconds for sessions that load late, up to `freshMs` after the engine starts. Each settled session history is inspected once. `scanLimit` limits eligible recoveries per pass, so healthy or permanent-error sessions cannot crowd out interrupted ones. Pausing suspends recovery within the same window; unloading cancels the poller.
163
179
 
164
- The browser mirrors DSH's active language into the internal `locale` field. Leave the five localized text fields empty or omit them to follow that language automatically; any non-empty value is treated as your own template and is never rewritten when the language changes:
180
+ The browser mirrors DSH's active language into the internal `locale` field. Leave the seven localized text fields empty or omit them to follow that language automatically; any non-empty value is treated as your own template and is never rewritten when the language changes:
181
+
182
+ ```yaml
183
+ - id: auto-continue
184
+ config:
185
+ locale: 'en' # normally managed by the browser
186
+ paused: false
187
+ continueText: ''
188
+ resumeSilentTurns: true
189
+ resumeCompletedTurns: false
190
+ continueTextSilent: ''
191
+ continueTextLoop: ''
192
+ continueTextMaxTokens: ''
193
+ guardTools: true
194
+ guardPendingText: ''
195
+ guardDoneText: ''
196
+ graceMs: 3000
197
+ cooldownMs: 20000
198
+ maxConsecutive: 3
199
+ scanOnBoot: true
200
+ scanLimit: 8
201
+ freshMs: 900000
202
+ verbose: true
203
+ classify: true
204
+ retryableErrorPatterns: ''
205
+ backoffFactor: 2
206
+ backoffMaxMs: 300000
207
+ notify: false
208
+ loopGuard: true
209
+ loopShortChars: 40
210
+ loopWindowMs: 30000
211
+ loopShortCount: 12
212
+ loopRepeatText: 4
213
+ loopToolRepeat: 5
214
+ loopText: ''
215
+ ```
216
+
217
+ <details>
218
+ <summary>Configuration files on older DSH versions</summary>
219
+
220
+ Older hosts store user settings in `~/.dsh/settings.yaml` under the plugin namespace instead of a profile entry:
165
221
 
166
222
  ```yaml
167
223
  auto-continue:
168
- locale: 'en' # normally managed by the browser
169
- paused: false
170
- continueText: ''
171
- continueTextMaxTokens: ''
172
- guardTools: true
173
- guardPendingText: ''
174
- guardDoneText: ''
175
- graceMs: 3000
176
- cooldownMs: 20000
177
- maxConsecutive: 3
178
- scanOnBoot: true
179
- scanLimit: 8
180
- freshMs: 900000
181
- verbose: true
182
- classify: true
183
- retryableErrorPatterns: ''
184
- backoffFactor: 2
185
- backoffMaxMs: 300000
186
- notify: false
187
- loopGuard: true
188
- loopShortChars: 40
189
- loopWindowMs: 30000
190
- loopShortCount: 12
191
- loopRepeatText: 4
192
- loopToolRepeat: 5
193
- loopText: ''
224
+ cooldownMs: 45000
194
225
  ```
195
226
 
227
+ When upgrading to DSH 0.1.7, move these values into the profile entry's `config` as described in [Migrating an older installation](#migrating-an-older-installation).
228
+
229
+ </details>
230
+
196
231
  **How the card works:**
197
232
 
198
- ![The collapsed Auto Continue card in the plugin configuration list](docs/screenshots/02-settings-card.png)
233
+ ![Expanded Auto continue configuration on DSH 0.1.7](docs/screenshots/02-settings-card.png)
199
234
 
200
235
  - Edits are **staged** — nothing reaches the disk until you hit **Save**; an unsaved badge marks the card while drafts are pending, and **Discard** drops them
201
236
  - A field you changed shows an **Overridden** badge with a per-field **Reset to default** button that restores the built-in value
202
237
  - Boolean fields are **tri-state**: *Inherit* (use the default) / *On* / *Off*
203
238
  - Invalid drafts (non-numbers, values below the minimum) block the save with a hint
204
239
  - In a read-only deployment the card shows the stored values but disables every control
205
- - Changes apply immediately after Save and persist in `~/.dsh/settings.yaml` (uninstalling the plugin leaves the section behind — harmless, delete it by hand if you like)
240
+ - Changes apply immediately after Save and persist in the active profile config (or `~/.dsh/settings.yaml` on older hosts)
241
+
242
+ <details>
243
+ <summary>Live status and the Save / Discard buttons</summary>
244
+
245
+ ![Live status and save controls at the bottom of the DSH 0.1.7 configuration card](docs/screenshots/07-card-panels.png)
246
+
247
+ </details>
206
248
 
207
249
  | Field | Default | Description |
208
250
  | --- | --- | --- |
209
251
  | Pause auto-continue | `off` | Global pause: no live or scan auto-send fires, queued pending sends are cancelled |
210
252
  | Continue text | `Continue` | Text automatically sent after an interruption |
211
253
  | Continue text (max tokens) | `Continue` | Text sent when the output token ceiling is reached (same placeholders) |
254
+ | Resume silent turns | `on` | Resume a turn that ended normally with reasoning only (no text, no tool call); does not reset the consecutive count |
255
+ | Continue text (silent turn) | `Continue. Your previous turn ended with internal reasoning only, ...` | Text sent to resume a silent turn (same placeholders) |
256
+ | Autonomous loop (continue after every turn) | `off` | Resume after every normally completed turn until stopped manually; successful resumes do not count toward the consecutive cap (no-visible-output turns do count) |
257
+ | Continue text (autonomous loop) | `Continue` | Text sent on each autonomous-loop resume (same placeholders) |
212
258
  | Idempotency guard | `on` | Inspect the last tool call before resuming and steer the model (see What It Does) |
213
259
  | Loop guard | `on` | Detect a running turn spinning in place and restart it (see What It Does) |
214
260
  | Short-sentence max (chars) | `40` | A model message shorter than this counts as a short sentence (spinning signal) |
@@ -221,11 +267,11 @@ auto-continue:
221
267
  | Guard text (tool succeeded) | `(The previous tool "{tool}" completed successfully. Result: {result}; do not run it again. Continue from there.)` | Appended when the last tool is confirmed done; `{tool}` / `{result}` placeholders |
222
268
  | Grace period (ms) | `3000` | Wait after an interruption; cancelled if the host recovers on its own |
223
269
  | Cooldown (ms) | `20000` | Min interval between auto-continues per session (failed attempts count too) |
224
- | Max consecutive | `3` | Max consecutive auto-continues; stops until a user intervenes or a turn completes |
225
- | Scan on load / reconnect | `on` | Scan recently interrupted sessions on load / reconnect |
226
- | Scan limit | `8` | Max sessions scanned (running / subagent sessions excluded) |
227
- | Scan window (ms) | `900000` | Scan only considers interruptions inside this window |
228
- | Verbose logs | `on` | `[auto-continue]` console logs |
270
+ | Max consecutive | `3` | Max consecutive auto-continues; stops until a user intervenes or a turn completes with visible output |
271
+ | Scan on host startup | `on` | Recover interrupted sessions that become available during the startup window |
272
+ | Scan limit | `8` | Maximum eligible recoveries per pass, most recently active first |
273
+ | Scan window (ms) | `900000` | Maximum interruption age and duration of startup polling |
274
+ | Verbose logs | `on` | `[auto-continue]` engine logs in the DSH terminal |
229
275
  | Classify errors | `on` | Auto-resume transient failures only; auth / balance / model errors are skipped and notified |
230
276
  | Custom retryable errors | empty | One case-insensitive literal per line; matching the error code, HTTP status, or message explicitly overrides the built-in classifier |
231
277
  | Backoff factor | `2` | Cooldown multiplier per consecutive failure (2 = 20s → 40s → 80s…) |
@@ -235,30 +281,34 @@ auto-continue:
235
281
  For a provider-specific error that is safe to resume (confirm first that manually sending "continue" recovers), add a narrow, stable fragment rather than disabling classification globally:
236
282
 
237
283
  ```yaml
238
- auto-continue:
239
- retryableErrorPatterns: |-
240
- Upstream rejected the request as invalid
284
+ - id: auto-continue
285
+ config:
286
+ retryableErrorPatterns: |-
287
+ Upstream rejected the request as invalid
241
288
  ```
242
289
 
243
290
  Patterns are literal substrings, not regular expressions. Blank lines are ignored; any matching line wins before the built-in permanent-error rules. Cooldown and consecutive-attempt limits still apply.
244
291
 
245
- `continueText` (and `continueTextMaxTokens`) accept the placeholders `{code}`, `{message}`, `{status}`, `{tool}` (last tool call before the failure), `{turn}`, `{errorCount}` (consecutive failures including this one), `{sessionTitle}` (from the session list) and `{elapsed}` (time since the failure, e.g. `1m5s`) — e.g. `Continue ({tool}: {code})` becomes `Continue (git push: UPSTREAM)`. The guard texts accept `{tool}` and `{result}` (a truncated excerpt of the last tool output).
292
+ `continueText` (and `continueTextMaxTokens`, `continueTextSilent`) accept the placeholders `{code}`, `{message}`, `{status}`, `{tool}` (last tool call before the failure), `{turn}`, `{errorCount}` (consecutive failures including this one), `{sessionTitle}` (from the session list) and `{elapsed}` (time since the failure, e.g. `1m5s`) — e.g. `Continue ({tool}: {code})` becomes `Continue (git push: UPSTREAM)`. The guard texts accept `{tool}` and `{result}` (a truncated excerpt of the last tool output).
246
293
 
247
294
  ---
248
295
 
249
296
  ## Privacy & permissions
250
297
 
251
- The plugin is browser-only and touches **no files, credentials, or network beyond the dsh host**:
298
+ The recovery engine runs inside the DSH host. The browser provides the configuration card, live status and optional notifications:
252
299
 
253
- - It opens the same two read-only event streams the web UI already uses (no extra server, no third-party endpoints)
254
- - The engine's **only automatic write** is `sessions.prompt` — the same call the Send button makes — with the text you configured (saving the settings card writes the `auto-continue` section of `~/.dsh/settings.yaml` through the normal settings API, exactly like any other setting)
255
- - No browser storage at all: the single host-side engine keeps its cooldowns, send caps, pauses and stats in process memory
300
+ - The engine reads session events and history through DSH's services. The browser talks to that host; the plugin adds no third-party service or credential store
301
+ - Recovery sends your configured text through `agent.followup`. The loop guard can cancel a looping turn through `agent.cancel` before sending its recovery prompt. Resumed agents continue with the session's existing tools and permissions
302
+ - Saving configuration uses DSH's settings API: the active profile patch on DSH 0.1.7, or `~/.dsh/settings.yaml` on older hosts
303
+ - Cooldowns, send caps, pauses and stats stay in host process memory and reset when the engine restarts
256
304
  - Browser notifications are opt-in (`notify` setting) and permission is requested on first use only
257
305
 
258
306
  ---
259
307
 
260
308
  ## Development
261
309
 
310
+ The CI runtime test uses the published DSH 0.1.7 packages to check the HTTP bridge and live settings through the real Loader. Run `npm ci --prefix tests/fixtures/dsh-0.1.7` once, then `npm run test:runtime` after building.
311
+
262
312
  ```bash
263
313
  npm run typecheck # tsc --noEmit
264
314
  npm run build # lib/client.js + lib/index.js + lib/types
package/README.zh.md CHANGED
@@ -44,6 +44,8 @@
44
44
  - **中英文本地化** — 设置卡片、内置续跑 / 护栏 / 循环文案以及浏览器通知都跟随 DSH 当前界面语言(初始值来自浏览器语言)。只支持 `en` 和 `zh`, 其他语言回落中文; 切换语言只会替换内置默认值, 不会覆盖用户自定义文本
45
45
  - **模板化继续文本** — `continueText` 支持 `{code}` `{message}` `{status}` `{tool}` `{turn}` `{errorCount}` `{sessionTitle}` `{elapsed}` 占位符, 续跑消息可携带失败上下文(如「继续 (git push 失败: UPSTREAM)」); 达到 `max-tokens` 时使用**另一套模板**(如「继续输出, 不要重复已生成的内容」)
46
46
  - **幂等护栏** — 续跑前检查上一步工具调用: 结果未确认(回合在工具执行中途夭折, 如 `git push` 可能已经推上去了)时, 续跑消息会提示模型先确认状态、不要重复执行; 工具已确认成功时说明已完成、请勿重复; 工具失败则不加护栏(重试本来就是目的)。两段护栏文本都可配置(支持 `{tool}` / `{result}` 占位符)
47
+ - **无输出回合续跑** — 已观察到模型步骤或推理回复,但回合正常结束且没有可见输出时自动恢复。没有模型活动的空回合不会触发;文本、工具调用、图片、扩展块和已显示的流式内容均算可见输出。未观察到开始的回合不会被猜测为静默。启动后也能恢复显式的 `no-visible-output` 标记。关闭开关会取消排队中的静默续跑;即使开关关闭,静默回合也不会清零重试上限。
48
+ - **自主循环** — 开启后每个正常完成的回合都自动续跑,直到手动停止。成功的续跑不计入连续上限,只有失败计数(无可见输出的回合按失败计,卡住的模型仍会触及上限,而不是无限重试);全局暂停与会话暂停照常生效,循环文本可配置(默认 `继续`)。
47
49
  - **暂停** — 设置卡片里的全局 **暂停自动继续** 开关可立即停掉一切(实时 + 扫描); 会话级暂停(如通过通知按钮)只挂起单个会话, 到期自动恢复。唯一的显式例外是通知里的 **立即续跑** 按钮——按下它等于用户明确要求发送这一次, 不受暂停限制
48
50
  - **通知按钮** — 通知带 **立即续跑**(无视冷却、连续上限与暂停, 马上发送)和 **暂停该会话 1 小时** 按钮
49
51
  - **循环守卫** — 连**运行中的回合**也盯着, 四个信号都会触发守卫(取消当前回合并用可配置的循环提示文本重启, 「停止重复, 换一种方式」): 模型**连续输出完全相同的消息**(不限长度, 如 "Let me test variants of the regex…" 连续 7 遍)、单条流式 assistant 消息内部出现连续近似重复段落、短时间内连续多条短句且期间无工具调用(典型的「Let me read…」空转)、或同一工具被连续反复调用且**参数与结果都相同**(参数或结果有变化视为有进展)。取消带有内部来源标记, 绝不会与用户手动停止混淆——只有守卫发起的取消才会重启。阈值、时间窗与提示文本都可配置
@@ -57,6 +59,7 @@
57
59
  | `turn/end` → `error` | 回合失败(模型 / 网络 / 超时等) |
58
60
  | `turn/end` → `interrupted` | 宿主崩溃重启后遗留的中断回合(由启动扫描恢复) |
59
61
  | `turn/end` → `max-tokens` | 达到输出 token 上限 |
62
+ | `turn/end` → `completed` / `no-visible-output` 且无可见输出 | 回合正常结束但只有推理: 没有文本, 也没有工具调用 |
60
63
  | `host/agent-error` | 无回合位置的 Agent 失败(仅网络/超时类消息自动续跑) |
61
64
 
62
65
  **绝不自动继续:** 用户主动停止(`aborted`)或策略拒绝(`blocked`); 实时流里的 `interrupted` 同样不自动继续——该标记只在宿主重载时由崩溃修复写入, 孤儿回合由启动扫描恢复, 不走实时路径; 宿主已自行恢复的会话; 正在运行的会话; 子代理会话; 处于冷却期 / 连续次数上限内的会话(可在设置卡片中调整, 见下)。若中断会话已有排队消息, 续跑消息会先执行, 原有消息随后按原顺序处理。
@@ -79,11 +82,13 @@
79
82
 
80
83
  ## 快速开始
81
84
 
82
- DSH 插件安装进 **profile**(`dsh web` 对应 `web` profile)。安装后重启 `dsh web` 即可。
85
+ DSH 插件安装进 **profile**(`dsh web` 对应 `web` profile)。下面的命令用于 Web 版, 安装后重启 `dsh web`。桌面版请通过应用内的**插件**页面安装。
83
86
 
84
- > **请使用最新 DSH(推荐 0.1.2-alpha.4 或更高版本)。** 安装前先运行 `dsh --version`。插件 v0.11.1 已支持 DSH 0.1.2-alpha.2+ 使用的设置 API(包括 alpha.3 和 alpha.4), 同时继续兼容 DSH 0.1.0-rc.7 至 0.1.1; rc.6 及更早版本仍不支持(`list slot ... requires options.id`)。预览版可能先发布在 [DSH 官方 Releases](https://github.com/deepseek-ai/deepseek-harness/releases), 公开 npm 标签会稍后跟进。
87
+ > **DSH 0.1.7 请使用插件 v0.11.9 或更新版本。** 本文和截图使用 **DSH 0.1.7-rc.2 + 插件 0.11.9**。安装前运行 `dsh --version`, 并核对 [DSH 官方 Releases](https://github.com/deepseek-ai/deepseek-harness/releases): 预览版可能先于公开 npm 的 `latest` 标签发布。
85
88
 
86
- 插件 v0.11.8 也已支持 DSH 0.1.7-alpha.2 的 `configForms` API。新版从 **插件 → dsh-client-auto-continue** 进入设置, 旧版仍从 **设置 → 插件** 进入。此适配修复了新版启动时的 `pending (waiting for service: settingsScope)` 错误。
89
+ DSH 0.1.7 的配置入口是**插件 → dsh-client-auto-continue → 自动继续**。**设置 → 内置插件**只展示组件状态, 没有可编辑的配置项。
90
+
91
+ 旧版宿主仍从**设置 → 插件 → 插件配置**进入。DSH 0.1.0-rc.6 及更早版本不受支持。如果之前使用软链或手动修改 Loader 配置安装, 请按[旧安装迁移](#旧安装迁移)操作。
87
92
 
88
93
  ### 从 npm 安装(推荐)
89
94
 
@@ -122,32 +127,37 @@ dsh plugin --profile web add link:$(pwd)
122
127
  dsh web
123
128
  ```
124
129
 
125
- ### 手动安装(无需 pnpm / dsh plugin)
130
+ ### 旧安装迁移
126
131
 
127
- ```bash
128
- ln -sfn "$(pwd)" ~/.dsh/profiles/node_modules/dsh-client-auto-continue
129
- # 然后在 ~/.dsh/profiles/web/cordis.patch.yml 追加:
130
- # - insert:
131
- # - id: auto-continue
132
- # name: 'dsh-client-auto-continue'
133
- dsh web
134
- ```
132
+ 手动添加 Loader 条目可以启动引擎, 但未必会在**插件**页面登记 bundle。请通过 profile 的包管理命令安装; 不再推荐只创建软链并添加 `insert` 条目。
133
+
134
+ 1. 等当前任务结束后停止 `dsh web`。备份 `~/.dsh/profiles/web/` 下的 `package.json`、`cordis.patch.yml`、`pnpm-lock.yaml`, 以及存在时的 `~/.dsh/settings.yaml`。如果设置了 `DSH_HOME`, 请用该目录替代 `~/.dsh`。
135
+ 2. 保留已有的自动继续参数。只删除 **`insert` 列表内**手动添加的 `auto-continue` 行; 若列表因此变空, 一并删除空列表。安装包会提供该行。顶层的 `- id: auto-continue` 搭配 `config:` 是配置覆盖项, **应当保留**。
136
+ 3. 使用上面的 npm 或 GitHub 命令安装。profile 的 `package.json` 中, `dsh.profile.bundles` 应在原有 DSH bundles 之外包含 `dsh-client-auto-continue`。如果已经包含, 且**插件**页面已有该插件, 这一步已经完成。
137
+ 4. 在 DSH 0.1.7 上, 将旧 `settings.yaml` → `auto-continue` 段落或已移除条目的 `config` 参数合并到 profile 的 `cordis.patch.yml`。例如, 自定义冷却时间写成:
138
+
139
+ ```yaml
140
+ - id: auto-continue
141
+ config:
142
+ cooldownMs: 45000 # 示例: 请保留你原先设置的值
143
+ ```
135
144
 
136
- > 从手动安装切换到 `dsh plugin add` 时, 请先删掉手动加的 `insert` 条目——包自带的 bundle patch 会注册插件行, 重复注册会冲突。
145
+ 若已有覆盖项, 请合并到其中, 不要重复添加。保留其他设置。DSH 0.1.7 读取的是条目配置, 修改旧 `settings.yaml` 段落不会更新新版表单。
146
+ 5. 重新启动 `dsh web` 并刷新浏览器。打开**插件 → dsh-client-auto-continue**, 展开**自动继续**, 检查旧参数是否保留。保存一次修改并刷新, 确认配置持久化正常。
137
147
 
138
- > **设置暴露:** DSH 0.1.0-rc.7 起 webui 设置区是**注册表驱动**的——插件注册的命名空间直接可见, 设置卡片开箱即用, 无需任何供应商补丁(插件要求 rc.7+, 见快速开始)。
148
+ **内置插件**里显示的 `include:auto-continue` 是正常的 Loader 前缀, 单凭这个名字不能判断为旧安装或重复引擎。
139
149
 
140
150
  ### 验证与卸载
141
151
 
142
152
  ```bash
143
- dsh --profile web --dump-config | grep auto-continue # 确认配置层已挂载
153
+ dsh --profile web --dump-config | grep -A 4 'id: auto-continue'
144
154
  ```
145
155
 
146
- 浏览器控制台(Ctrl/Cmd+Shift+I)中应看到 `[auto-continue] 已启动(文本="继续", …)`; 每次检测到中断和自动发送都会打日志。
156
+ 合并后的配置应只有一个 `id: auto-continue` 条目。在**插件 → dsh-client-auto-continue**中确认组件**运行中**, 展开**自动继续**后能编辑字段。开启详细日志后, 引擎活动会输出到运行 DSH 的终端。
147
157
 
148
158
  ```bash
149
159
  dsh plugin --profile web remove dsh-client-auto-continue # npm / 仓库安装
150
- # 或删除软链 + insert 条目 # 手动安装
160
+ # cordis.patch.yml 中若有该插件的配置覆盖项, 也一并移除
151
161
  dsh web
152
162
  ```
153
163
 
@@ -155,60 +165,96 @@ dsh web
155
165
 
156
166
  ## 配置
157
167
 
158
- 所有参数都可以在 GUI 里配置——无需改文件或控制台。打开 **设置 → 插件 → 插件配置**, **自动继续**会像其他插件一样显示为列表中的折叠卡片; 点击卡片或右侧箭头即可在当前位置展开完整配置。除了下面的字段, 展开后的卡片还带一个**统计面板**(今日活动, 可一键清零)和**已暂停会话**列表(每个都可单独解除)。
168
+ 在 **DSH 0.1.7** 中, 从主侧栏打开**插件**, 选择 **dsh-client-auto-continue**, 再展开**自动继续**卡片。**设置 → 内置插件**是单独的组件状态列表, 不能在其中编辑配置。旧版 DSH 的入口仍为**设置 → 插件 → 插件配置**。
169
+
170
+ ![DSH 0.1.7 插件页面中的自动继续折叠卡片](docs/screenshots/01-settings-section.zh.png)
171
+
172
+ 点击卡片标题或右侧箭头即可展开字段。卡片内还带有**统计面板**(今日活动, 可一键清零)和**已暂停会话**列表(每个都可单独解除)。
159
173
 
160
174
  新版配置卡会按接力方式、安全节奏、恢复雷达、循环断路器与现场状态组织配置; 卡片顶部也直接放出了开源仓库和 **Star on GitHub** 入口。
161
175
 
162
- **或者跳过 GUI, 直接编辑配置文件** — 引擎从 `~/.dsh/settings.yaml` 读取插件段落(所有插件的设置都在这一个文件里), 因此无论是否打过补丁都能用。文件被监听、自动重读, 改动即时生效; 若已打开的页面没反应, 重启 `dsh web` 即可。没填写的字段会回落到下表中的默认值。
176
+ DSH 0.1.7 将这些值保存在当前 profile patch 的 `auto-continue` 条目 config 中(默认 Web profile 对应 `~/.dsh/profiles/web/cordis.patch.yml`)。点**保存**后实时生效, 无需重启引擎。省略的字段使用下表默认值。
177
+
178
+ 启动恢复会每三秒等待一次延迟加载的会话,在引擎启动后的 `freshMs` 时间窗结束。每个已就绪会话的历史只检查一次,`scanLimit` 只限制每轮符合条件的恢复数量,正常会话或永久错误不会挤占名额。暂停会在同一时间窗内挂起恢复,卸载插件会取消轮询。
163
179
 
164
- 浏览器会把 DSH 当前语言同步到内部 `locale` 字段。下面五个本地化文本字段保持留空或直接省略时, 会自动跟随语言; 任何非空值都视为用户自己的模板, 切换语言时不会改写:
180
+ 浏览器会把 DSH 当前语言同步到内部 `locale` 字段。下面七个本地化文本字段保持留空或直接省略时, 会自动跟随语言; 任何非空值都视为用户自己的模板, 切换语言时不会改写:
181
+
182
+ ```yaml
183
+ - id: auto-continue
184
+ config:
185
+ locale: 'zh' # 通常由浏览器自动维护
186
+ paused: false
187
+ continueText: ''
188
+ resumeSilentTurns: true
189
+ resumeCompletedTurns: false
190
+ continueTextSilent: ''
191
+ continueTextLoop: ''
192
+ continueTextMaxTokens: ''
193
+ guardTools: true
194
+ guardPendingText: ''
195
+ guardDoneText: ''
196
+ graceMs: 3000
197
+ cooldownMs: 20000
198
+ maxConsecutive: 3
199
+ scanOnBoot: true
200
+ scanLimit: 8
201
+ freshMs: 900000
202
+ verbose: true
203
+ classify: true
204
+ retryableErrorPatterns: ''
205
+ backoffFactor: 2
206
+ backoffMaxMs: 300000
207
+ notify: false
208
+ loopGuard: true
209
+ loopShortChars: 40
210
+ loopWindowMs: 30000
211
+ loopShortCount: 12
212
+ loopRepeatText: 4
213
+ loopToolRepeat: 5
214
+ loopText: ''
215
+ ```
216
+
217
+ <details>
218
+ <summary>旧版 DSH 的配置文件</summary>
219
+
220
+ 旧版宿主将用户设置保存在 `~/.dsh/settings.yaml` 的插件命名空间下, 而非 profile 条目中:
165
221
 
166
222
  ```yaml
167
223
  auto-continue:
168
- locale: 'zh' # 通常由浏览器自动维护
169
- paused: false
170
- continueText: ''
171
- continueTextMaxTokens: ''
172
- guardTools: true
173
- guardPendingText: ''
174
- guardDoneText: ''
175
- graceMs: 3000
176
- cooldownMs: 20000
177
- maxConsecutive: 3
178
- scanOnBoot: true
179
- scanLimit: 8
180
- freshMs: 900000
181
- verbose: true
182
- classify: true
183
- retryableErrorPatterns: ''
184
- backoffFactor: 2
185
- backoffMaxMs: 300000
186
- notify: false
187
- loopGuard: true
188
- loopShortChars: 40
189
- loopWindowMs: 30000
190
- loopShortCount: 12
191
- loopRepeatText: 4
192
- loopToolRepeat: 5
193
- loopText: ''
224
+ cooldownMs: 45000
194
225
  ```
195
226
 
227
+ 升级到 DSH 0.1.7 时, 请按[旧安装迁移](#旧安装迁移)将这些值移入 profile 条目的 `config`。
228
+
229
+ </details>
230
+
196
231
  **卡片操作说明:**
197
232
 
198
- ![插件配置列表中的自动继续折叠卡片](docs/screenshots/02-settings-card.png)
233
+ ![DSH 0.1.7 中展开后的自动继续配置](docs/screenshots/02-settings-card.zh.png)
199
234
 
200
235
  - 修改是**暂存式**的——点「保存」之前不会写入磁盘; 有待保存草稿时卡片显示「未保存」徽章, 「放弃」可丢弃草稿
201
236
  - 改动过的字段会带「已覆盖」徽章, 并有逐字段的「恢复默认」按钮(回到内置默认值)
202
237
  - 布尔字段是三态:**继承**(用默认)/ 开 / 关
203
238
  - 非法输入(非数字、小于最小值)会阻止保存并给出提示
204
239
  - 只读部署中卡片只显示已存值, 所有控件禁用
205
- - 保存后立即生效, 持久化在 `~/.dsh/settings.yaml`(卸载插件会留下该段落, 无害, 想清理可手动删除)
240
+ - 保存后立即生效,持久化在当前 profile 配置中(旧版宿主使用 `~/.dsh/settings.yaml`)
241
+
242
+ <details>
243
+ <summary>现场状态与底部的保存 / 放弃按钮</summary>
244
+
245
+ ![DSH 0.1.7 配置卡底部的现场状态与保存按钮](docs/screenshots/07-card-panels.zh.png)
246
+
247
+ </details>
206
248
 
207
249
  | 字段 | 默认 | 说明 |
208
250
  | --- | --- | --- |
209
251
  | 暂停自动继续 | 关 | 全局暂停: 实时与扫描都不再自动发送, 已排队的待发送也会取消 |
210
252
  | 继续文本 | `继续` | 中断后自动发送的消息内容 |
211
253
  | 超限时的继续文本 | `继续` | 达到输出 token 上限时自动发送的文本(支持相同占位符) |
254
+ | 续跑无输出回合 | 开 | 回合正常结束但只有推理(没有文本、没有工具调用)时自动续跑; 不清零连续次数 |
255
+ | 无输出回合的继续文本 | `继续。你上一轮只输出了内部推理, ...` | 续跑无输出回合时发送的文本(支持相同占位符) |
256
+ | 自主循环(每个回合后都续跑) | 关 | 每个正常完成的回合都自动续跑,直到手动停止;成功的续跑不计入连续上限(无可见输出的回合计入) |
257
+ | 自主循环的继续文本 | `继续` | 自主循环续跑时发送的文本(支持相同占位符) |
212
258
  | 幂等护栏 | 开 | 续跑前检查上一步工具调用并给出指引(见「它做什么」) |
213
259
  | 循环守卫 | 开 | 检测运行中的回合空转并重启(见「它做什么」) |
214
260
  | 短句长度上限 (字符) | `40` | 模型消息文本短于该值计为一条短句(空转信号) |
@@ -221,11 +267,11 @@ auto-continue:
221
267
  | 工具已成功时的护栏文本 | `(上一步工具「{tool}」已完成, 结果: {result}; 不要重复执行, 直接继续)` | 上一步工具已确认成功时附加; 支持 {tool} / {result} 占位符 |
222
268
  | 宽限期 (ms) | `3000` | 中断后等待的时长; 期间宿主自行恢复则取消 |
223
269
  | 冷却时间 (ms) | `20000` | 同一会话两次自动「继续」的最小间隔(失败尝试也计入) |
224
- | 最大连续次数 | `3` | 同一会话连续自动「继续」上限; 超过后停止, 直到用户介入或成功回合 |
225
- | 启动/重连扫描 | 开 | 页面启动 / 重连时扫描最近中断的会话 |
226
- | 扫描会话数 | `8` | 扫描最多检查的会话数(不含运行中 / 子代理会话) |
227
- | 扫描时间窗 (ms) | `900000` | 扫描只处理该时间窗内的中断 |
228
- | 详细日志 | 开 | 控制台输出 `[auto-continue]` 日志 |
270
+ | 最大连续次数 | `3` | 同一会话连续自动「继续」上限; 超过后停止, 直到用户介入或出现有可见输出的成功回合 |
271
+ | 启动恢复扫描 | 开 | 恢复启动时间窗内延迟加载的中断会话 |
272
+ | 扫描会话数 | `8` | 每轮最多恢复的符合条件的会话数,优先最近活动的会话 |
273
+ | 扫描时间窗 (ms) | `900000` | 中断的最大年龄,同时限制启动轮询的持续时间 |
274
+ | 详细日志 | 开 | 在运行 DSH 的终端输出 `[auto-continue]` 引擎日志 |
229
275
  | 错误分类 | 开 | 仅自动恢复临时性错误; 认证 / 余额 / 模型等永久性错误跳过并通知 |
230
276
  | 自定义可恢复错误 | 空 | 每行一个大小写不敏感的普通文本片段; 命中错误码、HTTP 状态或消息时显式覆盖内置分类 |
231
277
  | 退避系数 | `2` | 连续失败时冷却间隔的倍率(2 = 20s → 40s → 80s…) |
@@ -235,30 +281,34 @@ auto-continue:
235
281
  遇到确认可以安全续跑的 provider 专属错误时(先确认手动发送「继续」确实能恢复), 应添加足够具体、稳定的片段, 而不是全局关闭错误分类:
236
282
 
237
283
  ```yaml
238
- auto-continue:
239
- retryableErrorPatterns: |-
240
- Upstream rejected the request as invalid
284
+ - id: auto-continue
285
+ config:
286
+ retryableErrorPatterns: |-
287
+ Upstream rejected the request as invalid
241
288
  ```
242
289
 
243
290
  匹配项是普通子串, 不是正则表达式。空行会被忽略; 任一行命中后会优先于内置永久错误规则。冷却与最大连续次数仍然生效。
244
291
 
245
- `continueText`(以及 `continueTextMaxTokens`)支持占位符 `{code}`、`{message}`、`{status}`、`{tool}`(失败前最后一次工具调用)、`{turn}`、`{errorCount}`(连续失败次数, 含本次)、`{sessionTitle}`(来自会话列表)和 `{elapsed}`(距失败经过的时间, 如 `1m5s`)——例如 `继续 ({tool}: {code})` 会变成 `继续 (git push: UPSTREAM)`。护栏文本支持 `{tool}` 与 `{result}`(上一步工具输出的截断摘要)。
292
+ `continueText`(以及 `continueTextMaxTokens`、`continueTextSilent`)支持占位符 `{code}`、`{message}`、`{status}`、`{tool}`(失败前最后一次工具调用)、`{turn}`、`{errorCount}`(连续失败次数, 含本次)、`{sessionTitle}`(来自会话列表)和 `{elapsed}`(距失败经过的时间, 如 `1m5s`)——例如 `继续 ({tool}: {code})` 会变成 `继续 (git push: UPSTREAM)`。护栏文本支持 `{tool}` 与 `{result}`(上一步工具输出的截断摘要)。
246
293
 
247
294
  ---
248
295
 
249
296
  ## 隐私与权限
250
297
 
251
- 插件是纯浏览器端, **不触碰任何文件、凭据, 也不访问 dsh 宿主以外的网络**:
298
+ 恢复引擎运行在 DSH 宿主进程中, 浏览器负责配置卡片、实时状态和可选通知:
252
299
 
253
- - 只复用 webui 本身就在用的两条只读事件流(无额外服务、无第三方端点)
254
- - 引擎**唯一会自动执行的写入**是 `sessions.prompt`——与点「发送」按钮完全相同的调用, 内容为你配置的文本(设置卡片里保存配置会通过常规设置 API 写入 `~/.dsh/settings.yaml` 的 `auto-continue` 段落, 与任何其他设置一样)
255
- - 不使用任何浏览器存储: 宿主侧单实例引擎的冷却、发送上限、暂停与统计全部保存在进程内存里
300
+ - 引擎通过 DSH 服务读取会话事件和历史, 浏览器与该宿主通信; 插件不新增第三方服务或凭据存储
301
+ - 恢复时通过 `agent.followup` 发送你配置的文本。循环守卫可先通过 `agent.cancel` 停止空转回合, 再发送恢复提示; 续跑的 Agent 沿用会话已有的工具和权限
302
+ - 保存配置使用 DSH 的设置 API: DSH 0.1.7 写入当前 profile patch, 旧版宿主写入 `~/.dsh/settings.yaml`
303
+ - 冷却、发送上限、暂停与统计保存在宿主进程内存中, 引擎重启后重置
256
304
  - 浏览器通知是可选开启的(`notify` 设置), 仅在首次使用时请求一次权限
257
305
 
258
306
  ---
259
307
 
260
308
  ## 开发
261
309
 
310
+ CI 会使用已发布的 DSH 0.1.7 组件,通过真实 Loader 检查 HTTP 桥与设置的实时读写。先运行一次 `npm ci --prefix tests/fixtures/dsh-0.1.7`,构建后运行 `npm run test:runtime`。
311
+
262
312
  ```bash
263
313
  npm run typecheck # tsc --noEmit
264
314
  npm run build # lib/client.js + lib/index.js + lib/types
Binary file
@@ -0,0 +1,35 @@
1
+ # Configuration screenshots
2
+
3
+ Captured on 2026-09-28 using **DSH 0.1.7-rc.2** and
4
+ **dsh-client-auto-continue 0.11.9** in Chromium, with DSH's dark theme.
5
+ These are screenshots of the running application in an isolated `DSH_HOME`
6
+ with no user sessions or API keys.
7
+
8
+ | View | English | Chinese | Viewport |
9
+ | --- | --- | --- | --- |
10
+ | Plugins → dsh-client-auto-continue, collapsed card | [01-settings-section.png](01-settings-section.png) | [01-settings-section.zh.png](01-settings-section.zh.png) | 1440 × 760 |
11
+ | Expanded card and recovery prompts | [02-settings-card.png](02-settings-card.png) | [02-settings-card.zh.png](02-settings-card.zh.png) | 1440 × 1100 |
12
+ | Live status and Save / Discard controls | [07-card-panels.png](07-card-panels.png) | [07-card-panels.zh.png](07-card-panels.zh.png) | 1440 × 950 |
13
+
14
+ To refresh them with that DSH version, create an empty DSH home and install
15
+ the released plugin:
16
+
17
+ ```bash
18
+ capture_home="$(mktemp -d)"
19
+ DSH_HOME="$capture_home" dsh plugin --profile web add dsh-client-auto-continue@0.11.9
20
+ DSH_HOME="$capture_home" dsh web --no-open
21
+ ```
22
+
23
+ Open the authenticated URL printed by DSH without including that URL in any
24
+ screenshot. Dismiss onboarding, select the dark theme, and navigate from the
25
+ main sidebar's **Plugins** button.
26
+
27
+ Capture the collapsed card, expand it for the top-of-page view, then scroll to
28
+ its Save / Discard footer for the final view. Switch **Settings → General →
29
+ Language** to Chinese and repeat. Use device scale factor 1 and the viewports
30
+ above; keep the UI content unchanged.
31
+
32
+ Before capture, verify that a text change and a numeric change both persist
33
+ after Save and a browser reload, then reset those overrides. Wait for the
34
+ profile writes to finish before checking the saved file. Keep the form at its
35
+ defaults and record the host/plugin versions when updating these images.