@iota-uz/sdk 0.20.0 → 0.22.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/chat-ui/PHOSPHOR-LICENSE +21 -0
- package/dist/chat-ui/animations/index.d.ts +4 -0
- package/dist/chat-ui/animations/variants.d.ts +322 -0
- package/dist/chat-ui/api/csrf.d.ts +20 -0
- package/dist/chat-ui/components/ActivityTrace.d.ts +12 -0
- package/dist/chat-ui/components/Alert.d.ts +13 -0
- package/dist/chat-ui/components/AllChatsList.d.ts +9 -0
- package/dist/chat-ui/components/ArchiveBanner.d.ts +9 -0
- package/dist/chat-ui/components/ArchivedChatList.d.ts +12 -0
- package/dist/chat-ui/components/AssistantMessage.d.ts +149 -0
- package/dist/chat-ui/components/AssistantTurnView.d.ts +25 -0
- package/dist/chat-ui/components/AttachmentGrid.d.ts +19 -0
- package/dist/chat-ui/components/AttachmentPreview.d.ts +14 -0
- package/dist/chat-ui/components/AttachmentUpload.d.ts +14 -0
- package/dist/chat-ui/components/AvatarStack.d.ts +21 -0
- package/dist/chat-ui/components/BiChatLayout.d.ts +19 -0
- package/dist/chat-ui/components/ChartCard.d.ts +17 -0
- package/dist/chat-ui/components/ChatHeader.d.ts +31 -0
- package/dist/chat-ui/components/ChatSession.d.ts +51 -0
- package/dist/chat-ui/components/CodeBlock.d.ts +26 -0
- package/dist/chat-ui/components/CodeOutputsPanel.d.ts +8 -0
- package/dist/chat-ui/components/CompactionDoodle.d.ts +7 -0
- package/dist/chat-ui/components/ConfirmModal.d.ts +23 -0
- package/dist/chat-ui/components/ConfirmationStep.d.ts +13 -0
- package/dist/chat-ui/components/DataTableCell.d.ts +11 -0
- package/dist/chat-ui/components/DataTableFooter.d.ts +9 -0
- package/dist/chat-ui/components/DataTableHeader.d.ts +15 -0
- package/dist/chat-ui/components/DataTableToolbar.d.ts +17 -0
- package/dist/chat-ui/components/DateGroupHeader.d.ts +11 -0
- package/dist/chat-ui/components/DateSeparator.d.ts +6 -0
- package/dist/chat-ui/components/DebugPanel.d.ts +7 -0
- package/dist/chat-ui/components/DownloadCard.d.ts +7 -0
- package/dist/chat-ui/components/EditableText.d.ts +30 -0
- package/dist/chat-ui/components/EmptyState.d.ts +19 -0
- package/dist/chat-ui/components/ErrorBoundary.d.ts +23 -0
- package/dist/chat-ui/components/FullscreenOverlay.d.ts +9 -0
- package/dist/chat-ui/components/ImageModal.d.ts +13 -0
- package/dist/chat-ui/components/InlineDialog.d.ts +16 -0
- package/dist/chat-ui/components/InlineQuestionForm.d.ts +7 -0
- package/dist/chat-ui/components/InteractiveTableCard.d.ts +18 -0
- package/dist/chat-ui/components/LoadingSpinner.d.ts +11 -0
- package/dist/chat-ui/components/MarkdownRenderer.d.ts +13 -0
- package/dist/chat-ui/components/Menu.d.ts +29 -0
- package/dist/chat-ui/components/MessageActions.d.ts +17 -0
- package/dist/chat-ui/components/MessageInput.d.ts +39 -0
- package/dist/chat-ui/components/MessageList.d.ts +12 -0
- package/dist/chat-ui/components/MessageQueueList.d.ts +9 -0
- package/dist/chat-ui/components/ModelSelector.d.ts +2 -0
- package/dist/chat-ui/components/PermissionGuard.d.ts +47 -0
- package/dist/chat-ui/components/QuestionForm.d.ts +10 -0
- package/dist/chat-ui/components/QuestionStep.d.ts +15 -0
- package/dist/chat-ui/components/RetryActionArea.d.ts +7 -0
- package/dist/chat-ui/components/ScreenReaderAnnouncer.d.ts +22 -0
- package/dist/chat-ui/components/ScrollToBottomButton.d.ts +12 -0
- package/dist/chat-ui/components/SearchInput.d.ts +27 -0
- package/dist/chat-ui/components/SessionArtifactList.d.ts +9 -0
- package/dist/chat-ui/components/SessionArtifactPreview.d.ts +7 -0
- package/dist/chat-ui/components/SessionArtifactPreviewModal.d.ts +13 -0
- package/dist/chat-ui/components/SessionArtifactsPanel.d.ts +13 -0
- package/dist/chat-ui/components/SessionItem.d.ts +18 -0
- package/dist/chat-ui/components/SessionMembersModal.d.ts +10 -0
- package/dist/chat-ui/components/SessionSkeleton.d.ts +6 -0
- package/dist/chat-ui/components/Sidebar.d.ts +22 -0
- package/dist/chat-ui/components/Skeleton.d.ts +63 -0
- package/dist/chat-ui/components/SkipLink.d.ts +2 -0
- package/dist/chat-ui/components/SourcesPanel.d.ts +7 -0
- package/dist/chat-ui/components/StreamError.d.ts +15 -0
- package/dist/chat-ui/components/StreamingCursor.d.ts +4 -0
- package/dist/chat-ui/components/SystemMessage.d.ts +10 -0
- package/dist/chat-ui/components/TabBar.d.ts +15 -0
- package/dist/chat-ui/components/TabbedChartGroup.d.ts +6 -0
- package/dist/chat-ui/components/TabbedTableGroup.d.ts +8 -0
- package/dist/chat-ui/components/TableExportButton.d.ts +13 -0
- package/dist/chat-ui/components/TableWithExport.d.ts +15 -0
- package/dist/chat-ui/components/Toast.d.ts +15 -0
- package/dist/chat-ui/components/ToastContainer.d.ts +10 -0
- package/dist/chat-ui/components/TouchContextMenu.d.ts +18 -0
- package/dist/chat-ui/components/Transition.d.ts +11 -0
- package/dist/chat-ui/components/TurnBubble.d.ts +51 -0
- package/dist/chat-ui/components/TypingIndicator.d.ts +13 -0
- package/dist/chat-ui/components/UserAvatar.d.ts +21 -0
- package/dist/chat-ui/components/UserFilter.d.ts +12 -0
- package/dist/chat-ui/components/UserMessage.d.ts +86 -0
- package/dist/chat-ui/components/UserTurnView.d.ts +25 -0
- package/dist/chat-ui/components/WelcomeContent.d.ts +17 -0
- package/dist/chat-ui/config/ConfigContext.d.ts +61 -0
- package/dist/chat-ui/context/ChatContext.d.ts +42 -0
- package/dist/chat-ui/context/IotaContext.d.ts +21 -0
- package/dist/chat-ui/context/chatHelpers.d.ts +18 -0
- package/dist/chat-ui/context/externalSnapshot.d.ts +4 -0
- package/dist/chat-ui/data/ArtifactManager.d.ts +23 -0
- package/dist/chat-ui/data/AttachmentUploader.d.ts +25 -0
- package/dist/chat-ui/data/HttpDataSource.d.ts +109 -0
- package/dist/chat-ui/data/ManagedHttpDataSource.d.ts +26 -0
- package/dist/chat-ui/data/MessageTransport.d.ts +88 -0
- package/dist/chat-ui/data/SessionManager.d.ts +52 -0
- package/dist/chat-ui/data/applet-rpc.d.ts +29 -0
- package/dist/chat-ui/data/mappers.d.ts +33 -0
- package/dist/chat-ui/data/openManagedEventSource.d.ts +54 -0
- package/dist/chat-ui/data/rpc.generated.d.ts +421 -0
- package/dist/chat-ui/hooks/createHorizontalSwipe.d.ts +27 -0
- package/dist/chat-ui/hooks/createReducedMotion.d.ts +1 -0
- package/dist/chat-ui/hooks/useActiveRuns.d.ts +47 -0
- package/dist/chat-ui/hooks/useAttachments.d.ts +80 -0
- package/dist/chat-ui/hooks/useAutoScroll.d.ts +51 -0
- package/dist/chat-ui/hooks/useBichatRouter.d.ts +40 -0
- package/dist/chat-ui/hooks/useBranding.d.ts +16 -0
- package/dist/chat-ui/hooks/useDataTable.d.ts +54 -0
- package/dist/chat-ui/hooks/useFocusTrap.d.ts +17 -0
- package/dist/chat-ui/hooks/useHttpDataSourceConfigFromApplet.d.ts +19 -0
- package/dist/chat-ui/hooks/useImageGallery.d.ts +67 -0
- package/dist/chat-ui/hooks/useKeyboardShortcuts.d.ts +23 -0
- package/dist/chat-ui/hooks/useLongPress.d.ts +22 -0
- package/dist/chat-ui/hooks/useMarkdownCopy.d.ts +46 -0
- package/dist/chat-ui/hooks/useMessageActions.d.ts +53 -0
- package/dist/chat-ui/hooks/useMessageListScroll.d.ts +22 -0
- package/dist/chat-ui/hooks/useModalLock.d.ts +1 -0
- package/dist/chat-ui/hooks/useScrollToBottom.d.ts +22 -0
- package/dist/chat-ui/hooks/useSidebarState.d.ts +8 -0
- package/dist/chat-ui/hooks/useToast.d.ts +43 -0
- package/dist/chat-ui/hooks/useTranslation.d.ts +4 -0
- package/dist/chat-ui/icons/index.d.ts +93 -0
- package/dist/chat-ui/icons.js +975 -0
- package/dist/chat-ui/index.d.ts +122 -0
- package/dist/chat-ui/index.js +51821 -0
- package/dist/chat-ui/machine/ChatMachine.d.ts +191 -0
- package/dist/chat-ui/machine/hitlLifecycle.d.ts +7 -0
- package/dist/chat-ui/machine/index.d.ts +2 -0
- package/dist/chat-ui/machine/selectors.d.ts +5 -0
- package/dist/chat-ui/machine/types.d.ts +127 -0
- package/dist/chat-ui/styles.css +1 -0
- package/dist/chat-ui/theme/themes.d.ts +6 -0
- package/dist/chat-ui/theme/types.d.ts +38 -0
- package/dist/chat-ui/types/applet/index.d.ts +82 -0
- package/dist/chat-ui/types/data-source.d.ts +81 -0
- package/dist/chat-ui/types/index.d.ts +719 -0
- package/dist/chat-ui/types/iota.d.ts +76 -0
- package/dist/chat-ui/utils/RateLimiter.d.ts +28 -0
- package/dist/chat-ui/utils/activitySteps.d.ts +15 -0
- package/dist/chat-ui/utils/artifactHelpers.d.ts +7 -0
- package/dist/chat-ui/utils/assistantTurnState.d.ts +4 -0
- package/dist/chat-ui/utils/chartSpec.d.ts +15 -0
- package/dist/chat-ui/utils/citationProcessor.d.ts +38 -0
- package/dist/chat-ui/utils/columnTypes.d.ts +9 -0
- package/dist/chat-ui/utils/cssLength.d.ts +1 -0
- package/dist/chat-ui/utils/dateFormatting.d.ts +13 -0
- package/dist/chat-ui/utils/debugMetrics.d.ts +5 -0
- package/dist/chat-ui/utils/debugModeStorage.d.ts +2 -0
- package/dist/chat-ui/utils/debugTrace.d.ts +4 -0
- package/dist/chat-ui/utils/errorDisplay.d.ts +23 -0
- package/dist/chat-ui/utils/eventNames.d.ts +27 -0
- package/dist/chat-ui/utils/fileUtils.d.ts +48 -0
- package/dist/chat-ui/utils/markdownMath.d.ts +9 -0
- package/dist/chat-ui/utils/markdownStream.d.ts +8 -0
- package/dist/chat-ui/utils/questionFormUtils.d.ts +18 -0
- package/dist/chat-ui/utils/queueStorage.d.ts +4 -0
- package/dist/chat-ui/utils/reasoningEffortStorage.d.ts +3 -0
- package/dist/chat-ui/utils/sessionGrouping.d.ts +7 -0
- package/dist/chat-ui/utils/sseParser.d.ts +34 -0
- package/dist/chat-ui/utils/tableSpec.d.ts +6 -0
- package/dist/chat-ui/utils/textBlocks.d.ts +43 -0
- package/dist/chat-ui/utils/toolLabels.d.ts +17 -0
- package/dist/client-host/{applet.d.ts → bichat-config.d.ts} +2 -16
- package/dist/client-host/bichat-config.d.ts.map +1 -0
- package/dist/client-host/{applet.js → bichat-config.js} +0 -8
- package/dist/client-host/identity.d.ts +4 -4
- package/dist/client-host/identity.js +2 -2
- package/dist/client-host/index.d.ts +7 -4
- package/dist/client-host/index.d.ts.map +1 -1
- package/dist/client-host/index.js +7 -4
- package/dist/client-host/solid-index.d.ts +1 -0
- package/dist/client-host/solid-index.d.ts.map +1 -1
- package/dist/client-host/solid-index.js +1 -0
- package/dist/client-host/solid-streaming.d.ts.map +1 -1
- package/dist/lens/CascadePanel-BXaSLD9I.js +700 -0
- package/dist/lens/ChartDataEquivalent-Uo4RCCqz.js +92 -0
- package/dist/lens/ChartPanel-BYIblvtO.js +981 -0
- package/dist/lens/CoveragePanel-CBxW7l_N.js +195 -0
- package/dist/lens/DashboardPanels.d.ts +4 -1
- package/dist/lens/DashboardPanels.d.ts.map +1 -1
- package/dist/lens/GaugePanel-Gm3y4QBi.js +39 -0
- package/dist/lens/LensDashboard.d.ts +7 -2
- package/dist/lens/LensDashboard.d.ts.map +1 -1
- package/dist/lens/MapPanel-Fr67rBRo.js +256 -0
- package/dist/lens/MetricFlowPanel-DFGBh3hI.js +135 -0
- package/dist/lens/MetricHierarchyPanel-DKiQ8e3m.js +121 -0
- package/dist/lens/MetricRelationshipPanel-YC3Cg9Id.js +120 -0
- package/dist/lens/PrintReport-BPI_jNyw.js +1876 -0
- package/dist/lens/TablePanel-Bh8dWK4d.js +946 -0
- package/dist/lens/{adapter-BwEwcw2W.js → adapter-DIzUDxuh.js} +384 -384
- package/dist/lens/contract/schemas.d.ts.map +1 -1
- package/dist/lens/contract/types.d.ts +1 -1
- package/dist/lens/contract/types.d.ts.map +1 -1
- package/dist/lens/controls/Calendar.d.ts +1 -1
- package/dist/lens/controls/Calendar.d.ts.map +1 -1
- package/dist/lens/controls/CompareFilterControl.d.ts +2 -2
- package/dist/lens/controls/CompareFilterControl.d.ts.map +1 -1
- package/dist/lens/controls/FacetFilterMenu.d.ts +2 -2
- package/dist/lens/controls/FacetFilterMenu.d.ts.map +1 -1
- package/dist/lens/controls/FilterBar.d.ts +3 -3
- package/dist/lens/controls/FilterBar.d.ts.map +1 -1
- package/dist/lens/controls/PeriodFilterControl.d.ts +2 -1
- package/dist/lens/controls/PeriodFilterControl.d.ts.map +1 -1
- package/dist/lens/controls/SegmentedFilterControl.d.ts +2 -2
- package/dist/lens/controls/SegmentedFilterControl.d.ts.map +1 -1
- package/dist/lens/controls/facetOptions.d.ts +5 -5
- package/dist/lens/controls/facetOptions.d.ts.map +1 -1
- package/dist/lens/element.d.ts +1 -1
- package/dist/lens/element.d.ts.map +1 -1
- package/dist/lens/explore/ContextMiniChart.d.ts +2 -1
- package/dist/lens/explore/ContextMiniChart.d.ts.map +1 -1
- package/dist/lens/explore/DrillOverlay.d.ts +2 -1
- package/dist/lens/explore/DrillOverlay.d.ts.map +1 -1
- package/dist/lens/explore/ExplorePanel.d.ts +2 -1
- package/dist/lens/explore/ExplorePanel.d.ts.map +1 -1
- package/dist/lens/explore/FocusContextHeader.d.ts +2 -1
- package/dist/lens/explore/FocusContextHeader.d.ts.map +1 -1
- package/dist/lens/explore/LensSelector.d.ts +2 -1
- package/dist/lens/explore/LensSelector.d.ts.map +1 -1
- package/dist/lens/explore/SourceDataDisclosure.d.ts +3 -3
- package/dist/lens/explore/SourceDataDisclosure.d.ts.map +1 -1
- package/dist/lens/icons.d.ts +36 -35
- package/dist/lens/icons.d.ts.map +1 -1
- package/dist/lens/{index-B6anZ5Pr.js → index-2qUA4koZ.js} +1 -1
- package/dist/lens/index-DW4iQi93.js +13171 -0
- package/dist/lens/index.d.ts +3 -1
- package/dist/lens/index.d.ts.map +1 -1
- package/dist/lens/index.js +14 -9
- package/dist/lens/{install-D5OiGDnd.js → install-C-b2Bm4Y.js} +1 -1
- package/dist/lens/{install-CsNOaFxV.js → install-C7rGzRvO.js} +1 -1
- package/dist/lens/{install-CumkiUJn.js → install-Ce8R_Bl2.js} +1 -1
- package/dist/lens/{install-VEXJv-Wi.js → install-Czhlaw4u.js} +1 -1
- package/dist/lens/keys-BC7G1vyT.js +91 -0
- package/dist/lens/metricViews-DSoDe0GU.js +210 -0
- package/dist/lens/panels/CascadePanel.d.ts +1 -1
- package/dist/lens/panels/CascadePanel.d.ts.map +1 -1
- package/dist/lens/panels/ChartDataEquivalent.d.ts +1 -1
- package/dist/lens/panels/ChartDataEquivalent.d.ts.map +1 -1
- package/dist/lens/panels/ChartHost.d.ts +1 -1
- package/dist/lens/panels/ChartHost.d.ts.map +1 -1
- package/dist/lens/panels/ChartPanel.d.ts +2 -1
- package/dist/lens/panels/ChartPanel.d.ts.map +1 -1
- package/dist/lens/panels/CopyValueButton.d.ts +1 -1
- package/dist/lens/panels/CopyValueButton.d.ts.map +1 -1
- package/dist/lens/panels/CoveragePanel.d.ts +1 -1
- package/dist/lens/panels/CoveragePanel.d.ts.map +1 -1
- package/dist/lens/panels/ExportMenu.d.ts +1 -1
- package/dist/lens/panels/ExportMenu.d.ts.map +1 -1
- package/dist/lens/panels/GaugePanel.d.ts +1 -1
- package/dist/lens/panels/GaugePanel.d.ts.map +1 -1
- package/dist/lens/panels/InfoTip.d.ts +2 -1
- package/dist/lens/panels/InfoTip.d.ts.map +1 -1
- package/dist/lens/panels/MapPanel.d.ts +1 -1
- package/dist/lens/panels/MapPanel.d.ts.map +1 -1
- package/dist/lens/panels/MetricFlowPanel.d.ts +1 -1
- package/dist/lens/panels/MetricFlowPanel.d.ts.map +1 -1
- package/dist/lens/panels/MetricHierarchyPanel.d.ts +2 -1
- package/dist/lens/panels/MetricHierarchyPanel.d.ts.map +1 -1
- package/dist/lens/panels/MetricRelationshipPanel.d.ts +1 -1
- package/dist/lens/panels/MetricRelationshipPanel.d.ts.map +1 -1
- package/dist/lens/panels/PanelExportMenu.d.ts +2 -2
- package/dist/lens/panels/PanelExportMenu.d.ts.map +1 -1
- package/dist/lens/panels/PanelFrame.d.ts +6 -6
- package/dist/lens/panels/PanelFrame.d.ts.map +1 -1
- package/dist/lens/panels/PanelOverlay.d.ts +4 -4
- package/dist/lens/panels/PanelOverlay.d.ts.map +1 -1
- package/dist/lens/panels/QualityChip.d.ts +8 -4
- package/dist/lens/panels/QualityChip.d.ts.map +1 -1
- package/dist/lens/panels/ShareSliceButton.d.ts +1 -1
- package/dist/lens/panels/ShareSliceButton.d.ts.map +1 -1
- package/dist/lens/panels/Skeleton.d.ts +13 -13
- package/dist/lens/panels/Skeleton.d.ts.map +1 -1
- package/dist/lens/panels/StatPanel.d.ts +11 -11
- package/dist/lens/panels/StatPanel.d.ts.map +1 -1
- package/dist/lens/panels/StatValueTicker.d.ts +2 -2
- package/dist/lens/panels/StatValueTicker.d.ts.map +1 -1
- package/dist/lens/panels/TablePanel.d.ts +2 -1
- package/dist/lens/panels/TablePanel.d.ts.map +1 -1
- package/dist/lens/panels/WaterfallPlot.d.ts +3 -3
- package/dist/lens/panels/WaterfallPlot.d.ts.map +1 -1
- package/dist/lens/panels/actions.d.ts +16 -13
- package/dist/lens/panels/actions.d.ts.map +1 -1
- package/dist/lens/panels/context.d.ts +5 -5
- package/dist/lens/panels/context.d.ts.map +1 -1
- package/dist/lens/panels/focusTrap.d.ts +4 -0
- package/dist/lens/panels/focusTrap.d.ts.map +1 -0
- package/dist/lens/panels/overlayContainer.d.ts +18 -0
- package/dist/lens/panels/overlayContainer.d.ts.map +1 -0
- package/dist/lens/panels/registry.d.ts +23 -23
- package/dist/lens/panels/registry.d.ts.map +1 -1
- package/dist/lens/panels/useIsClamped.d.ts +2 -2
- package/dist/lens/panels/useIsClamped.d.ts.map +1 -1
- package/dist/lens/panels/useMenuButton.d.ts +21 -14
- package/dist/lens/panels/useMenuButton.d.ts.map +1 -1
- package/dist/lens/{prefetch-C_qYKOTU.js → prefetch-Caqfl7sC.js} +2 -2
- package/dist/lens/{prefetchPanels-CD4C-A5q.js → prefetchPanels-B-09akeK.js} +1 -1
- package/dist/lens/print/PrintReport.d.ts +4 -3
- package/dist/lens/print/PrintReport.d.ts.map +1 -1
- package/dist/lens/print/formula.d.ts +3 -2
- package/dist/lens/print/formula.d.ts.map +1 -1
- package/dist/lens/print/quality.d.ts +3 -2
- package/dist/lens/print/quality.d.ts.map +1 -1
- package/dist/lens/{print-Iu804kRb.js → print-CcDZyjFC.js} +1 -1
- package/dist/lens/reports/contract/schemas.d.ts +17 -0
- package/dist/lens/reports/contract/schemas.d.ts.map +1 -0
- package/dist/lens/reports/contract/types.d.ts +42 -0
- package/dist/lens/reports/contract/types.d.ts.map +1 -0
- package/dist/lens/reports/draft.d.ts +28 -0
- package/dist/lens/reports/draft.d.ts.map +1 -0
- package/dist/lens/runtime/drawer.d.ts +3 -3
- package/dist/lens/runtime/drawer.d.ts.map +1 -1
- package/dist/lens/runtime/overlayContainer.d.ts +2 -2
- package/dist/lens/runtime/overlayContainer.d.ts.map +1 -1
- package/dist/lens/runtime/provider.d.ts +23 -23
- package/dist/lens/runtime/provider.d.ts.map +1 -1
- package/dist/lens/{scales-CWTA0tSQ.js → scales-DOCY7Afr.js} +1 -1
- package/dist/lens/style.css +1 -1
- package/dist/sdk-identity.cjs +3 -3
- package/dist/sdk-identity.js +3 -3
- package/dist/sdk-identity.json +2 -2
- package/package.json +11 -10
- package/dist/client-host/applet.d.ts.map +0 -1
- package/dist/client-host/portals.d.ts +0 -30
- package/dist/client-host/portals.d.ts.map +0 -1
- package/dist/client-host/portals.js +0 -84
- package/dist/client-host/route.d.ts +0 -17
- package/dist/client-host/route.d.ts.map +0 -1
- package/dist/client-host/route.js +0 -19
- package/dist/client-host/rpc.d.ts +0 -15
- package/dist/client-host/rpc.d.ts.map +0 -1
- package/dist/client-host/rpc.js +0 -28
- package/dist/lens/CascadePanel-Sd2OKQx-.js +0 -574
- package/dist/lens/ChartDataEquivalent-DgCAb4Ov.js +0 -53
- package/dist/lens/ChartPanel-CiAahY9O.js +0 -709
- package/dist/lens/CoveragePanel-DeeKg8gF.js +0 -131
- package/dist/lens/GaugePanel-8rsf_XHS.js +0 -43
- package/dist/lens/MapPanel-Bq0mfVCB.js +0 -179
- package/dist/lens/MetricFlowPanel-ZBJqPFpc.js +0 -70
- package/dist/lens/MetricHierarchyPanel-DStGwvVU.js +0 -72
- package/dist/lens/MetricRelationshipPanel-D6ItmGCS.js +0 -54
- package/dist/lens/PrintReport-Dr-6xXVr.js +0 -1367
- package/dist/lens/TablePanel-CzLP8gG0.js +0 -619
- package/dist/lens/index-R9mnOHaj.js +0 -11000
- package/dist/lens/keys-6_gqLhcv.js +0 -78
- package/dist/lens/metricViews-De-9pff-.js +0 -170
- package/dist/lens/runtime/focusTrap.d.ts +0 -4
- package/dist/lens/runtime/focusTrap.d.ts.map +0 -1
|
@@ -0,0 +1,76 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* BiChat context types layered on top of canonical applet-core context contracts.
|
|
3
|
+
*/
|
|
4
|
+
import type { AppConfig as AppletAppConfig, InitialContext as AppletInitialContext, LocaleContext as AppletLocaleContext, TenantContext as AppletTenantContext, UserContext as AppletUserContext } from './applet';
|
|
5
|
+
export type UserContext = AppletUserContext;
|
|
6
|
+
export type TenantContext = AppletTenantContext;
|
|
7
|
+
export type LocaleContext = AppletLocaleContext;
|
|
8
|
+
export type AppConfig = AppletAppConfig & {
|
|
9
|
+
streamEndpoint: string;
|
|
10
|
+
basePath: string;
|
|
11
|
+
assetsBasePath: string;
|
|
12
|
+
rpcUIEndpoint: string;
|
|
13
|
+
};
|
|
14
|
+
export interface Extensions {
|
|
15
|
+
branding?: {
|
|
16
|
+
appName?: string;
|
|
17
|
+
logoUrl?: string;
|
|
18
|
+
theme?: {
|
|
19
|
+
primary?: string;
|
|
20
|
+
secondary?: string;
|
|
21
|
+
accent?: string;
|
|
22
|
+
};
|
|
23
|
+
welcome?: {
|
|
24
|
+
title?: string;
|
|
25
|
+
description?: string;
|
|
26
|
+
examplePrompts?: Array<{
|
|
27
|
+
category: string;
|
|
28
|
+
text: string;
|
|
29
|
+
icon: string;
|
|
30
|
+
}>;
|
|
31
|
+
};
|
|
32
|
+
colors?: {
|
|
33
|
+
primary?: string;
|
|
34
|
+
secondary?: string;
|
|
35
|
+
accent?: string;
|
|
36
|
+
};
|
|
37
|
+
logo?: {
|
|
38
|
+
src?: string;
|
|
39
|
+
alt?: string;
|
|
40
|
+
};
|
|
41
|
+
};
|
|
42
|
+
features?: {
|
|
43
|
+
vision?: boolean;
|
|
44
|
+
webSearch?: boolean;
|
|
45
|
+
codeInterpreter?: boolean;
|
|
46
|
+
multiAgent?: boolean;
|
|
47
|
+
};
|
|
48
|
+
llm?: {
|
|
49
|
+
provider?: string;
|
|
50
|
+
apiKeyConfigured?: boolean;
|
|
51
|
+
reasoningEffortOptions?: string[];
|
|
52
|
+
models?: Array<{
|
|
53
|
+
id: string;
|
|
54
|
+
label: string;
|
|
55
|
+
default?: boolean;
|
|
56
|
+
}>;
|
|
57
|
+
};
|
|
58
|
+
debug?: {
|
|
59
|
+
limits?: {
|
|
60
|
+
policyMaxTokens: number;
|
|
61
|
+
modelMaxTokens: number;
|
|
62
|
+
effectiveMaxTokens: number;
|
|
63
|
+
completionReserveTokens: number;
|
|
64
|
+
};
|
|
65
|
+
};
|
|
66
|
+
}
|
|
67
|
+
export type IotaContext = Omit<AppletInitialContext, 'config' | 'extensions'> & {
|
|
68
|
+
config: AppConfig;
|
|
69
|
+
extensions?: Extensions;
|
|
70
|
+
};
|
|
71
|
+
declare global {
|
|
72
|
+
interface Window {
|
|
73
|
+
__APPLET_CONTEXT__: IotaContext;
|
|
74
|
+
__CSRF_TOKEN__: string;
|
|
75
|
+
}
|
|
76
|
+
}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Per-session rate limiter
|
|
3
|
+
* Prevents excessive requests within a time window
|
|
4
|
+
*/
|
|
5
|
+
export interface RateLimiterConfig {
|
|
6
|
+
maxRequests: number;
|
|
7
|
+
windowMs: number;
|
|
8
|
+
}
|
|
9
|
+
export declare class RateLimiter {
|
|
10
|
+
private timestamps;
|
|
11
|
+
private maxRequests;
|
|
12
|
+
private windowMs;
|
|
13
|
+
constructor(config: RateLimiterConfig);
|
|
14
|
+
/**
|
|
15
|
+
* Check if a request can be made
|
|
16
|
+
* Updates internal state if request is allowed
|
|
17
|
+
*/
|
|
18
|
+
canMakeRequest(): boolean;
|
|
19
|
+
/**
|
|
20
|
+
* Get milliseconds until next request is allowed
|
|
21
|
+
* Returns 0 if request can be made immediately
|
|
22
|
+
*/
|
|
23
|
+
getTimeUntilNextRequest(): number;
|
|
24
|
+
/**
|
|
25
|
+
* Reset the rate limiter state
|
|
26
|
+
*/
|
|
27
|
+
reset(): void;
|
|
28
|
+
}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Utility functions for activity step processing.
|
|
3
|
+
*/
|
|
4
|
+
import type { ActivityStep } from '../types';
|
|
5
|
+
/**
|
|
6
|
+
* Group activity steps by agent — top-level steps (no agentName) and
|
|
7
|
+
* agent groups (keyed by agentName).
|
|
8
|
+
*/
|
|
9
|
+
export declare function groupSteps(steps: ActivityStep[]): {
|
|
10
|
+
topLevel: ActivityStep[];
|
|
11
|
+
agentGroups: [
|
|
12
|
+
string,
|
|
13
|
+
ActivityStep[]
|
|
14
|
+
][];
|
|
15
|
+
};
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import type { SessionArtifact } from '../types';
|
|
2
|
+
export declare const FALLBACK_ARTIFACT_NAME = "Untitled artifact";
|
|
3
|
+
export declare function getArtifactName(artifact: SessionArtifact): string;
|
|
4
|
+
export declare function isImageArtifact(artifact: SessionArtifact): boolean;
|
|
5
|
+
export declare function isPDFArtifact(artifact: SessionArtifact): boolean;
|
|
6
|
+
export declare function isOfficeDocumentArtifact(artifact: SessionArtifact): boolean;
|
|
7
|
+
export declare function isTextArtifact(artifact: SessionArtifact): boolean;
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import type { AssistantTurn } from '../types';
|
|
2
|
+
export declare function isEmptyAssistantTurn(turn: AssistantTurn): boolean;
|
|
3
|
+
export declare function isPlaceholderWaitingAssistantTurn(turn: AssistantTurn): boolean;
|
|
4
|
+
export declare function shouldRenderInlineRetry(turn: AssistantTurn, canRegenerate: boolean): boolean;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Shared chart spec parsing for draw_chart tool output and artifact metadata.
|
|
3
|
+
* Used by SessionArtifactPreview, HttpDataSource (turn.charts), and MarkdownRenderer (code blocks).
|
|
4
|
+
*/
|
|
5
|
+
import type { ChartData } from '../types';
|
|
6
|
+
export declare const SUPPORTED_CHART_TYPES: Set<"line" | "bar" | "area" | "pie" | "donut">;
|
|
7
|
+
export declare function isRecord(value: unknown): value is Record<string, unknown>;
|
|
8
|
+
/**
|
|
9
|
+
* Parses a chart spec object (Apex options at top-level or under `options`) into ChartData.
|
|
10
|
+
*/
|
|
11
|
+
export declare function parseChartDataFromSpec(spec: Record<string, unknown>, fallbackTitle?: string): ChartData | null;
|
|
12
|
+
/**
|
|
13
|
+
* Parses a JSON string as a chart spec (e.g. from a ```chart or ```json code block).
|
|
14
|
+
*/
|
|
15
|
+
export declare function parseChartDataFromJsonString(json: string, fallbackTitle?: string): ChartData | null;
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Citation Processing Utility
|
|
3
|
+
*
|
|
4
|
+
* Transforms OpenAI citations from raw markers (e.g., ≡cite≡turn0search2≡)
|
|
5
|
+
* to formatted inline citation markers (e.g., [1], [2]).
|
|
6
|
+
*
|
|
7
|
+
* Process:
|
|
8
|
+
* 1. Sort citations by startIndex (descending) to process from end to start
|
|
9
|
+
* 2. Replace character ranges [startIndex, endIndex] with numbered markers
|
|
10
|
+
* 3. Return processed content with clean inline citation references
|
|
11
|
+
*/
|
|
12
|
+
import type { Citation } from '../types';
|
|
13
|
+
export interface ProcessedContent {
|
|
14
|
+
/** Content with citation markers replaced by [1], [2], etc. */
|
|
15
|
+
content: string;
|
|
16
|
+
/** Citations array with their display indices */
|
|
17
|
+
citations: Array<Citation & {
|
|
18
|
+
displayIndex: number;
|
|
19
|
+
}>;
|
|
20
|
+
}
|
|
21
|
+
/**
|
|
22
|
+
* Process message content to replace raw citation markers with formatted inline citations
|
|
23
|
+
*
|
|
24
|
+
* @param content - Raw message content with potential citation markers
|
|
25
|
+
* @param citations - Array of citations with startIndex/endIndex positions
|
|
26
|
+
* @returns Processed content with clean citation markers and indexed citations
|
|
27
|
+
*
|
|
28
|
+
* @example
|
|
29
|
+
* ```ts
|
|
30
|
+
* const result = processCitations(
|
|
31
|
+
* "Tesla reported $28B ≡cite≡turn0search2≡ revenue",
|
|
32
|
+
* [{ startIndex: 20, endIndex: 42, title: "...", url: "...", type: "url_citation" }]
|
|
33
|
+
* )
|
|
34
|
+
* // result.content = "Tesla reported $28B [1] revenue"
|
|
35
|
+
* // result.citations = [{ ..., displayIndex: 1 }]
|
|
36
|
+
* ```
|
|
37
|
+
*/
|
|
38
|
+
export declare function processCitations(content: string, citations: Citation[] | null | undefined): ProcessedContent;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
export type ColumnType = 'string' | 'number' | 'boolean' | 'date' | 'url' | 'null';
|
|
2
|
+
export interface FormattedCell {
|
|
3
|
+
display: string;
|
|
4
|
+
raw: unknown;
|
|
5
|
+
type: ColumnType;
|
|
6
|
+
isNull: boolean;
|
|
7
|
+
}
|
|
8
|
+
export declare function inferColumnType(values: unknown[], backendHint?: string): ColumnType;
|
|
9
|
+
export declare function formatCellValue(value: unknown, type: ColumnType): FormattedCell;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function cssLength(value: string | number | null | undefined): string | undefined;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Format a date as relative time (e.g., "5m ago", "2h ago")
|
|
3
|
+
* Falls back to HH:mm format for dates older than 24 hours
|
|
4
|
+
*
|
|
5
|
+
* Accepts an optional `t` function for i18n. Translation keys used:
|
|
6
|
+
* - BiChat.RelativeTime.JustNow
|
|
7
|
+
* - BiChat.RelativeTime.MinutesAgo (receives `{count}`)
|
|
8
|
+
* - BiChat.RelativeTime.HoursAgo (receives `{count}`)
|
|
9
|
+
* - BiChat.RelativeTime.DaysAgo (receives `{count}`)
|
|
10
|
+
*
|
|
11
|
+
* If no `t` function is provided, falls back to English defaults.
|
|
12
|
+
*/
|
|
13
|
+
export declare function formatRelativeTime(date: string | Date, t?: (key: string, params?: Record<string, string | number>) => string): string;
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import type { DebugUsage } from '../types';
|
|
2
|
+
export declare function formatGenerationDuration(generationMs: number): string;
|
|
3
|
+
export declare function formatDuration(durationMs: number): string;
|
|
4
|
+
export declare function calculateCompletionTokensPerSecond(usage?: DebugUsage, generationMs?: number): number | null;
|
|
5
|
+
export declare function calculateContextUsagePercent(promptTokens: number, effectiveMaxTokens?: number): number | null;
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import type { ConversationTurn, DebugTrace, SessionDebugUsage } from '../types';
|
|
2
|
+
export declare function hasMeaningfulUsage(trace?: DebugTrace['usage']): boolean;
|
|
3
|
+
export declare function hasDebugTrace(trace: DebugTrace): boolean;
|
|
4
|
+
export declare function getSessionDebugUsage(turns: ConversationTurn[]): SessionDebugUsage;
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
export interface RPCErrorDisplay {
|
|
2
|
+
title: string;
|
|
3
|
+
description: string;
|
|
4
|
+
isPermissionDenied: boolean;
|
|
5
|
+
}
|
|
6
|
+
export interface NormalizedRPCError extends RPCErrorDisplay {
|
|
7
|
+
code: string;
|
|
8
|
+
retryable: boolean;
|
|
9
|
+
userMessage: string;
|
|
10
|
+
isTimeout: boolean;
|
|
11
|
+
isOffline: boolean;
|
|
12
|
+
isCanceled: boolean;
|
|
13
|
+
isNotFound: boolean;
|
|
14
|
+
}
|
|
15
|
+
/**
|
|
16
|
+
* Check whether an error represents a permission-denied / forbidden response.
|
|
17
|
+
*/
|
|
18
|
+
export declare function isPermissionDeniedError(error: unknown): boolean;
|
|
19
|
+
export declare function normalizeRPCError(error: unknown, fallbackTitle: string): NormalizedRPCError;
|
|
20
|
+
/**
|
|
21
|
+
* Convert an unknown error into a structured display object.
|
|
22
|
+
*/
|
|
23
|
+
export declare function toErrorDisplay(error: unknown, fallbackTitle: string): RPCErrorDisplay;
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Hand-mirrored copy of the backend's pkg/httpdto.StreamEventType
|
|
3
|
+
* constant set. Used by subscribeRunEvents / subscribeActiveRuns /
|
|
4
|
+
* openManagedEventSource to register addEventListener handlers that
|
|
5
|
+
* match every `event:` label the server emits.
|
|
6
|
+
*
|
|
7
|
+
* Drift between this file and the Go definition is caught by
|
|
8
|
+
* eventNames.test.ts — the test reads the sibling Go source at test
|
|
9
|
+
* time and diffs the constant set. When the Go file is absent (CI
|
|
10
|
+
* without the SDK sidecar checkout) the drift guard self-skips.
|
|
11
|
+
*/
|
|
12
|
+
export declare const STREAM_EVENT_TYPES: readonly ["chunk", "content", "thinking", "tool_start", "tool_end", "text_block_end", "snapshot", "interrupt", "citation", "usage", "ping", "stream_started", "done", "cancelled", "error", "failed"];
|
|
13
|
+
export type StreamEventType = typeof STREAM_EVENT_TYPES[number];
|
|
14
|
+
/**
|
|
15
|
+
* Subset of {@link STREAM_EVENT_TYPES} that terminates a run from the
|
|
16
|
+
* client's perspective. Callers should close the EventSource and
|
|
17
|
+
* settle their promise on any of these.
|
|
18
|
+
*/
|
|
19
|
+
export declare const TERMINAL_STREAM_EVENT_TYPES: readonly ["done", "cancelled", "error", "failed"];
|
|
20
|
+
export type TerminalStreamEventType = typeof TERMINAL_STREAM_EVENT_TYPES[number];
|
|
21
|
+
/**
|
|
22
|
+
* Narrow + type-guard helper. Returns true when `name` is one of the
|
|
23
|
+
* terminal stream event types. The guard narrows precisely to the
|
|
24
|
+
* terminal subset — callers receiving `true` get {@link TerminalStreamEventType},
|
|
25
|
+
* not the full {@link StreamEventType} union.
|
|
26
|
+
*/
|
|
27
|
+
export declare function isTerminalEvent(name: string): name is TerminalStreamEventType;
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
export declare const ATTACHMENT_ACCEPT_ATTRIBUTE: string;
|
|
2
|
+
export declare function isImageMimeType(mimeType: string): boolean;
|
|
3
|
+
/**
|
|
4
|
+
* Validates a file against size and type constraints
|
|
5
|
+
* @throws Error if validation fails
|
|
6
|
+
*/
|
|
7
|
+
export declare function validateAttachmentFile(file: File, maxSizeBytes?: number): void;
|
|
8
|
+
/**
|
|
9
|
+
* Backward-compatible image validator used by older components/stories.
|
|
10
|
+
*/
|
|
11
|
+
export declare function validateImageFile(file: File, maxSizeBytes?: number): void;
|
|
12
|
+
/**
|
|
13
|
+
* Converts a file to base64 string (without data URL prefix).
|
|
14
|
+
* Prefers FileReader data URLs, then falls back to buffer-based encoding.
|
|
15
|
+
*/
|
|
16
|
+
export declare function convertToBase64(file: File): Promise<string>;
|
|
17
|
+
/**
|
|
18
|
+
* Creates a data URL from base64 string and MIME type
|
|
19
|
+
*/
|
|
20
|
+
export declare function createDataUrl(base64: string, mimeType: string): string;
|
|
21
|
+
/**
|
|
22
|
+
* Formats file size in human-readable format
|
|
23
|
+
*/
|
|
24
|
+
export declare function formatFileSize(bytes: number): string;
|
|
25
|
+
/**
|
|
26
|
+
* Validates multiple files don't exceed count limit
|
|
27
|
+
* @throws Error if count exceeds limit
|
|
28
|
+
*/
|
|
29
|
+
export declare function validateFileCount(currentCount: number, newCount: number, maxCount?: number): void;
|
|
30
|
+
import { File } from '../icons';
|
|
31
|
+
export interface FileVisual {
|
|
32
|
+
/** Phosphor icon component */
|
|
33
|
+
icon: typeof File;
|
|
34
|
+
/** Tailwind text-color classes for the icon (light + dark) */
|
|
35
|
+
iconColor: string;
|
|
36
|
+
/** Tailwind background classes for the icon container (light + dark) */
|
|
37
|
+
bgColor: string;
|
|
38
|
+
/** Short label (PDF, CSV, XLS, etc.) */
|
|
39
|
+
label: string;
|
|
40
|
+
}
|
|
41
|
+
/**
|
|
42
|
+
* Resolves visual metadata (icon, colors, label) for a file based on
|
|
43
|
+
* its MIME type and/or filename. Single source of truth used by
|
|
44
|
+
* AttachmentGrid, SessionArtifactList, DownloadCard, etc.
|
|
45
|
+
*/
|
|
46
|
+
export declare function getFileVisual(mimeType?: string, filename?: string): FileVisual;
|
|
47
|
+
/** Chart-specific visual (not mime-based, used for artifact type = 'chart') */
|
|
48
|
+
export declare const CHART_VISUAL: FileVisual;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Normalizes common LaTeX delimiters used by LLMs into remark-math compatible
|
|
3
|
+
* delimiters while preserving fenced and inline code sections.
|
|
4
|
+
*
|
|
5
|
+
* Supported conversions:
|
|
6
|
+
* - \[ ... \] -> $$ ... $$
|
|
7
|
+
* - \( ... \) -> $ ... $
|
|
8
|
+
*/
|
|
9
|
+
export declare function normalizeLatexDelimiters(markdown: string): string;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Normalizes partially-streamed markdown so that react-markdown
|
|
3
|
+
* can render it without layout artifacts (e.g. an unclosed code fence
|
|
4
|
+
* turning the rest of the message into a code block).
|
|
5
|
+
*
|
|
6
|
+
* Called on every streaming content update — kept intentionally cheap (O(lines)).
|
|
7
|
+
*/
|
|
8
|
+
export declare function normalizeStreamingMarkdown(text: string): string;
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Shared validation utilities for QuestionForm components
|
|
3
|
+
*/
|
|
4
|
+
import type { Question, QuestionAnswerData, QuestionAnswers } from '../types';
|
|
5
|
+
/**
|
|
6
|
+
* Checks if a question has been answered.
|
|
7
|
+
* A question is answered if it has at least one selected option OR custom text.
|
|
8
|
+
*/
|
|
9
|
+
export declare function isQuestionAnswered(data: QuestionAnswerData | undefined): boolean;
|
|
10
|
+
/**
|
|
11
|
+
* Validates that all questions are answered and custom text is valid.
|
|
12
|
+
* Returns null if valid, or an error message string if invalid.
|
|
13
|
+
*
|
|
14
|
+
* @param questions - Array of questions to validate
|
|
15
|
+
* @param answers - Map of question IDs to answer data
|
|
16
|
+
* @param t - Optional translation function for error messages
|
|
17
|
+
*/
|
|
18
|
+
export declare function validateAnswers(questions: Question[], answers: QuestionAnswers, t?: (key: string, params?: Record<string, string | number | boolean>) => string): string | null;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import type { Session, SessionGroup } from '../types';
|
|
2
|
+
/**
|
|
3
|
+
* Groups chat sessions by date relative to today
|
|
4
|
+
* Categories: Today, Yesterday, Last 7 Days, Last 30 Days, Older
|
|
5
|
+
* Sessions within each group are sorted by updatedAt (most recent first)
|
|
6
|
+
*/
|
|
7
|
+
export declare function groupSessionsByDate(sessions: Session[], t?: (key: string) => string): SessionGroup[];
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* SSE stream parser for consuming Server-Sent Events.
|
|
3
|
+
*/
|
|
4
|
+
import type { StreamChunk, StreamEvent } from '../types';
|
|
5
|
+
export interface SSEEvent {
|
|
6
|
+
type: string;
|
|
7
|
+
content?: string;
|
|
8
|
+
error?: string;
|
|
9
|
+
sessionId?: string;
|
|
10
|
+
toolName?: string;
|
|
11
|
+
toolCallId?: string;
|
|
12
|
+
durationMs?: number;
|
|
13
|
+
success?: boolean;
|
|
14
|
+
[key: string]: unknown;
|
|
15
|
+
}
|
|
16
|
+
/**
|
|
17
|
+
* Parses an SSE stream and yields parsed JSON events.
|
|
18
|
+
*/
|
|
19
|
+
export declare function parseSSEStream(reader: ReadableStreamDefaultReader<Uint8Array>): AsyncGenerator<SSEEvent, void, unknown>;
|
|
20
|
+
/**
|
|
21
|
+
* Parses BiChat SSE stream with normalization and terminal event guarantee.
|
|
22
|
+
*
|
|
23
|
+
* Guarantees that the generator always yields a terminal event (`done` or
|
|
24
|
+
* `error`) as its last item — even when the underlying stream closes silently
|
|
25
|
+
* without one.
|
|
26
|
+
*/
|
|
27
|
+
export declare function parseBichatStream(reader: ReadableStreamDefaultReader<Uint8Array>): AsyncGenerator<StreamChunk, void, unknown>;
|
|
28
|
+
/**
|
|
29
|
+
* Type-safe version of `parseBichatStream` that yields `StreamEvent`
|
|
30
|
+
* discriminated union members instead of the flat `StreamChunk`.
|
|
31
|
+
*
|
|
32
|
+
* Use this in new code for proper type narrowing on `event.type`.
|
|
33
|
+
*/
|
|
34
|
+
export declare function parseBichatStreamEvents(reader: ReadableStreamDefaultReader<Uint8Array>): AsyncGenerator<StreamEvent, void, unknown>;
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import type { RenderTableData } from '../types';
|
|
2
|
+
/**
|
|
3
|
+
* Parses RenderTableData from a record (e.g. artifact metadata from render_table tool).
|
|
4
|
+
*/
|
|
5
|
+
export declare function parseRenderTableDataFromMetadata(metadata: Record<string, unknown>, fallbackId: string): RenderTableData | null;
|
|
6
|
+
export declare function parseRenderTableDataFromJsonString(json: string, fallbackId: string): RenderTableData | null;
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Utilities for splitting accumulated assistant content into the distinct
|
|
3
|
+
* text blocks the server emitted.
|
|
4
|
+
*
|
|
5
|
+
* Background: the executor interleaves text with tool calls within one
|
|
6
|
+
* turn — `text → tool_call → text → tool_call → final_text`. Before the
|
|
7
|
+
* backend emitted `text_block_end` markers (iota-uz/iota-sdk#732 M1),
|
|
8
|
+
* all text segments collapsed into one paragraph on the client. Now the
|
|
9
|
+
* server emits a `text_block_end` event before each tool_start and at
|
|
10
|
+
* snapshot time carries byte offsets in `partialMetadata.text_block_offsets`.
|
|
11
|
+
*
|
|
12
|
+
* `splitIntoTextBlocks` is the client-side inverse: given the
|
|
13
|
+
* accumulated content string and the ordered list of byte offsets that
|
|
14
|
+
* mark segment ends, return one entry per segment. The trailing un-closed
|
|
15
|
+
* segment (if any) is included as the last entry.
|
|
16
|
+
*/
|
|
17
|
+
export interface AssistantTextBlock {
|
|
18
|
+
/** Zero-based index matching the seq carried on text_block_end events. */
|
|
19
|
+
seq: number;
|
|
20
|
+
/** Markdown source for this segment. */
|
|
21
|
+
content: string;
|
|
22
|
+
}
|
|
23
|
+
/**
|
|
24
|
+
* Split an accumulated assistant content string into blocks using byte
|
|
25
|
+
* offsets emitted by the server. Offsets are EXCLUSIVE end markers —
|
|
26
|
+
* i.e. `offsets[0]` is the length of block 0.
|
|
27
|
+
*
|
|
28
|
+
* - When `offsets` is empty or undefined, returns a single block with
|
|
29
|
+
* the full content.
|
|
30
|
+
* - When offsets are provided but content is shorter than the last
|
|
31
|
+
* offset (e.g. stale metadata), offsets beyond the content length are
|
|
32
|
+
* clamped so no crash propagates up.
|
|
33
|
+
* - Trailing content after the last offset is included as an extra
|
|
34
|
+
* block (the un-closed segment during streaming / the final segment
|
|
35
|
+
* after the last tool call).
|
|
36
|
+
*/
|
|
37
|
+
export declare function splitIntoTextBlocks(content: string, offsets?: ReadonlyArray<number> | null): AssistantTextBlock[];
|
|
38
|
+
/**
|
|
39
|
+
* Normalise partialMetadata.text_block_offsets from a StreamSnapshotPayload
|
|
40
|
+
* into a number[]. Guards against malformed server data (non-array,
|
|
41
|
+
* non-numeric entries) so UI code never has to think about shapes.
|
|
42
|
+
*/
|
|
43
|
+
export declare function readTextBlockOffsets(partialMetadata?: Record<string, unknown> | null): number[];
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Tool label resolution for the Activity Trace.
|
|
3
|
+
*
|
|
4
|
+
* Convention: `BiChat.Tools.{toolName}` for SDK-provided tools.
|
|
5
|
+
* Upstream consumers can extend with their own prefix (e.g., `Ali.Tools.{customTool}`).
|
|
6
|
+
*/
|
|
7
|
+
type TranslateFn = (key: string, params?: Record<string, string | number | boolean>) => string;
|
|
8
|
+
/**
|
|
9
|
+
* Resolve a human-readable label for a tool invocation.
|
|
10
|
+
*
|
|
11
|
+
* Lookup order:
|
|
12
|
+
* 1. Consumer prefix (if provided), e.g. `Ali.Tools.custom_tool`
|
|
13
|
+
* 2. SDK default prefix `BiChat.Tools.{name}`
|
|
14
|
+
* 3. Fallback: humanise the raw tool name
|
|
15
|
+
*/
|
|
16
|
+
export declare function getToolLabel(t: TranslateFn, name: string, args?: string, prefix?: string): string;
|
|
17
|
+
export {};
|
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
import type {
|
|
2
|
-
import type { ClientRouteContext } from './route';
|
|
1
|
+
import type { ClientRouteContext } from './bootstrap';
|
|
3
2
|
import type { SessionService } from './transport';
|
|
4
3
|
export interface StandardAppletContext {
|
|
5
4
|
config: {
|
|
@@ -36,17 +35,4 @@ export declare function biChatHTTPConfigFromRoute<TContext extends StandardApple
|
|
|
36
35
|
rpcTimeoutMs?: number;
|
|
37
36
|
streamConnectTimeoutMs?: number;
|
|
38
37
|
}): BiChatHTTPConfig;
|
|
39
|
-
|
|
40
|
-
windowKey: string;
|
|
41
|
-
context?: TContext;
|
|
42
|
-
}>>;
|
|
43
|
-
/**
|
|
44
|
-
* Bridges the standard route bootstrap into @iota-uz/sdk's AppletProvider
|
|
45
|
-
* `context` prop. No window.__APPLET_CONTEXT__ compatibility global is written.
|
|
46
|
-
*/
|
|
47
|
-
export declare function AppletRouteBridge<TContext extends StandardAppletContext>({ provider: Provider, route, children, }: PropsWithChildren<{
|
|
48
|
-
provider: ExplicitAppletProvider<TContext>;
|
|
49
|
-
route: ClientRouteContext<StandardAppletInitial<TContext>>;
|
|
50
|
-
}>): import("react/jsx-runtime").JSX.Element;
|
|
51
|
-
export {};
|
|
52
|
-
//# sourceMappingURL=applet.d.ts.map
|
|
38
|
+
//# sourceMappingURL=bichat-config.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"bichat-config.d.ts","sourceRoot":"","sources":["../src/bichat-config.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,aAAa,CAAA;AACrD,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,aAAa,CAAA;AAEjD,MAAM,WAAW,qBAAqB;IACpC,MAAM,EAAE;QACN,QAAQ,EAAE,MAAM,CAAA;QAChB,aAAa,EAAE,MAAM,CAAA;QACrB,cAAc,CAAC,EAAE,MAAM,CAAA;QACvB,cAAc,CAAC,EAAE,MAAM,CAAA;QACvB,cAAc,CAAC,EAAE,MAAM,CAAA;QACvB,SAAS,CAAC,EAAE,MAAM,CAAA;KACnB,CAAA;IACD,OAAO,CAAC,EAAE;QAAE,SAAS,CAAC,EAAE,MAAM,CAAA;KAAE,CAAA;IAChC,IAAI,CAAC,EAAE,OAAO,CAAA;IACd,MAAM,CAAC,EAAE,OAAO,CAAA;IAChB,MAAM,CAAC,EAAE,OAAO,CAAA;IAChB,UAAU,CAAC,EAAE,OAAO,CAAA;CACrB;AAED,MAAM,WAAW,qBAAqB,CAAC,QAAQ,SAAS,qBAAqB,GAAG,qBAAqB;IACnG,aAAa,EAAE,QAAQ,CAAA;CACxB;AAED,MAAM,WAAW,gBAAgB;IAC/B,OAAO,EAAE,MAAM,CAAA;IACf,WAAW,EAAE,MAAM,CAAA;IACnB,cAAc,CAAC,EAAE,MAAM,CAAA;IACvB,cAAc,CAAC,EAAE,MAAM,CAAA;IACvB,SAAS,CAAC,EAAE,MAAM,GAAG,CAAC,MAAM,MAAM,CAAC,CAAA;IACnC,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAA;IAChC,YAAY,CAAC,EAAE,MAAM,CAAA;IACrB,sBAAsB,CAAC,EAAE,MAAM,CAAA;CAChC;AAED,mFAAmF;AACnF,wBAAgB,yBAAyB,CAAC,QAAQ,SAAS,qBAAqB,EAC9E,KAAK,EAAE,kBAAkB,CAAC,qBAAqB,CAAC,QAAQ,CAAC,CAAC,EAC1D,OAAO,CAAC,EAAE,cAAc,EACxB,OAAO,GAAE;IAAE,YAAY,CAAC,EAAE,MAAM,CAAC;IAAC,sBAAsB,CAAC,EAAE,MAAM,CAAA;CAAO,GACvE,gBAAgB,CAclB"}
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
1
|
/** Replaces useHttpDataSourceConfigFromApplet/window globals for client routes. */
|
|
3
2
|
export function biChatHTTPConfigFromRoute(route, session, options = {}) {
|
|
4
3
|
const config = route.initial.appletContext.config;
|
|
@@ -15,10 +14,3 @@ export function biChatHTTPConfigFromRoute(route, session, options = {}) {
|
|
|
15
14
|
...options,
|
|
16
15
|
};
|
|
17
16
|
}
|
|
18
|
-
/**
|
|
19
|
-
* Bridges the standard route bootstrap into @iota-uz/sdk's AppletProvider
|
|
20
|
-
* `context` prop. No window.__APPLET_CONTEXT__ compatibility global is written.
|
|
21
|
-
*/
|
|
22
|
-
export function AppletRouteBridge({ provider: Provider, route, children, }) {
|
|
23
|
-
return _jsx(Provider, { windowKey: "__unused_client_route_context__", context: route.initial.appletContext, children: children });
|
|
24
|
-
}
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
export declare const SDK_RELEASE_VERSION = "0.
|
|
2
|
-
export declare const SDK_SOURCE_COMMIT = "
|
|
1
|
+
export declare const SDK_RELEASE_VERSION = "0.22.0";
|
|
2
|
+
export declare const SDK_SOURCE_COMMIT = "30b1df81bd53c837c80ad9638554104d2faefc24";
|
|
3
3
|
export declare const SDK_PROTOCOL_VERSION = "1.0.0";
|
|
4
4
|
export declare const SDK_IDENTITY: Readonly<{
|
|
5
|
-
releaseVersion: "0.
|
|
6
|
-
sourceCommit: "
|
|
5
|
+
releaseVersion: "0.22.0";
|
|
6
|
+
sourceCommit: "30b1df81bd53c837c80ad9638554104d2faefc24";
|
|
7
7
|
protocolVersion: "1.0.0";
|
|
8
8
|
}>;
|
|
9
9
|
export interface SDKRuntimeIdentity {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { CLIENT_HOST_PROTOCOL_VERSION } from './protocol';
|
|
2
|
-
export const SDK_RELEASE_VERSION = '0.
|
|
3
|
-
export const SDK_SOURCE_COMMIT = '
|
|
2
|
+
export const SDK_RELEASE_VERSION = '0.22.0';
|
|
3
|
+
export const SDK_SOURCE_COMMIT = '30b1df81bd53c837c80ad9638554104d2faefc24';
|
|
4
4
|
export const SDK_PROTOCOL_VERSION = CLIENT_HOST_PROTOCOL_VERSION;
|
|
5
5
|
export const SDK_IDENTITY = Object.freeze({
|
|
6
6
|
releaseVersion: SDK_RELEASE_VERSION,
|
|
@@ -1,14 +1,17 @@
|
|
|
1
|
-
export * from './
|
|
1
|
+
export * from './bichat-config';
|
|
2
2
|
export * from './bootstrap';
|
|
3
3
|
export * from './cache';
|
|
4
|
+
export * from './draft';
|
|
4
5
|
export * from './errors';
|
|
5
6
|
export * from './identity';
|
|
6
7
|
export * from './navigation';
|
|
7
|
-
export * from './portals';
|
|
8
8
|
export * from './protocol';
|
|
9
|
-
export * from './
|
|
10
|
-
export * from './rpc';
|
|
9
|
+
export * from './rpc-core';
|
|
11
10
|
export * from './services';
|
|
11
|
+
export * from './solid-portals';
|
|
12
|
+
export * from './solid-rpc';
|
|
13
|
+
export * from './solid-streaming';
|
|
14
|
+
export * from './solid';
|
|
12
15
|
export * from './streaming';
|
|
13
16
|
export * from './transport';
|
|
14
17
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,iBAAiB,CAAA;AAC/B,cAAc,aAAa,CAAA;AAC3B,cAAc,SAAS,CAAA;AACvB,cAAc,SAAS,CAAA;AACvB,cAAc,UAAU,CAAA;AACxB,cAAc,YAAY,CAAA;AAC1B,cAAc,cAAc,CAAA;AAC5B,cAAc,YAAY,CAAA;AAC1B,cAAc,YAAY,CAAA;AAC1B,cAAc,YAAY,CAAA;AAC1B,cAAc,iBAAiB,CAAA;AAC/B,cAAc,aAAa,CAAA;AAC3B,cAAc,mBAAmB,CAAA;AACjC,cAAc,SAAS,CAAA;AACvB,cAAc,aAAa,CAAA;AAC3B,cAAc,aAAa,CAAA"}
|
|
@@ -1,13 +1,16 @@
|
|
|
1
|
-
export * from './
|
|
1
|
+
export * from './bichat-config';
|
|
2
2
|
export * from './bootstrap';
|
|
3
3
|
export * from './cache';
|
|
4
|
+
export * from './draft';
|
|
4
5
|
export * from './errors';
|
|
5
6
|
export * from './identity';
|
|
6
7
|
export * from './navigation';
|
|
7
|
-
export * from './portals';
|
|
8
8
|
export * from './protocol';
|
|
9
|
-
export * from './
|
|
10
|
-
export * from './rpc';
|
|
9
|
+
export * from './rpc-core';
|
|
11
10
|
export * from './services';
|
|
11
|
+
export * from './solid-portals';
|
|
12
|
+
export * from './solid-rpc';
|
|
13
|
+
export * from './solid-streaming';
|
|
14
|
+
export * from './solid';
|
|
12
15
|
export * from './streaming';
|
|
13
16
|
export * from './transport';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"solid-index.d.ts","sourceRoot":"","sources":["../src/solid-index.ts"],"names":[],"mappings":"AAAA,cAAc,aAAa,CAAA;AAC3B,cAAc,SAAS,CAAA;AACvB,cAAc,SAAS,CAAA;AACvB,cAAc,UAAU,CAAA;AACxB,cAAc,YAAY,CAAA;AAC1B,cAAc,cAAc,CAAA;AAC5B,cAAc,YAAY,CAAA;AAC1B,cAAc,YAAY,CAAA;AAC1B,cAAc,YAAY,CAAA;AAC1B,cAAc,SAAS,CAAA;AACvB,cAAc,iBAAiB,CAAA;AAC/B,cAAc,aAAa,CAAA;AAC3B,cAAc,mBAAmB,CAAA;AACjC,cAAc,aAAa,CAAA;AAC3B,cAAc,aAAa,CAAA"}
|
|
1
|
+
{"version":3,"file":"solid-index.d.ts","sourceRoot":"","sources":["../src/solid-index.ts"],"names":[],"mappings":"AAAA,cAAc,iBAAiB,CAAA;AAC/B,cAAc,aAAa,CAAA;AAC3B,cAAc,SAAS,CAAA;AACvB,cAAc,SAAS,CAAA;AACvB,cAAc,UAAU,CAAA;AACxB,cAAc,YAAY,CAAA;AAC1B,cAAc,cAAc,CAAA;AAC5B,cAAc,YAAY,CAAA;AAC1B,cAAc,YAAY,CAAA;AAC1B,cAAc,YAAY,CAAA;AAC1B,cAAc,SAAS,CAAA;AACvB,cAAc,iBAAiB,CAAA;AAC/B,cAAc,aAAa,CAAA;AAC3B,cAAc,mBAAmB,CAAA;AACjC,cAAc,aAAa,CAAA;AAC3B,cAAc,aAAa,CAAA"}
|