@opentiny/tiny-robot 0.3.1-alpha.4 → 0.4.0-alpha.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.ts CHANGED
@@ -9,7 +9,6 @@ import { ComponentOptionsMixin } from 'vue';
9
9
  import { ComponentProvideOptions } from 'vue';
10
10
  import { ComponentPublicInstance } from 'vue';
11
11
  import { ComputedRef } from 'vue';
12
- import { Config } from 'dompurify';
13
12
  import { CreateComponentPublicInstanceWithMixins } from 'vue';
14
13
  import { CSSProperties } from 'vue';
15
14
  import { DebuggerEvent } from 'vue';
@@ -20,7 +19,6 @@ import { GlobalComponents } from 'vue';
20
19
  import { GlobalDirectives } from 'vue';
21
20
  import { nextTick } from 'vue';
22
21
  import { OnCleanup } from '@vue/reactivity';
23
- import { Options } from 'markdown-it';
24
22
  import { PropType } from 'vue';
25
23
  import { PublicProps } from 'vue';
26
24
  import { Ref } from 'vue';
@@ -35,13 +33,34 @@ import { WatchOptions } from 'vue';
35
33
  import { WatchStopHandle } from 'vue';
36
34
 
37
35
  declare const __VLS_component: DefineComponent<BubbleProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<BubbleProps> & Readonly<{}>, {
38
- content: string | BubbleContentItem[];
39
36
  placement: "start" | "end";
40
- shape: "rounded" | "corner";
41
- abortedText: string;
42
- }, {}, {}, {}, string, ComponentProvideOptions, false, {}, HTMLDivElement>;
37
+ shape: "rounded" | "corner" | "none";
38
+ splitPolymorphic: boolean;
39
+ }, {}, {}, {}, string, ComponentProvideOptions, false, {}, any>;
40
+
41
+ declare const __VLS_component_10: DefineComponent<SuggestionPillButtonProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<SuggestionPillButtonProps> & Readonly<{}>, {}, {}, {}, {}, string, ComponentProvideOptions, false, {}, HTMLButtonElement>;
43
42
 
44
- declare const __VLS_component_10: DefineComponent<__VLS_PublicProps_4, {
43
+ declare const __VLS_component_11: DefineComponent<__VLS_PublicProps_3, {
44
+ children: ComputedRef<(HTMLElement | SVGElement)[]>;
45
+ }, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {
46
+ "update:showAll": (value: boolean | undefined) => any;
47
+ } & {
48
+ "click-outside": (event: MouseEvent) => any;
49
+ }, string, PublicProps, Readonly<__VLS_PublicProps_3> & Readonly<{
50
+ "onClick-outside"?: ((event: MouseEvent) => any) | undefined;
51
+ "onUpdate:showAll"?: ((value: boolean | undefined) => any) | undefined;
52
+ }>, {
53
+ showAllButtonOn: "hover" | "always";
54
+ overflowMode: "expand" | "scroll";
55
+ }, {}, {}, {}, string, ComponentProvideOptions, false, {
56
+ containerWrapperRef: HTMLDivElement;
57
+ containerRef: HTMLDivElement;
58
+ staticMaybeItemRefs: unknown[];
59
+ floatingItemsRef: HTMLDivElement;
60
+ floatingMaybeItemRefs: unknown[];
61
+ }, HTMLDivElement>;
62
+
63
+ declare const __VLS_component_12: DefineComponent<__VLS_PublicProps_4, {
45
64
  update: () => void;
46
65
  }, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {
47
66
  "update:selectedGroup": (value: string) => any;
@@ -177,7 +196,7 @@ show?: TooltipContentProps["show"];
177
196
  }>, {}, {}, {}, {}, {}> | null;
178
197
  }, any>;
179
198
 
180
- declare const __VLS_component_11: DefineComponent<__VLS_PublicProps_5, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {
199
+ declare const __VLS_component_13: DefineComponent<__VLS_PublicProps_5, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {
181
200
  "update:theme": (value: string) => any;
182
201
  "update:colorMode": (value: ColorMode) => any;
183
202
  }, string, PublicProps, Readonly<__VLS_PublicProps_5> & Readonly<{
@@ -188,15 +207,20 @@ targetElement: string;
188
207
  storageKey: string;
189
208
  }, {}, {}, {}, string, ComponentProvideOptions, false, {}, any>;
190
209
 
191
- declare const __VLS_component_12: DefineComponent<WelcomeProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<WelcomeProps> & Readonly<{}>, {
210
+ declare const __VLS_component_14: DefineComponent<WelcomeProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<WelcomeProps> & Readonly<{}>, {
192
211
  align: "left" | "center" | "right" | string;
193
212
  }, {}, {}, {}, string, ComponentProvideOptions, false, {}, HTMLDivElement>;
194
213
 
195
- declare const __VLS_component_2: DefineComponent<__VLS_Props, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {
196
- contentRenderers: Record<string, BubbleContentRenderer>;
197
- }, {}, {}, {}, string, ComponentProvideOptions, false, {}, any>;
214
+ declare const __VLS_component_2: DefineComponent<BubbleListProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<BubbleListProps> & Readonly<{}>, {
215
+ groupStrategy: "consecutive" | "divider" | ((messages: BubbleMessage[], dividerRole?: string) => BubbleMessageGroup[]);
216
+ dividerRole: string;
217
+ }, {}, {}, {}, string, ComponentProvideOptions, false, {}, HTMLDivElement>;
198
218
 
199
- declare const __VLS_component_3: DefineComponent<__VLS_PublicProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {
219
+ declare const __VLS_component_3: DefineComponent<BubbleProviderProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<BubbleProviderProps> & Readonly<{}>, {}, {}, {}, {}, string, ComponentProvideOptions, false, {}, any>;
220
+
221
+ declare const __VLS_component_4: DefineComponent<BubbleBoxProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<BubbleBoxProps> & Readonly<{}>, {}, {}, {}, {}, string, ComponentProvideOptions, false, {}, HTMLDivElement>;
222
+
223
+ declare const __VLS_component_5: DefineComponent<__VLS_PublicProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {
200
224
  "update:show": (value: boolean) => any;
201
225
  "update:fullscreen": (value: boolean | undefined) => any;
202
226
  } & {
@@ -209,9 +233,9 @@ onClose?: (() => any) | undefined;
209
233
  title: string;
210
234
  }, {}, {}, {}, string, ComponentProvideOptions, false, {}, HTMLDivElement>;
211
235
 
212
- declare const __VLS_component_4: DefineComponent<DragOverlayProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<DragOverlayProps> & Readonly<{}>, {}, {}, {}, {}, string, ComponentProvideOptions, false, {}, any>;
236
+ declare const __VLS_component_6: DefineComponent<DragOverlayProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<DragOverlayProps> & Readonly<{}>, {}, {}, {}, {}, string, ComponentProvideOptions, false, {}, any>;
213
237
 
214
- declare const __VLS_component_5: DefineComponent<__VLS_PublicProps_2, {
238
+ declare const __VLS_component_7: DefineComponent<__VLS_PublicProps_2, {
215
239
  update: () => void;
216
240
  }, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {
217
241
  "update:show": (value: boolean) => any;
@@ -319,13 +343,13 @@ content?: () => VNode[];
319
343
  }) | null;
320
344
  }, any>;
321
345
 
322
- declare const __VLS_component_6: DefineComponent<PromptsProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {} & {
346
+ declare const __VLS_component_8: DefineComponent<PromptsProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {} & {
323
347
  "item-click": (ev: MouseEvent, item: PromptProps) => any;
324
348
  }, string, PublicProps, Readonly<PromptsProps> & Readonly<{
325
349
  "onItem-click"?: ((ev: MouseEvent, item: PromptProps) => any) | undefined;
326
350
  }>, {}, {}, {}, {}, string, ComponentProvideOptions, false, {}, HTMLDivElement>;
327
351
 
328
- declare const __VLS_component_7: DefineComponent<SenderProps, {
352
+ declare const __VLS_component_9: DefineComponent<SenderProps, {
329
353
  focus: () => void;
330
354
  blur: () => void;
331
355
  clear: () => void;
@@ -369,8 +393,8 @@ onSubmit?: ((value: string) => any) | undefined;
369
393
  disabled: boolean;
370
394
  modelValue: string;
371
395
  placeholder: string;
372
- mode: InputMode;
373
396
  loading: boolean;
397
+ mode: InputMode;
374
398
  autofocus: boolean;
375
399
  allowSpeech: boolean;
376
400
  allowFiles: boolean;
@@ -880,35 +904,11 @@ inputBoxType: string;
880
904
  buttonsContainerRef: HTMLDivElement;
881
905
  }, HTMLDivElement>;
882
906
 
883
- declare const __VLS_component_8: DefineComponent<SuggestionPillButtonProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<SuggestionPillButtonProps> & Readonly<{}>, {}, {}, {}, {}, string, ComponentProvideOptions, false, {}, HTMLButtonElement>;
884
-
885
- declare const __VLS_component_9: DefineComponent<__VLS_PublicProps_3, {
886
- children: ComputedRef<(HTMLElement | SVGElement)[]>;
887
- }, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {
888
- "update:showAll": (value: boolean | undefined) => any;
889
- } & {
890
- "click-outside": (event: MouseEvent) => any;
891
- }, string, PublicProps, Readonly<__VLS_PublicProps_3> & Readonly<{
892
- "onClick-outside"?: ((event: MouseEvent) => any) | undefined;
893
- "onUpdate:showAll"?: ((value: boolean | undefined) => any) | undefined;
894
- }>, {
895
- showAllButtonOn: "hover" | "always";
896
- overflowMode: "expand" | "scroll";
897
- }, {}, {}, {}, string, ComponentProvideOptions, false, {
898
- containerWrapperRef: HTMLDivElement;
899
- containerRef: HTMLDivElement;
900
- staticMaybeItemRefs: unknown[];
901
- floatingItemsRef: HTMLDivElement;
902
- floatingMaybeItemRefs: unknown[];
903
- }, HTMLDivElement>;
904
-
905
907
  declare type __VLS_PrettifyLocal<T> = {
906
908
  [K in keyof T]: T[K];
907
909
  } & {};
908
910
 
909
- declare type __VLS_Props = {
910
- contentRenderers?: Record<string, BubbleContentRenderer>;
911
- };
911
+ declare type __VLS_Props = BubbleRendererMessage<string | BubbleChatMessageItem | undefined>;
912
912
 
913
913
  declare type __VLS_Props_2 = ContainerProps;
914
914
 
@@ -952,10 +952,30 @@ declare function __VLS_template(): {
952
952
  attrs: Partial<{}>;
953
953
  slots: Readonly<BubbleSlots> & BubbleSlots;
954
954
  refs: {};
955
- rootEl: HTMLDivElement;
955
+ rootEl: any;
956
956
  };
957
957
 
958
958
  declare function __VLS_template_10(): {
959
+ attrs: Partial<{}>;
960
+ slots: Readonly<SuggestionPillButtonSlots> & SuggestionPillButtonSlots;
961
+ refs: {};
962
+ rootEl: HTMLButtonElement;
963
+ };
964
+
965
+ declare function __VLS_template_11(): {
966
+ attrs: Partial<{}>;
967
+ slots: Readonly<SuggestionPillsSlots> & SuggestionPillsSlots;
968
+ refs: {
969
+ containerWrapperRef: HTMLDivElement;
970
+ containerRef: HTMLDivElement;
971
+ staticMaybeItemRefs: unknown[];
972
+ floatingItemsRef: HTMLDivElement;
973
+ floatingMaybeItemRefs: unknown[];
974
+ };
975
+ rootEl: HTMLDivElement;
976
+ };
977
+
978
+ declare function __VLS_template_12(): {
959
979
  attrs: Partial<{}>;
960
980
  slots: Readonly<SuggestionPopoverSlots> & SuggestionPopoverSlots;
961
981
  refs: {
@@ -1074,7 +1094,7 @@ declare function __VLS_template_10(): {
1074
1094
  rootEl: any;
1075
1095
  };
1076
1096
 
1077
- declare function __VLS_template_11(): {
1097
+ declare function __VLS_template_13(): {
1078
1098
  attrs: Partial<{}>;
1079
1099
  slots: {
1080
1100
  default?(_: {}): any;
@@ -1083,7 +1103,7 @@ declare function __VLS_template_11(): {
1083
1103
  rootEl: any;
1084
1104
  };
1085
1105
 
1086
- declare function __VLS_template_12(): {
1106
+ declare function __VLS_template_14(): {
1087
1107
  attrs: Partial<{}>;
1088
1108
  slots: Readonly<WelcomeSlots> & WelcomeSlots;
1089
1109
  refs: {};
@@ -1091,6 +1111,13 @@ declare function __VLS_template_12(): {
1091
1111
  };
1092
1112
 
1093
1113
  declare function __VLS_template_2(): {
1114
+ attrs: Partial<{}>;
1115
+ slots: Readonly<BubbleListSlots> & BubbleListSlots;
1116
+ refs: {};
1117
+ rootEl: HTMLDivElement;
1118
+ };
1119
+
1120
+ declare function __VLS_template_3(): {
1094
1121
  attrs: Partial<{}>;
1095
1122
  slots: {
1096
1123
  default?(_: {}): any;
@@ -1099,14 +1126,23 @@ declare function __VLS_template_2(): {
1099
1126
  rootEl: any;
1100
1127
  };
1101
1128
 
1102
- declare function __VLS_template_3(): {
1129
+ declare function __VLS_template_4(): {
1130
+ attrs: Partial<{}>;
1131
+ slots: {
1132
+ default?(_: {}): any;
1133
+ };
1134
+ refs: {};
1135
+ rootEl: HTMLDivElement;
1136
+ };
1137
+
1138
+ declare function __VLS_template_5(): {
1103
1139
  attrs: Partial<{}>;
1104
1140
  slots: Readonly<ContainerSlots> & ContainerSlots;
1105
1141
  refs: {};
1106
1142
  rootEl: HTMLDivElement;
1107
1143
  };
1108
1144
 
1109
- declare function __VLS_template_4(): {
1145
+ declare function __VLS_template_6(): {
1110
1146
  attrs: Partial<{}>;
1111
1147
  slots: {
1112
1148
  overlay?(_: {
@@ -1117,7 +1153,7 @@ declare function __VLS_template_4(): {
1117
1153
  rootEl: any;
1118
1154
  };
1119
1155
 
1120
- declare function __VLS_template_5(): {
1156
+ declare function __VLS_template_7(): {
1121
1157
  attrs: Partial<{}>;
1122
1158
  slots: {
1123
1159
  trigger?(_: {}): any;
@@ -1219,14 +1255,14 @@ declare function __VLS_template_5(): {
1219
1255
  rootEl: any;
1220
1256
  };
1221
1257
 
1222
- declare function __VLS_template_6(): {
1258
+ declare function __VLS_template_8(): {
1223
1259
  attrs: Partial<{}>;
1224
1260
  slots: Readonly<PromptsSlots> & PromptsSlots;
1225
1261
  refs: {};
1226
1262
  rootEl: HTMLDivElement;
1227
1263
  };
1228
1264
 
1229
- declare function __VLS_template_7(): {
1265
+ declare function __VLS_template_9(): {
1230
1266
  attrs: Partial<{}>;
1231
1267
  slots: {
1232
1268
  header?(_: {}): any;
@@ -1736,26 +1772,6 @@ declare function __VLS_template_7(): {
1736
1772
  rootEl: HTMLDivElement;
1737
1773
  };
1738
1774
 
1739
- declare function __VLS_template_8(): {
1740
- attrs: Partial<{}>;
1741
- slots: Readonly<SuggestionPillButtonSlots> & SuggestionPillButtonSlots;
1742
- refs: {};
1743
- rootEl: HTMLButtonElement;
1744
- };
1745
-
1746
- declare function __VLS_template_9(): {
1747
- attrs: Partial<{}>;
1748
- slots: Readonly<SuggestionPillsSlots> & SuggestionPillsSlots;
1749
- refs: {
1750
- containerWrapperRef: HTMLDivElement;
1751
- containerRef: HTMLDivElement;
1752
- staticMaybeItemRefs: unknown[];
1753
- floatingItemsRef: HTMLDivElement;
1754
- floatingMaybeItemRefs: unknown[];
1755
- };
1756
- rootEl: HTMLDivElement;
1757
- };
1758
-
1759
1775
  declare type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
1760
1776
 
1761
1777
  declare type __VLS_TemplateResult_10 = ReturnType<typeof __VLS_template_10>;
@@ -1764,6 +1780,10 @@ declare type __VLS_TemplateResult_11 = ReturnType<typeof __VLS_template_11>;
1764
1780
 
1765
1781
  declare type __VLS_TemplateResult_12 = ReturnType<typeof __VLS_template_12>;
1766
1782
 
1783
+ declare type __VLS_TemplateResult_13 = ReturnType<typeof __VLS_template_13>;
1784
+
1785
+ declare type __VLS_TemplateResult_14 = ReturnType<typeof __VLS_template_14>;
1786
+
1767
1787
  declare type __VLS_TemplateResult_2 = ReturnType<typeof __VLS_template_2>;
1768
1788
 
1769
1789
  declare type __VLS_TemplateResult_3 = ReturnType<typeof __VLS_template_3>;
@@ -1804,6 +1824,18 @@ declare type __VLS_WithTemplateSlots_12<T, S> = T & {
1804
1824
  };
1805
1825
  };
1806
1826
 
1827
+ declare type __VLS_WithTemplateSlots_13<T, S> = T & {
1828
+ new (): {
1829
+ $slots: S;
1830
+ };
1831
+ };
1832
+
1833
+ declare type __VLS_WithTemplateSlots_14<T, S> = T & {
1834
+ new (): {
1835
+ $slots: S;
1836
+ };
1837
+ };
1838
+
1807
1839
  declare type __VLS_WithTemplateSlots_2<T, S> = T & {
1808
1840
  new (): {
1809
1841
  $slots: S;
@@ -1925,67 +1957,89 @@ declare interface BaseTextItem {
1925
1957
  content: string;
1926
1958
  }
1927
1959
 
1928
- declare const Bubble: typeof _default_18 & {
1960
+ declare const Bubble: typeof _default_20 & {
1929
1961
  install: typeof bubbleInstall;
1930
1962
  };
1931
1963
  export { Bubble }
1932
1964
  export { Bubble as TrBubble }
1933
1965
 
1934
- export declare interface BubbleCommonProps {
1935
- /**
1936
- * 气泡对齐位置
1937
- */
1938
- placement?: 'start' | 'end';
1939
- /**
1940
- * 气泡头像
1941
- */
1942
- avatar?: VNode;
1943
- /**
1944
- * 气泡形状,默认 'corner'
1945
- */
1946
- shape?: 'rounded' | 'corner';
1947
- /**
1948
- * 气泡内容渲染器。
1949
- * 如果 Bubble 中的 content 是长度大于 0 的数组,则 contentRenderer 无效。将会使用 BubbleProvider 中注册的渲染器
1950
- */
1951
- contentRenderer?: BubbleContentRenderer;
1952
- /**
1953
- * 自定义气泡内容字段。比如 customContentField 设置为 'my-content',则 Bubble 优先渲染 my-content 属性到气泡内容
1954
- */
1955
- customContentField?: string;
1966
+ /**
1967
+ * 基础消息类型(移除了样式相关属性)
1968
+ */
1969
+ declare type BubbleBaseMessage = Omit<BubbleProps, 'content' | 'role' | 'avatar' | 'placement' | 'shape' | 'splitPolymorphic'> & {
1970
+ role: string;
1971
+ };
1972
+
1973
+ /**
1974
+ * 气泡容器属性
1975
+ */
1976
+ export declare type BubbleBoxProps = Pick<BubbleProps, 'placement' | 'shape'>;
1977
+
1978
+ export declare type BubbleBoxRendererMatch = {
1979
+ find: (props: BubbleContentBoxProps) => boolean;
1980
+ renderer: Component;
1981
+ priority?: number;
1982
+ };
1983
+
1984
+ /**
1985
+ * 聊天消息接口(支持 OpenAI 格式)
1986
+ */
1987
+ export declare interface BubbleChatMessage {
1988
+ role: string;
1989
+ content?: string | BubbleChatMessageItem[];
1990
+ reasoning_content?: string;
1991
+ tool_calls?: ToolCall[];
1992
+ tool_call_id?: string;
1993
+ name?: string;
1994
+ }
1995
+
1996
+ /**
1997
+ * 多态内容项
1998
+ * 用于支持多种内容类型(文本、图片、音频等)
1999
+ */
2000
+ export declare interface BubbleChatMessageItem {
1956
2001
  /**
1957
- * 气泡中止文本
2002
+ * 内容类型标识符(例如:'text'、'image_url' 等)
1958
2003
  */
1959
- abortedText?: string;
2004
+ type?: string;
1960
2005
  /**
1961
- * 气泡最大宽度
2006
+ * 内容类型特定的附加属性
1962
2007
  */
1963
- maxWidth?: string | number;
2008
+ [key: string]: unknown;
1964
2009
  }
1965
2010
 
1966
- export declare abstract class BubbleContentClassRenderer {
1967
- abstract render(options: {
1968
- [key: string]: any;
1969
- }): VNode;
1970
- }
2011
+ /**
2012
+ * ContentBox 组件 Props
2013
+ */
2014
+ export declare type BubbleContentBoxProps = BubbleBoxProps & {
2015
+ messages: BubbleRendererMessage[];
2016
+ };
1971
2017
 
1972
- export declare type BubbleContentFunctionRenderer = (options: {
1973
- [key: string]: any;
1974
- }) => VNode;
2018
+ export declare type BubbleContentRendererMatch = {
2019
+ find: (message: BubbleRendererMessage) => boolean;
2020
+ renderer: Component;
2021
+ priority?: number;
2022
+ };
1975
2023
 
1976
- export declare interface BubbleContentItem {
1977
- type: string;
1978
- [key: string]: any;
2024
+ /**
2025
+ * 自定义分组函数类型
2026
+ */
2027
+ declare type BubbleGroupFunction = (messages: BubbleMessage[], dividerRole?: string) => BubbleMessageGroup[];
2028
+
2029
+ declare const bubbleInstall: (app: App) => void;
2030
+
2031
+ export declare interface BubbleItemSlot {
2032
+ prefix?: (slotProps: BubbleItemSlotProps) => VNode | VNode[];
2033
+ suffix?: (slotProps: BubbleItemSlotProps) => VNode | VNode[];
2034
+ 'content-footer'?: (slotProps: BubbleItemSlotProps) => VNode | VNode[];
2035
+ after?: (slotProps: BubbleItemSlotProps) => VNode | VNode[];
1979
2036
  }
1980
2037
 
1981
- export declare type BubbleContentRenderer = BubbleContentFunctionRenderer | BubbleContentClassRenderer | Component | {
1982
- component: Component;
1983
- defaultProps: Record<string, unknown>;
2038
+ declare type BubbleItemSlotProps = BubbleSlotProps & {
2039
+ messages: BubbleMessage[];
1984
2040
  };
1985
2041
 
1986
- declare const bubbleInstall: (app: App) => void;
1987
-
1988
- declare const BubbleList: typeof _default_19 & {
2042
+ declare const BubbleList: typeof _default_21 & {
1989
2043
  install: typeof bubbleListInstall;
1990
2044
  };
1991
2045
  export { BubbleList }
@@ -1993,59 +2047,133 @@ export { BubbleList as TrBubbleList }
1993
2047
 
1994
2048
  declare const bubbleListInstall: (app: App) => void;
1995
2049
 
2050
+ /**
2051
+ * BubbleList 组件 Props
2052
+ * 用于管理消息流和分组策略
2053
+ */
1996
2054
  export declare interface BubbleListProps {
1997
- items: (BubbleProps & {
1998
- slots?: BubbleSlots;
1999
- })[];
2055
+ messages: BubbleMessage[];
2000
2056
  /**
2001
- * 每个角色的默认配置项
2057
+ * 分组策略:
2058
+ * - 'consecutive': 连续相同角色的消息合并为一组
2059
+ * - 'divider': 按分割角色分组(连续的分割角色在一组,其他消息在另一组)
2060
+ * - 自定义函数: (messages, dividerRole) => BubbleMessageGroup[]
2061
+ *
2062
+ * 特殊情况:
2063
+ * - 当 message 的 content 为数组时,该 message 会被单独作为一个独立分组
2064
+ * - 该独立分组会被"密封",后续的消息(即使角色相同)也不会被添加到这个分组中
2002
2065
  */
2003
- roles?: Record<string, BubbleRoleConfig>;
2066
+ groupStrategy?: 'consecutive' | 'divider' | BubbleGroupFunction;
2004
2067
  /**
2005
- * 列表是否加载中
2068
+ * 'divider' 策略的分割角色
2069
+ * 具有此角色的消息将作为分割线
2070
+ * @default 'user'
2006
2071
  */
2007
- loading?: boolean;
2072
+ dividerRole?: string;
2008
2073
  /**
2009
- * 指定哪个角色可以有加载中状态
2074
+ * 角色配置(头像、位置、形状)
2010
2075
  */
2011
- loadingRole?: string;
2012
- autoScroll?: boolean;
2076
+ roleConfigs?: Record<string, BubbleRoleConfig>;
2077
+ /**
2078
+ * 是否拆分多态内容配置
2079
+ */
2080
+ splitPolymorphic?: BubbleProps['splitPolymorphic'];
2013
2081
  }
2014
2082
 
2015
- export declare class BubbleMarkdownContentRenderer extends BubbleContentClassRenderer {
2016
- readonly mdConfig: Options;
2017
- readonly dompurifyConfig: Config;
2018
- readonly sanitizeDisabled: boolean;
2019
- readonly defaultAttrs: Record<string, unknown>;
2020
- private md;
2021
- constructor(options?: BubbleMarkdownRendererOptions);
2022
- render(options: {
2023
- content?: string;
2024
- [key: string]: unknown;
2025
- }): VNode<RendererNode, RendererElement, {
2026
- [key: string]: any;
2027
- }>;
2028
- }
2083
+ declare type BubbleListSlotProps = BubbleItemSlotProps & {
2084
+ messageIndexes: number[];
2085
+ };
2029
2086
 
2030
- declare interface BubbleMarkdownRendererOptions {
2031
- mdConfig?: Options;
2032
- dompurifyConfig?: Config;
2033
- sanitizeDisabled?: boolean;
2034
- defaultAttrs?: Record<string, unknown>;
2087
+ export declare interface BubbleListSlots {
2088
+ prefix?: (slotProps: BubbleListSlotProps) => VNode | VNode[];
2089
+ suffix?: (slotProps: BubbleListSlotProps) => VNode | VNode[];
2090
+ 'content-footer'?: (slotProps: BubbleListSlotProps) => VNode | VNode[];
2091
+ after?: (slotProps: BubbleListSlotProps) => VNode | VNode[];
2035
2092
  }
2036
2093
 
2037
- export declare interface BubbleProps extends BubbleCommonProps {
2094
+ /**
2095
+ * 统一消息类型
2096
+ */
2097
+ export declare type BubbleMessage = BubblePlainMessage | BubblePolymorphicMessage;
2098
+
2099
+ /**
2100
+ * 统一分组类型
2101
+ */
2102
+ export declare type BubbleMessageGroup = BubblePlainMessageGroup | BubblePolymorphicMessageGroup;
2103
+
2104
+ /**
2105
+ * 普通消息(字符串内容)
2106
+ */
2107
+ export declare type BubblePlainMessage = BubbleBaseMessage & {
2108
+ content: string;
2109
+ };
2110
+
2111
+ /**
2112
+ * 普通消息分组(内容为字符串)
2113
+ */
2114
+ declare type BubblePlainMessageGroup = {
2115
+ role: string;
2116
+ messages: BubblePlainMessage[];
2117
+ isPolymorphic: false;
2118
+ messageIndexes: number[];
2119
+ };
2120
+
2121
+ /**
2122
+ * 多态消息(数组内容)
2123
+ */
2124
+ export declare type BubblePolymorphicMessage = BubbleBaseMessage & {
2125
+ content: BubbleChatMessageItem[];
2126
+ };
2127
+
2128
+ /**
2129
+ * 多态消息分组(内容为 BubbleChatMessageItem 数组)
2130
+ */
2131
+ declare type BubblePolymorphicMessageGroup = {
2132
+ role: string;
2133
+ messages: BubblePolymorphicMessage[];
2134
+ isPolymorphic: true;
2135
+ messageIndexes: number[];
2136
+ };
2137
+
2138
+ /**
2139
+ * Bubble 组件 Props
2140
+ * 用于渲染单个气泡的外观和内容
2141
+ */
2142
+ export declare type BubbleProps = Omit<BubbleChatMessage, 'role'> & {
2143
+ role?: string;
2038
2144
  /**
2039
- * 气泡内容
2145
+ * 气泡头像
2146
+ */
2147
+ avatar?: VNode | Component;
2148
+ /**
2149
+ * 气泡对齐位置,默认 'start'
2150
+ */
2151
+ placement?: 'start' | 'end';
2152
+ /**
2153
+ * 气泡形状,默认 'corner'
2154
+ */
2155
+ shape?: 'rounded' | 'corner' | 'none';
2156
+ /**
2157
+ * 气泡加载状态
2040
2158
  */
2041
- content?: string | BubbleContentItem[];
2042
- id?: string | number | symbol;
2043
- role?: string;
2044
2159
  loading?: boolean;
2045
- aborted?: boolean;
2046
- }
2160
+ /**
2161
+ * 是否隐藏气泡
2162
+ */
2163
+ hidden?: boolean;
2164
+ /**
2165
+ * 是否拆分多态内容(每个内容项各自渲染一个气泡)
2166
+ * - true:每个内容项各自渲染一个气泡
2167
+ * - false:所有内容项合并在同一个气泡中渲染(默认)
2168
+ */
2169
+ splitPolymorphic?: boolean;
2170
+ /**
2171
+ * 额外配置
2172
+ */
2173
+ extras?: Record<string, unknown>;
2174
+ };
2047
2175
 
2048
- declare const BubbleProvider: typeof _default_20 & {
2176
+ declare const BubbleProvider: typeof _default_22 & {
2049
2177
  install: typeof bubbleProviderInstall;
2050
2178
  };
2051
2179
  export { BubbleProvider }
@@ -2053,28 +2181,48 @@ export { BubbleProvider as TrBubbleProvider }
2053
2181
 
2054
2182
  declare const bubbleProviderInstall: (app: App) => void;
2055
2183
 
2056
- export declare type BubbleRoleConfig = BubbleCommonProps & {
2057
- hidden?: boolean;
2058
- slots?: BubbleSlots;
2184
+ export declare interface BubbleProviderProps {
2185
+ boxRendererMatches?: BubbleBoxRendererMatch[];
2186
+ contentRendererMatches?: BubbleContentRendererMatch[];
2187
+ fallbackBoxRenderer?: Component;
2188
+ fallbackContentRenderer?: Component;
2189
+ initialStore?: Record<string, unknown>;
2190
+ }
2191
+
2192
+ /**
2193
+ * 渲染器消息(扁平化的单条内容)
2194
+ */
2195
+ export declare type BubbleRendererMessage<T = string | BubbleChatMessageItem | undefined, E extends Record<string, unknown> = Record<string, unknown>> = Omit<BubbleBaseMessage, 'role'> & {
2196
+ role?: string;
2197
+ content: T;
2198
+ extras?: E;
2199
+ };
2200
+
2201
+ /**
2202
+ * 角色配置
2203
+ * 用于配置不同角色的气泡样式
2204
+ */
2205
+ export declare type BubbleRoleConfig = Pick<BubbleProps, 'avatar' | 'placement' | 'shape' | 'hidden'>;
2206
+
2207
+ declare type BubbleSlotProps = {
2208
+ rendererMessages: BubbleRendererMessage[];
2209
+ role?: string;
2210
+ isPolymorphic?: undefined;
2211
+ isFirstPolymorphic?: undefined;
2212
+ polymorphicIndex?: undefined;
2213
+ } | {
2214
+ rendererMessages: BubbleRendererMessage[];
2215
+ role?: string;
2216
+ isPolymorphic: boolean;
2217
+ isFirstPolymorphic: boolean;
2218
+ polymorphicIndex: number;
2059
2219
  };
2060
2220
 
2061
2221
  export declare interface BubbleSlots {
2062
- default?: (slotProps: {
2063
- bubbleProps: BubbleProps;
2064
- index?: number;
2065
- }) => unknown;
2066
- footer?: (slotProps: {
2067
- bubbleProps: BubbleProps;
2068
- index?: number;
2069
- }) => unknown;
2070
- loading?: (slotProps: {
2071
- bubbleProps: BubbleProps;
2072
- index?: number;
2073
- }) => unknown;
2074
- trailer?: (slotProps: {
2075
- bubbleProps: BubbleProps;
2076
- index?: number;
2077
- }) => unknown;
2222
+ prefix?: (slotProps: BubbleSlotProps) => VNode | VNode[];
2223
+ suffix?: (slotProps: BubbleSlotProps) => VNode | VNode[];
2224
+ 'content-footer'?: (slotProps: BubbleSlotProps) => VNode | VNode[];
2225
+ after?: (slotProps: BubbleSlotProps) => VNode | VNode[];
2078
2226
  }
2079
2227
 
2080
2228
  export declare interface ButtonGroupConfig {
@@ -2119,49 +2267,61 @@ declare const _default: {
2119
2267
  };
2120
2268
  export default _default;
2121
2269
 
2122
- declare const _default_10: typeof _default_30 & {
2270
+ declare const _default_10: typeof _default_28 & {
2271
+ install: typeof install_7;
2272
+ };
2273
+ export { _default_10 as History }
2274
+ export { _default_10 as TrHistory }
2275
+
2276
+ declare const _default_11: typeof _default_29 & {
2277
+ install: typeof install_8;
2278
+ };
2279
+ export { _default_11 as IconButton }
2280
+ export { _default_11 as TrIconButton }
2281
+
2282
+ declare const _default_12: typeof _default_32 & {
2123
2283
  install: typeof install_9;
2124
2284
  };
2125
- export { _default_10 as Sender }
2126
- export { _default_10 as TrSender }
2285
+ export { _default_12 as Sender }
2286
+ export { _default_12 as TrSender }
2127
2287
 
2128
- declare const _default_11: typeof _default_32 & {
2288
+ declare const _default_13: typeof _default_34 & {
2129
2289
  install: typeof install_10;
2130
2290
  };
2131
- export { _default_11 as SuggestionPills }
2132
- export { _default_11 as TrSuggestionPills }
2291
+ export { _default_13 as SuggestionPills }
2292
+ export { _default_13 as TrSuggestionPills }
2133
2293
 
2134
- declare const _default_12: typeof _default_33 & {
2294
+ declare const _default_14: typeof _default_35 & {
2135
2295
  install: typeof install_11;
2136
2296
  };
2137
- export { _default_12 as SuggestionPopover }
2138
- export { _default_12 as TrSuggestionPopover }
2297
+ export { _default_14 as SuggestionPopover }
2298
+ export { _default_14 as TrSuggestionPopover }
2139
2299
 
2140
- declare const _default_13: typeof _default_34 & {
2300
+ declare const _default_15: typeof _default_36 & {
2141
2301
  install: typeof install_12;
2142
2302
  };
2143
- export { _default_13 as ThemeProvider }
2144
- export { _default_13 as TrThemeProvider }
2303
+ export { _default_15 as ThemeProvider }
2304
+ export { _default_15 as TrThemeProvider }
2145
2305
 
2146
- declare const _default_14: typeof _default_35 & {
2306
+ declare const _default_16: typeof _default_37 & {
2147
2307
  install: typeof install_13;
2148
2308
  };
2149
- export { _default_14 as TrWelcome }
2150
- export { _default_14 as Welcome }
2309
+ export { _default_16 as TrWelcome }
2310
+ export { _default_16 as Welcome }
2151
2311
 
2152
- declare const _default_15: typeof _default_36 & {
2312
+ declare const _default_17: typeof _default_38 & {
2153
2313
  install: typeof install_14;
2154
2314
  };
2155
- export { _default_15 as McpServerPicker }
2156
- export { _default_15 as TrMcpServerPicker }
2315
+ export { _default_17 as McpServerPicker }
2316
+ export { _default_17 as TrMcpServerPicker }
2157
2317
 
2158
- declare const _default_16: typeof _default_37 & {
2318
+ declare const _default_18: typeof _default_39 & {
2159
2319
  install: typeof install_15;
2160
2320
  };
2161
- export { _default_16 as McpAddForm }
2162
- export { _default_16 as TrMcpAddForm }
2321
+ export { _default_18 as McpAddForm }
2322
+ export { _default_18 as TrMcpAddForm }
2163
2323
 
2164
- declare const _default_17: DefineComponent<AttachmentListProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {} & {
2324
+ declare const _default_19: DefineComponent<AttachmentListProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {} & {
2165
2325
  "update:items": (items: Attachment[]) => any;
2166
2326
  remove: (file: Attachment) => any;
2167
2327
  download: (event: MouseEvent, file: Attachment) => any;
@@ -2187,29 +2347,27 @@ fileMatchers: FileTypeMatcher[];
2187
2347
  variant: DisplayVariant;
2188
2348
  }, {}, {}, {}, string, ComponentProvideOptions, false, {}, HTMLDivElement>;
2189
2349
 
2190
- declare const _default_18: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
2191
-
2192
- declare const _default_19: DefineComponent<BubbleListProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<BubbleListProps> & Readonly<{}>, {}, {}, {}, {}, string, ComponentProvideOptions, false, {
2193
- scrollContainerRef: HTMLDivElement;
2194
- }, HTMLDivElement>;
2195
-
2196
- declare const _default_2: typeof _default_17 & {
2350
+ declare const _default_2: typeof _default_19 & {
2197
2351
  install: typeof install;
2198
2352
  };
2199
2353
  export { _default_2 as Attachments }
2200
2354
  export { _default_2 as TrAttachments }
2201
2355
 
2202
- declare const _default_20: __VLS_WithTemplateSlots_2<typeof __VLS_component_2, __VLS_TemplateResult_2["slots"]>;
2356
+ declare const _default_20: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
2357
+
2358
+ declare const _default_21: __VLS_WithTemplateSlots_2<typeof __VLS_component_2, __VLS_TemplateResult_2["slots"]>;
2359
+
2360
+ declare const _default_22: __VLS_WithTemplateSlots_3<typeof __VLS_component_3, __VLS_TemplateResult_3["slots"]>;
2203
2361
 
2204
- declare const _default_21: __VLS_WithTemplateSlots_3<typeof __VLS_component_3, __VLS_TemplateResult_3["slots"]>;
2362
+ declare const _default_23: __VLS_WithTemplateSlots_5<typeof __VLS_component_5, __VLS_TemplateResult_5["slots"]>;
2205
2363
 
2206
- declare const _default_22: DefineComponent< {}, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, ComponentProvideOptions, true, {}, any>;
2364
+ declare const _default_24: DefineComponent< {}, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, ComponentProvideOptions, true, {}, any>;
2207
2365
 
2208
- declare const _default_23: __VLS_WithTemplateSlots_4<typeof __VLS_component_4, __VLS_TemplateResult_4["slots"]>;
2366
+ declare const _default_25: __VLS_WithTemplateSlots_6<typeof __VLS_component_6, __VLS_TemplateResult_6["slots"]>;
2209
2367
 
2210
- declare const _default_24: __VLS_WithTemplateSlots_5<typeof __VLS_component_5, __VLS_TemplateResult_5["slots"]>;
2368
+ declare const _default_26: __VLS_WithTemplateSlots_7<typeof __VLS_component_7, __VLS_TemplateResult_7["slots"]>;
2211
2369
 
2212
- declare const _default_25: DefineComponent<FeedbackProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {} & {
2370
+ declare const _default_27: DefineComponent<FeedbackProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {} & {
2213
2371
  action: (name: string) => any;
2214
2372
  operation: (name: string) => any;
2215
2373
  }, string, PublicProps, Readonly<FeedbackProps> & Readonly<{
@@ -2221,7 +2379,7 @@ actionsLimit: number;
2221
2379
  sourcesLinesLimit: number;
2222
2380
  }, {}, {}, {}, string, ComponentProvideOptions, false, {}, HTMLDivElement>;
2223
2381
 
2224
- declare const _default_26: <T extends HistoryItem>(__VLS_props: NonNullable<Awaited<typeof __VLS_setup>>["props"], __VLS_ctx?: __VLS_PrettifyLocal<Pick<NonNullable<Awaited<typeof __VLS_setup>>, "attrs" | "emit" | "slots">>, __VLS_expose?: NonNullable<Awaited<typeof __VLS_setup>>["expose"], __VLS_setup?: Promise<{
2382
+ declare const _default_28: <T extends HistoryItem>(__VLS_props: NonNullable<Awaited<typeof __VLS_setup>>["props"], __VLS_ctx?: __VLS_PrettifyLocal<Pick<NonNullable<Awaited<typeof __VLS_setup>>, "attrs" | "emit" | "slots">>, __VLS_expose?: NonNullable<Awaited<typeof __VLS_setup>>["expose"], __VLS_setup?: Promise<{
2225
2383
  props: __VLS_PrettifyLocal<Pick<Partial<{}> & Omit<{
2226
2384
  readonly "onItem-click"?: ((item: T) => any) | undefined;
2227
2385
  readonly "onItem-title-change"?: ((newTitle: string, item: T) => any) | undefined;
@@ -2235,25 +2393,19 @@ declare const _default_26: <T extends HistoryItem>(__VLS_props: NonNullable<Awai
2235
2393
  __ctx?: Awaited<typeof __VLS_setup>;
2236
2394
  };
2237
2395
 
2238
- declare const _default_27: DefineComponent<IconButtonProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<IconButtonProps> & Readonly<{}>, {
2396
+ declare const _default_29: DefineComponent<IconButtonProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<IconButtonProps> & Readonly<{}>, {
2239
2397
  size: string | number;
2240
2398
  svgSize: string | number;
2241
2399
  }, {}, {}, {}, string, ComponentProvideOptions, false, {}, HTMLButtonElement>;
2242
2400
 
2243
- declare const _default_28: DefineComponent<PromptProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<PromptProps> & Readonly<{}>, {
2401
+ declare const _default_3: __VLS_WithTemplateSlots_4<typeof __VLS_component_4, __VLS_TemplateResult_4["slots"]>;
2402
+ export { _default_3 as BubbleBasicBox }
2403
+ export { _default_3 as TrBubbleBasicBox }
2404
+
2405
+ declare const _default_30: DefineComponent<PromptProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<PromptProps> & Readonly<{}>, {
2244
2406
  size: "small" | "medium" | "large";
2245
2407
  }, {}, {}, {}, string, ComponentProvideOptions, false, {}, HTMLDivElement>;
2246
2408
 
2247
- declare const _default_29: __VLS_WithTemplateSlots_6<typeof __VLS_component_6, __VLS_TemplateResult_6["slots"]>;
2248
-
2249
- declare const _default_3: typeof _default_21 & {
2250
- install: typeof install_2;
2251
- };
2252
- export { _default_3 as Container }
2253
- export { _default_3 as TrContainer }
2254
-
2255
- declare const _default_30: __VLS_WithTemplateSlots_7<typeof __VLS_component_7, __VLS_TemplateResult_7["slots"]>;
2256
-
2257
2409
  declare const _default_31: __VLS_WithTemplateSlots_8<typeof __VLS_component_8, __VLS_TemplateResult_8["slots"]>;
2258
2410
 
2259
2411
  declare const _default_32: __VLS_WithTemplateSlots_9<typeof __VLS_component_9, __VLS_TemplateResult_9["slots"]>;
@@ -2264,7 +2416,11 @@ declare const _default_34: __VLS_WithTemplateSlots_11<typeof __VLS_component_11,
2264
2416
 
2265
2417
  declare const _default_35: __VLS_WithTemplateSlots_12<typeof __VLS_component_12, __VLS_TemplateResult_12["slots"]>;
2266
2418
 
2267
- declare const _default_36: DefineComponent<__VLS_PublicProps_6, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {
2419
+ declare const _default_36: __VLS_WithTemplateSlots_13<typeof __VLS_component_13, __VLS_TemplateResult_13["slots"]>;
2420
+
2421
+ declare const _default_37: __VLS_WithTemplateSlots_14<typeof __VLS_component_14, __VLS_TemplateResult_14["slots"]>;
2422
+
2423
+ declare const _default_38: DefineComponent<__VLS_PublicProps_6, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {
2268
2424
  "update:visible": (value: boolean) => any;
2269
2425
  } & {
2270
2426
  refresh: (tab: "installed" | "market") => any;
@@ -2315,7 +2471,7 @@ allowPluginAdd: boolean;
2315
2471
  marketLoading: boolean;
2316
2472
  }, {}, {}, {}, string, ComponentProvideOptions, false, {}, any>;
2317
2473
 
2318
- declare const _default_37: DefineComponent<McpAddFormProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {} & {
2474
+ declare const _default_39: DefineComponent<McpAddFormProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {} & {
2319
2475
  cancel: () => any;
2320
2476
  confirm: (type: AddType, data: string | McpAddFormData) => any;
2321
2477
  "update:addType": (value: AddType) => any;
@@ -2327,41 +2483,39 @@ onConfirm?: ((type: AddType, data: string | McpAddFormData) => any) | undefined;
2327
2483
  addType: AddType;
2328
2484
  }, {}, {}, {}, string, ComponentProvideOptions, false, {}, HTMLDivElement>;
2329
2485
 
2330
- declare const _default_4: typeof _default_22 & {
2331
- install: typeof install_3;
2332
- };
2333
- export { _default_4 as Conversations }
2334
- export { _default_4 as TrConversations }
2486
+ declare const _default_4: DefineComponent<__VLS_Props, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {}, {}, {}, {}, string, ComponentProvideOptions, false, {}, any>;
2487
+ export { _default_4 as BubbleMarkdownRenderer }
2488
+ export { _default_4 as TrBubbleMarkdownRenderer }
2335
2489
 
2336
2490
  declare const _default_5: typeof _default_23 & {
2337
- install: typeof install_4;
2491
+ install: typeof install_2;
2338
2492
  };
2339
- export { _default_5 as DragOverlay }
2340
- export { _default_5 as TrDragOverlay }
2493
+ export { _default_5 as Container }
2494
+ export { _default_5 as TrContainer }
2341
2495
 
2342
2496
  declare const _default_6: typeof _default_24 & {
2343
- install: typeof install_5;
2497
+ install: typeof install_3;
2344
2498
  };
2345
- export { _default_6 as DropdownMenu }
2346
- export { _default_6 as TrDropdownMenu }
2499
+ export { _default_6 as Conversations }
2500
+ export { _default_6 as TrConversations }
2347
2501
 
2348
2502
  declare const _default_7: typeof _default_25 & {
2349
- install: typeof install_6;
2503
+ install: typeof install_4;
2350
2504
  };
2351
- export { _default_7 as Feedback }
2352
- export { _default_7 as TrFeedback }
2505
+ export { _default_7 as DragOverlay }
2506
+ export { _default_7 as TrDragOverlay }
2353
2507
 
2354
2508
  declare const _default_8: typeof _default_26 & {
2355
- install: typeof install_7;
2509
+ install: typeof install_5;
2356
2510
  };
2357
- export { _default_8 as History }
2358
- export { _default_8 as TrHistory }
2511
+ export { _default_8 as DropdownMenu }
2512
+ export { _default_8 as TrDropdownMenu }
2359
2513
 
2360
2514
  declare const _default_9: typeof _default_27 & {
2361
- install: typeof install_8;
2515
+ install: typeof install_6;
2362
2516
  };
2363
- export { _default_9 as IconButton }
2364
- export { _default_9 as TrIconButton }
2517
+ export { _default_9 as Feedback }
2518
+ export { _default_9 as TrFeedback }
2365
2519
 
2366
2520
  export declare type DisplayVariant = 'picture' | 'card' | 'auto';
2367
2521
 
@@ -2832,7 +2986,7 @@ export declare interface PopupConfig {
2832
2986
  };
2833
2987
  }
2834
2988
 
2835
- declare const Prompt: typeof _default_28 & {
2989
+ declare const Prompt: typeof _default_30 & {
2836
2990
  install: typeof installPrompt;
2837
2991
  };
2838
2992
  export { Prompt }
@@ -2869,7 +3023,7 @@ export declare interface PromptProps {
2869
3023
  size?: 'small' | 'medium' | 'large';
2870
3024
  }
2871
3025
 
2872
- declare const Prompts: typeof _default_29 & {
3026
+ declare const Prompts: typeof _default_31 & {
2873
3027
  install: typeof installPrompts;
2874
3028
  };
2875
3029
  export { Prompts }
@@ -3024,7 +3178,7 @@ export declare interface SuggestionGroup<T = Record<string, unknown>> {
3024
3178
 
3025
3179
  export declare type SuggestionItem<T = Record<string, unknown>> = SuggestionBaseItem & T;
3026
3180
 
3027
- declare const SuggestionPillButton: typeof _default_31 & {
3181
+ declare const SuggestionPillButton: typeof _default_33 & {
3028
3182
  install: typeof installPillButton;
3029
3183
  };
3030
3184
  export { SuggestionPillButton }
@@ -3191,6 +3345,19 @@ export declare type ThemeStorage = Pick<Storage, 'getItem' | 'setItem'>;
3191
3345
  */
3192
3346
  export declare type ThemeType = 'light' | 'dark';
3193
3347
 
3348
+ /**
3349
+ * 工具调用接口(支持 OpenAI 格式)
3350
+ */
3351
+ export declare interface ToolCall {
3352
+ id: string;
3353
+ type: 'function' | string;
3354
+ function: {
3355
+ name: string;
3356
+ arguments: string;
3357
+ };
3358
+ [x: string]: unknown;
3359
+ }
3360
+
3194
3361
  declare interface TooltipContentProps {
3195
3362
  show?: boolean;
3196
3363
  content: string;