@xmoon76/dsh-pi-tui 0.5.2-rc.1 → 0.5.4

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.
Files changed (39) hide show
  1. package/README.en.md +200 -124
  2. package/README.md +132 -90
  3. package/cordis.patch.yml +54 -50
  4. package/dist/builtins.mjs +2 -2
  5. package/dist/client-bootstrap-F5DHFI9t.mjs +5576 -0
  6. package/dist/context-summary-DAisTA_7.mjs +8557 -0
  7. package/dist/dispose-cause-CNFuUnjR.mjs +24 -0
  8. package/dist/entry-control-DvSrndWd.mjs +111 -0
  9. package/dist/extension/advanced.d.mts +1 -1
  10. package/dist/extension/unstable.d.mts +1 -1
  11. package/dist/{extensions-DzpBiiYb.d.mts → extensions-Bte3XOt5.d.mts} +1 -1
  12. package/dist/{extensions-VuoIE_Jc.mjs → extensions-CcuMY4n2.mjs} +722 -324
  13. package/dist/extensions.d.mts +2 -2
  14. package/dist/extensions.mjs +1 -1
  15. package/dist/host-bootstrap-DAgKknbY.mjs +119 -0
  16. package/dist/index.d.mts +10 -10
  17. package/dist/index.mjs +52682 -30024
  18. package/dist/local-client.mjs +323 -0
  19. package/dist/local-host.mjs +176 -0
  20. package/dist/{performance-host-BJT6scGF.mjs → performance-host-CcDJjjVA.mjs} +1 -1
  21. package/dist/performance-host.mjs +1 -1
  22. package/dist/{performance-view-jvvd8Jn7.mjs → performance-view-CfGvLZyD.mjs} +1 -1
  23. package/dist/{public-types-gZi3iFNh.d.mts → public-types-Dgf1bDke.d.mts} +3 -3
  24. package/dist/runtime-status-0lp9CM0V.mjs +1923 -0
  25. package/dist/{runtime-Dq6HoyjZ.mjs → runtime-vc4mdr-R.mjs} +1907 -1276
  26. package/dist/{session-DTauqYx6.mjs → session-tdJHLnJR.mjs} +3420 -339
  27. package/dist/{startup-CWQl0-0n.mjs → startup-JaVZoTIl.mjs} +69 -13
  28. package/dist/startup.d.mts +2 -2
  29. package/dist/startup.mjs +1 -1
  30. package/dist/{terminal-progress-source-Dpwz3csm.mjs → terminal-progress-source-xor3vakJ.mjs} +172 -49
  31. package/dist/visual-tools.d.mts +62 -0
  32. package/dist/visual-tools.mjs +556 -0
  33. package/generated/dsh-presets/README.md +1 -1
  34. package/generated/dsh-presets/cordis.patch.yml +8 -26
  35. package/generated/dsh-presets/minimal.patch.yml +17 -0
  36. package/generated/dsh-presets/ptc.patch.yml +8 -26
  37. package/generated/dsh-presets/standard.patch.yml +8 -26
  38. package/package.json +184 -154
  39. package/dist/context-summary-CxQnkDEN.mjs +0 -2478
package/README.en.md CHANGED
@@ -35,6 +35,16 @@ dsh plugin --profile pi-tui -- add @xmoon76/dsh-pi-tui@next
35
35
  dsh --profile pi-tui
36
36
  ```
37
37
 
38
+ > **Those two channels are not an installable compatible pair today.** They are
39
+ > channel pointers only: `@deepseek-ai/dsh@alpha` currently resolves to
40
+ > `0.2.1-alpha.5`, while `@xmoon76/dsh-pi-tui@next` still resolves to
41
+ > `0.5.2-rc.1` (peer floor `>=0.2.0-rc.2`, and npm semver excludes a
42
+ > different-major.minor.patch prerelease). Use the pairing table below and
43
+ > [compatibility guide](docs/guides/dsh-compatibility.md) for the matching rules; the
44
+ > stable `0.5.4` publishes to `@latest`, not `@next`, so no installable compatible
45
+ > combination exists on those two moving channels. Validate this exact checkout
46
+ > with `pnpm compat:dsh:npm`.
47
+
38
48
  Use the isolated npm driver (it installs the exact DSH version declared by this
39
49
  checkout and exercises the full build/test/package path):
40
50
 
@@ -42,7 +52,7 @@ checkout and exercises the full build/test/package path):
42
52
  pnpm compat:dsh:npm
43
53
  ```
44
54
 
45
- See the [compatibility guide](docs/dsh-compatibility.md) for the stable minimum,
55
+ See the [compatibility guide](docs/guides/dsh-compatibility.md) for the stable minimum,
46
56
  next compatibility range, and fallback paths.
47
57
 
48
58
  ### Requirements
@@ -54,27 +64,36 @@ next compatibility range, and fallback paths.
54
64
 
55
65
  | TUI package line | Official DSH tags for the pairing | Notes |
56
66
  |---|---|---|
57
- | `0.5.1` (stable / `@latest`) | `dsh-v0.2.0-rc.2` | Current stable line; both the minimum and the exact validation target are the 0.2.0-rc.2 family |
58
- | `0.5.2-rc.1` (next preview / `@next`) | `dsh-v0.2.0-rc.2` | Current next-line preview; the DSH baseline is identical to `0.5.1` (the 0.2.0-rc.2 family is both the minimum and the exact validation target) |
67
+ | `0.5.4` (stable / `@latest`) | `dsh-v0.2.1-rc.2`, `dsh-v0.2.1-rc.3`, `dsh-v0.2.1-rc.4` | Current stable line; the minimum DSH version is 0.2.1-rc.2, and this checkout's exact validation target is 0.2.1-rc.4 |
68
+ | `0.5.3` (stable, previous) | `dsh-v0.2.1-rc.2`, `dsh-v0.2.1-rc.3`, `dsh-v0.2.1-rc.4` | Previous stable line; the minimum DSH version is 0.2.1-rc.2, and it passes the official preset assembly on all three DSH versions |
69
+ | `0.5.1` (stable, previous) | `dsh-v0.2.0-rc.2` | Previous stable line; both the minimum and the exact validation target are the 0.2.0-rc.2 family |
70
+ | `0.5.2-rc.1` (published next-channel preview) | `dsh-v0.2.0-rc.2` | Previous next preview: published to the npm `next` dist-tag on 2026-10-17; its whole peer floor stays `>=0.2.0-rc.2`, so it does not cover 0.2.1-rc.2 |
71
+ | `dsh-v0.2.1-rc.1` (no paired TUI) | none | No released TUI in this matrix claims that intermediate release; never reuse `0.5.4` for it |
59
72
  | `0.5.0` (stable, previous) | `dsh-v0.1.7-rc.2`, `dsh-v0.2.0-rc.1` | Previous stable; 0.1.7-rc.2 minimum, exact validation target 0.2.0-rc.1 |
60
73
  | `0.4.9` (stable, previous) | `dsh-v0.1.7-rc.2` | Previous stable; the compatible TUI for a 0.1.7-rc.2 runtime |
61
74
  | `0.4.8` (stable, previous) | `dsh-v0.1.7-rc.1` | Previous stable; the compatible TUI for a 0.1.7-rc.1 runtime |
62
75
  | `0.4.6` (stable, previous) | `dsh-v0.1.5-rc.1`, `dsh-v0.1.5-rc.2` | Previous stable; the compatible TUI for a 0.1.5 runtime |
63
76
  | `0.4.7-alpha.2` (next, previous) | `dsh-v0.1.6-alpha.2` | Previous next line; the compatible TUI for a 0.1.6-alpha.2 runtime |
64
77
 
65
- Do not mix the stable and `@next` prerelease lines. `@next` currently resolves to
66
- the `0.5.2-rc.1` preview, whose DSH baseline is identical to `0.5.1`. `0.5.1` lifts the whole DSH
67
- peer floor to `>=0.2.0-rc.2`: the Question lifecycle
68
- consumes contracts published only in rc.2 (the `userQuestions.attachWait`/
69
- `answer` Remotes and the `userQuestions` Session projection), so mixing in the
70
- rc.1 family would be a false compatibility statement. The previous stable `0.5.0`
78
+ Do not mix the stable and `@next` prerelease lines. `0.5.4` is the current
79
+ stable release: its minimum DSH version (peer floor) stays the `0.2.1-rc.2`
80
+ family, and this checkout's exact validation target is `0.2.1-rc.4`. The
81
+ published `0.5.3` is the previous stable line and also pairs with `0.2.1-rc.2`,
82
+ `0.2.1-rc.3` and `0.2.1-rc.4`. The intermediate
83
+ `dsh-v0.2.1-rc.1` has no paired TUI, and `0.5.2-rc.1` is the previous preview
84
+ published to the npm `next` channel (its pairing, 0.2.0-rc.2, stays in the table
85
+ above; it does not cover 0.2.1-rc.2). The previous stable
86
+ `0.5.1` keeps pairing with 0.2.0-rc.2: it lifts the whole DSH peer floor to
87
+ `>=0.2.0-rc.2` (the Question lifecycle consumes contracts published only in
88
+ that rc.2 family). The previous stable `0.5.0`
71
89
  line keeps its `>=0.1.7-rc.2` floor (exact validation target 0.2.0-rc.1);
72
90
  older runtimes fail at the normal
73
91
  incompatible-runtime boundary, so install the paired TUI line from the table
74
92
  above. The startup notice
75
- is best-effort rather than a Loader startup-order guarantee. See the [full
76
- historical compatibility matrix](docs/dsh-compatibility.md) for official-tag
77
- pairings and fallback commands, and see the [latest `next`
93
+ is best-effort rather than a Loader startup-order guarantee. The pairing table
94
+ above is the published-line summary; see the [compatibility
95
+ guide](docs/guides/dsh-compatibility.md) for general matching, fallback and
96
+ diagnosis, and the [latest `next`
78
97
  README](https://github.com/XMoon/dsh-pi-tui/blob/next/README.md) for the current
79
98
  integration status.
80
99
 
@@ -122,7 +141,12 @@ dsh --profile pi-tui --session <session-id>
122
141
  * Full-text Transcript search
123
142
  * Folding for long Session history
124
143
  * Context, token, model, and runtime status
144
+ * Full-screen Settings workspace: About status, Models / Account, Agent and dynamic Extensions
125
145
  * Approval and `ask_user_question` dialogs
146
+ * Images: terminal-capability admission, JPEG/WebP previews, draft images and a read-only viewer
147
+ * Chart/SVG tools, `present_visual` publication and inline final-answer rendering
148
+ * Delivered-files tail and the `/deliverables` browser
149
+ * Experimental TSP renderer: native tool cards, Work Hub, images and published figures
126
150
  * Plan Review
127
151
  * Todo / Goal status
128
152
  * Human-readable terminal window titles
@@ -132,6 +156,8 @@ dsh --profile pi-tui --session <session-id>
132
156
 
133
157
  `Ctrl+O` controls Tool and System details and expands/collapses long user prompts in regular mode and in fullscreen outside Focus — in fullscreen Focus it bulk-expands the recent Thought roots or collapses them all, while long user prompts are expanded by clicking the marker (or by a search hit) and collapsed with `Ctrl+O`. `Alt+T` controls Thinking separately.
134
158
 
159
+ Tool approvals appear in the editor seat: the full Reason/Arguments body is readable in a scrollable area (no six-line preview), with `y` to allow once, `n` to reject, `Esc`/`Ctrl+C` to cancel, `c` to copy the raw arguments and `e` to expand. Fullscreen can click the actually painted Allow once / Reject / Cancel actions and wheel the body; regular mode stays keyboard-only. Short viewports show the real compact payload or `Resize to inspect more`, never a cropped decision.
160
+
135
161
  ### Conversation display
136
162
 
137
163
  `/display` switches between three presentation presets: `full` (default) is the normal Transcript projection; `focus` groups the current turn's Thinking, Tool Calls, and intermediate replies into a live Thought block; `compact` folds contiguous process into `Activity` spans with Header + `Think:` / `Action:` previews, keeps the session and assistant intermediate output visible in chronological order, renders injected notice / relay / recall entries separately (adjacent environment injections merge into an expandable Context cluster), and expands with a mouse click or `Ctrl+O`. The `Display` row in `/settings` offers the same values and persists the choice; `/focus` remains available as a compatibility command.
@@ -207,11 +233,45 @@ Transcript's tool card. Explicit `run_in_background: true` jobs (and jobs
207
233
  promoted to the background after a foreground timeout) remain visible in
208
234
  `TRACKED` after completion as long as the Job Registry keeps their record.
209
235
 
210
- `/plugins` opens the active profile's Plugin Manager: installed bundles and
211
- plugins are grouped into Current TUI / TUI Extensions / DSH Plugins, with
212
- enable/disable, remove and install; the `dsh-pi-tui` bundle currently providing
213
- the surface is read-only and cannot be disabled or removed from its own screen.
214
- The `Plugins Manage…` row in `/settings` opens the same surface on demand.
236
+ `/plugins` is a deep link into `/settings → Plugins`: both take the SAME
237
+ Settings fullscreen lease and the SAME Plugin Manager page — there is no
238
+ separate plugin screen and no Session create/switch. The catalog is grouped as
239
+ TUI & Extensions / Official DSH / Third-party / Experimental (the Experimental
240
+ group is always last). At >=120 columns, and only while the frame can grant six
241
+ real business-body rows, the frame shows
242
+ `Categories | Plugin List | Details`; a shorter frame degrades to the pair or one
243
+ column instead of squeezing the body. At 76-119 columns it shows
244
+ `Categories | List` or `List | Details` depending on the keyboard owner — the pair
245
+ again needs six real business-body rows, otherwise it degrades to one column; below
246
+ 76 columns it is one column. Install, dangerous confirmations and Diagnostics
247
+ always take the full width so risk text is never squeezed. Settings paints the
248
+ shared header/metadata/rule/pane header and the single last-row action bar; the
249
+ plugin page contributes only its business body. Search, status filters,
250
+ provenance/status facts, official catalog installs, enablement and removal are
251
+ available from the page; the actual Host-reported version, restart requirement
252
+ and errors are shown verbatim. The `dsh-pi-tui` bundle currently providing the
253
+ surface is read-only and cannot be disabled or removed from its own screen. The
254
+ category preview and `/plugins` share one page instance and one background
255
+ install request: `Esc` from the List returns to the Settings category and a
256
+ second `Esc` closes the workspace. Press `d` inside the page
257
+ for the read-only **Diagnostics** view: extension contribution health grouped by
258
+ owner (`active/failed/shadowed` with the full `lastError`), live registry counts,
259
+ the actual advertised capabilities, and contributions with no proven Loader-entry
260
+ owner under `Unassociated extension contributions`. `c` copies the selected fact,
261
+ `C` copies everything, `r` rereads and Esc returns. Diagnostics reads only the
262
+ extension ledger; Host package state and install logs stay out of it. `copy`
263
+ still proves emission only, never an OS-clipboard receipt.
264
+
265
+ The 14 official rc.2 Experimental bundles carry a bounded, identity-exact
266
+ Detail statement of their terminal surface and limits/risks (Web-only,
267
+ Host-only, the B04 WEB_ONLY/Host-row-pending boundary accepted by the Owner,
268
+ and the B13/B14 verified one-shot/provider boundaries). That copy never follows
269
+ enablement and never claims a live Host capability PASS. Upgrade guidance is
270
+ derived from Host facts only: shipped bundles upgrade with the DSH installation,
271
+ profile-owned bundles require Remove followed by an explicit later install,
272
+ missing entries use the official on-demand target, and the Current TUI bundle
273
+ is managed outside the screen. There is no in-place update, version picker or
274
+ silent reinstall.
215
275
 
216
276
  Subagents are shown using their complete lineage, including nested descendants:
217
277
 
@@ -254,6 +314,24 @@ provider/model per call (bounded by the allowlist). The setting is sampled at
254
314
  session composition and never rewrites the tools of an already-running
255
315
  session.
256
316
 
317
+ ### Delivered files and `/deliverables`
318
+
319
+ A final answer's `present` files render as a compact tail: at most four files,
320
+ two rows each (path relative to the current display subject's workspace plus
321
+ description), with `+N more · /deliverables` beyond four. On a fullscreen
322
+ AltScreen, Full, Compact and Focus can click `Browse all` and per-file
323
+ `Details`; a regular split keeps only the command entry.
324
+
325
+ `/deliverables` opens the delivery panel for the currently displayed session
326
+ (including a viewed child) with Files / Turns / Details: `↑↓` selects, `Enter`
327
+ opens details, `/` filters by filename, full Host path and description, `T`
328
+ switches among Turns with deliveries, `C` copies the raw Host path and `Esc`
329
+ goes back or closes. `Enter Preview` on Details reads one 120-line page of UTF-8
330
+ Host text; binary/document suffixes show that preview is unavailable without
331
+ reading bytes; a file that changes between pages restarts from the beginning.
332
+ Panel text is mouse-selectable, the panel is centered, and a terminal resize
333
+ keeps the current page, filter, cursor and scroll position.
334
+
257
335
  ### Shell
258
336
 
259
337
  The editor supports two Shell modes:
@@ -330,6 +408,9 @@ Common entry points:
330
408
  ```text
331
409
  /model
332
410
  /settings
411
+ /status
412
+ /deliverables
413
+ /view-image
333
414
  /login
334
415
  /permission
335
416
  /plan
@@ -339,96 +420,74 @@ Common entry points:
339
420
  /statusline
340
421
  ```
341
422
 
342
- Model selection, Reasoning Effort, permission presets, Plan, and Goal all keep the corresponding DSH runtime semantics.
343
-
344
- `/settings` opens a real full-screen workspace where the three-, two- and
345
- single-column layouts are projections of the SAME `categories → rows → detail`
346
- levels: wide terminals show all three columns, medium ones show
347
- `categories + rows` or `rows + details` for the current level, and narrow ones
348
- show only the current level. At every width ASCII `Right` advances exactly one
349
- level and `Left` returns one level (inert at L0); `Enter` follows the same
350
- transitions, and `Esc`/`Backspace` step back, closing at the outermost level.
351
- `Tab`/`Shift+Tab` remain inert. The Action Bar stays pinned to the last physical
352
- row. Multi-column choosing retains the active `[Details]` marker unless that
353
- heading would consume the only content row. It presents the real Appearance /
354
- Display facts: the theme's source-qualified raw value plus its friendly name,
355
- Icon style, the live Transcript display preset alongside the persisted preference,
356
- the live Thinking detail state, and each row's configuration Scope and backend
357
- readiness. `R`
358
- re-reads and `C` copies the selected row's exact source value. Browsing, choosing
359
- and copying alone never write configuration.
360
-
361
- The **`Configured theme` and `Transcript display` rows are directly editable**:
362
- from L1, `Right` or `Enter`, the painted `[Change…]` button, or ordinary visible
363
- Detail content opens the candidate choice in the SAME L2 pane. Current-value and
364
- Runtime/Persisted facts stay in the same pane above the candidate region and scroll
365
- independently. `Up`/`Down`/`Home`/`End` move the candidate; `PgUp`/`PgDn` and the
366
- wheel over facts scroll only the fact region, while the candidate wheel scrolls
367
- independently. During choice, `C` copies the original row value only while the
368
- Action Bar paints `c copy`; it never copies or commits the draft candidate. `Enter`
369
- or `[Confirm]` confirms explicitly, and `Left`/`Esc`/`Backspace` or `[Cancel]`
370
- cancels directly to L1 without writing anything. If the selected candidate identity
371
- has scrolled out of view, the first Enter only reveals it; confirmation requires a
372
- later Enter. From L2 browse or a settled outcome, Enter reopens choice for a
373
- writable non-pending row. At 44×8, a long identity may first reclaim the optional
374
- `Choose value` heading; if still needed, the fact area shrinks only to one original
375
- `Value` row. The complete identity, `Confirm` and `Enter confirm` must be visible
376
- before a write.
377
- An identity beyond the remaining candidate capacity stays unconfirmable. Only
378
- buttons and candidates that are really painted can be clicked. A confirmed change is stored through the existing
379
- serialized whole-document write path and then re-read from the authority: the
380
- detail names the live runtime fact (`Runtime`, e.g. the current palette) and the
381
- stored preference (`Persisted`) separately and states `Saving…`, `Verified`,
382
- `Not saved · <reason>`, `Commit accepted · verification unavailable` or
383
- `Outcome unknown · <reason>` — only a completed write whose authoritative
384
- re-read agrees is called Verified; a rejected write re-reads the authority first
385
- and reports Not saved only while it still carries the value the request started
386
- from; a third value, a value already in place or an unreadable authority is
387
- Outcome unknown, and a success whose readable readback disagrees is a failure
388
- rather than "verification unavailable". On a non-ready backend the theme is
389
- neither applied nor written; a display preset may already be live locally and
390
- then says that it was not stored instead of pretending it was. A plugin theme is
391
- resolved again by its source-qualified identity at confirm time, so an unloaded
392
- plugin theme is listed as unavailable and refused rather than degrading into a
393
- same-named file theme. Icon style and Thinking detail stay read-only rows. The
394
- existing complete settings editor is still available: `Other settings` → `Open
395
- existing settings…` retires the workspace and restores the surface it paused
396
- before opening the original editor, so Theme, the Plugin Manager, keybindings,
397
- permissions and extension settings keep every existing write path.
398
-
399
- The `Icon style` option in `/settings` switches the TUI's structural icons:
400
- `Emoji` (default, colorful), `Symbols` (compact single-cell terminal
401
- symbols), or `Minimal` (decorative icons hidden; only status/interaction
402
- markers remain). Switching applies immediately and persists.
403
-
404
- The `Terminal progress` row in `/settings` selects the native terminal status
405
- reporting in four modes: `9;4+7501` (default — both the OSC 9;4 progress bar and
406
- the OSC 7501 semantic state), `9;4` (progress-bar compatibility only), `7501`
407
- (semantic state only: working, waiting for approval/answer, done, error) and
408
- `Off` (clear and stop reporting). Switching applies immediately; done and error
409
- are reported only once a real run's last turn result is proven, while a
410
- cancelled or interrupted run returns to idle. A persisted `On` reads as the
411
- dual-protocol default.
412
-
413
- Terminal compatibility: a terminal that does not know OSC 7501 simply ignores
414
- it — Ghostty's GUI currently shows the OSC 9;4 progress bar and not the 7501
415
- semantic state, which is expected and not a reporting failure. Inside tmux and
416
- other terminal multiplexers an unknown OSC may not be forwarded to the outer
417
- terminal (this feature deliberately implements no tmux DCS passthrough and does
418
- not change multiplexer settings); use an outer terminal that supports it when
419
- the state must survive a multiplexer. The OSC 7501 semantic state describes the
420
- current Main Agent only.
421
-
422
- This project's own Remote composition (experimental, our Host) reports the same
423
- state: the Host side is served by this extension's private Host status stream and
424
- shares ONE interval classifier with Direct. **A third-party DSH Host without this
425
- extension's Host plugin is not supported** (it has no equivalent event source).
426
-
427
- Slash Commands registered by other plugins through `ctx.commands` are discovered automatically.
423
+ Model selection, Reasoning Effort, permission presets, Plan, and Goal all keep the corresponding DSH runtime semantics. `/model` candidates come only from the Host catalog: `deepseek-flash` is identified by the exact `(provider, model)` pair (the display name `DeepSeek-V4.1-Flash` is never the ID), and a selection writes the official Session/global default. A deployment catalog that no longer offers the ID shows no invented row.
424
+
425
+ `/settings` and `/status` open the same full-screen settings workspace on the
426
+ About home. Wide and medium terminals show a category rail plus the content
427
+ column; narrow terminals (under 76 columns) show About directly. The fixed
428
+ categories are About / Models / Account / Agent / Appearance / Conversation /
429
+ Input & Terminal / Tools / Plugins, with Extensions appended only while the
430
+ extension settings registry has rows. `Tab`/`Shift+Tab` move focus between
431
+ regions, `Right`/`Enter` go one level deeper, `Left`/`Esc`/`Backspace` step
432
+ back, and the outermost back closes the workspace; the Action Bar stays on the
433
+ last row.
434
+
435
+ About shows the TUI/DSH versions, backend, captured session identity,
436
+ whole-session statistics, TTFB/throughput and Context occupancy; `c` copies the
437
+ selected fact's raw value, `C` copies the full report and `r` refreshes. The old
438
+ `/status` page is gone; extension diagnostics moved to
439
+ `Settings → Plugins → Diagnostics` (`d`).
440
+
441
+ Models lists the Host provider catalog, API-key presence (not a connectivity
442
+ test), provider details, masked input and clear confirmations, the Add Provider
443
+ wizard and provider-native sign-in; the home lists only configured providers,
444
+ with unconfigured ones in the Add Provider catalog. Account shows sign-in state,
445
+ the browser authorization URL, SSH tunnel guidance, independent wallets, exact
446
+ attempt cancellation, refresh and a confirmed sign-out. `/login` and `/logout`
447
+ open the matching page deep link. DeepSeek Account sign-in uses the official Host
448
+ `host-webserver` loopback `/oauth/callback` on `127.0.0.1:0`; the TUI never
449
+ receives a token or grant, and `--help` opens no port.
450
+
451
+ Settings edits in place: Appearance (Icon style, Status line mode), Conversation
452
+ (Transcript detail, Thinking detail, Progress updates, Response style, Submit
453
+ while busy, Git attribution), Input & Terminal (Home/End keys, Fullscreen, wheel
454
+ lines, notifications, Terminal progress, Footer layout, Keyboard shortcuts),
455
+ Agent (approval policy, default permission, subagent model allowlist/selection,
456
+ user shell sandbox), Tools (Web Search / Fetch, Visual tools) and Extensions
457
+ (dynamic settings grouped by plugin). Every write needs explicit confirmation
458
+ and reports `Verified` / `Not saved` / `Outcome unknown` from the authoritative
459
+ read-back; `Fullscreen` applies after Settings closes normally. `/footer`,
460
+ `/statusline`, bare `/keybindings` and `/plugins` are deep links into the same
461
+ workspace; the legacy main settings editor and standalone plugin screen are
462
+ gone.
463
+
464
+ The **Visual tools** switch under `Settings → Tools` (default On) is the
465
+ profile-wide `pi-tui-visual-tools.enabled` and controls `dsh_pi_tui_chart`,
466
+ `dsh_pi_tui_svg` and `present_visual` together. After it is turned off, new
467
+ model requests no longer see the three tools, while historical results remain
468
+ displayable, copyable, searchable and exportable. Direct verifies the Host
469
+ registry state before showing Verified; Remote only reports that the preference
470
+ was saved.
471
+
472
+ `Settings → Tools → Web Search / Fetch` is a page in the same workspace: search
473
+ and fetch providers, result count, `Share Original Question`, HTTPS endpoint and
474
+ a read-only API-key reference. Each value is written only by an explicit Enter
475
+ confirmation and shows the Host's authoritative read-back. The two APIs are
476
+ separately billed providers; the default Messages/HTTP pair calls no billed API.
477
+
478
+ `Extensions` groups the live registration rows by owner with `Tab`/`Shift+Tab`
479
+ cycling groups and arrows/Home/End/paging/wheel staying inside the group.
480
+ Entries open native Detail/Choice; only an explicit Confirm writes to the
481
+ running plugin, `Verified` requires a live read-back, and a same-id HMR
482
+ re-registration inherits no old state. Extension settings never write the TUI
483
+ settings document or a Host profile.
428
484
 
429
485
  ### Footer customization
430
486
 
431
- `/footer` is the interactive Footer editor. You can combine builtin status items, change their side and order, choose a Style and Tone, edit Prefix/Suffix and Importance, and create your own Footer items.
487
+ `/footer` opens the Footer editor inside the same full-screen Settings workspace
488
+ (Appearance → Configure footer layout). You can combine builtin status items,
489
+ change their side and order, choose a Style and Tone, edit Prefix/Suffix and
490
+ Importance, and create your own Footer items.
432
491
 
433
492
  Four item sources are supported:
434
493
 
@@ -443,11 +502,27 @@ A `/footer` Custom Command Item is different from `footer: command`: the former
443
502
 
444
503
  For the full `/footer` workflow, Custom Text / Command items, YAML reference, security model, and troubleshooting, see:
445
504
 
446
- - [Footer customization guide](docs/footer-customization.md)
447
- - [Extension API for plugin authors](docs/extension-api.md)
505
+ - [Footer customization guide](docs/guides/footer.md)
506
+ - [Extension API for plugin authors](docs/extensions/stable.md)
448
507
 
449
508
  `/statusline` is an alias of `/footer`.
450
509
 
510
+ ### Images
511
+
512
+ Ctrl+V reads the system clipboard: an image becomes the canonical placeholder `[image #N (WxH)]` with draft thumbnails in one row above the composer (a short window lets the client hide that row, while typing and sending still work and the status line keeps reporting the real draft count); text is inserted at the live caret. `/image` and `/attach` can also add an image or a regular file to the current draft. A placeholder that appears several times shows several positions while the bytes are read and uploaded once.
513
+
514
+ Images in user messages, assistant messages and tool results are shown inside their own card, in their original order: one identity line (name, pixel size, byte count) plus one image. The PiTUI viewer is described below; in the experimental TSP renderer, viewing and zooming are the Tern client's own affordances (moving between neighbouring images depends on the client's version and capabilities). When an image cannot be read, its format is unsupported, or it exceeds the 16 MiB single-image limit, the card states the identity and the real reason instead of drawing a fabricated image. On a native Kitty terminal, transcript thumbnails, the composer draft card and the fullscreen image viewer all first convert JPEG/WebP to a bounded PNG in the background before painting pixels (WebP uses only its first frame, EXIF orientation is applied, and the longest edge is capped at 768 pixels; the identity row and the viewer keep the original name, dimensions, media type and byte count; the draft card only derives the one last local image it is allowed to show). A collapsed occurrence never starts a conversion; while converting or after a failure only text is shown (a failure reads `Preview unavailable`), and only a body that really painted pixels is clickable. The fullscreen viewer shows that same bounded derivative rather than a full-resolution original; PNG, iTerm2, GIF, narrow and graphics-unsupported terminals keep their existing behavior.
515
+
516
+ The rightmost three cells of a fullscreen image info row are `[-]`/`[+]`, folding only that image; clicking its body opens the read-only viewer. `/view-image` lists the images of the currently mounted transcript window; `Enter` views one and `Esc back` returns to the same list.
517
+
518
+ ### TSP renderer (experimental)
519
+
520
+ Set `DSH_PI_TUI_RENDERER=tsp` to enable the experimental Tern TSP renderer:
521
+ native tool cards, Preparing rows, PTC child calls, the Work Hub
522
+ (`/tasks`, `/subagents`), image paste and historical images, and native display
523
+ with Copy for published charts/SVGs. The default renderer remains PiTui;
524
+ Settings and Plugins pages that TSP cannot host are refused explicitly.
525
+
451
526
  ## Common keys
452
527
 
453
528
  | Key | Action |
@@ -466,6 +541,9 @@ For the full `/footer` workflow, Custom Text / Command items, YAML reference, se
466
541
  | `Ctrl+End` | Jump to the latest Transcript output in fullscreen; a clickable `↓ Latest` appears after leaving the live tail |
467
542
  | `Ctrl+O` | Expand / collapse Tool and System details and long user prompts in regular/fullscreen-non-Focus; in fullscreen Focus, bulk-toggle the Thought roots (expand long user prompts by clicking the marker) |
468
543
  | `Alt+T` | Expand / collapse Thinking |
544
+ | `Alt+V` | Select / cycle the current window's published charts or SVGs |
545
+ | `Alt+C` | Copy the selected chart / SVG |
546
+ | `Alt+O` | Open the selected SVG |
469
547
  | `Ctrl+G` | Edit current input in `$VISUAL`/`$EDITOR` |
470
548
  | `Ctrl+V` | Paste image |
471
549
  | `Tab` | Autocomplete slash commands and file paths |
@@ -523,8 +601,9 @@ keybindings:
523
601
  action-first, editable Keyboard Shortcuts Editor: it groups actions by
524
602
  category, searches action IDs/descriptions/current keys/default keys, and
525
603
  marks customized, conflict, Unbound, Disabled, and fixed states. A standalone Leader key row also configures the global leader key.
526
- - `/settings` has one `Keyboard shortcuts` launcher that opens the same editor
527
- and persistence controller as `/keybindings`.
604
+ - `/settings` has one `Keyboard shortcuts…` entry that opens the same-lease
605
+ full-screen page and the same persistence controller as bare `/keybindings`
606
+ (no 88-column overlay).
528
607
  - The recorder reads a real terminal key, parses it with `parseKey`, and stores
529
608
  the canonical `KeyId`; known dead, typing-swallowing, terminal-ambiguous, and
530
609
  conflicting shortcuts are rejected before saving. Ordinary recording cancels
@@ -677,12 +756,11 @@ export function apply(ctx: Context): void {
677
756
 
678
757
  Documentation:
679
758
 
680
- * [Extension API](docs/extension-api.md)
681
- * [Extension tiers](docs/extension-tiers.md)
682
- * [Advanced API](docs/extension-advanced.md)
683
- * [Unstable API](docs/extension-unstable.md)
684
- * [Plugin authoring](docs/plugin-authoring.md)
685
- * [Capability matrix](docs/extension-capability-matrix.md)
759
+ * [Extension API](docs/extensions/stable.md)
760
+ * [Extension tiers](docs/extensions/tiers.md)
761
+ * [Advanced API](docs/extensions/advanced.md)
762
+ * [Unstable API](docs/extensions/unstable.md)
763
+ * [Plugin authoring](docs/extensions/authoring.md)
686
764
 
687
765
  ## Development
688
766
 
@@ -740,7 +818,7 @@ The published package already contains the Pi TUI fork required at runtime. No s
740
818
 
741
819
  ### CI validation policy
742
820
 
743
- CI follows the tracked `test/compat/dsh-mode.json` policy for pushes to `next` and pull requests targeting `next`; `main` and every tag use npm Mode. Source Mode reads the source target from `test/compat/dsh-source.json` and validates the complete official DSH tarball family, TUI presets, and the old-runtime boundary; npm Mode uses the DSH version declared by the checkout's `package.json` and frozen lockfile to run the registry lane. The published `pi2dsh` ecosystem check is explicitly marked skipped for an unpublished source family. See [`docs/dsh-compatibility.md`](docs/dsh-compatibility.md) for the full workflow.
821
+ CI follows the tracked `test/compat/dsh-mode.json` policy for pushes to `next` and pull requests targeting `next`; `main` and every tag use npm Mode. Source Mode reads the source target from `test/compat/dsh-source.json` and validates the complete official DSH tarball family, TUI presets, and the old-runtime boundary; npm Mode uses the DSH version declared by the checkout's `package.json` and frozen lockfile to run the registry lane. The published `pi2dsh` ecosystem check runs in both modes and always targets the published ecosystem (it installs the published DSH and pi2dsh from the registry), so a source pack is explicitly skipped rather than passed. See [`docs/guides/dsh-compatibility.md`](docs/guides/dsh-compatibility.md) for the compatibility method.
744
822
 
745
823
  ## Repository layout
746
824
 
@@ -767,15 +845,13 @@ Contributor-oriented repository structure and development rules are documented i
767
845
 
768
846
  | Document | Content |
769
847
  | ------------------------------------------------------ | --------------------------------- |
770
- | [docs/README.md](docs/README.md) | Documentation index |
771
- | [docs/architecture.md](docs/architecture.md) | Architecture and module ownership |
772
- | [docs/input-history.md](docs/input-history.md) | Input history |
773
- | [docs/surface-decisions.md](docs/surface-decisions.md) | TUI interaction decisions |
774
- | [docs/concurrency.md](docs/concurrency.md) | Session concurrency |
775
- | [docs/failure-model.md](docs/failure-model.md) | Async failure / cancellation |
776
- | [docs/perf-baseline.md](docs/perf-baseline.md) | Performance baseline |
777
- | [docs/local-development.md](docs/local-development.md) | Local development and worktree policy |
778
- | [docs/extension-api.md](docs/extension-api.md) | Extension API |
848
+ | [docs/README.md](docs/README.md) | Documentation policy and index |
849
+ | [docs/architecture/overview.md](docs/architecture/overview.md) | Architecture, layers and dependency direction |
850
+ | [docs/architecture/host-client.md](docs/architecture/host-client.md) | Host/Client boundary and currentness contracts |
851
+ | [docs/architecture/surface-behavior.md](docs/architecture/surface-behavior.md) | Workspace/task/plugin surface behavior |
852
+ | [docs/guides/development.md](docs/guides/development.md) | Local development, worktrees and benchmark reruns |
853
+ | [docs/extensions/stable.md](docs/extensions/stable.md) | Extension API |
854
+ | [docs/guides/code-review.md](docs/guides/code-review.md) | Repository review checkpoints |
779
855
  | [AGENTS.md](AGENTS.md) | Contributor operating manual |
780
856
 
781
857
  ## Changelog