@deepseek-harness-tui/dsh-tui 0.13.0 → 0.14.1
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 +85 -5
- package/assets/claude-girl/claude-girl-happy.png +0 -0
- package/assets/claude-girl/claude-girl.png +0 -0
- package/assets/codex-girl/codex-girl-happy.png +0 -0
- package/assets/codex-girl/codex-girl.png +0 -0
- package/bin/dsh-tui.js +104 -18
- package/cordis.patch.yml +2 -0
- package/cordis.yml +2 -0
- package/guide/dsh-tui-guide/SKILL.md +4 -2
- package/guide/dsh-tui-guide/claude-backend.en.md +203 -0
- package/guide/dsh-tui-guide/claude-backend.md +161 -0
- package/guide/dsh-tui-guide/codex-backend.en.md +297 -0
- package/guide/dsh-tui-guide/codex-backend.md +257 -0
- package/guide/dsh-tui-guide/configuration.en.md +9 -2
- package/guide/dsh-tui-guide/configuration.md +9 -2
- package/guide/dsh-tui-guide/interaction.en.md +169 -27
- package/guide/dsh-tui-guide/interaction.md +115 -17
- package/guide/dsh-tui-guide/themes.en.md +24 -2
- package/guide/dsh-tui-guide/themes.md +21 -2
- package/guide/dsh-tui-guide/user-guide.en.md +38 -23
- package/guide/dsh-tui-guide/user-guide.md +22 -11
- package/guide/dsh-tui-guide/vscode.en.md +1 -0
- package/guide/dsh-tui-guide/vscode.md +1 -0
- package/lib/settings.json +139 -6
- package/lib/types/adapter/channel/state.d.ts.map +1 -1
- package/lib/types/adapter/channel/state.js +1 -0
- package/lib/types/adapter/channel/ui-policy.d.ts +17 -2
- package/lib/types/adapter/channel/ui-policy.d.ts.map +1 -1
- package/lib/types/adapter/channel/ui-policy.js +29 -0
- package/lib/types/adapter/channel/ui.d.ts.map +1 -1
- package/lib/types/adapter/channel/ui.js +45 -5
- package/lib/types/adapter/ports/channel-catalog.d.ts +7 -0
- package/lib/types/adapter/ports/channel-catalog.d.ts.map +1 -1
- package/lib/types/adapter/ports/channel-display.d.ts +7 -1
- package/lib/types/adapter/ports/channel-display.d.ts.map +1 -1
- package/lib/types/adapter/ports/channel-session.d.ts +5 -0
- package/lib/types/adapter/ports/channel-session.d.ts.map +1 -1
- package/lib/types/adapter/ports/channel-settings.d.ts +20 -0
- package/lib/types/adapter/ports/channel-settings.d.ts.map +1 -1
- package/lib/types/adapter/ports/channel-ui.d.ts +183 -6
- package/lib/types/adapter/ports/channel-ui.d.ts.map +1 -1
- package/lib/types/adapter/ports/channel-view.d.ts +477 -13
- package/lib/types/adapter/ports/channel-view.d.ts.map +1 -1
- package/lib/types/agent/backend.d.ts +168 -0
- package/lib/types/agent/backend.d.ts.map +1 -0
- package/lib/types/agent/backend.js +1 -0
- package/lib/types/agent/capabilities.d.ts +461 -0
- package/lib/types/agent/capabilities.d.ts.map +1 -0
- package/lib/types/agent/capabilities.js +1 -0
- package/lib/types/agent/events.d.ts +733 -0
- package/lib/types/agent/events.d.ts.map +1 -0
- package/lib/types/agent/events.js +2 -0
- package/lib/types/agent/index.d.ts +8 -0
- package/lib/types/agent/index.d.ts.map +1 -0
- package/lib/types/agent/index.js +7 -0
- package/lib/types/agent/messages.d.ts +52 -0
- package/lib/types/agent/messages.d.ts.map +1 -0
- package/lib/types/agent/messages.js +91 -0
- package/lib/types/agent/presentation.d.ts +29 -0
- package/lib/types/agent/presentation.d.ts.map +1 -0
- package/lib/types/agent/presentation.js +4 -0
- package/lib/types/agent/refs.d.ts +30 -0
- package/lib/types/agent/refs.d.ts.map +1 -0
- package/lib/types/agent/refs.js +39 -0
- package/lib/types/agent/session.d.ts +78 -0
- package/lib/types/agent/session.d.ts.map +1 -0
- package/lib/types/agent/session.js +1 -0
- package/lib/types/backends/claude/activity.d.ts +53 -0
- package/lib/types/backends/claude/activity.d.ts.map +1 -0
- package/lib/types/backends/claude/activity.js +103 -0
- package/lib/types/backends/claude/auth.d.ts +245 -0
- package/lib/types/backends/claude/auth.d.ts.map +1 -0
- package/lib/types/backends/claude/auth.js +503 -0
- package/lib/types/backends/claude/backend.d.ts +32 -0
- package/lib/types/backends/claude/backend.d.ts.map +1 -0
- package/lib/types/backends/claude/backend.js +296 -0
- package/lib/types/backends/claude/catalog.d.ts +17 -0
- package/lib/types/backends/claude/catalog.d.ts.map +1 -0
- package/lib/types/backends/claude/catalog.js +94 -0
- package/lib/types/backends/claude/channels.d.ts +63 -0
- package/lib/types/backends/claude/channels.d.ts.map +1 -0
- package/lib/types/backends/claude/channels.js +275 -0
- package/lib/types/backends/claude/contract.d.ts +37 -0
- package/lib/types/backends/claude/contract.d.ts.map +1 -0
- package/lib/types/backends/claude/contract.js +46 -0
- package/lib/types/backends/claude/controls.d.ts +134 -0
- package/lib/types/backends/claude/controls.d.ts.map +1 -0
- package/lib/types/backends/claude/controls.js +425 -0
- package/lib/types/backends/claude/dialogs.d.ts +62 -0
- package/lib/types/backends/claude/dialogs.d.ts.map +1 -0
- package/lib/types/backends/claude/dialogs.js +253 -0
- package/lib/types/backends/claude/flag-settings.d.ts +12 -0
- package/lib/types/backends/claude/flag-settings.d.ts.map +1 -0
- package/lib/types/backends/claude/flag-settings.js +49 -0
- package/lib/types/backends/claude/images.d.ts +49 -0
- package/lib/types/backends/claude/images.d.ts.map +1 -0
- package/lib/types/backends/claude/images.js +94 -0
- package/lib/types/backends/claude/index.d.ts +5 -0
- package/lib/types/backends/claude/index.d.ts.map +1 -0
- package/lib/types/backends/claude/index.js +4 -0
- package/lib/types/backends/claude/install.d.ts +15 -0
- package/lib/types/backends/claude/install.d.ts.map +1 -0
- package/lib/types/backends/claude/install.js +91 -0
- package/lib/types/backends/claude/modelEnv.d.ts +64 -0
- package/lib/types/backends/claude/modelEnv.d.ts.map +1 -0
- package/lib/types/backends/claude/modelEnv.js +199 -0
- package/lib/types/backends/claude/narrow.d.ts +10 -0
- package/lib/types/backends/claude/narrow.d.ts.map +1 -0
- package/lib/types/backends/claude/narrow.js +8 -0
- package/lib/types/backends/claude/older-history.d.ts +16 -0
- package/lib/types/backends/claude/older-history.d.ts.map +1 -0
- package/lib/types/backends/claude/older-history.js +101 -0
- package/lib/types/backends/claude/options.d.ts +181 -0
- package/lib/types/backends/claude/options.d.ts.map +1 -0
- package/lib/types/backends/claude/options.js +208 -0
- package/lib/types/backends/claude/permissions.d.ts +83 -0
- package/lib/types/backends/claude/permissions.d.ts.map +1 -0
- package/lib/types/backends/claude/permissions.js +331 -0
- package/lib/types/backends/claude/prefs.d.ts +55 -0
- package/lib/types/backends/claude/prefs.d.ts.map +1 -0
- package/lib/types/backends/claude/prefs.js +150 -0
- package/lib/types/backends/claude/process.d.ts +19 -0
- package/lib/types/backends/claude/process.d.ts.map +1 -0
- package/lib/types/backends/claude/process.js +156 -0
- package/lib/types/backends/claude/replay.d.ts +129 -0
- package/lib/types/backends/claude/replay.d.ts.map +1 -0
- package/lib/types/backends/claude/replay.js +505 -0
- package/lib/types/backends/claude/sdk-warnings.d.ts +23 -0
- package/lib/types/backends/claude/sdk-warnings.d.ts.map +1 -0
- package/lib/types/backends/claude/sdk-warnings.js +55 -0
- package/lib/types/backends/claude/sdk.d.ts +12 -0
- package/lib/types/backends/claude/sdk.d.ts.map +1 -0
- package/lib/types/backends/claude/sdk.js +34 -0
- package/lib/types/backends/claude/send-message.d.ts +54 -0
- package/lib/types/backends/claude/send-message.d.ts.map +1 -0
- package/lib/types/backends/claude/send-message.js +65 -0
- package/lib/types/backends/claude/session/auth.d.ts +47 -0
- package/lib/types/backends/claude/session/auth.d.ts.map +1 -0
- package/lib/types/backends/claude/session/auth.js +226 -0
- package/lib/types/backends/claude/session/channels.d.ts +82 -0
- package/lib/types/backends/claude/session/channels.d.ts.map +1 -0
- package/lib/types/backends/claude/session/channels.js +45 -0
- package/lib/types/backends/claude/session/input.d.ts +16 -0
- package/lib/types/backends/claude/session/input.d.ts.map +1 -0
- package/lib/types/backends/claude/session/input.js +64 -0
- package/lib/types/backends/claude/session/lifecycle.d.ts +6 -0
- package/lib/types/backends/claude/session/lifecycle.d.ts.map +1 -0
- package/lib/types/backends/claude/session/lifecycle.js +852 -0
- package/lib/types/backends/claude/session/store.d.ts +17 -0
- package/lib/types/backends/claude/session/store.d.ts.map +1 -0
- package/lib/types/backends/claude/session/store.js +122 -0
- package/lib/types/backends/claude/session/subagents.d.ts +13 -0
- package/lib/types/backends/claude/session/subagents.d.ts.map +1 -0
- package/lib/types/backends/claude/session/subagents.js +77 -0
- package/lib/types/backends/claude/session/types.d.ts +89 -0
- package/lib/types/backends/claude/session/types.d.ts.map +1 -0
- package/lib/types/backends/claude/session/types.js +1 -0
- package/lib/types/backends/claude/session.d.ts +4 -0
- package/lib/types/backends/claude/session.d.ts.map +1 -0
- package/lib/types/backends/claude/session.js +2 -0
- package/lib/types/backends/claude/side-query.d.ts +34 -0
- package/lib/types/backends/claude/side-query.d.ts.map +1 -0
- package/lib/types/backends/claude/side-query.js +116 -0
- package/lib/types/backends/claude/task-output.d.ts +13 -0
- package/lib/types/backends/claude/task-output.d.ts.map +1 -0
- package/lib/types/backends/claude/task-output.js +101 -0
- package/lib/types/backends/claude/tools.d.ts +45 -0
- package/lib/types/backends/claude/tools.d.ts.map +1 -0
- package/lib/types/backends/claude/tools.js +231 -0
- package/lib/types/backends/claude/transcript-file.d.ts +41 -0
- package/lib/types/backends/claude/transcript-file.d.ts.map +1 -0
- package/lib/types/backends/claude/transcript-file.js +195 -0
- package/lib/types/backends/claude/translate/attempts.d.ts +33 -0
- package/lib/types/backends/claude/translate/attempts.d.ts.map +1 -0
- package/lib/types/backends/claude/translate/attempts.js +243 -0
- package/lib/types/backends/claude/translate/content.d.ts +33 -0
- package/lib/types/backends/claude/translate/content.d.ts.map +1 -0
- package/lib/types/backends/claude/translate/content.js +91 -0
- package/lib/types/backends/claude/translate/core.d.ts +76 -0
- package/lib/types/backends/claude/translate/core.d.ts.map +1 -0
- package/lib/types/backends/claude/translate/core.js +447 -0
- package/lib/types/backends/claude/translate/events.d.ts +9 -0
- package/lib/types/backends/claude/translate/events.d.ts.map +1 -0
- package/lib/types/backends/claude/translate/events.js +77 -0
- package/lib/types/backends/claude/translate/lanes.d.ts +31 -0
- package/lib/types/backends/claude/translate/lanes.d.ts.map +1 -0
- package/lib/types/backends/claude/translate/lanes.js +177 -0
- package/lib/types/backends/claude/translate/messages.d.ts +36 -0
- package/lib/types/backends/claude/translate/messages.d.ts.map +1 -0
- package/lib/types/backends/claude/translate/messages.js +202 -0
- package/lib/types/backends/claude/translate/system.d.ts +40 -0
- package/lib/types/backends/claude/translate/system.d.ts.map +1 -0
- package/lib/types/backends/claude/translate/system.js +399 -0
- package/lib/types/backends/claude/translate/tasks.d.ts +19 -0
- package/lib/types/backends/claude/translate/tasks.d.ts.map +1 -0
- package/lib/types/backends/claude/translate/tasks.js +159 -0
- package/lib/types/backends/claude/translate/types.d.ts +114 -0
- package/lib/types/backends/claude/translate/types.d.ts.map +1 -0
- package/lib/types/backends/claude/translate/types.js +1 -0
- package/lib/types/backends/claude/translate.d.ts +9 -0
- package/lib/types/backends/claude/translate.d.ts.map +1 -0
- package/lib/types/backends/claude/translate.js +6 -0
- package/lib/types/backends/codex/auth/external-tokens.d.ts +66 -0
- package/lib/types/backends/codex/auth/external-tokens.d.ts.map +1 -0
- package/lib/types/backends/codex/auth/external-tokens.js +325 -0
- package/lib/types/backends/codex/auth/route.d.ts +14 -0
- package/lib/types/backends/codex/auth/route.d.ts.map +1 -0
- package/lib/types/backends/codex/auth/route.js +52 -0
- package/lib/types/backends/codex/auth/status.d.ts +16 -0
- package/lib/types/backends/codex/auth/status.d.ts.map +1 -0
- package/lib/types/backends/codex/auth/status.js +115 -0
- package/lib/types/backends/codex/backend.d.ts +58 -0
- package/lib/types/backends/codex/backend.d.ts.map +1 -0
- package/lib/types/backends/codex/backend.js +201 -0
- package/lib/types/backends/codex/catalog.d.ts +17 -0
- package/lib/types/backends/codex/catalog.d.ts.map +1 -0
- package/lib/types/backends/codex/catalog.js +128 -0
- package/lib/types/backends/codex/channels.d.ts +59 -0
- package/lib/types/backends/codex/channels.d.ts.map +1 -0
- package/lib/types/backends/codex/channels.js +274 -0
- package/lib/types/backends/codex/contract.d.ts +46 -0
- package/lib/types/backends/codex/contract.d.ts.map +1 -0
- package/lib/types/backends/codex/contract.js +80 -0
- package/lib/types/backends/codex/detect.d.ts +14 -0
- package/lib/types/backends/codex/detect.d.ts.map +1 -0
- package/lib/types/backends/codex/detect.js +90 -0
- package/lib/types/backends/codex/index.d.ts +6 -0
- package/lib/types/backends/codex/index.d.ts.map +1 -0
- package/lib/types/backends/codex/index.js +5 -0
- package/lib/types/backends/codex/modes.d.ts +16 -0
- package/lib/types/backends/codex/modes.d.ts.map +1 -0
- package/lib/types/backends/codex/modes.js +49 -0
- package/lib/types/backends/codex/narrow.d.ts +20 -0
- package/lib/types/backends/codex/narrow.d.ts.map +1 -0
- package/lib/types/backends/codex/narrow.js +18 -0
- package/lib/types/backends/codex/prefs.d.ts +42 -0
- package/lib/types/backends/codex/prefs.d.ts.map +1 -0
- package/lib/types/backends/codex/prefs.js +124 -0
- package/lib/types/backends/codex/protocol/index.d.ts +149 -0
- package/lib/types/backends/codex/protocol/index.d.ts.map +1 -0
- package/lib/types/backends/codex/protocol/index.js +130 -0
- package/lib/types/backends/codex/rpc/binary.d.ts +35 -0
- package/lib/types/backends/codex/rpc/binary.d.ts.map +1 -0
- package/lib/types/backends/codex/rpc/binary.js +174 -0
- package/lib/types/backends/codex/rpc/client.d.ts +72 -0
- package/lib/types/backends/codex/rpc/client.d.ts.map +1 -0
- package/lib/types/backends/codex/rpc/client.js +214 -0
- package/lib/types/backends/codex/rpc/hub.d.ts +105 -0
- package/lib/types/backends/codex/rpc/hub.d.ts.map +1 -0
- package/lib/types/backends/codex/rpc/hub.js +532 -0
- package/lib/types/backends/codex/rpc/transport.d.ts +39 -0
- package/lib/types/backends/codex/rpc/transport.d.ts.map +1 -0
- package/lib/types/backends/codex/rpc/transport.js +212 -0
- package/lib/types/backends/codex/session/activity.d.ts +18 -0
- package/lib/types/backends/codex/session/activity.d.ts.map +1 -0
- package/lib/types/backends/codex/session/activity.js +108 -0
- package/lib/types/backends/codex/session/approvals.d.ts +39 -0
- package/lib/types/backends/codex/session/approvals.d.ts.map +1 -0
- package/lib/types/backends/codex/session/approvals.js +477 -0
- package/lib/types/backends/codex/session/commands.d.ts +37 -0
- package/lib/types/backends/codex/session/commands.d.ts.map +1 -0
- package/lib/types/backends/codex/session/commands.js +141 -0
- package/lib/types/backends/codex/session/controls.d.ts +37 -0
- package/lib/types/backends/codex/session/controls.d.ts.map +1 -0
- package/lib/types/backends/codex/session/controls.js +303 -0
- package/lib/types/backends/codex/session/goals.d.ts +25 -0
- package/lib/types/backends/codex/session/goals.d.ts.map +1 -0
- package/lib/types/backends/codex/session/goals.js +97 -0
- package/lib/types/backends/codex/session/history.d.ts +52 -0
- package/lib/types/backends/codex/session/history.d.ts.map +1 -0
- package/lib/types/backends/codex/session/history.js +196 -0
- package/lib/types/backends/codex/session/images.d.ts +17 -0
- package/lib/types/backends/codex/session/images.d.ts.map +1 -0
- package/lib/types/backends/codex/session/images.js +138 -0
- package/lib/types/backends/codex/session/input.d.ts +75 -0
- package/lib/types/backends/codex/session/input.d.ts.map +1 -0
- package/lib/types/backends/codex/session/input.js +294 -0
- package/lib/types/backends/codex/session/plan-review.d.ts +19 -0
- package/lib/types/backends/codex/session/plan-review.d.ts.map +1 -0
- package/lib/types/backends/codex/session/plan-review.js +48 -0
- package/lib/types/backends/codex/session/prompts.d.ts +7 -0
- package/lib/types/backends/codex/session/prompts.d.ts.map +1 -0
- package/lib/types/backends/codex/session/prompts.js +47 -0
- package/lib/types/backends/codex/session/session.d.ts +12 -0
- package/lib/types/backends/codex/session/session.d.ts.map +1 -0
- package/lib/types/backends/codex/session/session.js +871 -0
- package/lib/types/backends/codex/session/side-query.d.ts +25 -0
- package/lib/types/backends/codex/session/side-query.d.ts.map +1 -0
- package/lib/types/backends/codex/session/side-query.js +121 -0
- package/lib/types/backends/codex/session/state.d.ts +57 -0
- package/lib/types/backends/codex/session/state.d.ts.map +1 -0
- package/lib/types/backends/codex/session/state.js +1 -0
- package/lib/types/backends/codex/session/subagents.d.ts +28 -0
- package/lib/types/backends/codex/session/subagents.d.ts.map +1 -0
- package/lib/types/backends/codex/session/subagents.js +286 -0
- package/lib/types/backends/codex/session/tasks.d.ts +25 -0
- package/lib/types/backends/codex/session/tasks.d.ts.map +1 -0
- package/lib/types/backends/codex/session/tasks.js +207 -0
- package/lib/types/backends/codex/session/tool-output.d.ts +9 -0
- package/lib/types/backends/codex/session/tool-output.d.ts.map +1 -0
- package/lib/types/backends/codex/session/tool-output.js +29 -0
- package/lib/types/backends/codex/translate/commands.d.ts +30 -0
- package/lib/types/backends/codex/translate/commands.d.ts.map +1 -0
- package/lib/types/backends/codex/translate/commands.js +103 -0
- package/lib/types/backends/codex/translate/events.d.ts +9 -0
- package/lib/types/backends/codex/translate/events.d.ts.map +1 -0
- package/lib/types/backends/codex/translate/events.js +71 -0
- package/lib/types/backends/codex/translate/items.d.ts +112 -0
- package/lib/types/backends/codex/translate/items.d.ts.map +1 -0
- package/lib/types/backends/codex/translate/items.js +375 -0
- package/lib/types/backends/codex/translate/live.d.ts +39 -0
- package/lib/types/backends/codex/translate/live.d.ts.map +1 -0
- package/lib/types/backends/codex/translate/live.js +315 -0
- package/lib/types/backends/codex/translate/notices.d.ts +27 -0
- package/lib/types/backends/codex/translate/notices.d.ts.map +1 -0
- package/lib/types/backends/codex/translate/notices.js +99 -0
- package/lib/types/backends/codex/translate/presentation.d.ts +49 -0
- package/lib/types/backends/codex/translate/presentation.d.ts.map +1 -0
- package/lib/types/backends/codex/translate/presentation.js +237 -0
- package/lib/types/backends/codex/translate/replay.d.ts +18 -0
- package/lib/types/backends/codex/translate/replay.d.ts.map +1 -0
- package/lib/types/backends/codex/translate/replay.js +33 -0
- package/lib/types/backends/codex/translate/usage.d.ts +29 -0
- package/lib/types/backends/codex/translate/usage.d.ts.map +1 -0
- package/lib/types/backends/codex/translate/usage.js +65 -0
- package/lib/types/backends/shared/atomic-file.d.ts +4 -0
- package/lib/types/backends/shared/atomic-file.d.ts.map +1 -0
- package/lib/types/backends/shared/atomic-file.js +52 -0
- package/lib/types/backends/shared/channel-tokens.d.ts +29 -0
- package/lib/types/backends/shared/channel-tokens.d.ts.map +1 -0
- package/lib/types/backends/shared/channel-tokens.js +161 -0
- package/lib/types/backends/shared/display-path.d.ts +3 -0
- package/lib/types/backends/shared/display-path.d.ts.map +1 -0
- package/lib/types/backends/shared/display-path.js +12 -0
- package/lib/types/branding.d.ts +92 -0
- package/lib/types/branding.d.ts.map +1 -0
- package/lib/types/branding.js +117 -0
- package/lib/types/channel/activity.d.ts +53 -0
- package/lib/types/channel/activity.d.ts.map +1 -0
- package/lib/types/channel/activity.js +955 -0
- package/lib/types/channel/capabilities.d.ts +24 -0
- package/lib/types/channel/capabilities.d.ts.map +1 -0
- package/lib/types/channel/capabilities.js +57 -0
- package/lib/types/channel/channel-slug.d.ts +9 -0
- package/lib/types/channel/channel-slug.d.ts.map +1 -0
- package/lib/types/channel/channel-slug.js +15 -0
- package/lib/types/channel/channel-wizard.d.ts +30 -0
- package/lib/types/channel/channel-wizard.d.ts.map +1 -0
- package/lib/types/channel/channel-wizard.js +226 -0
- package/lib/types/channel/elicitation.d.ts +135 -0
- package/lib/types/channel/elicitation.d.ts.map +1 -0
- package/lib/types/channel/elicitation.js +360 -0
- package/lib/types/channel/goal-command.d.ts +49 -0
- package/lib/types/channel/goal-command.d.ts.map +1 -0
- package/lib/types/channel/goal-command.js +72 -0
- package/lib/types/channel/history-restore.d.ts +16 -0
- package/lib/types/channel/history-restore.d.ts.map +1 -0
- package/lib/types/channel/history-restore.js +214 -0
- package/lib/types/channel/interaction.d.ts +38 -0
- package/lib/types/channel/interaction.d.ts.map +1 -0
- package/lib/types/channel/interaction.js +110 -0
- package/lib/types/channel/job-format.d.ts +6 -0
- package/lib/types/channel/job-format.d.ts.map +1 -0
- package/lib/types/channel/job-format.js +12 -0
- package/lib/types/channel/live-output.d.ts +35 -0
- package/lib/types/channel/live-output.d.ts.map +1 -0
- package/lib/types/channel/live-output.js +74 -0
- package/lib/types/channel/model-capabilities.d.ts +10 -0
- package/lib/types/channel/model-capabilities.d.ts.map +1 -0
- package/lib/types/channel/model-capabilities.js +51 -0
- package/lib/types/channel/permissions.d.ts +155 -0
- package/lib/types/channel/permissions.d.ts.map +1 -0
- package/lib/types/channel/permissions.js +188 -0
- package/lib/types/channel/projection.d.ts +110 -0
- package/lib/types/channel/projection.d.ts.map +1 -0
- package/lib/types/channel/projection.js +1521 -0
- package/lib/types/channel/question-record.d.ts +76 -0
- package/lib/types/channel/question-record.d.ts.map +1 -0
- package/lib/types/channel/question-record.js +109 -0
- package/lib/types/channel/questions.d.ts +204 -0
- package/lib/types/channel/questions.d.ts.map +1 -0
- package/lib/types/channel/questions.js +286 -0
- package/lib/types/channel/sanitize.d.ts +49 -0
- package/lib/types/channel/sanitize.d.ts.map +1 -0
- package/lib/types/channel/sanitize.js +88 -0
- package/lib/types/channel/selection-record.d.ts +18 -0
- package/lib/types/channel/selection-record.d.ts.map +1 -0
- package/lib/types/channel/selection-record.js +45 -0
- package/lib/types/channel/side-prompts.d.ts +59 -0
- package/lib/types/channel/side-prompts.d.ts.map +1 -0
- package/lib/types/channel/side-prompts.js +127 -0
- package/lib/types/channel/transcript.d.ts +17 -0
- package/lib/types/channel/transcript.d.ts.map +1 -0
- package/lib/types/channel/transcript.js +19 -0
- package/lib/types/channel/usage.d.ts +48 -0
- package/lib/types/channel/usage.d.ts.map +1 -0
- package/lib/types/channel/usage.js +143 -0
- package/lib/types/commands.d.ts +147 -0
- package/lib/types/commands.d.ts.map +1 -1
- package/lib/types/commands.js +196 -2
- package/lib/types/components/AgentMessageComposer.d.ts +50 -0
- package/lib/types/components/AgentMessageComposer.d.ts.map +1 -0
- package/lib/types/components/AgentMessageComposer.js +159 -0
- package/lib/types/components/BtwPanel.d.ts +13 -12
- package/lib/types/components/BtwPanel.d.ts.map +1 -1
- package/lib/types/components/BtwPanel.js +35 -24
- package/lib/types/components/ChannelPicker.d.ts +40 -0
- package/lib/types/components/ChannelPicker.d.ts.map +1 -0
- package/lib/types/components/ChannelPicker.js +26 -0
- package/lib/types/components/Chat/JobCard.d.ts +29 -31
- package/lib/types/components/Chat/JobCard.d.ts.map +1 -1
- package/lib/types/components/Chat/JobCard.js +31 -112
- package/lib/types/components/Chat/SubagentMessage.d.ts +4 -1
- package/lib/types/components/Chat/SubagentMessage.d.ts.map +1 -1
- package/lib/types/components/Chat/SubagentMessage.js +10 -3
- package/lib/types/components/ClaudeGirl.d.ts +27 -0
- package/lib/types/components/ClaudeGirl.d.ts.map +1 -0
- package/lib/types/components/ClaudeGirl.js +30 -0
- package/lib/types/components/CodeBlockFrame.d.ts +19 -0
- package/lib/types/components/CodeBlockFrame.d.ts.map +1 -0
- package/lib/types/components/CodeBlockFrame.js +138 -0
- package/lib/types/components/CommandSuggestions.d.ts +10 -1
- package/lib/types/components/CommandSuggestions.d.ts.map +1 -1
- package/lib/types/components/CommandSuggestions.js +20 -3
- package/lib/types/components/ContextBarView.d.ts +2 -2
- package/lib/types/components/ContextBarView.d.ts.map +1 -1
- package/lib/types/components/ContextBarView.js +18 -8
- package/lib/types/components/EffortChargeGlyph.d.ts +1 -1
- package/lib/types/components/EffortChargeGlyph.d.ts.map +1 -1
- package/lib/types/components/EffortChargeGlyph.js +3 -4
- package/lib/types/components/EffortInputBorder.d.ts +1 -2
- package/lib/types/components/EffortInputBorder.d.ts.map +1 -1
- package/lib/types/components/EffortInputBorder.js +7 -4
- package/lib/types/components/EffortSlider.d.ts +5 -1
- package/lib/types/components/EffortSlider.d.ts.map +1 -1
- package/lib/types/components/EffortSlider.js +2 -2
- package/lib/types/components/EffortTierBadge.d.ts +1 -2
- package/lib/types/components/EffortTierBadge.d.ts.map +1 -1
- package/lib/types/components/EffortTierBadge.js +8 -5
- package/lib/types/components/GoalTodoPanel.d.ts +2 -1
- package/lib/types/components/GoalTodoPanel.d.ts.map +1 -1
- package/lib/types/components/GoalTodoPanel.js +11 -5
- package/lib/types/components/InlineMathParagraph.js +1 -1
- package/lib/types/components/JobsPanel.d.ts +8 -9
- package/lib/types/components/JobsPanel.d.ts.map +1 -1
- package/lib/types/components/JobsPanel.js +72 -13
- package/lib/types/components/KernelPicker.d.ts +28 -0
- package/lib/types/components/KernelPicker.d.ts.map +1 -0
- package/lib/types/components/KernelPicker.js +37 -0
- package/lib/types/components/LogoV2.d.ts +7 -1
- package/lib/types/components/LogoV2.d.ts.map +1 -1
- package/lib/types/components/LogoV2.js +120 -24
- package/lib/types/components/Markdown.d.ts +2 -1
- package/lib/types/components/Markdown.d.ts.map +1 -1
- package/lib/types/components/Markdown.js +37 -8
- package/lib/types/components/MathBlock.d.ts.map +1 -1
- package/lib/types/components/MathBlock.js +3 -1
- package/lib/types/components/MermaidDiagram.d.ts.map +1 -1
- package/lib/types/components/MermaidDiagram.js +7 -5
- package/lib/types/components/MessageList.d.ts +21 -3
- package/lib/types/components/MessageList.d.ts.map +1 -1
- package/lib/types/components/MessageList.js +62 -42
- package/lib/types/components/ModePicker.d.ts +20 -0
- package/lib/types/components/ModePicker.d.ts.map +1 -0
- package/lib/types/components/ModePicker.js +17 -0
- package/lib/types/components/PromptInput.d.ts +2 -2
- package/lib/types/components/PromptInput.d.ts.map +1 -1
- package/lib/types/components/PromptInput.js +308 -55
- package/lib/types/components/SdkInstallWizard.d.ts +44 -0
- package/lib/types/components/SdkInstallWizard.d.ts.map +1 -0
- package/lib/types/components/SdkInstallWizard.js +18 -0
- package/lib/types/components/SearchBox.d.ts +7 -8
- package/lib/types/components/SearchBox.d.ts.map +1 -1
- package/lib/types/components/SearchBox.js +18 -9
- package/lib/types/components/SplitDiffView.d.ts.map +1 -1
- package/lib/types/components/SplitDiffView.js +113 -6
- package/lib/types/components/StarPrompt.d.ts.map +1 -1
- package/lib/types/components/StarPrompt.js +5 -3
- package/lib/types/components/StreamingMarkdown.d.ts.map +1 -1
- package/lib/types/components/StreamingMarkdown.js +6 -4
- package/lib/types/components/SubagentCard.d.ts +2 -1
- package/lib/types/components/SubagentCard.d.ts.map +1 -1
- package/lib/types/components/SubagentCard.js +25 -18
- package/lib/types/components/SubagentDashboard.d.ts +10 -6
- package/lib/types/components/SubagentDashboard.d.ts.map +1 -1
- package/lib/types/components/SubagentDashboard.js +32 -21
- package/lib/types/components/SubagentDetailScene.d.ts +16 -1
- package/lib/types/components/SubagentDetailScene.d.ts.map +1 -1
- package/lib/types/components/SubagentDetailScene.js +196 -45
- package/lib/types/components/SyntaxText.d.ts.map +1 -1
- package/lib/types/components/SyntaxText.js +4 -1
- package/lib/types/components/TurnInterruptedRow.d.ts +3 -1
- package/lib/types/components/TurnInterruptedRow.d.ts.map +1 -1
- package/lib/types/components/TurnInterruptedRow.js +6 -3
- package/lib/types/components/TurnUsageRow.d.ts +24 -0
- package/lib/types/components/TurnUsageRow.d.ts.map +1 -0
- package/lib/types/components/TurnUsageRow.js +46 -0
- package/lib/types/components/WorkingSpinner.d.ts +2 -1
- package/lib/types/components/WorkingSpinner.d.ts.map +1 -1
- package/lib/types/components/WorkingSpinner.js +21 -4
- package/lib/types/components/approvals/ApprovalPanel.d.ts +36 -13
- package/lib/types/components/approvals/ApprovalPanel.d.ts.map +1 -1
- package/lib/types/components/approvals/ApprovalPanel.js +173 -25
- package/lib/types/components/claudeGirlSprite.d.ts +18 -0
- package/lib/types/components/claudeGirlSprite.d.ts.map +1 -0
- package/lib/types/components/claudeGirlSprite.js +48 -0
- package/lib/types/components/design-system/ThemeProvider.d.ts.map +1 -1
- package/lib/types/components/design-system/ThemeProvider.js +46 -13
- package/lib/types/components/design-system/ThemedText.d.ts +3 -1
- package/lib/types/components/design-system/ThemedText.d.ts.map +1 -1
- package/lib/types/components/design-system/ThemedText.js +2 -2
- package/lib/types/components/diffPatch.d.ts +55 -0
- package/lib/types/components/diffPatch.d.ts.map +1 -0
- package/lib/types/components/diffPatch.js +142 -0
- package/lib/types/components/kernelCatalog.d.ts +48 -0
- package/lib/types/components/kernelCatalog.d.ts.map +1 -0
- package/lib/types/components/kernelCatalog.js +53 -0
- package/lib/types/components/launchpadActions.d.ts +13 -6
- package/lib/types/components/launchpadActions.d.ts.map +1 -1
- package/lib/types/components/launchpadActions.js +26 -4
- package/lib/types/components/launchpadParams.d.ts +101 -0
- package/lib/types/components/launchpadParams.d.ts.map +1 -0
- package/lib/types/components/launchpadParams.js +171 -0
- package/lib/types/components/maidPortrait.d.ts +37 -5
- package/lib/types/components/maidPortrait.d.ts.map +1 -1
- package/lib/types/components/maidPortrait.js +73 -54
- package/lib/types/components/messages/AgentMessageFlow.d.ts +20 -0
- package/lib/types/components/messages/AgentMessageFlow.d.ts.map +1 -0
- package/lib/types/components/messages/AgentMessageFlow.js +37 -0
- package/lib/types/components/messages/AssistantThinkingMessage.d.ts +6 -1
- package/lib/types/components/messages/AssistantThinkingMessage.d.ts.map +1 -1
- package/lib/types/components/messages/AssistantThinkingMessage.js +29 -5
- package/lib/types/components/messages/AssistantToolUseMessage.d.ts +11 -2
- package/lib/types/components/messages/AssistantToolUseMessage.d.ts.map +1 -1
- package/lib/types/components/messages/AssistantToolUseMessage.js +289 -36
- package/lib/types/components/messages/TranscriptLeaves.d.ts +85 -0
- package/lib/types/components/messages/TranscriptLeaves.d.ts.map +1 -0
- package/lib/types/components/messages/TranscriptLeaves.js +74 -0
- package/lib/types/components/messages/agentTeam.d.ts +69 -0
- package/lib/types/components/messages/agentTeam.d.ts.map +1 -0
- package/lib/types/components/messages/agentTeam.js +53 -0
- package/lib/types/components/messages/liveOutputLines.d.ts +33 -0
- package/lib/types/components/messages/liveOutputLines.d.ts.map +1 -0
- package/lib/types/components/messages/liveOutputLines.js +100 -0
- package/lib/types/components/messages/subagentTranscript.d.ts +146 -0
- package/lib/types/components/messages/subagentTranscript.d.ts.map +1 -0
- package/lib/types/components/messages/subagentTranscript.js +304 -0
- package/lib/types/components/questions/AskUserQuestionPanel.d.ts +16 -1
- package/lib/types/components/questions/AskUserQuestionPanel.d.ts.map +1 -1
- package/lib/types/components/questions/AskUserQuestionPanel.js +76 -6
- package/lib/types/components/questions/PlanReviewPanel.d.ts +8 -3
- package/lib/types/components/questions/PlanReviewPanel.d.ts.map +1 -1
- package/lib/types/components/questions/PlanReviewPanel.js +11 -6
- package/lib/types/components/questions/ProviderModelEditor.d.ts +12 -0
- package/lib/types/components/questions/ProviderModelEditor.d.ts.map +1 -0
- package/lib/types/components/questions/ProviderModelEditor.js +266 -0
- package/lib/types/components/shimmer.d.ts +26 -0
- package/lib/types/components/shimmer.d.ts.map +1 -1
- package/lib/types/components/shimmer.js +26 -0
- package/lib/types/components/sidePanel/InfoPanel.d.ts.map +1 -1
- package/lib/types/components/sidePanel/InfoPanel.js +13 -8
- package/lib/types/components/sidePanel/PanelBar.d.ts +0 -24
- package/lib/types/components/sidePanel/PanelBar.d.ts.map +1 -1
- package/lib/types/components/sidePanel/PanelBar.js +55 -77
- package/lib/types/components/sidePanel/PanelStore.d.ts +3 -1
- package/lib/types/components/sidePanel/PanelStore.d.ts.map +1 -1
- package/lib/types/components/sidePanel/PanelStore.js +8 -4
- package/lib/types/components/sidePanel/SidePanelColumn.d.ts +3 -10
- package/lib/types/components/sidePanel/SidePanelColumn.d.ts.map +1 -1
- package/lib/types/components/sidePanel/SidePanelColumn.js +9 -12
- package/lib/types/components/sidePanel/TrajectoryPanel.d.ts.map +1 -1
- package/lib/types/components/sidePanel/TrajectoryPanel.js +78 -14
- package/lib/types/components/sidePanel/agentViewStore.d.ts +20 -0
- package/lib/types/components/sidePanel/agentViewStore.d.ts.map +1 -0
- package/lib/types/components/sidePanel/agentViewStore.js +26 -0
- package/lib/types/components/sidePanel/btw/BtwComposer.d.ts +50 -0
- package/lib/types/components/sidePanel/btw/BtwComposer.d.ts.map +1 -0
- package/lib/types/components/sidePanel/btw/BtwComposer.js +45 -0
- package/lib/types/components/sidePanel/btw/BtwPanelAdapter.d.ts +13 -0
- package/lib/types/components/sidePanel/btw/BtwPanelAdapter.d.ts.map +1 -0
- package/lib/types/components/sidePanel/btw/BtwPanelAdapter.js +147 -0
- package/lib/types/components/sidePanel/btw/BtwThreadScene.d.ts +14 -0
- package/lib/types/components/sidePanel/btw/BtwThreadScene.d.ts.map +1 -0
- package/lib/types/components/sidePanel/btw/BtwThreadScene.js +131 -0
- package/lib/types/components/sidePanel/btw/BtwThreadView.d.ts +30 -0
- package/lib/types/components/sidePanel/btw/BtwThreadView.d.ts.map +1 -0
- package/lib/types/components/sidePanel/btw/BtwThreadView.js +87 -0
- package/lib/types/components/sidePanel/btw/threads.d.ts +111 -0
- package/lib/types/components/sidePanel/btw/threads.d.ts.map +1 -0
- package/lib/types/components/sidePanel/btw/threads.js +302 -0
- package/lib/types/components/sidePanel/builtinPanels.d.ts.map +1 -1
- package/lib/types/components/sidePanel/builtinPanels.js +70 -30
- package/lib/types/components/sidePanel/companion/CompanionPanel.d.ts +4 -46
- package/lib/types/components/sidePanel/companion/CompanionPanel.d.ts.map +1 -1
- package/lib/types/components/sidePanel/companion/CompanionPanel.js +19 -55
- package/lib/types/components/sidePanel/companion/mood.d.ts +32 -0
- package/lib/types/components/sidePanel/companion/mood.d.ts.map +1 -1
- package/lib/types/components/sidePanel/companion/mood.js +44 -0
- package/lib/types/components/sidePanel/companion/skins.d.ts +34 -0
- package/lib/types/components/sidePanel/companion/skins.d.ts.map +1 -1
- package/lib/types/components/sidePanel/companion/skins.js +203 -29
- package/lib/types/components/splashFonts.d.ts +17 -9
- package/lib/types/components/splashFonts.d.ts.map +1 -1
- package/lib/types/components/splashFonts.js +119 -15
- package/lib/types/components/splashLayout.d.ts.map +1 -1
- package/lib/types/components/splashLayout.js +3 -1
- package/lib/types/components/subagentDetailMemory.d.ts +17 -0
- package/lib/types/components/subagentDetailMemory.d.ts.map +1 -0
- package/lib/types/components/subagentDetailMemory.js +28 -0
- package/lib/types/components/trajectory/Inspector.d.ts.map +1 -1
- package/lib/types/components/trajectory/Inspector.js +9 -0
- package/lib/types/components/trajectory/Ledger.d.ts.map +1 -1
- package/lib/types/components/trajectory/Ledger.js +7 -1
- package/lib/types/components/trajectory/scope.d.ts +64 -0
- package/lib/types/components/trajectory/scope.d.ts.map +1 -0
- package/lib/types/components/trajectory/scope.js +88 -0
- package/lib/types/components/trajectory/useTrajectoryScope.d.ts +42 -0
- package/lib/types/components/trajectory/useTrajectoryScope.d.ts.map +1 -0
- package/lib/types/components/trajectory/useTrajectoryScope.js +86 -0
- package/lib/types/customTheme.d.ts +4 -6
- package/lib/types/customTheme.d.ts.map +1 -1
- package/lib/types/customTheme.js +6 -8
- package/lib/types/dsh-adapter/approvals.d.ts +18 -5
- package/lib/types/dsh-adapter/approvals.d.ts.map +1 -1
- package/lib/types/dsh-adapter/approvals.js +17 -4
- package/lib/types/dsh-adapter/backend/session.d.ts +64 -0
- package/lib/types/dsh-adapter/backend/session.d.ts.map +1 -0
- package/lib/types/dsh-adapter/backend/session.js +291 -0
- package/lib/types/dsh-adapter/backend/translate.d.ts +58 -0
- package/lib/types/dsh-adapter/backend/translate.d.ts.map +1 -0
- package/lib/types/dsh-adapter/backend/translate.js +467 -0
- package/lib/types/dsh-adapter/backends.d.ts +49 -0
- package/lib/types/dsh-adapter/backends.d.ts.map +1 -0
- package/lib/types/dsh-adapter/backends.js +124 -0
- package/lib/types/dsh-adapter/channel/action-readiness.d.ts +16 -0
- package/lib/types/dsh-adapter/channel/action-readiness.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/action-readiness.js +109 -0
- package/lib/types/dsh-adapter/channel/agent-view-projection.d.ts +2 -2
- package/lib/types/dsh-adapter/channel/agent-view-projection.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/background-action.d.ts +2 -2
- package/lib/types/dsh-adapter/channel/background-action.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/background-action.js +7 -5
- package/lib/types/dsh-adapter/channel/binding-events.d.ts +19 -9
- package/lib/types/dsh-adapter/channel/binding-events.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/binding-events.js +58 -135
- package/lib/types/dsh-adapter/channel/binding.d.ts +61 -14
- package/lib/types/dsh-adapter/channel/binding.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/binding.js +102 -35
- package/lib/types/dsh-adapter/channel/command-completions.d.ts +3 -0
- package/lib/types/dsh-adapter/channel/command-completions.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/command-completions.js +33 -4
- package/lib/types/dsh-adapter/channel/compaction.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/compaction.js +3 -2
- package/lib/types/dsh-adapter/channel/composer-images.d.ts +5 -0
- package/lib/types/dsh-adapter/channel/composer-images.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/composer-images.js +4 -3
- package/lib/types/dsh-adapter/channel/core/actions.d.ts +39 -0
- package/lib/types/dsh-adapter/channel/core/actions.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/core/actions.js +152 -0
- package/lib/types/dsh-adapter/channel/core/binding-feed.d.ts +145 -0
- package/lib/types/dsh-adapter/channel/core/binding-feed.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/core/binding-feed.js +289 -0
- package/lib/types/dsh-adapter/channel/core/compose.d.ts +217 -0
- package/lib/types/dsh-adapter/channel/core/compose.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/core/compose.js +938 -0
- package/lib/types/dsh-adapter/channel/core/files.d.ts +57 -0
- package/lib/types/dsh-adapter/channel/core/files.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/core/files.js +45 -0
- package/lib/types/dsh-adapter/channel/core/host.d.ts +55 -0
- package/lib/types/dsh-adapter/channel/core/host.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/core/host.js +116 -0
- package/lib/types/dsh-adapter/channel/core/local-actions.d.ts +46 -0
- package/lib/types/dsh-adapter/channel/core/local-actions.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/core/local-actions.js +117 -0
- package/lib/types/dsh-adapter/channel/core/local-images.d.ts +20 -0
- package/lib/types/dsh-adapter/channel/core/local-images.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/core/local-images.js +147 -0
- package/lib/types/dsh-adapter/channel/core/reports.d.ts +12 -0
- package/lib/types/dsh-adapter/channel/core/reports.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/core/reports.js +77 -0
- package/lib/types/dsh-adapter/channel/core/session-controls.d.ts +39 -0
- package/lib/types/dsh-adapter/channel/core/session-controls.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/core/session-controls.js +219 -0
- package/lib/types/dsh-adapter/channel/core/session-switch.d.ts +174 -0
- package/lib/types/dsh-adapter/channel/core/session-switch.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/core/session-switch.js +390 -0
- package/lib/types/dsh-adapter/channel/core/sessions.d.ts +40 -0
- package/lib/types/dsh-adapter/channel/core/sessions.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/core/sessions.js +268 -0
- package/lib/types/dsh-adapter/channel/decisions.d.ts +4 -3
- package/lib/types/dsh-adapter/channel/decisions.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/decisions.js +4 -4
- package/lib/types/dsh-adapter/channel/emitter.d.ts +15 -2
- package/lib/types/dsh-adapter/channel/emitter.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/emitter.js +5 -3
- package/lib/types/dsh-adapter/channel/extensions.d.ts +36 -0
- package/lib/types/dsh-adapter/channel/extensions.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/extensions.js +714 -0
- package/lib/types/dsh-adapter/channel/ide-selection.d.ts +1 -10
- package/lib/types/dsh-adapter/channel/ide-selection.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/ide-selection.js +4 -46
- package/lib/types/dsh-adapter/channel/input-actions.d.ts +27 -4
- package/lib/types/dsh-adapter/channel/input-actions.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/input-actions.js +240 -21
- package/lib/types/dsh-adapter/channel/input-delivery.d.ts +21 -5
- package/lib/types/dsh-adapter/channel/input-delivery.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/input-delivery.js +65 -27
- package/lib/types/dsh-adapter/channel/local-actions.d.ts +10 -32
- package/lib/types/dsh-adapter/channel/local-actions.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/local-actions.js +10 -78
- package/lib/types/dsh-adapter/channel/local-fs.d.ts +3 -0
- package/lib/types/dsh-adapter/channel/local-fs.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/local-fs.js +46 -0
- package/lib/types/dsh-adapter/channel/mode-actions.d.ts +3 -3
- package/lib/types/dsh-adapter/channel/mode-actions.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/mode-permission-actions.d.ts +2 -2
- package/lib/types/dsh-adapter/channel/mode-permission-actions.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/model-actions.d.ts +3 -3
- package/lib/types/dsh-adapter/channel/model-actions.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/model-actions.js +38 -5
- package/lib/types/dsh-adapter/channel/model-switch.d.ts +2 -2
- package/lib/types/dsh-adapter/channel/model-switch.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/model-switch.js +9 -6
- package/lib/types/dsh-adapter/channel/preferences.d.ts +1 -1
- package/lib/types/dsh-adapter/channel/preferences.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/preferences.js +16 -0
- package/lib/types/dsh-adapter/channel/projection.d.ts +16 -13
- package/lib/types/dsh-adapter/channel/projection.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/projection.js +38 -1143
- package/lib/types/dsh-adapter/channel/question-record.d.ts +3 -75
- package/lib/types/dsh-adapter/channel/question-record.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/question-record.js +3 -107
- package/lib/types/dsh-adapter/channel/session-activity.d.ts +9 -0
- package/lib/types/dsh-adapter/channel/session-activity.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/session-activity.js +42 -0
- package/lib/types/dsh-adapter/channel/session-adoption.d.ts +4 -4
- package/lib/types/dsh-adapter/channel/session-adoption.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/session-adoption.js +3 -1
- package/lib/types/dsh-adapter/channel/session-fork.d.ts +1 -1
- package/lib/types/dsh-adapter/channel/session-fork.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/session-fork.js +2 -1
- package/lib/types/dsh-adapter/channel/session-live-adoption.d.ts +7 -3
- package/lib/types/dsh-adapter/channel/session-live-adoption.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/session-live-adoption.js +1 -1
- package/lib/types/dsh-adapter/channel/session-metadata.d.ts +2 -9
- package/lib/types/dsh-adapter/channel/session-metadata.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/session-reset.d.ts +1 -1
- package/lib/types/dsh-adapter/channel/session-reset.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/session-reset.js +4 -0
- package/lib/types/dsh-adapter/channel/session-resume.d.ts +5 -10
- package/lib/types/dsh-adapter/channel/session-resume.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/session-resume.js +74 -113
- package/lib/types/dsh-adapter/channel/session-rewind.d.ts +4 -4
- package/lib/types/dsh-adapter/channel/session-rewind.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/session-rewind.js +7 -6
- package/lib/types/dsh-adapter/channel/session-tree-actions.d.ts +4 -4
- package/lib/types/dsh-adapter/channel/session-tree-actions.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/session-tree-actions.js +8 -7
- package/lib/types/dsh-adapter/channel/settings-host.d.ts +1 -1
- package/lib/types/dsh-adapter/channel/settings-host.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/settings-host.js +8 -0
- package/lib/types/dsh-adapter/channel/skill-catalog.d.ts +5 -1
- package/lib/types/dsh-adapter/channel/skill-catalog.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/skill-catalog.js +2 -2
- package/lib/types/dsh-adapter/channel/state.d.ts +72 -1
- package/lib/types/dsh-adapter/channel/state.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/state.js +7 -3
- package/lib/types/dsh-adapter/channel/subagent-projection.d.ts +58 -3
- package/lib/types/dsh-adapter/channel/subagent-projection.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/subagent-projection.js +153 -9
- package/lib/types/dsh-adapter/channel/subagent-transcript.d.ts +114 -0
- package/lib/types/dsh-adapter/channel/subagent-transcript.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/subagent-transcript.js +279 -0
- package/lib/types/dsh-adapter/channel/transcript.d.ts +7 -15
- package/lib/types/dsh-adapter/channel/transcript.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/transcript.js +17 -21
- package/lib/types/dsh-adapter/channel/types.d.ts +16 -7
- package/lib/types/dsh-adapter/channel/types.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/usage.d.ts +3 -23
- package/lib/types/dsh-adapter/channel/usage.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/usage.js +5 -111
- package/lib/types/dsh-adapter/channel/workspace-actions.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel/workspace-actions.js +2 -1
- package/lib/types/dsh-adapter/channel.d.ts +17 -8
- package/lib/types/dsh-adapter/channel.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel.js +24 -1059
- package/lib/types/dsh-adapter/context-occupancy.d.ts +6 -1
- package/lib/types/dsh-adapter/context-occupancy.d.ts.map +1 -1
- package/lib/types/dsh-adapter/context-occupancy.js +6 -1
- package/lib/types/dsh-adapter/decision-guard.d.ts +24 -0
- package/lib/types/dsh-adapter/decision-guard.d.ts.map +1 -1
- package/lib/types/dsh-adapter/decision-guard.js +44 -0
- package/lib/types/dsh-adapter/extension-events.d.ts +4 -1
- package/lib/types/dsh-adapter/extension-events.d.ts.map +1 -1
- package/lib/types/dsh-adapter/extension-events.js +22 -10
- package/lib/types/dsh-adapter/index.d.ts +41 -3
- package/lib/types/dsh-adapter/index.d.ts.map +1 -1
- package/lib/types/dsh-adapter/index.js +28 -1
- package/lib/types/dsh-adapter/jobs.d.ts +5 -3
- package/lib/types/dsh-adapter/jobs.d.ts.map +1 -1
- package/lib/types/dsh-adapter/jobs.js +53 -14
- package/lib/types/dsh-adapter/migrate/parse/jsonl.d.ts +1 -16
- package/lib/types/dsh-adapter/migrate/parse/jsonl.d.ts.map +1 -1
- package/lib/types/dsh-adapter/migrate/parse/jsonl.js +3 -29
- package/lib/types/dsh-adapter/oauth-credential-source.d.ts +34 -0
- package/lib/types/dsh-adapter/oauth-credential-source.d.ts.map +1 -0
- package/lib/types/dsh-adapter/oauth-credential-source.js +66 -0
- package/lib/types/dsh-adapter/plugin.d.ts +38 -2
- package/lib/types/dsh-adapter/plugin.d.ts.map +1 -1
- package/lib/types/dsh-adapter/plugin.js +546 -110
- package/lib/types/dsh-adapter/provider-model-capabilities.d.ts +10 -0
- package/lib/types/dsh-adapter/provider-model-capabilities.d.ts.map +1 -0
- package/lib/types/dsh-adapter/provider-model-capabilities.js +80 -0
- package/lib/types/dsh-adapter/providerWizard.d.ts +8 -2
- package/lib/types/dsh-adapter/providerWizard.d.ts.map +1 -1
- package/lib/types/dsh-adapter/providerWizard.js +118 -52
- package/lib/types/dsh-adapter/questions.d.ts +29 -124
- package/lib/types/dsh-adapter/questions.d.ts.map +1 -1
- package/lib/types/dsh-adapter/questions.js +33 -267
- package/lib/types/dsh-adapter/recap.d.ts +3 -15
- package/lib/types/dsh-adapter/recap.d.ts.map +1 -1
- package/lib/types/dsh-adapter/recap.js +3 -46
- package/lib/types/dsh-adapter/sanitize.d.ts +4 -44
- package/lib/types/dsh-adapter/sanitize.d.ts.map +1 -1
- package/lib/types/dsh-adapter/sanitize.js +4 -84
- package/lib/types/dsh-adapter/session-mount-heartbeat.d.ts +3 -1
- package/lib/types/dsh-adapter/session-mount-heartbeat.d.ts.map +1 -1
- package/lib/types/dsh-adapter/session-mount-heartbeat.js +4 -2
- package/lib/types/dsh-adapter/sessions/digest.d.ts +18 -3
- package/lib/types/dsh-adapter/sessions/digest.d.ts.map +1 -1
- package/lib/types/dsh-adapter/sessions/digest.js +60 -27
- package/lib/types/dsh-adapter/sessions/list.d.ts.map +1 -1
- package/lib/types/dsh-adapter/sessions/list.js +6 -4
- package/lib/types/dsh-adapter/sessions/recovery.d.ts +2 -2
- package/lib/types/dsh-adapter/sessions/recovery.d.ts.map +1 -1
- package/lib/types/dsh-adapter/sessions/recovery.js +23 -14
- package/lib/types/dsh-adapter/sessions/store.d.ts +2 -0
- package/lib/types/dsh-adapter/sessions/store.d.ts.map +1 -1
- package/lib/types/dsh-adapter/sessions/store.js +1 -0
- package/lib/types/dsh-adapter/sessions/types.d.ts +2 -0
- package/lib/types/dsh-adapter/sessions/types.d.ts.map +1 -1
- package/lib/types/dsh-adapter/sideQuestion.d.ts.map +1 -1
- package/lib/types/dsh-adapter/sideQuestion.js +3 -13
- package/lib/types/dsh-adapter/subagents.d.ts.map +1 -1
- package/lib/types/dsh-adapter/subagents.js +7 -0
- package/lib/types/dsh-adapter/themes.d.ts +1 -1
- package/lib/types/dsh-adapter/themes.d.ts.map +1 -1
- package/lib/types/dsh-adapter/trajectory/agent-source.d.ts +84 -0
- package/lib/types/dsh-adapter/trajectory/agent-source.d.ts.map +1 -0
- package/lib/types/dsh-adapter/trajectory/agent-source.js +601 -0
- package/lib/types/dsh-adapter/trajectory/guards.d.ts +31 -1
- package/lib/types/dsh-adapter/trajectory/guards.d.ts.map +1 -1
- package/lib/types/dsh-adapter/trajectory/guards.js +28 -0
- package/lib/types/dsh-adapter/trajectory/index.d.ts +3 -1
- package/lib/types/dsh-adapter/trajectory/index.d.ts.map +1 -1
- package/lib/types/dsh-adapter/trajectory/index.js +1 -0
- package/lib/types/dsh-adapter/trajectory/inspect.d.ts +7 -0
- package/lib/types/dsh-adapter/trajectory/inspect.d.ts.map +1 -1
- package/lib/types/dsh-adapter/trajectory/inspect.js +70 -2
- package/lib/types/dsh-adapter/trajectory/projection.d.ts +4 -0
- package/lib/types/dsh-adapter/trajectory/projection.d.ts.map +1 -1
- package/lib/types/dsh-adapter/trajectory/projection.js +36 -0
- package/lib/types/dsh-adapter/trajectory/types.d.ts +13 -0
- package/lib/types/dsh-adapter/trajectory/types.d.ts.map +1 -1
- package/lib/types/effortPrefs.d.ts +7 -0
- package/lib/types/effortPrefs.d.ts.map +1 -1
- package/lib/types/effortPrefs.js +11 -2
- package/lib/types/handoffAck.d.ts +57 -0
- package/lib/types/handoffAck.d.ts.map +1 -0
- package/lib/types/handoffAck.js +154 -0
- package/lib/types/handoffEvents.d.ts +52 -0
- package/lib/types/handoffEvents.d.ts.map +1 -0
- package/lib/types/handoffEvents.js +128 -0
- package/lib/types/i18n.d.ts +3189 -68
- package/lib/types/i18n.d.ts.map +1 -1
- package/lib/types/i18n.js +855 -9
- package/lib/types/ink/colorize.d.ts.map +1 -1
- package/lib/types/ink/colorize.js +8 -2
- package/lib/types/ink/components/AlternateScreen.d.ts +12 -1
- package/lib/types/ink/components/AlternateScreen.d.ts.map +1 -1
- package/lib/types/ink/components/AlternateScreen.js +25 -4
- package/lib/types/ink/components/App.d.ts +5 -1
- package/lib/types/ink/components/App.d.ts.map +1 -1
- package/lib/types/ink/components/App.js +52 -5
- package/lib/types/ink/components/Image.d.ts +8 -1
- package/lib/types/ink/components/Image.d.ts.map +1 -1
- package/lib/types/ink/components/Image.js +2 -2
- package/lib/types/ink/components/Text.d.ts +8 -1
- package/lib/types/ink/components/Text.d.ts.map +1 -1
- package/lib/types/ink/components/Text.js +11 -1
- package/lib/types/ink/dom.d.ts.map +1 -1
- package/lib/types/ink/dom.js +75 -3
- package/lib/types/ink/hooks/use-input.d.ts.map +1 -1
- package/lib/types/ink/hooks/use-input.js +9 -4
- package/lib/types/ink/ink.d.ts.map +1 -1
- package/lib/types/ink/ink.js +8 -2
- package/lib/types/ink/kitty-graphics.d.ts +7 -2
- package/lib/types/ink/kitty-graphics.d.ts.map +1 -1
- package/lib/types/ink/kitty-graphics.js +15 -7
- package/lib/types/ink/node-cache.d.ts +15 -1
- package/lib/types/ink/node-cache.d.ts.map +1 -1
- package/lib/types/ink/node-cache.js +4 -1
- package/lib/types/ink/output.d.ts.map +1 -1
- package/lib/types/ink/output.js +2 -0
- package/lib/types/ink/parse-keypress.d.ts +13 -0
- package/lib/types/ink/parse-keypress.d.ts.map +1 -1
- package/lib/types/ink/parse-keypress.js +438 -19
- package/lib/types/ink/reconciler.d.ts.map +1 -1
- package/lib/types/ink/reconciler.js +9 -0
- package/lib/types/ink/render-node-to-output.d.ts.map +1 -1
- package/lib/types/ink/render-node-to-output.js +200 -4
- package/lib/types/ink/render-stats.d.ts +35 -0
- package/lib/types/ink/render-stats.d.ts.map +1 -0
- package/lib/types/ink/render-stats.js +53 -0
- package/lib/types/ink/sixel-codec.d.ts +11 -1
- package/lib/types/ink/sixel-codec.d.ts.map +1 -1
- package/lib/types/ink/sixel-codec.js +10 -3
- package/lib/types/ink/sixel-graphics.js +2 -2
- package/lib/types/ink/styles.d.ts +46 -0
- package/lib/types/ink/styles.d.ts.map +1 -1
- package/lib/types/ink/terminal-image.d.ts +7 -0
- package/lib/types/ink/terminal-image.d.ts.map +1 -1
- package/lib/types/ink/terminal-querier.d.ts +1 -1
- package/lib/types/ink/terminal-querier.js +4 -4
- package/lib/types/ink/text-decoration.d.ts +49 -0
- package/lib/types/ink/text-decoration.d.ts.map +1 -0
- package/lib/types/ink/text-decoration.js +235 -0
- package/lib/types/ink/update-overflow-guard.d.ts +9 -0
- package/lib/types/ink/update-overflow-guard.d.ts.map +1 -1
- package/lib/types/ink/update-overflow-guard.js +41 -0
- package/lib/types/ink/wrap-text.d.ts.map +1 -1
- package/lib/types/ink/wrap-text.js +5 -1
- package/lib/types/kernelPrefs.d.ts +51 -0
- package/lib/types/kernelPrefs.d.ts.map +1 -0
- package/lib/types/kernelPrefs.js +126 -0
- package/lib/types/modelRecents.d.ts +10 -2
- package/lib/types/modelRecents.d.ts.map +1 -1
- package/lib/types/modelRecents.js +20 -7
- package/lib/types/screens/AgentTranscriptScene.d.ts +42 -0
- package/lib/types/screens/AgentTranscriptScene.d.ts.map +1 -0
- package/lib/types/screens/AgentTranscriptScene.js +269 -0
- package/lib/types/screens/Chat.d.ts +45 -7
- package/lib/types/screens/Chat.d.ts.map +1 -1
- package/lib/types/screens/Chat.js +625 -113
- package/lib/types/screens/Launchpad.d.ts +24 -7
- package/lib/types/screens/Launchpad.d.ts.map +1 -1
- package/lib/types/screens/Launchpad.js +147 -28
- package/lib/types/screens/SessionSupervisor.d.ts +3 -3
- package/lib/types/screens/SessionSupervisor.d.ts.map +1 -1
- package/lib/types/screens/SessionSupervisor.js +69 -5
- package/lib/types/screens/Settings.d.ts.map +1 -1
- package/lib/types/screens/Settings.js +211 -7
- package/lib/types/screens/StatusLine.d.ts +40 -1
- package/lib/types/screens/StatusLine.d.ts.map +1 -1
- package/lib/types/screens/StatusLine.js +131 -19
- package/lib/types/screens/StatusMetrics.d.ts +53 -17
- package/lib/types/screens/StatusMetrics.d.ts.map +1 -1
- package/lib/types/screens/StatusMetrics.js +141 -30
- package/lib/types/screens/TrajectoryScene.d.ts.map +1 -1
- package/lib/types/screens/TrajectoryScene.js +74 -12
- package/lib/types/screens/chat/backendCommands.d.ts +37 -0
- package/lib/types/screens/chat/backendCommands.d.ts.map +1 -0
- package/lib/types/screens/chat/backendCommands.js +51 -0
- package/lib/types/screens/chat/useBackendChannels.d.ts +20 -0
- package/lib/types/screens/chat/useBackendChannels.d.ts.map +1 -0
- package/lib/types/screens/chat/useBackendChannels.js +117 -0
- package/lib/types/screens/chat/useKernelPicker.d.ts +23 -0
- package/lib/types/screens/chat/useKernelPicker.d.ts.map +1 -0
- package/lib/types/screens/chat/useKernelPicker.js +72 -0
- package/lib/types/screens/chatOverlay.d.ts +32 -2
- package/lib/types/screens/chatOverlay.d.ts.map +1 -1
- package/lib/types/screens/chatOverlay.js +9 -0
- package/lib/types/screens/sessionSupervisor/useForeignSessions.d.ts.map +1 -1
- package/lib/types/screens/sessionSupervisor/useForeignSessions.js +5 -1
- package/lib/types/screens/sessionSupervisor/useSessionSupervisor.d.ts +14 -0
- package/lib/types/screens/sessionSupervisor/useSessionSupervisor.d.ts.map +1 -1
- package/lib/types/screens/sessionSupervisor/useSessionSupervisor.js +97 -22
- package/lib/types/sessionHistory.d.ts +18 -1
- package/lib/types/sessionHistory.d.ts.map +1 -1
- package/lib/types/sessionHistory.js +46 -4
- package/lib/types/sessionPins.d.ts +7 -0
- package/lib/types/sessionPins.d.ts.map +1 -1
- package/lib/types/sessionPins.js +9 -0
- package/lib/types/sessions/resumeFailure.d.ts.map +1 -1
- package/lib/types/sessions/resumeFailure.js +2 -1
- package/lib/types/settings/definitions.d.ts +74 -0
- package/lib/types/settings/definitions.d.ts.map +1 -1
- package/lib/types/settings/definitions.js +50 -4
- package/lib/types/terminal-utils/hyperlink.d.ts +2 -2
- package/lib/types/terminal-utils/hyperlink.d.ts.map +1 -1
- package/lib/types/terminal-utils/hyperlink.js +21 -4
- package/lib/types/terminal-utils/markdown.d.ts +34 -6
- package/lib/types/terminal-utils/markdown.d.ts.map +1 -1
- package/lib/types/terminal-utils/markdown.js +257 -66
- package/lib/types/theme.d.ts +49 -8
- package/lib/types/theme.d.ts.map +1 -1
- package/lib/types/theme.js +514 -18
- package/lib/types/tips.js +2 -2
- package/lib/types/trajectory/effortIgnition.d.ts +25 -7
- package/lib/types/trajectory/effortIgnition.d.ts.map +1 -1
- package/lib/types/trajectory/effortIgnition.js +106 -34
- package/lib/types/trajectory/window.d.ts +26 -0
- package/lib/types/trajectory/window.d.ts.map +1 -0
- package/lib/types/trajectory/window.js +27 -0
- package/lib/types/tuiDisplayPrefs.d.ts +38 -1
- package/lib/types/tuiDisplayPrefs.d.ts.map +1 -1
- package/lib/types/tuiDisplayPrefs.js +45 -1
- package/lib/types/update.d.ts +88 -3
- package/lib/types/update.d.ts.map +1 -1
- package/lib/types/update.js +285 -18
- package/lib/types/utils/crashDetail.d.ts +56 -0
- package/lib/types/utils/crashDetail.d.ts.map +1 -0
- package/lib/types/utils/crashDetail.js +175 -0
- package/lib/types/utils/imageResize.d.ts +9 -23
- package/lib/types/utils/imageResize.d.ts.map +1 -1
- package/lib/types/utils/imageResize.js +24 -20
- package/lib/types/utils/inputPaste.d.ts +9 -8
- package/lib/types/utils/inputPaste.d.ts.map +1 -1
- package/lib/types/utils/inputPaste.js +53 -16
- package/lib/types/utils/jsonl.d.ts +24 -0
- package/lib/types/utils/jsonl.d.ts.map +1 -0
- package/lib/types/utils/jsonl.js +36 -0
- package/package.json +18 -2
|
@@ -0,0 +1,714 @@
|
|
|
1
|
+
import { t } from '../../i18n.js';
|
|
2
|
+
import { channelCapabilities } from '../../channel/capabilities.js';
|
|
3
|
+
import { isCommandCompletionToken, LOCAL_COMMANDS } from '../../commands.js';
|
|
4
|
+
import { touchSession } from '../../sessionHistory.js';
|
|
5
|
+
import { DEFAULT_SESSION_MODES, resolveSessionModes } from '../../sessionModes.js';
|
|
6
|
+
import { createDshSession } from '../backend/session.js';
|
|
7
|
+
import { createDshTranslator, dshPricingWindow } from '../backend/translate.js';
|
|
8
|
+
import { getHostMessageObserver } from '../message-observer.js';
|
|
9
|
+
import { createForeignBrowser } from '../migrate/browse.js';
|
|
10
|
+
import { listSummaries, noteBranch } from '../sessions/index.js';
|
|
11
|
+
import { createAgentViewProjection } from './agent-view-projection.js';
|
|
12
|
+
import { createBackgroundCurrentAction } from './background-action.js';
|
|
13
|
+
import { dshChannelBinding } from './binding.js';
|
|
14
|
+
import { createBindingEvents } from './binding-events.js';
|
|
15
|
+
import { agentCapabilityEvidence, annotateCommandCapabilities, resolveAgentCapabilities } from './capabilities.js';
|
|
16
|
+
import { channelCommands } from './commands.js';
|
|
17
|
+
import { createManualCompaction } from './compaction.js';
|
|
18
|
+
import { createExternalCommandInvoker } from './external-commands.js';
|
|
19
|
+
import { createJobProjection } from './job-projection.js';
|
|
20
|
+
import { createDetachedHandleFactory } from './lifetime-resources.js';
|
|
21
|
+
import { createLoadedContextRefresher } from './loaded-context.js';
|
|
22
|
+
import { createLocalActions } from './local-actions.js';
|
|
23
|
+
import { mentionAttachments } from './mentions.js';
|
|
24
|
+
import { createModelActions } from './model-actions.js';
|
|
25
|
+
import { createModelSwitchAction } from './model-switch.js';
|
|
26
|
+
import { createPermissionModeActions } from './mode-permission-actions.js';
|
|
27
|
+
import { createPermissionModeRoster } from './mode-roster.js';
|
|
28
|
+
import { legacyPermissionPresetSnapshot, permissionPresetSnapshotFromService, unavailablePermissionPresetSnapshot } from './permissions.js';
|
|
29
|
+
import { createReportActions } from './reports.js';
|
|
30
|
+
import { createRewindPromptAction } from './session-actions.js';
|
|
31
|
+
import { createSessionAdoption } from './session-adoption.js';
|
|
32
|
+
import { createForkSessionAction } from './session-fork.js';
|
|
33
|
+
import { createLiveAgentAdoption } from './session-live-adoption.js';
|
|
34
|
+
import { createSessionMetadataActions } from './session-metadata.js';
|
|
35
|
+
import { createSessionResumeActions } from './session-resume.js';
|
|
36
|
+
import { createRewindToAction } from './session-rewind.js';
|
|
37
|
+
import { createSessionTreeReader } from './session-tree.js';
|
|
38
|
+
import { createTreeRewindAction } from './session-tree-actions.js';
|
|
39
|
+
import { createSkillCatalog } from './skill-catalog.js';
|
|
40
|
+
import { createSubagentProjection } from './subagent-projection.js';
|
|
41
|
+
import { readChildTranscriptPage } from './subagent-transcript.js';
|
|
42
|
+
import { DSH_BACKEND_LABEL } from './state.js';
|
|
43
|
+
import { foldBack } from './transcript.js';
|
|
44
|
+
import { createWorkspaceActions } from './workspace-actions.js';
|
|
45
|
+
/**
|
|
46
|
+
* Read the persistence backend's full session list (empty without one). The
|
|
47
|
+
* agent view's "stopped" rows come from this snapshot.
|
|
48
|
+
*/
|
|
49
|
+
async function listSessionsSnapshot(ctx) {
|
|
50
|
+
const persistence = ctx.get('sessionPersistence');
|
|
51
|
+
if (!persistence)
|
|
52
|
+
return [];
|
|
53
|
+
return listSummaries(persistence);
|
|
54
|
+
}
|
|
55
|
+
/**
|
|
56
|
+
* Attach the DSH specialists to a core whose bound session is a DSH session.
|
|
57
|
+
* Called inside `createChannel`'s construction transaction: a throw here is
|
|
58
|
+
* rolled back by the caller through the core's owner.
|
|
59
|
+
*/
|
|
60
|
+
export function attachDshExtensions(core, ctx, initialNative, options) {
|
|
61
|
+
const { state, owner, rowIds, host, notify } = core;
|
|
62
|
+
const { workspaceService, commandTrees } = host;
|
|
63
|
+
const adapterRuntime = host.adapterRuntime;
|
|
64
|
+
// The DSH specialists read the binding through its DSH view (the bound
|
|
65
|
+
// session is a DSH session for this whole composition).
|
|
66
|
+
const binding = dshChannelBinding(core.binding);
|
|
67
|
+
/** The bound session's DSH escape hatch. */
|
|
68
|
+
const dshNative = () => {
|
|
69
|
+
const native = binding.session.capabilities.native.dsh;
|
|
70
|
+
if (native === undefined)
|
|
71
|
+
throw new Error('dsh-tui: the bound session is not a DSH session');
|
|
72
|
+
return native;
|
|
73
|
+
};
|
|
74
|
+
// Detached work (/fork and agent-view dispatch) is owned until a caller
|
|
75
|
+
// explicitly transfers the temporary handle to its destination ledger.
|
|
76
|
+
const createDetachedHandle = createDetachedHandleFactory(owner);
|
|
77
|
+
// Detached handles are a stable ledger shared with adoption actions. The
|
|
78
|
+
// agent-view factory itself starts only after the full state surface exists.
|
|
79
|
+
const backgroundHandles = new Map();
|
|
80
|
+
let backgroundCurrentAction;
|
|
81
|
+
let agentView;
|
|
82
|
+
// The DSH child transcript source (docs/dsh-child-transcript.md). Built
|
|
83
|
+
// only when the host composition serves session persistence at attach;
|
|
84
|
+
// without it there is no history method, so the shared transcript tab
|
|
85
|
+
// never renders for this session. Every dependency is re-resolved per
|
|
86
|
+
// call; the reader fences on the binding capture and closes its handle.
|
|
87
|
+
const lookupChild = (id) => {
|
|
88
|
+
const agents = ctx.get('agents');
|
|
89
|
+
return agents?.get(id);
|
|
90
|
+
};
|
|
91
|
+
const childTranscript = ctx.get('sessionPersistence') === undefined ? undefined : readChildTranscriptPage.bind(null, {
|
|
92
|
+
capture: () => {
|
|
93
|
+
const captured = binding.capture();
|
|
94
|
+
return { sessionId: String(captured.agent.session.id), generation: captured.generation, session: captured.session };
|
|
95
|
+
},
|
|
96
|
+
isCurrent: capture => binding.isCurrent({ session: capture.session, agent: binding.agent, generation: capture.generation }),
|
|
97
|
+
subagents: () => ctx.get('subagents'),
|
|
98
|
+
persistence: () => ctx.get('sessionPersistence'),
|
|
99
|
+
sessionsStore: () => ctx.get('sessions'),
|
|
100
|
+
lookupChild,
|
|
101
|
+
// A fresh translator per call, like backend/session.ts's `history()`,
|
|
102
|
+
// so the live translator's frame fence and open-call ledger stay
|
|
103
|
+
// untouched. The presenter scope is the parent agent: the child's own
|
|
104
|
+
// Agent cannot be loaded without resuming it, and a wrong-scope
|
|
105
|
+
// presenter only degrades a card to plain text.
|
|
106
|
+
createTranslator: () => createDshTranslator({
|
|
107
|
+
tools: () => ctx.get('tools'),
|
|
108
|
+
scope: () => binding.agent,
|
|
109
|
+
attachments: () => ctx.get('attachments'),
|
|
110
|
+
}),
|
|
111
|
+
ownerSignal: owner.signal,
|
|
112
|
+
});
|
|
113
|
+
// Subagent projection owns the child store, transcript row identity and
|
|
114
|
+
// stream batching. Transport subscriptions below only route scoped events.
|
|
115
|
+
const subagentProjection = createSubagentProjection(() => state, {
|
|
116
|
+
rowIds,
|
|
117
|
+
agent: () => binding.agent,
|
|
118
|
+
// The continuation service is an optional host plugin: the projection's
|
|
119
|
+
// message capability (direct prompt, catalog roster) exists only when the
|
|
120
|
+
// service and its methods do.
|
|
121
|
+
subagents: () => ctx.get('subagents'),
|
|
122
|
+
ownerSignal: owner.signal,
|
|
123
|
+
lookupChild,
|
|
124
|
+
...(childTranscript === undefined ? {} : { readChildTranscript: childTranscript }),
|
|
125
|
+
});
|
|
126
|
+
owner.own(() => subagentProjection.dispose());
|
|
127
|
+
// Job projection owns registry callbacks and transcript rows. The optional
|
|
128
|
+
// service attachment has no authority after its injected lifetime ends.
|
|
129
|
+
const jobProjection = createJobProjection(() => state, {
|
|
130
|
+
owner, notify: (...args) => notify(...args), rowIds, agent: () => binding.agent, steer: text => channelCommands(state).steer(text),
|
|
131
|
+
});
|
|
132
|
+
// The DSH slash-command registry (optional service): /plan, /goal and
|
|
133
|
+
// friends register here; the TUI merges their descriptors into the slash
|
|
134
|
+
// menu and dispatches through `execute`.
|
|
135
|
+
const commandService = ctx.get('commands');
|
|
136
|
+
// messages.observe broker (optional service, C-042): absent the plugin-host
|
|
137
|
+
// row, publish is a no-op (soft degradation, #183).
|
|
138
|
+
const messageObserver = getHostMessageObserver(ctx.get('tuiMessageObserver'));
|
|
139
|
+
// Shift+Tab session-mode cycle: cordis.yml `modes` wins; absent/empty/
|
|
140
|
+
// atom-less → the built-in default/plan/full cycle (sessionModes.ts).
|
|
141
|
+
// Configured entries may additionally pin a durable `permission` preset
|
|
142
|
+
// identity (permission + plan allowed; permission + sandbox/approval is
|
|
143
|
+
// contradictory and dropped with a warning).
|
|
144
|
+
const { modes: resolvedConfiguredSessionModes, dropped: droppedModeIds } = resolveSessionModes(options.modes);
|
|
145
|
+
const filteredConfiguredSessionModes = resolvedConfiguredSessionModes
|
|
146
|
+
.filter(spec => spec.permission === undefined || isCommandCompletionToken(spec.permission));
|
|
147
|
+
const configuredSessionModes = filteredConfiguredSessionModes.length > 0
|
|
148
|
+
? filteredConfiguredSessionModes
|
|
149
|
+
: DEFAULT_SESSION_MODES;
|
|
150
|
+
if (droppedModeIds.length > 0) {
|
|
151
|
+
ctx.logger.warn(`dsh-tui: session modes ${droppedModeIds.map(id => `"${id}"`).join(', ')} declare no plan/sandbox/approval/permission atom; dropped from the Shift+Tab cycle`);
|
|
152
|
+
}
|
|
153
|
+
// Runtime permission roster: third-party presets enter the Shift+Tab cycle
|
|
154
|
+
// after the configured/default modes, rebuilt from the live service snapshot.
|
|
155
|
+
const permissionRoster = createPermissionModeRoster(ctx, {
|
|
156
|
+
configuredModes: configuredSessionModes,
|
|
157
|
+
agent: () => binding.agent,
|
|
158
|
+
warn: message => ctx.logger.warn(message),
|
|
159
|
+
});
|
|
160
|
+
const sessionModes = permissionRoster.modes;
|
|
161
|
+
// ── the DSH session's view of the common state ─────────────────────────
|
|
162
|
+
const initialSession = binding.session;
|
|
163
|
+
state.agentId = binding.agent.id;
|
|
164
|
+
state.sessionId = binding.agent.session.id;
|
|
165
|
+
state.mode = sessionModes[0];
|
|
166
|
+
// A DSH session supports everything the TUI offers.
|
|
167
|
+
state.backendCapabilities = channelCapabilities({
|
|
168
|
+
backendId: initialSession.ref.backendId,
|
|
169
|
+
backendLabel: options.backendLabel ?? DSH_BACKEND_LABEL,
|
|
170
|
+
capabilities: initialSession.capabilities,
|
|
171
|
+
dsh: true,
|
|
172
|
+
});
|
|
173
|
+
// Capability facts for the bound agent (channel/capabilities.ts). Reads are
|
|
174
|
+
// service lookups, so both consumers may call it freely: the public
|
|
175
|
+
// `capabilities()` accessor and the command-list annotation below.
|
|
176
|
+
const capabilitiesOf = () => resolveAgentCapabilities(agentCapabilityEvidence(ctx, binding.agent));
|
|
177
|
+
// Annotated from the start: Help and `/` completion read `commandList`
|
|
178
|
+
// before the first skill-catalog refresh publishes a new one, and a command
|
|
179
|
+
// whose capability is missing must never look usable in that window.
|
|
180
|
+
state.commandList = annotateCommandCapabilities(LOCAL_COMMANDS, capabilitiesOf());
|
|
181
|
+
Object.defineProperty(state, 'autoRecapOnOpen', {
|
|
182
|
+
configurable: true,
|
|
183
|
+
enumerable: true,
|
|
184
|
+
get() {
|
|
185
|
+
const settings = ctx.get('settings');
|
|
186
|
+
if (settings === undefined)
|
|
187
|
+
return false;
|
|
188
|
+
const ns = settings.describe({ redactSecrets: true }).find(entry => entry.ns === state.settingsNamespace);
|
|
189
|
+
return ns?.value?.recapOnOpen !== false;
|
|
190
|
+
},
|
|
191
|
+
});
|
|
192
|
+
state.subagentControl = subagentProjection.control;
|
|
193
|
+
state.jobControl = jobProjection.control;
|
|
194
|
+
/**
|
|
195
|
+
* The `tui/rewind-prompt` decision event (pi's `session_before_fork`):
|
|
196
|
+
* fired when the rewind picker confirms a message, before any fork work.
|
|
197
|
+
* The first answering plugin may cancel the rewind or offer extra modes
|
|
198
|
+
* rendered in the confirm pane.
|
|
199
|
+
*/
|
|
200
|
+
state.promptRewind = createRewindPromptAction(ctx, {
|
|
201
|
+
agent: () => binding.agent,
|
|
202
|
+
state: () => state,
|
|
203
|
+
withDecisionPending: core.input.withDecisionPending,
|
|
204
|
+
notify,
|
|
205
|
+
});
|
|
206
|
+
state.buildSessionTree = createSessionTreeReader(ctx, binding, () => state.cwd, (...args) => notify(...args), owner);
|
|
207
|
+
state.permissionPresets = () => {
|
|
208
|
+
let service;
|
|
209
|
+
try {
|
|
210
|
+
service = ctx.get('permissionPresets');
|
|
211
|
+
}
|
|
212
|
+
catch {
|
|
213
|
+
return unavailablePermissionPresetSnapshot();
|
|
214
|
+
}
|
|
215
|
+
if (service === undefined)
|
|
216
|
+
return legacyPermissionPresetSnapshot(state.mode.sandbox);
|
|
217
|
+
return permissionPresetSnapshotFromService(service, binding.agent.session);
|
|
218
|
+
};
|
|
219
|
+
// Immutable per-append snapshot (dsh-session caches the frozen array);
|
|
220
|
+
// reads follow session swaps (/resume /rewind /new) automatically.
|
|
221
|
+
state.traceEvents = () => dshNative().rawHistory();
|
|
222
|
+
// Trajectory availability for DSH: the raw log is always mounted, so the
|
|
223
|
+
// report is 'empty' until the session logs its first event and
|
|
224
|
+
// 'supported' after. Read per call over the same cached snapshot, so it
|
|
225
|
+
// follows session swaps and appends with no extra bookkeeping.
|
|
226
|
+
state.trajectorySource = () => (dshNative().rawHistory().length === 0 ? 'empty' : 'supported');
|
|
227
|
+
// The source label names what feeds the trajectory: the raw DSH session
|
|
228
|
+
// log, not the AgentEvent fold the core would otherwise mount.
|
|
229
|
+
state.trajectoryBackendLabel = () => t('trajectory-backend-dsh');
|
|
230
|
+
// The DSH log restores folded rows; the projector prices by the DeepSeek
|
|
231
|
+
// rate window and feeds the job registry. Installed before the seed replay.
|
|
232
|
+
const dshLocal = createLocalActions({
|
|
233
|
+
ctx,
|
|
234
|
+
owner,
|
|
235
|
+
binding,
|
|
236
|
+
state,
|
|
237
|
+
// Fold restore re-derives views with the bound session's presenters.
|
|
238
|
+
presenters: {
|
|
239
|
+
call: (name, rawArgs) => dshNative().presentCallView(name, rawArgs),
|
|
240
|
+
result: (name, rawArgs, data) => dshNative().presentResultView(name, rawArgs, data),
|
|
241
|
+
},
|
|
242
|
+
foldBack,
|
|
243
|
+
});
|
|
244
|
+
core.extend({
|
|
245
|
+
// Stale detection follows the agent: session wrappers are recreated per
|
|
246
|
+
// adoption, and switching A to B and back to A is the same conversation.
|
|
247
|
+
conversationKey: session => session.capabilities.native.dsh?.agent ?? session,
|
|
248
|
+
flushDeferred: () => subagentProjection.flush(),
|
|
249
|
+
loadOlder: dshLocal.loadOlder,
|
|
250
|
+
// Subagents and jobs come from the DSH host services (projections above).
|
|
251
|
+
ownsActivity: true,
|
|
252
|
+
// The DSH raw history is the trajectory source (state.traceEvents /
|
|
253
|
+
// trajectorySource are replaced above); the core's AgentEvent fold
|
|
254
|
+
// would only duplicate it.
|
|
255
|
+
ownsTrajectory: true,
|
|
256
|
+
// The DSH workspace may be remote: no local-disk stand-in for `fs`.
|
|
257
|
+
localFs: false,
|
|
258
|
+
dropRows: () => {
|
|
259
|
+
subagentProjection.dropRows();
|
|
260
|
+
jobProjection.dropRows();
|
|
261
|
+
},
|
|
262
|
+
touchSession: sessionId => { touchSession(sessionId); },
|
|
263
|
+
// A session log records no branch; note it so the browser can show it.
|
|
264
|
+
noteBranch: branch => { noteBranch(binding.agent.session.id, branch); },
|
|
265
|
+
// `ChannelUi.capabilities()`: the agent's composition facts.
|
|
266
|
+
agentCapabilities: capabilitiesOf,
|
|
267
|
+
});
|
|
268
|
+
core.feed.configureProjection({ jobs: jobProjection.store, pricingWindow: dshPricingWindow });
|
|
269
|
+
const resetProjection = core.feed.resetProjection;
|
|
270
|
+
const projector = core.feed.projector;
|
|
271
|
+
// Model selection is installed by bind; route/effort state is owned by model-actions.
|
|
272
|
+
const selection = { current: undefined, assembled: undefined };
|
|
273
|
+
// Registry command policy and rc.8 image encoding are an owner-scoped module.
|
|
274
|
+
const externalCommands = createExternalCommandInvoker(ctx, {
|
|
275
|
+
commandService,
|
|
276
|
+
runtime: adapterRuntime,
|
|
277
|
+
agent: () => binding.agent,
|
|
278
|
+
capture: () => binding.capture(),
|
|
279
|
+
bindingCurrent: capture => binding.isCurrent(capture),
|
|
280
|
+
allows: (subject, permission, scope) => host.currentGrantStore().allows(subject, permission, scope),
|
|
281
|
+
composer: core.composer,
|
|
282
|
+
attachments: () => mentionAttachments(ctx),
|
|
283
|
+
notify: (...args) => notify(...args),
|
|
284
|
+
});
|
|
285
|
+
const executeRegistryCommand = externalCommands.invokeText;
|
|
286
|
+
// Session actions close over these inert placeholders; they are installed
|
|
287
|
+
// below, before the channel starts.
|
|
288
|
+
let settleManualCompaction;
|
|
289
|
+
let resumeInto;
|
|
290
|
+
let adoptLiveAgent;
|
|
291
|
+
let rewindToNodeAction;
|
|
292
|
+
// Agent-view is activated after the complete state/action surface exists:
|
|
293
|
+
// no roster callback or persistence continuation can observe an unbound UI.
|
|
294
|
+
agentView = createAgentViewProjection(ctx, {
|
|
295
|
+
owner, binding, cwd: () => state.cwd,
|
|
296
|
+
configuredPreset: options.configuredPreset,
|
|
297
|
+
configuredProvider: options.configuredProvider,
|
|
298
|
+
configuredModel: options.configuredModel,
|
|
299
|
+
provider: options.provider, model: options.model,
|
|
300
|
+
notify,
|
|
301
|
+
listPersisted: () => listSessionsSnapshot(ctx),
|
|
302
|
+
createDetached: createDetachedHandle,
|
|
303
|
+
sessionSwitchVetoed: (kind, sessionId) => core.sessionSwitch.sessionSwitchVetoed(kind, sessionId),
|
|
304
|
+
adoptLive: target => adoptLiveAgent(target),
|
|
305
|
+
resumeInto: (sessionId, kind, keepCurrent) => resumeInto(sessionId, kind, keepCurrent),
|
|
306
|
+
backgroundCurrent: () => backgroundCurrentAction(),
|
|
307
|
+
backgroundHandles,
|
|
308
|
+
});
|
|
309
|
+
// The injection callback may synchronously publish its initial list, so it
|
|
310
|
+
// is installed only after the full action surface is ready (start).
|
|
311
|
+
const startJobs = () => {
|
|
312
|
+
if (typeof ctx.inject === 'function') {
|
|
313
|
+
ctx.inject(['jobs'], jobsCtx => {
|
|
314
|
+
jobProjection.attach(jobsCtx.jobs, dispose => jobsCtx.effect(() => dispose));
|
|
315
|
+
});
|
|
316
|
+
}
|
|
317
|
+
else {
|
|
318
|
+
jobProjection.attach(ctx.get?.('jobs'));
|
|
319
|
+
}
|
|
320
|
+
};
|
|
321
|
+
// Catalog/context services own their caches, registrations and async origin fences.
|
|
322
|
+
const skillCatalog = createSkillCatalog(ctx, {
|
|
323
|
+
owner,
|
|
324
|
+
commandService,
|
|
325
|
+
agent: () => binding.agent,
|
|
326
|
+
cwd: () => state.cwd,
|
|
327
|
+
setCommands(commands) {
|
|
328
|
+
// Annotate before publishing: Help and `/` completion both read
|
|
329
|
+
// `commandList`, so a command whose capability is missing says so
|
|
330
|
+
// instead of looking usable and failing on use.
|
|
331
|
+
state.commandList = annotateCommandCapabilities(commands, capabilitiesOf());
|
|
332
|
+
state.emit();
|
|
333
|
+
},
|
|
334
|
+
commandDescriptions: name => commandTrees?.descriptions(name),
|
|
335
|
+
// A skill gesture typed mid-turn stays immediate (steer at the next step
|
|
336
|
+
// boundary) instead of degrading into a turn-end followup (issue #1072).
|
|
337
|
+
working: () => state.working,
|
|
338
|
+
// Attached-context pass-through: the skill catalog never loses the
|
|
339
|
+
// FIFO/decision fence.
|
|
340
|
+
deliverUserText: (text, placement, attach) => core.input.deliverUserText(text, placement, [], attach),
|
|
341
|
+
});
|
|
342
|
+
const { viewOptions: skillViewOptions, registryFor: skillRegistryFor, refreshCommands: refreshCommandList, refreshSkillCommands } = skillCatalog;
|
|
343
|
+
// Each helper captures binding/cwd at invocation, rather than receiving a
|
|
344
|
+
// root-state bag. Its late completions are rejected by owner + binding.
|
|
345
|
+
const reportActions = createReportActions(ctx, {
|
|
346
|
+
owner,
|
|
347
|
+
capture: () => binding.capture(),
|
|
348
|
+
current: capture => binding.isCurrent(capture),
|
|
349
|
+
cwd: () => state.cwd,
|
|
350
|
+
model: () => state.model,
|
|
351
|
+
provider: () => options.provider,
|
|
352
|
+
contextWindow: () => state.contextWindow,
|
|
353
|
+
sessionTitle: () => state.sessionTitle,
|
|
354
|
+
runtime: adapterRuntime,
|
|
355
|
+
grantStore: host.currentGrantStore,
|
|
356
|
+
});
|
|
357
|
+
const foreignBrowser = createForeignBrowser(() => ctx.get('sessionPersistence'), owner.signal);
|
|
358
|
+
const sessionMetadataActions = createSessionMetadataActions(ctx, {
|
|
359
|
+
owner,
|
|
360
|
+
binding,
|
|
361
|
+
provider: () => state.provider,
|
|
362
|
+
model: () => state.model,
|
|
363
|
+
emit: () => state.emit(),
|
|
364
|
+
sessionTitle: () => state.sessionTitle,
|
|
365
|
+
setSessionTitle: title => { state.sessionTitle = title; },
|
|
366
|
+
setSessionColor: color => { state.sessionColor = color; },
|
|
367
|
+
forgetAgentView: sessionId => agentView.forget(sessionId),
|
|
368
|
+
setPersistedSessions: rows => agentView.setPersisted(rows),
|
|
369
|
+
skillRegistryFor,
|
|
370
|
+
skillViewOptions,
|
|
371
|
+
});
|
|
372
|
+
const loadedContext = createLoadedContextRefresher(ctx, {
|
|
373
|
+
owner,
|
|
374
|
+
agent: () => binding.agent,
|
|
375
|
+
cwd: () => state.cwd,
|
|
376
|
+
skillRegistryFor,
|
|
377
|
+
skillViewOptions,
|
|
378
|
+
publish(context) { state.loadedContext = context; state.emit(); },
|
|
379
|
+
});
|
|
380
|
+
const refreshLoadedContext = loadedContext.refresh;
|
|
381
|
+
// Replay the durable transcript first, then follow live events. The same
|
|
382
|
+
// seed re-populates the subagent dashboard's durable discovery facts
|
|
383
|
+
// (`subagent/catalog`, workflow member edges) so a resumed session keeps
|
|
384
|
+
// its dispatched-children history (issue #966). The seed is translated
|
|
385
|
+
// synchronously by the bound session (adoption tails replay inside a
|
|
386
|
+
// synchronous binding transaction, which the async `history()` cannot
|
|
387
|
+
// serve); callers have already bound the session the seed belongs to.
|
|
388
|
+
const replaySessionSeed = (events) => {
|
|
389
|
+
projector.apply(dshNative().translateReplay(events), { replay: true });
|
|
390
|
+
subagentProjection.bootstrapFromLog(events);
|
|
391
|
+
};
|
|
392
|
+
replaySessionSeed(initialNative.rawHistory());
|
|
393
|
+
projector.settleStreaming();
|
|
394
|
+
// Attached to an idle agent: any replayed turn/start belongs to a previous
|
|
395
|
+
// session run, so the spinner must not come up on boot.
|
|
396
|
+
state.working = false;
|
|
397
|
+
state.cancelPending = false;
|
|
398
|
+
state.status = binding.agent.status;
|
|
399
|
+
state.emit();
|
|
400
|
+
const modelActions = createModelActions(ctx, state, {
|
|
401
|
+
owner,
|
|
402
|
+
binding,
|
|
403
|
+
selection,
|
|
404
|
+
initialEffort: options.effort,
|
|
405
|
+
agent: () => binding.agent,
|
|
406
|
+
notify,
|
|
407
|
+
checkContextWarning: core.bookkeeping.checkContextWarning,
|
|
408
|
+
});
|
|
409
|
+
// The first bind (start) and every adoption tail bind through the core
|
|
410
|
+
// feed, which runs the DSH binding-events hooks below.
|
|
411
|
+
const bindAgent = () => { core.feed.bind(); };
|
|
412
|
+
const clearStagedImages = core.input.clearStagedImages;
|
|
413
|
+
const switchModelAction = createModelSwitchAction(ctx, state, {
|
|
414
|
+
owner,
|
|
415
|
+
binding,
|
|
416
|
+
rowIds,
|
|
417
|
+
// Compaction is installed below before the channel binds or exposes input.
|
|
418
|
+
settleCompaction: () => settleManualCompaction(),
|
|
419
|
+
resetProjector: resetProjection,
|
|
420
|
+
resetSubagents: subagentProjection.reset,
|
|
421
|
+
resetJobs: jobProjection.reset,
|
|
422
|
+
replay: replaySessionSeed,
|
|
423
|
+
settleReplay: projector.settleStreaming,
|
|
424
|
+
bindAgent: () => bindAgent(),
|
|
425
|
+
refreshCommands: refreshCommandList,
|
|
426
|
+
refreshLoadedContext,
|
|
427
|
+
refreshSkillCommands,
|
|
428
|
+
clearStagedImages,
|
|
429
|
+
dropModelCompletion: () => modelActions.dropModelNodeCache(),
|
|
430
|
+
notify,
|
|
431
|
+
});
|
|
432
|
+
const workspaceActions = createWorkspaceActions(state, {
|
|
433
|
+
owner,
|
|
434
|
+
service: workspaceService,
|
|
435
|
+
// The guarded workspace handoff: the core's `/new` over this session's
|
|
436
|
+
// DSH create path, with the target cwd.
|
|
437
|
+
newSession: target => core.sessionSwitch.newSession(target),
|
|
438
|
+
refreshGitBranch: () => core.refreshGitBranch(),
|
|
439
|
+
notify,
|
|
440
|
+
});
|
|
441
|
+
// This is the one necessary cyclic seam: mode actions need the completed
|
|
442
|
+
// state, while the state exposes their command surface. It is assigned
|
|
443
|
+
// before the channel starts binding/session observation.
|
|
444
|
+
const modeActions = createPermissionModeActions(ctx, state, {
|
|
445
|
+
owner,
|
|
446
|
+
runtime: adapterRuntime,
|
|
447
|
+
binding,
|
|
448
|
+
sessionModes,
|
|
449
|
+
roster: permissionRoster,
|
|
450
|
+
commandService,
|
|
451
|
+
executeRegistryCommand,
|
|
452
|
+
notify,
|
|
453
|
+
});
|
|
454
|
+
// Event subscription routing is a distinct binding owner. Its hooks run in
|
|
455
|
+
// every core bind: owner-level child listeners once, then per binding the
|
|
456
|
+
// activity seed, the model selection waterfalls and the raw subscribers.
|
|
457
|
+
const bindingEvents = createBindingEvents(ctx, {
|
|
458
|
+
owner,
|
|
459
|
+
binding,
|
|
460
|
+
state,
|
|
461
|
+
seedActivity: options.seedActivity,
|
|
462
|
+
seedContextOccupancy: options.seedContextOccupancy,
|
|
463
|
+
inputConvergence: core.inputConvergence,
|
|
464
|
+
selection,
|
|
465
|
+
modelActions,
|
|
466
|
+
modeActions,
|
|
467
|
+
projector,
|
|
468
|
+
subagents: subagentProjection,
|
|
469
|
+
agentView,
|
|
470
|
+
messageObserver,
|
|
471
|
+
retireAttachment: core.input.retireAttachment,
|
|
472
|
+
});
|
|
473
|
+
const sessionAdoption = createSessionAdoption(state, {
|
|
474
|
+
binding,
|
|
475
|
+
rowIds,
|
|
476
|
+
resetProjector: resetProjection,
|
|
477
|
+
resetSubagents: subagentProjection.reset,
|
|
478
|
+
resetJobs: jobProjection.reset,
|
|
479
|
+
replay: replaySessionSeed,
|
|
480
|
+
settleReplay: projector.settleStreaming,
|
|
481
|
+
bindAgent,
|
|
482
|
+
refreshCommands: refreshCommandList,
|
|
483
|
+
refreshLoadedContext,
|
|
484
|
+
refreshSkillCommands,
|
|
485
|
+
clearStagedImages,
|
|
486
|
+
touchSession,
|
|
487
|
+
});
|
|
488
|
+
const adoptForkedAgent = sessionAdoption.adoptForkedAgent;
|
|
489
|
+
adoptLiveAgent = createLiveAgentAdoption(state, {
|
|
490
|
+
binding,
|
|
491
|
+
openSession: (agent, handle) => createDshSession(ctx, { agent, handle }),
|
|
492
|
+
backgroundHandles,
|
|
493
|
+
rowIds,
|
|
494
|
+
resetProjector: resetProjection,
|
|
495
|
+
resetSubagents: subagentProjection.reset,
|
|
496
|
+
restoreSubagents: subagentProjection.restore,
|
|
497
|
+
parkSubagents: subagentProjection.park,
|
|
498
|
+
resetJobs: jobProjection.reset,
|
|
499
|
+
replay: replaySessionSeed,
|
|
500
|
+
settleReplay: projector.settleStreaming,
|
|
501
|
+
describeWorkspace: cwd => workspaceService.describe(cwd),
|
|
502
|
+
refreshGitBranch: () => core.refreshGitBranch(),
|
|
503
|
+
bindAgent,
|
|
504
|
+
refreshCommands: refreshCommandList,
|
|
505
|
+
refreshLoadedContext,
|
|
506
|
+
refreshSkillCommands,
|
|
507
|
+
clearStagedImages,
|
|
508
|
+
resetIdeSelection: core.resetIdeSelection,
|
|
509
|
+
notifySessionSwitched: core.sessionSwitch.notifySessionSwitched,
|
|
510
|
+
notifyAgentView: agentView.notify,
|
|
511
|
+
});
|
|
512
|
+
const resumeActions = createSessionResumeActions(ctx, state, {
|
|
513
|
+
configuredPreset: options.configuredPreset,
|
|
514
|
+
configuredProvider: options.configuredProvider,
|
|
515
|
+
configuredModel: options.configuredModel,
|
|
516
|
+
provider: options.provider,
|
|
517
|
+
model: options.model,
|
|
518
|
+
}, {
|
|
519
|
+
owner,
|
|
520
|
+
binding,
|
|
521
|
+
// `/resume` shares the live-adoption path with the session supervisor, so
|
|
522
|
+
// a target already running in this process is re-attached rather than
|
|
523
|
+
// resumed twice from its log (which would mount one log in two places).
|
|
524
|
+
adoptLive: target => adoptLiveAgent(target),
|
|
525
|
+
parkSubagents: subagentProjection.park,
|
|
526
|
+
backgroundHandles,
|
|
527
|
+
rowIds,
|
|
528
|
+
resetProjector: resetProjection,
|
|
529
|
+
resetSubagents: subagentProjection.reset,
|
|
530
|
+
resetJobs: jobProjection.reset,
|
|
531
|
+
replay: replaySessionSeed,
|
|
532
|
+
settleReplay: projector.settleStreaming,
|
|
533
|
+
describeWorkspace: cwd => workspaceService.describe(cwd),
|
|
534
|
+
refreshGitBranch: () => core.refreshGitBranch(),
|
|
535
|
+
bindAgent,
|
|
536
|
+
refreshCommands: refreshCommandList,
|
|
537
|
+
refreshLoadedContext,
|
|
538
|
+
refreshSkillCommands,
|
|
539
|
+
clearStagedImages,
|
|
540
|
+
resetIdeSelection: core.resetIdeSelection,
|
|
541
|
+
settleCompaction: () => settleManualCompaction(),
|
|
542
|
+
sessionSwitchVetoed: core.sessionSwitch.sessionSwitchVetoed,
|
|
543
|
+
notify,
|
|
544
|
+
notifySessionSwitched: core.sessionSwitch.notifySessionSwitched,
|
|
545
|
+
runtime: adapterRuntime,
|
|
546
|
+
});
|
|
547
|
+
resumeInto = resumeActions.resumeInto;
|
|
548
|
+
rewindToNodeAction = createTreeRewindAction(ctx, state, {
|
|
549
|
+
owner,
|
|
550
|
+
binding,
|
|
551
|
+
settleCompaction: () => settleManualCompaction(),
|
|
552
|
+
notify,
|
|
553
|
+
adoptForkedAgent,
|
|
554
|
+
notifySessionSwitched: core.sessionSwitch.notifySessionSwitched,
|
|
555
|
+
});
|
|
556
|
+
const rewindToAction = createRewindToAction(ctx, state, {
|
|
557
|
+
owner,
|
|
558
|
+
binding,
|
|
559
|
+
settleCompaction: () => settleManualCompaction(),
|
|
560
|
+
notify,
|
|
561
|
+
adoptForkedAgent,
|
|
562
|
+
notifySessionSwitched: core.sessionSwitch.notifySessionSwitched,
|
|
563
|
+
});
|
|
564
|
+
const forkSessionAction = createForkSessionAction(ctx, state, {
|
|
565
|
+
owner,
|
|
566
|
+
settleCompaction: () => settleManualCompaction(),
|
|
567
|
+
notify,
|
|
568
|
+
source: () => binding.agent.session,
|
|
569
|
+
createDetachedHandle,
|
|
570
|
+
});
|
|
571
|
+
const manualCompaction = createManualCompaction(ctx, state, {
|
|
572
|
+
owner,
|
|
573
|
+
agent: () => binding.agent,
|
|
574
|
+
withDecisionPending: core.input.withDecisionPending,
|
|
575
|
+
notify,
|
|
576
|
+
});
|
|
577
|
+
settleManualCompaction = manualCompaction.settle;
|
|
578
|
+
backgroundCurrentAction = createBackgroundCurrentAction(ctx, state, {
|
|
579
|
+
configuredPreset: options.configuredPreset,
|
|
580
|
+
configuredProvider: options.configuredProvider,
|
|
581
|
+
configuredModel: options.configuredModel,
|
|
582
|
+
provider: options.provider,
|
|
583
|
+
model: options.model,
|
|
584
|
+
}, {
|
|
585
|
+
owner,
|
|
586
|
+
binding,
|
|
587
|
+
backgroundHandles,
|
|
588
|
+
rowIds,
|
|
589
|
+
resetProjector: resetProjection,
|
|
590
|
+
resetSubagents: subagentProjection.reset,
|
|
591
|
+
parkSubagents: subagentProjection.park,
|
|
592
|
+
resetJobs: jobProjection.reset,
|
|
593
|
+
refreshEffortLevels: () => modelActions.refreshEffortLevels(),
|
|
594
|
+
bindAgent,
|
|
595
|
+
refreshCommands: refreshCommandList,
|
|
596
|
+
refreshLoadedContext,
|
|
597
|
+
refreshSkillCommands,
|
|
598
|
+
clearStagedImages,
|
|
599
|
+
notifySessionSwitched: core.sessionSwitch.notifySessionSwitched,
|
|
600
|
+
notify: (...args) => notify(...args),
|
|
601
|
+
notifyAgentView: agentView.notify,
|
|
602
|
+
});
|
|
603
|
+
// Every action a DSH session serves beyond the core's (the type keeps this
|
|
604
|
+
// table complete: a new public action must be placed on one side).
|
|
605
|
+
const delegates = {
|
|
606
|
+
runPermissionPreset: modeActions.runPermissionPreset,
|
|
607
|
+
rewindTo: rewindToAction,
|
|
608
|
+
rewindToNode: rewindToNodeAction,
|
|
609
|
+
forkSession: forkSessionAction,
|
|
610
|
+
resumeTo: resumeActions.resumeTo,
|
|
611
|
+
listWorkspaces: workspaceActions.listWorkspaces,
|
|
612
|
+
listWorkspaceRegistry: workspaceActions.listWorkspaceRegistry,
|
|
613
|
+
removeWorkspace: workspaceActions.removeWorkspace,
|
|
614
|
+
renameWorkspaceAt: workspaceActions.renameWorkspaceAt,
|
|
615
|
+
resolveWorkspace: workspaceActions.resolveWorkspace,
|
|
616
|
+
switchWorkspace: workspaceActions.switchWorkspace,
|
|
617
|
+
renameWorkspace: workspaceActions.renameWorkspace,
|
|
618
|
+
workspaceCommands: workspaceActions.workspaceCommands,
|
|
619
|
+
runWorkspaceCommand: workspaceActions.runWorkspaceCommand,
|
|
620
|
+
switchModel: switchModelAction,
|
|
621
|
+
listEfforts: modelActions.listEfforts,
|
|
622
|
+
setEffort: modelActions.setEffort,
|
|
623
|
+
setDefaultEffort: modelActions.setDefaultEffort,
|
|
624
|
+
cycleMode: modeActions.cycleMode,
|
|
625
|
+
listPresets: modelActions.listPresets,
|
|
626
|
+
switchPreset: modelActions.switchPreset,
|
|
627
|
+
listModels: modelActions.listModels,
|
|
628
|
+
listProviders: modelActions.listProviders,
|
|
629
|
+
invalidateModelCompletion: modelActions.dropModelNodeCache,
|
|
630
|
+
listSkills: sessionMetadataActions.listSkills,
|
|
631
|
+
describeCredential: sessionMetadataActions.describeCredential,
|
|
632
|
+
balanceInfo: reportActions.balanceInfo,
|
|
633
|
+
sideQuestion: sessionMetadataActions.sideQuestion,
|
|
634
|
+
cachedSessions: sessionMetadataActions.cachedSessions,
|
|
635
|
+
listSessions: sessionMetadataActions.listSessions,
|
|
636
|
+
previewSession: sessionMetadataActions.previewSession,
|
|
637
|
+
listForeignSources: foreignBrowser.listSources,
|
|
638
|
+
listForeignSessions: foreignBrowser.listSessions,
|
|
639
|
+
importForeignSession: foreignBrowser.importSession,
|
|
640
|
+
bindApprovalStore: agentView.bindApprovalStore,
|
|
641
|
+
agentViewRows: agentView.rows,
|
|
642
|
+
subscribeAgentView: agentView.subscribe,
|
|
643
|
+
dispatchBackgroundAgent: agentView.dispatch,
|
|
644
|
+
stopBackgroundAgent: agentView.stop,
|
|
645
|
+
attachToAgent: agentView.attach,
|
|
646
|
+
peekAgentSession: agentView.peek,
|
|
647
|
+
replyToAgent: agentView.reply,
|
|
648
|
+
backgroundCurrent: agentView.backgroundCurrent,
|
|
649
|
+
setResumeTarget: sessionMetadataActions.setResumeTarget,
|
|
650
|
+
renameSession: sessionMetadataActions.renameSession,
|
|
651
|
+
setSessionColor: sessionMetadataActions.setSessionColor,
|
|
652
|
+
recapRecent: sessionMetadataActions.recapRecent,
|
|
653
|
+
deleteSession: sessionMetadataActions.deleteSession,
|
|
654
|
+
renameSessionTo: sessionMetadataActions.renameSessionTo,
|
|
655
|
+
compact: manualCompaction.compact,
|
|
656
|
+
cancelCompact: manualCompaction.cancel,
|
|
657
|
+
runExternalCommand: externalCommands.invokeText,
|
|
658
|
+
runExternalCommandOutcome: externalCommands.invoke,
|
|
659
|
+
mcpStatus: reportActions.mcpStatus,
|
|
660
|
+
exportSession: reportActions.exportSession,
|
|
661
|
+
initWorkspace: reportActions.initWorkspace,
|
|
662
|
+
doctorInfo: reportActions.doctorInfo,
|
|
663
|
+
pluginsInfo: reportActions.pluginsInfo,
|
|
664
|
+
listSubagents: dshLocal.listSubagents,
|
|
665
|
+
};
|
|
666
|
+
core.extend({
|
|
667
|
+
completions: { workspaceCommands: () => workspaceService.commands(), model: modelActions },
|
|
668
|
+
bind: {
|
|
669
|
+
...bindingEvents.hooks,
|
|
670
|
+
// Re-anchor the job projection after every bind: its event
|
|
671
|
+
// subscription is deliberately owner-agnostic, so this is what makes
|
|
672
|
+
// the /jobs roster follow a session switch immediately.
|
|
673
|
+
afterBind: () => { jobProjection.reanchor(); },
|
|
674
|
+
resetTranslation: () => { binding.session.capabilities.native.dsh?.resetTranslation(); },
|
|
675
|
+
},
|
|
676
|
+
newSession: resumeActions.newSessionOpener,
|
|
677
|
+
delegates,
|
|
678
|
+
start: {
|
|
679
|
+
before() {
|
|
680
|
+
agentView.start();
|
|
681
|
+
owner.own(ctx.on('commands/change', () => { if (owner.current())
|
|
682
|
+
modeActions.refreshMode(); }));
|
|
683
|
+
},
|
|
684
|
+
after() {
|
|
685
|
+
startJobs();
|
|
686
|
+
skillCatalog.start();
|
|
687
|
+
void refreshLoadedContext();
|
|
688
|
+
},
|
|
689
|
+
},
|
|
690
|
+
});
|
|
691
|
+
// Subagents inherit provider/model from AgentOptions, but resumed TUI
|
|
692
|
+
// agents can legitimately carry their route only in persisted request
|
|
693
|
+
// headers. Their child scopes do not share this channel's per-agent
|
|
694
|
+
// ModelSelectionRef, so fill an otherwise incomplete first request from
|
|
695
|
+
// the active route. Keep complete child-specific routes authoritative.
|
|
696
|
+
// Registered before the first bind's own `agent/request` listener.
|
|
697
|
+
const disposeInheritedChildRoute = ctx.on('agent/request', async (_payload, next) => {
|
|
698
|
+
// This listener intentionally serves child scopes, not the bound agent's
|
|
699
|
+
// selection pipeline. Capture the foreground route before awaiting so an
|
|
700
|
+
// old child waterfall cannot borrow a later binding's model (A→B→A safe).
|
|
701
|
+
const capture = binding.capture();
|
|
702
|
+
const provider = state.provider;
|
|
703
|
+
const model = state.model;
|
|
704
|
+
const resolved = await next();
|
|
705
|
+
if (!owner.current() || !binding.isCurrent(capture))
|
|
706
|
+
return resolved;
|
|
707
|
+
if (typeof resolved.provider === 'string' && resolved.provider.length > 0 &&
|
|
708
|
+
typeof resolved.model === 'string' && resolved.model.length > 0) {
|
|
709
|
+
return resolved;
|
|
710
|
+
}
|
|
711
|
+
return { ...resolved, provider, model };
|
|
712
|
+
});
|
|
713
|
+
owner.own(disposeInheritedChildRoute);
|
|
714
|
+
}
|