@deepseek-harness-tui/dsh-tui 0.10.0 → 0.10.2
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 +5 -2
- package/bin/dsh-tui.js +99 -33
- package/cordis.patch.yml +25 -5
- package/lib/types/adapter/channel/actions.d.ts +17 -0
- package/lib/types/adapter/channel/actions.d.ts.map +1 -0
- package/lib/types/adapter/channel/actions.js +28 -0
- package/lib/types/adapter/channel/consumer.d.ts +34 -0
- package/lib/types/adapter/channel/consumer.d.ts.map +1 -0
- package/lib/types/adapter/channel/consumer.js +87 -0
- package/lib/types/adapter/channel/features.d.ts +12 -0
- package/lib/types/adapter/channel/features.d.ts.map +1 -0
- package/lib/types/adapter/channel/features.js +41 -0
- package/lib/types/adapter/channel/host-registry.d.ts +40 -0
- package/lib/types/adapter/channel/host-registry.d.ts.map +1 -0
- package/lib/types/adapter/channel/host-registry.js +120 -0
- package/lib/types/adapter/channel/index.d.ts +22 -0
- package/lib/types/adapter/channel/index.d.ts.map +1 -0
- package/lib/types/adapter/channel/index.js +21 -0
- package/lib/types/adapter/channel/internal-token.d.ts +12 -0
- package/lib/types/adapter/channel/internal-token.d.ts.map +1 -0
- package/lib/types/adapter/channel/internal-token.js +11 -0
- package/lib/types/adapter/channel/plugins.d.ts +17 -0
- package/lib/types/adapter/channel/plugins.d.ts.map +1 -0
- package/lib/types/adapter/channel/plugins.js +47 -0
- package/lib/types/adapter/channel/projection.d.ts +15 -0
- package/lib/types/adapter/channel/projection.d.ts.map +1 -0
- package/lib/types/adapter/channel/projection.js +59 -0
- package/lib/types/adapter/channel/provider.d.ts +52 -0
- package/lib/types/adapter/channel/provider.d.ts.map +1 -0
- package/lib/types/adapter/channel/provider.js +231 -0
- package/lib/types/adapter/channel/read-view.d.ts +4 -0
- package/lib/types/adapter/channel/read-view.d.ts.map +1 -0
- package/lib/types/adapter/channel/read-view.js +132 -0
- package/lib/types/adapter/channel/session-projection.d.ts +56 -0
- package/lib/types/adapter/channel/session-projection.d.ts.map +1 -0
- package/lib/types/adapter/channel/session-projection.js +247 -0
- package/lib/types/adapter/channel/state.d.ts +11 -0
- package/lib/types/adapter/channel/state.d.ts.map +1 -0
- package/lib/types/adapter/channel/state.js +55 -0
- package/lib/types/adapter/channel/transcript.d.ts +15 -0
- package/lib/types/adapter/channel/transcript.d.ts.map +1 -0
- package/lib/types/adapter/channel/transcript.js +22 -0
- package/lib/types/adapter/channel/ui-policy.d.ts +106 -0
- package/lib/types/adapter/channel/ui-policy.d.ts.map +1 -0
- package/lib/types/adapter/channel/ui-policy.js +166 -0
- package/lib/types/adapter/channel/ui.d.ts +16 -0
- package/lib/types/adapter/channel/ui.d.ts.map +1 -0
- package/lib/types/adapter/channel/ui.js +168 -0
- package/lib/types/adapter/index.d.ts +20 -0
- package/lib/types/adapter/index.d.ts.map +1 -0
- package/lib/types/adapter/index.js +19 -0
- package/lib/types/adapter/kernel/contract-catalog.d.ts +12 -0
- package/lib/types/adapter/kernel/contract-catalog.d.ts.map +1 -0
- package/lib/types/adapter/kernel/contract-catalog.js +11 -0
- package/lib/types/adapter/kernel/diagnostics.d.ts +18 -0
- package/lib/types/adapter/kernel/diagnostics.d.ts.map +1 -0
- package/lib/types/adapter/kernel/diagnostics.js +16 -0
- package/lib/types/adapter/kernel/driver-types.d.ts +16 -0
- package/lib/types/adapter/kernel/driver-types.d.ts.map +1 -0
- package/lib/types/adapter/kernel/driver-types.js +8 -0
- package/lib/types/adapter/kernel/host-facade.d.ts +65 -0
- package/lib/types/adapter/kernel/host-facade.d.ts.map +1 -0
- package/lib/types/adapter/kernel/host-facade.js +215 -0
- package/lib/types/adapter/kernel/host-probe-access.d.ts +71 -0
- package/lib/types/adapter/kernel/host-probe-access.d.ts.map +1 -0
- package/lib/types/adapter/kernel/host-probe-access.js +121 -0
- package/lib/types/adapter/kernel/index.d.ts +20 -0
- package/lib/types/adapter/kernel/index.d.ts.map +1 -0
- package/lib/types/adapter/kernel/index.js +19 -0
- package/lib/types/adapter/kernel/kernel-runtime.d.ts +138 -0
- package/lib/types/adapter/kernel/kernel-runtime.d.ts.map +1 -0
- package/lib/types/adapter/kernel/kernel-runtime.js +572 -0
- package/lib/types/adapter/kernel/ledger.d.ts +55 -0
- package/lib/types/adapter/kernel/ledger.d.ts.map +1 -0
- package/lib/types/adapter/kernel/ledger.js +33 -0
- package/lib/types/adapter/kernel/legacy-facade.d.ts +22 -0
- package/lib/types/adapter/kernel/legacy-facade.d.ts.map +1 -0
- package/lib/types/adapter/kernel/legacy-facade.js +34 -0
- package/lib/types/adapter/kernel/lifecycle.d.ts +38 -0
- package/lib/types/adapter/kernel/lifecycle.d.ts.map +1 -0
- package/lib/types/adapter/kernel/lifecycle.js +53 -0
- package/lib/types/adapter/kernel/replay-isolation.d.ts +27 -0
- package/lib/types/adapter/kernel/replay-isolation.d.ts.map +1 -0
- package/lib/types/adapter/kernel/replay-isolation.js +45 -0
- package/lib/types/adapter/kernel/replay.d.ts +132 -0
- package/lib/types/adapter/kernel/replay.d.ts.map +1 -0
- package/lib/types/adapter/kernel/replay.js +425 -0
- package/lib/types/adapter/kernel/runtime-context.d.ts +15 -0
- package/lib/types/adapter/kernel/runtime-context.d.ts.map +1 -0
- package/lib/types/adapter/kernel/runtime-context.js +24 -0
- package/lib/types/adapter/kernel/runtime.d.ts +70 -0
- package/lib/types/adapter/kernel/runtime.d.ts.map +1 -0
- package/lib/types/adapter/kernel/runtime.js +325 -0
- package/lib/types/adapter/kernel/slices/channel.d.ts +3 -0
- package/lib/types/adapter/kernel/slices/channel.d.ts.map +1 -0
- package/lib/types/adapter/kernel/slices/channel.js +8 -0
- package/lib/types/adapter/kernel/slices/decisions.d.ts +3 -0
- package/lib/types/adapter/kernel/slices/decisions.d.ts.map +1 -0
- package/lib/types/adapter/kernel/slices/decisions.js +10 -0
- package/lib/types/adapter/kernel/slices/extensions.d.ts +8 -0
- package/lib/types/adapter/kernel/slices/extensions.d.ts.map +1 -0
- package/lib/types/adapter/kernel/slices/extensions.js +43 -0
- package/lib/types/adapter/kernel/slices/index.d.ts +19 -0
- package/lib/types/adapter/kernel/slices/index.d.ts.map +1 -0
- package/lib/types/adapter/kernel/slices/index.js +36 -0
- package/lib/types/adapter/kernel/slices/presentation.d.ts +3 -0
- package/lib/types/adapter/kernel/slices/presentation.d.ts.map +1 -0
- package/lib/types/adapter/kernel/slices/presentation.js +14 -0
- package/lib/types/adapter/kernel/slices/scenes.d.ts +3 -0
- package/lib/types/adapter/kernel/slices/scenes.d.ts.map +1 -0
- package/lib/types/adapter/kernel/slices/scenes.js +14 -0
- package/lib/types/adapter/kernel/slices/settings.d.ts +3 -0
- package/lib/types/adapter/kernel/slices/settings.d.ts.map +1 -0
- package/lib/types/adapter/kernel/slices/settings.js +12 -0
- package/lib/types/adapter/kernel/slices/types.d.ts +20 -0
- package/lib/types/adapter/kernel/slices/types.d.ts.map +1 -0
- package/lib/types/adapter/kernel/slices/types.js +12 -0
- package/lib/types/adapter/kernel/slices/workspace.d.ts +3 -0
- package/lib/types/adapter/kernel/slices/workspace.d.ts.map +1 -0
- package/lib/types/adapter/kernel/slices/workspace.js +15 -0
- package/lib/types/adapter/ports/channel-catalog.d.ts +90 -0
- package/lib/types/adapter/ports/channel-catalog.d.ts.map +1 -0
- package/lib/types/adapter/ports/channel-catalog.js +2 -0
- package/lib/types/adapter/ports/channel-display.d.ts +90 -0
- package/lib/types/adapter/ports/channel-display.d.ts.map +1 -0
- package/lib/types/adapter/ports/channel-display.js +2 -0
- package/lib/types/adapter/ports/channel-session.d.ts +229 -0
- package/lib/types/adapter/ports/channel-session.d.ts.map +1 -0
- package/lib/types/adapter/ports/channel-session.js +2 -0
- package/lib/types/adapter/ports/channel-settings.d.ts +273 -0
- package/lib/types/adapter/ports/channel-settings.d.ts.map +1 -0
- package/lib/types/adapter/ports/channel-settings.js +1 -0
- package/lib/types/adapter/ports/channel-ui.d.ts +569 -0
- package/lib/types/adapter/ports/channel-ui.d.ts.map +1 -0
- package/lib/types/adapter/ports/channel-ui.js +1 -0
- package/lib/types/adapter/ports/channel-view.d.ts +609 -0
- package/lib/types/adapter/ports/channel-view.d.ts.map +1 -0
- package/lib/types/adapter/ports/channel-view.js +2 -0
- package/lib/types/adapter/ports/channel-workspace.d.ts +45 -0
- package/lib/types/adapter/ports/channel-workspace.d.ts.map +1 -0
- package/lib/types/adapter/ports/channel-workspace.js +2 -0
- package/lib/types/adapter/ports/channel.d.ts +145 -0
- package/lib/types/adapter/ports/channel.d.ts.map +1 -0
- package/lib/types/adapter/ports/channel.js +22 -0
- package/lib/types/adapter/ports/decisions.d.ts +18 -0
- package/lib/types/adapter/ports/decisions.d.ts.map +1 -0
- package/lib/types/adapter/ports/decisions.js +9 -0
- package/lib/types/adapter/ports/descriptor.d.ts +25 -0
- package/lib/types/adapter/ports/descriptor.d.ts.map +1 -0
- package/lib/types/adapter/ports/descriptor.js +11 -0
- package/lib/types/adapter/ports/extensions.d.ts +86 -0
- package/lib/types/adapter/ports/extensions.d.ts.map +1 -0
- package/lib/types/adapter/ports/extensions.js +9 -0
- package/lib/types/adapter/ports/index.d.ts +23 -0
- package/lib/types/adapter/ports/index.d.ts.map +1 -0
- package/lib/types/adapter/ports/index.js +14 -0
- package/lib/types/adapter/ports/owner.d.ts +19 -0
- package/lib/types/adapter/ports/owner.d.ts.map +1 -0
- package/lib/types/adapter/ports/owner.js +9 -0
- package/lib/types/adapter/ports/presentation.d.ts +81 -0
- package/lib/types/adapter/ports/presentation.d.ts.map +1 -0
- package/lib/types/adapter/ports/presentation.js +10 -0
- package/lib/types/adapter/ports/scenes.d.ts +24 -0
- package/lib/types/adapter/ports/scenes.d.ts.map +1 -0
- package/lib/types/adapter/ports/scenes.js +8 -0
- package/lib/types/adapter/ports/settings.d.ts +44 -0
- package/lib/types/adapter/ports/settings.d.ts.map +1 -0
- package/lib/types/adapter/ports/settings.js +9 -0
- package/lib/types/adapter/ports/workspace.d.ts +60 -0
- package/lib/types/adapter/ports/workspace.d.ts.map +1 -0
- package/lib/types/adapter/ports/workspace.js +8 -0
- package/lib/types/adapter/spec/index.d.ts +11 -0
- package/lib/types/adapter/spec/index.d.ts.map +1 -0
- package/lib/types/adapter/spec/index.js +10 -0
- package/lib/types/adapter/spec/profile.d.ts +10 -0
- package/lib/types/adapter/spec/profile.d.ts.map +1 -0
- package/lib/types/adapter/spec/profile.js +9 -0
- package/lib/types/adapter/spec/protocol-constants.d.ts +60 -0
- package/lib/types/adapter/spec/protocol-constants.d.ts.map +1 -0
- package/lib/types/adapter/spec/protocol-constants.js +129 -0
- package/lib/types/adapter/spec/tui-contributions.d.ts +18 -0
- package/lib/types/adapter/spec/tui-contributions.d.ts.map +1 -0
- package/lib/types/adapter/spec/tui-contributions.js +19 -0
- package/lib/types/adapter/standard/admission.d.ts +11 -0
- package/lib/types/adapter/standard/admission.d.ts.map +1 -0
- package/lib/types/adapter/standard/admission.js +10 -0
- package/lib/types/adapter/standard/descriptor.d.ts +74 -0
- package/lib/types/adapter/standard/descriptor.d.ts.map +1 -0
- package/lib/types/adapter/standard/descriptor.js +356 -0
- package/lib/types/{dsh-adapter → adapter/standard}/grants.d.ts +8 -3
- package/lib/types/adapter/standard/grants.d.ts.map +1 -0
- package/lib/types/{dsh-adapter → adapter/standard}/grants.js +14 -8
- package/lib/types/adapter/standard/index.d.ts +25 -0
- package/lib/types/adapter/standard/index.d.ts.map +1 -0
- package/lib/types/adapter/standard/index.js +24 -0
- package/lib/types/adapter/standard/negotiate.d.ts.map +1 -0
- package/lib/types/{plugin-spec → adapter/standard}/permission-scope.d.ts +3 -8
- package/lib/types/adapter/standard/permission-scope.d.ts.map +1 -0
- package/lib/types/{plugin-spec → adapter/standard}/permission-scope.js +4 -26
- package/lib/types/adapter/standard/protocols.d.ts +12 -0
- package/lib/types/adapter/standard/protocols.d.ts.map +1 -0
- package/lib/types/adapter/standard/protocols.js +11 -0
- package/lib/types/adapter/standard/registry.d.ts.map +1 -0
- package/lib/types/{plugin-spec → adapter/standard}/registry.js +3 -15
- package/lib/types/adapter/standard/schema-check.d.ts.map +1 -0
- package/lib/types/{plugin-spec → adapter/standard}/schema-check.js +4 -2
- package/lib/types/adapter/standard/tui-extension.d.ts +25 -0
- package/lib/types/adapter/standard/tui-extension.d.ts.map +1 -0
- package/lib/types/adapter/standard/tui-extension.js +45 -0
- package/lib/types/{plugin-spec → adapter/standard}/types.d.ts +3 -9
- package/lib/types/adapter/standard/types.d.ts.map +1 -0
- package/lib/types/{plugin-spec → adapter/standard}/validate.d.ts +3 -3
- package/lib/types/adapter/standard/validate.d.ts.map +1 -0
- package/lib/types/{plugin-spec → adapter/standard}/validate.js +14 -13
- package/lib/types/adapter/upstream/channel-driver.d.ts +22 -0
- package/lib/types/adapter/upstream/channel-driver.d.ts.map +1 -0
- package/lib/types/adapter/upstream/channel-driver.js +424 -0
- package/lib/types/adapter/upstream/decisions-driver.d.ts +15 -0
- package/lib/types/adapter/upstream/decisions-driver.d.ts.map +1 -0
- package/lib/types/adapter/upstream/decisions-driver.js +141 -0
- package/lib/types/adapter/upstream/detection.d.ts +26 -0
- package/lib/types/adapter/upstream/detection.d.ts.map +1 -0
- package/lib/types/adapter/upstream/detection.js +9 -0
- package/lib/types/adapter/upstream/driver.d.ts +50 -0
- package/lib/types/adapter/upstream/driver.d.ts.map +1 -0
- package/lib/types/adapter/upstream/driver.js +8 -0
- package/lib/types/adapter/upstream/extensions-driver.d.ts +24 -0
- package/lib/types/adapter/upstream/extensions-driver.d.ts.map +1 -0
- package/lib/types/adapter/upstream/extensions-driver.js +697 -0
- package/lib/types/adapter/upstream/host-descriptor-driver.d.ts +45 -0
- package/lib/types/adapter/upstream/host-descriptor-driver.d.ts.map +1 -0
- package/lib/types/adapter/upstream/host-descriptor-driver.js +606 -0
- package/lib/types/adapter/upstream/index.d.ts +18 -0
- package/lib/types/adapter/upstream/index.d.ts.map +1 -0
- package/lib/types/adapter/upstream/index.js +15 -0
- package/lib/types/adapter/upstream/presentation-driver.d.ts +17 -0
- package/lib/types/adapter/upstream/presentation-driver.d.ts.map +1 -0
- package/lib/types/adapter/upstream/presentation-driver.js +129 -0
- package/lib/types/adapter/upstream/scenes-driver.d.ts +18 -0
- package/lib/types/adapter/upstream/scenes-driver.d.ts.map +1 -0
- package/lib/types/adapter/upstream/scenes-driver.js +170 -0
- package/lib/types/adapter/upstream/settings-driver.d.ts +20 -0
- package/lib/types/adapter/upstream/settings-driver.d.ts.map +1 -0
- package/lib/types/adapter/upstream/settings-driver.js +173 -0
- package/lib/types/adapter/upstream/workspace-driver.d.ts +19 -0
- package/lib/types/adapter/upstream/workspace-driver.d.ts.map +1 -0
- package/lib/types/adapter/upstream/workspace-driver.js +190 -0
- package/lib/types/api.d.ts +1 -1
- package/lib/types/api.d.ts.map +1 -1
- package/lib/types/commands.d.ts +2 -41
- package/lib/types/commands.d.ts.map +1 -1
- package/lib/types/commands.js +1 -1
- package/lib/types/components/Chat/JobCard.d.ts.map +1 -1
- package/lib/types/components/Chat/JobCard.js +8 -1
- package/lib/types/components/GoalTodoPanel.d.ts +2 -1
- package/lib/types/components/GoalTodoPanel.d.ts.map +1 -1
- package/lib/types/components/HistorySearchDialog.d.ts.map +1 -1
- package/lib/types/components/HistorySearchDialog.js +7 -5
- package/lib/types/components/Markdown.d.ts +2 -2
- package/lib/types/components/Markdown.d.ts.map +1 -1
- package/lib/types/components/Markdown.js +28 -3
- package/lib/types/components/MessageList.d.ts.map +1 -1
- package/lib/types/components/MessageList.js +46 -17
- package/lib/types/components/ModelPicker.d.ts +1 -1
- package/lib/types/components/ModelPicker.d.ts.map +1 -1
- package/lib/types/components/ModelPicker.js +8 -4
- package/lib/types/components/OverlayAbove.d.ts +22 -1
- package/lib/types/components/OverlayAbove.d.ts.map +1 -1
- package/lib/types/components/OverlayAbove.js +74 -5
- package/lib/types/components/PromptInput.d.ts +2 -1
- package/lib/types/components/PromptInput.d.ts.map +1 -1
- package/lib/types/components/RewindPicker.d.ts.map +1 -1
- package/lib/types/components/RewindPicker.js +14 -6
- package/lib/types/components/SkillsPicker.d.ts.map +1 -1
- package/lib/types/components/SkillsPicker.js +6 -4
- package/lib/types/components/Spinner/spinnerMode.d.ts +1 -5
- package/lib/types/components/Spinner/spinnerMode.d.ts.map +1 -1
- package/lib/types/components/StreamingMarkdown.d.ts.map +1 -1
- package/lib/types/components/StreamingMarkdown.js +61 -9
- package/lib/types/components/design-system/ThemedBox.d.ts +4 -2
- package/lib/types/components/design-system/ThemedBox.d.ts.map +1 -1
- package/lib/types/components/design-system/ThemedBox.js +2 -2
- package/lib/types/components/messages/AssistantToolUseMessage.d.ts.map +1 -1
- package/lib/types/components/messages/AssistantToolUseMessage.js +69 -25
- package/lib/types/components/overlayBudget.d.ts +39 -0
- package/lib/types/components/overlayBudget.d.ts.map +1 -0
- package/lib/types/components/overlayBudget.js +43 -0
- package/lib/types/deepseekBalance.d.ts +2 -36
- package/lib/types/deepseekBalance.d.ts.map +1 -1
- package/lib/types/deepseekBalance.js +0 -14
- package/lib/types/deepseekPricing.d.ts +2 -1
- package/lib/types/deepseekPricing.d.ts.map +1 -1
- package/lib/types/deepseekPricing.js +8 -1
- package/lib/types/dsh-adapter/approvals.d.ts +11 -1
- package/lib/types/dsh-adapter/approvals.d.ts.map +1 -1
- package/lib/types/dsh-adapter/approvals.js +32 -12
- package/lib/types/dsh-adapter/channel/action-readiness.d.ts +20 -0
- package/lib/types/dsh-adapter/channel/action-readiness.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/action-readiness.js +83 -0
- package/lib/types/dsh-adapter/channel/activity.d.ts +20 -0
- package/lib/types/dsh-adapter/channel/activity.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/activity.js +113 -0
- package/lib/types/dsh-adapter/channel/agent-view-projection.d.ts +64 -0
- package/lib/types/dsh-adapter/channel/agent-view-projection.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/agent-view-projection.js +295 -0
- package/lib/types/dsh-adapter/channel/background-action.d.ts +41 -0
- package/lib/types/dsh-adapter/channel/background-action.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/background-action.js +86 -0
- package/lib/types/dsh-adapter/channel/binding-events.d.ts +65 -0
- package/lib/types/dsh-adapter/channel/binding-events.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/binding-events.js +169 -0
- package/lib/types/dsh-adapter/channel/binding.d.ts +41 -0
- package/lib/types/dsh-adapter/channel/binding.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/binding.js +227 -0
- package/lib/types/dsh-adapter/channel/command-completions.d.ts +29 -0
- package/lib/types/dsh-adapter/channel/command-completions.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/command-completions.js +94 -0
- package/lib/types/dsh-adapter/channel/commands.d.ts +8 -0
- package/lib/types/dsh-adapter/channel/commands.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/commands.js +9 -0
- package/lib/types/dsh-adapter/channel/compaction.d.ts +19 -0
- package/lib/types/dsh-adapter/channel/compaction.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/compaction.js +116 -0
- package/lib/types/dsh-adapter/channel/composer-images.d.ts +57 -0
- package/lib/types/dsh-adapter/channel/composer-images.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/composer-images.js +217 -0
- package/lib/types/dsh-adapter/channel/composer-mentions.d.ts +15 -0
- package/lib/types/dsh-adapter/channel/composer-mentions.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/composer-mentions.js +200 -0
- package/lib/types/dsh-adapter/channel/context-bookkeeping.d.ts +26 -0
- package/lib/types/dsh-adapter/channel/context-bookkeeping.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/context-bookkeeping.js +30 -0
- package/lib/types/dsh-adapter/channel/decisions.d.ts +19 -0
- package/lib/types/dsh-adapter/channel/decisions.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/decisions.js +90 -0
- package/lib/types/dsh-adapter/channel/emitter.d.ts +10 -0
- package/lib/types/dsh-adapter/channel/emitter.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/emitter.js +71 -0
- package/lib/types/dsh-adapter/channel/external-commands.d.ts +31 -0
- package/lib/types/dsh-adapter/channel/external-commands.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/external-commands.js +187 -0
- package/lib/types/dsh-adapter/channel/file-actions.d.ts +20 -0
- package/lib/types/dsh-adapter/channel/file-actions.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/file-actions.js +45 -0
- package/lib/types/dsh-adapter/channel/input-actions.d.ts +13 -0
- package/lib/types/dsh-adapter/channel/input-actions.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/input-actions.js +135 -0
- package/lib/types/dsh-adapter/channel/input-delivery.d.ts +37 -0
- package/lib/types/dsh-adapter/channel/input-delivery.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/input-delivery.js +305 -0
- package/lib/types/dsh-adapter/channel/job-projection.d.ts +28 -0
- package/lib/types/dsh-adapter/channel/job-projection.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/job-projection.js +150 -0
- package/lib/types/dsh-adapter/channel/lifetime-resources.d.ts +9 -0
- package/lib/types/dsh-adapter/channel/lifetime-resources.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/lifetime-resources.js +33 -0
- package/lib/types/dsh-adapter/channel/loaded-context.d.ts +40 -0
- package/lib/types/dsh-adapter/channel/loaded-context.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/loaded-context.js +62 -0
- package/lib/types/dsh-adapter/channel/local-actions.d.ts +70 -0
- package/lib/types/dsh-adapter/channel/local-actions.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/local-actions.js +108 -0
- package/lib/types/dsh-adapter/channel/mentions.d.ts +29 -0
- package/lib/types/dsh-adapter/channel/mentions.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/mentions.js +235 -0
- package/lib/types/dsh-adapter/channel/mode-actions.d.ts +30 -0
- package/lib/types/dsh-adapter/channel/mode-actions.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/mode-actions.js +247 -0
- package/lib/types/dsh-adapter/channel/mode-permission-actions.d.ts +35 -0
- package/lib/types/dsh-adapter/channel/mode-permission-actions.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/mode-permission-actions.js +199 -0
- package/lib/types/dsh-adapter/channel/mode-permission.d.ts +58 -0
- package/lib/types/dsh-adapter/channel/mode-permission.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/mode-permission.js +240 -0
- package/lib/types/dsh-adapter/channel/mode-roster.d.ts +51 -0
- package/lib/types/dsh-adapter/channel/mode-roster.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/mode-roster.js +119 -0
- package/lib/types/dsh-adapter/channel/model-actions.d.ts +46 -0
- package/lib/types/dsh-adapter/channel/model-actions.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/model-actions.js +275 -0
- package/lib/types/dsh-adapter/channel/model-switch.d.ts +32 -0
- package/lib/types/dsh-adapter/channel/model-switch.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/model-switch.js +98 -0
- package/lib/types/dsh-adapter/channel/notifications.d.ts +9 -0
- package/lib/types/dsh-adapter/channel/notifications.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/notifications.js +24 -0
- package/lib/types/dsh-adapter/channel/owner.d.ts +18 -0
- package/lib/types/dsh-adapter/channel/owner.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/owner.js +73 -0
- package/lib/types/dsh-adapter/channel/paths.d.ts +31 -0
- package/lib/types/dsh-adapter/channel/paths.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/paths.js +147 -0
- package/lib/types/dsh-adapter/channel/permissions.d.ts +40 -0
- package/lib/types/dsh-adapter/channel/permissions.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/permissions.js +187 -0
- package/lib/types/dsh-adapter/channel/preferences.d.ts +3 -0
- package/lib/types/dsh-adapter/channel/preferences.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/preferences.js +103 -0
- package/lib/types/dsh-adapter/channel/projection-helpers.d.ts +13 -0
- package/lib/types/dsh-adapter/channel/projection-helpers.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/projection-helpers.js +63 -0
- package/lib/types/dsh-adapter/channel/projection.d.ts +40 -0
- package/lib/types/dsh-adapter/channel/projection.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/projection.js +1021 -0
- package/lib/types/dsh-adapter/channel/reports.d.ts +32 -0
- package/lib/types/dsh-adapter/channel/reports.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/reports.js +171 -0
- package/lib/types/dsh-adapter/channel/session-actions.d.ts +13 -0
- package/lib/types/dsh-adapter/channel/session-actions.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/session-actions.js +29 -0
- package/lib/types/dsh-adapter/channel/session-adoption.d.ts +32 -0
- package/lib/types/dsh-adapter/channel/session-adoption.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/session-adoption.js +35 -0
- package/lib/types/dsh-adapter/channel/session-fork.d.ts +19 -0
- package/lib/types/dsh-adapter/channel/session-fork.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/session-fork.js +85 -0
- package/lib/types/dsh-adapter/channel/session-live-adoption.d.ts +32 -0
- package/lib/types/dsh-adapter/channel/session-live-adoption.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/session-live-adoption.js +62 -0
- package/lib/types/dsh-adapter/channel/session-metadata.d.ts +81 -0
- package/lib/types/dsh-adapter/channel/session-metadata.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/session-metadata.js +209 -0
- package/lib/types/dsh-adapter/channel/session-reset.d.ts +11 -0
- package/lib/types/dsh-adapter/channel/session-reset.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/session-reset.js +44 -0
- package/lib/types/dsh-adapter/channel/session-resume.d.ts +56 -0
- package/lib/types/dsh-adapter/channel/session-resume.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/session-resume.js +240 -0
- package/lib/types/dsh-adapter/channel/session-rewind.d.ts +19 -0
- package/lib/types/dsh-adapter/channel/session-rewind.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/session-rewind.js +128 -0
- package/lib/types/dsh-adapter/channel/session-tree-actions.d.ts +19 -0
- package/lib/types/dsh-adapter/channel/session-tree-actions.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/session-tree-actions.js +138 -0
- package/lib/types/dsh-adapter/channel/session-tree.d.ts +10 -0
- package/lib/types/dsh-adapter/channel/session-tree.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/session-tree.js +503 -0
- package/lib/types/dsh-adapter/channel/settings-host.d.ts +4 -0
- package/lib/types/dsh-adapter/channel/settings-host.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/settings-host.js +256 -0
- package/lib/types/dsh-adapter/channel/skill-catalog.d.ts +33 -0
- package/lib/types/dsh-adapter/channel/skill-catalog.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/skill-catalog.js +215 -0
- package/lib/types/dsh-adapter/channel/state.d.ts +46 -0
- package/lib/types/dsh-adapter/channel/state.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/state.js +31 -0
- package/lib/types/dsh-adapter/channel/subagent-projection.d.ts +47 -0
- package/lib/types/dsh-adapter/channel/subagent-projection.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/subagent-projection.js +140 -0
- package/lib/types/dsh-adapter/channel/transcript.d.ts +73 -0
- package/lib/types/dsh-adapter/channel/transcript.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/transcript.js +312 -0
- package/lib/types/dsh-adapter/channel/types.d.ts +162 -0
- package/lib/types/dsh-adapter/channel/types.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/types.js +1 -0
- package/lib/types/dsh-adapter/channel/usage.d.ts +13 -0
- package/lib/types/dsh-adapter/channel/usage.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/usage.js +48 -0
- package/lib/types/dsh-adapter/channel/workspace-actions.d.ts +20 -0
- package/lib/types/dsh-adapter/channel/workspace-actions.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel/workspace-actions.js +56 -0
- package/lib/types/dsh-adapter/channel-facade-actions.d.ts +25 -0
- package/lib/types/dsh-adapter/channel-facade-actions.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel-facade-actions.js +55 -0
- package/lib/types/dsh-adapter/channel-scene-outlet.d.ts +6 -0
- package/lib/types/dsh-adapter/channel-scene-outlet.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel-scene-outlet.js +13 -0
- package/lib/types/dsh-adapter/channel-ui.d.ts +9 -0
- package/lib/types/dsh-adapter/channel-ui.d.ts.map +1 -0
- package/lib/types/dsh-adapter/channel-ui.js +128 -0
- package/lib/types/dsh-adapter/channel.d.ts +9 -1525
- package/lib/types/dsh-adapter/channel.d.ts.map +1 -1
- package/lib/types/dsh-adapter/channel.js +753 -8145
- package/lib/types/dsh-adapter/command-trees.d.ts +1 -0
- package/lib/types/dsh-adapter/command-trees.d.ts.map +1 -1
- package/lib/types/dsh-adapter/command-trees.js +20 -1
- package/lib/types/dsh-adapter/compat/liveSession.d.ts +8 -4
- package/lib/types/dsh-adapter/compat/liveSession.d.ts.map +1 -1
- package/lib/types/dsh-adapter/compat/liveSession.js +28 -3
- package/lib/types/dsh-adapter/compat/persistence.d.ts +21 -0
- package/lib/types/dsh-adapter/compat/persistence.d.ts.map +1 -0
- package/lib/types/dsh-adapter/compat/persistence.js +17 -0
- package/lib/types/dsh-adapter/compat/sessionLog.d.ts +50 -11
- package/lib/types/dsh-adapter/compat/sessionLog.d.ts.map +1 -1
- package/lib/types/dsh-adapter/compat/sessionLog.js +325 -36
- package/lib/types/dsh-adapter/component-identity.d.ts +1 -1
- package/lib/types/dsh-adapter/component-identity.d.ts.map +1 -1
- package/lib/types/dsh-adapter/component-identity.js +1 -1
- package/lib/types/dsh-adapter/contract.d.ts +11 -9
- package/lib/types/dsh-adapter/contract.d.ts.map +1 -1
- package/lib/types/dsh-adapter/contract.js +19 -12
- package/lib/types/dsh-adapter/decision-guard.d.ts +56 -12
- package/lib/types/dsh-adapter/decision-guard.d.ts.map +1 -1
- package/lib/types/dsh-adapter/decision-guard.js +134 -22
- package/lib/types/dsh-adapter/dialogs.d.ts.map +1 -1
- package/lib/types/dsh-adapter/dialogs.js +13 -0
- package/lib/types/dsh-adapter/effect-ledger.d.ts +5 -0
- package/lib/types/dsh-adapter/effect-ledger.d.ts.map +1 -1
- package/lib/types/dsh-adapter/effect-ledger.js +53 -15
- package/lib/types/dsh-adapter/extension-events.d.ts +2 -9
- package/lib/types/dsh-adapter/extension-events.d.ts.map +1 -1
- package/lib/types/dsh-adapter/extension-events.js +0 -20
- package/lib/types/dsh-adapter/extensions.d.ts.map +1 -1
- package/lib/types/dsh-adapter/extensions.js +3 -2
- package/lib/types/dsh-adapter/host-grants.d.ts +23 -0
- package/lib/types/dsh-adapter/host-grants.d.ts.map +1 -0
- package/lib/types/dsh-adapter/host-grants.js +45 -0
- package/lib/types/dsh-adapter/jobs.d.ts +2 -46
- package/lib/types/dsh-adapter/jobs.d.ts.map +1 -1
- package/lib/types/dsh-adapter/jobs.js +0 -25
- package/lib/types/dsh-adapter/message-observer.d.ts +15 -2
- package/lib/types/dsh-adapter/message-observer.d.ts.map +1 -1
- package/lib/types/dsh-adapter/message-observer.js +157 -28
- package/lib/types/dsh-adapter/plugin-host.d.ts +80 -11
- package/lib/types/dsh-adapter/plugin-host.d.ts.map +1 -1
- package/lib/types/dsh-adapter/plugin-host.js +438 -41
- package/lib/types/dsh-adapter/plugin-storage.d.ts +11 -1
- package/lib/types/dsh-adapter/plugin-storage.d.ts.map +1 -1
- package/lib/types/dsh-adapter/plugin-storage.js +150 -11
- package/lib/types/dsh-adapter/plugin.d.ts.map +1 -1
- package/lib/types/dsh-adapter/plugin.js +75 -34
- package/lib/types/dsh-adapter/plugins-info.d.ts +2 -2
- package/lib/types/dsh-adapter/plugins-info.d.ts.map +1 -1
- package/lib/types/dsh-adapter/plugins-info.js +11 -6
- package/lib/types/dsh-adapter/presets.d.ts.map +1 -1
- package/lib/types/dsh-adapter/presets.js +3 -2
- package/lib/types/dsh-adapter/providerWizard.d.ts +2 -159
- package/lib/types/dsh-adapter/providerWizard.d.ts.map +1 -1
- package/lib/types/dsh-adapter/questions.d.ts +8 -0
- package/lib/types/dsh-adapter/questions.d.ts.map +1 -1
- package/lib/types/dsh-adapter/questions.js +18 -0
- package/lib/types/dsh-adapter/recap.d.ts +1 -9
- package/lib/types/dsh-adapter/recap.d.ts.map +1 -1
- package/lib/types/dsh-adapter/recap.js +0 -14
- package/lib/types/dsh-adapter/renderers.d.ts +1 -0
- package/lib/types/dsh-adapter/renderers.d.ts.map +1 -1
- package/lib/types/dsh-adapter/renderers.js +26 -1
- package/lib/types/dsh-adapter/scenes.d.ts +3 -1
- package/lib/types/dsh-adapter/scenes.d.ts.map +1 -1
- package/lib/types/dsh-adapter/scenes.js +31 -0
- package/lib/types/dsh-adapter/sessionTree.d.ts +14 -95
- package/lib/types/dsh-adapter/sessionTree.d.ts.map +1 -1
- package/lib/types/dsh-adapter/sessionTree.js +51 -36
- package/lib/types/dsh-adapter/sessions/digest.d.ts.map +1 -1
- package/lib/types/dsh-adapter/sessions/digest.js +40 -19
- package/lib/types/dsh-adapter/sessions/frames.js +2 -0
- package/lib/types/dsh-adapter/sessions/index.d.ts +1 -1
- package/lib/types/dsh-adapter/sessions/index.d.ts.map +1 -1
- package/lib/types/dsh-adapter/sessions/index.js +1 -1
- package/lib/types/dsh-adapter/sessions/list.d.ts +23 -0
- package/lib/types/dsh-adapter/sessions/list.d.ts.map +1 -1
- package/lib/types/dsh-adapter/sessions/list.js +28 -17
- package/lib/types/dsh-adapter/sessions/store.d.ts +2 -2
- package/lib/types/dsh-adapter/sessions/store.d.ts.map +1 -1
- package/lib/types/dsh-adapter/sessions/store.js +12 -11
- package/lib/types/dsh-adapter/sessions/types.d.ts +4 -128
- package/lib/types/dsh-adapter/sessions/types.d.ts.map +1 -1
- package/lib/types/dsh-adapter/sessions/types.js +0 -13
- package/lib/types/dsh-adapter/settings-sections.d.ts +4 -95
- package/lib/types/dsh-adapter/settings-sections.d.ts.map +1 -1
- package/lib/types/dsh-adapter/settings-sections.js +50 -13
- package/lib/types/dsh-adapter/settingsEditor.d.ts +2 -36
- package/lib/types/dsh-adapter/settingsEditor.d.ts.map +1 -1
- package/lib/types/dsh-adapter/settingsEditor.js +0 -18
- package/lib/types/dsh-adapter/shortcuts.d.ts +5 -0
- package/lib/types/dsh-adapter/shortcuts.d.ts.map +1 -1
- package/lib/types/dsh-adapter/shortcuts.js +49 -0
- package/lib/types/dsh-adapter/status.d.ts +5 -0
- package/lib/types/dsh-adapter/status.d.ts.map +1 -1
- package/lib/types/dsh-adapter/status.js +29 -0
- package/lib/types/dsh-adapter/subagents.d.ts +9 -49
- package/lib/types/dsh-adapter/subagents.d.ts.map +1 -1
- package/lib/types/dsh-adapter/subagents.js +92 -1
- package/lib/types/dsh-adapter/themes.d.ts +1 -0
- package/lib/types/dsh-adapter/themes.d.ts.map +1 -1
- package/lib/types/dsh-adapter/themes.js +29 -0
- package/lib/types/dsh-adapter/toast.d.ts +13 -0
- package/lib/types/dsh-adapter/toast.d.ts.map +1 -1
- package/lib/types/dsh-adapter/toast.js +31 -1
- package/lib/types/dsh-adapter/trajectory/aggregate.d.ts +2 -1
- package/lib/types/dsh-adapter/trajectory/aggregate.d.ts.map +1 -1
- package/lib/types/dsh-adapter/trajectory/aggregate.js +2 -1
- package/lib/types/dsh-adapter/trajectory/guards.d.ts +37 -18
- package/lib/types/dsh-adapter/trajectory/guards.d.ts.map +1 -1
- package/lib/types/dsh-adapter/trajectory/guards.js +43 -5
- package/lib/types/dsh-adapter/trajectory/inspect.d.ts +2 -2
- package/lib/types/dsh-adapter/trajectory/inspect.d.ts.map +1 -1
- package/lib/types/dsh-adapter/trajectory/projection.d.ts +31 -13
- package/lib/types/dsh-adapter/trajectory/projection.d.ts.map +1 -1
- package/lib/types/dsh-adapter/trajectory/projection.js +71 -14
- package/lib/types/dsh-adapter/trajectory/types.d.ts +1 -1
- package/lib/types/dsh-adapter/trajectory/types.d.ts.map +1 -1
- package/lib/types/dsh-adapter/transcript-images.d.ts +2 -19
- package/lib/types/dsh-adapter/transcript-images.d.ts.map +1 -1
- package/lib/types/dsh-adapter/workspaces.d.ts +2 -49
- package/lib/types/dsh-adapter/workspaces.d.ts.map +1 -1
- package/lib/types/dsh-adapter/workspaces.js +23 -3
- package/lib/types/i18n.d.ts +19 -7
- package/lib/types/i18n.d.ts.map +1 -1
- package/lib/types/i18n.js +8 -3
- package/lib/types/ink/components/ScrollBox.d.ts.map +1 -1
- package/lib/types/ink/components/ScrollBox.js +30 -33
- package/lib/types/ink/dom.d.ts.map +1 -1
- package/lib/types/ink/dom.js +32 -64
- package/lib/types/ink/get-max-width.d.ts +7 -15
- package/lib/types/ink/get-max-width.d.ts.map +1 -1
- package/lib/types/ink/get-max-width.js +7 -20
- package/lib/types/ink/ink.d.ts +1 -0
- package/lib/types/ink/ink.d.ts.map +1 -1
- package/lib/types/ink/ink.js +22 -3
- package/lib/types/ink/layout/node.d.ts +2 -0
- package/lib/types/ink/layout/node.d.ts.map +1 -1
- package/lib/types/ink/layout/yoga.d.ts +1 -0
- package/lib/types/ink/layout/yoga.d.ts.map +1 -1
- package/lib/types/ink/layout/yoga.js +3 -0
- package/lib/types/ink/node-cache.d.ts +11 -0
- package/lib/types/ink/node-cache.d.ts.map +1 -1
- package/lib/types/ink/node-cache.js +3 -0
- package/lib/types/ink/output.d.ts +6 -1
- package/lib/types/ink/output.d.ts.map +1 -1
- package/lib/types/ink/output.js +55 -65
- package/lib/types/ink/render-node-to-output.d.ts +24 -1
- package/lib/types/ink/render-node-to-output.d.ts.map +1 -1
- package/lib/types/ink/render-node-to-output.js +195 -71
- package/lib/types/ink/renderer.d.ts.map +1 -1
- package/lib/types/ink/renderer.js +14 -2
- package/lib/types/ink/styles.d.ts +12 -0
- package/lib/types/ink/styles.d.ts.map +1 -1
- package/lib/types/ink/tabstops.d.ts +3 -2
- package/lib/types/ink/tabstops.d.ts.map +1 -1
- package/lib/types/ink/tabstops.js +5 -4
- package/lib/types/ink/wrap-text.js +2 -2
- package/lib/types/modelGroups.d.ts +1 -1
- package/lib/types/modelGroups.d.ts.map +1 -1
- package/lib/types/modelRoute.js +1 -1
- package/lib/types/native-ts/yoga-layout/index.d.ts +8 -3
- package/lib/types/native-ts/yoga-layout/index.d.ts.map +1 -1
- package/lib/types/native-ts/yoga-layout/index.js +23 -8
- package/lib/types/plugin-host.d.ts +3 -4
- package/lib/types/plugin-host.d.ts.map +1 -1
- package/lib/types/plugin-host.js +8 -6
- package/lib/types/screens/AgentView.d.ts +1 -1
- package/lib/types/screens/AgentView.d.ts.map +1 -1
- package/lib/types/screens/Chat.d.ts +3 -2
- package/lib/types/screens/Chat.d.ts.map +1 -1
- package/lib/types/screens/Chat.js +91 -17
- package/lib/types/screens/SessionBrowser.d.ts +1 -1
- package/lib/types/screens/SessionBrowser.d.ts.map +1 -1
- package/lib/types/screens/SessionTree.d.ts +1 -1
- package/lib/types/screens/SessionTree.d.ts.map +1 -1
- package/lib/types/screens/Settings.d.ts +1 -1
- package/lib/types/screens/Settings.d.ts.map +1 -1
- package/lib/types/screens/StatusLine.d.ts +1 -1
- package/lib/types/screens/StatusLine.d.ts.map +1 -1
- package/lib/types/screens/StatusLine.js +40 -1
- package/lib/types/screens/TrajectoryScene.d.ts +1 -1
- package/lib/types/screens/TrajectoryScene.d.ts.map +1 -1
- package/lib/types/sessionModes.d.ts +11 -15
- package/lib/types/sessionModes.d.ts.map +1 -1
- package/lib/types/sessionModes.js +11 -0
- package/lib/types/tuiDisplayPrefs.d.ts +2 -68
- package/lib/types/tuiDisplayPrefs.d.ts.map +1 -1
- package/lib/types/tuiDisplayPrefs.js +5 -1
- package/lib/types/utils/credentials.d.ts +13 -0
- package/lib/types/utils/credentials.d.ts.map +1 -0
- package/lib/types/utils/credentials.js +41 -0
- package/lib/types/utils/fileSuggestions.d.ts +2 -9
- package/lib/types/utils/fileSuggestions.d.ts.map +1 -1
- package/lib/types/utils/fold-long-lines.d.ts +38 -0
- package/lib/types/utils/fold-long-lines.d.ts.map +1 -0
- package/lib/types/utils/fold-long-lines.js +91 -0
- package/node_modules/@deepseek-harness-tui/dsh-auth/lib/pi-ai.d.ts +1 -1
- package/node_modules/@deepseek-harness-tui/dsh-auth/lib/profiles.js +4 -0
- package/node_modules/@deepseek-harness-tui/dsh-auth/lib/service.js +15 -2
- package/node_modules/@deepseek-harness-tui/dsh-auth/package.json +10 -10
- package/package.json +125 -81
- package/presets/liangshen/.dsh-tui-managed.json +1 -1
- package/presets/liangshen/agent.cordis.yml +20 -4
- package/presets/liangshen/compaction-epoch.mjs +3 -1
- package/presets/liangshen/instruction-hint.mjs +2 -1
- package/presets/liangshen/session-events.mjs +8 -0
- package/lib/types/dsh-adapter/grants.d.ts.map +0 -1
- package/lib/types/dsh-adapter/host-descriptor.d.ts +0 -24
- package/lib/types/dsh-adapter/host-descriptor.d.ts.map +0 -1
- package/lib/types/dsh-adapter/host-descriptor.js +0 -169
- package/lib/types/dsh-adapter/plugin-test-utils.d.ts +0 -62
- package/lib/types/dsh-adapter/plugin-test-utils.d.ts.map +0 -1
- package/lib/types/dsh-adapter/plugin-test-utils.js +0 -61
- package/lib/types/plugin-spec/negotiate.d.ts.map +0 -1
- package/lib/types/plugin-spec/permission-scope.d.ts.map +0 -1
- package/lib/types/plugin-spec/registry.d.ts.map +0 -1
- package/lib/types/plugin-spec/schema-check.d.ts.map +0 -1
- package/lib/types/plugin-spec/tui-extension.d.ts +0 -16
- package/lib/types/plugin-spec/tui-extension.d.ts.map +0 -1
- package/lib/types/plugin-spec/tui-extension.js +0 -79
- package/lib/types/plugin-spec/types.d.ts.map +0 -1
- package/lib/types/plugin-spec/validate.d.ts.map +0 -1
- package/lib/types/test-utils.d.ts +0 -2
- package/lib/types/test-utils.d.ts.map +0 -1
- package/lib/types/test-utils.js +0 -8
- /package/lib/types/{plugin-spec → adapter/standard}/negotiate.d.ts +0 -0
- /package/lib/types/{plugin-spec → adapter/standard}/negotiate.js +0 -0
- /package/lib/types/{plugin-spec → adapter/standard}/registry.d.ts +0 -0
- /package/lib/types/{plugin-spec → adapter/standard}/schema-check.d.ts +0 -0
- /package/lib/types/{plugin-spec → adapter/standard}/types.js +0 -0
|
@@ -10,7 +10,8 @@ import { SyntaxText } from '../SyntaxText.js';
|
|
|
10
10
|
import { useTooltip } from '../Tooltip.js';
|
|
11
11
|
import { formatDuration } from '../../terminal-utils/format.js';
|
|
12
12
|
import { formatClock } from '../../trajectory/format.js';
|
|
13
|
-
import {
|
|
13
|
+
import { foldLongLines } from '../../utils/fold-long-lines.js';
|
|
14
|
+
import { getLang, t } from '../../i18n.js';
|
|
14
15
|
import { revealLinesOf, snapReveal } from '../smoothReveal.js';
|
|
15
16
|
import { useRevealVersion } from '../../hooks/useRevealVersion.js';
|
|
16
17
|
/** Tool display names: DSH emits lowercase tool ids (`bash`); display common
|
|
@@ -189,6 +190,28 @@ function capLines(lines, max, verbose) {
|
|
|
189
190
|
{ ...dim(`… +${lines.length - max} lines (ctrl+o to expand)`), revealOnHover: true },
|
|
190
191
|
];
|
|
191
192
|
}
|
|
193
|
+
/** Long-line clip for the body rows (utils/fold-long-lines.ts): the line cap
|
|
194
|
+
* above bounds how MANY rows a card paints, this bounds how many rows ONE
|
|
195
|
+
* row can paint. A `read` of a minified file, a terminal result whose last
|
|
196
|
+
* line never broke, or a `write` payload is a single 100k-char line — under
|
|
197
|
+
* `wrap="wrap"` the body would lay out thousands of visual rows per frame
|
|
198
|
+
* no matter what the line budget says. Identity-preserving (same array, same
|
|
199
|
+
* line objects) when every line fits, so the ordinary card allocates
|
|
200
|
+
* nothing. */
|
|
201
|
+
function foldBodyLines(lines) {
|
|
202
|
+
let out;
|
|
203
|
+
for (let index = 0; index < lines.length; index++) {
|
|
204
|
+
const line = lines[index];
|
|
205
|
+
const folded = foldLongLines(line.text);
|
|
206
|
+
if (folded.hiddenChars === 0) {
|
|
207
|
+
out?.push(line);
|
|
208
|
+
continue;
|
|
209
|
+
}
|
|
210
|
+
out ??= lines.slice(0, index);
|
|
211
|
+
out.push({ ...line, text: folded.text });
|
|
212
|
+
}
|
|
213
|
+
return out ?? lines;
|
|
214
|
+
}
|
|
192
215
|
/** Header title from the presentation view: terminal cards keep the
|
|
193
216
|
* `Name(command)` shape; everything else renders the tool's own title
|
|
194
217
|
* (`Edit /path`, `Read /path (1 - 100)`) with the first word bold. The
|
|
@@ -211,21 +234,35 @@ function clipHeaderArgs(args) {
|
|
|
211
234
|
* hundreds of KB, and the exact cost the HEADER_ARGS_BUDGET comment above
|
|
212
235
|
* keeps out of the header must not sneak back in through folding. (Lone-\r
|
|
213
236
|
* titles are not a thing presentCall produces; CRLF is normalized on the
|
|
214
|
-
* first line only.)
|
|
215
|
-
*
|
|
216
|
-
|
|
237
|
+
* first line only.)
|
|
238
|
+
*
|
|
239
|
+
* Two independent folds:
|
|
240
|
+
* - `foldLines` (the `dsh-tui.foldTerminalCommand` setting): a multi-line
|
|
241
|
+
* script collapses to its first source line, reported as `+N lines`.
|
|
242
|
+
* - The long-line clip (always on — utils/fold-long-lines.ts): a command is
|
|
243
|
+
* frequently ONE enormous line (`python -c …`, a minified blob, a pasted
|
|
244
|
+
* `curl` body). This header Text WRAPS, so an unclipped 200k-char command
|
|
245
|
+
* lays out thousands of rows on the card header itself — the same stall
|
|
246
|
+
* HEADER_ARGS_BUDGET keeps out of the args half of the line.
|
|
247
|
+
*
|
|
248
|
+
* Single short titles return undefined: nothing to fold, rendering stays
|
|
249
|
+
* byte-identical to the unfolded card (and the header stays tooltip-silent). */
|
|
250
|
+
function foldTerminalTitle(title, foldLines) {
|
|
217
251
|
const firstEnd = title.indexOf('\n');
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
252
|
+
let hiddenLines = 0;
|
|
253
|
+
let body = title;
|
|
254
|
+
if (firstEnd !== -1 && foldLines) {
|
|
255
|
+
let separators = 1;
|
|
256
|
+
for (let at = title.indexOf('\n', firstEnd + 1); at !== -1; at = title.indexOf('\n', at + 1))
|
|
257
|
+
separators++;
|
|
258
|
+
// Same trailing-newline rule as sideLines: a terminator is not a line.
|
|
259
|
+
hiddenLines = separators - (title.endsWith('\n') ? 1 : 0);
|
|
260
|
+
body = title.slice(0, title.charCodeAt(firstEnd - 1) === 13 ? firstEnd - 1 : firstEnd);
|
|
261
|
+
}
|
|
262
|
+
const clipped = foldLongLines(body);
|
|
263
|
+
if (hiddenLines <= 0 && clipped.hiddenChars === 0)
|
|
226
264
|
return undefined;
|
|
227
|
-
|
|
228
|
-
return { first, hidden };
|
|
265
|
+
return { first: clipped.text, hiddenLines: Math.max(0, hiddenLines), hiddenChars: clipped.hiddenChars };
|
|
229
266
|
}
|
|
230
267
|
/** Addendum line appended to the header hover tooltip when the header hides
|
|
231
268
|
* content (folded script / clipped args / width-truncated title): start or
|
|
@@ -289,7 +326,7 @@ function HeaderTitle({ name, title, isTerminal, folded, displayArgs, argsLanguag
|
|
|
289
326
|
return (_jsxs(_Fragment, { children: [_jsx(Box, { flexShrink: 0, children: _jsx(Text, { bold: true, color: nameColor, wrap: "truncate-end", children: name }) }), displayArgs !== '' && (_jsxs(Box, { flexWrap: "nowrap", ...headerTooltip, children: [_jsx(Text, { children: "(" }), _jsx(SyntaxText, { text: clipHeaderArgs(displayArgs), sourceText: displayArgs, language: argsLanguage }), _jsx(Text, { children: ")" })] }))] }));
|
|
290
327
|
}
|
|
291
328
|
if (isTerminal) {
|
|
292
|
-
return (_jsxs(_Fragment, { children: [_jsx(Box, { flexShrink: 0, children: _jsx(Text, { bold: true, color: nameColor, wrap: "truncate-end", children: name }) }), _jsx(Box, { flexWrap: "nowrap", ...headerTooltip, children: folded === undefined ? (_jsxs(Text, { children: ["(", title, ")"] })) : (_jsxs(_Fragment, { children: [_jsxs(Text, { children: ["(", folded.first, ")"] }), _jsx(Text, { dimColor: true, children: ` … +${folded.
|
|
329
|
+
return (_jsxs(_Fragment, { children: [_jsx(Box, { flexShrink: 0, children: _jsx(Text, { bold: true, color: nameColor, wrap: "truncate-end", children: name }) }), _jsx(Box, { flexWrap: "nowrap", ...headerTooltip, children: folded === undefined ? (_jsxs(Text, { children: ["(", title, ")"] })) : (_jsxs(_Fragment, { children: [_jsxs(Text, { children: ["(", folded.first, ")"] }), folded.hiddenLines > 0 && (_jsx(Text, { dimColor: true, children: ` … +${folded.hiddenLines} lines (ctrl+o to expand)` }))] })) })] }));
|
|
293
330
|
}
|
|
294
331
|
const trimmed = title.trim();
|
|
295
332
|
if (trimmed === '') {
|
|
@@ -345,14 +382,17 @@ export function AssistantToolUseMessage({ tool, marginTopOnTurn, verbose, isSele
|
|
|
345
382
|
// command) — then the call view's title stands.
|
|
346
383
|
const headerTitle = tool.resultView?.title ?? tool.callView?.title;
|
|
347
384
|
const headerIsTerminal = view?.card === 'terminal';
|
|
348
|
-
// Fold
|
|
349
|
-
//
|
|
350
|
-
// `verbose`, so expansion reuses the
|
|
351
|
-
// the title reference: settled titles
|
|
352
|
-
// useAnimationFrame tick of a running card
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
385
|
+
// Fold the terminal header: multi-line command script (setting-gated) plus
|
|
386
|
+
// the always-on long-line clip, both off once the card is verbose/expanded
|
|
387
|
+
// (Ctrl+O and the row click both land in `verbose`, so expansion reuses the
|
|
388
|
+
// existing state machine). Memoized on the title reference: settled titles
|
|
389
|
+
// never change, so the 1s useAnimationFrame tick of a running card
|
|
390
|
+
// re-renders without rescanning. `lang` joins the deps because the inline
|
|
391
|
+
// marker is localized.
|
|
392
|
+
const lang = getLang();
|
|
393
|
+
const foldedHeader = React.useMemo(() => headerIsTerminal && !verbose && headerTitle !== undefined
|
|
394
|
+
? foldTerminalTitle(headerTitle, foldTerminalCommand)
|
|
395
|
+
: undefined, [headerIsTerminal, foldTerminalCommand, verbose, headerTitle, lang]);
|
|
356
396
|
// Live elapsed clock while the call runs: the
|
|
357
397
|
// 1s tick re-renders the card; elapsed derives from wall-clock refs.
|
|
358
398
|
const [viewportRef] = useAnimationFrame(isRunning ? 1000 : null);
|
|
@@ -403,11 +443,15 @@ export function AssistantToolUseMessage({ tool, marginTopOnTurn, verbose, isSele
|
|
|
403
443
|
}
|
|
404
444
|
}
|
|
405
445
|
const cap = view?.card === 'diff' ? DIFF_BODY_MAX_LINES : TEXT_BODY_MAX_LINES;
|
|
406
|
-
|
|
446
|
+
// Long-line clip before anything downstream reads the body: the syntax
|
|
447
|
+
// highlighter walks `bodySource` by line index, so the folded text must be
|
|
448
|
+
// the single source of truth for both.
|
|
449
|
+
const bodyLines = verbose ? body : foldBodyLines(body);
|
|
450
|
+
const bodySource = bodyLines.map(line => line.text).join('\n');
|
|
407
451
|
const argsLanguage = jsonArgsLanguage(displayArgs);
|
|
408
452
|
// The footnote rides OUTSIDE the cap: it is a pointer, not content, and a
|
|
409
453
|
// long error body must not be the reason it disappears.
|
|
410
|
-
const lines = capLines(
|
|
454
|
+
const lines = capLines(bodyLines, cap, verbose);
|
|
411
455
|
const rendered = footnote === undefined ? lines : [...lines, { text: footnote, tone: 'hint' }];
|
|
412
456
|
// Smooth reveal (line-unit, pending CALL body only): model-authored prose
|
|
413
457
|
// (diff hunks, write content) flows in at ~30fps; the settled RESULT view,
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* OverlayAbove 高度预算的纯计算。
|
|
3
|
+
*
|
|
4
|
+
* 浮层用 bottom:'100%' 钉在锚点顶边向上生长;渲染器对 y<0 的行只裁不移
|
|
5
|
+
* (render-node-to-output.ts 刻意不再把浮层整体下移压住 composer)。所以
|
|
6
|
+
* 浮层高度一旦超过锚点上方可画的行数,顶部就整行消失——短会话 + 高终端下
|
|
7
|
+
* /model 的窗口按 terminalRows 预算,焦点行落在被裁区完全不可见(#493),
|
|
8
|
+
* 供应商模型多时列表混乱(#698)。生产方必须把 maxHeight 钳到实际空间,
|
|
9
|
+
* 这里是那条钳制的纯函数面,便于回归脚本直接断言不变量。
|
|
10
|
+
*/
|
|
11
|
+
/**
|
|
12
|
+
* 锚点上方可画的行数。
|
|
13
|
+
*
|
|
14
|
+
* inline 模式根帧可以高于终端:可见视口是帧尾 terminalRows 行(外加 Ink
|
|
15
|
+
* 的一行光标恢复行),帧顶被推进 scrollback 的部分不可画——与
|
|
16
|
+
* ImagePreviewOverlay 的视口换算一致。
|
|
17
|
+
*
|
|
18
|
+
* @param anchorTop - 锚点在根帧内的绝对 top(沿祖先累加 yoga computedTop)。
|
|
19
|
+
* @param rootHeight - 根帧高度。
|
|
20
|
+
* @param terminalRows - 终端真实行数。
|
|
21
|
+
* @returns 锚点顶边之上、视口之内的行数(≥0)。
|
|
22
|
+
*/
|
|
23
|
+
export declare function overlaySpaceAbove(input: {
|
|
24
|
+
anchorTop: number;
|
|
25
|
+
rootHeight: number;
|
|
26
|
+
terminalRows: number;
|
|
27
|
+
}): number;
|
|
28
|
+
/**
|
|
29
|
+
* 浮层的有效 maxHeight:调用方声明的上限与锚点上方空间取小。
|
|
30
|
+
*
|
|
31
|
+
* 尚未量到空间(首次挂载前没有布局)时沿用声明值;量到后至少 1 行——0 行
|
|
32
|
+
* maxHeight 在 yoga 里等于面板消失,用户以为 picker 没打开。
|
|
33
|
+
*
|
|
34
|
+
* @param maxHeight - 调用方声明的上限(可缺省)。
|
|
35
|
+
* @param spaceAbove - overlaySpaceAbove 的结果(未量到时 undefined)。
|
|
36
|
+
* @returns 传给浮层 Box 的 maxHeight(两者都缺省时 undefined)。
|
|
37
|
+
*/
|
|
38
|
+
export declare function clampOverlayHeight(maxHeight: number | undefined, spaceAbove: number | undefined): number | undefined;
|
|
39
|
+
//# sourceMappingURL=overlayBudget.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"overlayBudget.d.ts","sourceRoot":"","sources":["../../../src/components/overlayBudget.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAEH;;;;;;;;;;;GAWG;AACH,wBAAgB,iBAAiB,CAAC,KAAK,EAAE;IACvC,SAAS,EAAE,MAAM,CAAA;IACjB,UAAU,EAAE,MAAM,CAAA;IAClB,YAAY,EAAE,MAAM,CAAA;CACrB,GAAG,MAAM,CAIT;AAED;;;;;;;;;GASG;AACH,wBAAgB,kBAAkB,CAChC,SAAS,EAAE,MAAM,GAAG,SAAS,EAC7B,UAAU,EAAE,MAAM,GAAG,SAAS,GAC7B,MAAM,GAAG,SAAS,CAIpB"}
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* OverlayAbove 高度预算的纯计算。
|
|
3
|
+
*
|
|
4
|
+
* 浮层用 bottom:'100%' 钉在锚点顶边向上生长;渲染器对 y<0 的行只裁不移
|
|
5
|
+
* (render-node-to-output.ts 刻意不再把浮层整体下移压住 composer)。所以
|
|
6
|
+
* 浮层高度一旦超过锚点上方可画的行数,顶部就整行消失——短会话 + 高终端下
|
|
7
|
+
* /model 的窗口按 terminalRows 预算,焦点行落在被裁区完全不可见(#493),
|
|
8
|
+
* 供应商模型多时列表混乱(#698)。生产方必须把 maxHeight 钳到实际空间,
|
|
9
|
+
* 这里是那条钳制的纯函数面,便于回归脚本直接断言不变量。
|
|
10
|
+
*/
|
|
11
|
+
/**
|
|
12
|
+
* 锚点上方可画的行数。
|
|
13
|
+
*
|
|
14
|
+
* inline 模式根帧可以高于终端:可见视口是帧尾 terminalRows 行(外加 Ink
|
|
15
|
+
* 的一行光标恢复行),帧顶被推进 scrollback 的部分不可画——与
|
|
16
|
+
* ImagePreviewOverlay 的视口换算一致。
|
|
17
|
+
*
|
|
18
|
+
* @param anchorTop - 锚点在根帧内的绝对 top(沿祖先累加 yoga computedTop)。
|
|
19
|
+
* @param rootHeight - 根帧高度。
|
|
20
|
+
* @param terminalRows - 终端真实行数。
|
|
21
|
+
* @returns 锚点顶边之上、视口之内的行数(≥0)。
|
|
22
|
+
*/
|
|
23
|
+
export function overlaySpaceAbove(input) {
|
|
24
|
+
const { anchorTop, rootHeight, terminalRows } = input;
|
|
25
|
+
const viewportTop = rootHeight > terminalRows ? rootHeight - terminalRows + 1 : 0;
|
|
26
|
+
return Math.max(0, anchorTop - viewportTop);
|
|
27
|
+
}
|
|
28
|
+
/**
|
|
29
|
+
* 浮层的有效 maxHeight:调用方声明的上限与锚点上方空间取小。
|
|
30
|
+
*
|
|
31
|
+
* 尚未量到空间(首次挂载前没有布局)时沿用声明值;量到后至少 1 行——0 行
|
|
32
|
+
* maxHeight 在 yoga 里等于面板消失,用户以为 picker 没打开。
|
|
33
|
+
*
|
|
34
|
+
* @param maxHeight - 调用方声明的上限(可缺省)。
|
|
35
|
+
* @param spaceAbove - overlaySpaceAbove 的结果(未量到时 undefined)。
|
|
36
|
+
* @returns 传给浮层 Box 的 maxHeight(两者都缺省时 undefined)。
|
|
37
|
+
*/
|
|
38
|
+
export function clampOverlayHeight(maxHeight, spaceAbove) {
|
|
39
|
+
if (spaceAbove === undefined)
|
|
40
|
+
return maxHeight;
|
|
41
|
+
const bound = maxHeight === undefined ? spaceAbove : Math.min(maxHeight, spaceAbove);
|
|
42
|
+
return Math.max(1, bound);
|
|
43
|
+
}
|
|
@@ -1,39 +1,5 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
*
|
|
4
|
-
* 纯函数模块:只负责"用 key 换余额",密钥由调用方(channel 的 credentials
|
|
5
|
-
* seam → 环境变量兜底)解析,绝不在此打印或持久化。查询接口本身是只读的,
|
|
6
|
-
* 不消耗 API 额度(社区插件均按秒/分钟级轮询使用)。
|
|
7
|
-
*
|
|
8
|
-
* 响应结构(官方文档):
|
|
9
|
-
* { "is_available": true, "balance_infos": [
|
|
10
|
-
* { "currency": "CNY", "total_balance": "110.00",
|
|
11
|
-
* "granted_balance": "10.00", "topped_up_balance": "100.00" } ] }
|
|
12
|
-
* 余额字段是字符串数字;`granted` 为赠送余额,`topped_up` 为充值余额,
|
|
13
|
-
* 扣费优先扣赠送余额。
|
|
14
|
-
*/
|
|
15
|
-
/** 单个币种的余额快照(元)。 */
|
|
16
|
-
export interface BalanceInfo {
|
|
17
|
-
currency: string;
|
|
18
|
-
/** 总余额 = granted + toppedUp。 */
|
|
19
|
-
total: number;
|
|
20
|
-
/** 赠送余额。 */
|
|
21
|
-
granted: number;
|
|
22
|
-
/** 充值余额。 */
|
|
23
|
-
toppedUp: number;
|
|
24
|
-
}
|
|
25
|
-
export type BalanceResult = {
|
|
26
|
-
readonly ok: true;
|
|
27
|
-
/** 账户是否可用(是否有可用额度)。 */
|
|
28
|
-
readonly isAvailable: boolean;
|
|
29
|
-
readonly balances: readonly BalanceInfo[];
|
|
30
|
-
} | {
|
|
31
|
-
readonly ok: false;
|
|
32
|
-
/** 失败分类:无 key / 网络或超时 / 认证失败 / 非 2xx / 响应结构非法。 */
|
|
33
|
-
readonly reason: 'no-key' | 'network' | 'unauthorized' | 'http' | 'invalid';
|
|
34
|
-
/** 非 2xx 时的 HTTP 状态码(其余分类无)。 */
|
|
35
|
-
readonly status?: number;
|
|
36
|
-
};
|
|
1
|
+
import type { BalanceResult } from './adapter/ports/channel-catalog.js';
|
|
2
|
+
export type { BalanceResult, BalanceInfo } from './adapter/ports/channel-catalog.js';
|
|
37
3
|
/** 查询选项;fetchImpl 供无头回归注入。 */
|
|
38
4
|
export interface BalanceQueryOptions {
|
|
39
5
|
/** 覆盖全局 fetch(测试注入)。 */
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"deepseekBalance.d.ts","sourceRoot":"","sources":["../../src/deepseekBalance.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"deepseekBalance.d.ts","sourceRoot":"","sources":["../../src/deepseekBalance.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAe,MAAM,oCAAoC,CAAA;AACpF,YAAY,EAAE,aAAa,EAAE,WAAW,EAAE,MAAM,oCAAoC,CAAA;AAGpF,8BAA8B;AAC9B,MAAM,WAAW,mBAAmB;IAClC,wBAAwB;IACxB,SAAS,CAAC,EAAE,OAAO,KAAK,CAAA;IACxB,yBAAyB;IACzB,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB,qBAAqB;IACrB,SAAS,CAAC,EAAE,MAAM,CAAA;CACnB;AAED,eAAO,MAAM,yBAAyB,0CAA0C,CAAA;AAIhF;;;;GAIG;AACH,wBAAsB,YAAY,CAChC,MAAM,EAAE,MAAM,EACd,OAAO,GAAE,mBAAwB,GAChC,OAAO,CAAC,aAAa,CAAC,CA4BxB"}
|
|
@@ -1,17 +1,3 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* DeepSeek 官方账户余额查询(`GET /user/balance`)。
|
|
3
|
-
*
|
|
4
|
-
* 纯函数模块:只负责"用 key 换余额",密钥由调用方(channel 的 credentials
|
|
5
|
-
* seam → 环境变量兜底)解析,绝不在此打印或持久化。查询接口本身是只读的,
|
|
6
|
-
* 不消耗 API 额度(社区插件均按秒/分钟级轮询使用)。
|
|
7
|
-
*
|
|
8
|
-
* 响应结构(官方文档):
|
|
9
|
-
* { "is_available": true, "balance_infos": [
|
|
10
|
-
* { "currency": "CNY", "total_balance": "110.00",
|
|
11
|
-
* "granted_balance": "10.00", "topped_up_balance": "100.00" } ] }
|
|
12
|
-
* 余额字段是字符串数字;`granted` 为赠送余额,`topped_up` 为充值余额,
|
|
13
|
-
* 扣费优先扣赠送余额。
|
|
14
|
-
*/
|
|
15
1
|
export const DEEPSEEK_BALANCE_ENDPOINT = 'https://api.deepseek.com/user/balance';
|
|
16
2
|
const DEFAULT_TIMEOUT_MS = 8000;
|
|
17
3
|
/**
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* DeepSeek 官方定价与"本会话花费"估算(人民币口径)。
|
|
3
3
|
*
|
|
4
|
-
* 数据来源:DeepSeek 官方文档「模型 & 价格」页(2026-
|
|
4
|
+
* 数据来源:DeepSeek 官方文档「模型 & 价格」页(2026-09 快照,含
|
|
5
|
+
* V4.1-Flash 发布调价),单位为人民
|
|
5
6
|
* 币/百万 tokens。DeepSeek 官方 API 只返回 token 用量、不返回金额,本模块按
|
|
6
7
|
* 官方公开单价把会话累计 token 换算成金额 —— 这是**估算**,不是账单:
|
|
7
8
|
* 定价可能变动,且余额扣费发生在 DeepSeek 侧(以平台账单为准)。
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"deepseekPricing.d.ts","sourceRoot":"","sources":["../../src/deepseekPricing.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"deepseekPricing.d.ts","sourceRoot":"","sources":["../../src/deepseekPricing.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAEH,uCAAuC;AACvC,MAAM,MAAM,aAAa,GAAG,SAAS,CAAC,MAAM,EAAE,MAAM,CAAC,CAAA;AAErD,kCAAkC;AAClC,MAAM,WAAW,kBAAkB;IACjC,yBAAyB;IACzB,SAAS,EAAE,aAAa,CAAA;IACxB,gBAAgB;IAChB,QAAQ,EAAE,aAAa,CAAA;IACvB,UAAU;IACV,MAAM,EAAE,aAAa,CAAA;CACtB;AAED;;;;GAIG;AACH,eAAO,MAAM,qBAAqB,EAAE,QAAQ,CAAC,MAAM,CAAC,MAAM,EAAE,kBAAkB,CAAC,CAsB9E,CAAA;AAED;;;;;GAKG;AACH,eAAO,MAAM,2BAA2B,EAAE,SAAS,MAAM,EAIxD,CAAA;AAED,gDAAgD;AAChD,wBAAgB,0BAA0B,CAAC,QAAQ,EAAE,MAAM,GAAG,OAAO,CAEpE;AAED;;;GAGG;AACH,wBAAgB,UAAU,CAAC,IAAI,GAAE,IAAiB,GAAG,OAAO,CAM3D;AAED,wCAAwC;AACxC,wBAAgB,aAAa,CAAC,KAAK,EAAE,MAAM,GAAG,kBAAkB,GAAG,SAAS,CAU3E;AAED,6CAA6C;AAC7C,MAAM,WAAW,eAAe;IAC9B,KAAK,EAAE,MAAM,CAAA;IACb,MAAM,EAAE,MAAM,CAAA;IACd,SAAS,EAAE,MAAM,CAAA;IACjB,UAAU,EAAE,MAAM,CAAA;CACnB;AAED;;;GAGG;AACH,MAAM,WAAW,gBAAgB;IAC/B,IAAI,EAAE,eAAe,CAAA;IACrB,IAAI,EAAE,eAAe,CAAA;CACtB;AAiCD;;;;;;;;;GASG;AACH,wBAAgB,2BAA2B,CACzC,MAAM,EAAE,gBAAgB,EACxB,KAAK,EAAE,MAAM,GACZ;IAAE,KAAK,EAAE,MAAM,CAAC;IAAC,IAAI,EAAE,MAAM,CAAC;IAAC,IAAI,EAAE,MAAM,CAAA;CAAE,GAAG,SAAS,CAc3D;AAED;;GAEG;AACH,wBAAgB,sBAAsB,CACpC,MAAM,EAAE,gBAAgB,EACxB,KAAK,EAAE,MAAM,GACZ,MAAM,GAAG,SAAS,CAEpB"}
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* DeepSeek 官方定价与"本会话花费"估算(人民币口径)。
|
|
3
3
|
*
|
|
4
|
-
* 数据来源:DeepSeek 官方文档「模型 & 价格」页(2026-
|
|
4
|
+
* 数据来源:DeepSeek 官方文档「模型 & 价格」页(2026-09 快照,含
|
|
5
|
+
* V4.1-Flash 发布调价),单位为人民
|
|
5
6
|
* 币/百万 tokens。DeepSeek 官方 API 只返回 token 用量、不返回金额,本模块按
|
|
6
7
|
* 官方公开单价把会话累计 token 换算成金额 —— 这是**估算**,不是账单:
|
|
7
8
|
* 定价可能变动,且余额扣费发生在 DeepSeek 侧(以平台账单为准)。
|
|
@@ -18,6 +19,12 @@
|
|
|
18
19
|
* token 用量),不会给出错误数字。
|
|
19
20
|
*/
|
|
20
21
|
export const DEEPSEEK_MODEL_PRICES = {
|
|
22
|
+
// DeepSeek-V41-Flash(2026-09-10 发布并取代 V4-Pro 后的下调价目)。
|
|
23
|
+
'deepseek-flash': {
|
|
24
|
+
inputMiss: [1.0, 2.0],
|
|
25
|
+
inputHit: [0.02, 0.04],
|
|
26
|
+
output: [4.0, 8.0],
|
|
27
|
+
},
|
|
21
28
|
'deepseek-v4-flash': {
|
|
22
29
|
inputMiss: [1.5, 3.0],
|
|
23
30
|
inputHit: [0.05, 0.10],
|
|
@@ -13,6 +13,8 @@
|
|
|
13
13
|
* `'rejected'` from the panel, `'cancelled'` on abort/teardown; there is
|
|
14
14
|
* no allow-always or feedback channel in the protocol.
|
|
15
15
|
*/
|
|
16
|
+
import { compositionRoot } from './host-access.js';
|
|
17
|
+
import { type AdapterRuntimeOptions } from '../adapter/kernel/runtime.js';
|
|
16
18
|
import type { ApprovalOutcome, ApprovalRequest } from '@deepseek-ai/dsh-user-approval';
|
|
17
19
|
import type { SessionEvent } from '@deepseek-ai/dsh-session';
|
|
18
20
|
/** What the TUI renders while an approval is pending. */
|
|
@@ -48,6 +50,10 @@ export interface ApprovalSnapshot {
|
|
|
48
50
|
*/
|
|
49
51
|
readonly agentId: string;
|
|
50
52
|
}
|
|
53
|
+
/** Host-only registration used by the TUI plugin bootstrap. */
|
|
54
|
+
export declare function bindApprovalStore(ctx: Parameters<typeof compositionRoot>[0], store: ApprovalStore): void;
|
|
55
|
+
/** Host-only lookup used by the presentation Port bridge. */
|
|
56
|
+
export declare function getApprovalStore(ctx: Parameters<typeof compositionRoot>[0]): ApprovalStore | undefined;
|
|
51
57
|
/**
|
|
52
58
|
* Approval store: parks asks from the harness's approval seam, surfaces
|
|
53
59
|
* one at a time to the TUI, and settles each ask when the user decides or
|
|
@@ -55,6 +61,8 @@ export interface ApprovalSnapshot {
|
|
|
55
61
|
* {@link ApprovalStore.decide}.
|
|
56
62
|
*/
|
|
57
63
|
export declare class ApprovalStore {
|
|
64
|
+
private readonly runtime;
|
|
65
|
+
constructor(runtime?: AdapterRuntimeOptions);
|
|
58
66
|
private readonly queue;
|
|
59
67
|
private active;
|
|
60
68
|
private readonly listeners;
|
|
@@ -150,9 +158,10 @@ export declare class ApprovalStore {
|
|
|
150
158
|
* different session than the active ask's. The notification the SDK
|
|
151
159
|
* fires arrives after the event is already in the live session log, so the
|
|
152
160
|
* recheck sees the settled result.
|
|
161
|
+
* @param agentId - The emitting session's id (DSH shares agent/session identity).
|
|
153
162
|
* @param event - The appended session event.
|
|
154
163
|
*/
|
|
155
|
-
noteSessionEvent(event: SessionEvent): void;
|
|
164
|
+
noteSessionEvent(agentId: string, event: SessionEvent): void;
|
|
156
165
|
/**
|
|
157
166
|
* Whether another ask with this callId is already parked (active or
|
|
158
167
|
* queued). A genuine approval is raised once per gated tool call — the
|
|
@@ -208,6 +217,7 @@ export declare class ApprovalStore {
|
|
|
208
217
|
* monotonic and never erased. Deliberately badges instead of cancelling:
|
|
209
218
|
* cancelling both would hand the attacker a force-cancel primitive
|
|
210
219
|
* against genuine approvals.
|
|
220
|
+
* @param agentId - The agent domain owning the duplicated call id.
|
|
211
221
|
* @param callId - The duplicated call id (non-undefined by construction).
|
|
212
222
|
*/
|
|
213
223
|
private markCallIdAmbiguous;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"approvals.d.ts","sourceRoot":"","sources":["../../../src/dsh-adapter/approvals.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAEH,OAAO,KAAK,EAAE,eAAe,EAAE,eAAe,EAAE,MAAM,gCAAgC,CAAA;AACtF,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,0BAA0B,CAAA;AAG5D,yDAAyD;AACzD,MAAM,WAAW,gBAAgB;IAC/B,wEAAwE;IACxE,QAAQ,CAAC,GAAG,EAAE,MAAM,CAAA;IACpB,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAA;IACzB,0DAA0D;IAC1D,QAAQ,CAAC,MAAM,CAAC,EAAE,MAAM,CAAA;IACxB,oEAAoE;IACpE,QAAQ,CAAC,OAAO,CAAC,EAAE,MAAM,CAAA;IACzB;;;;;;;;;;;;;;OAcG;IACH,QAAQ,CAAC,QAAQ,CAAC,EAAE,IAAI,CAAA;IACxB;;;;;OAKG;IACH,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAA;CACzB;
|
|
1
|
+
{"version":3,"file":"approvals.d.ts","sourceRoot":"","sources":["../../../src/dsh-adapter/approvals.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAEH,OAAO,EAAE,eAAe,EAAE,MAAM,kBAAkB,CAAA;AAClD,OAAO,EAGL,KAAK,qBAAqB,EAC3B,MAAM,8BAA8B,CAAA;AACrC,OAAO,KAAK,EAAE,eAAe,EAAE,eAAe,EAAE,MAAM,gCAAgC,CAAA;AACtF,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,0BAA0B,CAAA;AAG5D,yDAAyD;AACzD,MAAM,WAAW,gBAAgB;IAC/B,wEAAwE;IACxE,QAAQ,CAAC,GAAG,EAAE,MAAM,CAAA;IACpB,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAA;IACzB,0DAA0D;IAC1D,QAAQ,CAAC,MAAM,CAAC,EAAE,MAAM,CAAA;IACxB,oEAAoE;IACpE,QAAQ,CAAC,OAAO,CAAC,EAAE,MAAM,CAAA;IACzB;;;;;;;;;;;;;;OAcG;IACH,QAAQ,CAAC,QAAQ,CAAC,EAAE,IAAI,CAAA;IACxB;;;;;OAKG;IACH,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAA;CACzB;AA+BD,+DAA+D;AAC/D,wBAAgB,iBAAiB,CAAC,GAAG,EAAE,UAAU,CAAC,OAAO,eAAe,CAAC,CAAC,CAAC,CAAC,EAAE,KAAK,EAAE,aAAa,GAAG,IAAI,CAGxG;AAED,6DAA6D;AAC7D,wBAAgB,gBAAgB,CAAC,GAAG,EAAE,UAAU,CAAC,OAAO,eAAe,CAAC,CAAC,CAAC,CAAC,GAAG,aAAa,GAAG,SAAS,CAGtG;AAsED;;;;;GAKG;AACH,qBAAa,aAAa;IACxB,OAAO,CAAC,QAAQ,CAAC,OAAO,CAAuB;gBAEnC,OAAO,GAAE,qBAA+C;IAGpE,OAAO,CAAC,QAAQ,CAAC,KAAK,CAAwB;IAC9C,OAAO,CAAC,MAAM,CAA6B;IAC3C,OAAO,CAAC,QAAQ,CAAC,SAAS,CAAwB;IAClD,OAAO,CAAC,GAAG,CAAI;IACf;;;OAGG;IACH,OAAO,CAAC,aAAa,CAAgC;IACrD;;;;OAIG;IACH,OAAO,CAAC,uBAAuB,CAAK;IACpC,OAAO,CAAC,YAAY,CAAQ;IAC5B;;;;;;;;;;;;;;;OAeG;IACH,OAAO,CAAC,QAAQ,CAAC,eAAe,CAAoB;IAEpD;;;;OAIG;IACH,SAAS,CAAC,QAAQ,EAAE,MAAM,IAAI,GAAG,MAAM,IAAI;IAO3C;;;;;;OAMG;IACH,WAAW,IAAI,gBAAgB,GAAG,IAAI;IAKtC;;;;OAIG;IACH,eAAe,IAAI,SAAS,MAAM,EAAE;IAYpC;;;;;;OAMG;IACH,kBAAkB,CAChB,OAAO,EAAE,MAAM,GACd,IAAI,CAAC,gBAAgB,EAAE,UAAU,CAAC,GAAG,OAAO,CAAC,IAAI,CAAC,gBAAgB,EAAE,QAAQ,GAAG,SAAS,CAAC,CAAC,GAAG,SAAS;IASzG,OAAO,CAAC,IAAI;IAIZ;iFAC6E;IAC7E,OAAO,CAAC,cAAc;IAStB,gEAAgE;IAChE,OAAO,CAAC,eAAe;IAOvB;;;;;;;;;;;;;;OAcG;IACH,OAAO,CAAC,qBAAqB;IAY7B;;;;;;;;;;;;;;OAcG;IACH,gBAAgB,CAAC,OAAO,EAAE,MAAM,EAAE,KAAK,EAAE,YAAY,GAAG,IAAI;IAc5D;;;;;;;;;;;OAWG;IACH,OAAO,CAAC,gBAAgB;IAUxB;;;;;;;;OAQG;IACH,IAAI,CAAC,GAAG,EAAE,eAAe,GAAG,OAAO,CAAC,eAAe,CAAC;IA2DpD;;;kCAG8B;IAC9B,OAAO,CAAC,SAAS;IAUjB;;;;OAIG;IACH,MAAM,CAAC,OAAO,EAAE,cAAc,GAAG,UAAU,GAAG,IAAI;IAWlD;;;;OAIG;IACH,SAAS,CAAC,OAAO,EAAE,eAAe,GAAG,IAAI;IAazC;;;OAGG;IACH,OAAO,CAAC,YAAY;IAKpB;;;;;;;;;;;;OAYG;IACH,OAAO,CAAC,mBAAmB;CAsB5B"}
|
|
@@ -13,7 +13,20 @@
|
|
|
13
13
|
* `'rejected'` from the panel, `'cancelled'` on abort/teardown; there is
|
|
14
14
|
* no allow-always or feedback channel in the protocol.
|
|
15
15
|
*/
|
|
16
|
+
import { compositionRoot } from './host-access.js';
|
|
17
|
+
import { assertCapabilityShadowPolicy, defaultAdapterRuntime, } from '../adapter/kernel/runtime.js';
|
|
16
18
|
import { snapshotLiveSessionEvents } from './compat/liveSession.js';
|
|
19
|
+
const approvalStores = new WeakMap();
|
|
20
|
+
/** Host-only registration used by the TUI plugin bootstrap. */
|
|
21
|
+
export function bindApprovalStore(ctx, store) {
|
|
22
|
+
const root = compositionRoot(ctx);
|
|
23
|
+
approvalStores.set(root, store);
|
|
24
|
+
}
|
|
25
|
+
/** Host-only lookup used by the presentation Port bridge. */
|
|
26
|
+
export function getApprovalStore(ctx) {
|
|
27
|
+
const root = compositionRoot(ctx);
|
|
28
|
+
return approvalStores.get(root);
|
|
29
|
+
}
|
|
17
30
|
const COMMAND_CLIP = 500;
|
|
18
31
|
/**
|
|
19
32
|
* Recover the gated command from the session log: the approval request
|
|
@@ -96,6 +109,10 @@ function consumedKey(agentId, callId) {
|
|
|
96
109
|
* {@link ApprovalStore.decide}.
|
|
97
110
|
*/
|
|
98
111
|
export class ApprovalStore {
|
|
112
|
+
runtime;
|
|
113
|
+
constructor(runtime = defaultAdapterRuntime()) {
|
|
114
|
+
this.runtime = runtime;
|
|
115
|
+
}
|
|
99
116
|
queue = [];
|
|
100
117
|
active;
|
|
101
118
|
listeners = new Set();
|
|
@@ -247,9 +264,10 @@ export class ApprovalStore {
|
|
|
247
264
|
* different session than the active ask's. The notification the SDK
|
|
248
265
|
* fires arrives after the event is already in the live session log, so the
|
|
249
266
|
* recheck sees the settled result.
|
|
267
|
+
* @param agentId - The emitting session's id (DSH shares agent/session identity).
|
|
250
268
|
* @param event - The appended session event.
|
|
251
269
|
*/
|
|
252
|
-
noteSessionEvent(event) {
|
|
270
|
+
noteSessionEvent(agentId, event) {
|
|
253
271
|
if (event.type !== 'tool/result')
|
|
254
272
|
return;
|
|
255
273
|
// Hygiene for {@link consumedCallIds}: once the paired result landed,
|
|
@@ -257,13 +275,9 @@ export class ApprovalStore {
|
|
|
257
275
|
// entry can go.
|
|
258
276
|
const resultCallId = event.data.message?.source?.callId;
|
|
259
277
|
if (resultCallId !== undefined) {
|
|
260
|
-
//
|
|
261
|
-
//
|
|
262
|
-
|
|
263
|
-
for (const entry of this.consumedCallIds) {
|
|
264
|
-
if (entry.endsWith(suffix))
|
|
265
|
-
this.consumedCallIds.delete(entry);
|
|
266
|
-
}
|
|
278
|
+
// Low-entropy callIds repeat across agents. A different session's
|
|
279
|
+
// result must not reopen this agent's park-after-decide replay window.
|
|
280
|
+
this.consumedCallIds.delete(consumedKey(agentId, resultCallId));
|
|
267
281
|
}
|
|
268
282
|
this.refreshActiveExternal();
|
|
269
283
|
}
|
|
@@ -282,8 +296,10 @@ export class ApprovalStore {
|
|
|
282
296
|
isCallIdInFlight(req) {
|
|
283
297
|
if (req.callId === undefined)
|
|
284
298
|
return false;
|
|
299
|
+
const agentKey = String(req.agent.id);
|
|
285
300
|
const key = String(req.callId);
|
|
286
|
-
const occupies = (pending) =>
|
|
301
|
+
const occupies = (pending) => String(pending.request.agent.id) === agentKey
|
|
302
|
+
&& pending.request.callId !== undefined && String(pending.request.callId) === key;
|
|
287
303
|
return (this.active !== undefined && occupies(this.active)) || this.queue.some(occupies);
|
|
288
304
|
}
|
|
289
305
|
/**
|
|
@@ -296,6 +312,7 @@ export class ApprovalStore {
|
|
|
296
312
|
* when the ask is withdrawn or the plugin tears down.
|
|
297
313
|
*/
|
|
298
314
|
park(req) {
|
|
315
|
+
assertCapabilityShadowPolicy('host.presentation.approve', this.runtime.mode, this.runtime.slices);
|
|
299
316
|
return new Promise(resolve => {
|
|
300
317
|
const command = commandOf(req);
|
|
301
318
|
// Source badge: park() is reached through the approval/request
|
|
@@ -309,7 +326,7 @@ export class ApprovalStore {
|
|
|
309
326
|
// clean on its own — see markCallIdAmbiguous), so the panel can warn.
|
|
310
327
|
const duplicate = this.isCallIdInFlight(req);
|
|
311
328
|
if (duplicate)
|
|
312
|
-
this.markCallIdAmbiguous(req.callId);
|
|
329
|
+
this.markCallIdAmbiguous(req.agent.id, req.callId);
|
|
313
330
|
const external = !isLiveToolApproval(req) || duplicate
|
|
314
331
|
|| (req.callId !== undefined && this.consumedCallIds.has(consumedKey(req.agent.id, req.callId)));
|
|
315
332
|
const pending = {
|
|
@@ -421,11 +438,14 @@ export class ApprovalStore {
|
|
|
421
438
|
* monotonic and never erased. Deliberately badges instead of cancelling:
|
|
422
439
|
* cancelling both would hand the attacker a force-cancel primitive
|
|
423
440
|
* against genuine approvals.
|
|
441
|
+
* @param agentId - The agent domain owning the duplicated call id.
|
|
424
442
|
* @param callId - The duplicated call id (non-undefined by construction).
|
|
425
443
|
*/
|
|
426
|
-
markCallIdAmbiguous(callId) {
|
|
444
|
+
markCallIdAmbiguous(agentId, callId) {
|
|
445
|
+
const agentKey = String(agentId);
|
|
427
446
|
const key = String(callId);
|
|
428
|
-
const same = (pending) =>
|
|
447
|
+
const same = (pending) => String(pending.request.agent.id) === agentKey
|
|
448
|
+
&& pending.request.callId !== undefined && String(pending.request.callId) === key;
|
|
429
449
|
let flipped = false;
|
|
430
450
|
if (this.active !== undefined && same(this.active) && this.active.snapshot.external !== true) {
|
|
431
451
|
this.active.snapshot.external = true;
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import type { ChannelState } from './types.js';
|
|
2
|
+
/**
|
|
3
|
+
* The Channel installs its effectful command delegates atomically after every
|
|
4
|
+
* specialist has been constructed. Construction-time callers fail closed
|
|
5
|
+
* rather than receiving a plausible no-op while the Channel is incomplete.
|
|
6
|
+
*/
|
|
7
|
+
export type ChannelActionDelegates = Pick<ChannelState, 'commandCompletions' | 'loadOlder' | 'rewindTo' | 'rewindToNode' | 'forkSession' | 'resumeTo' | 'newSession' | 'listWorkspaces' | 'resolveWorkspace' | 'switchWorkspace' | 'renameWorkspace' | 'workspaceCommands' | 'runWorkspaceCommand' | 'switchModel' | 'listEfforts' | 'setEffort' | 'setDefaultEffort' | 'cycleMode' | 'runPermissionPreset' | 'clear' | 'setActivityFrames' | 'listPresets' | 'switchPreset' | 'listModels' | 'listProviders' | 'invalidateModelCompletion' | 'listSkills' | 'describeCredential' | 'balanceInfo' | 'sideQuestion' | 'listFileCandidates' | 'listFiles' | 'listSessions' | 'previewSession' | 'bindApprovalStore' | 'agentViewRows' | 'subscribeAgentView' | 'dispatchBackgroundAgent' | 'stopBackgroundAgent' | 'attachToAgent' | 'peekAgentSession' | 'replyToAgent' | 'backgroundCurrent' | 'setResumeTarget' | 'renameSession' | 'setSessionColor' | 'recapRecent' | 'deleteSession' | 'renameSessionTo' | 'compact' | 'runExternalCommand' | 'runExternalCommandOutcome' | 'pushLocal' | 'mcpStatus' | 'exportSession' | 'initWorkspace' | 'doctorInfo' | 'pluginsInfo' | 'listSubagents'> & {
|
|
8
|
+
runLocalCommand(command: string, includeInContext: boolean): Promise<void>;
|
|
9
|
+
};
|
|
10
|
+
type ChannelActionMethodName = Exclude<keyof ChannelActionDelegates, 'runLocalCommand'>;
|
|
11
|
+
export type ChannelActionMethods = Pick<ChannelState, ChannelActionMethodName>;
|
|
12
|
+
/** The ChannelState-facing half of the readiness cell is deliberately pure:
|
|
13
|
+
* one typed forwarding method per public action, with no service access. */
|
|
14
|
+
export declare function createChannelActionMethods(getReadyActions: () => ChannelActionDelegates): ChannelActionMethods;
|
|
15
|
+
export declare function createChannelActionReadiness(): {
|
|
16
|
+
install(next: ChannelActionDelegates): void;
|
|
17
|
+
getReadyActions(): ChannelActionDelegates;
|
|
18
|
+
};
|
|
19
|
+
export {};
|
|
20
|
+
//# sourceMappingURL=action-readiness.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"action-readiness.d.ts","sourceRoot":"","sources":["../../../../src/dsh-adapter/channel/action-readiness.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,YAAY,CAAA;AAE9C;;;;GAIG;AACH,MAAM,MAAM,sBAAsB,GAAG,IAAI,CAAC,YAAY,EAClD,oBAAoB,GACpB,WAAW,GACX,UAAU,GACV,cAAc,GACd,aAAa,GACb,UAAU,GACV,YAAY,GACZ,gBAAgB,GAChB,kBAAkB,GAClB,iBAAiB,GACjB,iBAAiB,GACjB,mBAAmB,GACnB,qBAAqB,GACrB,aAAa,GACb,aAAa,GACb,WAAW,GACX,kBAAkB,GAClB,WAAW,GACX,qBAAqB,GACrB,OAAO,GACP,mBAAmB,GACnB,aAAa,GACb,cAAc,GACd,YAAY,GACZ,eAAe,GACf,2BAA2B,GAC3B,YAAY,GACZ,oBAAoB,GACpB,aAAa,GACb,cAAc,GACd,oBAAoB,GACpB,WAAW,GACX,cAAc,GACd,gBAAgB,GAChB,mBAAmB,GACnB,eAAe,GACf,oBAAoB,GACpB,yBAAyB,GACzB,qBAAqB,GACrB,eAAe,GACf,kBAAkB,GAClB,cAAc,GACd,mBAAmB,GACnB,iBAAiB,GACjB,eAAe,GACf,iBAAiB,GACjB,aAAa,GACb,eAAe,GACf,iBAAiB,GACjB,SAAS,GACT,oBAAoB,GACpB,2BAA2B,GAC3B,WAAW,GACX,WAAW,GACX,eAAe,GACf,eAAe,GACf,YAAY,GACZ,aAAa,GACb,eAAe,CAClB,GAAG;IACF,eAAe,CAAC,OAAO,EAAE,MAAM,EAAE,gBAAgB,EAAE,OAAO,GAAG,OAAO,CAAC,IAAI,CAAC,CAAA;CAC3E,CAAA;AAED,KAAK,uBAAuB,GAAG,OAAO,CAAC,MAAM,sBAAsB,EAAE,iBAAiB,CAAC,CAAA;AACvF,MAAM,MAAM,oBAAoB,GAAG,IAAI,CAAC,YAAY,EAAE,uBAAuB,CAAC,CAAA;AAE9E;4EAC4E;AAC5E,wBAAgB,0BAA0B,CACxC,eAAe,EAAE,MAAM,sBAAsB,GAC5C,oBAAoB,CAiEtB;AAED,wBAAgB,4BAA4B;kBAG1B,sBAAsB,GAAG,IAAI;uBAIxB,sBAAsB;EAK5C"}
|
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
/** The ChannelState-facing half of the readiness cell is deliberately pure:
|
|
2
|
+
* one typed forwarding method per public action, with no service access. */
|
|
3
|
+
export function createChannelActionMethods(getReadyActions) {
|
|
4
|
+
return {
|
|
5
|
+
commandCompletions: input => getReadyActions().commandCompletions(input),
|
|
6
|
+
loadOlder: () => getReadyActions().loadOlder(),
|
|
7
|
+
rewindTo: (row, mode = null) => getReadyActions().rewindTo(row, mode),
|
|
8
|
+
rewindToNode: (sessionId, seq, mode = 'rewind') => getReadyActions().rewindToNode(sessionId, seq, mode),
|
|
9
|
+
forkSession: () => getReadyActions().forkSession(),
|
|
10
|
+
resumeTo: sessionId => getReadyActions().resumeTo(sessionId),
|
|
11
|
+
newSession: () => getReadyActions().newSession(),
|
|
12
|
+
listWorkspaces: () => getReadyActions().listWorkspaces(),
|
|
13
|
+
resolveWorkspace: uri => getReadyActions().resolveWorkspace(uri),
|
|
14
|
+
// Preserve ChannelUi's promise rejection contract after release: a caller
|
|
15
|
+
// which already received this async method must observe a rejected promise,
|
|
16
|
+
// not a synchronous throw from the readiness guard.
|
|
17
|
+
async switchWorkspace(target) { return getReadyActions().switchWorkspace(target); },
|
|
18
|
+
renameWorkspace: title => getReadyActions().renameWorkspace(title),
|
|
19
|
+
workspaceCommands: () => getReadyActions().workspaceCommands(),
|
|
20
|
+
runWorkspaceCommand: (name, input) => getReadyActions().runWorkspaceCommand(name, input),
|
|
21
|
+
switchModel: (provider, model) => getReadyActions().switchModel(provider, model),
|
|
22
|
+
listEfforts: () => getReadyActions().listEfforts(),
|
|
23
|
+
setEffort: id => getReadyActions().setEffort(id),
|
|
24
|
+
setDefaultEffort: id => getReadyActions().setDefaultEffort(id),
|
|
25
|
+
cycleMode: () => getReadyActions().cycleMode(),
|
|
26
|
+
runPermissionPreset: name => getReadyActions().runPermissionPreset(name),
|
|
27
|
+
clear: () => getReadyActions().clear(),
|
|
28
|
+
setActivityFrames: name => getReadyActions().setActivityFrames(name),
|
|
29
|
+
listPresets: () => getReadyActions().listPresets(),
|
|
30
|
+
switchPreset: presetId => getReadyActions().switchPreset(presetId),
|
|
31
|
+
listModels: () => getReadyActions().listModels(),
|
|
32
|
+
listProviders: () => getReadyActions().listProviders(),
|
|
33
|
+
invalidateModelCompletion: () => getReadyActions().invalidateModelCompletion(),
|
|
34
|
+
listSkills: () => getReadyActions().listSkills(),
|
|
35
|
+
describeCredential: ref => getReadyActions().describeCredential(ref),
|
|
36
|
+
balanceInfo: () => getReadyActions().balanceInfo(),
|
|
37
|
+
sideQuestion: (question, options) => getReadyActions().sideQuestion(question, options),
|
|
38
|
+
listFileCandidates: (query, options) => getReadyActions().listFileCandidates(query, options),
|
|
39
|
+
listFiles: () => getReadyActions().listFiles(),
|
|
40
|
+
listSessions: () => getReadyActions().listSessions(),
|
|
41
|
+
previewSession: sessionId => getReadyActions().previewSession(sessionId),
|
|
42
|
+
bindApprovalStore: store => getReadyActions().bindApprovalStore(store),
|
|
43
|
+
agentViewRows: () => getReadyActions().agentViewRows(),
|
|
44
|
+
subscribeAgentView: listener => getReadyActions().subscribeAgentView(listener),
|
|
45
|
+
dispatchBackgroundAgent: prompt => getReadyActions().dispatchBackgroundAgent(prompt),
|
|
46
|
+
stopBackgroundAgent: sessionId => getReadyActions().stopBackgroundAgent(sessionId),
|
|
47
|
+
attachToAgent: sessionId => getReadyActions().attachToAgent(sessionId),
|
|
48
|
+
peekAgentSession: sessionId => getReadyActions().peekAgentSession(sessionId),
|
|
49
|
+
replyToAgent: (sessionId, text) => getReadyActions().replyToAgent(sessionId, text),
|
|
50
|
+
backgroundCurrent: () => getReadyActions().backgroundCurrent(),
|
|
51
|
+
setResumeTarget: sessionId => getReadyActions().setResumeTarget(sessionId),
|
|
52
|
+
renameSession: title => getReadyActions().renameSession(title),
|
|
53
|
+
setSessionColor: color => getReadyActions().setSessionColor(color),
|
|
54
|
+
recapRecent: options => getReadyActions().recapRecent(options),
|
|
55
|
+
deleteSession: sessionId => getReadyActions().deleteSession(sessionId),
|
|
56
|
+
renameSessionTo: (sessionId, title) => getReadyActions().renameSessionTo(sessionId, title),
|
|
57
|
+
compact: () => getReadyActions().compact(),
|
|
58
|
+
runExternalCommand: (name, rawInput) => getReadyActions().runExternalCommand(name, rawInput),
|
|
59
|
+
runExternalCommandOutcome: (name, rawInput, images) => getReadyActions().runExternalCommandOutcome(name, rawInput, images),
|
|
60
|
+
pushLocal: (title, lines) => getReadyActions().pushLocal(title, lines),
|
|
61
|
+
mcpStatus: () => getReadyActions().mcpStatus(),
|
|
62
|
+
exportSession: () => getReadyActions().exportSession(),
|
|
63
|
+
initWorkspace: () => getReadyActions().initWorkspace(),
|
|
64
|
+
doctorInfo: () => getReadyActions().doctorInfo(),
|
|
65
|
+
pluginsInfo: args => getReadyActions().pluginsInfo(args),
|
|
66
|
+
listSubagents: () => getReadyActions().listSubagents(),
|
|
67
|
+
};
|
|
68
|
+
}
|
|
69
|
+
export function createChannelActionReadiness() {
|
|
70
|
+
let delegates;
|
|
71
|
+
return {
|
|
72
|
+
install(next) {
|
|
73
|
+
if (delegates !== undefined)
|
|
74
|
+
throw new Error('dsh-tui: Channel actions are already installed');
|
|
75
|
+
delegates = Object.freeze(next);
|
|
76
|
+
},
|
|
77
|
+
getReadyActions() {
|
|
78
|
+
if (delegates === undefined)
|
|
79
|
+
throw new Error('dsh-tui: Channel actions are not installed');
|
|
80
|
+
return delegates;
|
|
81
|
+
},
|
|
82
|
+
};
|
|
83
|
+
}
|