@h-ai/ai 1.0.0-beta.37 → 1.0.0-beta.38

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.
Files changed (41) hide show
  1. package/README.en.md +11 -1
  2. package/README.ja.md +11 -1
  3. package/README.md +11 -1
  4. package/dist/{ai-acp-types-DvA3nO5I.d.ts → ai-acp-types-BC5Fhn-z.d.ts} +202 -51
  5. package/dist/{ai-audio-types-C4n15IHq.d.ts → ai-audio-types-BTdymerF.d.ts} +5 -5
  6. package/dist/{ai-audio-wav-MnfOlGUF.d.ts → ai-audio-wav-CabS7SJr.d.ts} +5 -5
  7. package/dist/ai-file-worker.js +2 -3
  8. package/dist/ai-file-worker.js.map +1 -1
  9. package/dist/ai-video-archive-worker.js +14 -4
  10. package/dist/ai-video-archive-worker.js.map +1 -1
  11. package/dist/browser.d.ts +5 -5
  12. package/dist/browser.js +5 -5
  13. package/dist/{chunk-XURRFCRC.js → chunk-6S4PMXOB.js} +14 -21
  14. package/dist/chunk-6S4PMXOB.js.map +1 -0
  15. package/dist/chunk-GCFJTKMW.js +63 -0
  16. package/dist/chunk-GCFJTKMW.js.map +1 -0
  17. package/dist/{chunk-CLCPQTW2.js → chunk-INQGKUP4.js} +193 -12
  18. package/dist/chunk-INQGKUP4.js.map +1 -0
  19. package/dist/{chunk-ENF7WU4Y.js → chunk-RI6NELDP.js} +76 -39
  20. package/dist/chunk-RI6NELDP.js.map +1 -0
  21. package/dist/{chunk-OWR55FRO.js → chunk-VCJVPJAP.js} +4 -4
  22. package/dist/chunk-VCJVPJAP.js.map +1 -0
  23. package/dist/client/index.d.ts +3 -3
  24. package/dist/client/index.js +3 -2
  25. package/dist/client/index.js.map +1 -1
  26. package/dist/index.d.ts +2 -2
  27. package/dist/index.js +2957 -1927
  28. package/dist/index.js.map +1 -1
  29. package/models/agents/README.md +11 -8
  30. package/models/agents/build.mjs +12 -1
  31. package/models/agents/codex-acp/Dockerfile +27 -5
  32. package/models/agents/codex-acp/agent.json +10 -0
  33. package/models/agents/codex-acp/hai-podman +99 -0
  34. package/models/agents/codex-acp/podman-containers.conf +10 -0
  35. package/package.json +10 -8
  36. package/dist/chunk-A3DZ6LJ5.js +0 -140
  37. package/dist/chunk-A3DZ6LJ5.js.map +0 -1
  38. package/dist/chunk-CLCPQTW2.js.map +0 -1
  39. package/dist/chunk-ENF7WU4Y.js.map +0 -1
  40. package/dist/chunk-OWR55FRO.js.map +0 -1
  41. package/dist/chunk-XURRFCRC.js.map +0 -1
@@ -3,24 +3,24 @@ import { SSEServerTransport as SSEServerTransport$1 } from '@modelcontextprotoco
3
3
  import { StdioServerTransport as StdioServerTransport$1 } from '@modelcontextprotocol/sdk/server/stdio.js';
4
4
  import { StreamableHTTPServerTransport as StreamableHTTPServerTransport$1 } from '@modelcontextprotocol/sdk/server/streamableHttp.js';
5
5
  import * as _a2a_js_sdk_server from '@a2a-js/sdk/server';
6
- import { AgentExecutor, AgentEvent } from '@a2a-js/sdk/server';
6
+ import { RequestContext as RequestContext$1, AgentExecutor, AgentEvent } from '@a2a-js/sdk/server';
7
7
  import * as _a2a_js_sdk from '@a2a-js/sdk';
8
8
  import { TaskState, Message as Message$1, Part as Part$1, SendMessageRequest as SendMessageRequest$1, Task as Task$1, TaskArtifactUpdateEvent as TaskArtifactUpdateEvent$1, TaskStatus as TaskStatus$1, TaskStatusUpdateEvent as TaskStatusUpdateEvent$1 } from '@a2a-js/sdk';
9
9
  import * as _h_ai_core from '@h-ai/core';
10
10
  import { HaiResult, HaiError } from '@h-ai/core';
11
- import { a as AudioContent, P as PlayableAudio, e as AudioOperations, b as AudioFormat } from './ai-audio-types-C4n15IHq.js';
11
+ import { a as AudioContent, P as PlayableAudio, e as AudioOperations, b as AudioFormat } from './ai-audio-types-BTdymerF.js';
12
12
  import * as _h_ai_runner from '@h-ai/runner';
13
- import { RunnerJson, RunnerScope, RunnerFunctions } from '@h-ai/runner';
13
+ import { RunnerScope, RunnerJson, RunnerFunctions } from '@h-ai/runner';
14
14
  import * as zod from 'zod';
15
15
  import { z, ZodType } from 'zod';
16
16
  import { F as FileOperations } from './ai-file-types-BMfnQU4W.js';
17
17
  import { CleanOptionsInput, ChunkOptionsInput } from '@h-ai/datapipe';
18
18
  import * as zod_v4_core from 'zod/v4/core';
19
19
  import * as _agentclientprotocol_sdk from '@agentclientprotocol/sdk';
20
- import { McpServer as McpServer$1, ContentBlock, RequestPermissionRequest, SessionNotification, ClientRequestHandlersByMethod, ClientCapabilities } from '@agentclientprotocol/sdk';
20
+ import { McpServer as McpServer$1, ContentBlock, TerminalOutputResponse, RequestPermissionRequest, SessionNotification, ClientRequestHandlersByMethod, ClientCapabilities } from '@agentclientprotocol/sdk';
21
21
  import { ToolDefinition as ToolDefinition$1, ToolRegistryOperations as ToolRegistryOperations$1, ToolExecutionOptions } from '@h-ai/tools';
22
22
  import OpenAI from 'openai';
23
- import { ToolServiceContext, ToolSet, ToolArtifactAccess, ToolSubmitRequest, ToolService, ToolArtifact, ToolArtifactReference } from '@h-ai/tools/server';
23
+ import { ToolServiceContext, ToolSet, ToolArtifactAccess, ToolInvoker, ToolArtifact, ToolArtifactReference } from '@h-ai/tools/server';
24
24
  import { CallToolRequest, PromptMessage, CallToolResult } from '@modelcontextprotocol/sdk/types.js';
25
25
  import { IncomingMessage, ServerResponse } from 'node:http';
26
26
 
@@ -965,10 +965,8 @@ interface AIRelStore<T> {
965
965
  withWriteLock?: <R>(write: (store: AIRelStore<T>) => Promise<R>) => Promise<R>;
966
966
  /** 持同一个写锁,在同一事务中提交当前和另一个关系 Store 的改动。 */
967
967
  withRelatedWriteLock?: <U, R>(related: AIRelStore<U>, write: (store: AIRelStore<T>, related: AIRelStore<U>) => Promise<R>) => Promise<R>;
968
- /** 核对有向量的记忆版本 ID,包含仍用业务 ID 存储向量的旧记录。 */
968
+ /** 核对有向量的记忆键:使用向量修订 ID,未分配修订 ID 时使用记忆业务 ID。 */
969
969
  getMemoryVectorIds?: (ids: string[]) => Promise<string[]>;
970
- /** 从已提交的关系记录按不可变主键读取一批需重建索引的记忆,读取失败须抛错。 */
971
- readMemoryVectorPage?: (afterId: string, limit: number) => Promise<T[]>;
972
970
  /** 按更新时间和主键升序获取小批记录键,避免加载业务 JSON。 */
973
971
  queryKeys?: (filter: StoreFilter<T>, cursor?: {
974
972
  updatedAt: number;
@@ -1332,6 +1330,12 @@ interface KnowledgeStore {
1332
1330
  content?: string;
1333
1331
  metadata?: Record<string, unknown>;
1334
1332
  }>>;
1333
+ /**
1334
+ * 供通用检索查询 Knowledge 管理的集合。活跃集合只返回当前发布版本,已撤销集合返回空数组。
1335
+ * 只有从未受管理的集合返回 undefined,允许通用检索读取其原始向量。查询失败抛错。
1336
+ * 自定义 Store 保留撤销集合或过期向量时实现此方法,避免通用检索再次读取这些记录。
1337
+ */
1338
+ searchManagedVectors?: (...args: Parameters<KnowledgeStore['searchVectors']>) => Promise<Awaited<ReturnType<KnowledgeStore['searchVectors']>> | undefined>;
1335
1339
  /** 确保向量集合存在 */
1336
1340
  ensureCollection: (collection: string, dimension: number) => Promise<void>;
1337
1341
  /** 注册 collection(setup 时持久化,幂等) */
@@ -1846,7 +1850,7 @@ declare function createMcpTools(options: McpToolOptions, services: () => MCPServ
1846
1850
  */
1847
1851
  type BuiltinArtifact = ToolArtifact;
1848
1852
  /**
1849
- * 业务资源引用,文件字节不会进入模型消息或 Runner 结果。
1853
+ * 业务资源引用,文件字节不会进入模型消息或工具结果。
1850
1854
  * @example
1851
1855
  * ```ts
1852
1856
  * import type { BuiltinArtifactReference } from '@h-ai/ai'
@@ -1875,10 +1879,10 @@ interface BuiltinToolOptions {
1875
1879
  context: ToolServiceContext;
1876
1880
  files: BuiltinArtifactAccess;
1877
1881
  /** 调用同一工具服务的固定容器作业;省略时不登记网址视频工作流。 */
1878
- executeJob?: (request: ToolSubmitRequest, context: ToolServiceContext) => Promise<HaiResult<RunnerJson>>;
1882
+ executeJob?: ToolInvoker['invoke'];
1879
1883
  }
1880
1884
  /**
1881
- * 本地工具服务与现有短期 MCP Broker 的装配。
1885
+ * 工具目录和调用接口与现有短期 MCP Broker 的装配。
1882
1886
  * @example
1883
1887
  * ```ts
1884
1888
  * import type { BuiltinToolBrokerOptions } from '@h-ai/ai'
@@ -1886,7 +1890,7 @@ interface BuiltinToolOptions {
1886
1890
  * ```
1887
1891
  */
1888
1892
  interface BuiltinToolBrokerOptions {
1889
- service: ToolService;
1893
+ service: ToolInvoker;
1890
1894
  url: string;
1891
1895
  }
1892
1896
  /**
@@ -2495,7 +2499,7 @@ interface ChatRecord {
2495
2499
  * ```
2496
2500
  */
2497
2501
  interface GenerateObjectRequest<T> {
2498
- /** 输出结构的 Zod schema */
2502
+ /** 可转换为 JSON Schema 的 Zod schema;本地验证会等待同步或异步校验规则。 */
2499
2503
  schema: ZodType<T>;
2500
2504
  /** 对话消息 */
2501
2505
  messages: ChatMessage[];
@@ -3557,7 +3561,7 @@ interface KnowledgeOperations {
3557
3561
  * 依次执行 ingest(),通过 onProgress 回调报告进度,单个文档失败不中断整体流程。
3558
3562
  *
3559
3563
  * @param inputs - 文档导入输入列表
3560
- * @param onProgress - 每完成一个文档后的回调
3564
+ * @param onProgress - 每完成一个文档后的进度通知;通知失败记录日志,批次仍继续
3561
3565
  * @returns 批量导入汇总结果
3562
3566
  */
3563
3567
  ingestBatch: (inputs: KnowledgeIngestInput[], onProgress?: (progress: KnowledgeIngestBatchProgress) => void) => Promise<HaiResult<KnowledgeIngestBatchResult>>;
@@ -4521,33 +4525,28 @@ interface ResolveRequiredModelEntryOptions {
4521
4525
  missingApiKeyMessage?: string;
4522
4526
  }
4523
4527
  /**
4524
- * 根据场景解析完整模型配置,并要求必须存在 API Key
4525
- *
4526
- * 用于需要访问远程模型 API 的场景,避免各子模块重复编写
4527
- * `if (!resolved.apiKey)` 之类的配置校验逻辑。
4528
+ * 解析模型条目及凭据、地址和请求默认值。
4528
4529
  *
4529
- * @param llmConfig - LLM 配置
4530
- * @param scenario - 使用场景
4531
- * @param explicit - 调用方显式指定的模型名称(最高优先级)
4532
- * @param options - 必需校验选项
4533
- * @returns 成功返回已解析模型配置,失败返回 `CONFIGURATION_ERROR`
4530
+ * @param llmConfig - 已校验的 LLM 配置
4531
+ * @param scenario - 调用场景
4532
+ * @param explicit - 优先使用的条目 ID 或供应商模型名
4533
+ * @param options - 可覆盖缺少凭据的提示
4534
+ * @returns 完整模型配置,缺少凭据时返回 `CONFIGURATION_ERROR`
4534
4535
  *
4535
4536
  * @example
4536
4537
  * ```ts
4537
4538
  * import { LLMConfigSchema, ai } from '@h-ai/ai'
4538
- *
4539
- * const config = LLMConfigSchema.parse({ apiKey: process.env.HAI_AI_LLM_APIKEY, models: [{ id: 'fast', model: 'gpt-4o-mini' }], scenarios: { summary: 'fast' } })
4540
- * const result = ai.resolveModelEntry(config, 'summary')
4541
- * if (result.success) {
4542
- * const modelName = result.data.model
4543
- * }
4539
+ * const config = LLMConfigSchema.parse({ apiKey: process.env.HAI_AI_LLM_APIKEY, models: [{ id: 'brief', model: 'gpt-4o-mini' }] })
4540
+ * const result = ai.resolveModelEntry(config, 'summary', 'brief')
4541
+ * if (!result.success) throw new Error(result.error.message)
4542
+ * const model = result.data.model
4544
4543
  * ```
4545
4544
  */
4546
4545
  declare function resolveModelEntry(llmConfig: LLMConfig, scenario: ModelScenario, explicit?: string, options?: ResolveRequiredModelEntryOptions): HaiResult<ResolvedModelConfig>;
4547
4546
  /**
4548
4547
  * 解析某次 chat 请求应使用的 API 协议(不校验 API Key)
4549
4548
  *
4550
- * 供 LLM Provider 路由层选择底层实现使用:优先取显式模型条目的 `protocol`,
4549
+ * 供 LLM Provider 路由层选择底层实现使用:优先取显式或聊天场景模型条目的 `protocol`,
4551
4550
  * 其次全局 `protocol`,最后回退 `chat`。临时模型的 `protocol` 由调用方单独传入优先。
4552
4551
  *
4553
4552
  * @param llmConfig - LLM 配置
@@ -6282,16 +6281,18 @@ type AIConfig = z.infer<typeof AIConfigSchema>;
6282
6281
  type AIConfigInput = z.input<typeof AIConfigSchema>;
6283
6282
 
6284
6283
  /**
6285
- * 已授权的 Git 提交文件树,包含规范 Base64 数据。
6284
+ * 已授权的 Git 提交文件树,包含规范 Base64 数据和可选的可执行文件路径。
6286
6285
  * @example
6287
6286
  * ```ts
6288
6287
  * import type { ACPProjectSnapshot } from '@h-ai/ai'
6289
- * function revision(snapshot: ACPProjectSnapshot) { return snapshot.revision }
6288
+ * function executablePaths(snapshot: ACPProjectSnapshot) { return snapshot.executables ?? [] }
6290
6289
  * ```
6291
6290
  */
6292
6291
  interface ACPProjectSnapshot {
6293
6292
  revision: string;
6294
6293
  files: Record<string, string>;
6294
+ /** Git 中模式为 100755 的普通文件。路径与 files 中的键一致,无可执行文件时省略。 */
6295
+ executables?: string[];
6295
6296
  }
6296
6297
  /**
6297
6298
  * 当前文件树相对于授权提交的改动。
@@ -6495,7 +6496,7 @@ interface A2AContextInfo {
6495
6496
  /**
6496
6497
  * A2A 认证器接口
6497
6498
  *
6498
- * 纯接口设计,由应用层实现,Kit 模块做胶水集成。
6499
+ * 由应用层实现。
6499
6500
  * 用于验证入站 A2A 请求的身份。
6500
6501
  *
6501
6502
  * @example
@@ -6516,6 +6517,71 @@ interface A2AAuthenticator {
6516
6517
  */
6517
6518
  authenticate: (headers: Record<string, string | undefined>) => Promise<HaiResult<A2ACallerIdentity>>;
6518
6519
  }
6520
+ /**
6521
+ * HTTP 认证器为 JSON-RPC 请求验证过的调用方身份。
6522
+ *
6523
+ * @example
6524
+ * ```ts
6525
+ * import type { A2AHttpIdentity } from '@h-ai/ai'
6526
+ * function identity(userId: string): A2AHttpIdentity {
6527
+ * return { agentId: userId }
6528
+ * }
6529
+ * ```
6530
+ */
6531
+ interface A2AHttpIdentity {
6532
+ /** 可信认证器确认的调用方 ID。 */
6533
+ readonly agentId: string;
6534
+ /** IAM API Key ID(使用 API Key 时)。 */
6535
+ readonly apiKeyId?: string;
6536
+ /** IAM API Key 上配置的权限范围。 */
6537
+ readonly scopes?: readonly string[];
6538
+ /** 认证器核验后的有效权限;IAM 验证器取当前主体授权与 Key 范围的交集。 */
6539
+ readonly permissions?: readonly string[];
6540
+ }
6541
+ /**
6542
+ * A2A HTTP 发布配置。两条路径均从站点根开始,使用精确匹配。
6543
+ *
6544
+ * @example
6545
+ * ```ts
6546
+ * import { type A2AHttpOptions, ai } from '@h-ai/ai'
6547
+ * function publish(authenticate: A2AHttpOptions['authenticate']) {
6548
+ * return ai.a2a.createHttpHandler({ rpcPath: '/partners/orders/a2a', authenticate })
6549
+ * }
6550
+ * ```
6551
+ */
6552
+ interface A2AHttpOptions {
6553
+ /** Agent Card 的 GET 路径,默认 /.well-known/agent-card.json。 */
6554
+ cardPath?: `/${string}`;
6555
+ /** JSON-RPC 的 POST 路径,默认 /a2a。 */
6556
+ rpcPath?: `/${string}`;
6557
+ /**
6558
+ * 显式传 false 才允许匿名。自定义验证器返回空值时拒绝;API Key 验证器按 Agent Card 查找凭据。
6559
+ */
6560
+ authenticate: false | ((request: Request) => Promise<A2AHttpIdentity | null | undefined>) | {
6561
+ verifyApiKey: (key: string) => Promise<HaiResult<{
6562
+ id: string;
6563
+ userId: string;
6564
+ scopes: readonly string[];
6565
+ permissions: readonly string[];
6566
+ }>>;
6567
+ };
6568
+ }
6569
+ /**
6570
+ * 由 HTTP 宿主挂载的 A2A 处理器。
6571
+ *
6572
+ * @example
6573
+ * ```ts
6574
+ * import type { A2AHttpHandler } from '@h-ai/ai'
6575
+ * function dispatch(a2a: A2AHttpHandler, request: Request, requestId: string) {
6576
+ * return a2a.handleRequest(request, requestId) // null 交给宿主继续匹配。
6577
+ * }
6578
+ * ```
6579
+ */
6580
+ interface A2AHttpHandler {
6581
+ readonly cardPath: `/${string}`;
6582
+ readonly rpcPath: `/${string}`;
6583
+ handleRequest: (request: Request, requestId?: string) => Promise<Response | null>;
6584
+ }
6519
6585
  /**
6520
6586
  * A2A 任务查询过滤器
6521
6587
  *
@@ -6563,6 +6629,23 @@ interface A2ATaskFilter {
6563
6629
  * ```
6564
6630
  */
6565
6631
  interface A2AOperations {
6632
+ /**
6633
+ * 创建一个可挂到 Serv 或 Kit 的 Agent Card 与 JSON-RPC 处理器。
6634
+ *
6635
+ * @throws 未初始化 AI、未配置 A2A、未注册执行器、非法路径、路径重复或未指定认证策略时抛出配置错误。
6636
+ */
6637
+ createHttpHandler: (options: A2AHttpOptions) => A2AHttpHandler;
6638
+ /**
6639
+ * 在 AgentExecutor 中读取来自可信传输层的调用方;匿名调用返回 undefined。
6640
+ * @example
6641
+ * ```ts
6642
+ * import { ai, type RequestContext } from '@h-ai/ai'
6643
+ * function canReadPartnerOrders(context: RequestContext): boolean {
6644
+ * return ai.a2a.getCallerIdentity(context)?.permissions?.includes('orders:read') ?? false
6645
+ * }
6646
+ * ```
6647
+ */
6648
+ getCallerIdentity: (context: RequestContext$1) => A2AHttpIdentity | undefined;
6566
6649
  /**
6567
6650
  * 注册 Agent 执行器
6568
6651
  *
@@ -6587,10 +6670,10 @@ interface A2AOperations {
6587
6670
  * 将 HTTP 请求体路由到 SDK 的 JsonRpcTransportHandler。
6588
6671
  *
6589
6672
  * @param requestBody - JSON-RPC 请求体
6590
- * @param context - 可信 HTTP 层认证上下文;agentId 映射为 SDK user.userName
6673
+ * @param caller - 可信传输层认证结果,可由执行器通过 getCallerIdentity 读取。
6591
6674
  * @returns JSON-RPC 响应(单条或流式);未初始化也返回 JSON-RPC 错误,不混入 HaiResult
6592
6675
  */
6593
- handleRequest: (requestBody: unknown, context?: Record<string, unknown>) => Promise<A2AHandleResult>;
6676
+ handleRequest: (requestBody: unknown, caller?: A2AHttpIdentity) => Promise<A2AHandleResult>;
6594
6677
  /**
6595
6678
  * 查询 A2A 消息列表(服务端管理接口,不自动推断调用方权限)
6596
6679
  *
@@ -6736,6 +6819,22 @@ interface A2ACallResult {
6736
6819
  responseParts?: unknown[];
6737
6820
  }
6738
6821
 
6822
+ /**
6823
+ * 校验待返回给原生 Agent 的用户决定。
6824
+ * @example 模块内部上下文
6825
+ * ```ts
6826
+ * const response = elicitationDecisionSchema.parse({ action: 'decline' })
6827
+ * ```
6828
+ */
6829
+ declare const elicitationDecisionSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
6830
+ action: z.ZodLiteral<"accept">;
6831
+ content: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean, z.ZodArray<z.ZodString>]>>>;
6832
+ }, z.core.$strict>, z.ZodObject<{
6833
+ action: z.ZodLiteral<"decline">;
6834
+ }, z.core.$strict>, z.ZodObject<{
6835
+ action: z.ZodLiteral<"cancel">;
6836
+ }, z.core.$strict>], "action">;
6837
+
6739
6838
  /**
6740
6839
  * 计划或持续会话的参数。
6741
6840
  * @example 模块内部上下文
@@ -6865,6 +6964,12 @@ declare const submitTurnSchema: z.ZodObject<{
6865
6964
  interface ACPPlatformPolicy {
6866
6965
  /** 只接受已由应用确认的主体和 Agent。默认禁止完全访问。 */
6867
6966
  allowFullAccess?: (scope: RunnerScope, agentId: string) => boolean | Promise<boolean>;
6967
+ /** 授予显式单轮任务控制专属 Rootless Podman 的权限。默认拒绝。 */
6968
+ allowNestedPodman?: (scope: RunnerScope, target: {
6969
+ agentId: string;
6970
+ environmentId: string;
6971
+ workspaceId?: string;
6972
+ }) => boolean | Promise<boolean>;
6868
6973
  /** 自动模式下明确允许同一用户复用独占 Worker。 */
6869
6974
  preferUserWorker?: (scope: RunnerScope, agentId: string) => boolean | Promise<boolean>;
6870
6975
  /** 检查当前主体是否能使用选定工具,每轮重新校验。 */
@@ -6875,13 +6980,26 @@ interface ACPPlatformPolicy {
6875
6980
  revoke: () => void | Promise<void>;
6876
6981
  signal?: AbortSignal;
6877
6982
  }>;
6983
+ /** 在已授权的独占文字轮次注册显示能力。publish 按正文顺序写入 Runner,轮次结束后失效。 */
6984
+ openToolDisplay?: (input: {
6985
+ scope: RunnerScope;
6986
+ sessionId: string;
6987
+ executionId: string;
6988
+ toolIds: readonly string[];
6989
+ signal: AbortSignal;
6990
+ publish: (tool: string, content: RunnerJson) => Promise<void>;
6991
+ }) => {
6992
+ prompt: string;
6993
+ close: () => void;
6994
+ redact?: (text: string) => string;
6995
+ } | undefined;
6878
6996
  /** 在计划和执行时验证知识库、文件与记忆选择的权限。 */
6879
6997
  allowContext?: (scope: RunnerScope, agentId: string, context: NonNullable<ACPPlatformRequest['context']>) => boolean | Promise<boolean>;
6880
6998
  /** 以当前主体检查只读工作区快照的访问权限。 */
6881
6999
  allowWorkspace?: (scope: RunnerScope, workspaceId: string) => boolean | Promise<boolean>;
6882
7000
  /** 在执行节点读取已授权的工作区文件。最多 8 个平铺普通文件,总量受执行环境和 16 MiB 上限约束。 */
6883
7001
  resolveWorkspace?: (scope: RunnerScope, workspaceId: string, signal: AbortSignal) => Promise<Readonly<Record<string, Uint8Array>>>;
6884
- /** 在工作区授权之后读取部署方登记的普通文件项目快照。 */
7002
+ /** 在工作区授权后读取部署方登记的项目快照及已有可执行文件路径。 */
6885
7003
  resolveProject?: (scope: RunnerScope, workspaceId: string, signal: AbortSignal) => Promise<ACPProjectSnapshot | undefined>;
6886
7004
  /** 在成功轮次后发布补丁;只向浏览器交付已绑定主体的产物引用。 */
6887
7005
  publishProject?: (input: {
@@ -6910,6 +7028,17 @@ interface ACPPlatformPolicy {
6910
7028
  }, signal: AbortSignal) => Promise<void>;
6911
7029
  /** 解析已授权技能的正文或原生指令。 */
6912
7030
  resolveSkills?: (scope: RunnerScope, agentId: string, skillIds: readonly string[], signal: AbortSignal) => Promise<ContentBlock[]>;
7031
+ /** 由提供交互响应入口的应用开启原生表单和 URL 询问。 */
7032
+ interactiveElicitation?: boolean;
7033
+ /** 允许一次已公布的模型或参数变更。按已知 Agent 和选项值放行,不能改变受管执行或审批规则。 */
7034
+ allowSessionConfig?: (scope: RunnerScope, sessionId: string, option: {
7035
+ agentId: string;
7036
+ id: string;
7037
+ category: string;
7038
+ value: string | boolean;
7039
+ }) => boolean | Promise<boolean>;
7040
+ /** 从已授权的宿主终端读取输出快照。应验证给定主体、会话与终端的归属。 */
7041
+ readTerminal?: (scope: RunnerScope, sessionId: string, terminalId: string, signal: AbortSignal) => Promise<TerminalOutputResponse | undefined>;
6913
7042
  /** 核对当前 ACL 和原生操作,返回绑定真实对象与操作的规则键。返回 undefined 时拒绝。 */
6914
7043
  resolvePermission?: (scope: RunnerScope, sessionId: string, tool: RequestPermissionRequest['toolCall']) => {
6915
7044
  key: string;
@@ -7706,6 +7835,7 @@ interface ContextManagerOptions {
7706
7835
  *
7707
7836
  * 当 LLM 返回 tool_calls 时,自动执行工具并将结果回传 LLM,
7708
7837
  * 重复此过程直到 LLM 给出文本回复或达到最大轮次。
7838
+ * 达到上限后再请求一次文本回复,禁用工具;设为 0 时,整轮仅生成文本。
7709
7839
  */
7710
7840
  maxToolRounds?: number;
7711
7841
  }
@@ -8586,7 +8716,7 @@ interface ManagedLLMOperations extends LLMOperations {
8586
8716
  models: AIResourceRegistry<z.output<typeof ModelEntrySchema>, z.input<typeof ModelEntrySchema>>;
8587
8717
  }
8588
8718
  /**
8589
- * 包含配置/数据库资源维护的 audio 操作接口。
8719
+ * 包含配置/数据库资源维护的 audio 操作接口;能力查询读取当前合并目录。
8590
8720
  * @example
8591
8721
  * ```ts
8592
8722
  * import { ai } from '@h-ai/ai'
@@ -9222,9 +9352,9 @@ type AudioWsClientMessage = AudioWsStartMessage | AudioWsTextMessage | AudioWsDo
9222
9352
  * ```
9223
9353
  */
9224
9354
  declare const AudioFormatSchema: zod.ZodEnum<{
9225
- pcm16: "pcm16";
9226
9355
  wav: "wav";
9227
9356
  mp3: "mp3";
9357
+ pcm16: "pcm16";
9228
9358
  opus: "opus";
9229
9359
  }>;
9230
9360
  /**
@@ -9252,9 +9382,9 @@ declare const AudioWsStartMessageSchema: zod.ZodObject<{
9252
9382
  voice: zod.ZodOptional<zod.ZodString>;
9253
9383
  instruction: zod.ZodOptional<zod.ZodString>;
9254
9384
  format: zod.ZodOptional<zod.ZodEnum<{
9255
- pcm16: "pcm16";
9256
9385
  wav: "wav";
9257
9386
  mp3: "mp3";
9387
+ pcm16: "pcm16";
9258
9388
  opus: "opus";
9259
9389
  }>>;
9260
9390
  sampleRate: zod.ZodOptional<zod.ZodNumber>;
@@ -9317,9 +9447,9 @@ declare const AudioWsClientMessageSchema: zod.ZodDiscriminatedUnion<[zod.ZodObje
9317
9447
  voice: zod.ZodOptional<zod.ZodString>;
9318
9448
  instruction: zod.ZodOptional<zod.ZodString>;
9319
9449
  format: zod.ZodOptional<zod.ZodEnum<{
9320
- pcm16: "pcm16";
9321
9450
  wav: "wav";
9322
9451
  mp3: "mp3";
9452
+ pcm16: "pcm16";
9323
9453
  opus: "opus";
9324
9454
  }>>;
9325
9455
  sampleRate: zod.ZodOptional<zod.ZodNumber>;
@@ -9587,8 +9717,8 @@ declare function createACPOperations(provider: AIStoreProvider, config: AIConfig
9587
9717
  readonly resources: {
9588
9718
  cpu: number;
9589
9719
  memoryMiB: number;
9590
- pids: number;
9591
9720
  scratchMiB: number;
9721
+ pids: number;
9592
9722
  };
9593
9723
  readonly modelId: string;
9594
9724
  readonly model: {
@@ -9612,6 +9742,7 @@ declare function createACPOperations(provider: AIStoreProvider, config: AIConfig
9612
9742
  readonly reason: "user-policy" | "verified-shared" | "isolated-default" | "explicit";
9613
9743
  readonly nativeResume: "none" | "load" | "resume";
9614
9744
  readonly workspaceId?: string | undefined;
9745
+ readonly runtimeProfile?: "nested-rootless-podman" | undefined;
9615
9746
  readonly agentId: string;
9616
9747
  readonly adapter: string;
9617
9748
  readonly requestedMode: "auto" | "shared" | "user" | "task";
@@ -9640,6 +9771,9 @@ declare function createACPOperations(provider: AIStoreProvider, config: AIConfig
9640
9771
  revoke: (id: string) => Promise<HaiResult<void>>;
9641
9772
  respond: (approvalId: string, decision: ACPApprovalDecision) => Promise<HaiResult<void>>;
9642
9773
  };
9774
+ elicitations: {
9775
+ respond: (id: string, input: z.input<typeof elicitationDecisionSchema>) => Promise<HaiResult<void>>;
9776
+ };
9643
9777
  tasks: {
9644
9778
  findSubmission: (sessionId: string, idempotencyKey: string) => Promise<HaiResult<{
9645
9779
  taskId: string;
@@ -9665,8 +9799,8 @@ declare function createACPOperations(provider: AIStoreProvider, config: AIConfig
9665
9799
  readonly resources: {
9666
9800
  cpu: number;
9667
9801
  memoryMiB: number;
9668
- pids: number;
9669
9802
  scratchMiB: number;
9803
+ pids: number;
9670
9804
  };
9671
9805
  readonly modelId: string;
9672
9806
  readonly model: {
@@ -9690,6 +9824,7 @@ declare function createACPOperations(provider: AIStoreProvider, config: AIConfig
9690
9824
  readonly reason: "user-policy" | "verified-shared" | "isolated-default" | "explicit";
9691
9825
  readonly nativeResume: "none" | "load" | "resume";
9692
9826
  readonly workspaceId?: string | undefined;
9827
+ readonly runtimeProfile?: "nested-rootless-podman" | undefined;
9693
9828
  readonly agentId: string;
9694
9829
  readonly adapter: string;
9695
9830
  readonly requestedMode: "auto" | "shared" | "user" | "task";
@@ -9707,8 +9842,8 @@ declare function createACPOperations(provider: AIStoreProvider, config: AIConfig
9707
9842
  readonly resources: {
9708
9843
  cpu: number;
9709
9844
  memoryMiB: number;
9710
- pids: number;
9711
9845
  scratchMiB: number;
9846
+ pids: number;
9712
9847
  };
9713
9848
  readonly modelId: string;
9714
9849
  readonly model: {
@@ -9732,6 +9867,7 @@ declare function createACPOperations(provider: AIStoreProvider, config: AIConfig
9732
9867
  readonly reason: "user-policy" | "verified-shared" | "isolated-default" | "explicit";
9733
9868
  readonly nativeResume: "none" | "load" | "resume";
9734
9869
  readonly workspaceId?: string | undefined;
9870
+ readonly runtimeProfile?: "nested-rootless-podman" | undefined;
9735
9871
  readonly agentId: string;
9736
9872
  readonly adapter: string;
9737
9873
  readonly requestedMode: "auto" | "shared" | "user" | "task";
@@ -9739,6 +9875,9 @@ declare function createACPOperations(provider: AIStoreProvider, config: AIConfig
9739
9875
  readonly environmentId: string;
9740
9876
  };
9741
9877
  }>>;
9878
+ setConfigOption: (configId: string, value: string | boolean) => Promise<HaiResult<string | number | boolean | z.core.util.JSONType[] | {
9879
+ [key: string]: z.core.util.JSONType;
9880
+ } | null>>;
9742
9881
  close: () => Promise<HaiResult<void>>;
9743
9882
  stream(content: ACPRunRequest["prompt"], options?: ACPTurnOptions): AsyncGenerator<_h_ai_runner.RunnerJson>;
9744
9883
  changeExecution: (execution: NonNullable<ACPPlatformRequest["execution"]> & {
@@ -9749,8 +9888,8 @@ declare function createACPOperations(provider: AIStoreProvider, config: AIConfig
9749
9888
  readonly resources: {
9750
9889
  cpu: number;
9751
9890
  memoryMiB: number;
9752
- pids: number;
9753
9891
  scratchMiB: number;
9892
+ pids: number;
9754
9893
  };
9755
9894
  readonly modelId: string;
9756
9895
  readonly model: {
@@ -9774,6 +9913,7 @@ declare function createACPOperations(provider: AIStoreProvider, config: AIConfig
9774
9913
  readonly reason: "user-policy" | "verified-shared" | "isolated-default" | "explicit";
9775
9914
  readonly nativeResume: "none" | "load" | "resume";
9776
9915
  readonly workspaceId?: string | undefined;
9916
+ readonly runtimeProfile?: "nested-rootless-podman" | undefined;
9777
9917
  readonly agentId: string;
9778
9918
  readonly adapter: string;
9779
9919
  readonly requestedMode: "auto" | "shared" | "user" | "task";
@@ -9793,8 +9933,8 @@ declare function createACPOperations(provider: AIStoreProvider, config: AIConfig
9793
9933
  readonly resources: {
9794
9934
  cpu: number;
9795
9935
  memoryMiB: number;
9796
- pids: number;
9797
9936
  scratchMiB: number;
9937
+ pids: number;
9798
9938
  };
9799
9939
  readonly modelId: string;
9800
9940
  readonly model: {
@@ -9818,6 +9958,7 @@ declare function createACPOperations(provider: AIStoreProvider, config: AIConfig
9818
9958
  readonly reason: "user-policy" | "verified-shared" | "isolated-default" | "explicit";
9819
9959
  readonly nativeResume: "none" | "load" | "resume";
9820
9960
  readonly workspaceId?: string | undefined;
9961
+ readonly runtimeProfile?: "nested-rootless-podman" | undefined;
9821
9962
  readonly agentId: string;
9822
9963
  readonly adapter: string;
9823
9964
  readonly requestedMode: "auto" | "shared" | "user" | "task";
@@ -9835,8 +9976,8 @@ declare function createACPOperations(provider: AIStoreProvider, config: AIConfig
9835
9976
  readonly resources: {
9836
9977
  cpu: number;
9837
9978
  memoryMiB: number;
9838
- pids: number;
9839
9979
  scratchMiB: number;
9980
+ pids: number;
9840
9981
  };
9841
9982
  readonly modelId: string;
9842
9983
  readonly model: {
@@ -9860,6 +10001,7 @@ declare function createACPOperations(provider: AIStoreProvider, config: AIConfig
9860
10001
  readonly reason: "user-policy" | "verified-shared" | "isolated-default" | "explicit";
9861
10002
  readonly nativeResume: "none" | "load" | "resume";
9862
10003
  readonly workspaceId?: string | undefined;
10004
+ readonly runtimeProfile?: "nested-rootless-podman" | undefined;
9863
10005
  readonly agentId: string;
9864
10006
  readonly adapter: string;
9865
10007
  readonly requestedMode: "auto" | "shared" | "user" | "task";
@@ -9867,6 +10009,9 @@ declare function createACPOperations(provider: AIStoreProvider, config: AIConfig
9867
10009
  readonly environmentId: string;
9868
10010
  };
9869
10011
  }>>;
10012
+ setConfigOption: (configId: string, value: string | boolean) => Promise<HaiResult<string | number | boolean | z.core.util.JSONType[] | {
10013
+ [key: string]: z.core.util.JSONType;
10014
+ } | null>>;
9870
10015
  close: () => Promise<HaiResult<void>>;
9871
10016
  stream(content: ACPRunRequest["prompt"], options?: ACPTurnOptions): AsyncGenerator<_h_ai_runner.RunnerJson>;
9872
10017
  changeExecution: (execution: NonNullable<ACPPlatformRequest["execution"]> & {
@@ -9877,8 +10022,8 @@ declare function createACPOperations(provider: AIStoreProvider, config: AIConfig
9877
10022
  readonly resources: {
9878
10023
  cpu: number;
9879
10024
  memoryMiB: number;
9880
- pids: number;
9881
10025
  scratchMiB: number;
10026
+ pids: number;
9882
10027
  };
9883
10028
  readonly modelId: string;
9884
10029
  readonly model: {
@@ -9902,6 +10047,7 @@ declare function createACPOperations(provider: AIStoreProvider, config: AIConfig
9902
10047
  readonly reason: "user-policy" | "verified-shared" | "isolated-default" | "explicit";
9903
10048
  readonly nativeResume: "none" | "load" | "resume";
9904
10049
  readonly workspaceId?: string | undefined;
10050
+ readonly runtimeProfile?: "nested-rootless-podman" | undefined;
9905
10051
  readonly agentId: string;
9906
10052
  readonly adapter: string;
9907
10053
  readonly requestedMode: "auto" | "shared" | "user" | "task";
@@ -9920,8 +10066,8 @@ declare function createACPOperations(provider: AIStoreProvider, config: AIConfig
9920
10066
  readonly resources: {
9921
10067
  cpu: number;
9922
10068
  memoryMiB: number;
9923
- pids: number;
9924
10069
  scratchMiB: number;
10070
+ pids: number;
9925
10071
  };
9926
10072
  readonly modelId: string;
9927
10073
  readonly model: {
@@ -9945,6 +10091,7 @@ declare function createACPOperations(provider: AIStoreProvider, config: AIConfig
9945
10091
  readonly reason: "user-policy" | "verified-shared" | "isolated-default" | "explicit";
9946
10092
  readonly nativeResume: "none" | "load" | "resume";
9947
10093
  readonly workspaceId?: string | undefined;
10094
+ readonly runtimeProfile?: "nested-rootless-podman" | undefined;
9948
10095
  readonly agentId: string;
9949
10096
  readonly adapter: string;
9950
10097
  readonly requestedMode: "auto" | "shared" | "user" | "task";
@@ -11719,7 +11866,7 @@ declare function createACPOperations(provider: AIStoreProvider, config: AIConfig
11719
11866
  /**
11720
11867
  * 关闭本进程拥有的会话并释放锁,不删除历史和工程内容。
11721
11868
  * @param id - 框架会话 ID。
11722
- * @returns 关闭完成的 HaiResult;不允许关闭其他进程拥有的执行环境。
11869
+ * @returns 关闭完成的 HaiResult;仍在启动或由其他进程持有时返回 ACP_BUSY。
11723
11870
  * @example
11724
11871
  * ```ts
11725
11872
  * import { ai } from '@h-ai/ai'
@@ -11977,6 +12124,8 @@ type ACPTransport = {
11977
12124
  interface ACPClientOptions {
11978
12125
  /** 接收原生会话事件,包括 session/new 完成前的事件;抛错将关闭连接。 */
11979
12126
  onEvent?: (event: SessionNotification) => void;
12127
+ /** 接收原生 URL 询问完成通知;宿主核对待完成请求的归属。 */
12128
+ onElicitationComplete?: (id: string) => void;
11980
12129
  /** 可信客户端回调实现;未提供权限回调时默认拒绝。 */
11981
12130
  handlers?: Partial<ClientRequestHandlersByMethod>;
11982
12131
  /** 向智能体声明的能力;声明的文件、终端和 elicitation 能力必须配齐回调。 */
@@ -12030,6 +12179,8 @@ interface ACPAgentAdapterInput {
12030
12179
  statePath: string;
12031
12180
  /** 受管任务请求的权限范围。 */
12032
12181
  permissionProfile?: 'read-only' | 'workspace' | 'full-access';
12182
+ /** 由受管计划确定,原生 Codex 允许任务内测试服务连接。 */
12183
+ runtimeProfile?: _h_ai_runner.RunnerEnvironment['runtimeProfile'];
12033
12184
  /** 为经过隔离验证的原生适配器启用只读共享启动配置。 */
12034
12185
  shared?: boolean;
12035
12186
  /** 已由适配器 Schema 校验的原生扩展选项。 */
@@ -12189,5 +12340,5 @@ interface ACPGitReport {
12189
12340
  */
12190
12341
  type ACPOperations = ReturnType<typeof createACPOperations>;
12191
12342
 
12192
- export { ACPConfigSchema as D, ACPPublishSchema as H, ACPRepositorySchema as I, ACPWorkspaceSchema as L, AIConfigSchema as O, AUDIO_WS_PATH as _, resolveModelApi as a, ApiTypeSchema as a0, AudioConfigSchema as a4, AudioFormatSchema as a5, AudioModelEntrySchema as a7, AudioOperationSchema as a9, CompressConfigSchema as aD, CompressionStrategySchema as aI, EmbeddingConfigSchema as aW, AudioOperationsSchema as aa, AudioProviderSchema as ac, AudioWsClientMessageSchema as ae, AudioWsDoneMessageSchema as ag, AudioWsStartMessageSchema as ao, AudioWsTextMessageSchema as aq, resolveAudioModel as b, EntityTypeSchema as b4, FileConfigSchema as b6, LLMConfigSchema as bL, MCPConfigSchema as bO, MCPExternalServerSchema as bR, MCPServerCapabilitiesSchema as b_, HaiAIError as bb, ImageConfigSchema as bd, ImageModelEntrySchema as bg, ImageProviderSchema as bj, KnowledgeConfigSchema as bp, resolveImageModel as c, MCPServerConfigSchema as c0, OptionalSecretSchema as cA, MemoryConfigSchema as ce, MemoryTypeSchema as cp, ModelCapabilitiesSchema as cu, ModelEntrySchema as cw, ModelScenarioSchema as cy, RetrievalConfigSchema as d2, RetrievalSourceSchema as d9, TokenConfigSchema as dA, SummaryConfigSchema as dn, ensureAudioCredential as e, ai as em, A2AConfigSchema as l, resolveModelEntry as r, serializePlayableAudio as s, A2ASkillConfigSchema as t, ACPAgentSchema as y };
12193
- export type { ApiType as $, A2AAgentCardConfig as A, ACPConfig as B, ACPConfigInput as C, ACPCreateSessionOptions as E, ACPGitReport as F, ACPOperations as G, ACPSessionInfo as J, ACPTransport as K, AIConfig as M, AIConfigInput as N, AIFunctions as P, AIInitOptions as Q, AIRelStore as R, AIRelStoreCompareAndSwap as S, AIRelStoreOptions as T, AIResourceEntry as U, AIResourceRegistry as V, AIStoreProvider as W, AIVectorBackend as X, AIVectorStore as Y, AIVersionedRecord as Z, EntityDocumentRelation as a$, AskOptions as a1, AssistantMessage as a2, AudioConfig as a3, AudioModelEntry as a6, AudioOperation as a8, Citation as aA, CommitTurnInput as aB, CompressConfig as aC, CompressOperations as aE, CompressOptions as aF, CompressResult as aG, CompressionStrategy as aH, ConsolidateOptions as aJ, ConsolidateResult as aK, ContextChatOptions as aL, ContextChatResult as aM, ContextManager as aN, ContextManagerOptions as aO, ContextOperations as aP, ContextResetOptions as aQ, ContextStreamEvent as aR, ConversationTurn as aS, ConversationTurnStatus as aT, DeveloperMessage as aU, EmbeddingConfig as aV, EmbeddingItem as aX, EmbeddingOperations as aY, EmbeddingRequest as aZ, EmbeddingResponse as a_, AudioProviderName as ab, AudioWsClientMessage as ad, AudioWsDoneMessage as af, AudioWsEndMessage as ah, AudioWsErrorMessage as ai, AudioWsSegmentDoneMessage as aj, AudioWsSegmentStartedMessage as ak, AudioWsServerMessage as al, AudioWsSpeechMessage as am, AudioWsStartMessage as an, AudioWsTextMessage as ap, AudioWsTranscriptMessage as ar, ChatCompletionChoice as as, ChatCompletionChunk as at, ChatCompletionDelta as au, ChatCompletionRequest as av, ChatCompletionResponse as aw, ChatHistoryOptions as ax, ChatMessage as ay, ChatRecord as az, MCPServerConfig as b$, EntityDocumentResult as b0, EntityListOptions as b1, EntityQueryOptions as b2, EntityType as b3, FileConfig as b5, GenerateImageRequest as b7, GenerateImageResult as b8, GenerateObjectRequest as b9, KnowledgeIngestResult as bA, KnowledgeOperations as bB, KnowledgeRepairOptions as bC, KnowledgeRepairProgress as bD, KnowledgeRepairResult as bE, KnowledgeRetrieveItem as bF, KnowledgeRetrieveOptions as bG, KnowledgeRetrieveResult as bH, KnowledgeSetupOptions as bI, KnowledgeStore as bJ, LLMConfig as bK, LLMOperations as bM, MCPConfig as bN, MCPContext as bP, MCPExternalServer as bQ, MCPOperations as bS, MCPPrompt as bT, MCPPromptArgument as bU, MCPPromptContent as bV, MCPPromptMessage as bW, MCPResource as bX, MCPResourceContent as bY, MCPServerCapabilities as bZ, GeneratedImage as ba, ImageConfig as bc, ImageContent as be, ImageModelEntry as bf, ImageOperations as bh, ImageProviderName as bi, ImageSize as bk, InteractionScope as bl, KnowledgeAskOptions as bm, KnowledgeAskResult as bn, KnowledgeConfig as bo, KnowledgeDocumentInfo as bq, KnowledgeDocumentListOptions as br, KnowledgeDocumentMetadata as bs, KnowledgeDocumentRemoveOptions as bt, KnowledgeDocumentRevision as bu, KnowledgeEntity as bv, KnowledgeIngestBatchProgress as bw, KnowledgeIngestBatchResult as bx, KnowledgeIngestFileInput as by, KnowledgeIngestInput as bz, ResolvedImageModel as c$, MCPToolDefinition as c1, MCPToolHandler as c2, ManagedAudioOperations as c3, ManagedImageOperations as c4, ManagedLLMOperations as c5, ManagedMCPOperations as c6, ManagedRetrievalOperations as c7, McpServerOptions as c8, MemoryAccessScope as c9, Part as cB, PersonaOperations as cC, PersonaProfile as cD, PersonaProfileInput as cE, PersonaProfileUpdate as cF, PersonaScopeOptions as cG, RagContextItem as cH, RagOperations as cI, RagOptions as cJ, RagResult as cK, RagStreamEvent as cL, ReasoningOperations as cM, ReasoningOptions as cN, ReasoningResult as cO, ReasoningStep as cP, ReasoningStepType as cQ, ReasoningStrategy as cR, ReasoningStreamEvent as cS, ReferenceImage as cT, RerankDocument as cU, RerankItem as cV, RerankOperations as cW, RerankRequest as cX, RerankResponse as cY, ResolveRequiredModelEntryOptions as cZ, ResolvedAudioModel as c_, MemoryAdminOperations as ca, MemoryClearAllOptions as cb, MemoryClearOptions as cc, MemoryConfig as cd, MemoryCoreOperations as cf, MemoryEntry as cg, MemoryEntryInput as ch, MemoryExtractOptions as ci, MemoryInjectionOptions as cj, MemoryListOptions as ck, MemoryListPageOptions as cl, MemoryOperations as cm, MemoryRecallOptions as cn, MemoryType as co, MemoryUpdateInput as cq, Message as cr, MessageContent as cs, MessageRole as ct, ModelEntry as cv, ModelScenario as cx, ObjectRef as cz, A2AAgentCardDocument as d, BuiltinToolBinding as d$, ResolvedModelConfig as d0, RetrievalConfig as d1, RetrievalOperations as d3, RetrievalRequest as d4, RetrievalResult as d5, RetrievalResultItem as d6, RetrievalSource as d7, RetrievalSourceConfig as d8, TokenOperations as dB, TokenUsage as dC, ToolCall as dD, ToolDefinition as dE, ToolMessage as dF, ToolRegistryOperations as dG, ToolsOperations as dH, UserMessage as dI, WhereClause as dJ, WhereOperator as dK, WhereValue as dL, ACPApprovalDecision as dM, ACPCitation as dN, ACPPlatformPolicy as dO, ACPPlatformRequest as dP, ACPProjectChanges as dQ, ACPProjectSnapshot as dR, ACPPublishSnapshot as dS, ACPRunObserver as dT, ACPRunRequest as dU, ACPSessionWorkspace as dV, ACPSubmitTurn as dW, ACPTurnOptions as dX, BuiltinArtifact as dY, BuiltinArtifactAccess as dZ, BuiltinArtifactReference as d_, SSEDecoder as da, SSEEvent as db, ScopedMemoryBinding as dc, ScopedMemoryOperations as dd, SendMessageRequest as de, SessionInfo as df, StoreFilter as dg, StorePage as dh, StoreScope as di, StreamOperations as dj, StreamProcessor as dk, StreamResult as dl, SummaryConfig as dm, SummaryOperations as dp, SummaryOptions as dq, SummaryResult as dr, SystemMessage as ds, Task as dt, TaskArtifactUpdateEvent as du, TaskStatus as dv, TaskStatusUpdateEvent as dw, TempModelConfig as dx, TextContent as dy, TokenConfig as dz, BuiltinToolBroker as e0, BuiltinToolBrokerOptions as e1, BuiltinToolOptions as e2, CreateBuiltinTools as e3, JsonFieldPreview as e4, JsonFieldPreviewOptions as e5, MCPJobFileContext as e6, MCPJobFiles as e7, MCPServiceAuthorization as e8, MCPServiceBinding as e9, MCPServiceBindingRequest as ea, MCPServiceBroker as eb, MCPServiceBrokerOptions as ec, MCPServiceOperations as ed, MCPServiceRequest as ee, McpServer as ef, McpToolOptions as eg, RequestContext as eh, SSEServerTransport as ei, ServerCallContext as ej, StdioServerTransport as ek, StreamableHTTPServerTransport as el, A2AApiKeySecurity as f, A2AAuthenticator as g, A2ACallOptions as h, A2ACallResult as i, A2ACallerIdentity as j, A2AConfig as k, A2AContextInfo as m, A2AHandleResult as n, A2AMessageRecord as o, A2AOperations as p, A2ASecurityConfig as q, A2ATaskFilter as u, ACPAgentAdapter as v, ACPAgentAdapterInput as w, ACPAgentLaunch as x, ACPClientOptions as z };
12343
+ export { ACPConfigSchema as D, ACPPublishSchema as H, ACPRepositorySchema as I, ACPWorkspaceSchema as L, AIConfigSchema as O, AUDIO_WS_PATH as _, resolveModelApi as a, ApiTypeSchema as a0, AudioConfigSchema as a4, AudioFormatSchema as a5, AudioModelEntrySchema as a7, AudioOperationSchema as a9, CompressConfigSchema as aD, CompressionStrategySchema as aI, EmbeddingConfigSchema as aW, AudioOperationsSchema as aa, AudioProviderSchema as ac, AudioWsClientMessageSchema as ae, AudioWsDoneMessageSchema as ag, AudioWsStartMessageSchema as ao, AudioWsTextMessageSchema as aq, resolveAudioModel as b, EntityTypeSchema as b4, FileConfigSchema as b6, LLMConfigSchema as bL, MCPConfigSchema as bO, MCPExternalServerSchema as bR, MCPServerCapabilitiesSchema as b_, HaiAIError as bb, ImageConfigSchema as bd, ImageModelEntrySchema as bg, ImageProviderSchema as bj, KnowledgeConfigSchema as bp, resolveImageModel as c, MCPServerConfigSchema as c0, OptionalSecretSchema as cA, MemoryConfigSchema as ce, MemoryTypeSchema as cp, ModelCapabilitiesSchema as cu, ModelEntrySchema as cw, ModelScenarioSchema as cy, RetrievalConfigSchema as d2, RetrievalSourceSchema as d9, TokenConfigSchema as dA, SummaryConfigSchema as dn, ensureAudioCredential as e, ai as ep, A2AConfigSchema as l, resolveModelEntry as r, serializePlayableAudio as s, A2ASkillConfigSchema as t, ACPAgentSchema as y };
12344
+ export type { ApiType as $, A2AAgentCardConfig as A, ACPConfig as B, ACPConfigInput as C, ACPCreateSessionOptions as E, ACPGitReport as F, ACPOperations as G, ACPSessionInfo as J, ACPTransport as K, AIConfig as M, AIConfigInput as N, AIFunctions as P, AIInitOptions as Q, AIRelStore as R, AIRelStoreCompareAndSwap as S, AIRelStoreOptions as T, AIResourceEntry as U, AIResourceRegistry as V, AIStoreProvider as W, AIVectorBackend as X, AIVectorStore as Y, AIVersionedRecord as Z, EntityDocumentRelation as a$, AskOptions as a1, AssistantMessage as a2, AudioConfig as a3, AudioModelEntry as a6, AudioOperation as a8, Citation as aA, CommitTurnInput as aB, CompressConfig as aC, CompressOperations as aE, CompressOptions as aF, CompressResult as aG, CompressionStrategy as aH, ConsolidateOptions as aJ, ConsolidateResult as aK, ContextChatOptions as aL, ContextChatResult as aM, ContextManager as aN, ContextManagerOptions as aO, ContextOperations as aP, ContextResetOptions as aQ, ContextStreamEvent as aR, ConversationTurn as aS, ConversationTurnStatus as aT, DeveloperMessage as aU, EmbeddingConfig as aV, EmbeddingItem as aX, EmbeddingOperations as aY, EmbeddingRequest as aZ, EmbeddingResponse as a_, AudioProviderName as ab, AudioWsClientMessage as ad, AudioWsDoneMessage as af, AudioWsEndMessage as ah, AudioWsErrorMessage as ai, AudioWsSegmentDoneMessage as aj, AudioWsSegmentStartedMessage as ak, AudioWsServerMessage as al, AudioWsSpeechMessage as am, AudioWsStartMessage as an, AudioWsTextMessage as ap, AudioWsTranscriptMessage as ar, ChatCompletionChoice as as, ChatCompletionChunk as at, ChatCompletionDelta as au, ChatCompletionRequest as av, ChatCompletionResponse as aw, ChatHistoryOptions as ax, ChatMessage as ay, ChatRecord as az, MCPServerConfig as b$, EntityDocumentResult as b0, EntityListOptions as b1, EntityQueryOptions as b2, EntityType as b3, FileConfig as b5, GenerateImageRequest as b7, GenerateImageResult as b8, GenerateObjectRequest as b9, KnowledgeIngestResult as bA, KnowledgeOperations as bB, KnowledgeRepairOptions as bC, KnowledgeRepairProgress as bD, KnowledgeRepairResult as bE, KnowledgeRetrieveItem as bF, KnowledgeRetrieveOptions as bG, KnowledgeRetrieveResult as bH, KnowledgeSetupOptions as bI, KnowledgeStore as bJ, LLMConfig as bK, LLMOperations as bM, MCPConfig as bN, MCPContext as bP, MCPExternalServer as bQ, MCPOperations as bS, MCPPrompt as bT, MCPPromptArgument as bU, MCPPromptContent as bV, MCPPromptMessage as bW, MCPResource as bX, MCPResourceContent as bY, MCPServerCapabilities as bZ, GeneratedImage as ba, ImageConfig as bc, ImageContent as be, ImageModelEntry as bf, ImageOperations as bh, ImageProviderName as bi, ImageSize as bk, InteractionScope as bl, KnowledgeAskOptions as bm, KnowledgeAskResult as bn, KnowledgeConfig as bo, KnowledgeDocumentInfo as bq, KnowledgeDocumentListOptions as br, KnowledgeDocumentMetadata as bs, KnowledgeDocumentRemoveOptions as bt, KnowledgeDocumentRevision as bu, KnowledgeEntity as bv, KnowledgeIngestBatchProgress as bw, KnowledgeIngestBatchResult as bx, KnowledgeIngestFileInput as by, KnowledgeIngestInput as bz, ResolvedImageModel as c$, MCPToolDefinition as c1, MCPToolHandler as c2, ManagedAudioOperations as c3, ManagedImageOperations as c4, ManagedLLMOperations as c5, ManagedMCPOperations as c6, ManagedRetrievalOperations as c7, McpServerOptions as c8, MemoryAccessScope as c9, Part as cB, PersonaOperations as cC, PersonaProfile as cD, PersonaProfileInput as cE, PersonaProfileUpdate as cF, PersonaScopeOptions as cG, RagContextItem as cH, RagOperations as cI, RagOptions as cJ, RagResult as cK, RagStreamEvent as cL, ReasoningOperations as cM, ReasoningOptions as cN, ReasoningResult as cO, ReasoningStep as cP, ReasoningStepType as cQ, ReasoningStrategy as cR, ReasoningStreamEvent as cS, ReferenceImage as cT, RerankDocument as cU, RerankItem as cV, RerankOperations as cW, RerankRequest as cX, RerankResponse as cY, ResolveRequiredModelEntryOptions as cZ, ResolvedAudioModel as c_, MemoryAdminOperations as ca, MemoryClearAllOptions as cb, MemoryClearOptions as cc, MemoryConfig as cd, MemoryCoreOperations as cf, MemoryEntry as cg, MemoryEntryInput as ch, MemoryExtractOptions as ci, MemoryInjectionOptions as cj, MemoryListOptions as ck, MemoryListPageOptions as cl, MemoryOperations as cm, MemoryRecallOptions as cn, MemoryType as co, MemoryUpdateInput as cq, Message as cr, MessageContent as cs, MessageRole as ct, ModelEntry as cv, ModelScenario as cx, ObjectRef as cz, A2AAgentCardDocument as d, BuiltinArtifact as d$, ResolvedModelConfig as d0, RetrievalConfig as d1, RetrievalOperations as d3, RetrievalRequest as d4, RetrievalResult as d5, RetrievalResultItem as d6, RetrievalSource as d7, RetrievalSourceConfig as d8, TokenOperations as dB, TokenUsage as dC, ToolCall as dD, ToolDefinition as dE, ToolMessage as dF, ToolRegistryOperations as dG, ToolsOperations as dH, UserMessage as dI, WhereClause as dJ, WhereOperator as dK, WhereValue as dL, A2AHttpHandler as dM, A2AHttpIdentity as dN, A2AHttpOptions as dO, ACPApprovalDecision as dP, ACPCitation as dQ, ACPPlatformPolicy as dR, ACPPlatformRequest as dS, ACPProjectChanges as dT, ACPProjectSnapshot as dU, ACPPublishSnapshot as dV, ACPRunObserver as dW, ACPRunRequest as dX, ACPSessionWorkspace as dY, ACPSubmitTurn as dZ, ACPTurnOptions as d_, SSEDecoder as da, SSEEvent as db, ScopedMemoryBinding as dc, ScopedMemoryOperations as dd, SendMessageRequest as de, SessionInfo as df, StoreFilter as dg, StorePage as dh, StoreScope as di, StreamOperations as dj, StreamProcessor as dk, StreamResult as dl, SummaryConfig as dm, SummaryOperations as dp, SummaryOptions as dq, SummaryResult as dr, SystemMessage as ds, Task as dt, TaskArtifactUpdateEvent as du, TaskStatus as dv, TaskStatusUpdateEvent as dw, TempModelConfig as dx, TextContent as dy, TokenConfig as dz, BuiltinArtifactAccess as e0, BuiltinArtifactReference as e1, BuiltinToolBinding as e2, BuiltinToolBroker as e3, BuiltinToolBrokerOptions as e4, BuiltinToolOptions as e5, CreateBuiltinTools as e6, JsonFieldPreview as e7, JsonFieldPreviewOptions as e8, MCPJobFileContext as e9, MCPJobFiles as ea, MCPServiceAuthorization as eb, MCPServiceBinding as ec, MCPServiceBindingRequest as ed, MCPServiceBroker as ee, MCPServiceBrokerOptions as ef, MCPServiceOperations as eg, MCPServiceRequest as eh, McpServer as ei, McpToolOptions as ej, RequestContext as ek, SSEServerTransport as el, ServerCallContext as em, StdioServerTransport as en, StreamableHTTPServerTransport as eo, A2AApiKeySecurity as f, A2AAuthenticator as g, A2ACallOptions as h, A2ACallResult as i, A2ACallerIdentity as j, A2AConfig as k, A2AContextInfo as m, A2AHandleResult as n, A2AMessageRecord as o, A2AOperations as p, A2ASecurityConfig as q, A2ATaskFilter as u, ACPAgentAdapter as v, ACPAgentAdapterInput as w, ACPAgentLaunch as x, ACPClientOptions as z };