@8wave/ai-elements 0.121.0-beta.23 → 0.121.0-beta.25
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/ai-elements.es.js +1303 -1225
- package/dist/ai-elements.es.js.map +1 -1
- package/dist-vue/PkChatbot.js +1 -1
- package/dist-vue/PkChatbotViewChat.js +1 -1
- package/dist-vue/PkChatbotViewConversations.js +1 -1
- package/dist-vue/PkChatbotViewFiles.js +1 -1
- package/dist-vue/PkChatbotViewProfile.js +1 -1
- package/dist-vue/_chunks/{PkChatbot-BFjoa5Wf.js → PkChatbot-BF4OzQEE.js} +6 -6
- package/dist-vue/_chunks/{PkChatbot-BFjoa5Wf.js.map → PkChatbot-BF4OzQEE.js.map} +1 -1
- package/dist-vue/_chunks/{PkChatbotViewChat-BgQ5OhkA.js → PkChatbotViewChat-CZBRaIn-.js} +2 -2
- package/dist-vue/_chunks/{PkChatbotViewChat-BgQ5OhkA.js.map → PkChatbotViewChat-CZBRaIn-.js.map} +1 -1
- package/dist-vue/_chunks/{PkChatbotViewConversations-dKZScKD9.js → PkChatbotViewConversations-DSSWFPod.js} +2 -2
- package/dist-vue/_chunks/{PkChatbotViewConversations-dKZScKD9.js.map → PkChatbotViewConversations-DSSWFPod.js.map} +1 -1
- package/dist-vue/_chunks/{PkChatbotViewFiles-CQC3rInD.js → PkChatbotViewFiles-CnAKz2X8.js} +2 -2
- package/dist-vue/_chunks/{PkChatbotViewFiles-CQC3rInD.js.map → PkChatbotViewFiles-CnAKz2X8.js.map} +1 -1
- package/dist-vue/_chunks/{PkChatbotViewProfile-CkZyWh4V.js → PkChatbotViewProfile-42pXpWbn.js} +2 -2
- package/dist-vue/_chunks/{PkChatbotViewProfile-CkZyWh4V.js.map → PkChatbotViewProfile-42pXpWbn.js.map} +1 -1
- package/dist-vue/_chunks/{useChatbotStore-CBjfSN69.js → useChatbotStore-CnCoo6j3.js} +1164 -1085
- package/dist-vue/_chunks/useChatbotStore-CnCoo6j3.js.map +1 -0
- package/dist-vue/composables.js +3 -1
- package/dist-vue/composables.js.map +1 -1
- package/dist-vue/index.js +36 -36
- package/dist-vue/index.js.map +1 -1
- package/dist-vue/packages/composable/src/chatbot/useChatbotStore.d.ts +102 -7
- package/package.json +1 -1
- package/dist-vue/_chunks/useChatbotStore-CBjfSN69.js.map +0 -1
|
@@ -1,12 +1,11 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { PageAccessLevel, ChatMessageActions, UIChatMessage, AgentWidgetLayout, AgentWidgetAppearance, AgentLoaderStrategy, StoragePolicy, AgentSearchMode, AgentBuiltInTool, WebSearchProvider, PlatformType, ToolGroupKind, BlockedReasonCode, ConversationAnalysisTrigger, Sentiment, SentimentTrend, UserTone, AbuseCategory, LlmIssueCategory, UserEngagement, AbuseConfidence } from '../../../models/src';
|
|
1
|
+
import { FileUIPart, ChatStatus, ChatRequestOptions, ChatAddToolOutputFunction, ChatAddToolApproveResponseFunction, ProviderMetadata, LanguageModelUsage } from 'ai';
|
|
2
|
+
import { PageAccessLevel, ChatMessageActions, UIChatMessage, AgentWidgetLayout, AgentWidgetAppearance, AgentLoaderStrategy, StoragePolicy, AgentSearchMode, AgentBuiltInTool, WebSearchProvider, UIChatMessageMetadata, PlatformType, ToolGroupKind, BlockedReasonCode, ConversationAnalysisTrigger, Sentiment, SentimentTrend, UserTone, AbuseCategory, LlmIssueCategory, UserEngagement, AbuseConfidence } from '../../../models/src';
|
|
3
3
|
import { RegisteredHostTool } from './hostTools';
|
|
4
4
|
import { ChatbotFile } from './api';
|
|
5
5
|
import { PendingAttachment } from './types';
|
|
6
6
|
import { Store } from 'pinia';
|
|
7
7
|
import { ChatbotApiClient } from '../../../../apps/web-component/src/api';
|
|
8
8
|
import { SharedV4ProviderMetadata, JSONObject } from '@ai-sdk/provider';
|
|
9
|
-
import { ProviderMetadata, LanguageModelUsage, ChatRequestOptions } from 'ai';
|
|
10
9
|
export type { JSONObject } from '@ai-sdk/provider';
|
|
11
10
|
/**
|
|
12
11
|
* Id prefix of the spoken QUESTIONS the client shows before the server has
|
|
@@ -610,7 +609,39 @@ export declare function useChatbotStore(agentId: string): Store<`chatbot-${strin
|
|
|
610
609
|
systemTheme: globalThis.Ref<"light" | "dark" | undefined, "light" | "dark" | undefined>;
|
|
611
610
|
hideWelcomeMessage: globalThis.Ref<boolean, boolean>;
|
|
612
611
|
isDark: globalThis.ComputedRef<boolean>;
|
|
613
|
-
chat: globalThis.ComputedRef<
|
|
612
|
+
chat: globalThis.ComputedRef<{
|
|
613
|
+
id: string;
|
|
614
|
+
error: Error | undefined;
|
|
615
|
+
status: ChatStatus;
|
|
616
|
+
messages: UIChatMessage[];
|
|
617
|
+
regenerate: ({ messageId, ...options }?: {
|
|
618
|
+
messageId?: string;
|
|
619
|
+
} & ChatRequestOptions) => Promise<void>;
|
|
620
|
+
stop: () => Promise<void>;
|
|
621
|
+
sendMessage: (message?: (Omit<UIChatMessage, "id" | "role"> & {
|
|
622
|
+
id?: string | undefined;
|
|
623
|
+
role?: "assistant" | "user" | "system" | undefined;
|
|
624
|
+
} & {
|
|
625
|
+
text?: never;
|
|
626
|
+
files?: never;
|
|
627
|
+
messageId?: string;
|
|
628
|
+
}) | {
|
|
629
|
+
text: string;
|
|
630
|
+
files?: FileList | FileUIPart[];
|
|
631
|
+
metadata?: UIChatMessageMetadata | undefined;
|
|
632
|
+
parts?: never;
|
|
633
|
+
messageId?: string;
|
|
634
|
+
} | {
|
|
635
|
+
files: FileList | FileUIPart[];
|
|
636
|
+
metadata?: UIChatMessageMetadata | undefined;
|
|
637
|
+
parts?: never;
|
|
638
|
+
messageId?: string;
|
|
639
|
+
} | undefined, options?: ChatRequestOptions) => Promise<void>;
|
|
640
|
+
resumeStream: (options?: ChatRequestOptions) => Promise<void>;
|
|
641
|
+
addToolOutput: ChatAddToolOutputFunction<UIChatMessage>;
|
|
642
|
+
addToolApprovalResponse: ChatAddToolApproveResponseFunction;
|
|
643
|
+
clearError: () => void;
|
|
644
|
+
}>;
|
|
614
645
|
messages: globalThis.ComputedRef<UIChatMessage[]>;
|
|
615
646
|
conversations: globalThis.Ref<{
|
|
616
647
|
id: string;
|
|
@@ -2475,7 +2506,39 @@ export declare function useChatbotStore(agentId: string): Store<`chatbot-${strin
|
|
|
2475
2506
|
systemTheme: globalThis.Ref<"light" | "dark" | undefined, "light" | "dark" | undefined>;
|
|
2476
2507
|
hideWelcomeMessage: globalThis.Ref<boolean, boolean>;
|
|
2477
2508
|
isDark: globalThis.ComputedRef<boolean>;
|
|
2478
|
-
chat: globalThis.ComputedRef<
|
|
2509
|
+
chat: globalThis.ComputedRef<{
|
|
2510
|
+
id: string;
|
|
2511
|
+
error: Error | undefined;
|
|
2512
|
+
status: ChatStatus;
|
|
2513
|
+
messages: UIChatMessage[];
|
|
2514
|
+
regenerate: ({ messageId, ...options }?: {
|
|
2515
|
+
messageId?: string;
|
|
2516
|
+
} & ChatRequestOptions) => Promise<void>;
|
|
2517
|
+
stop: () => Promise<void>;
|
|
2518
|
+
sendMessage: (message?: (Omit<UIChatMessage, "id" | "role"> & {
|
|
2519
|
+
id?: string | undefined;
|
|
2520
|
+
role?: "assistant" | "user" | "system" | undefined;
|
|
2521
|
+
} & {
|
|
2522
|
+
text?: never;
|
|
2523
|
+
files?: never;
|
|
2524
|
+
messageId?: string;
|
|
2525
|
+
}) | {
|
|
2526
|
+
text: string;
|
|
2527
|
+
files?: FileList | FileUIPart[];
|
|
2528
|
+
metadata?: UIChatMessageMetadata | undefined;
|
|
2529
|
+
parts?: never;
|
|
2530
|
+
messageId?: string;
|
|
2531
|
+
} | {
|
|
2532
|
+
files: FileList | FileUIPart[];
|
|
2533
|
+
metadata?: UIChatMessageMetadata | undefined;
|
|
2534
|
+
parts?: never;
|
|
2535
|
+
messageId?: string;
|
|
2536
|
+
} | undefined, options?: ChatRequestOptions) => Promise<void>;
|
|
2537
|
+
resumeStream: (options?: ChatRequestOptions) => Promise<void>;
|
|
2538
|
+
addToolOutput: ChatAddToolOutputFunction<UIChatMessage>;
|
|
2539
|
+
addToolApprovalResponse: ChatAddToolApproveResponseFunction;
|
|
2540
|
+
clearError: () => void;
|
|
2541
|
+
}>;
|
|
2479
2542
|
messages: globalThis.ComputedRef<UIChatMessage[]>;
|
|
2480
2543
|
conversations: globalThis.Ref<{
|
|
2481
2544
|
id: string;
|
|
@@ -4340,7 +4403,39 @@ export declare function useChatbotStore(agentId: string): Store<`chatbot-${strin
|
|
|
4340
4403
|
systemTheme: globalThis.Ref<"light" | "dark" | undefined, "light" | "dark" | undefined>;
|
|
4341
4404
|
hideWelcomeMessage: globalThis.Ref<boolean, boolean>;
|
|
4342
4405
|
isDark: globalThis.ComputedRef<boolean>;
|
|
4343
|
-
chat: globalThis.ComputedRef<
|
|
4406
|
+
chat: globalThis.ComputedRef<{
|
|
4407
|
+
id: string;
|
|
4408
|
+
error: Error | undefined;
|
|
4409
|
+
status: ChatStatus;
|
|
4410
|
+
messages: UIChatMessage[];
|
|
4411
|
+
regenerate: ({ messageId, ...options }?: {
|
|
4412
|
+
messageId?: string;
|
|
4413
|
+
} & ChatRequestOptions) => Promise<void>;
|
|
4414
|
+
stop: () => Promise<void>;
|
|
4415
|
+
sendMessage: (message?: (Omit<UIChatMessage, "id" | "role"> & {
|
|
4416
|
+
id?: string | undefined;
|
|
4417
|
+
role?: "assistant" | "user" | "system" | undefined;
|
|
4418
|
+
} & {
|
|
4419
|
+
text?: never;
|
|
4420
|
+
files?: never;
|
|
4421
|
+
messageId?: string;
|
|
4422
|
+
}) | {
|
|
4423
|
+
text: string;
|
|
4424
|
+
files?: FileList | FileUIPart[];
|
|
4425
|
+
metadata?: UIChatMessageMetadata | undefined;
|
|
4426
|
+
parts?: never;
|
|
4427
|
+
messageId?: string;
|
|
4428
|
+
} | {
|
|
4429
|
+
files: FileList | FileUIPart[];
|
|
4430
|
+
metadata?: UIChatMessageMetadata | undefined;
|
|
4431
|
+
parts?: never;
|
|
4432
|
+
messageId?: string;
|
|
4433
|
+
} | undefined, options?: ChatRequestOptions) => Promise<void>;
|
|
4434
|
+
resumeStream: (options?: ChatRequestOptions) => Promise<void>;
|
|
4435
|
+
addToolOutput: ChatAddToolOutputFunction<UIChatMessage>;
|
|
4436
|
+
addToolApprovalResponse: ChatAddToolApproveResponseFunction;
|
|
4437
|
+
clearError: () => void;
|
|
4438
|
+
}>;
|
|
4344
4439
|
messages: globalThis.ComputedRef<UIChatMessage[]>;
|
|
4345
4440
|
conversations: globalThis.Ref<{
|
|
4346
4441
|
id: string;
|
|
@@ -5634,4 +5729,4 @@ export declare function useChatbotStore(agentId: string): Store<`chatbot-${strin
|
|
|
5634
5729
|
navigate: (view: ChatbotView) => void;
|
|
5635
5730
|
renameChatTitle: (chatId: string, title: string) => Promise<void>;
|
|
5636
5731
|
deleteChat: (chatId: string) => Promise<void>;
|
|
5637
|
-
}, "regenerate" | "stopHostActions" | "closePageNotice" | "respondHostConfirmation" | "setPageAccessOff" | "buildDeviceContext" | "initialize" | "loadConversations" | "loadChatFiles" | "refreshMessages" | "appendMessage" | "getChatFileUrl" | "getChatFilePreviewUrl" | "deleteChatFile" | "handleSubmit" | "
|
|
5732
|
+
}, "regenerate" | "sendMessage" | "addToolOutput" | "addToolApprovalResponse" | "stopHostActions" | "closePageNotice" | "respondHostConfirmation" | "setPageAccessOff" | "buildDeviceContext" | "initialize" | "loadConversations" | "loadChatFiles" | "refreshMessages" | "appendMessage" | "getChatFileUrl" | "getChatFilePreviewUrl" | "deleteChatFile" | "handleSubmit" | "stopGeneration" | "startNewChat" | "handleFileSelect" | "clearFileLimitError" | "clearPendingAttachments" | "onUpvote" | "onDownvote" | "onFeedback" | "onFeedbackSubmit" | "onLeadSubmit" | "navigate" | "renameChatTitle" | "deleteChat">>;
|