@jingyi0605/codingns4dsh 0.2.1-beta.3 → 0.2.1-beta.5
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.en.md +30 -6
- package/README.md +121 -10
- package/THIRD_PARTY_NOTICES +141 -0
- package/assets/assistant-basics/female-v1.png +0 -0
- package/assets/assistant-basics/male-v1.png +0 -0
- package/assets/desktop-assistant/20261008-WebView2/345/210/206/345/217/221/350/257/264/346/230/216.md +14 -0
- package/assets/desktop-assistant/webview2/LICENSE.txt +27 -0
- package/assets/desktop-assistant/webview2/Microsoft.Web.WebView2.Core.dll +0 -0
- package/assets/desktop-assistant/webview2/Microsoft.Web.WebView2.Wpf.dll +0 -0
- package/assets/desktop-assistant/webview2/NOTICE.txt +85 -0
- package/assets/desktop-assistant/webview2/arm64/WebView2Loader.dll +0 -0
- package/assets/desktop-assistant/webview2/x64/WebView2Loader.dll +0 -0
- package/assets/desktop-assistant/webview2/x86/WebView2Loader.dll +0 -0
- package/assets/moss/LICENSE +201 -0
- package/assets/moss/ort_cpu_runtime.py +839 -0
- package/assets/moss/worker.py +278 -0
- package/assets/voice/bilingual-zh-en-bpe.vocab +500 -0
- package/avatar-packages/catalog.json +259 -0
- package/avatar-packages/manifests/bubu-codebrew-bear.avatar.json +13 -0
- package/avatar-packages/manifests/ds-whale-live2d.avatar.json +27 -0
- package/avatar-packages/manifests/ds-whale-sprite.avatar.json +13 -0
- package/avatar-packages/manifests/live2d-haru.avatar.json +13 -0
- package/avatar-packages/manifests/live2d-hiyori.avatar.json +13 -0
- package/avatar-packages/manifests/live2d-mao.avatar.json +13 -0
- package/avatar-packages/manifests/live2d-mark.avatar.json +13 -0
- package/avatar-packages/manifests/live2d-rice.avatar.json +13 -0
- package/avatar-packages/manifests/live2d-wanko.avatar.json +13 -0
- package/avatar-packages/manifests/nastya.avatar.json +13 -0
- package/avatar-packages/manifests/scout-corgi.avatar.json +13 -0
- package/avatar-packages/manifests/xiaoman.avatar.json +13 -0
- package/data/build/dist/client/account-bar.d.ts +1 -1
- package/data/build/dist/client/account-bar.d.ts.map +1 -1
- package/data/build/dist/client/account-bar.js +22 -14
- package/data/build/dist/client/account-bar.js.map +1 -1
- package/data/build/dist/client/adapter-catalog-watch.d.ts +8 -0
- package/data/build/dist/client/adapter-catalog-watch.d.ts.map +1 -0
- package/data/build/dist/client/adapter-catalog-watch.js +79 -0
- package/data/build/dist/client/adapter-catalog-watch.js.map +1 -0
- package/data/build/dist/client/assistant-settings-styles.d.ts +7 -0
- package/data/build/dist/client/assistant-settings-styles.d.ts.map +1 -0
- package/data/build/dist/client/assistant-settings-styles.js +6 -0
- package/data/build/dist/client/assistant-settings-styles.js.map +1 -0
- package/data/build/dist/client/avatar/builtin.d.ts +5 -0
- package/data/build/dist/client/avatar/builtin.d.ts.map +1 -0
- package/data/build/dist/client/avatar/builtin.js +9 -0
- package/data/build/dist/client/avatar/builtin.js.map +1 -0
- package/data/build/dist/client/avatar/cache-status.d.ts +4 -0
- package/data/build/dist/client/avatar/cache-status.d.ts.map +1 -0
- package/data/build/dist/client/avatar/cache-status.js +40 -0
- package/data/build/dist/client/avatar/cache-status.js.map +1 -0
- package/data/build/dist/client/avatar/catalog-panel.d.ts +49 -0
- package/data/build/dist/client/avatar/catalog-panel.d.ts.map +1 -0
- package/data/build/dist/client/avatar/catalog-panel.js +245 -0
- package/data/build/dist/client/avatar/catalog-panel.js.map +1 -0
- package/data/build/dist/client/avatar/catalog-picker.d.ts +38 -0
- package/data/build/dist/client/avatar/catalog-picker.d.ts.map +1 -0
- package/data/build/dist/client/avatar/catalog-picker.js +65 -0
- package/data/build/dist/client/avatar/catalog-picker.js.map +1 -0
- package/data/build/dist/client/avatar/desktop-bridge.d.ts +21 -0
- package/data/build/dist/client/avatar/desktop-bridge.d.ts.map +1 -0
- package/data/build/dist/client/avatar/desktop-bridge.js +109 -0
- package/data/build/dist/client/avatar/desktop-bridge.js.map +1 -0
- package/data/build/dist/client/avatar/desktop-entry.d.ts +2 -0
- package/data/build/dist/client/avatar/desktop-entry.d.ts.map +1 -0
- package/data/build/dist/client/avatar/desktop-entry.js +34 -0
- package/data/build/dist/client/avatar/desktop-entry.js.map +1 -0
- package/data/build/dist/client/avatar/desktop-view.d.ts +23 -0
- package/data/build/dist/client/avatar/desktop-view.d.ts.map +1 -0
- package/data/build/dist/client/avatar/desktop-view.js +72 -0
- package/data/build/dist/client/avatar/desktop-view.js.map +1 -0
- package/data/build/dist/client/avatar/engine.d.ts +45 -0
- package/data/build/dist/client/avatar/engine.d.ts.map +1 -0
- package/data/build/dist/client/avatar/engine.js +165 -0
- package/data/build/dist/client/avatar/engine.js.map +1 -0
- package/data/build/dist/client/avatar/floating.d.ts +20 -0
- package/data/build/dist/client/avatar/floating.d.ts.map +1 -0
- package/data/build/dist/client/avatar/floating.js +99 -0
- package/data/build/dist/client/avatar/floating.js.map +1 -0
- package/data/build/dist/client/avatar/image.d.ts +5 -0
- package/data/build/dist/client/avatar/image.d.ts.map +1 -0
- package/data/build/dist/client/avatar/image.js +22 -0
- package/data/build/dist/client/avatar/image.js.map +1 -0
- package/data/build/dist/client/avatar/live2d.d.ts +67 -0
- package/data/build/dist/client/avatar/live2d.d.ts.map +1 -0
- package/data/build/dist/client/avatar/live2d.js +288 -0
- package/data/build/dist/client/avatar/live2d.js.map +1 -0
- package/data/build/dist/client/avatar/loading.d.ts +27 -0
- package/data/build/dist/client/avatar/loading.d.ts.map +1 -0
- package/data/build/dist/client/avatar/loading.js +74 -0
- package/data/build/dist/client/avatar/loading.js.map +1 -0
- package/data/build/dist/client/avatar/manager.d.ts +71 -0
- package/data/build/dist/client/avatar/manager.d.ts.map +1 -0
- package/data/build/dist/client/avatar/manager.js +323 -0
- package/data/build/dist/client/avatar/manager.js.map +1 -0
- package/data/build/dist/client/avatar/portrait-capture.d.ts +30 -0
- package/data/build/dist/client/avatar/portrait-capture.d.ts.map +1 -0
- package/data/build/dist/client/avatar/portrait-capture.js +233 -0
- package/data/build/dist/client/avatar/portrait-capture.js.map +1 -0
- package/data/build/dist/client/avatar/portrait-editor.d.ts +14 -0
- package/data/build/dist/client/avatar/portrait-editor.d.ts.map +1 -0
- package/data/build/dist/client/avatar/portrait-editor.js +105 -0
- package/data/build/dist/client/avatar/portrait-editor.js.map +1 -0
- package/data/build/dist/client/avatar/portrait-service.d.ts +51 -0
- package/data/build/dist/client/avatar/portrait-service.d.ts.map +1 -0
- package/data/build/dist/client/avatar/portrait-service.js +244 -0
- package/data/build/dist/client/avatar/portrait-service.js.map +1 -0
- package/data/build/dist/client/avatar/portrait.d.ts +28 -0
- package/data/build/dist/client/avatar/portrait.d.ts.map +1 -0
- package/data/build/dist/client/avatar/portrait.js +56 -0
- package/data/build/dist/client/avatar/portrait.js.map +1 -0
- package/data/build/dist/client/avatar/preview-capture.d.ts +4 -0
- package/data/build/dist/client/avatar/preview-capture.d.ts.map +1 -0
- package/data/build/dist/client/avatar/preview-capture.js +100 -0
- package/data/build/dist/client/avatar/preview-capture.js.map +1 -0
- package/data/build/dist/client/avatar/preview-store.d.ts +41 -0
- package/data/build/dist/client/avatar/preview-store.d.ts.map +1 -0
- package/data/build/dist/client/avatar/preview-store.js +171 -0
- package/data/build/dist/client/avatar/preview-store.js.map +1 -0
- package/data/build/dist/client/avatar/preview.d.ts +14 -0
- package/data/build/dist/client/avatar/preview.d.ts.map +1 -0
- package/data/build/dist/client/avatar/preview.js +56 -0
- package/data/build/dist/client/avatar/preview.js.map +1 -0
- package/data/build/dist/client/avatar/registration.d.ts +2 -0
- package/data/build/dist/client/avatar/registration.d.ts.map +1 -0
- package/data/build/dist/client/avatar/registration.js +2 -0
- package/data/build/dist/client/avatar/registration.js.map +1 -0
- package/data/build/dist/client/avatar/registry.d.ts +45 -0
- package/data/build/dist/client/avatar/registry.d.ts.map +1 -0
- package/data/build/dist/client/avatar/registry.js +34 -0
- package/data/build/dist/client/avatar/registry.js.map +1 -0
- package/data/build/dist/client/avatar/settings-panel.d.ts +21 -0
- package/data/build/dist/client/avatar/settings-panel.d.ts.map +1 -0
- package/data/build/dist/client/avatar/settings-panel.js +169 -0
- package/data/build/dist/client/avatar/settings-panel.js.map +1 -0
- package/data/build/dist/client/avatar/slot.d.ts +17 -0
- package/data/build/dist/client/avatar/slot.d.ts.map +1 -0
- package/data/build/dist/client/avatar/slot.js +70 -0
- package/data/build/dist/client/avatar/slot.js.map +1 -0
- package/data/build/dist/client/avatar/spritesheet.d.ts +19 -0
- package/data/build/dist/client/avatar/spritesheet.d.ts.map +1 -0
- package/data/build/dist/client/avatar/spritesheet.js +91 -0
- package/data/build/dist/client/avatar/spritesheet.js.map +1 -0
- package/data/build/dist/client/avatar/temporary-preview.d.ts +25 -0
- package/data/build/dist/client/avatar/temporary-preview.d.ts.map +1 -0
- package/data/build/dist/client/avatar/temporary-preview.js +61 -0
- package/data/build/dist/client/avatar/temporary-preview.js.map +1 -0
- package/data/build/dist/client/bundle.js +25603 -3080
- package/data/build/dist/client/bundle.js.map +1 -1
- package/data/build/dist/client/cli-catalog.d.ts +3 -0
- package/data/build/dist/client/cli-catalog.d.ts.map +1 -1
- package/data/build/dist/client/cli-catalog.js +7 -0
- package/data/build/dist/client/cli-catalog.js.map +1 -1
- package/data/build/dist/client/cli-slots.d.ts.map +1 -1
- package/data/build/dist/client/cli-slots.js +14 -52
- package/data/build/dist/client/cli-slots.js.map +1 -1
- package/data/build/dist/client/debug/ui.d.ts.map +1 -1
- package/data/build/dist/client/debug/ui.js +14 -5
- package/data/build/dist/client/debug/ui.js.map +1 -1
- package/data/build/dist/client/desktop-assistant.js +8599 -0
- package/data/build/dist/client/features/assistant-composer-input.d.ts +10 -0
- package/data/build/dist/client/features/assistant-composer-input.d.ts.map +1 -0
- package/data/build/dist/client/features/assistant-composer-input.js +40 -0
- package/data/build/dist/client/features/assistant-composer-input.js.map +1 -0
- package/data/build/dist/client/features/assistant-configuration-session.d.ts +45 -0
- package/data/build/dist/client/features/assistant-configuration-session.d.ts.map +1 -0
- package/data/build/dist/client/features/assistant-configuration-session.js +252 -0
- package/data/build/dist/client/features/assistant-configuration-session.js.map +1 -0
- package/data/build/dist/client/features/assistant-configuration-tabs.d.ts +34 -0
- package/data/build/dist/client/features/assistant-configuration-tabs.d.ts.map +1 -0
- package/data/build/dist/client/features/assistant-configuration-tabs.js +48 -0
- package/data/build/dist/client/features/assistant-configuration-tabs.js.map +1 -0
- package/data/build/dist/client/features/assistant-conversation-message.d.ts +27 -0
- package/data/build/dist/client/features/assistant-conversation-message.d.ts.map +1 -0
- package/data/build/dist/client/features/assistant-conversation-message.js +55 -0
- package/data/build/dist/client/features/assistant-conversation-message.js.map +1 -0
- package/data/build/dist/client/features/assistant-debug-dialog.d.ts +3 -0
- package/data/build/dist/client/features/assistant-debug-dialog.d.ts.map +1 -0
- package/data/build/dist/client/features/assistant-debug-dialog.js +3 -0
- package/data/build/dist/client/features/assistant-debug-dialog.js.map +1 -0
- package/data/build/dist/client/features/assistant-debug-workbench.d.ts +48 -0
- package/data/build/dist/client/features/assistant-debug-workbench.d.ts.map +1 -0
- package/data/build/dist/client/features/assistant-debug-workbench.js +376 -0
- package/data/build/dist/client/features/assistant-debug-workbench.js.map +1 -0
- package/data/build/dist/client/features/assistant-floating-call.d.ts +33 -0
- package/data/build/dist/client/features/assistant-floating-call.d.ts.map +1 -0
- package/data/build/dist/client/features/assistant-floating-call.js +67 -0
- package/data/build/dist/client/features/assistant-floating-call.js.map +1 -0
- package/data/build/dist/client/features/assistant-panel.d.ts +2 -2
- package/data/build/dist/client/features/assistant-panel.d.ts.map +1 -1
- package/data/build/dist/client/features/assistant-panel.js +10 -123
- package/data/build/dist/client/features/assistant-panel.js.map +1 -1
- package/data/build/dist/client/features/assistant-realtime-call.d.ts +57 -0
- package/data/build/dist/client/features/assistant-realtime-call.d.ts.map +1 -0
- package/data/build/dist/client/features/assistant-realtime-call.js +131 -0
- package/data/build/dist/client/features/assistant-realtime-call.js.map +1 -0
- package/data/build/dist/client/features/assistant-record-style.d.ts +5 -0
- package/data/build/dist/client/features/assistant-record-style.d.ts.map +1 -0
- package/data/build/dist/client/features/assistant-record-style.js +25 -0
- package/data/build/dist/client/features/assistant-record-style.js.map +1 -0
- package/data/build/dist/client/features/assistant-voice-initialization.d.ts +26 -0
- package/data/build/dist/client/features/assistant-voice-initialization.d.ts.map +1 -0
- package/data/build/dist/client/features/assistant-voice-initialization.js +138 -0
- package/data/build/dist/client/features/assistant-voice-initialization.js.map +1 -0
- package/data/build/dist/client/features/assistant-voice-settings-group.d.ts +19 -0
- package/data/build/dist/client/features/assistant-voice-settings-group.d.ts.map +1 -0
- package/data/build/dist/client/features/assistant-voice-settings-group.js +34 -0
- package/data/build/dist/client/features/assistant-voice-settings-group.js.map +1 -0
- package/data/build/dist/client/features/assistant-voice-settings.d.ts +13 -0
- package/data/build/dist/client/features/assistant-voice-settings.d.ts.map +1 -0
- package/data/build/dist/client/features/assistant-voice-settings.js +184 -0
- package/data/build/dist/client/features/assistant-voice-settings.js.map +1 -0
- package/data/build/dist/client/features/assistant-workbench-controls.d.ts +72 -0
- package/data/build/dist/client/features/assistant-workbench-controls.d.ts.map +1 -0
- package/data/build/dist/client/features/assistant-workbench-controls.js +145 -0
- package/data/build/dist/client/features/assistant-workbench-controls.js.map +1 -0
- package/data/build/dist/client/features/assistant-workbench-entry.d.ts +4 -0
- package/data/build/dist/client/features/assistant-workbench-entry.d.ts.map +1 -0
- package/data/build/dist/client/features/assistant-workbench-entry.js +7 -0
- package/data/build/dist/client/features/assistant-workbench-entry.js.map +1 -0
- package/data/build/dist/client/features/assistant-workbench.d.ts +109 -0
- package/data/build/dist/client/features/assistant-workbench.d.ts.map +1 -0
- package/data/build/dist/client/features/assistant-workbench.js +568 -0
- package/data/build/dist/client/features/assistant-workbench.js.map +1 -0
- package/data/build/dist/client/features/cli-adapters.d.ts.map +1 -1
- package/data/build/dist/client/features/cli-adapters.js +48 -13
- package/data/build/dist/client/features/cli-adapters.js.map +1 -1
- package/data/build/dist/client/features/global-voice-assistant.d.ts.map +1 -1
- package/data/build/dist/client/features/global-voice-assistant.js +100 -39
- package/data/build/dist/client/features/global-voice-assistant.js.map +1 -1
- package/data/build/dist/client/features/lan-access.js +2 -2
- package/data/build/dist/client/features/lan-access.js.map +1 -1
- package/data/build/dist/client/features/mobile-access.d.ts.map +1 -1
- package/data/build/dist/client/features/mobile-access.js +9 -0
- package/data/build/dist/client/features/mobile-access.js.map +1 -1
- package/data/build/dist/client/features/peer-host.d.ts +4 -1
- package/data/build/dist/client/features/peer-host.d.ts.map +1 -1
- package/data/build/dist/client/features/peer-host.js +176 -106
- package/data/build/dist/client/features/peer-host.js.map +1 -1
- package/data/build/dist/client/features/types.d.ts +4 -0
- package/data/build/dist/client/features/types.d.ts.map +1 -1
- package/data/build/dist/client/features/voice-conversation-dialog.d.ts +9 -2
- package/data/build/dist/client/features/voice-conversation-dialog.d.ts.map +1 -1
- package/data/build/dist/client/features/voice-conversation-dialog.js +29 -7
- package/data/build/dist/client/features/voice-conversation-dialog.js.map +1 -1
- package/data/build/dist/client/features/voice-initialization-dialog.d.ts +42 -2
- package/data/build/dist/client/features/voice-initialization-dialog.d.ts.map +1 -1
- package/data/build/dist/client/features/voice-initialization-dialog.js +181 -67
- package/data/build/dist/client/features/voice-initialization-dialog.js.map +1 -1
- package/data/build/dist/client/features/workspace-session-enhancement.d.ts.map +1 -1
- package/data/build/dist/client/features/workspace-session-enhancement.js +37 -10
- package/data/build/dist/client/features/workspace-session-enhancement.js.map +1 -1
- package/data/build/dist/client/git-management.d.ts +1 -1
- package/data/build/dist/client/git-management.d.ts.map +1 -1
- package/data/build/dist/client/git-management.js +46 -27
- package/data/build/dist/client/git-management.js.map +1 -1
- package/data/build/dist/client/global-voice-runtime-registry.d.ts +4 -0
- package/data/build/dist/client/global-voice-runtime-registry.d.ts.map +1 -1
- package/data/build/dist/client/global-voice-runtime-registry.js.map +1 -1
- package/data/build/dist/client/index.d.ts +11 -0
- package/data/build/dist/client/index.d.ts.map +1 -1
- package/data/build/dist/client/index.js +10 -0
- package/data/build/dist/client/index.js.map +1 -1
- package/data/build/dist/client/locale.d.ts.map +1 -1
- package/data/build/dist/client/locale.js +61 -14
- package/data/build/dist/client/locale.js.map +1 -1
- package/data/build/dist/client/locales/assistantAvatar.d.ts +138 -0
- package/data/build/dist/client/locales/assistantAvatar.d.ts.map +1 -0
- package/data/build/dist/client/locales/assistantAvatar.js +273 -0
- package/data/build/dist/client/locales/assistantAvatar.js.map +1 -0
- package/data/build/dist/client/locales/assistantDebug.d.ts +4 -0
- package/data/build/dist/client/locales/assistantDebug.d.ts.map +1 -0
- package/data/build/dist/client/locales/assistantDebug.js +362 -0
- package/data/build/dist/client/locales/assistantDebug.js.map +1 -0
- package/data/build/dist/client/locales/assistantTts.d.ts +80 -0
- package/data/build/dist/client/locales/assistantTts.d.ts.map +1 -0
- package/data/build/dist/client/locales/assistantTts.js +76 -0
- package/data/build/dist/client/locales/assistantTts.js.map +1 -0
- package/data/build/dist/client/locales/assistantWorkbench.d.ts +126 -0
- package/data/build/dist/client/locales/assistantWorkbench.d.ts.map +1 -0
- package/data/build/dist/client/locales/assistantWorkbench.js +96 -0
- package/data/build/dist/client/locales/assistantWorkbench.js.map +1 -0
- package/data/build/dist/client/locales/peerHost.d.ts.map +1 -1
- package/data/build/dist/client/locales/peerHost.js +4 -0
- package/data/build/dist/client/locales/peerHost.js.map +1 -1
- package/data/build/dist/client/locales/peerHostWorkspace.js +2 -2
- package/data/build/dist/client/locales/peerHostWorkspace.js.map +1 -1
- package/data/build/dist/client/locales/terminalAuth.d.ts.map +1 -1
- package/data/build/dist/client/locales/terminalAuth.js +80 -0
- package/data/build/dist/client/locales/terminalAuth.js.map +1 -1
- package/data/build/dist/client/locales/usage.d.ts.map +1 -1
- package/data/build/dist/client/locales/usage.js +4 -0
- package/data/build/dist/client/locales/usage.js.map +1 -1
- package/data/build/dist/client/locales/voiceModels.d.ts +45 -0
- package/data/build/dist/client/locales/voiceModels.d.ts.map +1 -0
- package/data/build/dist/client/locales/voiceModels.js +85 -0
- package/data/build/dist/client/locales/voiceModels.js.map +1 -0
- package/data/build/dist/client/mobile-rightbar-tabs-dom.d.ts +29 -0
- package/data/build/dist/client/mobile-rightbar-tabs-dom.d.ts.map +1 -0
- package/data/build/dist/client/mobile-rightbar-tabs-dom.js +93 -0
- package/data/build/dist/client/mobile-rightbar-tabs-dom.js.map +1 -0
- package/data/build/dist/client/mobile-rightbar-visibility.d.ts +32 -0
- package/data/build/dist/client/mobile-rightbar-visibility.d.ts.map +1 -0
- package/data/build/dist/client/mobile-rightbar-visibility.js +188 -0
- package/data/build/dist/client/mobile-rightbar-visibility.js.map +1 -0
- package/data/build/dist/client/mobile-session-interaction.d.ts +9 -19
- package/data/build/dist/client/mobile-session-interaction.d.ts.map +1 -1
- package/data/build/dist/client/mobile-session-interaction.js +25 -169
- package/data/build/dist/client/mobile-session-interaction.js.map +1 -1
- package/data/build/dist/client/mobile-sidebar-gestures.d.ts +4 -0
- package/data/build/dist/client/mobile-sidebar-gestures.d.ts.map +1 -1
- package/data/build/dist/client/mobile-sidebar-gestures.js +17 -9
- package/data/build/dist/client/mobile-sidebar-gestures.js.map +1 -1
- package/data/build/dist/client/model-catalog-cache.d.ts +4 -4
- package/data/build/dist/client/model-catalog-cache.d.ts.map +1 -1
- package/data/build/dist/client/model-catalog-cache.js +66 -34
- package/data/build/dist/client/model-catalog-cache.js.map +1 -1
- package/data/build/dist/client/moss-voice-output.d.ts +39 -0
- package/data/build/dist/client/moss-voice-output.d.ts.map +1 -0
- package/data/build/dist/client/moss-voice-output.js +241 -0
- package/data/build/dist/client/moss-voice-output.js.map +1 -0
- package/data/build/dist/client/rpc-call.d.ts +4 -0
- package/data/build/dist/client/rpc-call.d.ts.map +1 -0
- package/data/build/dist/client/rpc-call.js +23 -0
- package/data/build/dist/client/rpc-call.js.map +1 -0
- package/data/build/dist/client/serial-polling.d.ts +13 -0
- package/data/build/dist/client/serial-polling.d.ts.map +1 -0
- package/data/build/dist/client/serial-polling.js +41 -0
- package/data/build/dist/client/serial-polling.js.map +1 -0
- package/data/build/dist/client/session-adapter-cache.d.ts.map +1 -1
- package/data/build/dist/client/session-adapter-cache.js +11 -1
- package/data/build/dist/client/session-adapter-cache.js.map +1 -1
- package/data/build/dist/client/settings-bridge.d.ts +1 -0
- package/data/build/dist/client/settings-bridge.d.ts.map +1 -1
- package/data/build/dist/client/settings-bridge.js +9 -1
- package/data/build/dist/client/settings-bridge.js.map +1 -1
- package/data/build/dist/client/sherpa-voice-adapter.d.ts +23 -2
- package/data/build/dist/client/sherpa-voice-adapter.d.ts.map +1 -1
- package/data/build/dist/client/sherpa-voice-adapter.js +386 -93
- package/data/build/dist/client/sherpa-voice-adapter.js.map +1 -1
- package/data/build/dist/client/streaming-sentence-queue.d.ts +20 -0
- package/data/build/dist/client/streaming-sentence-queue.d.ts.map +1 -0
- package/data/build/dist/client/streaming-sentence-queue.js +130 -0
- package/data/build/dist/client/streaming-sentence-queue.js.map +1 -0
- package/data/build/dist/client/subscription-slot.d.ts +11 -0
- package/data/build/dist/client/subscription-slot.d.ts.map +1 -1
- package/data/build/dist/client/subscription-slot.js +42 -15
- package/data/build/dist/client/subscription-slot.js.map +1 -1
- package/data/build/dist/client/terminal/log-preview.d.ts +14 -0
- package/data/build/dist/client/terminal/log-preview.d.ts.map +1 -0
- package/data/build/dist/client/terminal/log-preview.js +23 -0
- package/data/build/dist/client/terminal/log-preview.js.map +1 -0
- package/data/build/dist/client/terminal/model.d.ts +38 -7
- package/data/build/dist/client/terminal/model.d.ts.map +1 -1
- package/data/build/dist/client/terminal/model.js +188 -32
- package/data/build/dist/client/terminal/model.js.map +1 -1
- package/data/build/dist/client/terminal/recovery.d.ts +7 -3
- package/data/build/dist/client/terminal/recovery.d.ts.map +1 -1
- package/data/build/dist/client/terminal/recovery.js +45 -41
- package/data/build/dist/client/terminal/recovery.js.map +1 -1
- package/data/build/dist/client/terminal/selection-actions.d.ts +63 -0
- package/data/build/dist/client/terminal/selection-actions.d.ts.map +1 -0
- package/data/build/dist/client/terminal/selection-actions.js +132 -0
- package/data/build/dist/client/terminal/selection-actions.js.map +1 -0
- package/data/build/dist/client/terminal/share-menu.d.ts +17 -0
- package/data/build/dist/client/terminal/share-menu.d.ts.map +1 -0
- package/data/build/dist/client/terminal/share-menu.js +131 -0
- package/data/build/dist/client/terminal/share-menu.js.map +1 -0
- package/data/build/dist/client/terminal/sharing.d.ts +42 -0
- package/data/build/dist/client/terminal/sharing.d.ts.map +1 -0
- package/data/build/dist/client/terminal/sharing.js +144 -0
- package/data/build/dist/client/terminal/sharing.js.map +1 -0
- package/data/build/dist/client/terminal/snapshot.d.ts +32 -0
- package/data/build/dist/client/terminal/snapshot.d.ts.map +1 -0
- package/data/build/dist/client/terminal/snapshot.js +108 -0
- package/data/build/dist/client/terminal/snapshot.js.map +1 -0
- package/data/build/dist/client/terminal/styles.d.ts +14 -0
- package/data/build/dist/client/terminal/styles.d.ts.map +1 -1
- package/data/build/dist/client/terminal/styles.js +39 -1
- package/data/build/dist/client/terminal/styles.js.map +1 -1
- package/data/build/dist/client/terminal/surface-cache.d.ts +10 -0
- package/data/build/dist/client/terminal/surface-cache.d.ts.map +1 -0
- package/data/build/dist/client/terminal/surface-cache.js +19 -0
- package/data/build/dist/client/terminal/surface-cache.js.map +1 -0
- package/data/build/dist/client/terminal/ui.d.ts.map +1 -1
- package/data/build/dist/client/terminal/ui.js +78 -21
- package/data/build/dist/client/terminal/ui.js.map +1 -1
- package/data/build/dist/client/terminal/xterm-view.d.ts +5 -2
- package/data/build/dist/client/terminal/xterm-view.d.ts.map +1 -1
- package/data/build/dist/client/terminal/xterm-view.js +429 -397
- package/data/build/dist/client/terminal/xterm-view.js.map +1 -1
- package/data/build/dist/client/touch-input-focus.d.ts +30 -0
- package/data/build/dist/client/touch-input-focus.d.ts.map +1 -0
- package/data/build/dist/client/touch-input-focus.js +190 -0
- package/data/build/dist/client/touch-input-focus.js.map +1 -0
- package/data/build/dist/client/voice-capture.d.ts +9 -0
- package/data/build/dist/client/voice-capture.d.ts.map +1 -1
- package/data/build/dist/client/voice-capture.js +35 -1
- package/data/build/dist/client/voice-capture.js.map +1 -1
- package/data/build/dist/client/voice-chat-updates.d.ts +12 -0
- package/data/build/dist/client/voice-chat-updates.d.ts.map +1 -0
- package/data/build/dist/client/voice-chat-updates.js +39 -0
- package/data/build/dist/client/voice-chat-updates.js.map +1 -0
- package/data/build/dist/client/voice-diagnostics.d.ts +19 -0
- package/data/build/dist/client/voice-diagnostics.d.ts.map +1 -0
- package/data/build/dist/client/voice-diagnostics.js +73 -0
- package/data/build/dist/client/voice-diagnostics.js.map +1 -0
- package/data/build/dist/client/voice-model-setup-progress.d.ts +8 -0
- package/data/build/dist/client/voice-model-setup-progress.d.ts.map +1 -0
- package/data/build/dist/client/voice-model-setup-progress.js +27 -0
- package/data/build/dist/client/voice-model-setup-progress.js.map +1 -0
- package/data/build/dist/client/voice-stream-uploader.d.ts +41 -0
- package/data/build/dist/client/voice-stream-uploader.d.ts.map +1 -0
- package/data/build/dist/client/voice-stream-uploader.js +154 -0
- package/data/build/dist/client/voice-stream-uploader.js.map +1 -0
- package/data/build/dist/dsh-capabilities/client/config-forms-adapter.d.ts +4 -0
- package/data/build/dist/dsh-capabilities/client/config-forms-adapter.d.ts.map +1 -1
- package/data/build/dist/dsh-capabilities/client/config-forms-adapter.js +9 -0
- package/data/build/dist/dsh-capabilities/client/config-forms-adapter.js.map +1 -1
- package/data/build/dist/dsh-capabilities/client/primitives-adapter.d.ts +5 -1
- package/data/build/dist/dsh-capabilities/client/primitives-adapter.d.ts.map +1 -1
- package/data/build/dist/dsh-capabilities/client/primitives-adapter.js +25 -0
- package/data/build/dist/dsh-capabilities/client/primitives-adapter.js.map +1 -1
- package/data/build/dist/dsh-capabilities/client/terminal-sharing-adapter.d.ts +33 -0
- package/data/build/dist/dsh-capabilities/client/terminal-sharing-adapter.d.ts.map +1 -0
- package/data/build/dist/dsh-capabilities/client/terminal-sharing-adapter.js +187 -0
- package/data/build/dist/dsh-capabilities/client/terminal-sharing-adapter.js.map +1 -0
- package/data/build/dist/dsh-capabilities/host/assistant-agent-adapter.d.ts +55 -0
- package/data/build/dist/dsh-capabilities/host/assistant-agent-adapter.d.ts.map +1 -0
- package/data/build/dist/dsh-capabilities/host/assistant-agent-adapter.js +264 -0
- package/data/build/dist/dsh-capabilities/host/assistant-agent-adapter.js.map +1 -0
- package/data/build/dist/dsh-capabilities/host/assistant-attachment-adapter.d.ts +16 -0
- package/data/build/dist/dsh-capabilities/host/assistant-attachment-adapter.d.ts.map +1 -0
- package/data/build/dist/dsh-capabilities/host/assistant-attachment-adapter.js +69 -0
- package/data/build/dist/dsh-capabilities/host/assistant-attachment-adapter.js.map +1 -0
- package/data/build/dist/dsh-capabilities/host/assistant-llm-adapter.d.ts +36 -0
- package/data/build/dist/dsh-capabilities/host/assistant-llm-adapter.d.ts.map +1 -0
- package/data/build/dist/dsh-capabilities/host/assistant-llm-adapter.js +112 -0
- package/data/build/dist/dsh-capabilities/host/assistant-llm-adapter.js.map +1 -0
- package/data/build/dist/dsh-capabilities/host/assistant-web-search-adapter.d.ts +4 -0
- package/data/build/dist/dsh-capabilities/host/assistant-web-search-adapter.d.ts.map +1 -0
- package/data/build/dist/dsh-capabilities/host/assistant-web-search-adapter.js +41 -0
- package/data/build/dist/dsh-capabilities/host/assistant-web-search-adapter.js.map +1 -0
- package/data/build/dist/dsh-capabilities/matrix.d.ts.map +1 -1
- package/data/build/dist/dsh-capabilities/matrix.js +3 -0
- package/data/build/dist/dsh-capabilities/matrix.js.map +1 -1
- package/data/build/dist/dsh-capabilities/routes.d.ts.map +1 -1
- package/data/build/dist/dsh-capabilities/routes.js +18 -0
- package/data/build/dist/dsh-capabilities/routes.js.map +1 -1
- package/data/build/dist/dsh-capabilities/settings-store.d.ts +2 -0
- package/data/build/dist/dsh-capabilities/settings-store.d.ts.map +1 -1
- package/data/build/dist/dsh-capabilities/settings-store.js.map +1 -1
- package/data/build/dist/dsh-capabilities/types.d.ts +1 -1
- package/data/build/dist/dsh-capabilities/types.d.ts.map +1 -1
- package/data/build/dist/dsh-capabilities/types.js.map +1 -1
- package/data/build/dist/host/avatar/catalog.d.ts +21 -0
- package/data/build/dist/host/avatar/catalog.d.ts.map +1 -0
- package/data/build/dist/host/avatar/catalog.js +123 -0
- package/data/build/dist/host/avatar/catalog.js.map +1 -0
- package/data/build/dist/host/avatar/engine.d.ts +42 -0
- package/data/build/dist/host/avatar/engine.d.ts.map +1 -0
- package/data/build/dist/host/avatar/engine.js +167 -0
- package/data/build/dist/host/avatar/engine.js.map +1 -0
- package/data/build/dist/host/avatar/materials.d.ts +28 -0
- package/data/build/dist/host/avatar/materials.d.ts.map +1 -0
- package/data/build/dist/host/avatar/materials.js +183 -0
- package/data/build/dist/host/avatar/materials.js.map +1 -0
- package/data/build/dist/host/avatar/packages.d.ts +34 -0
- package/data/build/dist/host/avatar/packages.d.ts.map +1 -0
- package/data/build/dist/host/avatar/packages.js +200 -0
- package/data/build/dist/host/avatar/packages.js.map +1 -0
- package/data/build/dist/host/avatar/registry.d.ts +12 -0
- package/data/build/dist/host/avatar/registry.d.ts.map +1 -0
- package/data/build/dist/host/avatar/registry.js +22 -0
- package/data/build/dist/host/avatar/registry.js.map +1 -0
- package/data/build/dist/host/avatar/remote.d.ts +18 -0
- package/data/build/dist/host/avatar/remote.d.ts.map +1 -0
- package/data/build/dist/host/avatar/remote.js +103 -0
- package/data/build/dist/host/avatar/remote.js.map +1 -0
- package/data/build/dist/host/avatar/sources.d.ts +11 -0
- package/data/build/dist/host/avatar/sources.d.ts.map +1 -0
- package/data/build/dist/host/avatar/sources.js +78 -0
- package/data/build/dist/host/avatar/sources.js.map +1 -0
- package/data/build/dist/host/avatar/temporary-previews.d.ts +26 -0
- package/data/build/dist/host/avatar/temporary-previews.d.ts.map +1 -0
- package/data/build/dist/host/avatar/temporary-previews.js +139 -0
- package/data/build/dist/host/avatar/temporary-previews.js.map +1 -0
- package/data/build/dist/host/cli-adapters/acp-cli-driver.d.ts +1 -1
- package/data/build/dist/host/cli-adapters/acp-cli-driver.d.ts.map +1 -1
- package/data/build/dist/host/cli-adapters/acp-cli-driver.js +3 -10
- package/data/build/dist/host/cli-adapters/acp-cli-driver.js.map +1 -1
- package/data/build/dist/host/cli-adapters/antigravity-subscription.d.ts.map +1 -1
- package/data/build/dist/host/cli-adapters/antigravity-subscription.js +10 -10
- package/data/build/dist/host/cli-adapters/antigravity-subscription.js.map +1 -1
- package/data/build/dist/host/cli-adapters/claude-driver.d.ts.map +1 -1
- package/data/build/dist/host/cli-adapters/claude-driver.js +7 -5
- package/data/build/dist/host/cli-adapters/claude-driver.js.map +1 -1
- package/data/build/dist/host/cli-adapters/codebuddy-driver.d.ts.map +1 -1
- package/data/build/dist/host/cli-adapters/codebuddy-driver.js +8 -7
- package/data/build/dist/host/cli-adapters/codebuddy-driver.js.map +1 -1
- package/data/build/dist/host/cli-adapters/codex-driver.d.ts.map +1 -1
- package/data/build/dist/host/cli-adapters/codex-driver.js +10 -3
- package/data/build/dist/host/cli-adapters/codex-driver.js.map +1 -1
- package/data/build/dist/host/cli-adapters/command-code-driver.d.ts.map +1 -1
- package/data/build/dist/host/cli-adapters/command-code-driver.js +9 -8
- package/data/build/dist/host/cli-adapters/command-code-driver.js.map +1 -1
- package/data/build/dist/host/cli-adapters/cursor-driver.d.ts.map +1 -1
- package/data/build/dist/host/cli-adapters/cursor-driver.js +4 -3
- package/data/build/dist/host/cli-adapters/cursor-driver.js.map +1 -1
- package/data/build/dist/host/cli-adapters/delegate-dispatch.js +1 -1
- package/data/build/dist/host/cli-adapters/delegate-dispatch.js.map +1 -1
- package/data/build/dist/host/cli-adapters/delegation-mention-rewrite.d.ts +2 -0
- package/data/build/dist/host/cli-adapters/delegation-mention-rewrite.d.ts.map +1 -1
- package/data/build/dist/host/cli-adapters/delegation-mention-rewrite.js +5 -0
- package/data/build/dist/host/cli-adapters/delegation-mention-rewrite.js.map +1 -1
- package/data/build/dist/host/cli-adapters/desktop-app-runtime.d.ts.map +1 -1
- package/data/build/dist/host/cli-adapters/desktop-app-runtime.js +2 -4
- package/data/build/dist/host/cli-adapters/desktop-app-runtime.js.map +1 -1
- package/data/build/dist/host/cli-adapters/driver.d.ts +1 -1
- package/data/build/dist/host/cli-adapters/feature.d.ts.map +1 -1
- package/data/build/dist/host/cli-adapters/feature.js +28 -36
- package/data/build/dist/host/cli-adapters/feature.js.map +1 -1
- package/data/build/dist/host/cli-adapters/grok-driver.d.ts.map +1 -1
- package/data/build/dist/host/cli-adapters/grok-driver.js +2 -1
- package/data/build/dist/host/cli-adapters/grok-driver.js.map +1 -1
- package/data/build/dist/host/cli-adapters/kimi-driver.d.ts.map +1 -1
- package/data/build/dist/host/cli-adapters/kimi-driver.js +4 -3
- package/data/build/dist/host/cli-adapters/kimi-driver.js.map +1 -1
- package/data/build/dist/host/cli-adapters/legacy-session-adapter.d.ts +2 -0
- package/data/build/dist/host/cli-adapters/legacy-session-adapter.d.ts.map +1 -1
- package/data/build/dist/host/cli-adapters/legacy-session-adapter.js +10 -0
- package/data/build/dist/host/cli-adapters/legacy-session-adapter.js.map +1 -1
- package/data/build/dist/host/cli-adapters/log-files.d.ts +3 -0
- package/data/build/dist/host/cli-adapters/log-files.d.ts.map +1 -0
- package/data/build/dist/host/cli-adapters/log-files.js +32 -0
- package/data/build/dist/host/cli-adapters/log-files.js.map +1 -0
- package/data/build/dist/host/cli-adapters/native-team-subagent.js +1 -1
- package/data/build/dist/host/cli-adapters/native-team-subagent.js.map +1 -1
- package/data/build/dist/host/cli-adapters/opencode-driver.d.ts +10 -0
- package/data/build/dist/host/cli-adapters/opencode-driver.d.ts.map +1 -1
- package/data/build/dist/host/cli-adapters/opencode-driver.js +128 -26
- package/data/build/dist/host/cli-adapters/opencode-driver.js.map +1 -1
- package/data/build/dist/host/cli-adapters/opencode-v2-protocol.d.ts +29 -0
- package/data/build/dist/host/cli-adapters/opencode-v2-protocol.d.ts.map +1 -0
- package/data/build/dist/host/cli-adapters/opencode-v2-protocol.js +471 -0
- package/data/build/dist/host/cli-adapters/opencode-v2-protocol.js.map +1 -0
- package/data/build/dist/host/cli-adapters/pi-driver.d.ts.map +1 -1
- package/data/build/dist/host/cli-adapters/pi-driver.js +2 -1
- package/data/build/dist/host/cli-adapters/pi-driver.js.map +1 -1
- package/data/build/dist/host/cli-adapters/process-utils.d.ts +8 -2
- package/data/build/dist/host/cli-adapters/process-utils.d.ts.map +1 -1
- package/data/build/dist/host/cli-adapters/process-utils.js +90 -9
- package/data/build/dist/host/cli-adapters/process-utils.js.map +1 -1
- package/data/build/dist/host/cli-adapters/qoder-driver.d.ts.map +1 -1
- package/data/build/dist/host/cli-adapters/qoder-driver.js +55 -72
- package/data/build/dist/host/cli-adapters/qoder-driver.js.map +1 -1
- package/data/build/dist/host/cli-adapters/qoder-subscription.d.ts +6 -1
- package/data/build/dist/host/cli-adapters/qoder-subscription.d.ts.map +1 -1
- package/data/build/dist/host/cli-adapters/qoder-subscription.js +37 -10
- package/data/build/dist/host/cli-adapters/qoder-subscription.js.map +1 -1
- package/data/build/dist/host/cli-adapters/registry.d.ts +13 -21
- package/data/build/dist/host/cli-adapters/registry.d.ts.map +1 -1
- package/data/build/dist/host/cli-adapters/registry.js +71 -127
- package/data/build/dist/host/cli-adapters/registry.js.map +1 -1
- package/data/build/dist/host/cli-adapters/rpc-driver-utils.d.ts +1 -0
- package/data/build/dist/host/cli-adapters/rpc-driver-utils.d.ts.map +1 -1
- package/data/build/dist/host/cli-adapters/rpc-driver-utils.js +6 -6
- package/data/build/dist/host/cli-adapters/rpc-driver-utils.js.map +1 -1
- package/data/build/dist/host/cli-adapters/session-store.d.ts +5 -1
- package/data/build/dist/host/cli-adapters/session-store.d.ts.map +1 -1
- package/data/build/dist/host/cli-adapters/session-store.js +68 -11
- package/data/build/dist/host/cli-adapters/session-store.js.map +1 -1
- package/data/build/dist/host/cli-adapters/standard-stream-driver.d.ts.map +1 -1
- package/data/build/dist/host/cli-adapters/standard-stream-driver.js +4 -3
- package/data/build/dist/host/cli-adapters/standard-stream-driver.js.map +1 -1
- package/data/build/dist/host/cli-bridge/dispatch.js +1 -1
- package/data/build/dist/host/cli-bridge/dispatch.js.map +1 -1
- package/data/build/dist/host/debug.d.ts.map +1 -1
- package/data/build/dist/host/debug.js +5 -4
- package/data/build/dist/host/debug.js.map +1 -1
- package/data/build/dist/host/desktop-assistant/controller.d.ts +44 -0
- package/data/build/dist/host/desktop-assistant/controller.d.ts.map +1 -0
- package/data/build/dist/host/desktop-assistant/controller.js +150 -0
- package/data/build/dist/host/desktop-assistant/controller.js.map +1 -0
- package/data/build/dist/host/desktop-assistant/feature.d.ts +9 -0
- package/data/build/dist/host/desktop-assistant/feature.d.ts.map +1 -0
- package/data/build/dist/host/desktop-assistant/feature.js +102 -0
- package/data/build/dist/host/desktop-assistant/feature.js.map +1 -0
- package/data/build/dist/host/desktop-assistant/launcher.d.ts +5 -0
- package/data/build/dist/host/desktop-assistant/launcher.d.ts.map +1 -0
- package/data/build/dist/host/desktop-assistant/launcher.js +84 -0
- package/data/build/dist/host/desktop-assistant/launcher.js.map +1 -0
- package/data/build/dist/host/desktop-assistant/mac-agent.d.ts +5 -0
- package/data/build/dist/host/desktop-assistant/mac-agent.d.ts.map +1 -0
- package/data/build/dist/host/desktop-assistant/mac-agent.js +122 -0
- package/data/build/dist/host/desktop-assistant/mac-agent.js.map +1 -0
- package/data/build/dist/host/desktop-assistant/process.d.ts +4 -0
- package/data/build/dist/host/desktop-assistant/process.d.ts.map +1 -0
- package/data/build/dist/host/desktop-assistant/process.js +25 -0
- package/data/build/dist/host/desktop-assistant/process.js.map +1 -0
- package/data/build/dist/host/desktop-assistant/server.d.ts +12 -0
- package/data/build/dist/host/desktop-assistant/server.d.ts.map +1 -0
- package/data/build/dist/host/desktop-assistant/server.js +74 -0
- package/data/build/dist/host/desktop-assistant/server.js.map +1 -0
- package/data/build/dist/host/desktop-assistant/win-agent.d.ts +2 -0
- package/data/build/dist/host/desktop-assistant/win-agent.d.ts.map +1 -0
- package/data/build/dist/host/desktop-assistant/win-agent.js +197 -0
- package/data/build/dist/host/desktop-assistant/win-agent.js.map +1 -0
- package/data/build/dist/host/dsh-runtime-version.d.ts +1 -1
- package/data/build/dist/host/dsh-runtime-version.d.ts.map +1 -1
- package/data/build/dist/host/dsh-runtime-version.js +22 -17
- package/data/build/dist/host/dsh-runtime-version.js.map +1 -1
- package/data/build/dist/host/features/assistant-avatar-assets.d.ts +3 -0
- package/data/build/dist/host/features/assistant-avatar-assets.d.ts.map +1 -0
- package/data/build/dist/host/features/assistant-avatar-assets.js +3 -0
- package/data/build/dist/host/features/assistant-avatar-assets.js.map +1 -0
- package/data/build/dist/host/features/assistant-avatar-basics.d.ts +3 -0
- package/data/build/dist/host/features/assistant-avatar-basics.d.ts.map +1 -0
- package/data/build/dist/host/features/assistant-avatar-basics.js +34 -0
- package/data/build/dist/host/features/assistant-avatar-basics.js.map +1 -0
- package/data/build/dist/host/features/assistant-avatar-legacy-assets.d.ts +6 -0
- package/data/build/dist/host/features/assistant-avatar-legacy-assets.d.ts.map +1 -0
- package/data/build/dist/host/features/assistant-avatar-legacy-assets.js +146 -0
- package/data/build/dist/host/features/assistant-avatar-legacy-assets.js.map +1 -0
- package/data/build/dist/host/features/assistant-avatar-runtime.d.ts +20 -0
- package/data/build/dist/host/features/assistant-avatar-runtime.d.ts.map +1 -0
- package/data/build/dist/host/features/assistant-avatar-runtime.js +250 -0
- package/data/build/dist/host/features/assistant-avatar-runtime.js.map +1 -0
- package/data/build/dist/host/features/assistant-conversation-storage.d.ts +8 -0
- package/data/build/dist/host/features/assistant-conversation-storage.d.ts.map +1 -0
- package/data/build/dist/host/features/assistant-conversation-storage.js +38 -0
- package/data/build/dist/host/features/assistant-conversation-storage.js.map +1 -0
- package/data/build/dist/host/features/assistant-conversation.d.ts +57 -0
- package/data/build/dist/host/features/assistant-conversation.d.ts.map +1 -0
- package/data/build/dist/host/features/assistant-conversation.js +364 -0
- package/data/build/dist/host/features/assistant-conversation.js.map +1 -0
- package/data/build/dist/host/features/assistant-dispatch.d.ts +2 -2
- package/data/build/dist/host/features/assistant-dispatch.d.ts.map +1 -1
- package/data/build/dist/host/features/assistant-dispatch.js +4 -3
- package/data/build/dist/host/features/assistant-dispatch.js.map +1 -1
- package/data/build/dist/host/features/assistant-index-analysis.d.ts +49 -0
- package/data/build/dist/host/features/assistant-index-analysis.d.ts.map +1 -0
- package/data/build/dist/host/features/assistant-index-analysis.js +255 -0
- package/data/build/dist/host/features/assistant-index-analysis.js.map +1 -0
- package/data/build/dist/host/features/assistant-index-journal.d.ts +20 -0
- package/data/build/dist/host/features/assistant-index-journal.d.ts.map +1 -0
- package/data/build/dist/host/features/assistant-index-journal.js +40 -0
- package/data/build/dist/host/features/assistant-index-journal.js.map +1 -0
- package/data/build/dist/host/features/assistant-index-retry.d.ts +12 -0
- package/data/build/dist/host/features/assistant-index-retry.d.ts.map +1 -0
- package/data/build/dist/host/features/assistant-index-retry.js +54 -0
- package/data/build/dist/host/features/assistant-index-retry.js.map +1 -0
- package/data/build/dist/host/features/assistant-index-updates.d.ts +40 -0
- package/data/build/dist/host/features/assistant-index-updates.d.ts.map +1 -0
- package/data/build/dist/host/features/assistant-index-updates.js +183 -0
- package/data/build/dist/host/features/assistant-index-updates.js.map +1 -0
- package/data/build/dist/host/features/assistant-lifecycle-settings.d.ts +5 -0
- package/data/build/dist/host/features/assistant-lifecycle-settings.d.ts.map +1 -0
- package/data/build/dist/host/features/assistant-lifecycle-settings.js +72 -0
- package/data/build/dist/host/features/assistant-lifecycle-settings.js.map +1 -0
- package/data/build/dist/host/features/assistant-management-tools.d.ts +34 -0
- package/data/build/dist/host/features/assistant-management-tools.d.ts.map +1 -0
- package/data/build/dist/host/features/assistant-management-tools.js +69 -0
- package/data/build/dist/host/features/assistant-management-tools.js.map +1 -0
- package/data/build/dist/host/features/assistant-prompts.d.ts +6 -0
- package/data/build/dist/host/features/assistant-prompts.d.ts.map +1 -0
- package/data/build/dist/host/features/assistant-prompts.js +62 -0
- package/data/build/dist/host/features/assistant-prompts.js.map +1 -0
- package/data/build/dist/host/features/assistant-session-index.d.ts +6 -1
- package/data/build/dist/host/features/assistant-session-index.d.ts.map +1 -1
- package/data/build/dist/host/features/assistant-session-index.js +11 -12
- package/data/build/dist/host/features/assistant-session-index.js.map +1 -1
- package/data/build/dist/host/features/assistant-source-cache.d.ts +12 -0
- package/data/build/dist/host/features/assistant-source-cache.d.ts.map +1 -0
- package/data/build/dist/host/features/assistant-source-cache.js +56 -0
- package/data/build/dist/host/features/assistant-source-cache.js.map +1 -0
- package/data/build/dist/host/features/assistant-structured-index.d.ts +21 -0
- package/data/build/dist/host/features/assistant-structured-index.d.ts.map +1 -0
- package/data/build/dist/host/features/assistant-structured-index.js +138 -0
- package/data/build/dist/host/features/assistant-structured-index.js.map +1 -0
- package/data/build/dist/host/features/assistant-summary.d.ts.map +1 -1
- package/data/build/dist/host/features/assistant-summary.js +7 -1
- package/data/build/dist/host/features/assistant-summary.js.map +1 -1
- package/data/build/dist/host/features/assistant-text-chat.d.ts +29 -0
- package/data/build/dist/host/features/assistant-text-chat.d.ts.map +1 -0
- package/data/build/dist/host/features/assistant-text-chat.js +195 -0
- package/data/build/dist/host/features/assistant-text-chat.js.map +1 -0
- package/data/build/dist/host/features/assistant-tts-service.d.ts +47 -0
- package/data/build/dist/host/features/assistant-tts-service.d.ts.map +1 -0
- package/data/build/dist/host/features/assistant-tts-service.js +507 -0
- package/data/build/dist/host/features/assistant-tts-service.js.map +1 -0
- package/data/build/dist/host/features/assistant-voice-chat.d.ts +35 -0
- package/data/build/dist/host/features/assistant-voice-chat.d.ts.map +1 -0
- package/data/build/dist/host/features/assistant-voice-chat.js +133 -0
- package/data/build/dist/host/features/assistant-voice-chat.js.map +1 -0
- package/data/build/dist/host/features/assistant-voice-hotwords.d.ts +33 -0
- package/data/build/dist/host/features/assistant-voice-hotwords.d.ts.map +1 -0
- package/data/build/dist/host/features/assistant-voice-hotwords.js +114 -0
- package/data/build/dist/host/features/assistant-voice-hotwords.js.map +1 -0
- package/data/build/dist/host/features/assistant-voice-initialization.d.ts +26 -0
- package/data/build/dist/host/features/assistant-voice-initialization.d.ts.map +1 -0
- package/data/build/dist/host/features/assistant-voice-initialization.js +68 -0
- package/data/build/dist/host/features/assistant-voice-initialization.js.map +1 -0
- package/data/build/dist/host/features/assistant-voice-sources.d.ts +13 -0
- package/data/build/dist/host/features/assistant-voice-sources.d.ts.map +1 -0
- package/data/build/dist/host/features/assistant-voice-sources.js +72 -0
- package/data/build/dist/host/features/assistant-voice-sources.js.map +1 -0
- package/data/build/dist/host/features/assistant-voice-stream.d.ts +10 -0
- package/data/build/dist/host/features/assistant-voice-stream.d.ts.map +1 -1
- package/data/build/dist/host/features/assistant-voice-stream.js +208 -5
- package/data/build/dist/host/features/assistant-voice-stream.js.map +1 -1
- package/data/build/dist/host/features/global-voice-coordinator.d.ts.map +1 -1
- package/data/build/dist/host/features/global-voice-coordinator.js +15 -10
- package/data/build/dist/host/features/global-voice-coordinator.js.map +1 -1
- package/data/build/dist/host/features/global-voice-rpc.d.ts +8 -1
- package/data/build/dist/host/features/global-voice-rpc.d.ts.map +1 -1
- package/data/build/dist/host/features/global-voice-rpc.js +1076 -159
- package/data/build/dist/host/features/global-voice-rpc.js.map +1 -1
- package/data/build/dist/host/features/index.d.ts.map +1 -1
- package/data/build/dist/host/features/index.js +4 -0
- package/data/build/dist/host/features/index.js.map +1 -1
- package/data/build/dist/host/features/moss-tts-worker.d.ts +32 -0
- package/data/build/dist/host/features/moss-tts-worker.d.ts.map +1 -0
- package/data/build/dist/host/features/moss-tts-worker.js +216 -0
- package/data/build/dist/host/features/moss-tts-worker.js.map +1 -0
- package/data/build/dist/host/features/peer-host.d.ts.map +1 -1
- package/data/build/dist/host/features/peer-host.js +15 -7
- package/data/build/dist/host/features/peer-host.js.map +1 -1
- package/data/build/dist/host/features/sherpa-voice-runtime.d.ts +11 -0
- package/data/build/dist/host/features/sherpa-voice-runtime.d.ts.map +1 -1
- package/data/build/dist/host/features/sherpa-voice-runtime.js +72 -17
- package/data/build/dist/host/features/sherpa-voice-runtime.js.map +1 -1
- package/data/build/dist/host/features/sherpa-voice-worker.d.ts +18 -0
- package/data/build/dist/host/features/sherpa-voice-worker.d.ts.map +1 -0
- package/data/build/dist/host/features/sherpa-voice-worker.js +40 -0
- package/data/build/dist/host/features/sherpa-voice-worker.js.map +1 -0
- package/data/build/dist/host/features/sherpa-worker-runtime.d.ts +41 -0
- package/data/build/dist/host/features/sherpa-worker-runtime.d.ts.map +1 -0
- package/data/build/dist/host/features/sherpa-worker-runtime.js +200 -0
- package/data/build/dist/host/features/sherpa-worker-runtime.js.map +1 -0
- package/data/build/dist/host/features/types.d.ts +9 -1
- package/data/build/dist/host/features/types.d.ts.map +1 -1
- package/data/build/dist/host/features/voice-model-management.d.ts +22 -0
- package/data/build/dist/host/features/voice-model-management.d.ts.map +1 -0
- package/data/build/dist/host/features/voice-model-management.js +178 -0
- package/data/build/dist/host/features/voice-model-management.js.map +1 -0
- package/data/build/dist/host/features/voice-model-probe.d.ts +8 -0
- package/data/build/dist/host/features/voice-model-probe.d.ts.map +1 -0
- package/data/build/dist/host/features/voice-model-probe.js +76 -0
- package/data/build/dist/host/features/voice-model-probe.js.map +1 -0
- package/data/build/dist/host/features/voice-model-setup.d.ts +5 -2
- package/data/build/dist/host/features/voice-model-setup.d.ts.map +1 -1
- package/data/build/dist/host/features/voice-model-setup.js +40 -13
- package/data/build/dist/host/features/voice-model-setup.js.map +1 -1
- package/data/build/dist/host/features/voice-process-environment.d.ts +3 -0
- package/data/build/dist/host/features/voice-process-environment.d.ts.map +1 -0
- package/data/build/dist/host/features/voice-process-environment.js +16 -0
- package/data/build/dist/host/features/voice-process-environment.js.map +1 -0
- package/data/build/dist/host/features/voice-python-runtime.d.ts +21 -0
- package/data/build/dist/host/features/voice-python-runtime.d.ts.map +1 -0
- package/data/build/dist/host/features/voice-python-runtime.js +189 -0
- package/data/build/dist/host/features/voice-python-runtime.js.map +1 -0
- package/data/build/dist/host/index-injection.d.ts.map +1 -1
- package/data/build/dist/host/index-injection.js +5 -1
- package/data/build/dist/host/index-injection.js.map +1 -1
- package/data/build/dist/host/index.d.ts +6 -1
- package/data/build/dist/host/index.d.ts.map +1 -1
- package/data/build/dist/host/index.js +32 -14
- package/data/build/dist/host/index.js.map +1 -1
- package/data/build/dist/host/lan-access-dsh.d.ts.map +1 -1
- package/data/build/dist/host/lan-access-dsh.js +7 -23
- package/data/build/dist/host/lan-access-dsh.js.map +1 -1
- package/data/build/dist/host/modules/peer-host/host-api-proxy-service.d.ts +6 -46
- package/data/build/dist/host/modules/peer-host/host-api-proxy-service.d.ts.map +1 -1
- package/data/build/dist/host/modules/peer-host/host-api-proxy-service.js +48 -28
- package/data/build/dist/host/modules/peer-host/host-api-proxy-service.js.map +1 -1
- package/data/build/dist/host/modules/peer-host/peer-host-aggregate-service.d.ts +1 -0
- package/data/build/dist/host/modules/peer-host/peer-host-aggregate-service.d.ts.map +1 -1
- package/data/build/dist/host/modules/peer-host/peer-host-aggregate-service.js +1 -0
- package/data/build/dist/host/modules/peer-host/peer-host-aggregate-service.js.map +1 -1
- package/data/build/dist/host/modules/peer-host/peer-host-diagnostics.d.ts.map +1 -1
- package/data/build/dist/host/modules/peer-host/peer-host-diagnostics.js +1 -0
- package/data/build/dist/host/modules/peer-host/peer-host-diagnostics.js.map +1 -1
- package/data/build/dist/host/modules/peer-host/peer-host-handshake.d.ts.map +1 -1
- package/data/build/dist/host/modules/peer-host/peer-host-handshake.js +4 -1
- package/data/build/dist/host/modules/peer-host/peer-host-handshake.js.map +1 -1
- package/data/build/dist/host/modules/peer-host/peer-host-remote-summary-source.js +12 -0
- package/data/build/dist/host/modules/peer-host/peer-host-remote-summary-source.js.map +1 -1
- package/data/build/dist/host/modules/peer-host/peer-host-session.d.ts +7 -1
- package/data/build/dist/host/modules/peer-host/peer-host-session.d.ts.map +1 -1
- package/data/build/dist/host/modules/peer-host/peer-host-session.js +40 -13
- package/data/build/dist/host/modules/peer-host/peer-host-session.js.map +1 -1
- package/data/build/dist/host/rpc.d.ts.map +1 -1
- package/data/build/dist/host/rpc.js +46 -5
- package/data/build/dist/host/rpc.js.map +1 -1
- package/data/build/dist/host/settings.d.ts +2 -1
- package/data/build/dist/host/settings.d.ts.map +1 -1
- package/data/build/dist/host/settings.js +77 -13
- package/data/build/dist/host/settings.js.map +1 -1
- package/data/build/dist/host/stage0-dev-hmr.d.ts +6 -0
- package/data/build/dist/host/stage0-dev-hmr.d.ts.map +1 -0
- package/data/build/dist/host/stage0-dev-hmr.js +20 -0
- package/data/build/dist/host/stage0-dev-hmr.js.map +1 -0
- package/data/build/dist/host/tar-archive.d.ts +8 -0
- package/data/build/dist/host/tar-archive.d.ts.map +1 -0
- package/data/build/dist/host/tar-archive.js +17 -0
- package/data/build/dist/host/tar-archive.js.map +1 -0
- package/data/build/dist/host/terminal/backends/tmux-backend.d.ts +1 -1
- package/data/build/dist/host/terminal/backends/tmux-backend.d.ts.map +1 -1
- package/data/build/dist/host/terminal/backends/tmux-backend.js +15 -14
- package/data/build/dist/host/terminal/backends/tmux-backend.js.map +1 -1
- package/data/build/dist/host/voice-diagnostics.d.ts +34 -0
- package/data/build/dist/host/voice-diagnostics.d.ts.map +1 -0
- package/data/build/dist/host/voice-diagnostics.js +124 -0
- package/data/build/dist/host/voice-diagnostics.js.map +1 -0
- package/data/build/dist/shared/assistant-attachments.d.ts +27 -0
- package/data/build/dist/shared/assistant-attachments.d.ts.map +1 -0
- package/data/build/dist/shared/assistant-attachments.js +45 -0
- package/data/build/dist/shared/assistant-attachments.js.map +1 -0
- package/data/build/dist/shared/assistant-avatar-adapters.d.ts +18 -0
- package/data/build/dist/shared/assistant-avatar-adapters.d.ts.map +1 -0
- package/data/build/dist/shared/assistant-avatar-adapters.js +119 -0
- package/data/build/dist/shared/assistant-avatar-adapters.js.map +1 -0
- package/data/build/dist/shared/assistant-avatar-catalog.d.ts +37 -0
- package/data/build/dist/shared/assistant-avatar-catalog.d.ts.map +1 -0
- package/data/build/dist/shared/assistant-avatar-catalog.js +21 -0
- package/data/build/dist/shared/assistant-avatar-catalog.js.map +1 -0
- package/data/build/dist/shared/assistant-avatar-engine.d.ts +34 -0
- package/data/build/dist/shared/assistant-avatar-engine.d.ts.map +1 -0
- package/data/build/dist/shared/assistant-avatar-engine.js +32 -0
- package/data/build/dist/shared/assistant-avatar-engine.js.map +1 -0
- package/data/build/dist/shared/assistant-avatar-installation.d.ts +17 -0
- package/data/build/dist/shared/assistant-avatar-installation.d.ts.map +1 -0
- package/data/build/dist/shared/assistant-avatar-installation.js +7 -0
- package/data/build/dist/shared/assistant-avatar-installation.js.map +1 -0
- package/data/build/dist/shared/assistant-avatar-legacy-resources.d.ts +6 -0
- package/data/build/dist/shared/assistant-avatar-legacy-resources.d.ts.map +1 -0
- package/data/build/dist/shared/assistant-avatar-legacy-resources.js +20 -0
- package/data/build/dist/shared/assistant-avatar-legacy-resources.js.map +1 -0
- package/data/build/dist/shared/assistant-avatar-legacy.d.ts +15 -0
- package/data/build/dist/shared/assistant-avatar-legacy.d.ts.map +1 -0
- package/data/build/dist/shared/assistant-avatar-legacy.js +34 -0
- package/data/build/dist/shared/assistant-avatar-legacy.js.map +1 -0
- package/data/build/dist/shared/assistant-avatar-presets.d.ts +3 -0
- package/data/build/dist/shared/assistant-avatar-presets.d.ts.map +1 -0
- package/data/build/dist/shared/assistant-avatar-presets.js +3 -0
- package/data/build/dist/shared/assistant-avatar-presets.js.map +1 -0
- package/data/build/dist/shared/assistant-avatar-registration.d.ts +16 -0
- package/data/build/dist/shared/assistant-avatar-registration.d.ts.map +1 -0
- package/data/build/dist/shared/assistant-avatar-registration.js +33 -0
- package/data/build/dist/shared/assistant-avatar-registration.js.map +1 -0
- package/data/build/dist/shared/assistant-avatar-resources.d.ts +26 -0
- package/data/build/dist/shared/assistant-avatar-resources.d.ts.map +1 -0
- package/data/build/dist/shared/assistant-avatar-resources.js +4 -0
- package/data/build/dist/shared/assistant-avatar-resources.js.map +1 -0
- package/data/build/dist/shared/assistant-avatar.d.ts +103 -0
- package/data/build/dist/shared/assistant-avatar.d.ts.map +1 -0
- package/data/build/dist/shared/assistant-avatar.js +240 -0
- package/data/build/dist/shared/assistant-avatar.js.map +1 -0
- package/data/build/dist/shared/assistant-commands.d.ts +3 -0
- package/data/build/dist/shared/assistant-commands.d.ts.map +1 -0
- package/data/build/dist/shared/assistant-commands.js +3 -0
- package/data/build/dist/shared/assistant-commands.js.map +1 -0
- package/data/build/dist/shared/assistant-lifecycle.d.ts +17 -0
- package/data/build/dist/shared/assistant-lifecycle.d.ts.map +1 -0
- package/data/build/dist/shared/assistant-lifecycle.js +45 -0
- package/data/build/dist/shared/assistant-lifecycle.js.map +1 -0
- package/data/build/dist/shared/assistant-message-timeline.d.ts +13 -0
- package/data/build/dist/shared/assistant-message-timeline.d.ts.map +1 -0
- package/data/build/dist/shared/assistant-message-timeline.js +22 -0
- package/data/build/dist/shared/assistant-message-timeline.js.map +1 -0
- package/data/build/dist/shared/assistant-prompts.d.ts +12 -0
- package/data/build/dist/shared/assistant-prompts.d.ts.map +1 -0
- package/data/build/dist/shared/assistant-prompts.js +32 -0
- package/data/build/dist/shared/assistant-prompts.js.map +1 -0
- package/data/build/dist/shared/assistant-tts.d.ts +93 -0
- package/data/build/dist/shared/assistant-tts.d.ts.map +1 -0
- package/data/build/dist/shared/assistant-tts.js +80 -0
- package/data/build/dist/shared/assistant-tts.js.map +1 -0
- package/data/build/dist/shared/assistant-voice-sessions.d.ts +13 -0
- package/data/build/dist/shared/assistant-voice-sessions.d.ts.map +1 -0
- package/data/build/dist/shared/assistant-voice-sessions.js +16 -0
- package/data/build/dist/shared/assistant-voice-sessions.js.map +1 -0
- package/data/build/dist/shared/contracts/assistant.d.ts +206 -0
- package/data/build/dist/shared/contracts/assistant.d.ts.map +1 -1
- package/data/build/dist/shared/contracts/cli-adapter.d.ts +3 -0
- package/data/build/dist/shared/contracts/cli-adapter.d.ts.map +1 -1
- package/data/build/dist/shared/contracts/config.d.ts +23 -0
- package/data/build/dist/shared/contracts/config.d.ts.map +1 -1
- package/data/build/dist/shared/contracts/config.js +2 -0
- package/data/build/dist/shared/contracts/config.js.map +1 -1
- package/data/build/dist/shared/contracts/errors.d.ts +1 -0
- package/data/build/dist/shared/contracts/errors.d.ts.map +1 -1
- package/data/build/dist/shared/contracts/errors.js +1 -0
- package/data/build/dist/shared/contracts/errors.js.map +1 -1
- package/data/build/dist/shared/contracts/peer-host.d.ts +3 -0
- package/data/build/dist/shared/contracts/peer-host.d.ts.map +1 -1
- package/data/build/dist/shared/contracts/peer-host.js +1 -0
- package/data/build/dist/shared/contracts/peer-host.js.map +1 -1
- package/data/build/dist/shared/contracts/terminal-share.d.ts +27 -0
- package/data/build/dist/shared/contracts/terminal-share.d.ts.map +1 -0
- package/data/build/dist/shared/contracts/terminal-share.js +2 -0
- package/data/build/dist/shared/contracts/terminal-share.js.map +1 -0
- package/data/build/dist/shared/contracts/version.d.ts +3 -1
- package/data/build/dist/shared/contracts/version.d.ts.map +1 -1
- package/data/build/dist/shared/contracts/version.js +20 -7
- package/data/build/dist/shared/contracts/version.js.map +1 -1
- package/data/build/dist/shared/contracts/voice-runtime.d.ts +15 -1
- package/data/build/dist/shared/contracts/voice-runtime.d.ts.map +1 -1
- package/data/build/dist/shared/contracts/voice-runtime.js.map +1 -1
- package/data/build/dist/shared/desktop-assistant.d.ts +35 -0
- package/data/build/dist/shared/desktop-assistant.d.ts.map +1 -0
- package/data/build/dist/shared/desktop-assistant.js +27 -0
- package/data/build/dist/shared/desktop-assistant.js.map +1 -0
- package/data/build/dist/shared/index.d.ts +16 -2
- package/data/build/dist/shared/index.d.ts.map +1 -1
- package/data/build/dist/shared/index.js +10 -0
- package/data/build/dist/shared/index.js.map +1 -1
- package/data/build/dist/shared/peer-host-http-routes.d.ts +62 -0
- package/data/build/dist/shared/peer-host-http-routes.d.ts.map +1 -0
- package/data/build/dist/shared/peer-host-http-routes.js +31 -0
- package/data/build/dist/shared/peer-host-http-routes.js.map +1 -0
- package/data/build/dist/shared/runtime-environment.d.ts +5 -0
- package/data/build/dist/shared/runtime-environment.d.ts.map +1 -0
- package/data/build/dist/shared/runtime-environment.js +7 -0
- package/data/build/dist/shared/runtime-environment.js.map +1 -0
- package/data/build/dist/shared/voice-diagnostics.d.ts +18 -0
- package/data/build/dist/shared/voice-diagnostics.d.ts.map +1 -0
- package/data/build/dist/shared/voice-diagnostics.js +57 -0
- package/data/build/dist/shared/voice-diagnostics.js.map +1 -0
- package/data/build/dist/shared/voice-initialization.d.ts +22 -0
- package/data/build/dist/shared/voice-initialization.d.ts.map +1 -0
- package/data/build/dist/shared/voice-initialization.js +4 -0
- package/data/build/dist/shared/voice-initialization.js.map +1 -0
- package/data/build/dist/shared/voice-models.d.ts +43 -0
- package/data/build/dist/shared/voice-models.d.ts.map +1 -1
- package/data/build/dist/shared/voice-models.js +23 -8
- package/data/build/dist/shared/voice-models.js.map +1 -1
- package/data/build/dist/shared/voice-stream.d.ts +12 -1
- package/data/build/dist/shared/voice-stream.d.ts.map +1 -1
- package/data/build/dist/shared/voice-stream.js +8 -1
- package/data/build/dist/shared/voice-stream.js.map +1 -1
- package/package.json +19 -3
- package/profile/README.md +2 -2
- package/profile/package.json +2 -2
- package/profile/version.json +1 -1
- package/version.json +1 -1
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { type AssistantAttachmentUpload } from '../../shared/assistant-attachments.js';
|
|
2
|
+
/** 只匹配完整指令,避免把路径、带参数文本或普通问题误当成破坏性操作。 */
|
|
3
|
+
export declare function readAssistantComposerCommand(text: string): 'clear' | undefined;
|
|
4
|
+
export declare function isAssistantClearCommandSuggestion(text: string): boolean;
|
|
5
|
+
/** 先归零再测量,删除内容也能缩回单行;超过视口上限后仅内部滚动。 */
|
|
6
|
+
export declare function resizeAssistantComposerTextarea(input: HTMLTextAreaElement): void;
|
|
7
|
+
export declare function validateAssistantFiles(files: readonly File[]): void;
|
|
8
|
+
/** 附件在点击发送时才编码;选择、删除或取消草稿不会在 Host 留下文件。 */
|
|
9
|
+
export declare function encodeAssistantFiles(files: readonly File[]): Promise<readonly AssistantAttachmentUpload[]>;
|
|
10
|
+
//# sourceMappingURL=assistant-composer-input.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"assistant-composer-input.d.ts","sourceRoot":"","sources":["../../../../../src/client/features/assistant-composer-input.ts"],"names":[],"mappings":"AAAA,OAAO,EACwB,KAAK,yBAAyB,EAAE,MAAM,uCAAuC,CAAA;AAG5G,wCAAwC;AACxC,wBAAgB,4BAA4B,CAAC,IAAI,EAAE,MAAM,GAAG,OAAO,GAAG,SAAS,CAE9E;AACD,wBAAgB,iCAAiC,CAAC,IAAI,EAAE,MAAM,GAAG,OAAO,CAGvE;AAED,sCAAsC;AACtC,wBAAgB,+BAA+B,CAAC,KAAK,EAAE,mBAAmB,GAAG,IAAI,CAQhF;AAED,wBAAgB,sBAAsB,CAAC,KAAK,EAAE,SAAS,IAAI,EAAE,GAAG,IAAI,CAInE;AACD,2CAA2C;AAC3C,wBAAsB,oBAAoB,CAAC,KAAK,EAAE,SAAS,IAAI,EAAE,GAAG,OAAO,CAAC,SAAS,yBAAyB,EAAE,CAAC,CAQhH"}
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
import { ASSISTANT_ATTACHMENT_MAX_FILES, ASSISTANT_ATTACHMENT_MAX_BYTES, ASSISTANT_ATTACHMENT_MAX_TOTAL_BYTES, ASSISTANT_IMAGE_MEDIA_TYPES } from '../../shared/assistant-attachments.js';
|
|
2
|
+
import { ASSISTANT_CLEAR_COMMANDS } from '../../shared/assistant-commands.js';
|
|
3
|
+
/** 只匹配完整指令,避免把路径、带参数文本或普通问题误当成破坏性操作。 */
|
|
4
|
+
export function readAssistantComposerCommand(text) {
|
|
5
|
+
return ASSISTANT_CLEAR_COMMANDS.includes(text.trim().toLowerCase()) ? 'clear' : undefined;
|
|
6
|
+
}
|
|
7
|
+
export function isAssistantClearCommandSuggestion(text) {
|
|
8
|
+
const prefix = text.trim().toLowerCase();
|
|
9
|
+
return prefix.startsWith('/') && ASSISTANT_CLEAR_COMMANDS.some((command) => command.startsWith(prefix));
|
|
10
|
+
}
|
|
11
|
+
/** 先归零再测量,删除内容也能缩回单行;超过视口上限后仅内部滚动。 */
|
|
12
|
+
export function resizeAssistantComposerTextarea(input) {
|
|
13
|
+
const style = input.ownerDocument.defaultView?.getComputedStyle(input);
|
|
14
|
+
const minimum = Number.parseFloat(style?.minHeight ?? '') || 38;
|
|
15
|
+
const maximum = Number.parseFloat(style?.maxHeight ?? '') || 120;
|
|
16
|
+
input.style.height = '0px';
|
|
17
|
+
const height = input.scrollHeight;
|
|
18
|
+
input.style.height = `${Math.min(maximum, Math.max(minimum, height))}px`;
|
|
19
|
+
input.style.overflowY = height > maximum ? 'auto' : 'hidden';
|
|
20
|
+
}
|
|
21
|
+
export function validateAssistantFiles(files) {
|
|
22
|
+
if (files.length > ASSISTANT_ATTACHMENT_MAX_FILES)
|
|
23
|
+
throw new Error('awb.attachments.countError');
|
|
24
|
+
if (files.some((file) => file.size > ASSISTANT_ATTACHMENT_MAX_BYTES) || files.reduce((sum, file) => sum + file.size, 0) > ASSISTANT_ATTACHMENT_MAX_TOTAL_BYTES)
|
|
25
|
+
throw new Error('awb.attachments.sizeError');
|
|
26
|
+
if (files.some((file) => file.type.startsWith('image/') && !ASSISTANT_IMAGE_MEDIA_TYPES.some((type) => type === file.type)))
|
|
27
|
+
throw new Error('awb.attachments.typeError');
|
|
28
|
+
}
|
|
29
|
+
/** 附件在点击发送时才编码;选择、删除或取消草稿不会在 Host 留下文件。 */
|
|
30
|
+
export async function encodeAssistantFiles(files) {
|
|
31
|
+
validateAssistantFiles(files);
|
|
32
|
+
return await Promise.all(files.map(async (file) => {
|
|
33
|
+
const bytes = new Uint8Array(await file.arrayBuffer());
|
|
34
|
+
let binary = '';
|
|
35
|
+
for (let offset = 0; offset < bytes.length; offset += 8192)
|
|
36
|
+
binary += String.fromCharCode(...bytes.subarray(offset, offset + 8192));
|
|
37
|
+
return { name: file.name, mediaType: file.type, data: btoa(binary) };
|
|
38
|
+
}));
|
|
39
|
+
}
|
|
40
|
+
//# sourceMappingURL=assistant-composer-input.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"assistant-composer-input.js","sourceRoot":"","sources":["../../../../../src/client/features/assistant-composer-input.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,8BAA8B,EAAE,8BAA8B,EAAE,oCAAoC,EAC3G,2BAA2B,EAAkC,MAAM,uCAAuC,CAAA;AAC5G,OAAO,EAAE,wBAAwB,EAAE,MAAM,oCAAoC,CAAA;AAE7E,wCAAwC;AACxC,MAAM,UAAU,4BAA4B,CAAC,IAAY;IACvD,OAAO,wBAAwB,CAAC,QAAQ,CAAC,IAAI,CAAC,IAAI,EAAE,CAAC,WAAW,EAAE,CAAC,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,SAAS,CAAA;AAC3F,CAAC;AACD,MAAM,UAAU,iCAAiC,CAAC,IAAY;IAC5D,MAAM,MAAM,GAAG,IAAI,CAAC,IAAI,EAAE,CAAC,WAAW,EAAE,CAAA;IACxC,OAAO,MAAM,CAAC,UAAU,CAAC,GAAG,CAAC,IAAI,wBAAwB,CAAC,IAAI,CAAC,CAAC,OAAO,EAAE,EAAE,CAAC,OAAO,CAAC,UAAU,CAAC,MAAM,CAAC,CAAC,CAAA;AACzG,CAAC;AAED,sCAAsC;AACtC,MAAM,UAAU,+BAA+B,CAAC,KAA0B;IACxE,MAAM,KAAK,GAAG,KAAK,CAAC,aAAa,CAAC,WAAW,EAAE,gBAAgB,CAAC,KAAK,CAAC,CAAA;IACtE,MAAM,OAAO,GAAG,MAAM,CAAC,UAAU,CAAC,KAAK,EAAE,SAAS,IAAI,EAAE,CAAC,I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AAC3C,MAAM,CAAC,KAAK,UAAU,oBAAoB,CAAC,KAAsB;IAC/D,sBAAsB,CAAC,KAAK,CAAC,CAAA;IAC7B,OAAO,MAAM,OAAO,CAAC,GAAG,CAAC,KAAK,CAAC,GAAG,CAAC,KAAK,EAAE,IAAI,EAAE,EAAE;QAChD,MAAM,KAAK,GAAG,IAAI,UAAU,CAAC,MAAM,IAAI,CAAC,WAAW,EAAE,CAAC,CAAA;QACtD,IAAI,MAAM,GAAG,EAAE,CAAA;QACf,KAAK,IAAI,MAAM,GAAG,CAAC,EAAE,MAAM,GAAG,KAAK,CAAC,MAAM,EAAE,MAAM,IAAI,IAAI;YAAE,MAAM,IAAI,MAAM,CAAC,YAAY,CAAC,GAAG,KAAK,CAAC,QAAQ,CAAC,MAAM,EAAE,MAAM,GAAG,IAAI,CAAC,CAAC,CAAA;QACnI,OAAO,EAAE,IAAI,EAAE,IAAI,CAAC,IAAI,EAAE,SAAS,EAAE,IAAI,CAAC,IAAI,EAAE,IAAI,EAAE,IAAI,CAAC,MAAM,CAAC,EAAE,CAAA;IACtE,CAAC,CAAC,CAAC,CAAA;AACL,CAAC"}
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
import type { CodingNsSettings } from '../../shared/contracts/config.js';
|
|
2
|
+
import type { CodingNsSettingsOperation, CodingNsSettingsSnapshot, CodingNsSettingsStore } from '../../dsh-capabilities/settings-store.js';
|
|
3
|
+
import type { CodingNsClientServices } from './types.js';
|
|
4
|
+
type ConfigurationSnapshot = CodingNsSettingsSnapshot<CodingNsSettings> & {
|
|
5
|
+
readonly preparing: boolean;
|
|
6
|
+
};
|
|
7
|
+
/** 配置窗口的唯一草稿存储;普通写入只修改内存,正式运行仍读原服务。 */
|
|
8
|
+
export declare class AssistantConfigurationSession implements CodingNsSettingsStore<CodingNsSettings> {
|
|
9
|
+
private readonly original;
|
|
10
|
+
readonly services: CodingNsClientServices;
|
|
11
|
+
private snapshot;
|
|
12
|
+
private readonly listeners;
|
|
13
|
+
private readonly changes;
|
|
14
|
+
private readonly portraits;
|
|
15
|
+
private readonly portraitValues;
|
|
16
|
+
private readonly removedPortraits;
|
|
17
|
+
private readonly removals;
|
|
18
|
+
private readonly devices;
|
|
19
|
+
private releaseAdapter;
|
|
20
|
+
private preparationSupport;
|
|
21
|
+
private preparations;
|
|
22
|
+
private lifetime;
|
|
23
|
+
private localRevision;
|
|
24
|
+
constructor(original: CodingNsClientServices);
|
|
25
|
+
readonly getSnapshot: () => ConfigurationSnapshot;
|
|
26
|
+
readonly subscribe: (listener: () => void) => (() => void);
|
|
27
|
+
/** 权威快照变化仅更新未编辑字段,后台状态刷新不能抹掉模型等草稿。 */
|
|
28
|
+
sync(): void;
|
|
29
|
+
reset(): void;
|
|
30
|
+
mutate(operations: readonly CodingNsSettingsOperation[], expectedRevision?: number): Promise<boolean>;
|
|
31
|
+
set(field: string, value: unknown): Promise<boolean>;
|
|
32
|
+
unset(field: string): Promise<boolean>;
|
|
33
|
+
load(): Promise<void>;
|
|
34
|
+
reload(): Promise<void>;
|
|
35
|
+
/** 身份字段由生命周期接口校验,其余字段同一请求合并保存。 */
|
|
36
|
+
configurationPatch(): readonly CodingNsSettingsOperation[];
|
|
37
|
+
commitLocal(signal: AbortSignal): Promise<void>;
|
|
38
|
+
dispose(): void;
|
|
39
|
+
private requireWritable;
|
|
40
|
+
private publish;
|
|
41
|
+
private call;
|
|
42
|
+
private dispatch;
|
|
43
|
+
}
|
|
44
|
+
export {};
|
|
45
|
+
//# sourceMappingURL=assistant-configuration-session.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"assistant-configuration-session.d.ts","sourceRoot":"","sources":["../../../../../src/client/features/assistant-configuration-session.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,kCAAkC,CAAA;AACxE,OAAO,KAAK,EAAE,yBAAyB,EAAE,wBAAwB,EAAE,qBAAqB,EAAE,MAAM,0CAA0C,CAAA;AA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AAK,EAAE,OAAO,GAAG,OAAO,CAAC,OAAO,CAAC;IACpD,KAAK,CAAC,KAAK,EAAE,MAAM,GAAG,OAAO,CAAC,OAAO,CAAC;IACtC,IAAI,IAAI,OAAO,CAAC,IAAI,CAAC;IACrB,MAAM,IAAI,OAAO,CAAC,IAAI,CAAC;IAC7B,kCAAkC;IAClC,kBAAkB,IAAI,SAAS,yBAAyB,EAAE;IAIpD,WAAW,CAAC,MAAM,EAAE,WAAW,GAAG,OAAO,CAAC,IAAI,CAAC;IAUrD,OAAO,IAAI,IAAI;IACf,OAAO,CAAC,eAAe;IAGvB,OAAO,CAAC,OAAO;YAKD,IAAI;YASJ,QAAQ;CA4DvB"}
|
|
@@ -0,0 +1,252 @@
|
|
|
1
|
+
import { sameSettingsValue } from '../../dsh-capabilities/settings-store.js';
|
|
2
|
+
import { readAssistantTtsSettings, MOSS_BUILTIN_VOICES, validateAssistantTtsParameters } from '../../shared/assistant-tts.js';
|
|
3
|
+
import { getGlobalVoiceAdapter, registerGlobalVoiceAdapter } from '../global-voice-runtime-registry.js';
|
|
4
|
+
import { getAssistantAvatarRegistry, bindAssistantAvatarRegistry } from '../avatar/registry.js';
|
|
5
|
+
import { getAssistantAvatarManager, bindAssistantAvatarManager, AssistantAvatarManager } from '../avatar/manager.js';
|
|
6
|
+
import { AssistantAvatarPortraitService, assistantAvatarPortraitOverrideStore, bindAssistantAvatarPortraitService, getAssistantAvatarPortraitService } from '../avatar/portrait-service.js';
|
|
7
|
+
import { CODINGNS_RPC_CHANNEL } from '../../shared/contracts/transport.js';
|
|
8
|
+
import { hasAssistantAvatarConsent } from '../../shared/assistant-avatar-catalog.js';
|
|
9
|
+
import { findAssistantVoiceModel } from '../../shared/voice-models.js';
|
|
10
|
+
import { codingNsTranslator } from '../locale.js';
|
|
11
|
+
const resourceActions = new Set(['assistant/tts/setup', 'assistant/tts/import', 'assistant/voice/setup', 'assistant/voice/initialize', 'avatar/install', 'avatar/installCatalog']);
|
|
12
|
+
/** 配置窗口的唯一草稿存储;普通写入只修改内存,正式运行仍读原服务。 */
|
|
13
|
+
export class AssistantConfigurationSession {
|
|
14
|
+
original;
|
|
15
|
+
services;
|
|
16
|
+
snapshot;
|
|
17
|
+
listeners = new Set();
|
|
18
|
+
changes = new Map();
|
|
19
|
+
portraits = new Map();
|
|
20
|
+
portraitValues = new Map();
|
|
21
|
+
removedPortraits = new Set();
|
|
22
|
+
removals = new Map();
|
|
23
|
+
devices = new Map();
|
|
24
|
+
releaseAdapter;
|
|
25
|
+
preparationSupport;
|
|
26
|
+
preparations = 0;
|
|
27
|
+
lifetime = new AbortController();
|
|
28
|
+
localRevision = 0;
|
|
29
|
+
constructor(original) {
|
|
30
|
+
this.original = original;
|
|
31
|
+
this.snapshot = { ...original.settings.getSnapshot(), value: structuredClone(original.settings.getSnapshot().value), revision: this.localRevision, preparing: false };
|
|
32
|
+
this.services = { ...original, configurationDraft: true, settings: this, rpc: { call: (channel, endpoint, payload, signal) => this.call(channel, endpoint, payload, signal) } };
|
|
33
|
+
bindAssistantAvatarRegistry(this.services, getAssistantAvatarRegistry(original));
|
|
34
|
+
const overrides = {
|
|
35
|
+
read: async (key, signal) => this.portraitValues.get(key) ?? await assistantAvatarPortraitOverrideStore.read(key, signal),
|
|
36
|
+
write: async (key, id, _surface, preview, signal) => {
|
|
37
|
+
signal?.throwIfAborted();
|
|
38
|
+
const model = getAssistantAvatarManager(this.services).list().find((item) => item.id === id);
|
|
39
|
+
if (model === undefined)
|
|
40
|
+
return false;
|
|
41
|
+
this.portraitValues.set(key, preview);
|
|
42
|
+
this.portraits.set(key, { model, renderer: getAssistantAvatarRegistry(this.services).get(model.surfaces?.dialog?.renderer ?? model.renderer), preview });
|
|
43
|
+
return true;
|
|
44
|
+
},
|
|
45
|
+
removeModel: async (id) => { this.removedPortraits.add(id); for (const [key, item] of this.portraits)
|
|
46
|
+
if (item.model.id === id) {
|
|
47
|
+
this.portraits.delete(key);
|
|
48
|
+
this.portraitValues.delete(key);
|
|
49
|
+
} },
|
|
50
|
+
};
|
|
51
|
+
bindAssistantAvatarPortraitService(this.services, new AssistantAvatarPortraitService(undefined, undefined, undefined, undefined, undefined, overrides));
|
|
52
|
+
bindAssistantAvatarManager(this.services, new AssistantAvatarManager(this, getAssistantAvatarManager(original).adapters, undefined, undefined, this.services.rpc, (id) => { this.removedPortraits.add(id); }));
|
|
53
|
+
const adapter = getGlobalVoiceAdapter(original);
|
|
54
|
+
if (adapter !== undefined)
|
|
55
|
+
this.releaseAdapter = registerGlobalVoiceAdapter(this.services, new Proxy(adapter, { get: (target, key) => {
|
|
56
|
+
if (key === 'selectInputDevice' || key === 'selectOutputDevice')
|
|
57
|
+
return async (id) => { this.requireWritable(); this.devices.set(key === 'selectInputDevice' ? 'input' : 'output', id); };
|
|
58
|
+
if (key === 'inputDeviceId' || key === 'outputDeviceId')
|
|
59
|
+
return this.devices.get(key === 'inputDeviceId' ? 'input' : 'output') ?? Reflect.get(target, key);
|
|
60
|
+
const value = Reflect.get(target, key);
|
|
61
|
+
return typeof value === 'function' ? value.bind(target) : value;
|
|
62
|
+
} }));
|
|
63
|
+
}
|
|
64
|
+
getSnapshot = () => this.snapshot;
|
|
65
|
+
subscribe = (listener) => { this.listeners.add(listener); return () => this.listeners.delete(listener); };
|
|
66
|
+
/** 权威快照变化仅更新未编辑字段,后台状态刷新不能抹掉模型等草稿。 */
|
|
67
|
+
sync() {
|
|
68
|
+
const fresh = this.original.settings.getSnapshot();
|
|
69
|
+
let value = structuredClone(fresh.value);
|
|
70
|
+
if (value !== undefined)
|
|
71
|
+
for (const operation of this.changes.values())
|
|
72
|
+
value = apply(value, operation);
|
|
73
|
+
this.publish({ ...fresh, value, revision: this.localRevision });
|
|
74
|
+
}
|
|
75
|
+
reset() {
|
|
76
|
+
this.lifetime.abort();
|
|
77
|
+
this.lifetime = new AbortController();
|
|
78
|
+
this.preparationSupport = undefined;
|
|
79
|
+
this.changes.clear();
|
|
80
|
+
this.portraits.clear();
|
|
81
|
+
this.portraitValues.clear();
|
|
82
|
+
this.removedPortraits.clear();
|
|
83
|
+
this.removals.clear();
|
|
84
|
+
this.devices.clear();
|
|
85
|
+
getAssistantAvatarPortraitService(this.services).dispose();
|
|
86
|
+
this.localRevision++;
|
|
87
|
+
this.sync();
|
|
88
|
+
}
|
|
89
|
+
async mutate(operations, expectedRevision) {
|
|
90
|
+
this.requireWritable();
|
|
91
|
+
if (expectedRevision !== undefined && expectedRevision !== this.localRevision)
|
|
92
|
+
throw new Error('settings namespace "assistant-draft" changed since it was read (expected revision)');
|
|
93
|
+
for (const operation of operations) {
|
|
94
|
+
if (operation.path[0] !== 'assistant' || operation.path.length < 2 || operation.path.length > 4
|
|
95
|
+
|| operation.path.some((key) => !/^[A-Za-z][A-Za-z0-9_-]*$/u.test(key) || ['constructor', 'prototype'].includes(key)))
|
|
96
|
+
throw new Error('配置草稿只允许修改助理字段');
|
|
97
|
+
}
|
|
98
|
+
let value = this.snapshot.value;
|
|
99
|
+
for (const operation of operations) {
|
|
100
|
+
value = apply(value, operation);
|
|
101
|
+
const path = operation.path.join('.');
|
|
102
|
+
// 父字段替换覆盖更早的子字段;重新编辑的字段排到末尾,刷新时按真实顺序重放。
|
|
103
|
+
for (const key of this.changes.keys())
|
|
104
|
+
if (key === path || key.startsWith(path + '.'))
|
|
105
|
+
this.changes.delete(key);
|
|
106
|
+
this.changes.set(path, structuredClone(operation));
|
|
107
|
+
}
|
|
108
|
+
this.localRevision++;
|
|
109
|
+
this.publish({ ...this.snapshot, value, revision: this.localRevision });
|
|
110
|
+
return true;
|
|
111
|
+
}
|
|
112
|
+
async set(field, value) { return this.mutate([{ op: 'set', path: field.split('.'), value }]); }
|
|
113
|
+
async unset(field) { return this.mutate([{ op: 'unset', path: field.split('.') }]); }
|
|
114
|
+
async load() { this.sync(); }
|
|
115
|
+
async reload() { await this.original.settings.reload?.(); this.sync(); }
|
|
116
|
+
/** 身份字段由生命周期接口校验,其余字段同一请求合并保存。 */
|
|
117
|
+
configurationPatch() {
|
|
118
|
+
return [...this.changes.values()].filter((operation) => ['appearance', 'voice', 'tts', 'prompts'].includes(operation.path[1]))
|
|
119
|
+
.map((operation) => ({ ...operation, path: operation.path.slice(1) }));
|
|
120
|
+
}
|
|
121
|
+
async commitLocal(signal) {
|
|
122
|
+
for (const item of this.portraits.values())
|
|
123
|
+
await getAssistantAvatarPortraitService(this.original).setPortrait(item.model, item.renderer, item.preview, signal);
|
|
124
|
+
const adapter = getGlobalVoiceAdapter(this.original);
|
|
125
|
+
for (const [direction, id] of this.devices) {
|
|
126
|
+
signal.throwIfAborted();
|
|
127
|
+
await (direction === 'input' ? adapter?.selectInputDevice(id) : adapter?.selectOutputDevice(id));
|
|
128
|
+
}
|
|
129
|
+
for (const id of this.removedPortraits)
|
|
130
|
+
getAssistantAvatarPortraitService(this.original).removeModel(id);
|
|
131
|
+
for (const { endpoint, payload } of this.removals.values()) {
|
|
132
|
+
const result = await this.original.rpc.call(CODINGNS_RPC_CHANNEL, endpoint, payload, signal);
|
|
133
|
+
if (!result.ok)
|
|
134
|
+
throw new Error(result.error.message);
|
|
135
|
+
}
|
|
136
|
+
}
|
|
137
|
+
dispose() { this.lifetime.abort(); this.releaseAdapter?.(); getAssistantAvatarPortraitService(this.services).dispose(); this.listeners.clear(); }
|
|
138
|
+
requireWritable() {
|
|
139
|
+
if (!this.original.settings.getSnapshot().writable || !this.snapshot.writable || this.snapshot.status !== 'ready' || this.snapshot.value === undefined)
|
|
140
|
+
throw new Error('当前助理配置不可写');
|
|
141
|
+
}
|
|
142
|
+
publish(next) {
|
|
143
|
+
const snapshot = { ...next, preparing: this.preparations > 0 };
|
|
144
|
+
if (sameSettingsValue(this.snapshot, snapshot))
|
|
145
|
+
return;
|
|
146
|
+
this.snapshot = snapshot;
|
|
147
|
+
for (const listener of this.listeners)
|
|
148
|
+
listener();
|
|
149
|
+
}
|
|
150
|
+
async call(channel, endpoint, payload, signal) {
|
|
151
|
+
// 关闭后的租约释放仍必须发送,不能被草稿取消信号挡住。
|
|
152
|
+
if (endpoint === 'avatar/releasePreview')
|
|
153
|
+
return this.original.rpc.call(channel, endpoint, payload, signal);
|
|
154
|
+
const ownedSignal = AbortSignal.any([this.lifetime.signal, ...(signal === undefined ? [] : [signal])]);
|
|
155
|
+
const preparing = resourceActions.has(endpoint);
|
|
156
|
+
if (preparing) {
|
|
157
|
+
this.preparations++;
|
|
158
|
+
this.publish(this.snapshot);
|
|
159
|
+
}
|
|
160
|
+
try {
|
|
161
|
+
return await this.dispatch(channel, endpoint, payload, ownedSignal);
|
|
162
|
+
}
|
|
163
|
+
finally {
|
|
164
|
+
if (preparing) {
|
|
165
|
+
this.preparations--;
|
|
166
|
+
this.publish(this.snapshot);
|
|
167
|
+
}
|
|
168
|
+
}
|
|
169
|
+
}
|
|
170
|
+
async dispatch(channel, endpoint, payload, signal) {
|
|
171
|
+
signal?.throwIfAborted();
|
|
172
|
+
const value = payload;
|
|
173
|
+
// 调试窗口的模型选择只用于显式测试,不提前改变正式索引的模型。
|
|
174
|
+
if (endpoint === 'assistant/index/configure')
|
|
175
|
+
return { ok: true, value: { configured: true } };
|
|
176
|
+
// 第三方目录的权限记录也属于配置,首次开启先统一保存再读取目录。
|
|
177
|
+
if (endpoint === 'avatar/catalog' && !hasAssistantAvatarConsent(this.original.settings.getSnapshot().value?.assistant.appearance?.thirdPartyConsent))
|
|
178
|
+
return { ok: true, value: [] };
|
|
179
|
+
if (endpoint === 'avatar/remove') {
|
|
180
|
+
this.requireWritable();
|
|
181
|
+
this.removals.set(endpoint + ':' + String(value?.id), { endpoint, payload });
|
|
182
|
+
return { ok: true, value: undefined };
|
|
183
|
+
}
|
|
184
|
+
if (['assistant/tts/select', 'assistant/tts/configure', 'assistant/tts/remove'].includes(endpoint)) {
|
|
185
|
+
const tts = readAssistantTtsSettings(this.snapshot.value.assistant.tts);
|
|
186
|
+
const next = endpoint.endsWith('/configure') ? { ...tts, parameters: validateAssistantTtsParameters(value?.parameters, tts.parameters) }
|
|
187
|
+
: endpoint.endsWith('/remove') ? { ...tts, voices: tts.voices.filter((voice) => voice.id !== value?.id), selectedId: tts.selectedId === value?.id ? 'moss:Junhao' : tts.selectedId }
|
|
188
|
+
: { ...tts, selectedId: value?.id ?? tts.selectedId, backend: value?.backend === 'browser' ? 'browser' : 'moss-onnx' };
|
|
189
|
+
await this.set('assistant.tts', next);
|
|
190
|
+
return this.call(channel, 'assistant/tts/catalog', {}, signal);
|
|
191
|
+
}
|
|
192
|
+
const preparing = ['assistant/tts/setup', 'assistant/tts/import', 'assistant/voice/setup', 'assistant/voice/initialize'].includes(endpoint);
|
|
193
|
+
if (preparing) {
|
|
194
|
+
this.requireWritable();
|
|
195
|
+
// 旧 Host 可能忽略 prepareOnly,先确认能力,不能静默退回立即启用。
|
|
196
|
+
this.preparationSupport ??= this.original.rpc.call(channel, 'assistant/configuration/capabilities', {}, signal)
|
|
197
|
+
.then((response) => response.ok && response.value?.prepareOnly === true);
|
|
198
|
+
if (!await this.preparationSupport) {
|
|
199
|
+
const t = codingNsTranslator(this.original.locale);
|
|
200
|
+
return { ok: false, error: { code: 'UNSUPPORTED', message: t('awb.preparationUnsupported') } };
|
|
201
|
+
}
|
|
202
|
+
signal?.throwIfAborted();
|
|
203
|
+
}
|
|
204
|
+
const preparedModelId = endpoint === 'assistant/voice/initialize' ? findAssistantVoiceModel(this.snapshot.value.assistant.voice.modelId ?? '')?.id : undefined;
|
|
205
|
+
const result = await this.original.rpc.call(channel, endpoint, preparing ? { ...value, ...(preparedModelId === undefined ? {} : { modelId: preparedModelId }), prepareOnly: true } : payload, signal);
|
|
206
|
+
signal.throwIfAborted();
|
|
207
|
+
if (!result.ok)
|
|
208
|
+
return result;
|
|
209
|
+
if (preparing) {
|
|
210
|
+
const prepared = result.value;
|
|
211
|
+
if (endpoint === 'assistant/voice/setup' && prepared.voice !== undefined)
|
|
212
|
+
await this.set('assistant.voice', prepared.voice);
|
|
213
|
+
if (endpoint === 'assistant/voice/initialize') {
|
|
214
|
+
if (prepared.voice !== undefined)
|
|
215
|
+
await this.set('assistant.voice', prepared.voice);
|
|
216
|
+
await this.set('assistant.tts', { ...readAssistantTtsSettings(this.snapshot.value.assistant.tts), backend: 'moss-onnx' });
|
|
217
|
+
}
|
|
218
|
+
if (endpoint === 'assistant/tts/setup')
|
|
219
|
+
await this.set('assistant.tts', { ...readAssistantTtsSettings(this.snapshot.value.assistant.tts), backend: 'moss-onnx' });
|
|
220
|
+
if (endpoint === 'assistant/tts/import') {
|
|
221
|
+
const current = readAssistantTtsSettings(this.snapshot.value.assistant.tts), incoming = prepared.settings;
|
|
222
|
+
const voices = new Map([...current.voices, ...incoming.voices].map((voice) => [voice.id, voice]));
|
|
223
|
+
await this.set('assistant.tts', { ...current, ...incoming, voices: [...voices.values()] });
|
|
224
|
+
}
|
|
225
|
+
}
|
|
226
|
+
if (endpoint.startsWith('assistant/tts/') && result.value?.settings !== undefined) {
|
|
227
|
+
const raw = this.snapshot.value.assistant.tts;
|
|
228
|
+
const settings = { ...readAssistantTtsSettings(raw), ...(raw?.parameters === undefined ? {} : { parameters: raw.parameters }) };
|
|
229
|
+
return { ok: true, value: { ...result.value, settings, voices: [...MOSS_BUILTIN_VOICES, ...settings.voices] } };
|
|
230
|
+
}
|
|
231
|
+
if (endpoint === 'assistant/voice/initialization' || endpoint === 'assistant/voice/initialize') {
|
|
232
|
+
const snapshot = result.value, settings = readAssistantTtsSettings(this.snapshot.value.assistant.tts), voice = this.snapshot.value.assistant.voice;
|
|
233
|
+
const model = findAssistantVoiceModel(voice.modelId ?? '');
|
|
234
|
+
return { ok: true, value: { ...snapshot, modelId: voice.modelId || snapshot.modelId, modelLabel: model?.label ?? snapshot.modelLabel,
|
|
235
|
+
ready: voice.initialized && snapshot.tts.status.ready && settings.backend === 'moss-onnx',
|
|
236
|
+
tts: { ...snapshot.tts, settings, voices: [...MOSS_BUILTIN_VOICES, ...settings.voices] } } };
|
|
237
|
+
}
|
|
238
|
+
return result;
|
|
239
|
+
}
|
|
240
|
+
}
|
|
241
|
+
function apply(value, operation) {
|
|
242
|
+
const next = structuredClone(value), path = operation.path, root = next;
|
|
243
|
+
let target = root;
|
|
244
|
+
for (const key of path.slice(0, -1))
|
|
245
|
+
target = target[key] ??= {};
|
|
246
|
+
if (operation.op === 'unset')
|
|
247
|
+
delete target[path.at(-1)];
|
|
248
|
+
else
|
|
249
|
+
target[path.at(-1)] = structuredClone(operation.value);
|
|
250
|
+
return next;
|
|
251
|
+
}
|
|
252
|
+
//# sourceMappingURL=assistant-configuration-session.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"assistant-configuration-session.js","sourceRoot":"","sources":["../../../../../src/client/features/assistant-configuration-session.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,iBAAiB,EAAE,MAAM,0CAA0C,CAAA;AAC5E,OAAO,EAAE,wBAAwB,EAAE,mBAAmB,EAAE,8BAA8B,EAAE,MAAM,+BAA+B,CAAA;AAG7H,OAAO,EAAE,qBAAqB,EAAE,0BAA0B,EAAE,MAAM,qCAAqC,CAAA;AACvG,OAAO,EAAE,0BAA0B,EAAE,2BAA2B,EAAE,MAAM,uBAAuB,CAAA;AAC/F,OAAO,EAAE,yBAAyB,EAAE,0BAA0B,EAAE,sBAAsB,EAAE,MAAM,sBAAsB,CAAA;AACpH,OAAO,EAAE,8BAA8B,EAAE,oCAAoC,EAAE,kCAAkC,EAAE,iCAAiC,EAAE,MAAM,+BAA+B,CAAA;AAI3L,OAAO,EAAE,oBAAoB,EAAE,MAAM,qCAAqC,CAAA;AAC1E,OAAO,EAAE,yBAAyB,EAAE,MAAM,0CAA0C,CAAA;AACpF,OAAO,EAAE,uBAAuB,EAAE,MAAM,8BAA8B,CAAA;AACtE,OAAO,EAAE,kBAAkB,EAAE,MAAM,cAAc,CAAA;AAGjD,MAAM,eAAe,GAAG,IAAI,GAAG,CAAC,CAAC,qBAAqB,EAAE,sBAAsB,EAAE,uBAAuB,EAAE,4BAA4B,EAAE,g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E,EAAE,EAAE,CAAA;QAChG,CAAC;QACD,OAAO,MAAM,CAAA;IACf,CAAC;CACF;AACD,SAAS,KAAK,CAAC,KAAuB,EAAE,SAAoC;IAC1E,MAAM,IAAI,GAAG,eAAe,CAAC,KAAK,CAAC,EAAE,IAAI,GAAG,SAAS,CAAC,IAAI,EAAE,IAAI,GAAG,IAAsC,CAAA;IACzG,IAAI,MAAM,GAAG,IAAI,CAAA;IACjB,KAAK,MAAM,GAAG,IAAI,IAAI,CAAC,KAAK,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC;QAAE,MAAM,GAAG,MAAM,CAAC,GAAG,CAAC,KAAK,EAAE,CAAA;IAChE,IAAI,SAAS,CAAC,EAAE,KAAK,OAAO;QAAE,OAAO,MAAM,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC,CAAC,CAAE,CAAC,CAAA;;QACpD,MAAM,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC,CAAC,CAAE,CAAC,GAAG,eAAe,CAAC,SAAS,CAAC,KAAK,CAAC,CAAA;IAC5D,OAAO,IAAI,CAAA;AACb,CAAC"}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import type { ReactElement, ReactNode } from 'react';
|
|
2
|
+
import type { CodingNsTranslator } from '../locale.js';
|
|
3
|
+
declare const tabs: readonly [{
|
|
4
|
+
readonly id: "basic";
|
|
5
|
+
readonly label: "awb.tab.basic";
|
|
6
|
+
}, {
|
|
7
|
+
readonly id: "appearance";
|
|
8
|
+
readonly label: "awb.tab.appearance";
|
|
9
|
+
}, {
|
|
10
|
+
readonly id: "voice";
|
|
11
|
+
readonly label: "awb.tab.voice";
|
|
12
|
+
}, {
|
|
13
|
+
readonly id: "more";
|
|
14
|
+
readonly label: "awb.more";
|
|
15
|
+
}];
|
|
16
|
+
export type AssistantConfigurationTab = typeof tabs[number]['id'];
|
|
17
|
+
/** 延迟挂载尚未访问的页,访问后保留实例,避免切换丢失资源表单或中断安装。 */
|
|
18
|
+
export declare function AssistantConfigurationTabs({ active, visited, panels, preview, t, onChange }: {
|
|
19
|
+
readonly active: AssistantConfigurationTab;
|
|
20
|
+
readonly visited: readonly AssistantConfigurationTab[];
|
|
21
|
+
readonly panels: Readonly<Record<AssistantConfigurationTab, ReactNode>>;
|
|
22
|
+
readonly preview: ReactNode;
|
|
23
|
+
readonly t: CodingNsTranslator;
|
|
24
|
+
readonly onChange: (tab: AssistantConfigurationTab) => void;
|
|
25
|
+
}): ReactElement;
|
|
26
|
+
/** 标签可用方向键、Home 和 End 切换,只有当前标签进入顺序焦点。 */
|
|
27
|
+
export declare function AssistantConfigurationTabBar({ id, active, t, onChange }: {
|
|
28
|
+
readonly id: string;
|
|
29
|
+
readonly active: AssistantConfigurationTab;
|
|
30
|
+
readonly t: CodingNsTranslator;
|
|
31
|
+
readonly onChange: (tab: AssistantConfigurationTab) => void;
|
|
32
|
+
}): ReactElement;
|
|
33
|
+
export {};
|
|
34
|
+
//# sourceMappingURL=assistant-configuration-tabs.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"assistant-configuration-tabs.d.ts","sourceRoot":"","sources":["../../../../../src/client/features/assistant-configuration-tabs.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAiB,YAAY,EAAE,SAAS,EAAE,MAAM,OAAO,CAAA;AACnE,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,cAAc,CAAA;AAGtD,QAAA,MAAM,IAAI;;;;;;;;;;;;EAGA,CAAA;AACV,MAAM,MAAM,yBAAyB,GAAG,OAAO,IAAI,CAAC,MAAM,CAAC,CAAC,IAAI,CAAC,CAAA;AAEjE,0CAA0C;AAC1C,wBAAgB,0BAA0B,CAAC,EAAE,MAAM,EAAE,OAAO,EAAE,MAAM,EAAE,OAAO,EAAE,CAAC,EAAE,QAAQ,EAAE,EAAE;IAC5F,QAAQ,CAAC,MAAM,EAAE,yBAAyB,CAAA;IAC1C,QAAQ,CAAC,OAAO,EAAE,SAAS,yBAAyB,EAAE,CAAA;IACtD,QAAQ,CAAC,MAAM,EAAE,QAAQ,CAAC,MAAM,CAAC,yBAAyB,EAAE,SAAS,CAAC,CAAC,CAAA;IACvE,QAAQ,CAAC,OAAO,EAAE,SAAS,CAAA;IAC3B,QAAQ,CAAC,CAAC,EAAE,kBAAkB,CAAA;IAC9B,QAAQ,CAAC,QAAQ,EAAE,CAAC,GAAG,EAAE,yBAAyB,KAAK,IAAI,CAAA;CAC5D,GAAG,YAAY,CAcf;AAED,0CAA0C;AAC1C,wBAAgB,4BAA4B,CAAC,EAAE,EAAE,EAAE,MAAM,EAAE,CAAC,EAAE,QAAQ,EAAE,EAAE;IACxE,QAAQ,CAAC,EAAE,EAAE,MAAM,CAAC;IAAC,QAAQ,CAAC,MAAM,EAAE,yBAAyB,CAAC;IAAC,QAAQ,CAAC,CAAC,EAAE,kBAAkB,CAAA;IAC/F,QAAQ,CAAC,QAAQ,EAAE,CAAC,GAAG,EAAE,yBAAyB,KAAK,IAAI,CAAA;CAC5D,GAAG,YAAY,CAwBf"}
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
import { createElement, useId } from 'react';
|
|
2
|
+
import { dshThemeColor } from '../theme.js';
|
|
3
|
+
const tabs = [
|
|
4
|
+
{ id: 'basic', label: 'awb.tab.basic' }, { id: 'appearance', label: 'awb.tab.appearance' },
|
|
5
|
+
{ id: 'voice', label: 'awb.tab.voice' }, { id: 'more', label: 'awb.more' },
|
|
6
|
+
];
|
|
7
|
+
/** 延迟挂载尚未访问的页,访问后保留实例,避免切换丢失资源表单或中断安装。 */
|
|
8
|
+
export function AssistantConfigurationTabs({ active, visited, panels, preview, t, onChange }) {
|
|
9
|
+
const id = useId();
|
|
10
|
+
return createElement('div', { 'data-codingns-configuration-tabs': true, style: { display: 'grid', gap: 11, minWidth: 0 } }, createElement(AssistantConfigurationTabBar, { id, active, t, onChange }), createElement('div', { style: { display: 'flex', flexWrap: 'wrap', alignItems: 'stretch', gap: 22, minWidth: 0 } }, createElement('div', { style: { flex: '1 1 330px', minWidth: 0 } }, ...tabs.map((tab) => createElement('section', {
|
|
11
|
+
key: tab.id, id: `${id}-panel-${tab.id}`, role: 'tabpanel', 'aria-labelledby': `${id}-tab-${tab.id}`,
|
|
12
|
+
hidden: tab.id !== active, tabIndex: 0, 'data-codingns-configuration-page': tab.id,
|
|
13
|
+
style: { display: tab.id === active ? 'grid' : 'none', gap: 11, minWidth: 0 },
|
|
14
|
+
}, tab.id === active || visited.includes(tab.id) ? panels[tab.id] : null))),
|
|
15
|
+
// 更多设置使用全宽;预览实例保留,来回切换不重新加载所选形象。
|
|
16
|
+
createElement('div', { hidden: active === 'more', 'data-codingns-configuration-preview': true,
|
|
17
|
+
style: { display: active === 'more' ? 'none' : 'flex', flex: '1 1 290px', minWidth: 0 } }, preview)));
|
|
18
|
+
}
|
|
19
|
+
/** 标签可用方向键、Home 和 End 切换,只有当前标签进入顺序焦点。 */
|
|
20
|
+
export function AssistantConfigurationTabBar({ id, active, t, onChange }) {
|
|
21
|
+
const navigate = (event, index) => {
|
|
22
|
+
let next;
|
|
23
|
+
if (event.key === 'ArrowRight')
|
|
24
|
+
next = (index + 1) % tabs.length;
|
|
25
|
+
else if (event.key === 'ArrowLeft')
|
|
26
|
+
next = (index + tabs.length - 1) % tabs.length;
|
|
27
|
+
else if (event.key === 'Home')
|
|
28
|
+
next = 0;
|
|
29
|
+
else if (event.key === 'End')
|
|
30
|
+
next = tabs.length - 1;
|
|
31
|
+
else
|
|
32
|
+
return;
|
|
33
|
+
event.preventDefault();
|
|
34
|
+
onChange(tabs[next].id);
|
|
35
|
+
event.currentTarget.parentElement?.querySelectorAll('[role="tab"]')[next]?.focus();
|
|
36
|
+
};
|
|
37
|
+
return createElement('div', { role: 'tablist', 'aria-label': t('awb.configure'),
|
|
38
|
+
style: { position: 'sticky', top: 0, zIndex: 2, display: 'flex', gap: 4, padding: 4, borderRadius: 12,
|
|
39
|
+
background: dshThemeColor.cardBackground, border: `1px solid ${dshThemeColor.border}`, overflowX: 'auto', minWidth: 0 } }, ...tabs.map((tab, index) => createElement('button', { key: tab.id, type: 'button', role: 'tab', id: `${id}-tab-${tab.id}`,
|
|
40
|
+
'aria-controls': `${id}-panel-${tab.id}`, 'aria-selected': active === tab.id, tabIndex: active === tab.id ? 0 : -1,
|
|
41
|
+
onClick: () => onChange(tab.id), onKeyDown: (event) => navigate(event, index),
|
|
42
|
+
style: { flex: '1 0 auto', minHeight: 36, border: 0, borderRadius: 8, padding: '7px 12px', whiteSpace: 'nowrap', cursor: 'pointer',
|
|
43
|
+
font: 'inherit', fontSize: 13, fontWeight: active === tab.id ? 600 : 400,
|
|
44
|
+
color: active === tab.id ? dshThemeColor.labelPrimary : dshThemeColor.labelSecondary,
|
|
45
|
+
background: active === tab.id ? dshThemeColor.pageBackground : 'transparent',
|
|
46
|
+
boxShadow: active === tab.id ? dshThemeColor.subtleShadow : 'none' }, }, t(tab.label))));
|
|
47
|
+
}
|
|
48
|
+
//# sourceMappingURL=assistant-configuration-tabs.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"assistant-configuration-tabs.js","sourceRoot":"","sources":["../../../../../src/client/features/assistant-configuration-tabs.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,KAAK,EAAE,MAAM,OAAO,CAAA;AAG5C,OAAO,EAAE,aAAa,EAAE,MAAM,aAAa,CAAA;AAE3C,MAAM,IAAI,GAAG;IACX,EAAE,EAAE,EAAE,OAAO,EAAE,KAAK,EAAE,eAAe,EAAE,EAAE,EAAE,EAAE,EAAE,YAAY,EAAE,KAAK,EAAE,oBAAoB,EAAE;IAC1F,EAAE,EAAE,EAAE,OAAO,EAAE,KAAK,EAAE,eAAe,EAAE,EAAE,EAAE,EAAE,EAAE,MAAM,EAAE,KAAK,EAAE,UAAU,EAAE;CAClE,CAAA;AAGV,0CAA0C;AAC1C,MAAM,UAAU,0BAA0B,CAAC,EAAE,MAAM,EAAE,OAAO,EAAE,M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E,SAAS,EAAE,EAAE,EAAE,MAAM,EAAE,CAAC,EAAE,YAAY,EAAE,CAAC,EAAE,OAAO,EAAE,UAAU,EAAE,UAAU,EAAE,QAAQ,EAAE,MAAM,EAAE,SAAS;YAChI,IAAI,EAAE,SAAS,EAAE,QAAQ,EAAE,EAAE,EAAE,UAAU,EAAE,MAAM,KAAK,GAAG,CAAC,EAAE,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,GAAG;YACxE,KAAK,EAAE,MAAM,KAAK,GAAG,CAAC,EAAE,CAAC,CAAC,CAAC,aAAa,CAAC,YAAY,CAAC,CAAC,CAAC,aAAa,CAAC,cAAc;YACpF,UAAU,EAAE,MAAM,KAAK,GAAG,CAAC,EAAE,CAAC,CAAC,CAAC,aAAa,CAAC,cAAc,CAAC,CAAC,CAAC,aAAa;YAC5E,SAAS,EAAE,MAAM,KAAK,GAAG,CAAC,EAAE,CAAC,CAAC,CAAC,aAAa,CAAC,YAAY,CAAC,CAAC,CAAC,MAAM,EAAE,GACvE,EAAE,CAAC,CAAC,GAAG,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,CAAA;AACtB,CAAC"}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import type { ReactElement } from 'react';
|
|
2
|
+
import type { AssistantConversationMessage, AssistantToolCall } from '../../shared/contracts/assistant.js';
|
|
3
|
+
import type { AssistantAvatarModel } from '../../shared/assistant-avatar.js';
|
|
4
|
+
import type { CodingNsTranslator } from '../locale.js';
|
|
5
|
+
import type { CodingNsClientServices } from './types.js';
|
|
6
|
+
/** 聊天和语音详情共用消息样式与静态头像,方向只由所在视图指定。 */
|
|
7
|
+
export declare function AssistantConversationMessageView({ message, name, t, services, model, side, streaming }: {
|
|
8
|
+
readonly message: Pick<AssistantConversationMessage, 'role' | 'text' | 'attachments' | 'interrupted' | 'toolCalls'>;
|
|
9
|
+
readonly name: string;
|
|
10
|
+
readonly t: CodingNsTranslator;
|
|
11
|
+
readonly services?: CodingNsClientServices | undefined;
|
|
12
|
+
readonly model?: AssistantAvatarModel | undefined;
|
|
13
|
+
readonly side?: 'left' | 'right';
|
|
14
|
+
readonly streaming?: boolean;
|
|
15
|
+
}): ReactElement;
|
|
16
|
+
/** 文字聊天、实时字幕与通话历史共用同一时间线,不额外生成工具汇总区。 */
|
|
17
|
+
export declare function AssistantMessageContentView({ text, calls, t }: {
|
|
18
|
+
readonly text: string;
|
|
19
|
+
readonly calls?: readonly AssistantToolCall[] | undefined;
|
|
20
|
+
readonly t: CodingNsTranslator;
|
|
21
|
+
}): ReactElement;
|
|
22
|
+
/** 工具信息单独展示,不拼入消息正文,字幕与语音合成都只使用原始 text。 */
|
|
23
|
+
export declare function AssistantToolCallsView({ calls, t }: {
|
|
24
|
+
readonly calls?: readonly AssistantToolCall[] | undefined;
|
|
25
|
+
readonly t: CodingNsTranslator;
|
|
26
|
+
}): ReactElement | null;
|
|
27
|
+
//# sourceMappingURL=assistant-conversation-message.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"assistant-conversation-message.d.ts","sourceRoot":"","sources":["../../../../../src/client/features/assistant-conversation-message.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,OAAO,CAAA;AACzC,OAAO,KAAK,EAAE,4BAA4B,EAAE,iBAAiB,EAAE,MAAM,qCAAqC,CAAA;AAC1G,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,kCAAkC,CAAA;AAE5E,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,cAAc,CAAA;AAEtD,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,YAAY,CAAA;AAIxD,qCAAqC;AACrC,wBAAgB,gCAAgC,CAAC,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC,EAAE,QAAQ,EAAE,KAAK,EAAE,IAAI,EAAE,SAAiB,EAAE,EAAE;IAC/G,QAAQ,CAAC,OAAO,EAAE,IAAI,CAAC,4BAA4B,EAAE,MAAM,GAAG,MAAM,GAAG,aAAa,GAAG,aAAa,GAAG,WAAW,CAAC,CAAA;IACnH,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IAAC,QAAQ,CAAC,CAAC,EAAE,kBAAkB,CAAA;IACrD,QAAQ,CAAC,QAAQ,CAAC,EAAE,sBAAsB,GAAG,SAAS,CAAC;IAAC,QAAQ,CAAC,KAAK,CAAC,EAAE,oBAAoB,GAAG,SAAS,CAAA;IACzG,QAAQ,CAAC,IAAI,CAAC,EAAE,MAAM,GAAG,OAAO,CAAC;IAAC,QAAQ,CAAC,SAAS,CAAC,EAAE,OAAO,CAAA;CAC/D,GAAG,YAAY,CAcf;AAED,wCAAwC;AACxC,wBAAgB,2BAA2B,CAAC,EAAE,IAAI,EAAE,KAAK,EAAE,CAAC,EAAE,EAAE;IAC9D,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IAAC,QAAQ,CAAC,KAAK,CAAC,EAAE,SAAS,iBAAiB,EAAE,GAAG,SAAS,CAAC;IAAC,QAAQ,CAAC,CAAC,EAAE,kBAAkB,CAAA;CACjH,GAAG,YAAY,CAKf;AAED,2CAA2C;AAC3C,wBAAgB,sBAAsB,CAAC,EAAE,KAAK,EAAE,CAAC,EAAE,EAAE;IAAE,QAAQ,CAAC,KAAK,CAAC,EAAE,SAAS,iBAAiB,EAAE,GAAG,SAAS,CAAC;IAAC,QAAQ,CAAC,CAAC,EAAE,kBAAkB,CAAA;CAAE,GAAG,YAAY,GAAG,IAAI,CAKvK"}
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
import { createElement, Fragment } from 'react';
|
|
2
|
+
import { AssistantAvatarPortrait } from '../avatar/portrait.js';
|
|
3
|
+
import { dshThemeColor } from '../theme.js';
|
|
4
|
+
import { assistantMessageTimeline } from '../../shared/assistant-message-timeline.js';
|
|
5
|
+
import { AssistantRecordChevron, AssistantRecordStyle } from './assistant-record-style.js';
|
|
6
|
+
/** 聊天和语音详情共用消息样式与静态头像,方向只由所在视图指定。 */
|
|
7
|
+
export function AssistantConversationMessageView({ message, name, t, services, model, side, streaming = false }) {
|
|
8
|
+
return createElement('article', { 'data-codingns-assistant-message': message.role,
|
|
9
|
+
...(side === undefined ? {} : { 'data-codingns-message-side': side }), ...(streaming ? { role: 'status' } : {}),
|
|
10
|
+
style: { padding: '11px 14px', borderRadius: 10, background: message.role === 'user' ? dshThemeColor.surfaceSubtle : 'transparent',
|
|
11
|
+
justifySelf: side === 'left' ? 'start' : side === 'right' || message.role === 'user' ? 'end' : 'stretch',
|
|
12
|
+
maxWidth: side === undefined ? '100%' : '88%', minWidth: 0, boxSizing: 'border-box', fontSize: 14, lineHeight: 1.65, whiteSpace: 'pre-wrap', overflowWrap: 'anywhere' } }, createElement('div', { style: { display: 'flex', alignItems: 'center', justifyContent: side === 'right' ? 'flex-end' : 'flex-start', gap: 7, marginBottom: 5 } }, message.role !== 'assistant' || services === undefined || model === undefined ? null : createElement(AssistantAvatarPortrait, { services, model }), createElement('small', { style: { color: dshThemeColor.labelSecondary } }, message.role === 'user' ? t('voice.dialog.user') : name, message.interrupted ? ' · ' + t('awb.call.interrupted') : '')), createElement(AssistantMessageContentView, { text: message.text, calls: message.role === 'assistant' ? message.toolCalls : undefined, t }), message.attachments?.length ? createElement('div', { 'data-codingns-assistant-message-attachments': true, style: { display: 'flex', flexWrap: 'wrap', gap: 6, marginTop: 8 } }, ...message.attachments.map((item) => createElement('span', { key: item.attachment.attachmentId, title: item.attachment.name,
|
|
13
|
+
style: { fontSize: 12, padding: '3px 8px', borderRadius: 8, border: `1px solid ${dshThemeColor.border}` } }, item.attachment.name || t('awb.attachments.unnamed')))) : null);
|
|
14
|
+
}
|
|
15
|
+
/** 文字聊天、实时字幕与通话历史共用同一时间线,不额外生成工具汇总区。 */
|
|
16
|
+
export function AssistantMessageContentView({ text, calls, t }) {
|
|
17
|
+
return createElement(Fragment, null, ...assistantMessageTimeline(text, calls).map((part) => part.kind === 'tool'
|
|
18
|
+
? createElement(AssistantToolCallsView, { key: part.key, calls: [part.call], t })
|
|
19
|
+
: createElement('div', { key: part.key, 'data-codingns-assistant-text': true,
|
|
20
|
+
style: { whiteSpace: 'pre-wrap', overflowWrap: 'anywhere' } }, part.text)));
|
|
21
|
+
}
|
|
22
|
+
/** 工具信息单独展示,不拼入消息正文,字幕与语音合成都只使用原始 text。 */
|
|
23
|
+
export function AssistantToolCallsView({ calls, t }) {
|
|
24
|
+
if (!calls?.length)
|
|
25
|
+
return null;
|
|
26
|
+
return createElement('div', { 'data-codingns-assistant-tools': true,
|
|
27
|
+
style: { display: 'grid', gap: 6, marginBlock: 6, textAlign: 'left', whiteSpace: 'normal', minWidth: 0 } }, createElement(AssistantRecordStyle), ...calls.map((call) => createElement(AssistantToolCallView, { key: call.id, call, t })));
|
|
28
|
+
}
|
|
29
|
+
/** 整个标题栏就是展开入口;实时状态更新不替换 details,保留用户的展开状态。 */
|
|
30
|
+
function AssistantToolCallView({ call, t }) {
|
|
31
|
+
const label = t(call.kind === 'web-search' ? 'awb.call.webSearch' : call.kind === 'attachment' ? 'awb.call.attachment' : 'awb.call.workspace');
|
|
32
|
+
const status = t(`awb.call.tool.${call.state}`);
|
|
33
|
+
const color = call.state === 'failed' ? dshThemeColor.error : call.state === 'completed' ? dshThemeColor.success
|
|
34
|
+
: call.state === 'running' ? dshThemeColor.accent : dshThemeColor.labelSecondary;
|
|
35
|
+
const startedAt = new Date(call.startedAt);
|
|
36
|
+
return createElement('article', { 'data-codingns-assistant-tool': call.name, 'data-state': call.state,
|
|
37
|
+
style: { borderRadius: 10, border: `1px solid ${dshThemeColor.border}`, background: dshThemeColor.surfaceSubtle,
|
|
38
|
+
color: dshThemeColor.labelPrimary, fontSize: 12, lineHeight: 1.4, minWidth: 0 } }, createElement('details', { className: 'codingns-assistant-tool-details' }, createElement('summary', { className: 'codingns-assistant-tool-summary', title: t('awb.call.toolDetails'),
|
|
39
|
+
'aria-label': `${label} · ${call.name} · ${status} · ${t('awb.call.toolDetails')}`,
|
|
40
|
+
style: { display: 'flex', alignItems: 'center', gap: 8, padding: '8px 10px', minWidth: 0 } }, createElement('span', { style: { display: 'grid', placeItems: 'center', flexShrink: 0, width: 28, height: 28, borderRadius: 8,
|
|
41
|
+
color, background: `color-mix(in srgb, ${color} 9%, transparent)` } }, createElement(AssistantToolIcon, { kind: call.kind })), createElement('span', { style: { flex: '1 1 auto', minWidth: 0, display: 'grid', gap: 1 } }, createElement('strong', { style: { fontSize: 12, fontWeight: 600 } }, label), createElement('span', { className: 'codingns-assistant-tool-name', title: call.name, style: { color: dshThemeColor.labelSecondary, fontFamily: dshThemeColor.codeFont,
|
|
42
|
+
fontSize: 11, overflow: 'hidden', textOverflow: 'ellipsis', whiteSpace: 'nowrap' } }, call.name)), createElement('span', { style: { display: 'grid', justifyItems: 'end', gap: 3, flexShrink: 0 } }, createElement('span', { role: 'status', style: { display: 'inline-flex', alignItems: 'center', gap: 4, color,
|
|
43
|
+
padding: '1px 6px', borderRadius: 5, background: `color-mix(in srgb, ${color} 9%, transparent)`, fontSize: 11, whiteSpace: 'nowrap' } }, createElement('span', { 'aria-hidden': true, style: { width: 4, height: 4, borderRadius: '50%', background: 'currentColor' } }), status), createElement('time', { dateTime: Number.isNaN(startedAt.valueOf()) ? undefined : startedAt.toISOString(), title: startedAt.toLocaleString(),
|
|
44
|
+
style: { color: dshThemeColor.labelTertiary, fontSize: 10, fontVariantNumeric: 'tabular-nums', whiteSpace: 'nowrap' } }, startedAt.toLocaleTimeString([], { hour: '2-digit', minute: '2-digit', second: '2-digit', hour12: false }))), createElement(AssistantRecordChevron)), createElement('div', { style: { display: 'grid', gap: 8, padding: '9px 10px 10px', borderTop: `1px solid ${dshThemeColor.border}`, minWidth: 0 } }, ...[[t('awb.call.arguments'), call.arguments], [t('awb.call.result'), call.result]].map(([heading, value]) => createElement('div', { key: heading, style: { minWidth: 0 } }, createElement('small', { style: { color: dshThemeColor.labelSecondary, fontSize: 11, fontWeight: 500 } }, heading), createElement('pre', { tabIndex: 0, 'aria-label': heading, style: { margin: '4px 0 0', padding: '6px 8px', borderRadius: 6,
|
|
45
|
+
background: dshThemeColor.cardBackground, maxHeight: 160, overflowY: 'auto', overscrollBehavior: 'contain', scrollbarWidth: 'thin',
|
|
46
|
+
whiteSpace: 'pre-wrap', overflowWrap: 'anywhere', fontFamily: dshThemeColor.codeFont, fontSize: 11, lineHeight: 1.5 } }, value || '—'))))));
|
|
47
|
+
}
|
|
48
|
+
function AssistantToolIcon({ kind }) {
|
|
49
|
+
const path = kind === 'web-search' ? 'M21 12a9 9 0 1 1-18 0 9 9 0 0 1 18 0ZM3 12h18M12 3a17 17 0 0 1 0 18 17 17 0 0 1 0-18Z'
|
|
50
|
+
: kind === 'attachment' ? 'M14 3H6v18h12V7l-4-4Zm0 0v5h4M9 12h6m-6 4h6'
|
|
51
|
+
: 'M3 6h7l2 2h9v12H3V6Zm0 4h18';
|
|
52
|
+
return createElement('svg', { width: 16, height: 16, viewBox: '0 0 24 24', fill: 'none', stroke: 'currentColor', strokeWidth: 1.7,
|
|
53
|
+
strokeLinecap: 'round', strokeLinejoin: 'round', 'aria-hidden': true }, createElement('path', { d: path }));
|
|
54
|
+
}
|
|
55
|
+
//# sourceMappingURL=assistant-conversation-message.js.map
|