@epoch-agent/protocol 0.21.0 → 0.23.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
@@ -232,6 +232,18 @@ interface ApprovalRequest {
232
232
  type ApprovalOutcome = 'allow-once' | 'allow-session' | 'allow-always' | 'deny' | PlanApprovalOutcome;
233
233
  /** 合法出口清单,顺序即声明顺序。给错误提示和用例列可选值用 */
234
234
  declare const APPROVAL_OUTCOMES: readonly ApprovalOutcome[];
235
+ /**
236
+ * 一条审批决定管多大范围。
237
+ *
238
+ * `exact` = 只对这一个目标生效(默认);`prefix` = 对这个目录及其子树生效。
239
+ * 只有用户**明确选择**时才该用后者 —— 判据在
240
+ * `PermissionManager.recordApproval` 的 `scope` 参数上。
241
+ *
242
+ * ⚠️ **它和 `WireCachedApproval.scope` 是同一个联合,写在 protocol 是为了
243
+ * 那边能引它**(那份 wire 契约要把它印给「撤销」面板:同一个 target 在两档下
244
+ * 管的范围差着一整棵目录树,用户判断该不该撤靠的正是这个)。
245
+ */
246
+ type ApprovalScope = 'exact' | 'prefix';
235
247
  /**
236
248
  * 把**外部来的**自由字符串收窄成 `ApprovalOutcome`。
237
249
  *
@@ -291,8 +303,19 @@ interface PermissionManager {
291
303
  setLevel(level: PermissionLevel): void;
292
304
  /** 获取当前级别 */
293
305
  getLevel(): PermissionLevel;
294
- /** 记录用户审批决定(写入审批缓存) */
295
- recordApproval(toolName: string, target: string, decision: ApprovalOutcome): void;
306
+ /**
307
+ * 记录用户审批决定(写入审批缓存)。
308
+ *
309
+ * @param scope 这条决定管多大范围。**默认 `'exact'`(只管这一个目标)**,
310
+ * 传 `'prefix'` 才是「这个目录及其子树」。
311
+ *
312
+ * ⚠️ **别把默认值改成 `'prefix'`**:调用方漏传时的后果从「问第二遍」
313
+ * 变成「一次点击放开了整棵目录树」,而两者都在用户看不见的地方发生。
314
+ * 今天传 `'prefix'` 的只有一处 —— `tool-executor` 里「用户刚批准了
315
+ * 一次工作区外的访问」那一条,它的 target 是**已经算好的目录根**
316
+ * (`permission/granted-paths.ts` 的 `approvalRootFor`)。
317
+ */
318
+ recordApproval(toolName: string, target: string, decision: ApprovalOutcome, scope?: ApprovalScope): void;
296
319
  /**
297
320
  * 用户答复了一次审批 —— **只进审计流水,不碰审批缓存**。
298
321
  *
@@ -377,6 +400,30 @@ interface ToolContext {
377
400
  * —— 全仓只有那一份实现(验收 #11)。
378
401
  */
379
402
  extraRoots?: readonly string[];
403
+ /**
404
+ * **权限层这一次放行的、工作区外的路径**(2026-10-08)。
405
+ *
406
+ * 它和 {@link extraRoots} 是两件事,别混:
407
+ * - `extraRoots` = 用户**事先**用 `--add-dir` 声明的地盘,跨会话稳定;
408
+ * - `grantedPaths` = 权限层**这一次**判定放行的结果(档位放行 / 用户刚在
409
+ * 审批框里点了允许),一次调用一变。
410
+ *
411
+ * ## 工具侧该怎么用它
412
+ *
413
+ * 边界判定写成 `isInWorkspace(target, ctx.workDir, [...extraRoots, ...grantedPaths])`,
414
+ * **不要自己去看 `permissionLevel` 判档位**。判据一句话:**「这次放行了什么」
415
+ * 由权限层答,工具层只执行**。在这里再判一次档位等于长出第二张档位表,而两张表
416
+ * 分叉的表现是「界面说放行了、工具说越界」——这一类不一致没有任何检查抓得到
417
+ * (判据同 [`by-level.ts`](../../core/src/permission/by-level.ts) 文件头那张
418
+ * 「沙箱模式」的孪生表)。
419
+ *
420
+ * ## 为什么不给 = 拒
421
+ *
422
+ * 工具层那道 `PathEscapeError` 保留成**第二道网**:嵌入宿主自己实现
423
+ * `PermissionManager` 时不实现这一格,也不该因此把工作区边界整个拆掉。
424
+ * 拿不到就按老行为拒 —— 与没有这个字段之前逐字节相同。
425
+ */
426
+ grantedPaths?: readonly string[];
380
427
  /**
381
428
  * 这次实际生效的**数据目录**(`~/.epoch` 那一层)。工具要算 artifact 路径时
382
429
  * 一律传给 infra 的 `artifactsDir(sessionId, ctx.homeDir)`,**别省第二个参数**。
@@ -1023,6 +1070,45 @@ type AgentRoleSource = 'builtin' | 'user' | 'project' | 'plugin' | 'host';
1023
1070
  interface AgentRole {
1024
1071
  /** slug,`[a-z0-9-]`。同时是 `delegate_task` 的 `role` 入参取值 */
1025
1072
  name: string;
1073
+ /**
1074
+ * **给人看**的名字(2026-10-08)。缺省 = 回落 {@link name}。
1075
+ *
1076
+ * ## 它和 `name` 的分工,一句话:标识是身份,这一格只是称呼
1077
+ *
1078
+ * `name` 一个字节都不动 —— 它仍是 `delegate_task` 的 `role` 入参取值、
1079
+ * `--agent` 的取值、同名合并(`mergeRoles`)的 key,也是会话表上记的那个值。
1080
+ * 这一格**不参与上面任何一条**,纯粹是屏幕上和身份行里那个称呼。
1081
+ *
1082
+ * 之所以必须另开一格而不是放宽 `name`:`AGENT_ROLE_NAME_PATTERN` 只收
1083
+ * `[a-z0-9-]`,而且插件 / 宿主角色的名字**一定带 `<前缀>:`**
1084
+ * (`loadPluginRoles` 是 `${plugin}:${role.name}`)—— 于是插件作者手上那个
1085
+ * 名字天然长成 `easel-kit:easel`,那是两个标识拼起来的,不是一个人的称呼。
1086
+ * 放宽 `name` 的代价写在那个常量上:中文进来会把工具调用打坏。
1087
+ *
1088
+ * ## 三个消费点(都走 `displayName ?? name`,别各写各的)
1089
+ *
1090
+ * | 在哪儿 | 文件 |
1091
+ * | ----------------- | --------------------------------------------------- |
1092
+ * | 输入框那枚 chip | `web/src/composer/expert-chip.tsx` |
1093
+ * | 会话底栏那格身份 | `web/src/composer/identity.tsx` |
1094
+ * | 回合头 + 能力页卡 | `web/src/thread/turn-head.tsx` / `capability/experts.tsx` |
1095
+ *
1096
+ * 外加一个**不在屏幕上**的消费点,而且它比上面几个都值:身份行
1097
+ * (`core/src/agent/message-utils.ts` 的 `identityLine()`)—— 那是**模型每一轮
1098
+ * 都读到**的一句,`easel-kit:easel` 换成「内容助手」在那儿比在屏幕上更省。
1099
+ *
1100
+ * ## 为什么叫 `displayName`(同源的一个先例)
1101
+ *
1102
+ * 插件清单上已有的那一格就叫这个名字(`core/src/plugin/manifest.ts`),
1103
+ * 语义逐字相同:「给人看的名字(不填就印标识)」。而 `title` 在本仓库已被
1104
+ * 会话标题占着(`runtime/src/build.ts` 的 `WireSessionSummary.title`),
1105
+ * 挪过来用会让人以为角色也能像会话那样被重命名。
1106
+ *
1107
+ * ⚠️ **缺省回落发生在消费侧,不在 loader**:读口不写这一格,
1108
+ * 「没写」和「写了但等于 name」不合并成同一个值 —— 前端要判断
1109
+ * 「该不该把它当成一个可以再解释一遍的别名」时,只有前者分得出来。
1110
+ */
1111
+ displayName?: string;
1026
1112
  /**
1027
1113
  * 给**主 agent** 看的「什么时候该派给我」,会进 `delegate_task` 的工具描述。
1028
1114
  *
@@ -1296,6 +1382,16 @@ type AgentRoleScope = 'delegate' | 'session';
1296
1382
  */
1297
1383
  interface ActiveAgentRole {
1298
1384
  name: string;
1385
+ /**
1386
+ * 给人看的称呼({@link AgentRole.displayName},2026-10-08)。**可以没有**,
1387
+ * 这时屏幕上回落印 `name`。
1388
+ *
1389
+ * ⚠️ **它只在真的写过时才在**(装配层那条投影是 `...(displayName ? {…} : {})`),
1390
+ * 所以「没写」和「写了」在这一格上是两个形状 —— 这和上面 `source` 同一套口径:
1391
+ * 拿不到真话就整格不带,而不是填一个和 `name` 逐字相同的值。
1392
+ * 后者会让「这个角色有没有自己的称呼」这件事从网线上消失。
1393
+ */
1394
+ displayName?: string;
1299
1395
  /**
1300
1396
  * 来自哪一层。**可以没有** —— 直接 `new AgentLoop({ role })` 的嵌入宿主
1301
1397
  * 手里未必有这个事实(角色表在装配层)。
@@ -2107,7 +2203,7 @@ type ShellKind = (typeof SHELL_KINDS)[number];
2107
2203
  * core 里有一条用例锁着它们相等 —— 一个只改了一头的人会当场变红。
2108
2204
  */
2109
2205
  declare const UNLIMITED_TURNS = 0;
2110
- type ProviderType = 'openai' | 'anthropic' | 'google' | 'deepseek' | 'groq' | 'mistral' | 'moonshotai' | 'cohere' | 'xai' | 'perplexity' | 'amazon-bedrock' | 'azure' | 'togetherai' | 'ollama' | 'openai-compatible';
2206
+ type ProviderType = 'openai' | 'anthropic' | 'google' | 'deepseek' | 'groq' | 'mistral' | 'moonshotai' | 'zhipu' | 'dashscope' | 'bytedance' | 'qianfan' | 'cohere' | 'xai' | 'perplexity' | 'amazon-bedrock' | 'azure' | 'togetherai' | 'ollama' | 'openai-compatible';
2111
2207
  /** provider 元信息:展示名 + API key 环境变量名 */
2112
2208
  interface ProviderInfo {
2113
2209
  type: ProviderType;
@@ -2137,7 +2233,7 @@ interface ProviderInfo {
2137
2233
  * runtime 的 `providerLabel()`,那两条完整显示名在 catalog 的 `provider.label_*` 下。
2138
2234
  *
2139
2235
  * 判据同这个文件删掉 `PLAN_OUTCOME_LABELS` 那一次:**协议层出码和品牌名,文案在
2140
- * catalog**。品牌名不进 catalog 是因为它本来就不翻 —— 十三家里另外十一家一个字都不用动。
2236
+ * catalog**。品牌名不进 catalog 是因为它本来就不翻 —— 除带注解的那两家,其余各家一个字都不用动。
2141
2237
  */
2142
2238
  declare const PROVIDER_INFOS: readonly ProviderInfo[];
2143
2239
  declare const PROVIDER_TYPES: readonly ProviderType[];
@@ -2267,17 +2363,30 @@ interface EpochConfig {
2267
2363
  *
2268
2364
  * ## 为什么需要一个能关掉的开关
2269
2365
  *
2270
- * 2026-08-16 起**每一条终端命令**都套上了 OS 强制的写入边界,而
2366
+ * 2026-08-16 起**每一条终端命令**都套上了 OS 强制的写入边界(今天 `auto` /
2367
+ * `bypass` 两档除外,见下),而
2271
2368
  * `workspace-write` 那张可写目录表(工作区 + 临时目录 + 一张工具链缓存表,
2272
2369
  * 逐条列在 infra 的 `TOOLCHAIN_CACHE_DIRS` 上)**是猜出来的**。真撞上一条
2273
2370
  * 表里没有的缓存目录时,用户看到的是**一条本来能跑的命令突然被挡** ——
2274
2371
  * 那时他需要的是一个能立刻关掉的开关,而不是等我们发一版把目录补进表里。
2275
2372
  *
2276
- * ## ⚠️ `bypass` 档不是它的替代品
2373
+ * ## ⚠️ `bypass` / `auto` 两档都不是它的替代品
2277
2374
  *
2278
2375
  * `bypass` 映射到 `danger-full-access`,沙箱确实整个让开 —— 但它**同时把审批
2279
2376
  * 也全放开了**,而那两件事本来正交(方案 46 §2.3「我们不做二维」)。
2280
2377
  * 一个只想解开写入边界的人被迫连审批一起关掉,那不是应急路径,是一次降级。
2378
+ *
2379
+ * ⚠️ **2026-10-08 起 `auto` 档也不上沙箱**(`sandboxModeForLevel('auto')` 改成了
2380
+ * `danger-full-access`,判据在那张表上)—— 那一档的文件工具早就放行工作区外,
2381
+ * 留着沙箱只会让同一档里 `file_write('~/x')` 落得下去而 `echo > ~/x` 被挡。
2382
+ * 于是「想让命令写出工作区」今天有**三条粒度不同**的路,它们互不替代:
2383
+ *
2384
+ * | 想让命令写出工作区,但…… | 用哪个 |
2385
+ * | ------------------------------ | ----------- |
2386
+ * | 审批**一条都不想动** | 这个开关 |
2387
+ * | 只留「危险」和「判不了」的审批 | `auto` 档 |
2388
+ * | 什么都不问 | `bypass` 档 |
2389
+ *
2281
2390
  * 这条判据不止写在这儿:`sandboxPolicyFor()` 关掉这个开关时**`mode` 照旧按
2282
2391
  * 权限档位推**(`default` 仍然是 `workspace-write`,不会被改写成
2283
2392
  * `danger-full-access`),所以两个轴始终分得开,`plugin-terminal` 那边有一条
@@ -6816,6 +6925,12 @@ type WireHubEvent =
6816
6925
  * ⚠️ 置顶那一档的过期**看得见、但不会骗人**:那一行还在列表里、点得开、
6817
6926
  * 内容也对,只是位置旧了一拍;而按下去的那一页自己会重取
6818
6927
  * (`SessionActs.reload`),它当场就是对的。
6928
+ *
6929
+ * ⚠️ **绑定工作区(2026-09-30)不在上面这一档里,它要发。** 形状上它和置顶
6930
+ * 很像(同样不增不减任何一行),分界是**那句话会不会骗人**:绑定把那一行送进
6931
+ * 了错误的分组(侧栏那三组读的正是 `WireSessionSummary.workspace`),屏幕上
6932
+ * 那句话是假的,而且**不会自己修**。判据全文在 `server/src/hub.ts` 的
6933
+ * `notifySessionsChanged()` 产地表上。
6819
6934
  */
6820
6935
  | {
6821
6936
  type: 'sessions-changed';
@@ -7907,6 +8022,40 @@ interface WireConfigResponse {
7907
8022
  * 但它答的**只有**引导会话那一个 —— 它不是一份全局真源,从来都不是。
7908
8023
  */
7909
8024
  workspace: WireSessionWorkspace | null;
8025
+ /**
8026
+ * 不绑工作区时,引擎**实际**跑在哪个目录(2026-09-30)。
8027
+ *
8028
+ * 它是宿主起这个服务时的 cwd(`buildRuntime({ workDir })`,缺省 `process.cwd()`),
8029
+ * 也正是绑定表答不出来时的那个回落 —— 引擎算「这段会话在哪儿干活」的一行是
8030
+ * `now?.workspace.root ?? opts.defaultWorkDir`(`session-factory.ts` 的 `site()`)。
8031
+ *
8032
+ * ## 为什么它非上这条端点不可
8033
+ *
8034
+ * 输入框底栏那一格在 `unbound`(建好了、还没挑地盘)时说的是**一个目录的名字**,
8035
+ * 而在有这一格之前那句话根本说不出口 —— 界面上只能画「选择工作区」这个**动作**。
8036
+ * 拿 {@link knownWorkspaces} 的第一条顶替**不行**:那是「最近用过」,
8037
+ * 而不绑时引擎跑的是这一格,两者在同一个屏幕上会给出两个答案。
8038
+ *
8039
+ * ⚠️ **别读成「这段会话绑在这儿」。** 它和 {@link workspace} 是两个问题:
8040
+ * 后者是**用户做过的一次决定**(`bound` 才非 null),这一格是**没做决定时谁在生效**。
8041
+ * 用户挑完目录之后这一格照旧是它自己,不跟着变。
8042
+ *
8043
+ * ## ⚠️ 形状借的是 {@link WireWorkspaceRef},但它**不是**那一族的一员
8044
+ *
8045
+ * 借形状只为一件事:`name` 必须**服务端**切。路径分隔符跟着服务进程的平台走,
8046
+ * 让浏览器切等于在 Windows 上把 `C:\work\proj` 整条当成一个名字 ——
8047
+ * 判据全文在 `server/src/workspace/session.ts` 的 `displayName` 上。
8048
+ *
8049
+ * 但它**不在** {@link knownWorkspaces} 里、也不该被当成一条「最近用过」:
8050
+ * 两处一起印出来的时候,用户会以为那是两个目录。
8051
+ *
8052
+ * ⚠️ 它是**可选键**,和 `maxCostUsd` / `lastSessionId` 那一族同一个形状:
8053
+ * `WebRuntimeView` 是个窄接口,**自己拼它的宿主**([EMBEDDING §10](../../../docs/EMBEDDING.md))
8054
+ * 可以不给 —— 那时**整个不下发这个键**,界面退回「选择工作区」那个纯动作形态
8055
+ * (底栏那一格两种形态都画得出来)。
8056
+ * 把 `EpochRuntime` 整个传进来的宿主什么都不用做:它恒有这一格。
8057
+ */
8058
+ defaultWorkDir?: WireWorkspaceRef;
7910
8059
  /**
7911
8060
  * 本机「已知工作区」清单,最近使用的在前(决定 18 第 5 条)。
7912
8061
  *
@@ -9723,18 +9872,39 @@ declare const WIRE_PLAN_FIELDS: WireFields<WirePlanResponse>;
9723
9872
  * 第三档**不是** `unbound` —— 是 `unknown`(「这个进程说不出它在哪儿干过活」)。
9724
9873
  * 也就是说:`none` / `unbound` 在那一格照旧合并(这一句一个字没变),而那个 `null`
9725
9874
  * 身上还压着**另一件**这里没数到的事。判据全文在 `WireSummaryWorkspace` 第一节。
9875
+ *
9876
+ * ## ⚠️ 2026-09-30:`bound` / `none` 多了一格 `changeable`
9877
+ *
9878
+ * 它说的是**这一次决定还能不能改**,判据只有一条:这段会话**开过工没有**
9879
+ * (runtime 的 `WorkspaceControl.canChange`;`epoch web` 那一侧问的是会话库
9880
+ * ——「有没有那一行」,而那一行是第一轮开始时才建的)。
9881
+ *
9882
+ * **开过工之后照旧一个字不能改**(决定 18 那条锁),还没开过工的话那个窗口里
9883
+ * **一个工具调用都还没有**,也就没有「前面那些相对路径」要护 —— 那次锁在窗口里
9884
+ * 本来就没有对象。所以这不是放宽,是原来那句话把一个空窗口也一起锁上了。
9885
+ *
9886
+ * `unbound` 不带这一格:那一档压根还没有决定,它**一直**是可挑的
9887
+ * (「先聊两句、后选目录」那条路,判据在 `WorkspaceDecisionLog` 上)。
9888
+ *
9889
+ * ⚠️ **它让同一个 `state` 有了两种可点形态**(`bound` 能挑 / 不能挑),
9890
+ * 所以界面必须把这一格画出来 —— 不然屏幕上分不出「已经绑了、锁死了」和
9891
+ * 「已经绑了、但还能换」。底栏那一格的做法是两个一起上:虚线边框管形状、
9892
+ * 文案里那半句管道理(`WorkspacePickerProps.defaultWorkDir` 那一节)。
9726
9893
  */
9727
9894
  type WireWorkspaceBinding =
9728
9895
  /** 绑在这儿。`workspace` 上那三处不对称是决定 18 要求界面必须说出来的 */
9729
9896
  {
9730
9897
  state: 'bound';
9731
9898
  workspace: WireSessionWorkspace;
9899
+ /** 这次决定还能不能改。判据见上面那一节 ⚠️ */
9900
+ changeable: boolean;
9732
9901
  }
9733
9902
  /** 明确选过「不使用工作区」。**不是**「还没选」,见上面那张表 */
9734
9903
  | {
9735
9904
  state: 'none';
9905
+ changeable: boolean;
9736
9906
  }
9737
- /** 建好了、还没选地盘 —— picker 该出现的唯一一档 */
9907
+ /** 建好了、还没选地盘 —— picker 该出现的唯一一档。**它一直可挑**,所以没有 `changeable` */
9738
9908
  | {
9739
9909
  state: 'unbound';
9740
9910
  };
@@ -10591,6 +10761,20 @@ declare const WIRE_COMPACT_FIELDS: WireFields<WireCompactResponse>;
10591
10761
  */
10592
10762
  interface WireAgentRoleSummary {
10593
10763
  name: string;
10764
+ /**
10765
+ * 给人看的称呼(`AgentRole.displayName`,2026-10-08)。**`null` = 没写**,
10766
+ * 那时卡上印的仍是 {@link name}。
10767
+ *
10768
+ * ⚠️ **不要把 `null` 在服务端翻成 `name`**,判据逐字同下面 `tools` 那一格:
10769
+ * 翻过之后「这个身份有没有自己的称呼」这件事从网线上整个消失,而界面正好
10770
+ * 要拿它决定措辞(写没写决定卡上那一句说的是名字还是标识)。
10771
+ * 回落 `name` 是**消费侧**的事(`web` 四处各一个 `??`)。
10772
+ *
10773
+ * ⚠️ 空串不是一档合法值:`ROLE_FRONTMATTER_SCHEMA` 上它是
10774
+ * `z.string().min(1).optional()`,写空串等于没写 —— 别在这一层再收一个
10775
+ * 「空串也算写了」的口径出来。
10776
+ */
10777
+ displayName: string | null;
10594
10778
  /** 给**主 agent** 看的「什么时候派给我」。能力页原样显示,不改写 */
10595
10779
  description: string;
10596
10780
  /**
@@ -11379,7 +11563,7 @@ declare const WIRE_SKILL_REMOVE_FIELDS: WireFields<WireSkillRemoveResponse>;
11379
11563
  /**
11380
11564
  * `POST /api/roles` 的请求体 —— 稿子上有、身份那一栏一直没有的那张「新建」。
11381
11565
  *
11382
- * ## 六格,和 frontmatter 逐格对上,一格不多
11566
+ * ## 每一格都和 frontmatter 对得上,一格不多
11383
11567
  *
11384
11568
  * 角色文件是 Markdown + YAML frontmatter,认得的键只有四个
11385
11569
  * (`name` / `description` / `tools` / `maxTurns`,真源是 `loader.ts` 的
@@ -11395,11 +11579,15 @@ declare const WIRE_SKILL_REMOVE_FIELDS: WireFields<WireSkillRemoveResponse>;
11395
11579
  * >
11396
11580
  * > ✅ **2026-08-27 补齐了,那条理由因此到期 —— 但它没被推翻,是被满足了。**
11397
11581
  * > 这一轮同时加了请求体那一格**和 `role-add.tsx` 上那张表单里的那一格**,
11398
- * > 两个一起落地。⚠️ 所以那句话的**规矩**照旧有效:往这张表里加第六格的人,
11582
+ * > 两个一起落地。⚠️ 所以那句话的**规矩**照旧有效:往这张表里加一格的人,
11399
11583
  * > 要么连表单一起加,要么别加。
11400
11584
  * >
11401
- * > 于是「六格,和 frontmatter 逐格对上,一格不多」重新是逐字真的:
11402
- * > `name` / `description` / `tools` / `maxTurns` / `skills` 五个键 + 正文 = `prompt`。
11585
+ * > 📮 **2026-10-08 照那条规矩加了第七格 `displayName`**(同一天先加的读口,
11586
+ * > 见 `AgentRole.displayName`)。于是今天:frontmatter 认**六个**键
11587
+ * > (`name` / `description` / `tools` / `skills` / `maxTurns` / `displayName`)
11588
+ * > + 正文 = `prompt`,请求体**七格**。⚠️ 上面两段的「四个」「五个」现在都是
11589
+ * > 历史读数,**别照着数**;真源是 `loader.ts` 的 `ROLE_FRONTMATTER_SCHEMA`。
11590
+ * > 要数的话数它,不数这一段。
11403
11591
  *
11404
11592
  * ## ⚠️ 落点恒为**用户级**(`~/.epoch/agents/<name>.md`),请求体里没有这一格
11405
11593
  *
@@ -11418,6 +11606,19 @@ interface WireRoleAddRequest {
11418
11606
  * 「界面上建得出来、下次启动读不进去」,而屏幕上不会有任何东西指向这个输入框。
11419
11607
  */
11420
11608
  name: string;
11609
+ /**
11610
+ * 给人看的称呼(2026-10-08)。**不给 = 回落 `name`**(屏幕上和身份行里都印标识)。
11611
+ *
11612
+ * 它是一条**纯展示**的格子:不参与 `delegate_task` 的取值、不参与同名合并、
11613
+ * 不改文件名(落盘那个文件仍叫 `<name>.md`)。判据和分工写在 protocol 的
11614
+ * `AgentRole.displayName` 上。
11615
+ *
11616
+ * ⚠️ **为什么补这一格**:`AgentRole.displayName` 是加在**读口**(frontmatter)
11617
+ * 上的,而这张表是**写口**。只加读口的话就又是一个「手写 md 生效、界面建不了」
11618
+ * 的字段 —— 这条规矩下面第六节逐字写着(`skills` 那一格刚还过这笔账)。
11619
+ * 两半一起落,`role-add.tsx` 那张表单里也跟着多一格输入。
11620
+ */
11621
+ displayName?: string;
11421
11622
  /**
11422
11623
  * 「什么时候该派给我」。**必填,而且这不是表单礼貌** ——
11423
11624
  * `FrontmatterSchema` 上它是 `z.string().min(1)`,缺了它 loader 会**整份跳过
@@ -12654,6 +12855,81 @@ interface WirePluginPreview {
12654
12855
  name: string;
12655
12856
  version: string;
12656
12857
  } | null;
12858
+ /**
12859
+ * 这个插件依赖了谁、每一个这次怎么处置(2026-09-30)。**没有依赖就是空数组**。
12860
+ *
12861
+ * 这一格是那道闸门的**内容**:`b-kit` 会跟着一起落下来,所以它带来的 hooks 和
12862
+ * MCP 子进程也得摆在同一屏上给用户看一眼 —— 只画根那一份等于让他确认了一个
12863
+ * 自己没看见的东西。
12864
+ *
12865
+ * ⚠️ **空数组和「清单里没写 dependencies」在这一层是同一件事**(core 那一侧才分),
12866
+ * 界面因此只有一种画法:空的就不画那一段。
12867
+ */
12868
+ dependencies: readonly WirePluginDependency[];
12869
+ }
12870
+ /**
12871
+ * 一个依赖这次的处置(2026-09-30)。
12872
+ *
12873
+ * 三档的措辞和 core 的 `InstallDependency` 逐字对齐 —— 它们本来就是同一件事在
12874
+ * 两个层上的说法,而那边那张表(每一档答什么问题)就是这一格的文档。
12875
+ */
12876
+ interface WirePluginDependency {
12877
+ name: string;
12878
+ status: WirePluginDependencyStatus;
12879
+ /** 谁要的它:根的名字,或者闭包里上一层那个依赖的名字 */
12880
+ requiredBy: string;
12881
+ /** `plan` 是解析出来的来源;`unresolved` 时是**试过的那一条**(可能没有) */
12882
+ source: string | null;
12883
+ /** `unresolved` 为什么解不出来。给人看的一句 */
12884
+ reason: string | null;
12885
+ /**
12886
+ * 给人看的名字(清单里的 `displayName`)—— `plan` / `installed` 才有,没有就是 `null`。
12887
+ *
12888
+ * ⚠️ 它和 {@link WirePluginDependency.name} **不是同一件事**:`name` 是写进清单
12889
+ * `dependencies` 那一格、也是市场条目名和宿主 `plugin_key` 的那个标识串,
12890
+ * 而用户认不出它(「b-kit 是什么」)。界面两个都要,判据在 `installed` 那一行的写法上。
12891
+ */
12892
+ displayName: string | null;
12893
+ /** `plan` 才有:它自己的版本 */
12894
+ version: string | null;
12895
+ /**
12896
+ * `plan` 才有:它的 `epochVersion` 和当前引擎不匹配 —— 装得上,但加载器会跳过它。
12897
+ *
12898
+ * ⚠️ 这一格在依赖上比在根上更要紧:根的版本不匹配是「这个插件用不了」,
12899
+ * 而依赖的版本不匹配是「**你以为装上了的那个依赖其实不在场**」——
12900
+ * 后者从表面上完全看不出来。
12901
+ */
12902
+ versionUnmet: WirePluginVersionUnmet | null;
12903
+ /** `plan` 才有:它会带来什么。界面照根那一份的画法画它 */
12904
+ inventory: WirePluginDependencyInventory | null;
12905
+ }
12906
+ type WirePluginDependencyStatus = 'installed' | 'plan' | 'unresolved';
12907
+ /** 「这个引擎加载不了它」。形状同 core 的 `InstallPreview.versionUnmet` */
12908
+ interface WirePluginVersionUnmet {
12909
+ required: string;
12910
+ current: string;
12911
+ reason: string;
12912
+ }
12913
+ /**
12914
+ * 一个依赖会带来什么。
12915
+ *
12916
+ * ⚠️ 这几个字段的名字和口径**逐字同 {@link WirePluginPreview} 上那几格**
12917
+ * (`commands` / `hooks` / `denyRules` / …),差别只是它们在这儿裹了一层 ——
12918
+ * 根那一份是摊平的(一屏只有它一个),依赖有好几个,摊平了分不清谁是谁。
12919
+ * ⚠️ 于是**两边要一起改**:那一屏上根和依赖画的是同一个组件。
12920
+ */
12921
+ interface WirePluginDependencyInventory {
12922
+ /** 已加前缀的命令名(`b-kit:review`) */
12923
+ commands: readonly string[];
12924
+ roles: readonly string[];
12925
+ skills: readonly string[];
12926
+ /** ⚠️ 非空 = 它也会跑 shell 命令 */
12927
+ hooks: readonly WirePluginHookTally[];
12928
+ denyRules: number;
12929
+ /** ⚠️ 已加前缀。非空 = 它也会起子进程 */
12930
+ mcpServers: readonly string[];
12931
+ ignoredBuckets: readonly string[];
12932
+ hasJsTools: boolean;
12657
12933
  }
12658
12934
  /**
12659
12935
  * `POST /api/plugins/install/preview` / `.../update/preview` 的回执。
@@ -13177,43 +13453,6 @@ interface WireMcpApplyResponse {
13177
13453
  }
13178
13454
  declare const WIRE_MCP_APPLY_RESPONSE_FIELDS: WireFields<WireMcpApplyResponse>;
13179
13455
 
13180
- /**
13181
- * 这个进程记下了哪些审批决定,以及**逐条撤销** ——
13182
- * `POST /api/sessions/:id/approval-cache`(2026-08-27)。
13183
- *
13184
- * ## 为什么有这一格
13185
- *
13186
- * 审批弹窗上点错一下,那个工具在这个进程里就死了:`allow-always` 落
13187
- * `~/.epoch/approvals.json`(用户至少删得掉那个文件),而 `deny` 只在内存里、
13188
- * `ttlMs: 0` 永不过期 —— 在这一格之前,**除了重启进程,一次点错的「拒绝」
13189
- * 收不回来**,而屏幕上只会一直印「操作被拦截 [权限]: 已缓存拒绝」。
13190
- * 判据全文在 core 的 [approval-cache.ts](../../core/src/permission/approval-cache.ts)
13191
- * 的 `revoke()` 上,那张 📮 的原文在 `permission/manager.ts` 的
13192
- * `checkRulesAndCache` JSDoc 里。
13193
- *
13194
- * ## ⚠️ 读那一半**不在这条路上**,它搭在 `GET .../security` 里
13195
- *
13196
- * `WirePermissionStatus.cached`([wire-security.ts](./wire-security.ts) 第二节)
13197
- * 就是这张表,那个文件从这里 import {@link WireCachedApproval}。
13198
- * 搭过去而不是在这儿开一条
13199
- * `GET`,两条判据:
13200
- *
13201
- * 1. 安全中心那一屏的纪律是**一次取齐**(`wire-security.ts` 的文件头)。
13202
- * 这张表和它上面那张规则表要在同一屏、同一眼里读 —— 分两发拉的话,
13203
- * 屏幕上会同时挂着 T1 时刻的规则和 T2 时刻的缓存;
13204
- * 2. 审批缓存和 `rules` / `shadows` / `audit` 一样是**进程级**的事实
13205
- * (core 的 `permission/shared.ts`),它本来就该和那三样躺在同一个块里。
13206
- *
13207
- * 所以这个文件里只有**写**那一半,以及被两边共用的那一行的形状。
13208
- *
13209
- * ## ⚠️ 名字不许简称成 `approvals`,那个词已经被占了
13210
- *
13211
- * `GET /api/sessions/:id/approvals` 是**挂起的审批请求**(重连后补拉那一条),
13212
- * `POST /api/approvals/:requestId` 是回答其中一条。那是「现在有人在问你」,
13213
- * 这一条是「你以前答过什么」—— 两件事共用一个词的话,
13214
- * `/api/sessions/:id/approvals` 上会同时挂着一个队列和一张历史表。
13215
- * 所以这一路逐字叫 `approval-cache`,和引擎侧那个类同名。
13216
- */
13217
13456
  /**
13218
13457
  * 缓存里存得下的决定。**没有 `allow-once`** —— 那一档刻意不入缓存
13219
13458
  * (进了就变成「永久允许」了,判据在 core 的 `ApprovalCache.record()` 上),
@@ -13257,7 +13496,7 @@ interface WireCachedApproval {
13257
13496
  * **必须印出来**:同一个 `target` 在两档下管的范围差着一整棵目录树,
13258
13497
  * 而用户判断「这条该不该撤」靠的正是这个。
13259
13498
  */
13260
- scope: 'exact' | 'prefix';
13499
+ scope: ApprovalScope;
13261
13500
  decision: WireCachedDecision;
13262
13501
  /** `Date.now()`,记下这条决定的时刻。时区归浏览器,时刻归 wire */
13263
13502
  at: number;
@@ -14767,7 +15006,7 @@ interface WireProviderOption {
14767
15006
  */
14768
15007
  keyHint: string | null;
14769
15008
  /**
14770
- * **这台机器此刻配的就是这一家**(2026-09-11)。十三家里最多一家是 `true`。
15009
+ * **这台机器此刻配的就是这一家**(2026-09-11)。这张单子里最多一家是 `true`。
14771
15010
  *
14772
15011
  * ## 加它是为了让选择器「一展示就有清单」
14773
15012
  *
@@ -16444,4 +16683,4 @@ declare const SECRET_SERVICE = "epoch-agent";
16444
16683
  */
16445
16684
  declare const MCP_DATA_KEY_NAME = "mcp-auth-data-key";
16446
16685
 
16447
- export { ACTION_CONTEXTS, AGENT_ROLE_NAME_PATTERN, API_KEY_ENV_VARS, APPEARANCE_LANGS, APPEARANCE_THEMES, APPROVAL_OUTCOMES, type ActiveAgentRole, type AgentEvent, type AgentEventOf, type AgentEventType, type AgentRole, type AgentRoleScope, type AgentRoleSource, type AppearanceLang, type AppearanceTheme, type ApprovalAnswer, type ApprovalOutcome, type ApprovalReply, type ApprovalRequest, type ArtifactKind, type AttributeValue, type Attributes, type BackgroundTaskInfo, type BackgroundTaskKind, type BackgroundTaskStatus, type BlankCard, type BlankGreeting, type BoundKey, type BudgetBreach, COMMAND_NAME_PATTERN, COMPLIANCE_ACTIONS, COMPLIANCE_CATEGORIES, CURRENCIES, type Catalogs, type ComplianceAction, type ComplianceCategory, type ContextBreakdown, type ContextSegment, type Currency, type CurrencyDisplay, type CustomCommandDef, type CustomCommandSource, DEFAULT_AGENT_ROLE, DEFAULT_LANG, type DecidedTrustLevel, type Diagnostic, DiagnosticSink, type DiagnosticStatus, type EpochConfig, type EpochContentPart, type EpochFilePart, type EpochHook, type EpochImagePart, type EpochMessage, type EpochMessageRole, type EpochPlugin, type EpochSessionPart, type EpochSkill, type EpochTextPart, type EpochTool, type EpochToolCall, type EpochToolResult, type EpochTurnFacts, type EpochUserContent, type ExpandedCommand, FOLLOW_SYSTEM, type FileOmitReason, type FinishReason, type FixableApproval, type FlatCatalog, type FormatMoneyOptions, GEN_AI, HEADLESS_INPUT_EVENT_TYPES, HEADLESS_INPUT_FORMATS, HEADLESS_OUTPUT_FORMATS, HEADLESS_PROTOCOL_VERSION, type HeadlessEnvelope, type HeadlessEvent, type HeadlessInit, type HeadlessInputEvent, type HeadlessInputEventType, type HeadlessInputFormat, type HeadlessLifecycleEvent, type HeadlessOutputFormat, type HeadlessResult, type HeadlessResultReason, type HookContext, type HookEvent, type HookHandler, type HookManager, type HookRegistration, type HookType, type HostText, type HostUser, type JsonSchema, KEY_ACTIONS, type KeyAction, type KeyChord, type KeyContext, type KeySequence, type KeybindingReport, type KeybindingSource, type KeybindingTable, LANGS, type Lang, type LocalizedDetail, type LogFn, MAX_ATTACH_BYTES, MAX_ATTACH_FILES, MAX_ATTACH_TOTAL_BYTES, MAX_HEADER_CHARS, MAX_OPTIONS, MAX_QUESTIONS, MAX_SESSION_ATTACH_BYTES, MAX_SESSION_REFS, MCP_DATA_KEY_NAME, METRIC, MIN_OPTIONS, type MentionSet, type ModelRef, type ModelSelection, type ModelSelectionOrigin, type MoneyDigits, NOOP_TELEMETRY, type NoticeCode, OPERATION_TYPES, OVERSIZE_RATIO, type Operation, type OperationType, PERMISSION_LEVELS, PLAN_OUTCOMES, PLUGIN_CATEGORY_DISPLAY_SEP, PLUGIN_MENU_MESSAGE_TYPE, PLUGIN_UPLOAD_MULTI_SEP, PROVIDER_INFOS, PROVIDER_TYPES, type PermissionDecision, type PermissionLevel, type PermissionManager, type PermissionRuleLists, type PlanApprovalOutcome, type PlanProposal, type PluginContext, type PluginMenuMessage, type ProviderInfo, type ProviderType, type QuestionAnswer, type QuestionItem, type QuestionOption, type QuestionPage, type QuestionRequest, RESERVED_CHORDS, RESERVED_COMMAND_NAMES, type RejectReason, type RejectedKey, type RuleValue, SCHEDULE_DRAFT_TOOL, SCHEDULE_INTERVAL_MINUTES, SCHEDULE_RUN_STATUSES, SCHEDULE_TEMPLATES, SEARCH_API_KEY_ENV, SEARCH_PROVIDER_TYPES, SECRET_SERVICE, SEQUENCE_CONTEXTS, SESSION_MENTION_PREFIX, SESSION_REFERENCE_ERROR_CODES, SETTINGS_PANE_IDS, SHELL_KINDS, SIDEBAR_MENU_MESSAGE_TYPE, SIMULTANEOUS_CONTEXTS, SYSTEM_NOTE_PREFIX, type ScheduleAllowlist, type ScheduleBackendKind, type ScheduleCycle, type ScheduleDefinition, type ScheduleDraft, type ScheduleDraftAllowlist, type ScheduleDraftCreate, type ScheduleDraftPermission, type ScheduleDraftUpdate, type SchedulePendingApproval, type SchedulePendingItem, type ScheduleRun, type ScheduleRunStatus, type ScheduleRunnerSpec, type ScheduleTemplate, type ScheduleTemplateId, type ScheduleTrigger, type ScheduleTriggerKind, type ScheduleWeekday, type ScheduleWideningKind, type SearchProviderType, type SecretBackendId, type SecretStore, type SelectionContext, type SelectionRejection, type SelectionWarning, type SessionAttachKind, type SessionAttachResult, type SessionOmitReason, type SessionSurfaceMessage, type SessionSurfaceView, type SetSelectionResult, type SettingsPaneId, type SettingsPaneItem, type ShellKind, type SidebarMenuItem, type SidebarMenuMessage, type SpanLike, type SubToolCall, type SubToolCallResult, type Telemetry, type TokenUsage, type ToolAnnotations, type ToolArtifact, type ToolArtifactInput, type ToolContext, type ToolDefinition, ToolExposure, type ToolProvider, type ToolResult, type Translate, type TranslateVars, type TrustExecGrant, type TrustGrant, type TrustLevel, type TrustManager, type TrustRecord, type TrustScope, type TrustTier, UNLIMITED_TURNS, type VerifyResult, WIRE_ABORT_FIELDS, WIRE_ABOUT_FIELDS, WIRE_AGENT_ROLE_FIELDS, WIRE_APPEARANCE_RESPONSE_FIELDS, WIRE_APPROVAL_CACHE_REVOKE_REQUEST_FIELDS, WIRE_APPROVAL_CACHE_REVOKE_RESPONSE_FIELDS, WIRE_APPROVAL_LIST_FIELDS, WIRE_APPROVAL_ROW_FIELDS, WIRE_ARTIFACTS_FIELDS, WIRE_ATTACHMENT_UPLOAD_FIELDS, WIRE_AUDIT_LOG_FIELDS, WIRE_AUDIT_ROW_FIELDS, WIRE_AUTH_COOKIE, WIRE_AUTH_COOKIE_ATTRS, WIRE_AUTH_TOKEN_PARAM, WIRE_BACKGROUND_TASK_FIELDS, WIRE_BLOCKED_GOALS_FIELDS, WIRE_BLOCKED_GOAL_FIELDS, WIRE_BLOCKED_LEVEL_FIELDS, WIRE_BUILTIN_CONNECTOR_FIELDS, WIRE_CACHED_APPROVAL_FIELDS, WIRE_CAPABILITIES_FIELDS, WIRE_CAPABILITY_PROJECT_FIELDS, WIRE_CHECKPOINT_LIST_FIELDS, WIRE_CHECKPOINT_SUMMARY_FIELDS, WIRE_COMMANDS_FIELDS, WIRE_COMMAND_EXPANSION_FIELDS, WIRE_COMPACT_FIELDS, WIRE_COMPRESSION_LINE_FIELDS, WIRE_CONFIG_FIELDS, WIRE_CONTEXT_FIELDS, WIRE_CREATE_SESSION_FIELDS, WIRE_CREATE_WORKSPACE_FIELDS, WIRE_CREATE_WORKSPACE_RESPONSE_FIELDS, WIRE_CUSTOM_COMMAND_FIELDS, WIRE_DELETE_SESSION_FIELDS, WIRE_DIFF_FILE_FIELDS, WIRE_ERROR_FIELDS, WIRE_FILE_CANDIDATES_FIELDS, WIRE_FILE_CANDIDATE_FIELDS, WIRE_FILE_CHANGE_FIELDS, WIRE_FILE_OPEN_RESPONSE_FIELDS, WIRE_FILE_REFERENCE_FIELDS, WIRE_FILE_STAT_MAX, WIRE_FILE_STAT_OK_FIELDS, WIRE_FILE_STAT_REFUSED_FIELDS, WIRE_FILE_STAT_RESPONSE_FIELDS, WIRE_FILE_TEXT_RESPONSE_FIELDS, WIRE_FORGET_WORKSPACE_FIELDS, WIRE_FORGET_WORKSPACE_RESPONSE_FIELDS, WIRE_GOAL_ACTIONS, WIRE_GOAL_BLOCK_FIELDS, WIRE_GOAL_CLEAR_FIELDS, WIRE_GOAL_CREATE_FIELDS, WIRE_GOAL_FIELDS, WIRE_GOAL_LIMITS_FIELDS, WIRE_GOAL_PHASES, WIRE_GOAL_REFUSALS, WIRE_GOAL_RESPONSE_FIELDS, WIRE_GOAL_WRITE_FIELDS, WIRE_HEALTH_FIELDS, WIRE_IMAGE_REFERENCE_FIELDS, WIRE_KNOWN_WORKSPACE_FIELDS, WIRE_LANG_PARAM, WIRE_LAST_SESSION_FIELDS, WIRE_LAST_SESSION_RESPONSE_FIELDS, WIRE_MANAGED_LOCK_FIELDS, WIRE_MCP_ADD_FIELDS, WIRE_MCP_ADD_RESPONSE_FIELDS, WIRE_MCP_APPLY_ENTRY_FIELDS, WIRE_MCP_APPLY_RESPONSE_FIELDS, WIRE_MCP_CONFIG_APPLY_FIELDS, WIRE_MCP_CONFIG_FIELDS, WIRE_MCP_CONFIG_ISSUE_FIELDS, WIRE_MCP_CONFIG_SAVE_FIELDS, WIRE_MCP_CONFIG_SAVE_RESPONSE_FIELDS, WIRE_MCP_CONNECTOR_FIELDS, WIRE_MCP_RECONNECT_FIELDS, WIRE_MESSAGE_LIST_FIELDS, WIRE_MODEL_FIELDS, WIRE_MODEL_SELECTION_FIELDS, WIRE_MODEL_SET_FIELDS, WIRE_MODEL_SUGGESTIONS_FIELDS, WIRE_PATCH_SESSION_FIELDS, WIRE_PATCH_SESSION_RESPONSE_FIELDS, WIRE_PERMISSION_RULE_FIELDS, WIRE_PERMISSION_SET_REQUEST_FIELDS, WIRE_PERMISSION_SET_RESPONSE_FIELDS, WIRE_PERMISSION_SHADOW_FIELDS, WIRE_PERMISSION_STATE_FIELDS, WIRE_PERMISSION_STATUS_FIELDS, WIRE_PLAN_ACTIONS, WIRE_PLAN_FIELDS, WIRE_PLAN_MODE_REQUEST_FIELDS, WIRE_PLAN_MODE_RESPONSE_FIELDS, WIRE_PLAN_MODE_STATE_FIELDS, WIRE_PLUGINS_FIELDS, WIRE_PLUGIN_ACTION_FIELDS, WIRE_PLUGIN_ARCHIVE_SUFFIXES, WIRE_PLUGIN_INSTALL_FIELDS, WIRE_PLUGIN_LOCAL_FIELDS, WIRE_PLUGIN_LOCAL_INSTALL_FIELDS, WIRE_PLUGIN_MARKETPLACE_FIELDS, WIRE_PLUGIN_MARKETPLACE_RESPONSE_FIELDS, WIRE_PLUGIN_NAME_FIELDS, WIRE_PLUGIN_PREVIEW_FIELDS, WIRE_PLUGIN_PREVIEW_RESPONSE_FIELDS, WIRE_PLUGIN_REFRESH_RESPONSE_FIELDS, WIRE_PLUGIN_STAGE_FIELDS, WIRE_PLUGIN_STAGE_RESPONSE_FIELDS, WIRE_PLUGIN_UPDATE_FIELDS, WIRE_PLUGIN_UPLOAD_CONFIRM_FIELDS, WIRE_PLUGIN_UPLOAD_FIELDS, WIRE_PLUGIN_UPLOAD_FORM_FIELDS, WIRE_PLUGIN_UPLOAD_PREVIEW_RESPONSE_FIELDS, WIRE_PLUGIN_UPLOAD_RESPONSE_FIELDS, WIRE_POLICY_DIR_FIELDS, WIRE_POLICY_STATUS_FIELDS, WIRE_PROJECT_INVENTORY_FIELDS, WIRE_PROVIDERS_FIELDS, WIRE_PROVIDER_KEY_FIELDS, WIRE_PROVIDER_MODELS_FIELDS, WIRE_PROVIDER_OPTION_FIELDS, WIRE_QUESTION_LIST_FIELDS, WIRE_QUESTION_ROW_FIELDS, WIRE_RESPOND_APPROVAL_FIELDS, WIRE_RESPOND_APPROVAL_RESPONSE_FIELDS, WIRE_RESPOND_QUESTION_FIELDS, WIRE_RESPOND_QUESTION_RESPONSE_FIELDS, WIRE_REWIND_FILE_PLAN_FIELDS, WIRE_REWIND_OUTCOME_FIELDS, WIRE_REWIND_PREVIEW_FIELDS, WIRE_REWIND_REQUEST_FIELDS, WIRE_REWIND_RESPONSE_FIELDS, WIRE_REWIND_SCOPES, WIRE_ROLES_FIELDS, WIRE_ROLE_ADD_FIELDS, WIRE_ROLE_ADD_RESPONSE_FIELDS, WIRE_ROLE_REMOVE_FIELDS, WIRE_RUNNING_SCHEDULE_FIELDS, WIRE_SANDBOX_STATUS_FIELDS, WIRE_SCHEDULE_CAPABILITY_FIELDS, WIRE_SCHEDULE_CREATE_FIELDS, WIRE_SCHEDULE_DEFAULTS_FIELDS, WIRE_SCHEDULE_DELETE_FIELDS, WIRE_SCHEDULE_FIELDS, WIRE_SCHEDULE_FIX_FIELDS, WIRE_SCHEDULE_FIX_REQUEST_FIELDS, WIRE_SCHEDULE_ISSUE_CODES, WIRE_SCHEDULE_LIST_FIELDS, WIRE_SCHEDULE_PENDING_FIELDS, WIRE_SCHEDULE_RECORDING_FIELDS, WIRE_SCHEDULE_ROW_FIELDS, WIRE_SCHEDULE_RUNNING_FIELDS, WIRE_SCHEDULE_RUNS_FIELDS, WIRE_SCHEDULE_RUN_FIELDS, WIRE_SCHEDULE_SAVE_FIELDS, WIRE_SECURITY_FIELDS, WIRE_SECURITY_WORKSPACE_FIELDS, WIRE_SEND_MESSAGE_FIELDS, WIRE_SEND_MESSAGE_RESPONSE_FIELDS, WIRE_SESSION_CANDIDATES_FIELDS, WIRE_SESSION_CANDIDATE_FIELDS, WIRE_SESSION_FINISH_FIELDS, WIRE_SESSION_LIST_FIELDS, WIRE_SESSION_REFERENCE_FIELDS, WIRE_SESSION_RESPONSE_FIELDS, WIRE_SESSION_SUMMARY_FIELDS, WIRE_SESSION_WORKSPACE_FIELDS, WIRE_SESSION_WORKSPACE_RESPONSE_FIELDS, WIRE_SETTINGS_FIELDS, WIRE_SETTINGS_WRITE_FIELDS, WIRE_SETTINGS_WRITE_REQUEST_FIELDS, WIRE_SETTING_PENDING_FIELDS, WIRE_SETTING_ROW_FIELDS, WIRE_SETTING_STEP_FIELDS, WIRE_SETTING_WRITE_FIELDS, WIRE_SETTING_WRITE_LAYERS, WIRE_SKILL_BODY_FIELDS, WIRE_SKILL_DROP_SUFFIXES, WIRE_SKILL_FIELDS, WIRE_SKILL_IMPORT_FIELDS, WIRE_SKILL_IMPORT_PREVIEW_FIELDS, WIRE_SKILL_REMOVE_FIELDS, WIRE_SKILL_STAGE_FIELDS, WIRE_TASKS_FIELDS, WIRE_TOOLS_FIELDS, WIRE_TOOL_GATE_FIELDS, WIRE_TOOL_ROW_FIELDS, WIRE_TRUST_REQUEST_FIELDS, WIRE_TRUST_REQUEST_RESPONSE_FIELDS, WIRE_WORKSPACE_DIFF_FIELDS, WIRE_WORKSPACE_DIRS_FIELDS, WIRE_WORKSPACE_DIR_ENTRY_FIELDS, WIRE_WORKSPACE_REF_FIELDS, type WireAbortResponse, type WireAbout, type WireAgentEnvelope, type WireAgentEvent, type WireAgentRoleSummary, type WireAppearanceRequest, type WireAppearanceResponse, type WireApprovalCacheRevokeRequest, type WireApprovalCacheRevokeResponse, type WireApprovalListResponse, type WireApprovalRequest, type WireArtifactsResponse, type WireAttachmentUploadResponse, type WireAuditCode, type WireAuditLog, type WireAuditOutcome, type WireAuditRow, type WireAuthDenyReason, type WireAuthDenyStatus, type WireAuthGuard, type WireAuthRequestView, type WireAuthVerdict, type WireBackgroundTask, type WireBindWorkspaceRequest, type WireBlockedGoal, type WireBlockedGoalsResponse, type WireBlockedLevel, type WireBuiltinConnector, type WireCachedApproval, type WireCachedDecision, type WireCapabilitiesResponse, type WireCapabilityProject, type WireCheckpointListResponse, type WireCheckpointSummary, type WireCommandExpansion, type WireCommandsResponse, type WireCompactRequest, type WireCompactResponse, type WireCompressionLine, type WireConfigResponse, type WireContextResponse, type WireCreateSessionRequest, type WireCreateSessionResponse, type WireCreateWorkspaceRequest, type WireCreateWorkspaceResponse, type WireCustomCommand, type WireDeleteSessionResponse, type WireDiffFile, type WireDiffNote, type WireDiffOmitReason, type WireDiffSource, type WireDiffStatus, type WireEnvelope, type WireErrorResponse, type WireEvent, type WireFields, type WireFileCandidate, type WireFileCandidatesResponse, type WireFileChange, type WireFileKind, type WireFileOpenRefusal, type WireFileOpenResponse, type WireFileReference, type WireFileRefusal, type WireFileStat, type WireFileStatOk, type WireFileStatRefused, type WireFileStatResponse, type WireFileTextResponse, type WireFixture, type WireFixtureCase, type WireForgetWorkspaceRequest, type WireForgetWorkspaceResponse, type WireGoal, type WireGoalBlock, type WireGoalClearResponse, type WireGoalCreateRequest, type WireGoalLimits, type WireGoalPhase, type WireGoalRefusal, type WireGoalResponse, type WireGoalUpdateRequest, type WireGoalWriteResponse, type WireHealthResponse, type WireHostCompose, type WireHostComposeRequest, type WireHostComposeResponse, type WireHostComposeStateResponse, type WireHostComposeTakeResponse, type WireHubEnvelope, type WireHubEvent, type WireImageReference, type WireKnownWorkspace, type WireKnownWorkspaceRef, type WireLastSessionRequest, type WireLastSessionResponse, type WireManagedLock, type WireMcpAddRequest, type WireMcpAddResponse, type WireMcpApplyAction, type WireMcpApplyEntry, type WireMcpApplyResponse, type WireMcpConfigApplyRequest, type WireMcpConfigIssue, type WireMcpConfigResponse, type WireMcpConfigSaveRequest, type WireMcpConfigSaveResponse, type WireMcpConnector, type WireMcpReconnectResponse, type WireMessageListResponse, type WireModelCaveat, type WireModelProbeStatus, type WireModelRejection, type WireModelResponse, type WireModelSelection, type WireModelSetRequest, type WireModelSetResponse, type WireModelSource, type WireModelSuggestions, type WirePatchSessionRequest, type WirePatchSessionResponse, type WirePermissionRememberFailure, type WirePermissionRuleRow, type WirePermissionSetRequest, type WirePermissionSetResponse, type WirePermissionShadow, type WirePermissionState, type WirePermissionStatus, type WirePickDirectoryResponse, type WirePlanAction, type WirePlanModeRequest, type WirePlanModeResponse, type WirePlanModeState, type WirePlanResponse, type WirePluginActionResponse, type WirePluginCategory, type WirePluginCounts, type WirePluginEntry, type WirePluginHit, type WirePluginHookTally, type WirePluginInstallRequest, type WirePluginLocalInstallRequest, type WirePluginLocalRequest, type WirePluginMarketplace, type WirePluginMarketplaceRequest, type WirePluginMarketplaceResponse, type WirePluginMenuItem, type WirePluginNameRequest, type WirePluginPreview, type WirePluginPreviewRequest, type WirePluginPreviewResponse, type WirePluginRefreshResponse, type WirePluginRefuseReason, type WirePluginSourceType, type WirePluginStageRequest, type WirePluginStageResponse, type WirePluginStatus, type WirePluginUpdateRequest, type WirePluginUploadChoice, type WirePluginUploadConfirmRequest, type WirePluginUploadField, type WirePluginUploadFieldName, type WirePluginUploadFields, type WirePluginUploadFile, type WirePluginUploadForm, type WirePluginUploadPlan, type WirePluginUploadPreviewResponse, type WirePluginUploadRequest, type WirePluginUploadResponse, type WirePluginVisibility, type WirePluginsResponse, type WirePolicyDir, type WirePolicyStatus, type WireProjectInventory, type WireProviderKeyRequest, type WireProviderKeyResponse, type WireProviderModelsRequest, type WireProviderModelsResponse, type WireProviderOption, type WireProviderSummary, type WireProvidersResponse, type WireQuestionListResponse, type WireQuestionRequest, type WireReplayMessage, type WireResetReason, type WireRespondApprovalRequest, type WireRespondApprovalResponse, type WireRespondQuestionRequest, type WireRespondQuestionResponse, type WireRewindAction, type WireRewindDrift, type WireRewindFilePlan, type WireRewindOutcome, type WireRewindPreview, type WireRewindRequest, type WireRewindResponse, type WireRewindScope, type WireRoleAddRequest, type WireRoleAddResponse, type WireRoleRemoveFailure, type WireRoleRemoveResponse, type WireRolesResponse, type WireRunningSchedule, type WireSandboxReason, type WireSandboxStatus, type WireScheduleCapability, type WireScheduleCreateRequest, type WireScheduleDefaults, type WireScheduleDeleteResponse, type WireScheduleFixRequest, type WireScheduleFixResponse, type WireScheduleIssue, type WireScheduleIssueCode, type WireScheduleListResponse, type WireSchedulePendingResponse, type WireScheduleRecordingResponse, type WireScheduleRegisterRefusal, type WireScheduleRegisterWarning, type WireScheduleRegistration, type WireScheduleResponse, type WireScheduleRow, type WireScheduleRunResponse, type WireScheduleRunningResponse, type WireScheduleRunsResponse, type WireScheduleSaveResponse, type WireScheduleUpdateRequest, type WireSecurityResponse, type WireSecurityWorkspace, type WireSendMessageRequest, type WireSendMessageResponse, type WireSessionCandidate, type WireSessionCandidatesResponse, type WireSessionFinish, type WireSessionListResponse, type WireSessionReference, type WireSessionResponse, type WireSessionSummary, type WireSessionWorkspace, type WireSessionWorkspaceResponse, type WireSettingApply, type WireSettingFutile, type WireSettingLayer, type WireSettingPending, type WireSettingRow, type WireSettingStep, type WireSettingValue, type WireSettingValueKind, type WireSettingWrite, type WireSettingWriteLayer, type WireSettingsResponse, type WireSettingsWriteRequest, type WireSettingsWriteResponse, type WireSkillBodyResponse, type WireSkillImportConflict, type WireSkillImportEntry, type WireSkillImportFailure, type WireSkillImportForm, type WireSkillImportIssue, type WireSkillImportPreviewResponse, type WireSkillImportResponse, type WireSkillRemoveFailure, type WireSkillRemoveResponse, type WireSkillStageFailure, type WireSkillStageResponse, type WireSkillSummary, type WireSummaryWorkspace, type WireTaggedEvent, type WireTasksResponse, type WireToolGate, type WireToolGateAxis, type WireToolRow, type WireToolSummary, type WireToolVerdict, type WireToolsResponse, type WireTrustRequestRequest, type WireTrustRequestResponse, type WireTurnState, type WireWorkspaceBinding, type WireWorkspaceDiffResponse, type WireWorkspaceDirEntry, type WireWorkspaceDirsResponse, type WireWorkspaceRef, apiKeyEnvVar, assertNeverPart, assistantTurnText, attachSessionSurface, chordId, collectPendingApprovals, compressionThresholdTokens, conformsToWire, contentToText, diagnosticToLine, extractAllMentions, extractMentions, extractSessionMentions, filePartSummary, flattenCatalog, formatMoney, getProviderInfo, hasFailure, imagePartOmittedSummary, isAppearanceLang, isAppearanceTheme, isApprovalOutcome, isContextNearlyFull, isCurrency, isHeadlessInputFormat, isHeadlessLifecycleEvent, isHeadlessOutputFormat, isKeyAction, isLang, isMentionableFilePath, isOperationType, isPermissionLevel, isPlanOutcome, isPromptOversize, isProviderType, isQuestionAnswerMap, isSearchProviderType, isSettingsPaneId, isValidAgentRoleName, isValidCommandName, isWireGoalPhase, isWireHubEvent, isWirePlanAction, isWirePluginArchiveName, isWireRewindScope, isWireSettingWriteLayer, isWireSkillDropName, joinUploadMulti, makeTranslate, mcpConnectorState, normalizeApproval, packSessionSurface, parseChord, parseModelRef, parseSequence, perAction, placeholdersOf, promptTokens, resolveHostText, sequenceId, sessionPartSummary, splitUploadMulti, stripSystemNote, systemNote, tableOf, totalUsageTokens, translatorFor, truncateToBudget, turnDigest, unfixedRules, utf8ByteLength, wireFields };
16686
+ export { ACTION_CONTEXTS, AGENT_ROLE_NAME_PATTERN, API_KEY_ENV_VARS, APPEARANCE_LANGS, APPEARANCE_THEMES, APPROVAL_OUTCOMES, type ActiveAgentRole, type AgentEvent, type AgentEventOf, type AgentEventType, type AgentRole, type AgentRoleScope, type AgentRoleSource, type AppearanceLang, type AppearanceTheme, type ApprovalAnswer, type ApprovalOutcome, type ApprovalReply, type ApprovalRequest, type ApprovalScope, type ArtifactKind, type AttributeValue, type Attributes, type BackgroundTaskInfo, type BackgroundTaskKind, type BackgroundTaskStatus, type BlankCard, type BlankGreeting, type BoundKey, type BudgetBreach, COMMAND_NAME_PATTERN, COMPLIANCE_ACTIONS, COMPLIANCE_CATEGORIES, CURRENCIES, type Catalogs, type ComplianceAction, type ComplianceCategory, type ContextBreakdown, type ContextSegment, type Currency, type CurrencyDisplay, type CustomCommandDef, type CustomCommandSource, DEFAULT_AGENT_ROLE, DEFAULT_LANG, type DecidedTrustLevel, type Diagnostic, DiagnosticSink, type DiagnosticStatus, type EpochConfig, type EpochContentPart, type EpochFilePart, type EpochHook, type EpochImagePart, type EpochMessage, type EpochMessageRole, type EpochPlugin, type EpochSessionPart, type EpochSkill, type EpochTextPart, type EpochTool, type EpochToolCall, type EpochToolResult, type EpochTurnFacts, type EpochUserContent, type ExpandedCommand, FOLLOW_SYSTEM, type FileOmitReason, type FinishReason, type FixableApproval, type FlatCatalog, type FormatMoneyOptions, GEN_AI, HEADLESS_INPUT_EVENT_TYPES, HEADLESS_INPUT_FORMATS, HEADLESS_OUTPUT_FORMATS, HEADLESS_PROTOCOL_VERSION, type HeadlessEnvelope, type HeadlessEvent, type HeadlessInit, type HeadlessInputEvent, type HeadlessInputEventType, type HeadlessInputFormat, type HeadlessLifecycleEvent, type HeadlessOutputFormat, type HeadlessResult, type HeadlessResultReason, type HookContext, type HookEvent, type HookHandler, type HookManager, type HookRegistration, type HookType, type HostText, type HostUser, type JsonSchema, KEY_ACTIONS, type KeyAction, type KeyChord, type KeyContext, type KeySequence, type KeybindingReport, type KeybindingSource, type KeybindingTable, LANGS, type Lang, type LocalizedDetail, type LogFn, MAX_ATTACH_BYTES, MAX_ATTACH_FILES, MAX_ATTACH_TOTAL_BYTES, MAX_HEADER_CHARS, MAX_OPTIONS, MAX_QUESTIONS, MAX_SESSION_ATTACH_BYTES, MAX_SESSION_REFS, MCP_DATA_KEY_NAME, METRIC, MIN_OPTIONS, type MentionSet, type ModelRef, type ModelSelection, type ModelSelectionOrigin, type MoneyDigits, NOOP_TELEMETRY, type NoticeCode, OPERATION_TYPES, OVERSIZE_RATIO, type Operation, type OperationType, PERMISSION_LEVELS, PLAN_OUTCOMES, PLUGIN_CATEGORY_DISPLAY_SEP, PLUGIN_MENU_MESSAGE_TYPE, PLUGIN_UPLOAD_MULTI_SEP, PROVIDER_INFOS, PROVIDER_TYPES, type PermissionDecision, type PermissionLevel, type PermissionManager, type PermissionRuleLists, type PlanApprovalOutcome, type PlanProposal, type PluginContext, type PluginMenuMessage, type ProviderInfo, type ProviderType, type QuestionAnswer, type QuestionItem, type QuestionOption, type QuestionPage, type QuestionRequest, RESERVED_CHORDS, RESERVED_COMMAND_NAMES, type RejectReason, type RejectedKey, type RuleValue, SCHEDULE_DRAFT_TOOL, SCHEDULE_INTERVAL_MINUTES, SCHEDULE_RUN_STATUSES, SCHEDULE_TEMPLATES, SEARCH_API_KEY_ENV, SEARCH_PROVIDER_TYPES, SECRET_SERVICE, SEQUENCE_CONTEXTS, SESSION_MENTION_PREFIX, SESSION_REFERENCE_ERROR_CODES, SETTINGS_PANE_IDS, SHELL_KINDS, SIDEBAR_MENU_MESSAGE_TYPE, SIMULTANEOUS_CONTEXTS, SYSTEM_NOTE_PREFIX, type ScheduleAllowlist, type ScheduleBackendKind, type ScheduleCycle, type ScheduleDefinition, type ScheduleDraft, type ScheduleDraftAllowlist, type ScheduleDraftCreate, type ScheduleDraftPermission, type ScheduleDraftUpdate, type SchedulePendingApproval, type SchedulePendingItem, type ScheduleRun, type ScheduleRunStatus, type ScheduleRunnerSpec, type ScheduleTemplate, type ScheduleTemplateId, type ScheduleTrigger, type ScheduleTriggerKind, type ScheduleWeekday, type ScheduleWideningKind, type SearchProviderType, type SecretBackendId, type SecretStore, type SelectionContext, type SelectionRejection, type SelectionWarning, type SessionAttachKind, type SessionAttachResult, type SessionOmitReason, type SessionSurfaceMessage, type SessionSurfaceView, type SetSelectionResult, type SettingsPaneId, type SettingsPaneItem, type ShellKind, type SidebarMenuItem, type SidebarMenuMessage, type SpanLike, type SubToolCall, type SubToolCallResult, type Telemetry, type TokenUsage, type ToolAnnotations, type ToolArtifact, type ToolArtifactInput, type ToolContext, type ToolDefinition, ToolExposure, type ToolProvider, type ToolResult, type Translate, type TranslateVars, type TrustExecGrant, type TrustGrant, type TrustLevel, type TrustManager, type TrustRecord, type TrustScope, type TrustTier, UNLIMITED_TURNS, type VerifyResult, WIRE_ABORT_FIELDS, WIRE_ABOUT_FIELDS, WIRE_AGENT_ROLE_FIELDS, WIRE_APPEARANCE_RESPONSE_FIELDS, WIRE_APPROVAL_CACHE_REVOKE_REQUEST_FIELDS, WIRE_APPROVAL_CACHE_REVOKE_RESPONSE_FIELDS, WIRE_APPROVAL_LIST_FIELDS, WIRE_APPROVAL_ROW_FIELDS, WIRE_ARTIFACTS_FIELDS, WIRE_ATTACHMENT_UPLOAD_FIELDS, WIRE_AUDIT_LOG_FIELDS, WIRE_AUDIT_ROW_FIELDS, WIRE_AUTH_COOKIE, WIRE_AUTH_COOKIE_ATTRS, WIRE_AUTH_TOKEN_PARAM, WIRE_BACKGROUND_TASK_FIELDS, WIRE_BLOCKED_GOALS_FIELDS, WIRE_BLOCKED_GOAL_FIELDS, WIRE_BLOCKED_LEVEL_FIELDS, WIRE_BUILTIN_CONNECTOR_FIELDS, WIRE_CACHED_APPROVAL_FIELDS, WIRE_CAPABILITIES_FIELDS, WIRE_CAPABILITY_PROJECT_FIELDS, WIRE_CHECKPOINT_LIST_FIELDS, WIRE_CHECKPOINT_SUMMARY_FIELDS, WIRE_COMMANDS_FIELDS, WIRE_COMMAND_EXPANSION_FIELDS, WIRE_COMPACT_FIELDS, WIRE_COMPRESSION_LINE_FIELDS, WIRE_CONFIG_FIELDS, WIRE_CONTEXT_FIELDS, WIRE_CREATE_SESSION_FIELDS, WIRE_CREATE_WORKSPACE_FIELDS, WIRE_CREATE_WORKSPACE_RESPONSE_FIELDS, WIRE_CUSTOM_COMMAND_FIELDS, WIRE_DELETE_SESSION_FIELDS, WIRE_DIFF_FILE_FIELDS, WIRE_ERROR_FIELDS, WIRE_FILE_CANDIDATES_FIELDS, WIRE_FILE_CANDIDATE_FIELDS, WIRE_FILE_CHANGE_FIELDS, WIRE_FILE_OPEN_RESPONSE_FIELDS, WIRE_FILE_REFERENCE_FIELDS, WIRE_FILE_STAT_MAX, WIRE_FILE_STAT_OK_FIELDS, WIRE_FILE_STAT_REFUSED_FIELDS, WIRE_FILE_STAT_RESPONSE_FIELDS, WIRE_FILE_TEXT_RESPONSE_FIELDS, WIRE_FORGET_WORKSPACE_FIELDS, WIRE_FORGET_WORKSPACE_RESPONSE_FIELDS, WIRE_GOAL_ACTIONS, WIRE_GOAL_BLOCK_FIELDS, WIRE_GOAL_CLEAR_FIELDS, WIRE_GOAL_CREATE_FIELDS, WIRE_GOAL_FIELDS, WIRE_GOAL_LIMITS_FIELDS, WIRE_GOAL_PHASES, WIRE_GOAL_REFUSALS, WIRE_GOAL_RESPONSE_FIELDS, WIRE_GOAL_WRITE_FIELDS, WIRE_HEALTH_FIELDS, WIRE_IMAGE_REFERENCE_FIELDS, WIRE_KNOWN_WORKSPACE_FIELDS, WIRE_LANG_PARAM, WIRE_LAST_SESSION_FIELDS, WIRE_LAST_SESSION_RESPONSE_FIELDS, WIRE_MANAGED_LOCK_FIELDS, WIRE_MCP_ADD_FIELDS, WIRE_MCP_ADD_RESPONSE_FIELDS, WIRE_MCP_APPLY_ENTRY_FIELDS, WIRE_MCP_APPLY_RESPONSE_FIELDS, WIRE_MCP_CONFIG_APPLY_FIELDS, WIRE_MCP_CONFIG_FIELDS, WIRE_MCP_CONFIG_ISSUE_FIELDS, WIRE_MCP_CONFIG_SAVE_FIELDS, WIRE_MCP_CONFIG_SAVE_RESPONSE_FIELDS, WIRE_MCP_CONNECTOR_FIELDS, WIRE_MCP_RECONNECT_FIELDS, WIRE_MESSAGE_LIST_FIELDS, WIRE_MODEL_FIELDS, WIRE_MODEL_SELECTION_FIELDS, WIRE_MODEL_SET_FIELDS, WIRE_MODEL_SUGGESTIONS_FIELDS, WIRE_PATCH_SESSION_FIELDS, WIRE_PATCH_SESSION_RESPONSE_FIELDS, WIRE_PERMISSION_RULE_FIELDS, WIRE_PERMISSION_SET_REQUEST_FIELDS, WIRE_PERMISSION_SET_RESPONSE_FIELDS, WIRE_PERMISSION_SHADOW_FIELDS, WIRE_PERMISSION_STATE_FIELDS, WIRE_PERMISSION_STATUS_FIELDS, WIRE_PLAN_ACTIONS, WIRE_PLAN_FIELDS, WIRE_PLAN_MODE_REQUEST_FIELDS, WIRE_PLAN_MODE_RESPONSE_FIELDS, WIRE_PLAN_MODE_STATE_FIELDS, WIRE_PLUGINS_FIELDS, WIRE_PLUGIN_ACTION_FIELDS, WIRE_PLUGIN_ARCHIVE_SUFFIXES, WIRE_PLUGIN_INSTALL_FIELDS, WIRE_PLUGIN_LOCAL_FIELDS, WIRE_PLUGIN_LOCAL_INSTALL_FIELDS, WIRE_PLUGIN_MARKETPLACE_FIELDS, WIRE_PLUGIN_MARKETPLACE_RESPONSE_FIELDS, WIRE_PLUGIN_NAME_FIELDS, WIRE_PLUGIN_PREVIEW_FIELDS, WIRE_PLUGIN_PREVIEW_RESPONSE_FIELDS, WIRE_PLUGIN_REFRESH_RESPONSE_FIELDS, WIRE_PLUGIN_STAGE_FIELDS, WIRE_PLUGIN_STAGE_RESPONSE_FIELDS, WIRE_PLUGIN_UPDATE_FIELDS, WIRE_PLUGIN_UPLOAD_CONFIRM_FIELDS, WIRE_PLUGIN_UPLOAD_FIELDS, WIRE_PLUGIN_UPLOAD_FORM_FIELDS, WIRE_PLUGIN_UPLOAD_PREVIEW_RESPONSE_FIELDS, WIRE_PLUGIN_UPLOAD_RESPONSE_FIELDS, WIRE_POLICY_DIR_FIELDS, WIRE_POLICY_STATUS_FIELDS, WIRE_PROJECT_INVENTORY_FIELDS, WIRE_PROVIDERS_FIELDS, WIRE_PROVIDER_KEY_FIELDS, WIRE_PROVIDER_MODELS_FIELDS, WIRE_PROVIDER_OPTION_FIELDS, WIRE_QUESTION_LIST_FIELDS, WIRE_QUESTION_ROW_FIELDS, WIRE_RESPOND_APPROVAL_FIELDS, WIRE_RESPOND_APPROVAL_RESPONSE_FIELDS, WIRE_RESPOND_QUESTION_FIELDS, WIRE_RESPOND_QUESTION_RESPONSE_FIELDS, WIRE_REWIND_FILE_PLAN_FIELDS, WIRE_REWIND_OUTCOME_FIELDS, WIRE_REWIND_PREVIEW_FIELDS, WIRE_REWIND_REQUEST_FIELDS, WIRE_REWIND_RESPONSE_FIELDS, WIRE_REWIND_SCOPES, WIRE_ROLES_FIELDS, WIRE_ROLE_ADD_FIELDS, WIRE_ROLE_ADD_RESPONSE_FIELDS, WIRE_ROLE_REMOVE_FIELDS, WIRE_RUNNING_SCHEDULE_FIELDS, WIRE_SANDBOX_STATUS_FIELDS, WIRE_SCHEDULE_CAPABILITY_FIELDS, WIRE_SCHEDULE_CREATE_FIELDS, WIRE_SCHEDULE_DEFAULTS_FIELDS, WIRE_SCHEDULE_DELETE_FIELDS, WIRE_SCHEDULE_FIELDS, WIRE_SCHEDULE_FIX_FIELDS, WIRE_SCHEDULE_FIX_REQUEST_FIELDS, WIRE_SCHEDULE_ISSUE_CODES, WIRE_SCHEDULE_LIST_FIELDS, WIRE_SCHEDULE_PENDING_FIELDS, WIRE_SCHEDULE_RECORDING_FIELDS, WIRE_SCHEDULE_ROW_FIELDS, WIRE_SCHEDULE_RUNNING_FIELDS, WIRE_SCHEDULE_RUNS_FIELDS, WIRE_SCHEDULE_RUN_FIELDS, WIRE_SCHEDULE_SAVE_FIELDS, WIRE_SECURITY_FIELDS, WIRE_SECURITY_WORKSPACE_FIELDS, WIRE_SEND_MESSAGE_FIELDS, WIRE_SEND_MESSAGE_RESPONSE_FIELDS, WIRE_SESSION_CANDIDATES_FIELDS, WIRE_SESSION_CANDIDATE_FIELDS, WIRE_SESSION_FINISH_FIELDS, WIRE_SESSION_LIST_FIELDS, WIRE_SESSION_REFERENCE_FIELDS, WIRE_SESSION_RESPONSE_FIELDS, WIRE_SESSION_SUMMARY_FIELDS, WIRE_SESSION_WORKSPACE_FIELDS, WIRE_SESSION_WORKSPACE_RESPONSE_FIELDS, WIRE_SETTINGS_FIELDS, WIRE_SETTINGS_WRITE_FIELDS, WIRE_SETTINGS_WRITE_REQUEST_FIELDS, WIRE_SETTING_PENDING_FIELDS, WIRE_SETTING_ROW_FIELDS, WIRE_SETTING_STEP_FIELDS, WIRE_SETTING_WRITE_FIELDS, WIRE_SETTING_WRITE_LAYERS, WIRE_SKILL_BODY_FIELDS, WIRE_SKILL_DROP_SUFFIXES, WIRE_SKILL_FIELDS, WIRE_SKILL_IMPORT_FIELDS, WIRE_SKILL_IMPORT_PREVIEW_FIELDS, WIRE_SKILL_REMOVE_FIELDS, WIRE_SKILL_STAGE_FIELDS, WIRE_TASKS_FIELDS, WIRE_TOOLS_FIELDS, WIRE_TOOL_GATE_FIELDS, WIRE_TOOL_ROW_FIELDS, WIRE_TRUST_REQUEST_FIELDS, WIRE_TRUST_REQUEST_RESPONSE_FIELDS, WIRE_WORKSPACE_DIFF_FIELDS, WIRE_WORKSPACE_DIRS_FIELDS, WIRE_WORKSPACE_DIR_ENTRY_FIELDS, WIRE_WORKSPACE_REF_FIELDS, type WireAbortResponse, type WireAbout, type WireAgentEnvelope, type WireAgentEvent, type WireAgentRoleSummary, type WireAppearanceRequest, type WireAppearanceResponse, type WireApprovalCacheRevokeRequest, type WireApprovalCacheRevokeResponse, type WireApprovalListResponse, type WireApprovalRequest, type WireArtifactsResponse, type WireAttachmentUploadResponse, type WireAuditCode, type WireAuditLog, type WireAuditOutcome, type WireAuditRow, type WireAuthDenyReason, type WireAuthDenyStatus, type WireAuthGuard, type WireAuthRequestView, type WireAuthVerdict, type WireBackgroundTask, type WireBindWorkspaceRequest, type WireBlockedGoal, type WireBlockedGoalsResponse, type WireBlockedLevel, type WireBuiltinConnector, type WireCachedApproval, type WireCachedDecision, type WireCapabilitiesResponse, type WireCapabilityProject, type WireCheckpointListResponse, type WireCheckpointSummary, type WireCommandExpansion, type WireCommandsResponse, type WireCompactRequest, type WireCompactResponse, type WireCompressionLine, type WireConfigResponse, type WireContextResponse, type WireCreateSessionRequest, type WireCreateSessionResponse, type WireCreateWorkspaceRequest, type WireCreateWorkspaceResponse, type WireCustomCommand, type WireDeleteSessionResponse, type WireDiffFile, type WireDiffNote, type WireDiffOmitReason, type WireDiffSource, type WireDiffStatus, type WireEnvelope, type WireErrorResponse, type WireEvent, type WireFields, type WireFileCandidate, type WireFileCandidatesResponse, type WireFileChange, type WireFileKind, type WireFileOpenRefusal, type WireFileOpenResponse, type WireFileReference, type WireFileRefusal, type WireFileStat, type WireFileStatOk, type WireFileStatRefused, type WireFileStatResponse, type WireFileTextResponse, type WireFixture, type WireFixtureCase, type WireForgetWorkspaceRequest, type WireForgetWorkspaceResponse, type WireGoal, type WireGoalBlock, type WireGoalClearResponse, type WireGoalCreateRequest, type WireGoalLimits, type WireGoalPhase, type WireGoalRefusal, type WireGoalResponse, type WireGoalUpdateRequest, type WireGoalWriteResponse, type WireHealthResponse, type WireHostCompose, type WireHostComposeRequest, type WireHostComposeResponse, type WireHostComposeStateResponse, type WireHostComposeTakeResponse, type WireHubEnvelope, type WireHubEvent, type WireImageReference, type WireKnownWorkspace, type WireKnownWorkspaceRef, type WireLastSessionRequest, type WireLastSessionResponse, type WireManagedLock, type WireMcpAddRequest, type WireMcpAddResponse, type WireMcpApplyAction, type WireMcpApplyEntry, type WireMcpApplyResponse, type WireMcpConfigApplyRequest, type WireMcpConfigIssue, type WireMcpConfigResponse, type WireMcpConfigSaveRequest, type WireMcpConfigSaveResponse, type WireMcpConnector, type WireMcpReconnectResponse, type WireMessageListResponse, type WireModelCaveat, type WireModelProbeStatus, type WireModelRejection, type WireModelResponse, type WireModelSelection, type WireModelSetRequest, type WireModelSetResponse, type WireModelSource, type WireModelSuggestions, type WirePatchSessionRequest, type WirePatchSessionResponse, type WirePermissionRememberFailure, type WirePermissionRuleRow, type WirePermissionSetRequest, type WirePermissionSetResponse, type WirePermissionShadow, type WirePermissionState, type WirePermissionStatus, type WirePickDirectoryResponse, type WirePlanAction, type WirePlanModeRequest, type WirePlanModeResponse, type WirePlanModeState, type WirePlanResponse, type WirePluginActionResponse, type WirePluginCategory, type WirePluginCounts, type WirePluginDependency, type WirePluginDependencyInventory, type WirePluginDependencyStatus, type WirePluginEntry, type WirePluginHit, type WirePluginHookTally, type WirePluginInstallRequest, type WirePluginLocalInstallRequest, type WirePluginLocalRequest, type WirePluginMarketplace, type WirePluginMarketplaceRequest, type WirePluginMarketplaceResponse, type WirePluginMenuItem, type WirePluginNameRequest, type WirePluginPreview, type WirePluginPreviewRequest, type WirePluginPreviewResponse, type WirePluginRefreshResponse, type WirePluginRefuseReason, type WirePluginSourceType, type WirePluginStageRequest, type WirePluginStageResponse, type WirePluginStatus, type WirePluginUpdateRequest, type WirePluginUploadChoice, type WirePluginUploadConfirmRequest, type WirePluginUploadField, type WirePluginUploadFieldName, type WirePluginUploadFields, type WirePluginUploadFile, type WirePluginUploadForm, type WirePluginUploadPlan, type WirePluginUploadPreviewResponse, type WirePluginUploadRequest, type WirePluginUploadResponse, type WirePluginVersionUnmet, type WirePluginVisibility, type WirePluginsResponse, type WirePolicyDir, type WirePolicyStatus, type WireProjectInventory, type WireProviderKeyRequest, type WireProviderKeyResponse, type WireProviderModelsRequest, type WireProviderModelsResponse, type WireProviderOption, type WireProviderSummary, type WireProvidersResponse, type WireQuestionListResponse, type WireQuestionRequest, type WireReplayMessage, type WireResetReason, type WireRespondApprovalRequest, type WireRespondApprovalResponse, type WireRespondQuestionRequest, type WireRespondQuestionResponse, type WireRewindAction, type WireRewindDrift, type WireRewindFilePlan, type WireRewindOutcome, type WireRewindPreview, type WireRewindRequest, type WireRewindResponse, type WireRewindScope, type WireRoleAddRequest, type WireRoleAddResponse, type WireRoleRemoveFailure, type WireRoleRemoveResponse, type WireRolesResponse, type WireRunningSchedule, type WireSandboxReason, type WireSandboxStatus, type WireScheduleCapability, type WireScheduleCreateRequest, type WireScheduleDefaults, type WireScheduleDeleteResponse, type WireScheduleFixRequest, type WireScheduleFixResponse, type WireScheduleIssue, type WireScheduleIssueCode, type WireScheduleListResponse, type WireSchedulePendingResponse, type WireScheduleRecordingResponse, type WireScheduleRegisterRefusal, type WireScheduleRegisterWarning, type WireScheduleRegistration, type WireScheduleResponse, type WireScheduleRow, type WireScheduleRunResponse, type WireScheduleRunningResponse, type WireScheduleRunsResponse, type WireScheduleSaveResponse, type WireScheduleUpdateRequest, type WireSecurityResponse, type WireSecurityWorkspace, type WireSendMessageRequest, type WireSendMessageResponse, type WireSessionCandidate, type WireSessionCandidatesResponse, type WireSessionFinish, type WireSessionListResponse, type WireSessionReference, type WireSessionResponse, type WireSessionSummary, type WireSessionWorkspace, type WireSessionWorkspaceResponse, type WireSettingApply, type WireSettingFutile, type WireSettingLayer, type WireSettingPending, type WireSettingRow, type WireSettingStep, type WireSettingValue, type WireSettingValueKind, type WireSettingWrite, type WireSettingWriteLayer, type WireSettingsResponse, type WireSettingsWriteRequest, type WireSettingsWriteResponse, type WireSkillBodyResponse, type WireSkillImportConflict, type WireSkillImportEntry, type WireSkillImportFailure, type WireSkillImportForm, type WireSkillImportIssue, type WireSkillImportPreviewResponse, type WireSkillImportResponse, type WireSkillRemoveFailure, type WireSkillRemoveResponse, type WireSkillStageFailure, type WireSkillStageResponse, type WireSkillSummary, type WireSummaryWorkspace, type WireTaggedEvent, type WireTasksResponse, type WireToolGate, type WireToolGateAxis, type WireToolRow, type WireToolSummary, type WireToolVerdict, type WireToolsResponse, type WireTrustRequestRequest, type WireTrustRequestResponse, type WireTurnState, type WireWorkspaceBinding, type WireWorkspaceDiffResponse, type WireWorkspaceDirEntry, type WireWorkspaceDirsResponse, type WireWorkspaceRef, apiKeyEnvVar, assertNeverPart, assistantTurnText, attachSessionSurface, chordId, collectPendingApprovals, compressionThresholdTokens, conformsToWire, contentToText, diagnosticToLine, extractAllMentions, extractMentions, extractSessionMentions, filePartSummary, flattenCatalog, formatMoney, getProviderInfo, hasFailure, imagePartOmittedSummary, isAppearanceLang, isAppearanceTheme, isApprovalOutcome, isContextNearlyFull, isCurrency, isHeadlessInputFormat, isHeadlessLifecycleEvent, isHeadlessOutputFormat, isKeyAction, isLang, isMentionableFilePath, isOperationType, isPermissionLevel, isPlanOutcome, isPromptOversize, isProviderType, isQuestionAnswerMap, isSearchProviderType, isSettingsPaneId, isValidAgentRoleName, isValidCommandName, isWireGoalPhase, isWireHubEvent, isWirePlanAction, isWirePluginArchiveName, isWireRewindScope, isWireSettingWriteLayer, isWireSkillDropName, joinUploadMulti, makeTranslate, mcpConnectorState, normalizeApproval, packSessionSurface, parseChord, parseModelRef, parseSequence, perAction, placeholdersOf, promptTokens, resolveHostText, sequenceId, sessionPartSummary, splitUploadMulti, stripSystemNote, systemNote, tableOf, totalUsageTokens, translatorFor, truncateToBudget, turnDigest, unfixedRules, utf8ByteLength, wireFields };
package/dist/index.js CHANGED
@@ -265,6 +265,15 @@ var PROVIDER_INFOS = [
265
265
  apiKeyEnv: "MOONSHOT_API_KEY",
266
266
  interactive: true
267
267
  },
268
+ { type: "zhipu", label: "Zhipu GLM", apiKeyEnv: "ZHIPUAI_API_KEY", interactive: true },
269
+ {
270
+ type: "dashscope",
271
+ label: "Alibaba DashScope",
272
+ apiKeyEnv: "DASHSCOPE_API_KEY",
273
+ interactive: true
274
+ },
275
+ { type: "bytedance", label: "Volcengine Ark", apiKeyEnv: "ARK_API_KEY", interactive: true },
276
+ { type: "qianfan", label: "Baidu Qianfan", apiKeyEnv: "QIANFAN_API_KEY", interactive: true },
268
277
  { type: "cohere", label: "Cohere", apiKeyEnv: "COHERE_API_KEY", interactive: true },
269
278
  { type: "xai", label: "xAI / Grok", apiKeyEnv: "XAI_API_KEY", interactive: true },
270
279
  { type: "perplexity", label: "Perplexity", apiKeyEnv: "PERPLEXITY_API_KEY", interactive: true },
@@ -1180,6 +1189,7 @@ var WIRE_COMPACT_FIELDS = wireFields()({
1180
1189
  // src/wire-capability.ts
1181
1190
  var WIRE_AGENT_ROLE_FIELDS = wireFields()({
1182
1191
  name: true,
1192
+ displayName: true,
1183
1193
  description: true,
1184
1194
  source: true,
1185
1195
  tools: true,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@epoch-agent/protocol",
3
- "version": "0.21.0",
3
+ "version": "0.23.0",
4
4
  "private": false,
5
5
  "description": "epoch-agent 契约层:工具 / 事件 / 权限 / 插件的类型定义,零运行时依赖",
6
6
  "repository": {