@assistant-ui/core 0.3.18 → 0.3.20
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/adapters/attachment.d.ts +9 -10
- package/dist/adapters/attachment.d.ts.map +1 -1
- package/dist/adapters/attachment.js +2 -1
- package/dist/adapters/attachment.js.map +1 -1
- package/dist/adapters/directive-formatter.d.ts +1 -2
- package/dist/adapters/directive-formatter.d.ts.map +1 -1
- package/dist/adapters/feedback.d.ts +2 -2
- package/dist/adapters/feedback.d.ts.map +1 -1
- package/dist/adapters/speech.d.ts +6 -7
- package/dist/adapters/speech.d.ts.map +1 -1
- package/dist/adapters/speech.js +13 -3
- package/dist/adapters/speech.js.map +1 -1
- package/dist/adapters/suggestion.d.ts +5 -6
- package/dist/adapters/suggestion.d.ts.map +1 -1
- package/dist/adapters/thread-history.d.ts +10 -7
- package/dist/adapters/thread-history.d.ts.map +1 -1
- package/dist/adapters/trigger.d.ts +1 -2
- package/dist/adapters/trigger.d.ts.map +1 -1
- package/dist/adapters/voice.d.ts +5 -6
- package/dist/adapters/voice.d.ts.map +1 -1
- package/dist/index.d.ts +2 -2
- package/dist/index.js.map +1 -1
- package/dist/internal/duplicate-detection.d.ts +1 -2
- package/dist/internal/duplicate-detection.d.ts.map +1 -1
- package/dist/internal.d.ts +1 -1
- package/dist/model-context/frame/host.d.ts +1 -2
- package/dist/model-context/frame/host.d.ts.map +1 -1
- package/dist/model-context/frame/host.js +26 -11
- package/dist/model-context/frame/host.js.map +1 -1
- package/dist/model-context/frame/provider.d.ts +1 -2
- package/dist/model-context/frame/provider.d.ts.map +1 -1
- package/dist/model-context/frame/types.d.ts +5 -6
- package/dist/model-context/frame/types.d.ts.map +1 -1
- package/dist/model-context/interactable-composer-metadata.d.ts +9 -10
- package/dist/model-context/interactable-composer-metadata.d.ts.map +1 -1
- package/dist/model-context/interactable-composer-metadata.js +11 -9
- package/dist/model-context/interactable-composer-metadata.js.map +1 -1
- package/dist/model-context/registry-handles.d.ts +3 -4
- package/dist/model-context/registry-handles.d.ts.map +1 -1
- package/dist/model-context/registry.d.ts +1 -2
- package/dist/model-context/registry.d.ts.map +1 -1
- package/dist/model-context/tool-call-text.d.ts +2 -3
- package/dist/model-context/tool-call-text.d.ts.map +1 -1
- package/dist/model-context/tool.d.ts +2 -3
- package/dist/model-context/tool.d.ts.map +1 -1
- package/dist/model-context/types.d.ts +8 -9
- package/dist/model-context/types.d.ts.map +1 -1
- package/dist/react/AssistantProvider.d.ts +3 -4
- package/dist/react/AssistantProvider.d.ts.map +1 -1
- package/dist/react/AssistantRuntimeProvider.d.ts +1 -2
- package/dist/react/AssistantRuntimeProvider.d.ts.map +1 -1
- package/dist/react/RuntimeAdapter.d.ts +2 -3
- package/dist/react/RuntimeAdapter.d.ts.map +1 -1
- package/dist/react/adapters/LocalStorageThreadListAdapter.d.ts +4 -5
- package/dist/react/adapters/LocalStorageThreadListAdapter.d.ts.map +1 -1
- package/dist/react/adapters/LocalStorageThreadListAdapter.js +43 -19
- package/dist/react/adapters/LocalStorageThreadListAdapter.js.map +1 -1
- package/dist/react/adapters/TitleGenerationAdapter.d.ts +2 -3
- package/dist/react/adapters/TitleGenerationAdapter.d.ts.map +1 -1
- package/dist/react/client/AdaptedRemoteThread.d.ts +1 -2
- package/dist/react/client/AdaptedRemoteThread.d.ts.map +1 -1
- package/dist/react/client/DataRenderers.d.ts +1 -2
- package/dist/react/client/DataRenderers.d.ts.map +1 -1
- package/dist/react/client/DataRenderers.js +20 -15
- package/dist/react/client/DataRenderers.js.map +1 -1
- package/dist/react/client/InMemoryThreadList.d.ts +3 -4
- package/dist/react/client/InMemoryThreadList.d.ts.map +1 -1
- package/dist/react/client/Interactables.d.ts +1 -2
- package/dist/react/client/Interactables.d.ts.map +1 -1
- package/dist/react/client/Interactables.js +11 -5
- package/dist/react/client/Interactables.js.map +1 -1
- package/dist/react/client/RemoteThreadList.d.ts +2 -3
- package/dist/react/client/RemoteThreadList.d.ts.map +1 -1
- package/dist/react/client/RemoteThreadList.js +3 -2
- package/dist/react/client/RemoteThreadList.js.map +1 -1
- package/dist/react/client/Tools.d.ts +2 -2
- package/dist/react/client/Tools.d.ts.map +1 -1
- package/dist/react/client/interactable-model-context.d.ts +2 -3
- package/dist/react/client/interactable-model-context.d.ts.map +1 -1
- package/dist/react/client/interactable-model-context.js +3 -2
- package/dist/react/client/interactable-model-context.js.map +1 -1
- package/dist/react/index.d.ts +2 -2
- package/dist/react/index.js +2 -2
- package/dist/react/interactables-legacy/Interactables.d.ts +1 -2
- package/dist/react/interactables-legacy/Interactables.d.ts.map +1 -1
- package/dist/react/interactables-legacy/interactable-model-context.d.ts +2 -3
- package/dist/react/interactables-legacy/interactable-model-context.d.ts.map +1 -1
- package/dist/react/interactables-legacy/scopes.d.ts +9 -10
- package/dist/react/interactables-legacy/scopes.d.ts.map +1 -1
- package/dist/react/interactables-legacy/useAssistantInteractable.d.ts +2 -3
- package/dist/react/interactables-legacy/useAssistantInteractable.d.ts.map +1 -1
- package/dist/react/interactables-legacy/useAssistantInteractable.js +3 -0
- package/dist/react/interactables-legacy/useAssistantInteractable.js.map +1 -1
- package/dist/react/interactables-legacy/useInteractableState.d.ts +1 -2
- package/dist/react/interactables-legacy/useInteractableState.d.ts.map +1 -1
- package/dist/react/interactables-shared/useInteractablePersistenceQueue.d.ts +1 -2
- package/dist/react/interactables-shared/useInteractablePersistenceQueue.d.ts.map +1 -1
- package/dist/react/model-context/define-mcp-toolkit.d.ts +4 -5
- package/dist/react/model-context/define-mcp-toolkit.d.ts.map +1 -1
- package/dist/react/model-context/define-toolkit.d.ts +2 -3
- package/dist/react/model-context/define-toolkit.d.ts.map +1 -1
- package/dist/react/model-context/external-tool.d.ts +1 -2
- package/dist/react/model-context/external-tool.d.ts.map +1 -1
- package/dist/react/model-context/human-tool.d.ts +3 -4
- package/dist/react/model-context/human-tool.d.ts.map +1 -1
- package/dist/react/model-context/interactableTool.d.ts +3 -4
- package/dist/react/model-context/interactableTool.d.ts.map +1 -1
- package/dist/react/model-context/makeAssistantDataUI.d.ts +2 -3
- package/dist/react/model-context/makeAssistantDataUI.d.ts.map +1 -1
- package/dist/react/model-context/makeAssistantTool.d.ts +2 -3
- package/dist/react/model-context/makeAssistantTool.d.ts.map +1 -1
- package/dist/react/model-context/makeAssistantToolUI.d.ts +2 -3
- package/dist/react/model-context/makeAssistantToolUI.d.ts.map +1 -1
- package/dist/react/model-context/provider-tool.d.ts +2 -3
- package/dist/react/model-context/provider-tool.d.ts.map +1 -1
- package/dist/react/model-context/stub-tool.d.ts +1 -2
- package/dist/react/model-context/stub-tool.d.ts.map +1 -1
- package/dist/react/model-context/toolbox.d.ts +9 -10
- package/dist/react/model-context/toolbox.d.ts.map +1 -1
- package/dist/react/model-context/useAssistantContext.d.ts +2 -2
- package/dist/react/model-context/useAssistantContext.d.ts.map +1 -1
- package/dist/react/model-context/useAssistantDataUI.d.ts +2 -3
- package/dist/react/model-context/useAssistantDataUI.d.ts.map +1 -1
- package/dist/react/model-context/useAssistantInstructions.d.ts +2 -2
- package/dist/react/model-context/useAssistantInstructions.d.ts.map +1 -1
- package/dist/react/model-context/useAssistantTool.d.ts +2 -3
- package/dist/react/model-context/useAssistantTool.d.ts.map +1 -1
- package/dist/react/model-context/useAssistantToolUI.d.ts +2 -3
- package/dist/react/model-context/useAssistantToolUI.d.ts.map +1 -1
- package/dist/react/model-context/useAuiToolOverrides.d.ts +1 -2
- package/dist/react/model-context/useAuiToolOverrides.d.ts.map +1 -1
- package/dist/react/model-context/useInlineRender.d.ts +1 -2
- package/dist/react/model-context/useInlineRender.d.ts.map +1 -1
- package/dist/react/model-context/useInteractable.d.ts +4 -5
- package/dist/react/model-context/useInteractable.d.ts.map +1 -1
- package/dist/react/model-context/useInteractable.js +4 -1
- package/dist/react/model-context/useInteractable.js.map +1 -1
- package/dist/react/model-context/useInteractableState.d.ts +1 -2
- package/dist/react/model-context/useInteractableState.d.ts.map +1 -1
- package/dist/react/model-context/useInteractableVersions.d.ts +1 -2
- package/dist/react/model-context/useInteractableVersions.d.ts.map +1 -1
- package/dist/react/model-context/useInteractableVersions.js +1 -1
- package/dist/react/model-context/useToolArgsStatus.d.ts +2 -3
- package/dist/react/model-context/useToolArgsStatus.d.ts.map +1 -1
- package/dist/react/primitive-hooks/useActionBarCopy.d.ts +2 -3
- package/dist/react/primitive-hooks/useActionBarCopy.d.ts.map +1 -1
- package/dist/react/primitive-hooks/useActionBarEdit.d.ts +1 -2
- package/dist/react/primitive-hooks/useActionBarEdit.d.ts.map +1 -1
- package/dist/react/primitive-hooks/useActionBarFeedback.d.ts +2 -3
- package/dist/react/primitive-hooks/useActionBarFeedback.d.ts.map +1 -1
- package/dist/react/primitive-hooks/useActionBarReload.d.ts +1 -2
- package/dist/react/primitive-hooks/useActionBarReload.d.ts.map +1 -1
- package/dist/react/primitive-hooks/useActionBarSpeak.d.ts +1 -2
- package/dist/react/primitive-hooks/useActionBarSpeak.d.ts.map +1 -1
- package/dist/react/primitive-hooks/useActionBarStopSpeaking.d.ts +1 -2
- package/dist/react/primitive-hooks/useActionBarStopSpeaking.d.ts.map +1 -1
- package/dist/react/primitive-hooks/useBranchPickerNext.d.ts +1 -2
- package/dist/react/primitive-hooks/useBranchPickerNext.d.ts.map +1 -1
- package/dist/react/primitive-hooks/useBranchPickerPrevious.d.ts +1 -2
- package/dist/react/primitive-hooks/useBranchPickerPrevious.d.ts.map +1 -1
- package/dist/react/primitive-hooks/useComposerAddAttachment.d.ts +1 -2
- package/dist/react/primitive-hooks/useComposerAddAttachment.d.ts.map +1 -1
- package/dist/react/primitive-hooks/useComposerCancel.d.ts +1 -2
- package/dist/react/primitive-hooks/useComposerCancel.d.ts.map +1 -1
- package/dist/react/primitive-hooks/useComposerDictate.d.ts +1 -2
- package/dist/react/primitive-hooks/useComposerDictate.d.ts.map +1 -1
- package/dist/react/primitive-hooks/useComposerSend.d.ts +1 -2
- package/dist/react/primitive-hooks/useComposerSend.d.ts.map +1 -1
- package/dist/react/primitive-hooks/useEditComposerCancel.d.ts +1 -2
- package/dist/react/primitive-hooks/useEditComposerCancel.d.ts.map +1 -1
- package/dist/react/primitive-hooks/useEditComposerSend.d.ts +1 -2
- package/dist/react/primitive-hooks/useEditComposerSend.d.ts.map +1 -1
- package/dist/react/primitive-hooks/useMessageBranching.d.ts +1 -2
- package/dist/react/primitive-hooks/useMessageBranching.d.ts.map +1 -1
- package/dist/react/primitive-hooks/useMessageError.d.ts +1 -2
- package/dist/react/primitive-hooks/useMessageError.d.ts.map +1 -1
- package/dist/react/primitive-hooks/useMessageReload.d.ts +1 -2
- package/dist/react/primitive-hooks/useMessageReload.d.ts.map +1 -1
- package/dist/react/primitive-hooks/useSuggestionTrigger.d.ts +2 -3
- package/dist/react/primitive-hooks/useSuggestionTrigger.d.ts.map +1 -1
- package/dist/react/primitive-hooks/useThreadIsEmpty.d.ts +1 -2
- package/dist/react/primitive-hooks/useThreadIsEmpty.d.ts.map +1 -1
- package/dist/react/primitive-hooks/useThreadIsRunning.d.ts +1 -2
- package/dist/react/primitive-hooks/useThreadIsRunning.d.ts.map +1 -1
- package/dist/react/primitive-hooks/useThreadListItemArchive.d.ts +1 -2
- package/dist/react/primitive-hooks/useThreadListItemArchive.d.ts.map +1 -1
- package/dist/react/primitive-hooks/useThreadListItemDelete.d.ts +1 -2
- package/dist/react/primitive-hooks/useThreadListItemDelete.d.ts.map +1 -1
- package/dist/react/primitive-hooks/useThreadListItemTrigger.d.ts +1 -2
- package/dist/react/primitive-hooks/useThreadListItemTrigger.d.ts.map +1 -1
- package/dist/react/primitive-hooks/useThreadListItemUnarchive.d.ts +1 -2
- package/dist/react/primitive-hooks/useThreadListItemUnarchive.d.ts.map +1 -1
- package/dist/react/primitive-hooks/useThreadListLoadMore.d.ts +1 -2
- package/dist/react/primitive-hooks/useThreadListLoadMore.d.ts.map +1 -1
- package/dist/react/primitive-hooks/useThreadListNew.d.ts +1 -2
- package/dist/react/primitive-hooks/useThreadListNew.d.ts.map +1 -1
- package/dist/react/primitive-hooks/useThreadMessageIds.d.ts +1 -2
- package/dist/react/primitive-hooks/useThreadMessageIds.d.ts.map +1 -1
- package/dist/react/primitive-hooks/useThreadMessages.d.ts +1 -2
- package/dist/react/primitive-hooks/useThreadMessages.d.ts.map +1 -1
- package/dist/react/primitive-hooks/useVoice.d.ts +3 -4
- package/dist/react/primitive-hooks/useVoice.d.ts.map +1 -1
- package/dist/react/primitives/chainOfThought/ChainOfThoughtParts.d.ts +2 -3
- package/dist/react/primitives/chainOfThought/ChainOfThoughtParts.d.ts.map +1 -1
- package/dist/react/primitives/composer/ComposerAttachments.d.ts +4 -5
- package/dist/react/primitives/composer/ComposerAttachments.d.ts.map +1 -1
- package/dist/react/primitives/composer/ComposerIf.d.ts +4 -5
- package/dist/react/primitives/composer/ComposerIf.d.ts.map +1 -1
- package/dist/react/primitives/composer/ComposerQueue.d.ts +2 -3
- package/dist/react/primitives/composer/ComposerQueue.d.ts.map +1 -1
- package/dist/react/primitives/generativeUI/GenerativeUI.d.ts +4 -5
- package/dist/react/primitives/generativeUI/GenerativeUI.d.ts.map +1 -1
- package/dist/react/primitives/generativeUI/GenerativeUI.js +27 -28
- package/dist/react/primitives/generativeUI/GenerativeUI.js.map +1 -1
- package/dist/react/primitives/message/MessageAttachments.d.ts +4 -5
- package/dist/react/primitives/message/MessageAttachments.d.ts.map +1 -1
- package/dist/react/primitives/message/MessageGroupedParts.d.ts +13 -5
- package/dist/react/primitives/message/MessageGroupedParts.d.ts.map +1 -1
- package/dist/react/primitives/message/MessageGroupedParts.js +3 -2
- package/dist/react/primitives/message/MessageGroupedParts.js.map +1 -1
- package/dist/react/primitives/message/MessageParts.d.ts +10 -10
- package/dist/react/primitives/message/MessageParts.d.ts.map +1 -1
- package/dist/react/primitives/message/MessageQuote.d.ts +2 -3
- package/dist/react/primitives/message/MessageQuote.d.ts.map +1 -1
- package/dist/react/primitives/messagePart/MessagePartInProgress.d.ts +2 -3
- package/dist/react/primitives/messagePart/MessagePartInProgress.d.ts.map +1 -1
- package/dist/react/primitives/part/PartMessages.d.ts +4 -4
- package/dist/react/primitives/part/PartMessages.d.ts.map +1 -1
- package/dist/react/primitives/part/PartMessages.js +1 -0
- package/dist/react/primitives/part/PartMessages.js.map +1 -1
- package/dist/react/primitives/thread/ThreadMessages.d.ts +7 -8
- package/dist/react/primitives/thread/ThreadMessages.d.ts.map +1 -1
- package/dist/react/primitives/thread/ThreadMessages.js +6 -5
- package/dist/react/primitives/thread/ThreadMessages.js.map +1 -1
- package/dist/react/primitives/thread/ThreadSuggestions.d.ts +5 -6
- package/dist/react/primitives/thread/ThreadSuggestions.d.ts.map +1 -1
- package/dist/react/primitives/threadList/ThreadListItems.d.ts +4 -5
- package/dist/react/primitives/threadList/ThreadListItems.d.ts.map +1 -1
- package/dist/react/primitives/threadListItem/ThreadListItemTitle.d.ts +2 -3
- package/dist/react/primitives/threadListItem/ThreadListItemTitle.d.ts.map +1 -1
- package/dist/react/providers/AttachmentByIndexProvider.d.ts +2 -3
- package/dist/react/providers/AttachmentByIndexProvider.d.ts.map +1 -1
- package/dist/react/providers/ChainOfThoughtByIndicesProvider.d.ts +1 -2
- package/dist/react/providers/ChainOfThoughtByIndicesProvider.d.ts.map +1 -1
- package/dist/react/providers/ChainOfThoughtPartByIndexProvider.d.ts +1 -2
- package/dist/react/providers/ChainOfThoughtPartByIndexProvider.d.ts.map +1 -1
- package/dist/react/providers/MessageByIdProvider.d.ts +1 -2
- package/dist/react/providers/MessageByIdProvider.d.ts.map +1 -1
- package/dist/react/providers/MessageByIndexProvider.d.ts +1 -2
- package/dist/react/providers/MessageByIndexProvider.d.ts.map +1 -1
- package/dist/react/providers/PartByIndexProvider.d.ts +1 -2
- package/dist/react/providers/PartByIndexProvider.d.ts.map +1 -1
- package/dist/react/providers/QueueItemByIndexProvider.d.ts +2 -3
- package/dist/react/providers/QueueItemByIndexProvider.d.ts.map +1 -1
- package/dist/react/providers/ReadonlyThreadProvider.d.ts +2 -3
- package/dist/react/providers/ReadonlyThreadProvider.d.ts.map +1 -1
- package/dist/react/providers/SuggestionByIndexProvider.d.ts +2 -3
- package/dist/react/providers/SuggestionByIndexProvider.d.ts.map +1 -1
- package/dist/react/providers/TextMessagePartProvider.d.ts +1 -2
- package/dist/react/providers/TextMessagePartProvider.d.ts.map +1 -1
- package/dist/react/providers/ThreadListItemByIndexProvider.d.ts +1 -2
- package/dist/react/providers/ThreadListItemByIndexProvider.d.ts.map +1 -1
- package/dist/react/providers/ThreadListItemRuntimeProvider.d.ts +1 -2
- package/dist/react/providers/ThreadListItemRuntimeProvider.d.ts.map +1 -1
- package/dist/react/runtimes/RemoteThreadListHookInstanceManager.d.ts +3 -2
- package/dist/react/runtimes/RemoteThreadListHookInstanceManager.d.ts.map +1 -1
- package/dist/react/runtimes/RemoteThreadListHookInstanceManager.js +17 -7
- package/dist/react/runtimes/RemoteThreadListHookInstanceManager.js.map +1 -1
- package/dist/react/runtimes/RemoteThreadListThreadListRuntimeCore.d.ts +1 -2
- package/dist/react/runtimes/RemoteThreadListThreadListRuntimeCore.d.ts.map +1 -1
- package/dist/react/runtimes/RemoteThreadListThreadListRuntimeCore.js +2 -1
- package/dist/react/runtimes/RemoteThreadListThreadListRuntimeCore.js.map +1 -1
- package/dist/react/runtimes/RemoteThreadResource.d.ts +4 -5
- package/dist/react/runtimes/RemoteThreadResource.d.ts.map +1 -1
- package/dist/react/runtimes/RuntimeAdapterProvider.d.ts +3 -3
- package/dist/react/runtimes/RuntimeAdapterProvider.d.ts.map +1 -1
- package/dist/react/runtimes/assistant-transport/commandQueue.d.ts +2 -3
- package/dist/react/runtimes/assistant-transport/commandQueue.d.ts.map +1 -1
- package/dist/react/runtimes/assistant-transport/replayBoundaryStream.d.ts +3 -4
- package/dist/react/runtimes/assistant-transport/replayBoundaryStream.d.ts.map +1 -1
- package/dist/react/runtimes/assistant-transport/runManager.d.ts +2 -3
- package/dist/react/runtimes/assistant-transport/runManager.d.ts.map +1 -1
- package/dist/react/runtimes/assistant-transport/types.d.ts +17 -18
- package/dist/react/runtimes/assistant-transport/types.d.ts.map +1 -1
- package/dist/react/runtimes/assistant-transport/useAssistantTransportRuntime.d.ts +4 -5
- package/dist/react/runtimes/assistant-transport/useAssistantTransportRuntime.d.ts.map +1 -1
- package/dist/react/runtimes/assistant-transport/useConvertedState.d.ts +1 -2
- package/dist/react/runtimes/assistant-transport/useConvertedState.d.ts.map +1 -1
- package/dist/react/runtimes/assistant-transport/useLatestRef.d.ts +1 -2
- package/dist/react/runtimes/assistant-transport/useLatestRef.d.ts.map +1 -1
- package/dist/react/runtimes/cloud/AssistantCloudThreadHistoryAdapter.d.ts +3 -26
- package/dist/react/runtimes/cloud/AssistantCloudThreadHistoryAdapter.d.ts.map +1 -1
- package/dist/react/runtimes/cloud/AssistantCloudThreadHistoryAdapter.js +152 -378
- package/dist/react/runtimes/cloud/AssistantCloudThreadHistoryAdapter.js.map +1 -1
- package/dist/react/runtimes/cloud/CloudFileAttachmentAdapter.d.ts +2 -2
- package/dist/react/runtimes/cloud/CloudFileAttachmentAdapter.d.ts.map +1 -1
- package/dist/react/runtimes/cloud/CloudFileAttachmentAdapter.js +22 -2
- package/dist/react/runtimes/cloud/CloudFileAttachmentAdapter.js.map +1 -1
- package/dist/react/runtimes/cloud/auiV0.d.ts +51 -18
- package/dist/react/runtimes/cloud/auiV0.d.ts.map +1 -1
- package/dist/react/runtimes/cloud/auiV0.js +125 -17
- package/dist/react/runtimes/cloud/auiV0.js.map +1 -1
- package/dist/react/runtimes/cloud/createCloudThreadListAdapter.d.ts +6 -6
- package/dist/react/runtimes/cloud/createCloudThreadListAdapter.d.ts.map +1 -1
- package/dist/react/runtimes/cloud/createCloudThreadListAdapter.js +4 -0
- package/dist/react/runtimes/cloud/createCloudThreadListAdapter.js.map +1 -1
- package/dist/react/runtimes/cloud/createCloudThreadListAdapterCreateFallback.d.ts +1 -2
- package/dist/react/runtimes/cloud/createCloudThreadListAdapterCreateFallback.d.ts.map +1 -1
- package/dist/react/runtimes/cloud/sdkIdentity.d.ts +5 -0
- package/dist/react/runtimes/cloud/sdkIdentity.d.ts.map +1 -0
- package/dist/react/runtimes/cloud/sdkIdentity.js +9 -0
- package/dist/react/runtimes/cloud/sdkIdentity.js.map +1 -0
- package/dist/react/runtimes/cloud/useCloudThreadListAdapter.d.ts +1 -2
- package/dist/react/runtimes/cloud/useCloudThreadListAdapter.d.ts.map +1 -1
- package/dist/react/runtimes/cloud/useCloudThreadListRuntime.d.ts +1 -2
- package/dist/react/runtimes/cloud/useCloudThreadListRuntime.d.ts.map +1 -1
- package/dist/react/runtimes/createMessageConverter.d.ts +1 -2
- package/dist/react/runtimes/createMessageConverter.d.ts.map +1 -1
- package/dist/react/runtimes/createRuntimeExtras.d.ts +3 -4
- package/dist/react/runtimes/createRuntimeExtras.d.ts.map +1 -1
- package/dist/react/runtimes/external-message-converter.d.ts +14 -4
- package/dist/react/runtimes/external-message-converter.d.ts.map +1 -1
- package/dist/react/runtimes/external-message-converter.js +26 -61
- package/dist/react/runtimes/external-message-converter.js.map +1 -1
- package/dist/react/runtimes/useExternalStoreRuntime.d.ts +1 -2
- package/dist/react/runtimes/useExternalStoreRuntime.d.ts.map +1 -1
- package/dist/react/runtimes/useExternalStoreSharedOptions.d.ts +1 -2
- package/dist/react/runtimes/useExternalStoreSharedOptions.d.ts.map +1 -1
- package/dist/react/runtimes/useLocalRuntime.d.ts +3 -4
- package/dist/react/runtimes/useLocalRuntime.d.ts.map +1 -1
- package/dist/react/runtimes/useRemoteThreadListRuntime.d.ts +1 -2
- package/dist/react/runtimes/useRemoteThreadListRuntime.d.ts.map +1 -1
- package/dist/react/runtimes/useRemoteThreadListRuntime.js +3 -3
- package/dist/react/runtimes/useRemoteThreadListRuntime.js.map +1 -1
- package/dist/react/runtimes/useRuntimeAdapters.d.ts +4 -4
- package/dist/react/runtimes/useRuntimeAdapters.d.ts.map +1 -1
- package/dist/react/runtimes/useStreamingTiming.d.ts +2 -2
- package/dist/react/runtimes/useStreamingTiming.d.ts.map +1 -1
- package/dist/react/types/MessagePartComponentTypes.d.ts +26 -27
- package/dist/react/types/MessagePartComponentTypes.d.ts.map +1 -1
- package/dist/react/types/scopes/dataRenderers.d.ts +3 -4
- package/dist/react/types/scopes/dataRenderers.d.ts.map +1 -1
- package/dist/react/types/scopes/interactables.d.ts +10 -11
- package/dist/react/types/scopes/interactables.d.ts.map +1 -1
- package/dist/react/types/scopes/tools.d.ts +4 -5
- package/dist/react/types/scopes/tools.d.ts.map +1 -1
- package/dist/react/utils/getMessageQuote.d.ts +1 -2
- package/dist/react/utils/getMessageQuote.d.ts.map +1 -1
- package/dist/react/utils/groupParts.d.ts +13 -9
- package/dist/react/utils/groupParts.d.ts.map +1 -1
- package/dist/react/utils/groupParts.js +6 -0
- package/dist/react/utils/groupParts.js.map +1 -1
- package/dist/react/utils/useJSONEqual.d.ts +3 -2
- package/dist/react/utils/useJSONEqual.d.ts.map +1 -1
- package/dist/react/utils/useJSONEqual.js +6 -1
- package/dist/react/utils/useJSONEqual.js.map +1 -1
- package/dist/react/utils/useJSONSchemaDependency.d.ts +6 -0
- package/dist/react/utils/useJSONSchemaDependency.d.ts.map +1 -0
- package/dist/react/utils/useJSONSchemaDependency.js +20 -0
- package/dist/react/utils/useJSONSchemaDependency.js.map +1 -0
- package/dist/runtime/api/assistant-runtime.d.ts +2 -3
- package/dist/runtime/api/assistant-runtime.d.ts.map +1 -1
- package/dist/runtime/api/attachment-runtime.d.ts +6 -7
- package/dist/runtime/api/attachment-runtime.d.ts.map +1 -1
- package/dist/runtime/api/bindings.d.ts +5 -6
- package/dist/runtime/api/bindings.d.ts.map +1 -1
- package/dist/runtime/api/composer-runtime.d.ts +10 -10
- package/dist/runtime/api/composer-runtime.d.ts.map +1 -1
- package/dist/runtime/api/message-part-runtime.d.ts +3 -4
- package/dist/runtime/api/message-part-runtime.d.ts.map +1 -1
- package/dist/runtime/api/message-part-runtime.js +3 -2
- package/dist/runtime/api/message-part-runtime.js.map +1 -1
- package/dist/runtime/api/message-runtime.d.ts +8 -6
- package/dist/runtime/api/message-runtime.d.ts.map +1 -1
- package/dist/runtime/api/message-runtime.js +3 -2
- package/dist/runtime/api/message-runtime.js.map +1 -1
- package/dist/runtime/api/paths.d.ts +6 -7
- package/dist/runtime/api/paths.d.ts.map +1 -1
- package/dist/runtime/api/thread-list-item-runtime.d.ts +8 -8
- package/dist/runtime/api/thread-list-item-runtime.d.ts.map +1 -1
- package/dist/runtime/api/thread-list-runtime.d.ts +4 -5
- package/dist/runtime/api/thread-list-runtime.d.ts.map +1 -1
- package/dist/runtime/api/thread-runtime.d.ts +10 -11
- package/dist/runtime/api/thread-runtime.d.ts.map +1 -1
- package/dist/runtime/api/thread-runtime.js +2 -5
- package/dist/runtime/api/thread-runtime.js.map +1 -1
- package/dist/runtime/base/base-assistant-runtime-core.d.ts +1 -2
- package/dist/runtime/base/base-assistant-runtime-core.d.ts.map +1 -1
- package/dist/runtime/base/base-composer-runtime-core.d.ts +2 -2
- package/dist/runtime/base/base-composer-runtime-core.d.ts.map +1 -1
- package/dist/runtime/base/base-composer-runtime-core.js +46 -10
- package/dist/runtime/base/base-composer-runtime-core.js.map +1 -1
- package/dist/runtime/base/base-thread-runtime-core.d.ts +10 -3
- package/dist/runtime/base/base-thread-runtime-core.d.ts.map +1 -1
- package/dist/runtime/base/base-thread-runtime-core.js +212 -77
- package/dist/runtime/base/base-thread-runtime-core.js.map +1 -1
- package/dist/runtime/base/default-edit-composer-runtime-core.d.ts +1 -2
- package/dist/runtime/base/default-edit-composer-runtime-core.d.ts.map +1 -1
- package/dist/runtime/base/default-edit-composer-runtime-core.js +12 -2
- package/dist/runtime/base/default-edit-composer-runtime-core.js.map +1 -1
- package/dist/runtime/base/default-thread-composer-runtime-core.d.ts +1 -2
- package/dist/runtime/base/default-thread-composer-runtime-core.d.ts.map +1 -1
- package/dist/runtime/base/default-thread-composer-runtime-core.js +7 -1
- package/dist/runtime/base/default-thread-composer-runtime-core.js.map +1 -1
- package/dist/runtime/branch/external-thread-branch-adapter.d.ts +1 -2
- package/dist/runtime/branch/external-thread-branch-adapter.d.ts.map +1 -1
- package/dist/runtime/interfaces/assistant-runtime-core.d.ts +1 -2
- package/dist/runtime/interfaces/assistant-runtime-core.d.ts.map +1 -1
- package/dist/runtime/interfaces/composer-runtime-core.d.ts +10 -11
- package/dist/runtime/interfaces/composer-runtime-core.d.ts.map +1 -1
- package/dist/runtime/interfaces/thread-list-runtime-core.d.ts +4 -5
- package/dist/runtime/interfaces/thread-list-runtime-core.d.ts.map +1 -1
- package/dist/runtime/interfaces/thread-runtime-core.d.ts +23 -16
- package/dist/runtime/interfaces/thread-runtime-core.d.ts.map +1 -1
- package/dist/runtime/queue/external-thread-queue-adapter.d.ts +2 -3
- package/dist/runtime/queue/external-thread-queue-adapter.d.ts.map +1 -1
- package/dist/runtime/queue/message-queue.d.ts +10 -4
- package/dist/runtime/queue/message-queue.d.ts.map +1 -1
- package/dist/runtime/queue/message-queue.js +70 -7
- package/dist/runtime/queue/message-queue.js.map +1 -1
- package/dist/runtime/queue/queue-item.d.ts +2 -3
- package/dist/runtime/queue/queue-item.d.ts.map +1 -1
- package/dist/runtime/utils/abortable-thread-load.d.ts +2 -3
- package/dist/runtime/utils/abortable-thread-load.d.ts.map +1 -1
- package/dist/runtime/utils/attachment-add-operations.d.ts +3 -4
- package/dist/runtime/utils/attachment-add-operations.d.ts.map +1 -1
- package/dist/runtime/utils/auto-status.d.ts +9 -6
- package/dist/runtime/utils/auto-status.d.ts.map +1 -1
- package/dist/runtime/utils/auto-status.js +12 -4
- package/dist/runtime/utils/auto-status.js.map +1 -1
- package/dist/runtime/utils/chat-model-adapter.d.ts +5 -6
- package/dist/runtime/utils/chat-model-adapter.d.ts.map +1 -1
- package/dist/runtime/utils/external-message-conversion.d.ts +26 -15
- package/dist/runtime/utils/external-message-conversion.d.ts.map +1 -1
- package/dist/runtime/utils/external-message-conversion.js +51 -14
- package/dist/runtime/utils/external-message-conversion.js.map +1 -1
- package/dist/runtime/utils/external-store-message.d.ts +4 -5
- package/dist/runtime/utils/external-store-message.d.ts.map +1 -1
- package/dist/runtime/utils/message-repository-session.d.ts +3 -4
- package/dist/runtime/utils/message-repository-session.d.ts.map +1 -1
- package/dist/runtime/utils/message-repository.d.ts +4 -5
- package/dist/runtime/utils/message-repository.d.ts.map +1 -1
- package/dist/runtime/utils/message-repository.js +3 -3
- package/dist/runtime/utils/message-repository.js.map +1 -1
- package/dist/runtime/utils/pending-tool-calls.d.ts +2 -3
- package/dist/runtime/utils/pending-tool-calls.d.ts.map +1 -1
- package/dist/runtime/utils/resolveToolApprovalResponse.d.ts +1 -2
- package/dist/runtime/utils/resolveToolApprovalResponse.d.ts.map +1 -1
- package/dist/runtime/utils/runtime-extras-brand.d.ts +2 -3
- package/dist/runtime/utils/runtime-extras-brand.d.ts.map +1 -1
- package/dist/runtime/utils/stored-message-parts.d.ts +21 -0
- package/dist/runtime/utils/stored-message-parts.d.ts.map +1 -0
- package/dist/runtime/utils/stored-message-parts.js +83 -0
- package/dist/runtime/utils/stored-message-parts.js.map +1 -0
- package/dist/runtime/utils/streaming-timing.d.ts +4 -5
- package/dist/runtime/utils/streaming-timing.d.ts.map +1 -1
- package/dist/runtime/utils/thread-message-like.d.ts +7 -6
- package/dist/runtime/utils/thread-message-like.d.ts.map +1 -1
- package/dist/runtime/utils/thread-message-like.js +4 -2
- package/dist/runtime/utils/thread-message-like.js.map +1 -1
- package/dist/runtime/utils/thread-runtime-lifecycle.d.ts +3 -4
- package/dist/runtime/utils/thread-runtime-lifecycle.d.ts.map +1 -1
- package/dist/runtime/utils/tool-call-tree.d.ts +4 -5
- package/dist/runtime/utils/tool-call-tree.d.ts.map +1 -1
- package/dist/runtimes/assistant-transport/utils.d.ts +1 -2
- package/dist/runtimes/assistant-transport/utils.d.ts.map +1 -1
- package/dist/runtimes/external-store/external-store-adapter.d.ts +9 -6
- package/dist/runtimes/external-store/external-store-adapter.d.ts.map +1 -1
- package/dist/runtimes/external-store/external-store-runtime-core.d.ts +1 -2
- package/dist/runtimes/external-store/external-store-runtime-core.d.ts.map +1 -1
- package/dist/runtimes/external-store/external-store-shared-options.d.ts +2 -3
- package/dist/runtimes/external-store/external-store-shared-options.d.ts.map +1 -1
- package/dist/runtimes/external-store/external-store-thread-list-runtime-core.d.ts +2 -3
- package/dist/runtimes/external-store/external-store-thread-list-runtime-core.d.ts.map +1 -1
- package/dist/runtimes/external-store/external-store-thread-runtime-core.d.ts +4 -3
- package/dist/runtimes/external-store/external-store-thread-runtime-core.d.ts.map +1 -1
- package/dist/runtimes/external-store/external-store-thread-runtime-core.js +36 -6
- package/dist/runtimes/external-store/external-store-thread-runtime-core.js.map +1 -1
- package/dist/runtimes/external-store/thread-message-converter.d.ts +2 -3
- package/dist/runtimes/external-store/thread-message-converter.d.ts.map +1 -1
- package/dist/runtimes/inert/InertThreadRuntimeCore.d.ts +2 -3
- package/dist/runtimes/inert/InertThreadRuntimeCore.d.ts.map +1 -1
- package/dist/runtimes/internal.d.ts +1 -1
- package/dist/runtimes/local/local-runtime-core.d.ts +1 -2
- package/dist/runtimes/local/local-runtime-core.d.ts.map +1 -1
- package/dist/runtimes/local/local-runtime-options.d.ts +1 -2
- package/dist/runtimes/local/local-runtime-options.d.ts.map +1 -1
- package/dist/runtimes/local/local-thread-list-runtime-core.d.ts +2 -3
- package/dist/runtimes/local/local-thread-list-runtime-core.d.ts.map +1 -1
- package/dist/runtimes/local/local-thread-runtime-core.d.ts +10 -5
- package/dist/runtimes/local/local-thread-runtime-core.d.ts.map +1 -1
- package/dist/runtimes/local/local-thread-runtime-core.js +57 -10
- package/dist/runtimes/local/local-thread-runtime-core.js.map +1 -1
- package/dist/runtimes/local/should-continue.d.ts +1 -2
- package/dist/runtimes/local/should-continue.d.ts.map +1 -1
- package/dist/runtimes/readonly/ReadonlyThreadRuntimeCore.d.ts +1 -2
- package/dist/runtimes/readonly/ReadonlyThreadRuntimeCore.d.ts.map +1 -1
- package/dist/runtimes/remote-thread-list/adapter/in-memory.d.ts +1 -2
- package/dist/runtimes/remote-thread-list/adapter/in-memory.d.ts.map +1 -1
- package/dist/runtimes/remote-thread-list/adapter-changed.d.ts +1 -2
- package/dist/runtimes/remote-thread-list/adapter-changed.d.ts.map +1 -1
- package/dist/runtimes/remote-thread-list/empty-thread-core.d.ts +1 -2
- package/dist/runtimes/remote-thread-list/empty-thread-core.d.ts.map +1 -1
- package/dist/runtimes/remote-thread-list/optimistic-state.d.ts +1 -2
- package/dist/runtimes/remote-thread-list/optimistic-state.d.ts.map +1 -1
- package/dist/runtimes/remote-thread-list/remote-thread-state.d.ts +16 -17
- package/dist/runtimes/remote-thread-list/remote-thread-state.d.ts.map +1 -1
- package/dist/runtimes/remote-thread-list/title-generation.d.ts +7 -8
- package/dist/runtimes/remote-thread-list/title-generation.d.ts.map +1 -1
- package/dist/runtimes/remote-thread-list/title.d.ts +2 -3
- package/dist/runtimes/remote-thread-list/title.d.ts.map +1 -1
- package/dist/runtimes/remote-thread-list/types.d.ts +8 -9
- package/dist/runtimes/remote-thread-list/types.d.ts.map +1 -1
- package/dist/runtimes/tool-invocations/ToolInvocationTracker.d.ts +4 -5
- package/dist/runtimes/tool-invocations/ToolInvocationTracker.d.ts.map +1 -1
- package/dist/runtimes/tool-invocations/ToolInvocationTracker.js +2 -1
- package/dist/runtimes/tool-invocations/ToolInvocationTracker.js.map +1 -1
- package/dist/store/clients/chain-of-thought-client.d.ts +1 -2
- package/dist/store/clients/chain-of-thought-client.d.ts.map +1 -1
- package/dist/store/clients/external-thread.d.ts +3 -4
- package/dist/store/clients/external-thread.d.ts.map +1 -1
- package/dist/store/clients/external-thread.js +256 -211
- package/dist/store/clients/external-thread.js.map +1 -1
- package/dist/store/clients/model-context-client.d.ts +1 -2
- package/dist/store/clients/model-context-client.d.ts.map +1 -1
- package/dist/store/clients/no-op-composer-client.d.ts +1 -2
- package/dist/store/clients/no-op-composer-client.d.ts.map +1 -1
- package/dist/store/clients/runtime-adapter.d.ts +1 -2
- package/dist/store/clients/runtime-adapter.d.ts.map +1 -1
- package/dist/store/clients/single-thread-list.d.ts +1 -2
- package/dist/store/clients/single-thread-list.d.ts.map +1 -1
- package/dist/store/clients/suggestions.d.ts +3 -4
- package/dist/store/clients/suggestions.d.ts.map +1 -1
- package/dist/store/clients/thread-message-client.d.ts +2 -3
- package/dist/store/clients/thread-message-client.d.ts.map +1 -1
- package/dist/store/clients/thread-selection-events.d.ts +1 -2
- package/dist/store/clients/thread-selection-events.d.ts.map +1 -1
- package/dist/store/clients/thread-tasks.d.ts +12 -0
- package/dist/store/clients/thread-tasks.d.ts.map +1 -0
- package/dist/store/clients/thread-tasks.js +69 -0
- package/dist/store/clients/thread-tasks.js.map +1 -0
- package/dist/store/env.d.ts +1 -2
- package/dist/store/env.d.ts.map +1 -1
- package/dist/store/index.d.ts +3 -2
- package/dist/store/index.js +3 -3
- package/dist/store/primitive-predicates.d.ts +11 -12
- package/dist/store/primitive-predicates.d.ts.map +1 -1
- package/dist/store/primitive-predicates.js +4 -4
- package/dist/store/primitive-predicates.js.map +1 -1
- package/dist/store/runtime-clients/attachment-runtime-client.d.ts +1 -2
- package/dist/store/runtime-clients/attachment-runtime-client.d.ts.map +1 -1
- package/dist/store/runtime-clients/composer-runtime-client.d.ts +1 -2
- package/dist/store/runtime-clients/composer-runtime-client.d.ts.map +1 -1
- package/dist/store/runtime-clients/handle-runtime-action.d.ts +1 -2
- package/dist/store/runtime-clients/handle-runtime-action.d.ts.map +1 -1
- package/dist/store/runtime-clients/handle-thread-list-action.d.ts +1 -2
- package/dist/store/runtime-clients/handle-thread-list-action.d.ts.map +1 -1
- package/dist/store/runtime-clients/liveRef.d.ts +1 -2
- package/dist/store/runtime-clients/liveRef.d.ts.map +1 -1
- package/dist/store/runtime-clients/message-part-runtime-client.d.ts +1 -2
- package/dist/store/runtime-clients/message-part-runtime-client.d.ts.map +1 -1
- package/dist/store/runtime-clients/message-runtime-client.d.ts +1 -2
- package/dist/store/runtime-clients/message-runtime-client.d.ts.map +1 -1
- package/dist/store/runtime-clients/thread-list-item-runtime-client.d.ts +1 -2
- package/dist/store/runtime-clients/thread-list-item-runtime-client.d.ts.map +1 -1
- package/dist/store/runtime-clients/thread-list-runtime-client.d.ts +1 -2
- package/dist/store/runtime-clients/thread-list-runtime-client.d.ts.map +1 -1
- package/dist/store/runtime-clients/thread-runtime-client.d.ts +1 -2
- package/dist/store/runtime-clients/thread-runtime-client.d.ts.map +1 -1
- package/dist/store/runtime-clients/thread-runtime-client.js +176 -128
- package/dist/store/runtime-clients/thread-runtime-client.js.map +1 -1
- package/dist/store/runtime-clients/useSubscribable.d.ts +1 -2
- package/dist/store/runtime-clients/useSubscribable.d.ts.map +1 -1
- package/dist/store/scope-registration.d.ts +2 -0
- package/dist/store/scope-registration.d.ts.map +1 -1
- package/dist/store/scopes/attachment.d.ts +4 -5
- package/dist/store/scopes/attachment.d.ts.map +1 -1
- package/dist/store/scopes/chain-of-thought.d.ts +5 -6
- package/dist/store/scopes/chain-of-thought.d.ts.map +1 -1
- package/dist/store/scopes/composer.d.ts +6 -7
- package/dist/store/scopes/composer.d.ts.map +1 -1
- package/dist/store/scopes/message.d.ts +6 -6
- package/dist/store/scopes/message.d.ts.map +1 -1
- package/dist/store/scopes/model-context.d.ts +3 -4
- package/dist/store/scopes/model-context.d.ts.map +1 -1
- package/dist/store/scopes/part.d.ts +4 -5
- package/dist/store/scopes/part.d.ts.map +1 -1
- package/dist/store/scopes/queue-item.d.ts +4 -4
- package/dist/store/scopes/queue-item.d.ts.map +1 -1
- package/dist/store/scopes/suggestion.d.ts +4 -5
- package/dist/store/scopes/suggestion.d.ts.map +1 -1
- package/dist/store/scopes/suggestions.d.ts +5 -6
- package/dist/store/scopes/suggestions.d.ts.map +1 -1
- package/dist/store/scopes/task.d.ts +35 -0
- package/dist/store/scopes/task.d.ts.map +1 -0
- package/dist/store/scopes/task.js +0 -0
- package/dist/store/scopes/thread-list-item.d.ts +5 -6
- package/dist/store/scopes/thread-list-item.d.ts.map +1 -1
- package/dist/store/scopes/thread.d.ts +25 -6
- package/dist/store/scopes/thread.d.ts.map +1 -1
- package/dist/store/scopes/threads.d.ts +4 -5
- package/dist/store/scopes/threads.d.ts.map +1 -1
- package/dist/subscribable/subscribable.d.ts +15 -15
- package/dist/subscribable/subscribable.d.ts.map +1 -1
- package/dist/subscribable/subscribable.js +23 -15
- package/dist/subscribable/subscribable.js.map +1 -1
- package/dist/tests/remote-thread-list-test-helpers.d.ts +5 -6
- package/dist/tests/remote-thread-list-test-helpers.d.ts.map +1 -1
- package/dist/types/attachment.d.ts +9 -10
- package/dist/types/attachment.d.ts.map +1 -1
- package/dist/types/augmentations.d.ts +3 -4
- package/dist/types/augmentations.d.ts.map +1 -1
- package/dist/types/directive.d.ts +2 -3
- package/dist/types/directive.d.ts.map +1 -1
- package/dist/types/error.d.ts +8 -9
- package/dist/types/error.d.ts.map +1 -1
- package/dist/types/index.d.ts +2 -2
- package/dist/types/message.d.ts +53 -44
- package/dist/types/message.d.ts.map +1 -1
- package/dist/types/message.js.map +1 -1
- package/dist/types/quote.d.ts +1 -2
- package/dist/types/quote.d.ts.map +1 -1
- package/dist/types/trigger.d.ts +2 -3
- package/dist/types/trigger.d.ts.map +1 -1
- package/dist/types/unsubscribe.d.ts +1 -2
- package/dist/types/unsubscribe.d.ts.map +1 -1
- package/dist/utils/abortable-iterable.d.ts +2 -3
- package/dist/utils/abortable-iterable.d.ts.map +1 -1
- package/dist/utils/abortable-iterable.js +30 -14
- package/dist/utils/abortable-iterable.js.map +1 -1
- package/dist/utils/composite-context-provider.d.ts +1 -2
- package/dist/utils/composite-context-provider.d.ts.map +1 -1
- package/dist/utils/data-url.d.ts +6 -7
- package/dist/utils/data-url.d.ts.map +1 -1
- package/dist/utils/getGroupStatus.d.ts +17 -2
- package/dist/utils/getGroupStatus.d.ts.map +1 -1
- package/dist/utils/getGroupStatus.js +32 -7
- package/dist/utils/getGroupStatus.js.map +1 -1
- package/dist/utils/id.d.ts +3 -4
- package/dist/utils/id.d.ts.map +1 -1
- package/dist/utils/image-media-type.d.ts +1 -2
- package/dist/utils/image-media-type.d.ts.map +1 -1
- package/dist/utils/invoke-user-callback.d.ts +1 -2
- package/dist/utils/invoke-user-callback.d.ts.map +1 -1
- package/dist/utils/json/is-json-equal.d.ts +1 -2
- package/dist/utils/json/is-json-equal.d.ts.map +1 -1
- package/dist/utils/json/is-json.d.ts +4 -5
- package/dist/utils/json/is-json.d.ts.map +1 -1
- package/dist/utils/json/stable-stringify-tool-args.d.ts +2 -3
- package/dist/utils/json/stable-stringify-tool-args.d.ts.map +1 -1
- package/dist/utils/normalizePartStatus.d.ts +4 -5
- package/dist/utils/normalizePartStatus.d.ts.map +1 -1
- package/dist/utils/notify-event-listeners.d.ts +1 -2
- package/dist/utils/notify-event-listeners.d.ts.map +1 -1
- package/dist/utils/record.d.ts +1 -2
- package/dist/utils/record.d.ts.map +1 -1
- package/dist/utils/silent-runtime-action.d.ts +2 -3
- package/dist/utils/silent-runtime-action.d.ts.map +1 -1
- package/dist/utils/text.d.ts +1 -2
- package/dist/utils/text.d.ts.map +1 -1
- package/dist/utils/wire-media.d.ts +3 -4
- package/dist/utils/wire-media.d.ts.map +1 -1
- package/dist/utils/wire-media.js +2 -2
- package/dist/utils/wire-media.js.map +1 -1
- package/package.json +15 -14
- package/src/adapters/attachment.ts +8 -1
- package/src/adapters/feedback.ts +1 -0
- package/src/adapters/speech.test.ts +236 -0
- package/src/adapters/speech.ts +17 -10
- package/src/adapters/thread-history.ts +3 -0
- package/src/index.ts +1 -0
- package/src/model-context/frame/host.test.ts +113 -1
- package/src/model-context/frame/host.ts +39 -12
- package/src/model-context/frame/provider.test.ts +45 -20
- package/src/model-context/interactable-composer-metadata.test.ts +30 -0
- package/src/model-context/interactable-composer-metadata.ts +10 -10
- package/src/react/RuntimeAdapter.test.ts +4 -1
- package/src/react/adapters/LocalStorageThreadListAdapter.test.ts +361 -0
- package/src/react/adapters/LocalStorageThreadListAdapter.tsx +69 -19
- package/src/react/client/DataRenderers.test.tsx +45 -0
- package/src/react/client/DataRenderers.ts +13 -9
- package/src/react/client/Interactables.test.ts +52 -4
- package/src/react/client/Interactables.ts +7 -1
- package/src/react/client/RemoteThreadList.concurrent.test.tsx +9 -3
- package/src/react/client/RemoteThreadList.test.ts +46 -7
- package/src/react/client/RemoteThreadList.ts +15 -2
- package/src/react/client/interactable-model-context.test.ts +44 -0
- package/src/react/client/interactable-model-context.ts +3 -2
- package/src/react/index.ts +5 -1
- package/src/react/interactables-legacy/Interactables.test.ts +9 -3
- package/src/react/interactables-legacy/useAssistantInteractable.test.tsx +150 -0
- package/src/react/interactables-legacy/useAssistantInteractable.ts +10 -1
- package/src/react/model-context/useInteractable.test.tsx +204 -0
- package/src/react/model-context/useInteractable.ts +3 -0
- package/src/react/primitive-hooks/useActionBarCopy.test.ts +5 -6
- package/src/react/primitive-hooks/useSuggestionTrigger.test.ts +0 -1
- package/src/react/primitives/generativeUI/GenerativeUI.test.tsx +54 -0
- package/src/react/primitives/generativeUI/GenerativeUI.tsx +13 -18
- package/src/react/primitives/message/MessageGroupedParts.test.tsx +99 -0
- package/src/react/primitives/message/MessageGroupedParts.tsx +15 -4
- package/src/react/primitives/part/PartMessages.test.tsx +104 -1
- package/src/react/primitives/part/PartMessages.tsx +1 -0
- package/src/react/primitives/thread/ThreadMessages.test.tsx +160 -0
- package/src/react/primitives/thread/ThreadMessages.tsx +8 -5
- package/src/react/providers/ReadonlyThreadProvider.test.tsx +56 -0
- package/src/react/runtimes/RemoteThreadListHookInstanceManager.layout.test.tsx +62 -0
- package/src/react/runtimes/RemoteThreadListHookInstanceManager.retry.test.tsx +2 -2
- package/src/react/runtimes/RemoteThreadListHookInstanceManager.test.tsx +23 -20
- package/src/react/runtimes/RemoteThreadListHookInstanceManager.title.test.tsx +24 -17
- package/src/react/runtimes/RemoteThreadListHookInstanceManager.tsx +39 -24
- package/src/react/runtimes/RemoteThreadListThreadListRuntimeCore.tsx +7 -1
- package/src/react/runtimes/assistant-transport/transport-scheduling.test.ts +73 -46
- package/src/react/runtimes/assistant-transport/useAssistantTransportRuntime.test.tsx +66 -1
- package/src/react/runtimes/cloud/AssistantCloudThreadHistoryAdapter.test.ts +20 -14
- package/src/react/runtimes/cloud/AssistantCloudThreadHistoryAdapter.test.tsx +323 -1
- package/src/react/runtimes/cloud/AssistantCloudThreadHistoryAdapter.ts +190 -523
- package/src/react/runtimes/cloud/CloudFileAttachmentAdapter.test.ts +81 -0
- package/src/react/runtimes/cloud/CloudFileAttachmentAdapter.ts +27 -1
- package/src/react/runtimes/cloud/auiV0.ts +281 -26
- package/src/react/runtimes/cloud/auiV0DecodeSafely.test.ts +522 -0
- package/src/react/runtimes/cloud/createCloudThreadListAdapter.test.ts +21 -0
- package/src/react/runtimes/cloud/createCloudThreadListAdapter.ts +7 -1
- package/src/react/runtimes/cloud/sdkIdentity.ts +9 -0
- package/src/react/runtimes/cloud/useCloudThreadListAdapter.test.tsx +18 -4
- package/src/react/runtimes/external-message-converter.test.ts +143 -4
- package/src/react/runtimes/external-message-converter.ts +39 -93
- package/src/react/runtimes/remote-thread-hook-on-tap.test.ts +2 -1
- package/src/react/runtimes/useExternalStoreRuntime.lifecycle.test.tsx +8 -2
- package/src/react/runtimes/useExternalStoreRuntime.suggestions.test.tsx +6 -2
- package/src/react/runtimes/useRemoteThreadListRuntime.concurrent.test.tsx +84 -4
- package/src/react/runtimes/useRemoteThreadListRuntime.ts +6 -2
- package/src/react/utils/groupParts.ts +12 -1
- package/src/react/utils/useJSONEqual.ts +9 -0
- package/src/react/utils/useJSONSchemaDependency.ts +22 -0
- package/src/runtime/api/message-part-runtime.ts +4 -1
- package/src/runtime/api/message-runtime.ts +15 -2
- package/src/runtime/api/thread-runtime.test.ts +58 -0
- package/src/runtime/api/thread-runtime.ts +2 -4
- package/src/runtime/base/base-composer-runtime-core.ts +69 -16
- package/src/runtime/base/base-thread-runtime-core.test.ts +1799 -49
- package/src/runtime/base/base-thread-runtime-core.ts +296 -94
- package/src/runtime/base/default-edit-composer-runtime-core.ts +12 -2
- package/src/runtime/base/default-thread-composer-runtime-core.ts +12 -1
- package/src/runtime/interfaces/thread-runtime-core.ts +8 -0
- package/src/runtime/queue/message-queue.ts +79 -7
- package/src/runtime/utils/auto-status.test.ts +112 -1
- package/src/runtime/utils/auto-status.ts +31 -5
- package/src/runtime/utils/external-message-conversion.test.ts +177 -0
- package/src/runtime/utils/external-message-conversion.ts +128 -33
- package/src/runtime/utils/message-repository.test.ts +49 -0
- package/src/runtime/utils/message-repository.ts +3 -3
- package/src/runtime/utils/stored-message-parts.ts +174 -0
- package/src/runtime/utils/thread-message-like.test.ts +52 -0
- package/src/runtime/utils/thread-message-like.ts +11 -2
- package/src/runtimes/external-store/external-store-adapter.ts +4 -0
- package/src/runtimes/external-store/external-store-thread-runtime-core.ts +74 -9
- package/src/runtimes/local/local-thread-runtime-core.test.ts +189 -12
- package/src/runtimes/local/local-thread-runtime-core.ts +91 -10
- package/src/runtimes/tool-invocations/EDGE_CASES.md +2 -6
- package/src/runtimes/tool-invocations/ToolInvocationTracker.test.ts +133 -0
- package/src/runtimes/tool-invocations/ToolInvocationTracker.ts +10 -6
- package/src/store/clients/external-thread.ts +53 -14
- package/src/store/clients/thread-tasks.test.ts +274 -0
- package/src/store/clients/thread-tasks.ts +138 -0
- package/src/store/index.ts +8 -0
- package/src/store/primitive-predicates.test.ts +64 -5
- package/src/store/primitive-predicates.ts +10 -2
- package/src/store/runtime-clients/thread-runtime-client.test.tsx +110 -0
- package/src/store/runtime-clients/thread-runtime-client.ts +31 -1
- package/src/store/scope-registration.ts +2 -0
- package/src/store/scopes/message.ts +4 -1
- package/src/store/scopes/task.ts +34 -0
- package/src/store/scopes/thread.ts +16 -0
- package/src/store/thread-tasks.test.tsx +209 -0
- package/src/subscribable/subscribable.test.ts +161 -1
- package/src/subscribable/subscribable.ts +25 -15
- package/src/tests/MessageRepository.test.ts +1 -5
- package/src/tests/attachment-adapters.test.ts +16 -1
- package/src/tests/auiV0Encode.test.ts +304 -0
- package/src/tests/base-composer-runtime-core-addAttachment.test.ts +6 -6
- package/src/tests/base-composer-runtime-core-send.test.ts +51 -0
- package/src/tests/base-composer-runtime-core.test.ts +329 -6
- package/src/tests/composer-can-cancel.test.ts +35 -6
- package/src/tests/composer-can-send.test.ts +22 -0
- package/src/tests/default-edit-composer-runtime-core.test.ts +47 -0
- package/src/tests/external-store-thread-runtime-core-adapter.test.ts +369 -16
- package/src/tests/external-store-thread-runtime-core.test.ts +31 -0
- package/src/tests/external-thread-attachments.test.tsx +91 -23
- package/src/tests/external-thread-feedback.test.tsx +20 -7
- package/src/tests/external-thread-parity.test.tsx +35 -1
- package/src/tests/groupParts.test.ts +71 -0
- package/src/tests/message-queue.test.ts +290 -2
- package/src/tests/remote-thread-list-reactive-threadId.test.ts +51 -0
- package/src/tests/thread-switch-events.test.tsx +11 -7
- package/src/tests/useRemoteThreadListRuntime-controlled.test.tsx +45 -1
- package/src/types/index.ts +1 -0
- package/src/types/message.test.ts +19 -0
- package/src/types/message.ts +23 -7
- package/src/utils/abortable-iterable.test.ts +115 -0
- package/src/utils/abortable-iterable.ts +34 -23
- package/src/utils/getGroupStatus.test.ts +70 -4
- package/src/utils/getGroupStatus.ts +35 -12
- package/src/utils/wire-media.test.ts +10 -0
- package/src/utils/wire-media.ts +6 -2
|
@@ -1,16 +1,20 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { bindExternalStoreMessage } from "../../runtime/utils/external-store-message.js";
|
|
3
|
-
import {
|
|
4
|
-
import { chunkExternalMessages, completeExternalMessageConversion, convertExternalMessageCallback, convertExternalMessageChunk, convertExternalMessages as convertExternalMessages$1, shallowArrayEqual } from "../../runtime/utils/external-message-conversion.js";
|
|
3
|
+
import { convertExternalMessages as convertExternalMessages$1, createExternalMessageConversionCache as createExternalMessageConversionCache$1 } from "../../runtime/utils/external-message-conversion.js";
|
|
5
4
|
import { c } from "@assistant-ui/tap/react-shim/compiler-runtime";
|
|
6
5
|
import { useState } from "@assistant-ui/tap/react-shim";
|
|
7
6
|
//#region src/react/runtimes/external-message-converter.ts
|
|
8
|
-
|
|
9
|
-
|
|
7
|
+
/**
|
|
8
|
+
* Creates a cache for plain external message conversion. Pass the same cache on every call for one message list, and a source message that has not changed since the previous call converts to the same `ThreadMessage` object.
|
|
9
|
+
*
|
|
10
|
+
* Entries are keyed by source message identity and rebuilt whenever `callback` or `metadata` is a different object than on the previous call, so keep both referentially stable.
|
|
11
|
+
*/
|
|
12
|
+
const createExternalMessageConversionCache = () => createExternalMessageConversionCache$1();
|
|
13
|
+
const convertExternalMessages = (messages, callback, isRunning, metadata, cache) => convertExternalMessages$1(messages, callback, isRunning, metadata, void 0, cache);
|
|
10
14
|
const useExternalMessageConverter = (t0) => {
|
|
11
|
-
const $ = c(
|
|
15
|
+
const $ = c(12);
|
|
12
16
|
const { callback, messages, isRunning, joinStrategy, metadata } = t0;
|
|
13
|
-
const [
|
|
17
|
+
const [cache] = useState(_temp);
|
|
14
18
|
let t1;
|
|
15
19
|
if ($[0] !== metadata) {
|
|
16
20
|
t1 = metadata ?? {};
|
|
@@ -18,73 +22,34 @@ const useExternalMessageConverter = (t0) => {
|
|
|
18
22
|
$[1] = t1;
|
|
19
23
|
} else t1 = $[1];
|
|
20
24
|
let t2;
|
|
21
|
-
if ($[2] !==
|
|
25
|
+
if ($[2] !== callback || $[3] !== t1) {
|
|
22
26
|
t2 = {
|
|
23
27
|
metadata: t1,
|
|
24
|
-
callback
|
|
25
|
-
...caches
|
|
28
|
+
callback
|
|
26
29
|
};
|
|
27
|
-
$[2] =
|
|
28
|
-
$[3] =
|
|
29
|
-
$[4] =
|
|
30
|
-
|
|
31
|
-
} else t2 = $[5];
|
|
30
|
+
$[2] = callback;
|
|
31
|
+
$[3] = t1;
|
|
32
|
+
$[4] = t2;
|
|
33
|
+
} else t2 = $[4];
|
|
32
34
|
const state = t2;
|
|
33
|
-
let
|
|
34
|
-
if ($[6] !== isRunning || $[7] !== joinStrategy || $[8] !== messages || $[9] !== state.callback || $[10] !== state.
|
|
35
|
-
|
|
36
|
-
for (const message of messages) {
|
|
37
|
-
let result = state.callbackCache.get(message);
|
|
38
|
-
if (!result || result.metadata !== state.metadata || result.callback !== state.callback) {
|
|
39
|
-
result = {
|
|
40
|
-
...convertExternalMessageCallback(message, state.callback, state.metadata),
|
|
41
|
-
metadata: state.metadata,
|
|
42
|
-
callback: state.callback
|
|
43
|
-
};
|
|
44
|
-
state.callbackCache.set(message, result);
|
|
45
|
-
}
|
|
46
|
-
callbackResults.push(result);
|
|
47
|
-
}
|
|
48
|
-
let t4;
|
|
49
|
-
if ($[15] !== state.chunkCache) {
|
|
50
|
-
t4 = (message_0) => {
|
|
51
|
-
const key = message_0.outputs[0];
|
|
52
|
-
if (!key) return message_0;
|
|
53
|
-
const cached = state.chunkCache.get(key);
|
|
54
|
-
if (cached && shallowArrayEqual(cached.outputs, message_0.outputs)) return cached;
|
|
55
|
-
state.chunkCache.set(key, message_0);
|
|
56
|
-
return message_0;
|
|
57
|
-
};
|
|
58
|
-
$[15] = state.chunkCache;
|
|
59
|
-
$[16] = t4;
|
|
60
|
-
} else t4 = $[16];
|
|
61
|
-
const chunks = chunkExternalMessages(callbackResults, joinStrategy).map(t4);
|
|
62
|
-
const threadMessages = state.converterCache.convertMessages(chunks, (cache, message_1, idx) => convertExternalMessageChunk(message_1, idx, chunks.length, isRunning, state.metadata.error, {
|
|
63
|
-
message: cache,
|
|
64
|
-
generatedFallbackMessages
|
|
65
|
-
}, state.metadata.cancelledMessageIds));
|
|
35
|
+
let threadMessages;
|
|
36
|
+
if ($[5] !== cache || $[6] !== isRunning || $[7] !== joinStrategy || $[8] !== messages || $[9] !== state.callback || $[10] !== state.metadata) {
|
|
37
|
+
threadMessages = convertExternalMessages$1(messages, state.callback, isRunning, state.metadata, joinStrategy, cache);
|
|
66
38
|
bindExternalStoreMessage(threadMessages, messages);
|
|
67
|
-
|
|
39
|
+
$[5] = cache;
|
|
68
40
|
$[6] = isRunning;
|
|
69
41
|
$[7] = joinStrategy;
|
|
70
42
|
$[8] = messages;
|
|
71
43
|
$[9] = state.callback;
|
|
72
|
-
$[10] = state.
|
|
73
|
-
$[11] =
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
$[14] = t3;
|
|
77
|
-
} else t3 = $[14];
|
|
78
|
-
return t3;
|
|
44
|
+
$[10] = state.metadata;
|
|
45
|
+
$[11] = threadMessages;
|
|
46
|
+
} else threadMessages = $[11];
|
|
47
|
+
return threadMessages;
|
|
79
48
|
};
|
|
80
49
|
function _temp() {
|
|
81
|
-
return
|
|
82
|
-
callbackCache: /* @__PURE__ */ new WeakMap(),
|
|
83
|
-
chunkCache: /* @__PURE__ */ new WeakMap(),
|
|
84
|
-
converterCache: new ThreadMessageConverter()
|
|
85
|
-
};
|
|
50
|
+
return createExternalMessageConversionCache$1();
|
|
86
51
|
}
|
|
87
52
|
//#endregion
|
|
88
|
-
export { convertExternalMessages, useExternalMessageConverter };
|
|
53
|
+
export { convertExternalMessages, createExternalMessageConversionCache, useExternalMessageConverter };
|
|
89
54
|
|
|
90
55
|
//# sourceMappingURL=external-message-converter.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"external-message-converter.js","names":["c","_c","useMemo","useState","
|
|
1
|
+
{"version":3,"file":"external-message-converter.js","names":["c","_c","useMemo","useState","convertExternalMessages","convertExternalMessagesInternal","createExternalMessageConversionCache","createExternalMessageConversionCacheInternal","ExternalMessageConverterCallback","ExternalMessageConverterMessage","ExternalMessageConverterMetadata","InternalExternalMessageConversionCache","JoinStrategy","bindExternalStoreMessage","ExternalMessageConversionCache","__brand","useExternalMessageConverter","Message","Metadata","Callback","T","WeakKey","messages","callback","isRunning","metadata","cache","undefined","t0","$","joinStrategy","_temp","t1","t2","state","threadMessages"],"sources":["../../../src/react/runtimes/external-message-converter.ts"],"sourcesContent":["\"use client\";\n\nimport { useMemo, useState } from \"react\";\nimport {\n convertExternalMessages as convertExternalMessagesInternal,\n createExternalMessageConversionCache as createExternalMessageConversionCacheInternal,\n type ExternalMessageConverterCallback,\n type ExternalMessageConverterMessage,\n type ExternalMessageConverterMetadata,\n type InternalExternalMessageConversionCache,\n type JoinStrategy,\n} from \"../../runtime/utils/external-message-conversion\";\nimport { bindExternalStoreMessage } from \"../../runtime/utils/external-store-message\";\n\nexport type { JoinStrategy };\nexport type ExternalMessageConversionCache = {\n readonly __brand: unique symbol;\n};\n\n/**\n * Creates a cache for plain external message conversion. Pass the same cache on every call for one message list, and a source message that has not changed since the previous call converts to the same `ThreadMessage` object.\n *\n * Entries are keyed by source message identity and rebuilt whenever `callback` or `metadata` is a different object than on the previous call, so keep both referentially stable.\n */\nexport const createExternalMessageConversionCache =\n (): ExternalMessageConversionCache =>\n createExternalMessageConversionCacheInternal() as unknown as ExternalMessageConversionCache;\n\nexport namespace useExternalMessageConverter {\n export type Message = ExternalMessageConverterMessage;\n export type Metadata = ExternalMessageConverterMetadata;\n export type Callback<T> = ExternalMessageConverterCallback<T>;\n}\n\nexport const convertExternalMessages = <T extends WeakKey>(\n messages: T[],\n callback: useExternalMessageConverter.Callback<T>,\n isRunning: boolean,\n metadata: useExternalMessageConverter.Metadata,\n cache?: ExternalMessageConversionCache,\n) =>\n convertExternalMessagesInternal(\n messages,\n callback,\n isRunning,\n metadata,\n undefined,\n cache as unknown as InternalExternalMessageConversionCache<T> | undefined,\n );\n\nexport const useExternalMessageConverter = <T extends WeakKey>({\n callback,\n messages,\n isRunning,\n joinStrategy,\n metadata,\n}: {\n callback: useExternalMessageConverter.Callback<T>;\n messages: T[];\n isRunning: boolean;\n joinStrategy?: JoinStrategy | undefined;\n metadata?: useExternalMessageConverter.Metadata | undefined;\n}) => {\n // The cache lives for the component lifetime: React Compiler hoists allocations without reactive dependencies out of useMemo, so entries carry the callback and metadata that produced them instead of being flushed when those change.\n const [cache] = useState(() =>\n createExternalMessageConversionCacheInternal<T>(),\n );\n\n const state = useMemo(\n () => ({\n metadata: metadata ?? {},\n callback,\n }),\n [callback, metadata],\n );\n\n return useMemo(() => {\n const threadMessages = convertExternalMessagesInternal(\n messages,\n state.callback,\n isRunning,\n state.metadata,\n joinStrategy,\n cache,\n );\n\n bindExternalStoreMessage(threadMessages, messages);\n return threadMessages;\n }, [state, messages, isRunning, joinStrategy, cache]);\n};\n"],"mappings":";;;;;;;;;;;AAwBA,MAAaM,6CAETC,uCAA6C;AAQjD,MAAaH,2BACXkB,UACAC,UACAC,WACAC,UACAC,UAEArB,0BACEiB,UACAC,UACAC,WACAC,UACAE,KAAAA,GACAD,KACF;AAEF,MAAaV,+BAA8BY,OAAA;CAAA,MAAAC,IAAA5B,EAAA,EAAA;CAAoB,MAAA,EAAAsB,UAAAD,UAAAE,WAAAM,cAAAL,aAAAG;CAc7D,MAAA,CAAAF,SAAgBvB,SAAS4B,KAEzB;CAAE,IAAAC;CAAA,IAAAH,EAAA,OAAAJ,UAAA;EAIYO,KAAAP,YAAA,CAAa;EAACI,EAAA,KAAAJ;EAAAI,EAAA,KAAAG;CAAA,OAAAA,KAAAH,EAAA;CAAA,IAAAI;CAAA,IAAAJ,EAAA,OAAAN,YAAAM,EAAA,OAAAG,IAAA;EADnBC,KAAA;GAAAR,UACKO;GAAcT;EAE1B;EAACM,EAAA,KAAAN;EAAAM,EAAA,KAAAG;EAAAH,EAAA,KAAAI;CAAA,OAAAA,KAAAJ,EAAA;CAJH,MAAAK,QACSD;CAKP,IAAAE;CAAA,IAAAN,EAAA,OAAAH,SAAAG,EAAA,OAAAL,aAAAK,EAAA,OAAAC,gBAAAD,EAAA,OAAAP,YAAAO,EAAA,OAAAK,MAAAX,YAAAM,EAAA,QAAAK,MAAAT,UAAA;EAGAU,iBAAuB9B,0BACrBiB,UACAY,MAAKX,UACLC,WACAU,MAAKT,UACLK,cACAJ,KACF;EAEAb,yBAAyBsB,gBAAgBb,QAAQ;EAACO,EAAA,KAAAH;EAAAG,EAAA,KAAAL;EAAAK,EAAA,KAAAC;EAAAD,EAAA,KAAAP;EAAAO,EAAA,KAAAK,MAAAX;EAAAM,EAAA,MAAAK,MAAAT;EAAAI,EAAA,MAAAM;CAAA,OAAAA,iBAAAN,EAAA;CAAA,OAClDM;AAAsB;AArCiB,SAAAJ,QAAA;CAAA,OAevCxB,uCAAgD;AAAC"}
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import { ExternalStoreAdapter } from "../../runtimes/external-store/external-store-adapter.js";
|
|
2
2
|
import { AssistantRuntime } from "../../runtime/api/assistant-runtime.js";
|
|
3
3
|
//#region src/react/runtimes/useExternalStoreRuntime.d.ts
|
|
4
|
-
declare const useExternalStoreRuntime: <T>(store: ExternalStoreAdapter<T>) => AssistantRuntime;
|
|
4
|
+
export declare const useExternalStoreRuntime: <T>(store: ExternalStoreAdapter<T>) => AssistantRuntime;
|
|
5
5
|
//#endregion
|
|
6
|
-
export { useExternalStoreRuntime };
|
|
7
6
|
//# sourceMappingURL=useExternalStoreRuntime.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useExternalStoreRuntime.d.ts","names":[],"sources":["../../../src/react/runtimes/useExternalStoreRuntime.ts"],"mappings":";;;
|
|
1
|
+
{"version":3,"file":"useExternalStoreRuntime.d.ts","names":[],"sources":["../../../src/react/runtimes/useExternalStoreRuntime.ts"],"mappings":";;;qBAUa,0BAA2B,GACtC,OAAO,qBAAqB,OAC3B"}
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { ExternalStoreSharedOptions } from "../../runtimes/external-store/external-store-shared-options.js";
|
|
2
2
|
//#region src/react/runtimes/useExternalStoreSharedOptions.d.ts
|
|
3
|
-
declare const useExternalStoreSharedOptions: (options: ExternalStoreSharedOptions) => ExternalStoreSharedOptions;
|
|
3
|
+
export declare const useExternalStoreSharedOptions: (options: ExternalStoreSharedOptions) => ExternalStoreSharedOptions;
|
|
4
4
|
//#endregion
|
|
5
|
-
export { useExternalStoreSharedOptions };
|
|
6
5
|
//# sourceMappingURL=useExternalStoreSharedOptions.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useExternalStoreSharedOptions.d.ts","names":[],"sources":["../../../src/react/runtimes/useExternalStoreSharedOptions.ts"],"mappings":";;
|
|
1
|
+
{"version":3,"file":"useExternalStoreSharedOptions.d.ts","names":[],"sources":["../../../src/react/runtimes/useExternalStoreSharedOptions.ts"],"mappings":";;qBAKa,gCACX,SAAS,+BACR"}
|
|
@@ -11,12 +11,12 @@ import { AssistantRuntime } from "../../runtime/api/assistant-runtime.js";
|
|
|
11
11
|
import "../../index.js";
|
|
12
12
|
import { AssistantCloud } from "assistant-cloud";
|
|
13
13
|
//#region src/react/runtimes/useLocalRuntime.d.ts
|
|
14
|
-
type LocalRuntimeOptions = Omit<LocalRuntimeOptionsBase, "adapters"> & {
|
|
14
|
+
export type LocalRuntimeOptions = Omit<LocalRuntimeOptionsBase, "adapters"> & {
|
|
15
15
|
cloud?: AssistantCloud | undefined;
|
|
16
16
|
initialMessages?: readonly ThreadMessageLike[] | undefined;
|
|
17
17
|
adapters?: Omit<LocalRuntimeOptionsBase["adapters"], "chatModel"> | undefined;
|
|
18
18
|
};
|
|
19
|
-
declare const splitLocalRuntimeOptions: <T extends LocalRuntimeOptions>(options: T) => {
|
|
19
|
+
export declare const splitLocalRuntimeOptions: <T extends LocalRuntimeOptions>(options: T) => {
|
|
20
20
|
localRuntimeOptions: {
|
|
21
21
|
cloud: AssistantCloud | undefined;
|
|
22
22
|
initialMessages: readonly ThreadMessageLike[] | undefined;
|
|
@@ -38,7 +38,6 @@ declare const splitLocalRuntimeOptions: <T extends LocalRuntimeOptions>(options:
|
|
|
38
38
|
};
|
|
39
39
|
otherOptions: Omit<T, "adapters" | "maxSteps" | "unstable_humanToolNames" | "unstable_enableMessageQueue" | "unstable_queueClearOnRewind" | "unstable_queueClearOnCancel" | "cloud" | "initialMessages">;
|
|
40
40
|
};
|
|
41
|
-
declare const useLocalRuntime: (chatModel: ChatModelAdapter, { cloud, ...options }?: LocalRuntimeOptions) => AssistantRuntime;
|
|
41
|
+
export declare const useLocalRuntime: (chatModel: ChatModelAdapter, { cloud, ...options }?: LocalRuntimeOptions) => AssistantRuntime;
|
|
42
42
|
//#endregion
|
|
43
|
-
export { LocalRuntimeOptions, splitLocalRuntimeOptions, useLocalRuntime };
|
|
44
43
|
//# sourceMappingURL=useLocalRuntime.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useLocalRuntime.d.ts","names":[],"sources":["../../../src/react/runtimes/useLocalRuntime.ts"],"mappings":";;;;;;;;;;;;;
|
|
1
|
+
{"version":3,"file":"useLocalRuntime.d.ts","names":[],"sources":["../../../src/react/runtimes/useLocalRuntime.ts"],"mappings":";;;;;;;;;;;;;YAcY,sBAAsB,KAAK;EACrC,QAAQ;EACR,2BAA2B;EAC3B,WAAW,KAAK;;qBA2DL,2BAA4B,UAAU,qBACjD,SAAS;;;;;;;;;;;;;;;;;;;;;;qBA6BE,kBACX,WAAW,oBACX,UAAA,YAAuB,wBACtB"}
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import { RemoteThreadListOptions } from "../../runtimes/remote-thread-list/types.js";
|
|
2
2
|
import { AssistantRuntime } from "../../runtime/api/assistant-runtime.js";
|
|
3
3
|
//#region src/react/runtimes/useRemoteThreadListRuntime.d.ts
|
|
4
|
-
declare const useRemoteThreadListRuntime: (options: RemoteThreadListOptions) => AssistantRuntime;
|
|
4
|
+
export declare const useRemoteThreadListRuntime: (options: RemoteThreadListOptions) => AssistantRuntime;
|
|
5
5
|
//#endregion
|
|
6
|
-
export { useRemoteThreadListRuntime };
|
|
7
6
|
//# sourceMappingURL=useRemoteThreadListRuntime.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useRemoteThreadListRuntime.d.ts","names":[],"sources":["../../../src/react/runtimes/useRemoteThreadListRuntime.ts"],"mappings":";;;
|
|
1
|
+
{"version":3,"file":"useRemoteThreadListRuntime.d.ts","names":[],"sources":["../../../src/react/runtimes/useRemoteThreadListRuntime.ts"],"mappings":";;;qBAmFa,6BACX,SAAS,4BACR"}
|
|
@@ -4,7 +4,7 @@ import { AssistantRuntimeImpl } from "../../runtime/api/assistant-runtime.js";
|
|
|
4
4
|
import { useSubscribable } from "../../store/runtime-clients/useSubscribable.js";
|
|
5
5
|
import { RemoteThreadListThreadListRuntimeCore } from "./RemoteThreadListThreadListRuntimeCore.js";
|
|
6
6
|
import { c } from "@assistant-ui/tap/react-shim/compiler-runtime";
|
|
7
|
-
import { useCallback, useEffect, useEffectEvent, useInsertionEffect, useMemo, useRef, useState } from "@assistant-ui/tap/react-shim";
|
|
7
|
+
import { useCallback, useEffect, useEffectEvent, useInsertionEffect, useLayoutEffect, useMemo, useRef, useState } from "@assistant-ui/tap/react-shim";
|
|
8
8
|
import { useAui } from "@assistant-ui/store";
|
|
9
9
|
//#region src/react/runtimes/useRemoteThreadListRuntime.ts
|
|
10
10
|
var RemoteThreadListRuntimeCore = class extends BaseAssistantRuntimeCore {
|
|
@@ -94,7 +94,7 @@ const useRemoteThreadListRuntimeImpl = (options) => {
|
|
|
94
94
|
};
|
|
95
95
|
const useRemoteThreadListRuntime = (options) => {
|
|
96
96
|
const [runtimeHookStore] = useState(() => new WritableSubscribable(options.runtimeHook));
|
|
97
|
-
|
|
97
|
+
useLayoutEffect(() => {
|
|
98
98
|
runtimeHookStore.setState(options.runtimeHook);
|
|
99
99
|
}, [runtimeHookStore, options.runtimeHook]);
|
|
100
100
|
const initialThreadIdRef = useRef(options.initialThreadId);
|
|
@@ -106,7 +106,7 @@ const useRemoteThreadListRuntime = (options) => {
|
|
|
106
106
|
})();
|
|
107
107
|
}, [runtimeHookStore]);
|
|
108
108
|
const onThreadIdChange = useEffectEvent((threadId) => {
|
|
109
|
-
options.onThreadIdChange?.(threadId);
|
|
109
|
+
return options.onThreadIdChange?.(threadId);
|
|
110
110
|
});
|
|
111
111
|
const stableOptions = useMemo(() => ({
|
|
112
112
|
adapter: options.adapter,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useRemoteThreadListRuntime.js","names":["useState","useEffect","useInsertionEffect","useMemo","useRef","useCallback","useEffectEvent","BaseAssistantRuntimeCore","AssistantRuntimeImpl","RemoteThreadListOptions","AssistantRuntimeCore","AssistantRuntime","RemoteThreadListThreadListRuntimeCore","WritableSubscribable","useSubscribable","useAui","RemoteThreadListRuntimeCore","threads","constructor","options","_contextProvider","RenderComponent","__internal_RenderComponent","useRemoteThreadListRuntimeImpl","$","_c","t0","runtime","t1","queueMicrotask","__internal_dispose","t2","t3","__internal_setOptions","__internal_load","t4","t5","window","document","reloadAfterError","loadError","undefined","reload","reloadAfterVisible","visibilityState","addEventListener","removeEventListener","t6","t7","useRemoteThreadListRuntime","runtimeHookStore","runtimeHook","setState","initialThreadIdRef","initialThreadId","stableRuntimeHook","useCommittedRuntimeHook","subscribe","getState","getServerSnapshot","onThreadIdChange","threadId","stableOptions","adapter","allowNesting","current","aui","isNested","threadListItem","source","Error"],"sources":["../../../src/react/runtimes/useRemoteThreadListRuntime.ts"],"sourcesContent":["import {\n useState,\n useEffect,\n useInsertionEffect,\n useMemo,\n useRef,\n useCallback,\n useEffectEvent,\n} from \"react\";\nimport { BaseAssistantRuntimeCore } from \"../../runtime/base/base-assistant-runtime-core\";\nimport { AssistantRuntimeImpl } from \"../../runtime/api/assistant-runtime\";\nimport type { RemoteThreadListOptions } from \"../../runtimes/remote-thread-list/types\";\nimport type { AssistantRuntimeCore } from \"../../runtime/interfaces/assistant-runtime-core\";\nimport type { AssistantRuntime } from \"../../runtime/api/assistant-runtime\";\nimport { RemoteThreadListThreadListRuntimeCore } from \"./RemoteThreadListThreadListRuntimeCore\";\nimport { WritableSubscribable } from \"../../subscribable/subscribable\";\nimport { useSubscribable } from \"../../store/runtime-clients/useSubscribable\";\nimport { useAui } from \"@assistant-ui/store\";\n\nclass RemoteThreadListRuntimeCore\n extends BaseAssistantRuntimeCore\n implements AssistantRuntimeCore\n{\n public readonly threads;\n\n constructor(options: RemoteThreadListOptions) {\n super();\n this.threads = new RemoteThreadListThreadListRuntimeCore(\n options,\n this._contextProvider,\n );\n }\n\n public get RenderComponent() {\n return this.threads.__internal_RenderComponent;\n }\n}\n\nconst useRemoteThreadListRuntimeImpl = (\n options: RemoteThreadListOptions,\n): AssistantRuntime => {\n const [runtime] = useState(() => new RemoteThreadListRuntimeCore(options));\n\n // Insertion-effect cleanup runs only when React deletes the fiber, so a\n // hidden <Activity> or a re-suspended boundary keeps the threads alive; the\n // disposal is deferred to a microtask because it notifies subscribers and\n // React forbids scheduling updates from an insertion effect.\n useInsertionEffect(\n () => () => queueMicrotask(() => runtime.threads.__internal_dispose()),\n [runtime],\n );\n\n useEffect(() => {\n runtime.threads.__internal_setOptions(options);\n runtime.threads.__internal_load();\n }, [runtime, options]);\n\n useEffect(() => {\n if (typeof window === \"undefined\" || typeof document === \"undefined\") {\n return;\n }\n\n const reloadAfterError = () => {\n if (runtime.threads.loadError !== undefined) {\n void runtime.threads.reload();\n }\n };\n const reloadAfterVisible = () => {\n if (document.visibilityState === \"visible\") reloadAfterError();\n };\n\n window.addEventListener(\"online\", reloadAfterError);\n document.addEventListener(\"visibilitychange\", reloadAfterVisible);\n return () => {\n window.removeEventListener(\"online\", reloadAfterError);\n document.removeEventListener(\"visibilitychange\", reloadAfterVisible);\n };\n }, [runtime]);\n\n return useMemo(() => new AssistantRuntimeImpl(runtime), [runtime]);\n};\n\nexport const useRemoteThreadListRuntime = (\n options: RemoteThreadListOptions,\n): AssistantRuntime => {\n const [runtimeHookStore] = useState(\n () => new WritableSubscribable(options.runtimeHook),\n );\n
|
|
1
|
+
{"version":3,"file":"useRemoteThreadListRuntime.js","names":["useState","useEffect","useInsertionEffect","useLayoutEffect","useMemo","useRef","useCallback","useEffectEvent","BaseAssistantRuntimeCore","AssistantRuntimeImpl","RemoteThreadListOptions","AssistantRuntimeCore","AssistantRuntime","RemoteThreadListThreadListRuntimeCore","WritableSubscribable","useSubscribable","useAui","RemoteThreadListRuntimeCore","threads","constructor","options","_contextProvider","RenderComponent","__internal_RenderComponent","useRemoteThreadListRuntimeImpl","$","_c","t0","runtime","t1","queueMicrotask","__internal_dispose","t2","t3","__internal_setOptions","__internal_load","t4","t5","window","document","reloadAfterError","loadError","undefined","reload","reloadAfterVisible","visibilityState","addEventListener","removeEventListener","t6","t7","useRemoteThreadListRuntime","runtimeHookStore","runtimeHook","setState","initialThreadIdRef","initialThreadId","stableRuntimeHook","useCommittedRuntimeHook","subscribe","getState","getServerSnapshot","onThreadIdChange","threadId","stableOptions","adapter","allowNesting","current","aui","isNested","threadListItem","source","Error"],"sources":["../../../src/react/runtimes/useRemoteThreadListRuntime.ts"],"sourcesContent":["import {\n useState,\n useEffect,\n useInsertionEffect,\n useLayoutEffect,\n useMemo,\n useRef,\n useCallback,\n useEffectEvent,\n} from \"react\";\nimport { BaseAssistantRuntimeCore } from \"../../runtime/base/base-assistant-runtime-core\";\nimport { AssistantRuntimeImpl } from \"../../runtime/api/assistant-runtime\";\nimport type { RemoteThreadListOptions } from \"../../runtimes/remote-thread-list/types\";\nimport type { AssistantRuntimeCore } from \"../../runtime/interfaces/assistant-runtime-core\";\nimport type { AssistantRuntime } from \"../../runtime/api/assistant-runtime\";\nimport { RemoteThreadListThreadListRuntimeCore } from \"./RemoteThreadListThreadListRuntimeCore\";\nimport { WritableSubscribable } from \"../../subscribable/subscribable\";\nimport { useSubscribable } from \"../../store/runtime-clients/useSubscribable\";\nimport { useAui } from \"@assistant-ui/store\";\n\nclass RemoteThreadListRuntimeCore\n extends BaseAssistantRuntimeCore\n implements AssistantRuntimeCore\n{\n public readonly threads;\n\n constructor(options: RemoteThreadListOptions) {\n super();\n this.threads = new RemoteThreadListThreadListRuntimeCore(\n options,\n this._contextProvider,\n );\n }\n\n public get RenderComponent() {\n return this.threads.__internal_RenderComponent;\n }\n}\n\nconst useRemoteThreadListRuntimeImpl = (\n options: RemoteThreadListOptions,\n): AssistantRuntime => {\n const [runtime] = useState(() => new RemoteThreadListRuntimeCore(options));\n\n // Insertion-effect cleanup runs only when React deletes the fiber, so a\n // hidden <Activity> or a re-suspended boundary keeps the threads alive; the\n // disposal is deferred to a microtask because it notifies subscribers and\n // React forbids scheduling updates from an insertion effect.\n useInsertionEffect(\n () => () => queueMicrotask(() => runtime.threads.__internal_dispose()),\n [runtime],\n );\n\n useEffect(() => {\n runtime.threads.__internal_setOptions(options);\n runtime.threads.__internal_load();\n }, [runtime, options]);\n\n useEffect(() => {\n if (typeof window === \"undefined\" || typeof document === \"undefined\") {\n return;\n }\n\n const reloadAfterError = () => {\n if (runtime.threads.loadError !== undefined) {\n void runtime.threads.reload();\n }\n };\n const reloadAfterVisible = () => {\n if (document.visibilityState === \"visible\") reloadAfterError();\n };\n\n window.addEventListener(\"online\", reloadAfterError);\n document.addEventListener(\"visibilitychange\", reloadAfterVisible);\n return () => {\n window.removeEventListener(\"online\", reloadAfterError);\n document.removeEventListener(\"visibilitychange\", reloadAfterVisible);\n };\n }, [runtime]);\n\n return useMemo(() => new AssistantRuntimeImpl(runtime), [runtime]);\n};\n\nexport const useRemoteThreadListRuntime = (\n options: RemoteThreadListOptions,\n): AssistantRuntime => {\n const [runtimeHookStore] = useState(\n () => new WritableSubscribable(options.runtimeHook),\n );\n // The layout phase re-renders hosted threads before this commit yields. An\n // insertion effect cannot notify subscribers, so descendant layout effects\n // of the same commit still see the previous hook.\n useLayoutEffect(() => {\n runtimeHookStore.setState(options.runtimeHook);\n }, [runtimeHookStore, options.runtimeHook]);\n\n const initialThreadIdRef = useRef(options.initialThreadId);\n\n // Thread resources subscribe to the store rather than reading a ref, so a\n // hook published at commit reaches exactly the resources that use it and an\n // abandoned render publishes nothing. The store pins its server snapshot to\n // the constructor value for hydration, which tap reads on any never-mounted\n // fiber, so the live state serves as the server snapshot here.\n const stableRuntimeHook = useCallback(\n function useCommittedRuntimeHook() {\n return useSubscribable({\n subscribe: runtimeHookStore.subscribe,\n getState: runtimeHookStore.getState,\n getServerSnapshot: runtimeHookStore.getState,\n })();\n },\n [runtimeHookStore],\n );\n\n const onThreadIdChange = useEffectEvent((threadId: string | undefined) => {\n return options.onThreadIdChange?.(threadId);\n });\n\n const stableOptions = useMemo<RemoteThreadListOptions>(\n () => ({\n adapter: options.adapter,\n allowNesting: options.allowNesting,\n threadId: options.threadId,\n initialThreadId: initialThreadIdRef.current,\n runtimeHook: stableRuntimeHook,\n onThreadIdChange,\n }),\n [\n options.adapter,\n options.allowNesting,\n options.threadId,\n stableRuntimeHook,\n ],\n );\n\n const aui = useAui();\n const isNested = aui.threadListItem.source !== null;\n\n if (isNested) {\n if (!stableOptions.allowNesting) {\n throw new Error(\n \"useRemoteThreadListRuntime cannot be nested inside another RemoteThreadListRuntime. \" +\n \"Set allowNesting: true to allow nesting (the inner runtime will become a no-op).\",\n );\n }\n\n // If allowNesting is true and already inside a thread list context,\n // just call the runtimeHook directly (no-op behavior)\n return options.runtimeHook();\n }\n\n const runtime = useRemoteThreadListRuntimeImpl(stableOptions);\n\n return runtime;\n};\n"],"mappings":";;;;;;;;;AAoBA,IAAMiB,8BAAN,cACUT,yBAEV;CACE;CAEAW,YAAYC,SAAkC;EAC5C,MAAM;EACN,KAAKF,UAAU,IAAIL,sCACjBO,SACA,KAAKC,gBACP;CACF;CAEA,IAAWC,kBAAkB;EAC3B,OAAO,KAAKJ,QAAQK;CACtB;AACF;AAEA,MAAMC,kCAAiCJ,YAAA;CAAA,MAAAK,IAAAC,EAAA,EAAA;CAAA,IAAAC;CAAA,IAAAF,EAAA,OAAAL,SAAA;EAGVO,WAAM,IAAIV,4BAA4BG,OAAO;EAACK,EAAA,KAAAL;EAAAK,EAAA,KAAAE;CAAA,OAAAA,KAAAF,EAAA;CAAzE,MAAA,CAAAG,WAAkB5B,SAAS2B,EAA8C;CAAE,IAAAE;CAAA,IAAAJ,EAAA,OAAAG,QAAAV,SAAA;EAOzEW,iBAAYC,qBAAqBF,QAAOV,QAAQa,mBAAoB,CAAC;EAACN,EAAA,KAAAG,QAAAV;EAAAO,EAAA,KAAAI;CAAA,OAAAA,KAAAJ,EAAA;CAAA,IAAAO;CAAA,IAAAP,EAAA,OAAAG,SAAA;EACtEI,KAAA,CAACJ,OAAO;EAACH,EAAA,KAAAG;EAAAH,EAAA,KAAAO;CAAA,OAAAA,KAAAP,EAAA;CAFXvB,mBACE2B,IACAG,EACF;CAAC,IAAAC;CAAA,IAAAR,EAAA,OAAAL,WAAAK,EAAA,OAAAG,QAAAV,SAAA;EAESe,WAAA;GACRL,QAAOV,QAAQgB,sBAAuBd,OAAO;GAC7CQ,QAAOV,QAAQiB,gBAAiB;EAAC;EAClCV,EAAA,KAAAL;EAAAK,EAAA,KAAAG,QAAAV;EAAAO,EAAA,KAAAQ;CAAA,OAAAA,KAAAR,EAAA;CAAA,IAAAW;CAAA,IAAAX,EAAA,OAAAL,WAAAK,EAAA,QAAAG,SAAA;EAAEQ,KAAA,CAACR,SAASR,OAAO;EAACK,EAAA,KAAAL;EAAAK,EAAA,MAAAG;EAAAH,EAAA,MAAAW;CAAA,OAAAA,KAAAX,EAAA;CAHrBxB,UAAUgC,IAGPG,EAAkB;CAAC,IAAAC;CAAA,IAAAZ,EAAA,QAAAG,QAAAV,SAAA;EAEZmB,WAAA;GACR,IAAI,OAAOC,WAAW,eAAe,OAAOC,aAAa,aAAW;GAIpE,MAAAC,yBAAyB;IACvB,IAAIZ,QAAOV,QAAQuB,cAAeC,KAAAA,GAC3Bd,QAAOV,QAAQyB,OAAQ;GAC7B;GAEH,MAAAC,2BAA2B;IACzB,IAAIL,SAAQM,oBAAqB,WAAWL,iBAAiB;GAAE;GAGjEF,OAAMQ,iBAAkB,UAAUN,gBAAgB;GAClDD,SAAQO,iBAAkB,oBAAoBF,kBAAkB;GAAC,aAC1D;IACLN,OAAMS,oBAAqB,UAAUP,gBAAgB;IACrDD,SAAQQ,oBAAqB,oBAAoBH,kBAAkB;GAAC;EACrE;EACFnB,EAAA,MAAAG,QAAAV;EAAAO,EAAA,MAAAY;CAAA,OAAAA,KAAAZ,EAAA;CAAA,IAAAuB;CAAA,IAAAvB,EAAA,QAAAG,SAAA;EAAEoB,KAAA,CAACpB,OAAO;EAACH,EAAA,MAAAG;EAAAH,EAAA,MAAAuB;CAAA,OAAAA,KAAAvB,EAAA;CApBZxB,UAAUoC,IAoBPW,EAAS;CAAC,IAAAC;CAAA,IAAAxB,EAAA,QAAAG,SAAA;EAEQqB,KAAA,IAAIxC,qBAAqBmB,OAAO;EAACH,EAAA,MAAAG;EAAAH,EAAA,MAAAwB;CAAA,OAAAA,KAAAxB,EAAA;CAAA,OAAjCwB;AAAiC;AAGxD,MAAaC,8BACX9B,YACqB;CACrB,MAAM,CAAC+B,oBAAoBnD,eACnB,IAAIc,qBAAqBM,QAAQgC,WAAW,CACpD;CAIAjD,sBAAsB;EACpBgD,iBAAiBE,SAASjC,QAAQgC,WAAW;CAC/C,GAAG,CAACD,kBAAkB/B,QAAQgC,WAAW,CAAC;CAE1C,MAAME,qBAAqBjD,OAAOe,QAAQmC,eAAe;CAOzD,MAAMC,oBAAoBlD,YACxB,SAASmD,0BAA0B;EACjC,OAAO1C,gBAAgB;GACrB2C,WAAWP,iBAAiBO;GAC5BC,UAAUR,iBAAiBQ;GAC3BC,mBAAmBT,iBAAiBQ;EACtC,CAAC,CAAC,CAAC;CACL,GACA,CAACR,gBAAgB,CACnB;CAEA,MAAMU,mBAAmBtD,gBAAgBuD,aAAiC;EACxE,OAAO1C,QAAQyC,mBAAmBC,QAAQ;CAC5C,CAAC;CAED,MAAMC,gBAAgB3D,eACb;EACL4D,SAAS5C,QAAQ4C;EACjBC,cAAc7C,QAAQ6C;EACtBH,UAAU1C,QAAQ0C;EAClBP,iBAAiBD,mBAAmBY;EACpCd,aAAaI;EACbK;CACF,IACA;EACEzC,QAAQ4C;EACR5C,QAAQ6C;EACR7C,QAAQ0C;EACRN;CAAiB,CAErB;CAKA,IAHYxC,OACKmD,CAAG,CAACE,eAAeC,WAAW,MAEjC;EACZ,IAAI,CAACP,cAAcE,cACjB,MAAM,IAAIM,MACR,sKAEF;EAKF,OAAOnD,QAAQgC,YAAY;CAC7B;CAIA,OAFgB5B,+BAA+BuC,aAExCnC;AACT"}
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { RuntimeAdapters } from "../../runtimes/remote-thread-list/types.js";
|
|
2
2
|
//#region src/react/runtimes/useRuntimeAdapters.d.ts
|
|
3
3
|
declare const RuntimeAdaptersContext: import("react").Context<RuntimeAdapters | null>;
|
|
4
|
-
declare const useRuntimeAdaptersProvider: <T>(adapters: RuntimeAdapters | null, fn: () => T) => T;
|
|
5
|
-
declare const useRuntimeAdapters: () => RuntimeAdapters | null;
|
|
6
|
-
declare const useStableRuntimeAdapters: (adapters: RuntimeAdapters | null | undefined) => RuntimeAdapters | null;
|
|
4
|
+
export declare const useRuntimeAdaptersProvider: <T>(adapters: RuntimeAdapters | null, fn: () => T) => T;
|
|
5
|
+
export declare const useRuntimeAdapters: () => RuntimeAdapters | null;
|
|
6
|
+
export declare const useStableRuntimeAdapters: (adapters: RuntimeAdapters | null | undefined) => RuntimeAdapters | null;
|
|
7
7
|
//#endregion
|
|
8
|
-
export { RuntimeAdaptersContext
|
|
8
|
+
export { RuntimeAdaptersContext };
|
|
9
9
|
//# sourceMappingURL=useRuntimeAdapters.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useRuntimeAdapters.d.ts","names":[],"sources":["../../../src/react/runtimes/useRuntimeAdapters.ts"],"mappings":";;cAKM,wCAAsB,QAAA;
|
|
1
|
+
{"version":3,"file":"useRuntimeAdapters.d.ts","names":[],"sources":["../../../src/react/runtimes/useRuntimeAdapters.ts"],"mappings":";;cAKM,wCAAsB,QAAA;qBAEf,6BAA8B,GACzC,UAAU,wBACV,UAAU,MACT;qBAEU,0BAAkB;qBAQlB,2BACX,UAAU,uCACT"}
|
|
@@ -19,7 +19,7 @@ import { StreamingTimingAccessors, StreamingTimingOptions, StreamingTimingState
|
|
|
19
19
|
* });
|
|
20
20
|
* ```
|
|
21
21
|
*/
|
|
22
|
-
declare const useStreamingTiming: <TMessage>(messages: readonly TMessage[], isRunning: boolean, accessors: StreamingTimingAccessors<TMessage>, options?: StreamingTimingOptions) => Record<string, MessageTiming>;
|
|
22
|
+
export declare const useStreamingTiming: <TMessage>(messages: readonly TMessage[], isRunning: boolean, accessors: StreamingTimingAccessors<TMessage>, options?: StreamingTimingOptions) => Record<string, MessageTiming>;
|
|
23
23
|
//#endregion
|
|
24
|
-
export {
|
|
24
|
+
export type { StreamingTimingAccessors, StreamingTimingOptions, StreamingTimingState };
|
|
25
25
|
//# sourceMappingURL=useStreamingTiming.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useStreamingTiming.d.ts","names":[],"sources":["../../../src/react/runtimes/useStreamingTiming.ts"],"mappings":";;;;;;;;;;;;;;;;;;;;;
|
|
1
|
+
{"version":3,"file":"useStreamingTiming.d.ts","names":[],"sources":["../../../src/react/runtimes/useStreamingTiming.ts"],"mappings":";;;;;;;;;;;;;;;;;;;;;qBAmCa,qBAAsB,UACjC,mBAAmB,YACnB,oBACA,WAAW,yBAAyB,WACpC,UAAU,2BACT,eAAe"}
|
|
@@ -5,38 +5,38 @@ import "../../index.js";
|
|
|
5
5
|
import { ToolResponse } from "assistant-stream";
|
|
6
6
|
import { ComponentType, PropsWithChildren } from "react";
|
|
7
7
|
//#region src/react/types/MessagePartComponentTypes.d.ts
|
|
8
|
-
type EmptyMessagePartProps = {
|
|
8
|
+
export type EmptyMessagePartProps = {
|
|
9
9
|
status: MessagePartStatus;
|
|
10
10
|
};
|
|
11
|
-
type EmptyMessagePartComponent = ComponentType<EmptyMessagePartProps>;
|
|
12
|
-
type TextMessagePartProps = MessagePartState & TextMessagePart;
|
|
13
|
-
type TextMessagePartComponent = ComponentType<TextMessagePartProps>;
|
|
14
|
-
type ReasoningMessagePartProps = MessagePartState & ReasoningMessagePart;
|
|
15
|
-
type ReasoningMessagePartComponent = ComponentType<ReasoningMessagePartProps>;
|
|
16
|
-
type ReasoningGroupProps = PropsWithChildren<{
|
|
11
|
+
export type EmptyMessagePartComponent = ComponentType<EmptyMessagePartProps>;
|
|
12
|
+
export type TextMessagePartProps = MessagePartState & TextMessagePart;
|
|
13
|
+
export type TextMessagePartComponent = ComponentType<TextMessagePartProps>;
|
|
14
|
+
export type ReasoningMessagePartProps = MessagePartState & ReasoningMessagePart;
|
|
15
|
+
export type ReasoningMessagePartComponent = ComponentType<ReasoningMessagePartProps>;
|
|
16
|
+
export type ReasoningGroupProps = PropsWithChildren<{
|
|
17
17
|
startIndex: number;
|
|
18
18
|
endIndex: number;
|
|
19
19
|
}>;
|
|
20
|
-
type ReasoningGroupComponent = ComponentType<ReasoningGroupProps>;
|
|
21
|
-
type SourceMessagePartProps = MessagePartState & SourceMessagePart;
|
|
22
|
-
type SourceMessagePartComponent = ComponentType<SourceMessagePartProps>;
|
|
23
|
-
type ImageMessagePartProps = MessagePartState & ImageMessagePart;
|
|
24
|
-
type ImageMessagePartComponent = ComponentType<ImageMessagePartProps>;
|
|
25
|
-
type FileMessagePartProps = MessagePartState & FileMessagePart;
|
|
26
|
-
type FileMessagePartComponent = ComponentType<FileMessagePartProps>;
|
|
20
|
+
export type ReasoningGroupComponent = ComponentType<ReasoningGroupProps>;
|
|
21
|
+
export type SourceMessagePartProps = MessagePartState & SourceMessagePart;
|
|
22
|
+
export type SourceMessagePartComponent = ComponentType<SourceMessagePartProps>;
|
|
23
|
+
export type ImageMessagePartProps = MessagePartState & ImageMessagePart;
|
|
24
|
+
export type ImageMessagePartComponent = ComponentType<ImageMessagePartProps>;
|
|
25
|
+
export type FileMessagePartProps = MessagePartState & FileMessagePart;
|
|
26
|
+
export type FileMessagePartComponent = ComponentType<FileMessagePartProps>;
|
|
27
27
|
/**
|
|
28
28
|
* @deprecated Use {@link FileMessagePartProps} and render `audio/*` mime types
|
|
29
29
|
* from the `File` slot.
|
|
30
30
|
*/
|
|
31
|
-
type Unstable_AudioMessagePartProps = MessagePartState & Unstable_AudioMessagePart;
|
|
31
|
+
export type Unstable_AudioMessagePartProps = MessagePartState & Unstable_AudioMessagePart;
|
|
32
32
|
/**
|
|
33
33
|
* @deprecated Use {@link FileMessagePartComponent} and render `audio/*` mime
|
|
34
34
|
* types from the `File` slot.
|
|
35
35
|
*/
|
|
36
|
-
type Unstable_AudioMessagePartComponent = ComponentType<Unstable_AudioMessagePartProps>;
|
|
37
|
-
type DataMessagePartProps<T = any> = MessagePartState & DataMessagePart<T>;
|
|
38
|
-
type DataMessagePartComponent<T = any> = ComponentType<DataMessagePartProps<T>>;
|
|
39
|
-
type ToolCallMessagePartProps<TArgs = any, TResult = unknown> = MessagePartState & ToolCallMessagePart<TArgs, TResult> & {
|
|
36
|
+
export type Unstable_AudioMessagePartComponent = ComponentType<Unstable_AudioMessagePartProps>;
|
|
37
|
+
export type DataMessagePartProps<T = any> = MessagePartState & DataMessagePart<T>;
|
|
38
|
+
export type DataMessagePartComponent<T = any> = ComponentType<DataMessagePartProps<T>>;
|
|
39
|
+
export type ToolCallMessagePartProps<TArgs = any, TResult = unknown> = MessagePartState & ToolCallMessagePart<TArgs, TResult> & {
|
|
40
40
|
/**
|
|
41
41
|
* Sets the result for this tool-call message part.
|
|
42
42
|
*
|
|
@@ -62,9 +62,9 @@ type ToolCallMessagePartProps<TArgs = any, TResult = unknown> = MessagePartState
|
|
|
62
62
|
respondToApproval: (response: ToolApprovalResponse) => Promise<void>;
|
|
63
63
|
};
|
|
64
64
|
/** Component used to render a tool-call message part. */
|
|
65
|
-
type ToolCallMessagePartComponent<TArgs = any, TResult = any> = ComponentType<ToolCallMessagePartProps<TArgs, TResult>>;
|
|
66
|
-
type QuoteMessagePartProps = QuoteInfo;
|
|
67
|
-
type QuoteMessagePartComponent = ComponentType<QuoteMessagePartProps>;
|
|
65
|
+
export type ToolCallMessagePartComponent<TArgs = any, TResult = any> = ComponentType<ToolCallMessagePartProps<TArgs, TResult>>;
|
|
66
|
+
export type QuoteMessagePartProps = QuoteInfo;
|
|
67
|
+
export type QuoteMessagePartComponent = ComponentType<QuoteMessagePartProps>;
|
|
68
68
|
/**
|
|
69
69
|
* The consumer-provided allowlist of components a generative-ui spec is
|
|
70
70
|
* permitted to render. Keys are the component names referenced in the spec
|
|
@@ -73,10 +73,10 @@ type QuoteMessagePartComponent = ComponentType<QuoteMessagePartProps>;
|
|
|
73
73
|
* This registry is the security boundary in the same-realm rendering path —
|
|
74
74
|
* any name not present in the registry is rejected with a typed error.
|
|
75
75
|
*/
|
|
76
|
-
type GenerativeUIComponentRegistry = Record<string, ComponentType<any>>;
|
|
77
|
-
type GenerativeUIMessagePartProps = MessagePartState & GenerativeUIMessagePart;
|
|
78
|
-
type GenerativeUIMessagePartComponent = ComponentType<GenerativeUIMessagePartProps>;
|
|
79
|
-
type GenerativeUIRenderProps = {
|
|
76
|
+
export type GenerativeUIComponentRegistry = Record<string, ComponentType<any>>;
|
|
77
|
+
export type GenerativeUIMessagePartProps = MessagePartState & GenerativeUIMessagePart;
|
|
78
|
+
export type GenerativeUIMessagePartComponent = ComponentType<GenerativeUIMessagePartProps>;
|
|
79
|
+
export type GenerativeUIRenderProps = {
|
|
80
80
|
/** The JSON spec to render. */
|
|
81
81
|
spec: GenerativeUISpec;
|
|
82
82
|
/** The component allowlist. */
|
|
@@ -88,5 +88,4 @@ type GenerativeUIRenderProps = {
|
|
|
88
88
|
}> | undefined;
|
|
89
89
|
};
|
|
90
90
|
//#endregion
|
|
91
|
-
export { DataMessagePartComponent, DataMessagePartProps, EmptyMessagePartComponent, EmptyMessagePartProps, FileMessagePartComponent, FileMessagePartProps, GenerativeUIComponentRegistry, GenerativeUIMessagePartComponent, GenerativeUIMessagePartProps, GenerativeUIRenderProps, ImageMessagePartComponent, ImageMessagePartProps, QuoteMessagePartComponent, QuoteMessagePartProps, ReasoningGroupComponent, ReasoningGroupProps, ReasoningMessagePartComponent, ReasoningMessagePartProps, SourceMessagePartComponent, SourceMessagePartProps, TextMessagePartComponent, TextMessagePartProps, ToolCallMessagePartComponent, ToolCallMessagePartProps, Unstable_AudioMessagePartComponent, Unstable_AudioMessagePartProps };
|
|
92
91
|
//# sourceMappingURL=MessagePartComponentTypes.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"MessagePartComponentTypes.d.ts","names":[],"sources":["../../../src/react/types/MessagePartComponentTypes.ts"],"mappings":";;;;;;;
|
|
1
|
+
{"version":3,"file":"MessagePartComponentTypes.d.ts","names":[],"sources":["../../../src/react/types/MessagePartComponentTypes.ts"],"mappings":";;;;;;;YAmBY;EACV,QAAQ;;YAEE,4BAA4B,cAAc;YAE1C,uBAAuB,mBAAmB;YAC1C,2BAA2B,cAAc;YAEzC,4BAA4B,mBAAmB;YAC/C,gCACV,cAAc;YAEJ,sBAAsB;EAChC;EACA;;YAEU,0BAA0B,cAAc;YAExC,yBAAyB,mBAAmB;YAC5C,6BAA6B,cAAc;YAE3C,wBAAwB,mBAAmB;YAC3C,4BAA4B,cAAc;YAE1C,uBAAuB,mBAAmB;YAC1C,2BAA2B,cAAc;;;;;YAMzC,iCAAiC,mBAC3C;;;;;YAKU,qCACV,cAAc;YAEJ,qBAAqB,WAAW,mBAC1C,gBAAgB;YACN,yBAAyB,WAAW,cAC9C,qBAAqB;YAGX,yBACV,aACA,qBACE,mBACF,oBAAoB,OAAO;;;;;;;EAOzB,YAAY,QAAQ,UAAU,aAAa;;;;;EAK3C,SAAS;;;;;;;;;;;EAWT,oBAAoB,UAAU,yBAAyB;;;YAI/C,6BACV,aACA,iBACE,cAAc,yBAAyB,OAAO;YAEtC,wBAAwB;YACxB,4BAA4B,cAAc;;;;;;;;;YAU1C,gCAAgC,eAAe;YAE/C,+BAA+B,mBACzC;YACU,mCACV,cAAc;YAEJ;;EAEV,MAAM;;EAEN,YAAY;;EAEZ,WAAW;IAAgB;IAAmB"}
|
|
@@ -2,18 +2,17 @@ import { Unsubscribe } from "../../../types/unsubscribe.js";
|
|
|
2
2
|
import { DataMessagePartComponent } from "../MessagePartComponentTypes.js";
|
|
3
3
|
import "../../../index.js";
|
|
4
4
|
//#region src/react/types/scopes/dataRenderers.d.ts
|
|
5
|
-
type DataRenderersState = {
|
|
5
|
+
export type DataRenderersState = {
|
|
6
6
|
renderers: Record<string, DataMessagePartComponent[]>;
|
|
7
7
|
fallbacks: DataMessagePartComponent[];
|
|
8
8
|
};
|
|
9
|
-
type DataRenderersMethods = {
|
|
9
|
+
export type DataRenderersMethods = {
|
|
10
10
|
getState(): DataRenderersState;
|
|
11
11
|
setDataUI(name: string, render: DataMessagePartComponent): Unsubscribe;
|
|
12
12
|
setFallbackDataUI(render: DataMessagePartComponent): Unsubscribe;
|
|
13
13
|
};
|
|
14
|
-
type DataRenderersClientSchema = {
|
|
14
|
+
export type DataRenderersClientSchema = {
|
|
15
15
|
methods: DataRenderersMethods;
|
|
16
16
|
};
|
|
17
17
|
//#endregion
|
|
18
|
-
export { DataRenderersClientSchema, DataRenderersMethods, DataRenderersState };
|
|
19
18
|
//# sourceMappingURL=dataRenderers.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"dataRenderers.d.ts","names":[],"sources":["../../../../src/react/types/scopes/dataRenderers.ts"],"mappings":";;;;
|
|
1
|
+
{"version":3,"file":"dataRenderers.d.ts","names":[],"sources":["../../../../src/react/types/scopes/dataRenderers.ts"],"mappings":";;;;YAGY;EACV,WAAW,eAAe;EAC1B,WAAW;;YAGD;EACV,YAAY;EACZ,UAAU,cAAc,QAAQ,2BAA2B;EAC3D,kBAAkB,QAAQ,2BAA2B;;YAG3C;EACV,SAAS"}
|
|
@@ -7,11 +7,11 @@ import { Tool } from "assistant-stream";
|
|
|
7
7
|
* Schema type matching Tool["parameters"] from assistant-stream.
|
|
8
8
|
* Accepts both StandardSchemaV1 and JSONSchema7.
|
|
9
9
|
*/
|
|
10
|
-
type Unstable_InteractableStateSchema = NonNullable<Extract<Tool, {
|
|
10
|
+
export type Unstable_InteractableStateSchema = NonNullable<Extract<Tool, {
|
|
11
11
|
parameters: unknown;
|
|
12
12
|
}>["parameters"]>;
|
|
13
13
|
type InteractableScope = "app" | "thread";
|
|
14
|
-
type Unstable_InteractableDefinition = {
|
|
14
|
+
export type Unstable_InteractableDefinition = {
|
|
15
15
|
id: string;
|
|
16
16
|
name: string;
|
|
17
17
|
description: string;
|
|
@@ -20,7 +20,7 @@ type Unstable_InteractableDefinition = {
|
|
|
20
20
|
initialState: unknown;
|
|
21
21
|
scope?: InteractableScope | undefined;
|
|
22
22
|
};
|
|
23
|
-
type Unstable_InteractableRegistration = {
|
|
23
|
+
export type Unstable_InteractableRegistration = {
|
|
24
24
|
id: string;
|
|
25
25
|
name: string;
|
|
26
26
|
description: string;
|
|
@@ -33,21 +33,21 @@ type Unstable_InteractableRegistration = {
|
|
|
33
33
|
*/
|
|
34
34
|
updateRender?: ToolCallMessagePartComponent | undefined;
|
|
35
35
|
};
|
|
36
|
-
type Unstable_InteractablePersistenceStatus = {
|
|
36
|
+
export type Unstable_InteractablePersistenceStatus = {
|
|
37
37
|
isPending: boolean;
|
|
38
38
|
error: unknown;
|
|
39
39
|
};
|
|
40
|
-
type Unstable_InteractablesState = {
|
|
40
|
+
export type Unstable_InteractablesState = {
|
|
41
41
|
/** Keyed by instance id */
|
|
42
42
|
definitions: Record<string, Unstable_InteractableDefinition>;
|
|
43
43
|
/** Per-id persistence sync status */
|
|
44
44
|
persistence: Record<string, Unstable_InteractablePersistenceStatus>;
|
|
45
45
|
};
|
|
46
|
-
type Unstable_InteractablePersistedState = Record<string, {
|
|
46
|
+
export type Unstable_InteractablePersistedState = Record<string, {
|
|
47
47
|
name: string;
|
|
48
48
|
state: unknown;
|
|
49
49
|
}>;
|
|
50
|
-
type Unstable_InteractablePersistenceAdapter = {
|
|
50
|
+
export type Unstable_InteractablePersistenceAdapter = {
|
|
51
51
|
save(state: Unstable_InteractablePersistedState): void | Promise<void>;
|
|
52
52
|
/**
|
|
53
53
|
* Restores previously saved state. Called when the adapter is attached;
|
|
@@ -56,10 +56,10 @@ type Unstable_InteractablePersistenceAdapter = {
|
|
|
56
56
|
*/
|
|
57
57
|
load?(): Unstable_InteractablePersistedState | null | undefined | Promise<Unstable_InteractablePersistedState | null | undefined>;
|
|
58
58
|
};
|
|
59
|
-
type Unstable_InteractablesConfig = {
|
|
59
|
+
export type Unstable_InteractablesConfig = {
|
|
60
60
|
persistence?: Unstable_InteractablePersistenceAdapter | undefined;
|
|
61
61
|
};
|
|
62
|
-
type Unstable_InteractablesMethods = {
|
|
62
|
+
export type Unstable_InteractablesMethods = {
|
|
63
63
|
getState(): Unstable_InteractablesState;
|
|
64
64
|
register(def: Unstable_InteractableRegistration): Unsubscribe;
|
|
65
65
|
setState(id: string, updater: (prev: unknown) => unknown): void;
|
|
@@ -68,9 +68,8 @@ type Unstable_InteractablesMethods = {
|
|
|
68
68
|
setPersistenceAdapter(adapter: Unstable_InteractablePersistenceAdapter | undefined): void;
|
|
69
69
|
flush(): Promise<void>;
|
|
70
70
|
};
|
|
71
|
-
type Unstable_InteractablesClientSchema = {
|
|
71
|
+
export type Unstable_InteractablesClientSchema = {
|
|
72
72
|
methods: Unstable_InteractablesMethods;
|
|
73
73
|
};
|
|
74
74
|
//#endregion
|
|
75
|
-
export { Unstable_InteractableDefinition, Unstable_InteractablePersistedState, Unstable_InteractablePersistenceAdapter, Unstable_InteractablePersistenceStatus, Unstable_InteractableRegistration, Unstable_InteractableStateSchema, Unstable_InteractablesClientSchema, Unstable_InteractablesConfig, Unstable_InteractablesMethods, Unstable_InteractablesState };
|
|
76
75
|
//# sourceMappingURL=interactables.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"interactables.d.ts","names":[],"sources":["../../../../src/react/types/scopes/interactables.ts"],"mappings":";;;;;;;;;
|
|
1
|
+
{"version":3,"file":"interactables.d.ts","names":[],"sources":["../../../../src/react/types/scopes/interactables.ts"],"mappings":";;;;;;;;;YAQY,mCAAmC,YAC7C,QAAQ;EAAQ;;KAGb;YAEO;EACV;EACA;EACA;EACA,aAAa;EACb;EACA;EACA,QAAQ;;YAGE;EACV;EACA;EACA;EACA,aAAa;EACb;;;;;;EAMA,eAAe;;YAGL;EACV;EACA;;YAGU;;EAEV,aAAa,eAAe;;EAE5B,aAAa,eAAe;;YAGlB,sCAAsC;EAE9C;EAAc;;YAGN;EACV,KAAK,OAAO,6CAA6C;;;;;;EAMzD,SACI,yDAGA,QAAQ;;YAGF;EACV,cAAc;;YAGJ;EACV,YAAY;EACZ,SAAS,KAAK,oCAAoC;EAClD,SAAS,YAAY,UAAU;EAC/B,eAAe;EACf,YAAY,OAAO;EACnB,sBACE,SAAS;EAEX,SAAS;;YAGC;EACV,SAAS"}
|
|
@@ -3,7 +3,7 @@ import { ToolCallText } from "../../../model-context/tool-call-text.js";
|
|
|
3
3
|
import { ToolCallMessagePartComponent } from "../MessagePartComponentTypes.js";
|
|
4
4
|
import "../../../index.js";
|
|
5
5
|
//#region src/react/types/scopes/tools.d.ts
|
|
6
|
-
type McpAppResourceOutput = {
|
|
6
|
+
export type McpAppResourceOutput = {
|
|
7
7
|
readonly render: ToolCallMessagePartComponent;
|
|
8
8
|
};
|
|
9
9
|
/**
|
|
@@ -17,20 +17,19 @@ type ToolRegistration = {
|
|
|
17
17
|
/** Whether this UI renders standalone, outside the chain-of-thought trace. */
|
|
18
18
|
readonly standalone: boolean;
|
|
19
19
|
};
|
|
20
|
-
type ToolsState = {
|
|
20
|
+
export type ToolsState = {
|
|
21
21
|
/** Registered tool UIs (renderer + presentation options) keyed by tool name. */
|
|
22
22
|
toolUIs: Record<string, readonly ToolRegistration[]>;
|
|
23
23
|
mcpApp?: McpAppResourceOutput | undefined;
|
|
24
24
|
};
|
|
25
|
-
type ToolsMethods = {
|
|
25
|
+
export type ToolsMethods = {
|
|
26
26
|
getState(): ToolsState;
|
|
27
27
|
setToolUI(toolName: string, render: ToolCallMessagePartComponent, options?: {
|
|
28
28
|
standalone?: boolean;
|
|
29
29
|
}): Unsubscribe;
|
|
30
30
|
};
|
|
31
|
-
type ToolsClientSchema = {
|
|
31
|
+
export type ToolsClientSchema = {
|
|
32
32
|
methods: ToolsMethods;
|
|
33
33
|
};
|
|
34
34
|
//#endregion
|
|
35
|
-
export { McpAppResourceOutput, ToolsClientSchema, ToolsMethods, ToolsState };
|
|
36
35
|
//# sourceMappingURL=tools.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tools.d.ts","names":[],"sources":["../../../../src/react/types/scopes/tools.ts"],"mappings":";;;;;
|
|
1
|
+
{"version":3,"file":"tools.d.ts","names":[],"sources":["../../../../src/react/types/scopes/tools.ts"],"mappings":";;;;;YAIY;WACD,QAAQ;;;;;;;KAQd;WACM,QAAQ;WACR,aAAa;;WAEb;;YAGC;;EAEV,SAAS,wBAAwB;EACjC,SAAS;;YAGC;EACV,YAAY;EACZ,UACE,kBACA,QAAQ,8BACR;IAAY;MACX;;YAGO;EACV,SAAS"}
|
|
@@ -5,7 +5,6 @@ type MessageQuoteState = {
|
|
|
5
5
|
metadata?: unknown;
|
|
6
6
|
};
|
|
7
7
|
};
|
|
8
|
-
declare const getMessageQuote: (state: MessageQuoteState) => QuoteInfo | undefined;
|
|
8
|
+
export declare const getMessageQuote: (state: MessageQuoteState) => QuoteInfo | undefined;
|
|
9
9
|
//#endregion
|
|
10
|
-
export { getMessageQuote };
|
|
11
10
|
//# sourceMappingURL=getMessageQuote.d.ts.map
|