@webskill/chatbot 0.16.0 → 0.18.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
@@ -1,31 +1,9 @@
1
- import { AgentLoopConfig, ApprovalScope, BridgeCapabilities, DataSourceInfo, DocumentSurfaceHost, DocxTextExtractor, ExternalSkillProvider, ExternalToolSource, FileSystemProvider, HookRunner, InteractionRequest, InteractionResponse, LifecycleEventInit, LinkedDocumentReader, LlmClient, NetworkPolicy, Page, PageQuery, PdfTextExtractor, RenderBlock, RenderResultRequest, RunSnapshot, RunSnapshotListEntry, RuntimePhase, RuntimeRun, ScriptExecutor, SessionStore, SkillCandidateMarker, SkillCatalogEntry, SkillIntegrityGuard, SkillOutcomeReporter, SkillStateGuard, UiBridge, UiSpecDrafts, UiSpecEvent, UiSpecSnapshot, UiSurfaceActionRequest, UiSurfaceActionResponse, UserProfile, UserProfileExport, WebSkillErrorCode, XlsxTextExtractor, diffUserProfile } from "@webskill/sdk";
2
- import { SandboxMode, TypeScriptSupportOptions } from "@webskill/sdk/browser";
3
- import { CustomSurfaceActionEvent, ReactBridgeState, SpecInteractionChannel, SurfaceRegistry, UiSurfaceActionEvent } from "@webskill/sdk/ui-react";
4
- import { DownloadedFileConsent, DownloadedFileReader, PageActionPolicy, PagePerceptionPolicy, PerceptionPagingBudget, PerceptionRecord, SkillCandidateSink, TabWorksetPolicy, TodoItem } from "@webskill/sdk/agent";
1
+ import { a as RuntimeRendererId, c as RuntimeQuickPrompt, d as TranslateFn, i as RuntimeLlmEntry, l as Locale, n as RuntimeConfig, o as QuickPrompt, r as RuntimeConfigStore, s as QuickPromptIconName, t as RuntimeAppearanceConfig, u as LocalizedText } from "./index-Nnkn73aD.js";
5
2
  import "react";
6
- import "react/jsx-runtime";
7
- //#region ../ui-kit/src/i18n/types.d.ts
8
- /** @stable */
9
- type Locale = 'zh' | 'en';
10
- /**
11
- * 宿主 / 用户提供的、随界面语言切换的短文案(0.13.0 分册 21 FR-21.1)。
12
- * SDK 自己的界面文案走 `createI18n` 字典,不用这个类型。
13
- * 允许只填部分语种,缺的语种由 `resolveLocalizedText` 借用已填的。
14
- * @experimental
15
- */
16
- type LocalizedText = Partial<Record<Locale, string>>;
17
- /** 单语言词条:key → 文案(支持 {name} 占位插值) */
18
- type LocaleMessages = Record<string, string>;
19
- /** 双语字典:zh/en 两个 locale 的键集必须一致(见 assertDictionaryComplete) */
20
- interface Dictionary {
21
- en: LocaleMessages;
22
- zh: LocaleMessages;
23
- }
24
- type DictionaryKey<D extends Dictionary> = keyof D['en'] & string;
25
- type InterpolationParams = Record<string, string | number>;
26
- /** t(key, params?):查当前 locale 词条并做 {name} 插值 */
27
- type TranslateFn<D extends Dictionary = Dictionary> = (key: DictionaryKey<D>, params?: InterpolationParams) => string;
28
- //#endregion
3
+ import { AgentLoopConfig, ApprovalScope, BridgeCapabilities, DataSourceInfo, DocumentSurfaceHost, DocxTextExtractor, ExternalSkillProvider, ExternalToolSource, FileSystemProvider, HookRunner, InteractionRequest, InteractionResponse, LifecycleEventInit, LinkedDocumentReader, LlmClient, NetworkPolicy, Page, PageQuery, PdfTextExtractor, RenderBlock, RenderResultRequest, RunSnapshot, RunSnapshotListEntry, RuntimePhase, RuntimeRun, ScriptExecutor, SessionStore, SkillCandidateMarker, SkillCatalogEntry, SkillIntegrityGuard, SkillOutcomeReporter, SkillStateGuard, UiBridge, UiSpecDrafts, UiSpecEvent, UiSpecSnapshot, UiSurfaceActionRequest, UiSurfaceActionResponse, UserProfile, UserProfileExport, VisionDelegate, VisionDelegateRequest, VisionDelegateResult, WebSkillErrorCode, XlsxTextExtractor, diffUserProfile } from "@webskill/sdk";
4
+ import { SandboxMode, TypeScriptSupportOptions, WebOfficeConsent, WebOfficeHost } from "@webskill/sdk/browser";
5
+ import { CustomSurfaceActionEvent, ReactBridgeState, SpecInteractionChannel, SurfaceRegistry, UiSurfaceActionEvent } from "@webskill/sdk/ui-react";
6
+ import { ConsentUi, DocxDocumentReader, DownloadedFileConsent, DownloadedFileReader, PageActionPolicy, PagePerceptionPolicy, PdfDocumentReader, PerceptionPagingBudget, PerceptionRecord, SkillCandidateSink, TabWorksetPolicy, TodoItem, XlsxDocumentReader } from "@webskill/sdk/agent";
29
7
  //#region ../core/src/attachment/kind.d.ts
30
8
  /**
31
9
  * 附件类型判据与文本形态。0.14.0 分册 20 从 `@webskill/chatbot` 迁入:
@@ -74,371 +52,6 @@ interface DocumentSurfacePort {
74
52
  }): Promise<void>;
75
53
  }
76
54
  //#endregion
77
- //#region ../runtime/src/sandbox/bridgeProtocol.d.ts
78
- /**
79
- * 能力模式:true 直通 / false 关闭(TOOL_UNSUPPORTED)/ 'require-approval' 调用前强制授权
80
- * (布尔语义与现状完全兼容)
81
- */
82
- type CapabilityMode = boolean | 'require-approval';
83
- /** 授权粒度:'once-per-run'(默认,run 内同类能力批准一次)/ 'every-call'(每次调用都问) */
84
- type ApprovalScope$1 = 'once-per-run' | 'every-call';
85
- //#endregion
86
- //#region ../runtime/src/sandbox/networkPolicy.d.ts
87
- /**
88
- * 网络策略类型 + 匹配逻辑(单一来源:browser worker 经函数字符串注入、
89
- * node worker 直接 import,禁止各自重复实现)。
90
- *
91
- * 注意:isNetworkAllowed 会被 toString() 内嵌进浏览器 Worker bootstrap,
92
- * 函数体必须自包含(不引用模块内其它符号),且不得使用模板字符串/反引号。
93
- */
94
- type NetworkPolicy$1 = 'deny-all' | 'allow-all' | {
95
- allow: string[];
96
- };
97
- //#endregion
98
- //#region ../ui-kit/src/runtime-config/quickPrompts.d.ts
99
- /**
100
- * 快捷指令可选图标名(0.12.0 分册 21)。
101
- * 用受控枚举而不是让宿主传组件:SDK 的图标集不进公开契约,
102
- * 换实现(lucide → 别的)时宿主代码不用动。
103
- *
104
- * 0.13.0 分册 17 FR-17.1:真值源从 `@webskill/chatbot` 迁到这里,
105
- * 让 console 的配置界面也能用同一份枚举;`@webskill/chatbot` 原样 re-export,
106
- * 公开面逐字不变。
107
- * @experimental
108
- */
109
- type QuickPromptIconName = 'chart' | 'document' | 'report' | 'search' | 'list' | 'bug' | 'test' | 'metric' | 'compare' | 'page' | 'run' | 'warn' | 'sparkles' | 'settings';
110
- /**
111
- * 带图标的快捷指令(0.12.0 分册 21)。
112
- * @experimental
113
- */
114
- interface QuickPrompt {
115
- /**
116
- * 点击后发出的文本,同时作为按钮可见文案。
117
- * 0.13.0 分册 21 FR-21.1:改为按语种取值,可只填部分语种。
118
- */
119
- text: LocalizedText;
120
- /** 缺省或取值不在枚举内时按无图标渲染 */
121
- icon?: QuickPromptIconName;
122
- }
123
- /**
124
- * `RuntimeConfig` 里持久化的快捷指令条目(0.13.0 分册 17)。
125
- * 比 `QuickPrompt` 多一个稳定 `id`:列表增删改需要它做定位,
126
- * 用 `text` 当 key 在「两条同文案」时会塌陷。`id` 不进任何发给模型的字符串。
127
- * @experimental
128
- */
129
- interface RuntimeQuickPrompt {
130
- id: string;
131
- text: LocalizedText;
132
- icon?: QuickPromptIconName;
133
- }
134
- //#endregion
135
- //#region ../ui-kit/src/runtime-config/types.d.ts
136
- /**
137
- * 运行环境配置模型(P2):console Configure Tab 编辑、chatbot ChatEngine 装配应用,
138
- * 宿主经 RuntimeConfigStore 接线同一存储源(playground localStorage / 集成 OPFS 文件)。
139
- * 默认值严格对齐 SDK(AgentLoop/InteractionPolicy/executor 缺省)。
140
- */
141
- interface RuntimeLoopConfig {
142
- maxTurns: number;
143
- totalTimeoutMs: number;
144
- toolTimeoutMs: number;
145
- temperature?: number;
146
- toolResultMaxBytes: number;
147
- maxHistoryMessages: number;
148
- /** `file` 分片的 base64 上限;超出即拒绝并说明,不截断(FR-23.4) */
149
- maxDocumentBytes: number;
150
- /** `document-text` 分片的字节上限;同样拒绝而不截断(FR-23.4) */
151
- maxDocumentTextBytes: number;
152
- }
153
- interface RuntimeInteractionConfig {
154
- missingParams: 'user' | 'llm';
155
- confirmations: 'required' | 'auto-approve';
156
- interactionTimeoutMs: number;
157
- approvalScope: ApprovalScope$1;
158
- }
159
- type RuntimeRouterStrategy = 'progressive' | 'full-disclosure';
160
- /** 生命周期钩子执行策略(`HookRunnerOptions` 的可配置部分) */
161
- interface RuntimeHooksConfig {
162
- timeoutMs: number;
163
- /** true 时钩子异常终止 run;缺省隔离为 warning */
164
- failOnHookError: boolean;
165
- }
166
- /** 浏览器宿主执行器档位;Node 宿主的 in-process/worker/process 由宿主侧扩展展示 */
167
- type RuntimeSandboxExecutor = 'auto' | 'blob-worker' | 'iframe-sandbox';
168
- /**
169
- * 用户自己声明的取数源(0.14.0 分册 19)。
170
- *
171
- * 存在的理由:从别的宿主导出的技能会声明本宿主没有的源 id,没有这一段就永远跑不起来。
172
- * 它不放宽任何闸门——`url` 照过 `sandbox.remoteUrl` 判定,取数照受 `capabilities.fetchData` 管,
173
- * 变的只是「谁来写这个地址」:宿主开发者,还是宿主的使用者。
174
- */
175
- interface RuntimeDataSourceEntry {
176
- id: string;
177
- /** 绝对 http(s) 地址 */
178
- url: string;
179
- description: string;
180
- }
181
- interface RuntimeSandboxConfig {
182
- executor: RuntimeSandboxExecutor;
183
- networkPolicy: NetworkPolicy$1;
184
- capabilities: {
185
- readReference: CapabilityMode;
186
- /** 同时管 readAsset 与 readAssetBinary */
187
- readAsset: CapabilityMode;
188
- writeArtifact: CapabilityMode;
189
- confirm: CapabilityMode;
190
- /**
191
- * 脚本按宿主声明的数据源取数(分册 16)。
192
- * 与 `readAsset` **相反**,缺省 `false`:它会出网,缺省开等于每个技能默认拿到出站能力。
193
- */
194
- fetchData: CapabilityMode;
195
- };
196
- /**
197
- * 单次取数结果的字节上限(分册 16)。超出即拒绝,**不截断**
198
- * ——截断后的 JSON 解不出来,比拒绝更糟。结果回到脚本,不进模型上下文,
199
- * 所以不受 `toolResultMaxBytes` 约束。
200
- */
201
- maxDataSourceBytes: number;
202
- /**
203
- * 用户声明的取数源(0.14.0 分册 19);缺省空数组 = 只有宿主代码写死的那些。
204
- * 与宿主源撞 id 时宿主的那条胜出——否则用户配置就能改写宿主的授权面。
205
- */
206
- dataSources: RuntimeDataSourceEntry[];
207
- /**
208
- * 出站 URL 准入策略(`RemoteUrlPolicy` 的可配置部分):技能安装、MCP 端点连接
209
- * 这类由宿主发起的取数都按它判定。两项都默认关,即 https-only 且拒绝内网/环回。
210
- */
211
- remoteUrl: RuntimeRemoteUrlConfig;
212
- /** 浏览器沙箱的 TypeScript 支持;关闭时 `.ts` 脚本按 `TOOL_UNSUPPORTED` 拒绝 */
213
- typescript: RuntimeTypeScriptConfig;
214
- /**
215
- * 读取用户下载的文件(0.14.0 分册 20)。缺省 `false`。
216
- *
217
- * **不放进 `capabilities`**:那张表的语义是三态 `CapabilityMode`(关 / 需批准 / 开),
218
- * 而本能力的「需批准」是恒定的,放进去会凭空多出一个「开且不批准」的非法组合。
219
- */
220
- downloadedFiles: boolean;
221
- /**
222
- * 让技能脚本读用户本轮上传的文件(0.15.0 分册 17)。缺省 `false`。
223
- *
224
- * **不放进 `capabilities`**,理由同 `downloadedFiles`:本能力的「需批准」是恒定的。
225
- * 关闭时脚本上下文里连那两个成员都不存在,而不是存在但总失败。
226
- */
227
- uploadFiles: boolean;
228
- /**
229
- * 单个上传文件交给脚本的字节上限(分册 17)。超出即拒,**不截断**
230
- * ——截一半的 xlsx / 图片解不开,而脚本看不出它残缺。
231
- */
232
- maxUploadFileBytes: number;
233
- }
234
- /**
235
- * 只做类型擦除,不做类型检查。`esbuildUrl` 为绝对 http(s) 地址时按 `remoteUrl` 判定;
236
- * 同源相对路径与打包器 specifier 不属于出站请求,不参与判定。
237
- */
238
- interface RuntimeTypeScriptConfig {
239
- enabled: boolean;
240
- /** esbuild-wasm 的 JS 入口地址;enabled 时必填 */
241
- esbuildUrl?: string;
242
- /** esbuild.wasm 二进制地址;缺省由 esbuild 自行推导 */
243
- wasmUrl?: string;
244
- }
245
- /** 与 `@webskill/core` 的 `RemoteUrlPolicy` 同形,但两个字段都是必填(配置需要确定值) */
246
- interface RuntimeRemoteUrlConfig {
247
- allowHttp: boolean;
248
- allowPrivateHosts: boolean;
249
- }
250
- /** `chrome-builtin` 走浏览器 Prompt API,无端点与密钥;其余三档是云端 HTTP 协议 */
251
- type RuntimeLlmProvider = 'openai-compatible' | 'anthropic' | 'google' | 'chrome-builtin';
252
- /**
253
- * 单个模型的能力声明(FR-11.4 / FR-14.2)。`image` 缺省视为 `false`:
254
- * 猜测支持会把图片发给纯文本模型,拿到的是 provider 的不可读报错。
255
- * `tools` 反过来,缺省视为 `true`:云端模型几乎都支持,默认关会把存量配置里
256
- * 没标能力的条目全部降级成纯对话。
257
- * @experimental
258
- */
259
- interface RuntimeLlmCapabilities {
260
- image: boolean;
261
- /** 是否支持原生工具调用;false 时 Agent 走纯对话路径 */
262
- tools: boolean;
263
- }
264
- /**
265
- * 单个模型条目。`id` 稳定,会话记录与消息归属存的是它,用户改名不影响历史;
266
- * `label` 只用于展示——同一个 `model` 可能配了两个不同的 `baseUrl`(公司代理与直连),
267
- * 光看 `model` 区分不出来。
268
- */
269
- interface RuntimeLlmEntry {
270
- id: string;
271
- label: string;
272
- provider: RuntimeLlmProvider;
273
- baseUrl?: string;
274
- apiKey?: string;
275
- model: string;
276
- requestTimeoutMs?: number;
277
- capabilities?: RuntimeLlmCapabilities;
278
- /**
279
- * Anthropic extended thinking 预算(0.10.0 遗留项 #1):仅 anthropic 条目有意义;
280
- * 设置面是开关,开启写入 `DEFAULT_THINKING_BUDGET_TOKENS`。
281
- * 0.10.0 #40.4:缺省(undefined)视为**开启**(按默认预算),显式关闭存 0。
282
- * @experimental
283
- */
284
- thinkingBudgetTokens?: number;
285
- }
286
- /** 模型列表 + 默认项。`defaultId` 由 `mergeRuntimeConfigDefaults` 归一到真实存在的条目 */
287
- interface RuntimeLlmSelection {
288
- entries: readonly RuntimeLlmEntry[];
289
- defaultId?: string;
290
- }
291
- /**
292
- * Agent 能力开关(0.5.0)。默认值逐项经需求评审确定,不适用「新能力一律默认关」的通则。
293
- * `todo`:待办清单,默认**开启**——不引入新攻击面、提示词体积远小于生成式 UI catalog,
294
- * 且关闭时多步任务体验明显更差。
295
- * `skillGeneration`:技能自动生成,默认**关闭**——会把对话内容写进持久化的候选,
296
- * 属于新增攻击面(AC-G7 判据一)。
297
- * `generativeUi`:生成式 UI,默认**关闭**——catalog 描述约 14 KB 计入每次请求。
298
- * `uiPresets`:开放给模型的场景预设,默认全开——预设本体按需加载,
299
- * 只有名字与一行摘要计入请求;置空列表等于完全关闭预设。
300
- */
301
- interface RuntimeAgentCapabilitiesConfig {
302
- todo: boolean;
303
- skillGeneration: boolean;
304
- generativeUi: boolean;
305
- /** 串行委派(FR-11.8):默认关。一句话可能展开成多个子 run,调用量对用户不可预期 */
306
- delegation: boolean;
307
- uiPresets: string[];
308
- }
309
- /**
310
- * 未签名技能的处置策略(与 core 的 `UnsignedPolicy` 同形,配置层独立命名)。
311
- * 默认 `'warn'` 由需求评审定下(FR-1.2):`deny` 会让现存未签名技能立即不可用,
312
- * 且默认信任库为空时接受集为空;`allow` 等于策略不存在。
313
- */
314
- type UnsignedSkillPolicy = 'allow' | 'warn' | 'deny';
315
- interface RuntimeSecurityConfig {
316
- unsignedSkills: UnsignedSkillPolicy;
317
- }
318
- /** 生成式 UI 的渲染器档位。ui-kit 不依赖 `@webskill/ui`,因此这里写字面量联合 @experimental */
319
- type RuntimeRendererId = 'native' | 'a2ui' | 'openui' | 'vercel';
320
- /**
321
- * 外观配置(0.6.0 FR-20.1)。0.5.x 之前外观由宿主自持并单独存一份,
322
- * 导致 chatbot 与 console 各看各的;纳入 `RuntimeConfig` 后两端共用同一份。
323
- * `dictationLang` 只对 chatbot 有意义(console 无语音输入),但同属外观段。
324
- * @experimental
325
- */
326
- interface RuntimeAppearanceConfig {
327
- theme: 'light' | 'dark';
328
- locale: Locale;
329
- renderer: RuntimeRendererId;
330
- dictationLang: string;
331
- }
332
- /**
333
- * 多模态输入配置(0.6.0 FR-11.3 / FR-11.6 / FR-12.3)。
334
- * `imageAttachments` 与 `pageImageCapture` 默认都关(AC-G5):
335
- * 两者都会把图像随请求外发给模型提供方,属新增攻击面。
336
- * @experimental
337
- */
338
- /**
339
- * 文档投放面(0.11.0 分册 18)。
340
- *
341
- * **只有一个闸门字段**。CSP 白名单不在这里:它由 viewer 路由的**响应头**
342
- * 下发(FR-18.3 第 1 条),是宿主部署时调 `viewerCspHeader` 的入参;
343
- * 浏览器侧的运行时配置改不动已经发出去的响应头,携在这里只会是个不生效的假开关。
344
- */
345
- interface RuntimeDocumentSurfaceConfig {
346
- /** 关着即没有这个投放面;开启还要求宿主额外提供一条 viewer 路由 */
347
- enabled: boolean;
348
- }
349
- interface RuntimeMultimodalConfig {
350
- imageAttachments: boolean;
351
- /** 页面图像抓取总开关(FR-12.3);关时感知只走纯文本路径 */
352
- pageImageCapture: boolean;
353
- /** 附件与取像共用 */
354
- maxImageBytes: number;
355
- /** 附件与取像共用 */
356
- maxImagesPerMessage: number;
357
- /**
358
- * 页面取像时小于该面积(平方像素)的元素视作工具图标,不占名额(0.13.0 FR-20.4)。
359
- * `0` 是合法值,意为关闭过滤;只作用于页面取像,不管用户上传的附件。
360
- */
361
- minImageArea: number;
362
- }
363
- /**
364
- * 用户画像配置(0.6.0 FR-19.6)。`enabled` 默认**关**(AC-G5):
365
- * 开启后会把用户的提问与填写持久化到本地,属新增攻击面;
366
- * `encrypted` 默认**开**——它不新增采集,只决定已采集的数据怎么落盘,默认明文无正当理由。
367
- * chatbot 与 console 共用这一份。
368
- * @experimental
369
- */
370
- interface RuntimeUserProfileConfig {
371
- enabled: boolean;
372
- /** 画像注入系统提示的字节上限(FR-19.4) */
373
- injectMaxBytes: number;
374
- /** 行为记录容量上限,超出淘汰最旧(FR-19.2) */
375
- recordLimit: number;
376
- /** 本地存储加密(FR-19.5) */
377
- encrypted: boolean;
378
- }
379
- /** @experimental */
380
- interface RuntimeSkillStateConfig {
381
- /**
382
- * 技能连续失败自动隔离阈值(0.10.0 UI-UX5 #48-12;#49-2 起默认 5),
383
- * 与 governance `SkillStatePolicy` 的缺省对齐。读点在 console 的
384
- * GovernanceFacade 装配处(`failureThreshold`),守卫本身不读配置。
385
- */
386
- quarantineThreshold: number;
387
- }
388
- /** @experimental */
389
- interface RuntimeConfig {
390
- loop: RuntimeLoopConfig;
391
- interaction: RuntimeInteractionConfig;
392
- router: {
393
- strategy: RuntimeRouterStrategy;
394
- };
395
- hooks: RuntimeHooksConfig;
396
- streaming: boolean;
397
- renderResult: boolean;
398
- sandbox: RuntimeSandboxConfig;
399
- llm: RuntimeLlmSelection;
400
- agentCapabilities: RuntimeAgentCapabilitiesConfig;
401
- security: RuntimeSecurityConfig;
402
- appearance: RuntimeAppearanceConfig;
403
- multimodal: RuntimeMultimodalConfig;
404
- documentSurface: RuntimeDocumentSurfaceConfig;
405
- userProfile: RuntimeUserProfileConfig;
406
- skillState: RuntimeSkillStateConfig;
407
- /**
408
- * 快捷指令的**唯一权威**(0.13.0 分册 21 FR-21.5)。
409
- * `ChatbotConfig.quickPrompts` 降级为一次性种子源,不再参与渲染判断。
410
- */
411
- quickPrompts: readonly RuntimeQuickPrompt[];
412
- /**
413
- * 宿主种子是否已注入过(FR-21.6)。
414
- * 不得用 `quickPrompts.length === 0` 推断:「从未配置」与「用户删光了」都是空数组,
415
- * 靠数组本身分不开——这正是 D-17-3 当年绕不过去的地方。
416
- */
417
- quickPromptsSeeded: boolean;
418
- /** 空态与动态指令条最多展示多少条;超出的部分截断。取值 1..{@link MAX_QUICK_PROMPT_LIMIT} */
419
- quickPromptLimit: number;
420
- /** 被用户删掉的自动模型条目 id(FR-14.3):删一次就不该再自己长回来 */
421
- dismissedAutoEntries: readonly string[];
422
- }
423
- /** @experimental */
424
- interface RuntimeConfigStore {
425
- /**
426
- * Loads the runtime configuration. Implementations SHOULD return a complete
427
- * RuntimeConfig; consumers wrap stores with `withRuntimeConfigDefaults` so partial
428
- * or legacy data is normalized through `mergeRuntimeConfigDefaults` on the read
429
- * path. Callers must not apply their own additional fallback merge.
430
- */
431
- load(): Promise<RuntimeConfig>;
432
- save(config: RuntimeConfig): Promise<void>;
433
- reset(): Promise<void>;
434
- /**
435
- * Subscribes to configuration changes; returns an unsubscribe function.
436
- * Optional: stores without it degrade to the previous behaviour where hosts
437
- * remount consumers after a save.
438
- */
439
- subscribe?(listener: () => void): () => void;
440
- }
441
- //#endregion
442
55
  //#region ../ui-kit/src/runtime-config/stores.d.ts
443
56
  /**
444
57
  * `RuntimeConfigStore` 的两个实现(0.6.0 FR-20.1)。0.5.x 之前 SDK 只有接口没有实现,
@@ -463,6 +76,71 @@ declare function createLocalStorageRuntimeConfigStore(options?: LocalStorageRunt
463
76
  /** 内存实现:测试、SSR、以及宿主明确不想持久化时使用。 @experimental */
464
77
  declare function createMemoryRuntimeConfigStore(initial?: Partial<RuntimeConfig>): RuntimeConfigStore;
465
78
  //#endregion
79
+ //#region src/core/visionDelegate.d.ts
80
+ /**
81
+ * 委派目标端点的可辨识标识;告知卡与审计都只用这三项(FR-17.6a / FR-17.7a)
82
+ * @experimental
83
+ */
84
+ interface VisionDelegationEndpoint {
85
+ /** 模型条目 id */
86
+ readonly id: string;
87
+ /** 用户在 Console 里给这条起的名字 */
88
+ readonly label: string;
89
+ /** `baseUrl` 的主机名;内置档没有 baseUrl 时是 provider 名 */
90
+ readonly host: string;
91
+ }
92
+ /**
93
+ * 视觉委派的记忆端口(0.21.0 分册 17 · FR-17.9b)。形状照抄 `DownloadedFileConsent`:
94
+ * 存哪、记多久归宿主,SDK 只定接口。不注入即**每次都问**(FR-17.9c)。
95
+ * @experimental
96
+ */
97
+ interface VisionDelegationConsent {
98
+ recall(endpoint: VisionDelegationEndpoint): boolean | Promise<boolean>;
99
+ remember(endpoint: VisionDelegationEndpoint): void | Promise<void>;
100
+ /**
101
+ * 复选框旁的文案。宿主不实现即用通用兜底串——
102
+ * SDK 无权替宿主宣称记住的是「这个端点」还是「所有端点」,写死会变成谎报授权范围。
103
+ */
104
+ describeScope?(endpoint: VisionDelegationEndpoint): string | undefined;
105
+ }
106
+ /** 装配参数;每一项都是「每次调用时重读」的取值函数,不是装配期快照 @experimental */
107
+ interface ChatbotVisionDelegateOptions {
108
+ /** 每次调用时读的实时配置:选中模型与端点列表中途都可能变 */
109
+ config(): Promise<RuntimeConfig | undefined>;
110
+ /** 当前选中的模型条目 id(未选中即用默认项) */
111
+ selectedModelId(): string | undefined;
112
+ /** 选中条目的解析口径必须与主链路一致,否则「主模型看不看得了图」两处会打架 */
113
+ selectedEntry(config: RuntimeConfig | undefined): RuntimeLlmEntry | undefined;
114
+ /** 告知卡出口;引擎的 UI 桥天然满足 */
115
+ ui: ConsentUi;
116
+ consent?: VisionDelegationConsent;
117
+ /** 留痕出口。不注入仍然可以委派(FR-17.6b):审计是宿主能力,不是同意条件 */
118
+ audit?: {
119
+ append(event: {
120
+ type: string;
121
+ target: string;
122
+ data?: Record<string, unknown>;
123
+ }): Promise<unknown>;
124
+ };
125
+ /** 按条目建客户端。缺省由调用方注入 `createLlmClient` */
126
+ createClient(entry: RuntimeLlmEntry): LlmClient;
127
+ }
128
+ /**
129
+ * 视觉委派的宿主侧实现(0.21.0 分册 17)。
130
+ *
131
+ * 三件事按顺序发生:挑端点(FR-17.2)→ 征得同意(FR-17.7)→ 一次调用认完所有图(FR-17.3a)。
132
+ * 在用户作出选择之前**不发出任何请求**:客户端是在同意之后才建的(FR-17.7b / AC-17.3)。
133
+ * @experimental
134
+ */
135
+ declare class ChatbotVisionDelegate implements VisionDelegate {
136
+ #private;
137
+ constructor(options: ChatbotVisionDelegateOptions);
138
+ /** 新会话重新问(AC-17.4)。同意的记忆归宿主,这里不碰 */
139
+ forgetSessionDecision(): void;
140
+ applies(): Promise<boolean>;
141
+ describe(request: VisionDelegateRequest): Promise<VisionDelegateResult>;
142
+ }
143
+ //#endregion
466
144
  //#region src/core/hostAdapter.d.ts
467
145
  /**
468
146
  * 宿主装配口:chatbot 不感知环境(浏览器/Node),全部能力经此注入。
@@ -530,6 +208,27 @@ interface ChatbotHostAdapter {
530
208
  * PDF 仍然默认直传,能读的端点拿到的还是原件;不注入即没有回退能力。
531
209
  */
532
210
  pdfExtractor?: PdfTextExtractor;
211
+ /**
212
+ * 逐页读 PDF(0.21.0 分册 22):拿页数、逐页文本、逐页图、把整页渲成图。
213
+ *
214
+ * 与 `pdfExtractor` 分开给,是因为它们回答的是两个问题:那个问「整份的文本是什么」,
215
+ * 这个问「第 N 页是什么」。三个 `*DocumentReader` 各自独立,缺哪个就哪种格式
216
+ * 明确报「本环境不支持」,不互相兜底。
217
+ * @experimental
218
+ */
219
+ pdfDocumentReader?: PdfDocumentReader;
220
+ /** docx → 块序列(`createDocxBlockReader`);不注入即 `read_document` 读不了 Word @experimental */
221
+ docxDocumentReader?: DocxDocumentReader;
222
+ /** xlsx → 行流(`createXlsxBlockReader`);不注入即 `read_document` 读不了 Excel @experimental */
223
+ xlsxDocumentReader?: XlsxDocumentReader;
224
+ /**
225
+ * 视觉委派的「不再询问」记忆端口(0.21.0 分册 17 · FR-17.9)。
226
+ *
227
+ * **不注入不等于关闭**:委派本身只要模型列表里有能看图的条目就成立,
228
+ * 只是每次都要弹告知卡(FR-17.9c)。本册刻意不加 Console 开关(FR-17.8)。
229
+ * @experimental
230
+ */
231
+ visionConsent?: VisionDelegationConsent;
533
232
  /** 文档读取留痕出口(FR-22.6);分册 17 的 `upload.file.read` 也走这条 */
534
233
  documentAudit?: {
535
234
  append(event: {
@@ -551,6 +250,20 @@ interface ChatbotHostAdapter {
551
250
  /** 「不再询问」的记忆端口;不注入即每次都问 */
552
251
  consent?: DownloadedFileConsent;
553
252
  };
253
+ /**
254
+ * 读页内嵌的 WPS WebOffice 文档(0.21.0 分册 11~13)。
255
+ * **不注入即两个工具都不注册**——本册刻意不加设置开关(FR-13.8):
256
+ * 能不能读取决于这一页有没有那样一份文档,那不是用户需要预先决定的事。
257
+ *
258
+ * 与 `downloads` 同一条装配规矩:宿主只交端口(枚举 / 读取 / 截屏),
259
+ * 授权卡出口与审计出口在引擎这一侧。
260
+ * @experimental
261
+ */
262
+ webOffice?: {
263
+ host: WebOfficeHost;
264
+ /** 「不再询问」的记忆端口;不注入即每次都问 */
265
+ consent?: WebOfficeConsent;
266
+ };
554
267
  /**
555
268
  * 文档投放面(0.15.0 分册 13)。宿主交出 viewer 页地址、投放前确认与审计出口,
556
269
  * 三件都在 `createDocumentSurfaceHost` 的选项里。
@@ -625,6 +338,12 @@ interface ChatEngineOptions {
625
338
  generativeUi?: boolean;
626
339
  /** 沙箱执行器替换点(测试注入 spy 断言构造参数;缺省 BrowserWorkerScriptExecutor) */
627
340
  executorFactory?: (deps: SandboxExecutorDeps) => ScriptExecutor;
341
+ /**
342
+ * 视觉委派用的客户端工厂(分册 17)。缺省 `createLlmClient`——
343
+ * 与主链路同一个工厂,被选中条目的 `baseUrl` / `apiKey` / `model` 原样生效(FR-17.2c)。
344
+ * 替换点存在只为让判据能断言「请求打到了哪个端点」(AC-17.8),不是配置项。
345
+ */
346
+ visionClientFactory?: (entry: RuntimeLlmEntry) => LlmClient;
628
347
  /**
629
348
  * 宿主声明的数据源取数入口(分册 16)。不注入即脚本上下文没有 `fetchData` 这个键。
630
349
  *
@@ -762,8 +481,14 @@ declare class ChatEngine {
762
481
  send(text: string, attachments?: readonly ChatAttachmentInput[]): Promise<void>;
763
482
  /** 附件落盘根目录(composer 附件适配器写入,send 时读回) */
764
483
  get attachmentsRoot(): string;
765
- /** 取消进行中的 run(Composer Stop 按钮);run 未找到/已结束返回 false */
766
- cancel(runId: string): boolean;
484
+ /**
485
+ * 取消进行中的 run(Composer Stop 按钮);run 未找到/已结束返回 false。
486
+ *
487
+ * 不传 runId 就取消引擎自己记着的那一个。UI 那边的 runId 是 `run-started` 事件携回去的,
488
+ * 而 `run-preparing` 到 `run-started` 之间是一整段无声区(队列/发现/路由)——
489
+ * 那段里面板已经是忙碌态、终止按钮已经在了,可 UI 手里还没 id,按下去是个空操作。
490
+ */
491
+ cancel(runId?: string): boolean;
767
492
  /**
768
493
  * 释放引擎:取消进行中的 run、退订全部事件、丢弃装配缓存。
769
494
  * 宿主重挂组件时用它收尾;只是换配置的话用 `reloadConfig()`,不要 dispose。
@@ -1055,7 +780,19 @@ interface ChatSessionListResult {
1055
780
  skipped: readonly string[];
1056
781
  }
1057
782
  /** @stable */
1058
- type ChatEvent = {
783
+ type ChatEvent =
784
+ /**
785
+ * 请求已受理,正在交给 runtime(分册 20 FR-20.2)。
786
+ *
787
+ * `run-started` 是从 runtime 的 `route` 生命周期事件派生的,而 route 排在
788
+ * 队列 / discover / listSkills / catalogFilter 之后。那一整段里任何一处慢或挂,
789
+ * 界面上都是同一副画面:什么都没有。本事件把那段变成一个显式状态。
790
+ */
791
+ {
792
+ type: 'run-preparing';
793
+ sessionId: string;
794
+ queued: boolean;
795
+ } | {
1059
796
  type: 'run-started';
1060
797
  runId: string;
1061
798
  } | {
@@ -1112,6 +849,18 @@ type ChatEvent = {
1112
849
  name: string;
1113
850
  args?: string;
1114
851
  errorCode?: string;
852
+ } |
853
+ /**
854
+ * 委派识图的逐张进度(分册 26 FR-26.9)。挂在 `source` 这个工具名上,
855
+ * 不带 callId——委派发生在工具**结果**回喂阶段,那时调用早已结束。
856
+ * @experimental
857
+ */
858
+ {
859
+ type: 'vision-progress';
860
+ runId: string;
861
+ source: string;
862
+ done: number;
863
+ total: number;
1115
864
  } | {
1116
865
  type: 'run-completed';
1117
866
  runId: string;
@@ -1120,6 +869,21 @@ type ChatEvent = {
1120
869
  activeSkillNames: string[];
1121
870
  /** 终止原因对应的稳定错误码(仅非正常结束时):UI 据此分类提示,不再压平为 RUN_FAILED */
1122
871
  code?: WebSkillErrorCode;
872
+ /**
873
+ * 本 run 结束时的上下文水位线(末轮输入 token,分册 20 FR-20.5)。
874
+ * 上游不回报 usage 时缺省——不填 0冒充「已知为零」。
875
+ */
876
+ contextTokens?: number;
877
+ } |
878
+ /**
879
+ * 历史被压缩(分册 20 FR-20.8):只描述运行时历史的变化,会话存储里的原文不动。
880
+ * @experimental
881
+ */
882
+ {
883
+ type: 'context-compacted';
884
+ sessionId: string;
885
+ removed: number;
886
+ kept: number;
1123
887
  } | {
1124
888
  type: 'todo-changed';
1125
889
  runId: string;
@@ -1427,6 +1191,7 @@ declare const chatbotDictionary: {
1427
1191
  'tool.status.completed': string;
1428
1192
  'tool.status.failed': string;
1429
1193
  'tool.status.denied': string;
1194
+ 'tool.vision.progress': string;
1430
1195
  'tool.duration': string;
1431
1196
  'tool.args': string;
1432
1197
  'tool.denied.reason': string;
@@ -1473,6 +1238,7 @@ declare const chatbotDictionary: {
1473
1238
  'todo.status.inProgress': string;
1474
1239
  'todo.status.completed': string;
1475
1240
  'todo.delegatedTo': string;
1241
+ 'todo.dismiss': string;
1476
1242
  'interaction.ask.title': string;
1477
1243
  'interaction.confirm.title': string;
1478
1244
  'interaction.form.title': string;
@@ -1510,6 +1276,21 @@ declare const chatbotDictionary: {
1510
1276
  'interaction.downloadedFile.read': string;
1511
1277
  'interaction.downloadedFile.file': string;
1512
1278
  'interaction.downloadedFile.remember': string;
1279
+ 'interaction.webOffice.listTitle': string;
1280
+ 'interaction.webOffice.listBody': string;
1281
+ 'interaction.webOffice.readTitle': string;
1282
+ 'interaction.webOffice.readBody': string;
1283
+ 'interaction.webOffice.captureTitle': string;
1284
+ 'interaction.webOffice.captureBody': string;
1285
+ 'interaction.webOffice.claimedTypeNote': string;
1286
+ 'interaction.webOffice.rememberFallback': string;
1287
+ 'interaction.visionDelegation.title': string;
1288
+ 'interaction.visionDelegation.reason': string;
1289
+ 'interaction.visionDelegation.endpoint': string;
1290
+ 'interaction.visionDelegation.declineNote': string;
1291
+ 'interaction.visionDelegation.rememberFallback': string;
1292
+ 'interaction.visionDelegation.rememberSession': string;
1293
+ 'interaction.visionDelegation.body': string;
1513
1294
  'interaction.uploadFile.read': string;
1514
1295
  'interaction.uploadFile.file': string;
1515
1296
  'interaction.sandbox.readReference': string;
@@ -1586,6 +1367,12 @@ declare const chatbotDictionary: {
1586
1367
  'composer.addAttachment.imagesOff': string;
1587
1368
  'composer.addAttachment.modelNoImages': string;
1588
1369
  'attachment.imagesDropped': string;
1370
+ 'attachment.storeFailed.title': string;
1371
+ 'attachment.storeFailed': string;
1372
+ 'attachment.pdfAsText': string;
1373
+ 'attachment.pdfRefused': string;
1374
+ 'attachment.pdfNoExtractor': string;
1375
+ 'attachment.textTooLong': string;
1589
1376
  'composer.dictate': string;
1590
1377
  'composer.dictate.stop': string;
1591
1378
  'composer.dictate.recording': string;
@@ -1818,6 +1605,7 @@ declare const chatbotDictionary: {
1818
1605
  'tool.status.completed': string;
1819
1606
  'tool.status.failed': string;
1820
1607
  'tool.status.denied': string;
1608
+ 'tool.vision.progress': string;
1821
1609
  'tool.duration': string;
1822
1610
  'tool.args': string;
1823
1611
  'tool.denied.reason': string;
@@ -1864,6 +1652,7 @@ declare const chatbotDictionary: {
1864
1652
  'todo.status.inProgress': string;
1865
1653
  'todo.status.completed': string;
1866
1654
  'todo.delegatedTo': string;
1655
+ 'todo.dismiss': string;
1867
1656
  'interaction.ask.title': string;
1868
1657
  'interaction.confirm.title': string;
1869
1658
  'interaction.form.title': string;
@@ -1901,6 +1690,21 @@ declare const chatbotDictionary: {
1901
1690
  'interaction.downloadedFile.read': string;
1902
1691
  'interaction.downloadedFile.file': string;
1903
1692
  'interaction.downloadedFile.remember': string;
1693
+ 'interaction.webOffice.listTitle': string;
1694
+ 'interaction.webOffice.listBody': string;
1695
+ 'interaction.webOffice.readTitle': string;
1696
+ 'interaction.webOffice.readBody': string;
1697
+ 'interaction.webOffice.captureTitle': string;
1698
+ 'interaction.webOffice.captureBody': string;
1699
+ 'interaction.webOffice.claimedTypeNote': string;
1700
+ 'interaction.webOffice.rememberFallback': string;
1701
+ 'interaction.visionDelegation.title': string;
1702
+ 'interaction.visionDelegation.reason': string;
1703
+ 'interaction.visionDelegation.endpoint': string;
1704
+ 'interaction.visionDelegation.declineNote': string;
1705
+ 'interaction.visionDelegation.rememberFallback': string;
1706
+ 'interaction.visionDelegation.rememberSession': string;
1707
+ 'interaction.visionDelegation.body': string;
1904
1708
  'interaction.uploadFile.read': string;
1905
1709
  'interaction.uploadFile.file': string;
1906
1710
  'interaction.sandbox.readReference': string;
@@ -1977,6 +1781,12 @@ declare const chatbotDictionary: {
1977
1781
  'composer.addAttachment.imagesOff': string;
1978
1782
  'composer.addAttachment.modelNoImages': string;
1979
1783
  'attachment.imagesDropped': string;
1784
+ 'attachment.storeFailed.title': string;
1785
+ 'attachment.storeFailed': string;
1786
+ 'attachment.pdfAsText': string;
1787
+ 'attachment.pdfRefused': string;
1788
+ 'attachment.pdfNoExtractor': string;
1789
+ 'attachment.textTooLong': string;
1980
1790
  'composer.dictate': string;
1981
1791
  'composer.dictate.stop': string;
1982
1792
  'composer.dictate.recording': string;
@@ -2212,6 +2022,7 @@ declare const useT: () => TranslateFn<{
2212
2022
  'tool.status.completed': string;
2213
2023
  'tool.status.failed': string;
2214
2024
  'tool.status.denied': string;
2025
+ 'tool.vision.progress': string;
2215
2026
  'tool.duration': string;
2216
2027
  'tool.args': string;
2217
2028
  'tool.denied.reason': string;
@@ -2258,6 +2069,7 @@ declare const useT: () => TranslateFn<{
2258
2069
  'todo.status.inProgress': string;
2259
2070
  'todo.status.completed': string;
2260
2071
  'todo.delegatedTo': string;
2072
+ 'todo.dismiss': string;
2261
2073
  'interaction.ask.title': string;
2262
2074
  'interaction.confirm.title': string;
2263
2075
  'interaction.form.title': string;
@@ -2295,6 +2107,21 @@ declare const useT: () => TranslateFn<{
2295
2107
  'interaction.downloadedFile.read': string;
2296
2108
  'interaction.downloadedFile.file': string;
2297
2109
  'interaction.downloadedFile.remember': string;
2110
+ 'interaction.webOffice.listTitle': string;
2111
+ 'interaction.webOffice.listBody': string;
2112
+ 'interaction.webOffice.readTitle': string;
2113
+ 'interaction.webOffice.readBody': string;
2114
+ 'interaction.webOffice.captureTitle': string;
2115
+ 'interaction.webOffice.captureBody': string;
2116
+ 'interaction.webOffice.claimedTypeNote': string;
2117
+ 'interaction.webOffice.rememberFallback': string;
2118
+ 'interaction.visionDelegation.title': string;
2119
+ 'interaction.visionDelegation.reason': string;
2120
+ 'interaction.visionDelegation.endpoint': string;
2121
+ 'interaction.visionDelegation.declineNote': string;
2122
+ 'interaction.visionDelegation.rememberFallback': string;
2123
+ 'interaction.visionDelegation.rememberSession': string;
2124
+ 'interaction.visionDelegation.body': string;
2298
2125
  'interaction.uploadFile.read': string;
2299
2126
  'interaction.uploadFile.file': string;
2300
2127
  'interaction.sandbox.readReference': string;
@@ -2371,6 +2198,12 @@ declare const useT: () => TranslateFn<{
2371
2198
  'composer.addAttachment.imagesOff': string;
2372
2199
  'composer.addAttachment.modelNoImages': string;
2373
2200
  'attachment.imagesDropped': string;
2201
+ 'attachment.storeFailed.title': string;
2202
+ 'attachment.storeFailed': string;
2203
+ 'attachment.pdfAsText': string;
2204
+ 'attachment.pdfRefused': string;
2205
+ 'attachment.pdfNoExtractor': string;
2206
+ 'attachment.textTooLong': string;
2374
2207
  'composer.dictate': string;
2375
2208
  'composer.dictate.stop': string;
2376
2209
  'composer.dictate.recording': string;
@@ -2603,6 +2436,7 @@ declare const useT: () => TranslateFn<{
2603
2436
  'tool.status.completed': string;
2604
2437
  'tool.status.failed': string;
2605
2438
  'tool.status.denied': string;
2439
+ 'tool.vision.progress': string;
2606
2440
  'tool.duration': string;
2607
2441
  'tool.args': string;
2608
2442
  'tool.denied.reason': string;
@@ -2649,6 +2483,7 @@ declare const useT: () => TranslateFn<{
2649
2483
  'todo.status.inProgress': string;
2650
2484
  'todo.status.completed': string;
2651
2485
  'todo.delegatedTo': string;
2486
+ 'todo.dismiss': string;
2652
2487
  'interaction.ask.title': string;
2653
2488
  'interaction.confirm.title': string;
2654
2489
  'interaction.form.title': string;
@@ -2686,6 +2521,21 @@ declare const useT: () => TranslateFn<{
2686
2521
  'interaction.downloadedFile.read': string;
2687
2522
  'interaction.downloadedFile.file': string;
2688
2523
  'interaction.downloadedFile.remember': string;
2524
+ 'interaction.webOffice.listTitle': string;
2525
+ 'interaction.webOffice.listBody': string;
2526
+ 'interaction.webOffice.readTitle': string;
2527
+ 'interaction.webOffice.readBody': string;
2528
+ 'interaction.webOffice.captureTitle': string;
2529
+ 'interaction.webOffice.captureBody': string;
2530
+ 'interaction.webOffice.claimedTypeNote': string;
2531
+ 'interaction.webOffice.rememberFallback': string;
2532
+ 'interaction.visionDelegation.title': string;
2533
+ 'interaction.visionDelegation.reason': string;
2534
+ 'interaction.visionDelegation.endpoint': string;
2535
+ 'interaction.visionDelegation.declineNote': string;
2536
+ 'interaction.visionDelegation.rememberFallback': string;
2537
+ 'interaction.visionDelegation.rememberSession': string;
2538
+ 'interaction.visionDelegation.body': string;
2689
2539
  'interaction.uploadFile.read': string;
2690
2540
  'interaction.uploadFile.file': string;
2691
2541
  'interaction.sandbox.readReference': string;
@@ -2762,6 +2612,12 @@ declare const useT: () => TranslateFn<{
2762
2612
  'composer.addAttachment.imagesOff': string;
2763
2613
  'composer.addAttachment.modelNoImages': string;
2764
2614
  'attachment.imagesDropped': string;
2615
+ 'attachment.storeFailed.title': string;
2616
+ 'attachment.storeFailed': string;
2617
+ 'attachment.pdfAsText': string;
2618
+ 'attachment.pdfRefused': string;
2619
+ 'attachment.pdfNoExtractor': string;
2620
+ 'attachment.textTooLong': string;
2765
2621
  'composer.dictate': string;
2766
2622
  'composer.dictate.stop': string;
2767
2623
  'composer.dictate.recording': string;
@@ -3208,6 +3064,6 @@ declare function ErrorCard({ code, message, loopLimits, onOpenSettings, onDismis
3208
3064
  * Version of the published `@webskill/chatbot` package, injected at build time.
3209
3065
  * @stable
3210
3066
  */
3211
- declare const CHATBOT_VERSION = "0.16.0";
3067
+ declare const CHATBOT_VERSION = "0.18.0";
3212
3068
  //#endregion
3213
- export { A2uiSurfaceHost, type A2uiSurfaceHostProps, A2uiSurfaceSnapshotHost, type A2uiSurfaceSnapshotHostProps, type AppearanceChange, CHATBOT_VERSION, type ChatAttachmentInput, type ChatAttachmentMeta, type ChatContentPart, ChatEngine, type ChatEngineOptions, type ChatEvent, type ChatInteractionRecord, type ChatLayout, type ChatMessage, type ChatRunPhase, type ChatSessionListResult, type ChatSessionMeta, type ChatTheme, type ChatThinking, type ChatTokenUsage, type ChatToolCall, Chatbot, type ChatbotConfig, type ChatbotGovernancePorts, type ChatbotHostAdapter, type ChatbotProps, CompositeUiBridge, type CompositeUiBridgeDeps, DEFAULT_RENDERER_CAPABILITIES, DEFAULT_RUNTIME_CONFIG_STORAGE_KEY, type DownloadableFile, ErrorCard, type ErrorCardProps, InteractionCard, type InteractionCardProps, InterruptedBanner, type InterruptedBannerProps, type Locale, type LocalizedText, OpenUiSurfaceHost, type OpenUiSurfaceHostProps, OpenUiSurfaceSnapshotHost, type OpenUiSurfaceSnapshotHostProps, type QuickPrompt, type QuickPromptIconName, type RendererCapability, type RendererKind, type ResolvedChatLayout, ResultBlockList, type ResultBlockListProps, ResultBlocksPro, type ResultBlocksProProps, type RunSnapshot, type RuntimeAppearanceConfig, type RuntimeConfig, type RuntimeConfigStore, type RuntimeQuickPrompt, type RuntimeRendererId, type SandboxExecutorDeps, type SettingsSectionId, SkillBadges, SpecInteraction, type SpecInteractionProps, VercelPayloadPreview, type VercelPayloadPreviewProps, VercelSurfaceHost, type VercelSurfaceHostProps, VercelSurfaceSnapshotHost, type VercelSurfaceSnapshotHostProps, chatbotDictionary, configureA2uiMarkdown, createLocalStorageRuntimeConfigStore, createMemoryRuntimeConfigStore, isLlmEntryUsable, pickUsableLlmEntry, probeA2uiAvailability, probeOpenUiAvailability, sandboxExecutorDeps, useT };
3069
+ export { A2uiSurfaceHost, type A2uiSurfaceHostProps, A2uiSurfaceSnapshotHost, type A2uiSurfaceSnapshotHostProps, type AppearanceChange, CHATBOT_VERSION, type ChatAttachmentInput, type ChatAttachmentMeta, type ChatContentPart, ChatEngine, type ChatEngineOptions, type ChatEvent, type ChatInteractionRecord, type ChatLayout, type ChatMessage, type ChatRunPhase, type ChatSessionListResult, type ChatSessionMeta, type ChatTheme, type ChatThinking, type ChatTokenUsage, type ChatToolCall, Chatbot, type ChatbotConfig, type ChatbotGovernancePorts, type ChatbotHostAdapter, type ChatbotProps, ChatbotVisionDelegate, type ChatbotVisionDelegateOptions, CompositeUiBridge, type CompositeUiBridgeDeps, DEFAULT_RENDERER_CAPABILITIES, DEFAULT_RUNTIME_CONFIG_STORAGE_KEY, type DownloadableFile, ErrorCard, type ErrorCardProps, InteractionCard, type InteractionCardProps, InterruptedBanner, type InterruptedBannerProps, type Locale, type LocalizedText, OpenUiSurfaceHost, type OpenUiSurfaceHostProps, OpenUiSurfaceSnapshotHost, type OpenUiSurfaceSnapshotHostProps, type QuickPrompt, type QuickPromptIconName, type RendererCapability, type RendererKind, type ResolvedChatLayout, ResultBlockList, type ResultBlockListProps, ResultBlocksPro, type ResultBlocksProProps, type RunSnapshot, type RuntimeAppearanceConfig, type RuntimeConfig, type RuntimeConfigStore, type RuntimeQuickPrompt, type RuntimeRendererId, type SandboxExecutorDeps, type SettingsSectionId, SkillBadges, SpecInteraction, type SpecInteractionProps, VercelPayloadPreview, type VercelPayloadPreviewProps, VercelSurfaceHost, type VercelSurfaceHostProps, VercelSurfaceSnapshotHost, type VercelSurfaceSnapshotHostProps, type VisionDelegationConsent, type VisionDelegationEndpoint, chatbotDictionary, configureA2uiMarkdown, createLocalStorageRuntimeConfigStore, createMemoryRuntimeConfigStore, isLlmEntryUsable, pickUsableLlmEntry, probeA2uiAvailability, probeOpenUiAvailability, sandboxExecutorDeps, useT };