@epoch-agent/protocol 2.0.1 → 2.2.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
@@ -1825,7 +1825,19 @@ interface ModelEntryCapabilities {
1825
1825
  images?: boolean;
1826
1826
  /** 思考模式。不开的话强度那一组整个不出现 */
1827
1827
  reasoning?: boolean;
1828
- /** 仅思考模式:关不掉思考(界面上不给「关」那一档) */
1828
+ /**
1829
+ * 仅思考模式:关不掉思考。
1830
+ *
1831
+ * ⚠️ **2026-10-19 起是个只读兼容字段,界面不再产生它。** 它全仓唯一的消费方是
1832
+ * core `router.getEffort()` 的 `canTurnOff = reasoningToggle && !reasoningOnly` ——
1833
+ * 也就是只能把「允许关闭」减掉;而设置页在勾上它的同时就把「允许关闭思考」那一格
1834
+ * 藏了,两者永远不可能同时为真,于是它勾与不勾结果逐字相同。
1835
+ *
1836
+ * 保留是为了读旧 `models.json`(手写过这个字段的那几条照旧按它算),新写的条目
1837
+ * 不应再带它;下次在设置页保存那一条时它会自然消失。
1838
+ *
1839
+ * @deprecated 写它没有任何效果,见上
1840
+ */
1829
1841
  reasoningOnly?: boolean;
1830
1842
  /** 允许关闭思考:滑块上多一个「关」 */
1831
1843
  reasoningToggle?: boolean;
@@ -2194,7 +2206,7 @@ interface SettingsPaneItem {
2194
2206
  }
2195
2207
 
2196
2208
  /**
2197
- * 宿主自定义的那几格侧栏菜单(2026-09-02;2026-10-16 起「用户」那一格整个交出去了)。
2209
+ * 宿主自定义的那几格菜单(2026-09-02;2026-10-16 起「用户」那一格整个交出去了)。
2198
2210
  *
2199
2211
  * 这个文件里的 {@link SidebarMenuItem} 是**几个宿主配置键共用的那一个 item 形状**:
2200
2212
  *
@@ -2202,6 +2214,7 @@ interface SettingsPaneItem {
2202
2214
  * | -- | ------ | ------ |
2203
2215
  * | `EpochConfig.sidebarMenu` | 侧栏最底下那一格里「用户」**右边**那枚分体按钮(一项露在外面,其余在「⋯」里) | 那枚按钮整个没有,「用户」照旧一整行 |
2204
2216
  * | `EpochConfig.sidebarHeadMenu`(2026-10-15) | 侧栏头「收起侧栏」左边那几枚图标;收起后探出来那张卡里是几行菜单 | 侧栏头一枚都不多 |
2217
+ * | `EpochConfig.topbarMenu`(2026-10-19) | 顶栏最右端那一枚图标按钮(第一项露在外面,其余收在它右边那枚「⋯」展开的菜单里) | 顶栏右边一枚都不多 |
2205
2218
  *
2206
2219
  * 同一条消息还有一个发送方不是菜单项:`EpochConfig.brandMenuId`(2026-10-15)配了时,
2207
2220
  * 点侧栏头那一格品牌发 `{ type, id: brandMenuId }`。
@@ -2213,11 +2226,11 @@ interface SettingsPaneItem {
2213
2226
  * 里只剩内置的「设置」一项。两条消息(出站那条和入站的 {@link OpenSettingsMessage})
2214
2227
  * 在这个文件的末尾。
2215
2228
  *
2216
- * ⚠️ **剩下的两个键互不兜底**,这是 2026-09-07 拆开那一笔留下的规矩(老板原话:
2217
- * 「不行,需要是两个配置」):只配一个的宿主在**另一面一项都没有**;谁都不去拿另一个
2229
+ * ⚠️ **剩下的三个键互不兜底**,这是 2026-09-07 拆开那一笔留下的规矩(老板原话:
2230
+ * 「不行,需要是两个配置」):只配一个的宿主在**别的面一项都没有**;谁都不去拿另一个
2218
2231
  * 顶上 —— 那种兜底的表现是宿主配了一个键却在**两处**都看见东西,而它想改掉多出来的
2219
2232
  * 那一处时会发现没有对应的键可关。判据在 web 的 `shell/sidebar.tsx` 上
2220
- * (几个常量各判一次「键在且非空数组」)。
2233
+ * (几个常量各判一次「键在且非空数组」;`topbarMenu` 那一次在 `shell/topbar.tsx`)。
2221
2234
  *
2222
2235
  * ⚠️ **类型名照旧是 `SidebarMenuItem`,没有跟着拆**。它是**同一个形状**
2223
2236
  * (`id` / `label` / `icon` 三个字段,一个字都不差),为「这一份是给哪个键的」造第二个
@@ -2236,10 +2249,10 @@ interface SettingsPaneItem {
2236
2249
  * ## 点下去发生什么:往父窗口发一条 `postMessage`,**不跳页**
2237
2250
  *
2238
2251
  * ⚠️ **几个键共用这一条消息,而且不带「来源」** —— 点侧栏底部那几项、侧栏头那几枚、
2239
- * 品牌那一格发出去的东西**逐字节一样**(`{ type, id }`)。刻意的:宿主已经拿 `id`
2252
+ * 顶栏那一枚、品牌那一格发出去的东西**逐字节一样**(`{ type, id }`)。刻意的:宿主已经拿 `id`
2240
2253
  * 认出了是哪一项,而那个 `id` 出自它自己那份配置 —— 它当然知道自己把那一项配在了
2241
- * 哪个键上。多带一个 `from: 'sidebar' | 'menu'` 的代价是**宿主那句监听得跟着改**,
2242
- * 换来的是一个它本来就答得出的答案。
2254
+ * 哪个键上。多带一个 `from: 'sidebar' | 'head' | 'topbar' | 'brand'` 的代价是
2255
+ * **宿主那句监听得跟着改**,换来的是一个它本来就答得出的答案。
2243
2256
  *
2244
2257
  * 这是这一格和 `brand` 唯一的形状差别 —— 品牌是一个字符串,菜单是一个**动作**,
2245
2258
  * 而动作要有个落点。三条路里选了这一条:
@@ -2284,9 +2297,9 @@ interface SettingsPaneItem {
2284
2297
  * (「用户菜单归宿主」)是这一条的上下文。
2285
2298
  */
2286
2299
  /**
2287
- * 侧栏菜单里的一项。**`sidebarMenu` 和 `sidebarHeadMenu` 两个键共用这一个形状**
2288
- * (见文件头第一节那张表)—— 名字里的 `Sidebar` 是它 2026-09-02 出生时的位置,
2289
- * 不是「只给 `sidebarMenu` 用」的意思。
2300
+ * 菜单里的一项。**`sidebarMenu` / `sidebarHeadMenu` / `topbarMenu` 三个键共用这一个
2301
+ * 形状**(见文件头第一节那张表)—— 名字里的 `Sidebar` 是它 2026-09-02 出生时的位置,
2302
+ * 不是「只给 `sidebarMenu` 用」的意思(2026-10-19 顶栏那个键也吃它)。
2290
2303
  *
2291
2304
  * ⚠️ 三个字段都是**宿主的话**,一个都不过 i18n catalog —— 同侧栏底下那几条启动
2292
2305
  * 诊断的 `detail`:它们的内容随宿主而变,没有有限的码可以枚举。用户把界面切成
@@ -2296,11 +2309,11 @@ interface SidebarMenuItem {
2296
2309
  /**
2297
2310
  * 宿主自己认的那个码 —— 点下去原样回给它({@link SidebarMenuMessage.id})。
2298
2311
  *
2299
- * ⚠️ **一个键里不许重复**(core 的 schema 拦这一条,两个键各拦自己那一份):
2312
+ * ⚠️ **一个键里不许重复**(core 的 schema 拦这一条,三个键各拦自己那一份):
2300
2313
  * 重了的话宿主收到消息也分不出用户按的是哪一行,而屏幕上那两行长得完全不一样。
2301
2314
  *
2302
2315
  * ⚠️ **跨键重复反过来不拦,而且它是一句说得通的话**:同一个 `id` 同时配进
2303
- * `sidebarMenu` 和 `sidebarHeadMenu`,意思是「这个去处两处都摆一份」—— 那时两处
2316
+ * `sidebarMenu` / `sidebarHeadMenu` / `topbarMenu`,意思是「这个去处几处都摆一份」—— 那时几处
2304
2317
  * 点下去发的是同一条消息,宿主那侧本来就该做同一件事(判据在文件头「几个键共用
2305
2318
  * 这一条消息」那一段)。要拦的话得让 schema 跨字段看,而它拦掉的是一个正当写法。
2306
2319
  *
@@ -3214,6 +3227,33 @@ interface EpochConfig {
3214
3227
  * 判据在 [wire-host-badges.ts](./wire-host-badges.ts) 的文件头。
3215
3228
  */
3216
3229
  sidebarHeadMenu?: readonly SidebarMenuItem[];
3230
+ /**
3231
+ * 宿主自定义的**顶栏右上那一枚图标按钮**(2026-10-19)。**缺省 = 一枚都不多**,
3232
+ * 顶栏右边照旧空着。
3233
+ *
3234
+ * 画的位置:`.topbar` 最右端,和会话标题同一行(标题吃满剩下的宽度,装不下收
3235
+ * 省略号)。第一项是露在外面那一枚图标按钮,`label` 在 `aria-label` / `title` 上;
3236
+ * 配了多项时其余收进它右边那枚「⋯」展开的菜单(图标 + `label`)。
3237
+ *
3238
+ * ## ⚠️ 外面**恒为一枚**,不跟着宿主配了几项长
3239
+ *
3240
+ * 这一格和侧栏头那几枚({@link sidebarHeadMenu})刻意不同:那边可以横着排一列,
3241
+ * 这里不行。判据是顶栏的宽度预算 —— 360px 那一档量过(`web/src/styles/shell.css`
3242
+ * 的 `.topbar__facts` 那一段记着同族的实测):顶栏是一条 `nowrap` 的 flex 行,
3243
+ * `min-width: 0` 夹不小 min-content,装不下时**出屏幕的是最右边那一个**,
3244
+ * 而屏幕上一点异样都没有(按钮中心点跑到屏幕外,手指点不着)。
3245
+ * 所以这里用结构兜,而不是靠「宿主别配太多」:外面 1 枚 + 最多 1 枚「⋯」。
3246
+ * 顶栏这一键**不分「外面 / 里面」**(没有 `primary`),露出来的一定是第一项。
3247
+ *
3248
+ * 形状、口径逐字照 {@link sidebarHeadMenu}(同一个 {@link SidebarMenuItem}、同一条
3249
+ * `postMessage`、同一张图标白名单;空数组是配错了、`id` 不许重复、跨键重复不拦),
3250
+ * 和另外几个键**互不兜底** —— 只配这个键时侧栏那一面一项都不多,反过来也一样。
3251
+ *
3252
+ * 未读点同 {@link sidebarHeadMenu}:`POST /api/host/badges` 按 `id` 开关。
3253
+ * 露在外面那一枚画在图标右上角;收进「⋯」的那几项在菜单行行尾,而只要有任意
3254
+ * 一项亮着,「⋯」自己右上角也挂一颗(和侧栏收起时那枚开关同一个处置)。
3255
+ */
3256
+ topbarMenu?: readonly SidebarMenuItem[];
3217
3257
  /**
3218
3258
  * 宿主自定义的那几张开场卡片(2026-09-04)。**缺省 = 新会话空屏上一张都没有**,
3219
3259
  * 那一屏仍然只有一行招呼。
@@ -4608,6 +4648,12 @@ interface EpochMessage {
4608
4648
  * 4. **它只能递一个答案。** 真正的写操作仍然由模型调插件的工具去执行
4609
4649
  * (于是多一次审批框)。这是代价,也是它保住的那条线:
4610
4650
  * **模型是唯一发起工具调用的角色**。
4651
+ * 5. **不收 HTML 字符串**(2026-10-19 用户拍的,别再问「要不要加一格 `html`」)。
4652
+ * 看着像缺一格,其实是一个决定:这一格的 `url` 已经来自模型了,而「让模型在我们
4653
+ * 自己的界面里画一块可交互区域」是另一个量级的事 —— 那段内容能长得和宿主自己的
4654
+ * 控件一模一样,而用户点它的时候以为那是我们在问。要自定义界面,由插件在本机
4655
+ * 起一页:页的边界写在 `sandbox` 上(web 的 `iframe-sandbox.ts`),而且那一页
4656
+ * 有自己的 URL、用户和宿主都能说清「这块是谁画的」。
4611
4657
  */
4612
4658
  /** 一个选项。**没有「其他」** —— 自由输入由宿主自动提供,不占模型的选项额度 */
4613
4659
  interface QuestionOption {
@@ -8629,6 +8675,16 @@ interface WireConfigResponse {
8629
8675
  * 两个键互不兜底)。
8630
8676
  */
8631
8677
  sidebarHeadMenu?: readonly SidebarMenuItem[];
8678
+ /**
8679
+ * 宿主自定义的**顶栏右上那一枚图标按钮**(2026-10-19)—— `EpochConfig.topbarMenu`
8680
+ * 原样转发,没配就没有这个键。口径逐字同 {@link sidebarHeadMenu}(同一个 item 形状、
8681
+ * 同一条 `postMessage`、几个键互不兜底)。
8682
+ *
8683
+ * ⚠️ **画法和侧栏头那几枚不同,而那是网线这一侧不用管的事**:顶栏外面恒为
8684
+ * 第一项、其余收进一枚「⋯」(结构判据在 `EpochConfig.topbarMenu` 上)。
8685
+ * 这一层照旧把整份清单原样带下去 —— 自己画前端的宿主按自己的排版决定画几枚。
8686
+ */
8687
+ topbarMenu?: readonly SidebarMenuItem[];
8632
8688
  /**
8633
8689
  * 首屏那一刻**亮着点**的那几项(2026-10-15)—— **一个都没亮就没有这个键**。
8634
8690
  *
@@ -9590,6 +9646,39 @@ interface WireDeleteSessionResponse {
9590
9646
  checkpointsRemoved: boolean;
9591
9647
  }
9592
9648
  declare const WIRE_DELETE_SESSION_FIELDS: WireFields<WireDeleteSessionResponse>;
9649
+ /**
9650
+ * `POST /api/sessions/:id/revive` 的回执(2026-10-19)。
9651
+ *
9652
+ * 把一段**库里还在、这个进程手里没有**的会话接回 Hub(实现和判据在
9653
+ * `server/src/sessions/revive.ts`)。这条端点是给 web 打开会话那一刻用的:
9654
+ * 接回来之后 `GET .../model` / `.../permission` / `.../workspace` 和
9655
+ * `POST .../plan` 才答得出、点得动。
9656
+ *
9657
+ * ## `revived: false` 不是失败
9658
+ *
9659
+ * 它说的是「这段会话**本来就活着**」—— 这条端点幂等,打开一段已经在 Hub 里的
9660
+ * 会话是空操作。界面据此决定要不要重取那四格(本来活着的话,它们手里的答案
9661
+ * 就是对的,多问一遍只是噪音)。
9662
+ *
9663
+ * ## 接不回来不是 4xx 里的一句「没成」,而是三种各不相同的话
9664
+ *
9665
+ * 三种都沿用现成的码,这条端点不发明新的:
9666
+ *
9667
+ * | 服务端的结局 | 回什么 | 是什么意思 |
9668
+ * | --- | --- | --- |
9669
+ * | 没有落盘的工作区决定(v7 之前的老行 / 假 id) | 404 `unknown-session` | 这段会话说不出它在哪儿干过活,接不回来 |
9670
+ * | 被挤出 Hub、又接不回来 | 409 `session-cooled` | 它存在、只是此刻不在手里 |
9671
+ * | 目录没了 / 被锁着 / provider 没配 | 400 / 503(原话) | 接的过程真的失败了,那句话里带着出路 |
9672
+ *
9673
+ * ⚠️ **自动复活那一侧把这些失败全吞掉**:打开一段接不回来的旧会话,今天的形态
9674
+ * 本来就只是「三格只读」,用户没在做那件事,弹一条横幅是把「我没在问的事」
9675
+ * 推到他脸上(判据在 `web/src/state/store.tsx` 的 `revive` 上)。
9676
+ */
9677
+ interface WireReviveResponse {
9678
+ /** `true` = 这一次真的接回来了;`false` = 本来就活着,什么都没做 */
9679
+ revived: boolean;
9680
+ }
9681
+ declare const WIRE_REVIVE_FIELDS: WireFields<WireReviveResponse>;
9593
9682
  /**
9594
9683
  * 改一段会话的元信息。
9595
9684
  *
@@ -9930,6 +10019,37 @@ interface WireSendMessageRequest {
9930
10019
  * 不是字符串、空串、超过 128 个字符 = 当没给(这一条照常发,只是回执上不带编号)。
9931
10020
  */
9932
10021
  clientMessageId?: string;
10022
+ /**
10023
+ * 这一条是**在哪个插件面板开着的时候**发出去的(2026-10-20)。
10024
+ *
10025
+ * 只影响 system prompt 里**一句话**:`<self>` 段那条
10026
+ * 「用户点了插件「飞书文档」(feishu-kit),这一轮优先用它带来的东西…」
10027
+ * (渲染在 `core/src/agent/self-index.ts` 的 `renderSelfIndex`)。
10028
+ *
10029
+ * ## 为什么要单独一格,而不是让模型自己猜
10030
+ *
10031
+ * 模型那边唯一相关的钩子是一条**常驻约定**,它写的是「用户点了插件**名**」——
10032
+ * 也就是说模型被要求优先用某个插件的东西,却不知道用户点的是谁。而点开面板
10033
+ * 这件事**没有任何请求发出去**(那是 web 前端的一格 React state),所以不带上
10034
+ * 这一格,它永远只能等用户在话里自己敲那个名字。
10035
+ *
10036
+ * ## 缺席 = 这一刻没开任何插件面板
10037
+ *
10038
+ * **叉掉面板就等于不带这一格**,于是下一条消息的 prompt 里那条规则整个消失
10039
+ * —— 这正是用户要的语义(「叉掉就没有这个提示」)。它不是「会话级设置」:
10040
+ * 面板跟会话走、能随时开关,而这条网线答的是**这一条消息**当时的那个状态。
10041
+ *
10042
+ * ## ⚠️ 和上面 `role` 的分界:认不出来时**静默当没给**,不是 400
10043
+ *
10044
+ * `role` 认不出来必须 400,因为那会静默换掉工具表和身份行(用户以为 `explore`
10045
+ * 在答、实际 `build` 在改文件,而屏幕上看不出区别)。这一格认不出来只是
10046
+ * **少印一句话**:用户眼前的面板照样开着,模型的回答照样正确,只是不知道
10047
+ * 该优先用哪个插件。为一个提示付出「这条消息发不出去」的代价不成比例。
10048
+ *
10049
+ * 值域由服务端守(`server/src/api.ts` 拿插件表核对):只认**真装着的**插件名,
10050
+ * 别的一律当没给 —— prompt 里写一个不存在的插件名是假话,而模型会照着去找。
10051
+ */
10052
+ plugin?: string;
9933
10053
  }
9934
10054
  declare const WIRE_SEND_MESSAGE_FIELDS: WireFields<WireSendMessageRequest>;
9935
10055
  /**
@@ -10338,6 +10458,33 @@ interface WireWorkspaceDiffResponse {
10338
10458
  * 顶上去 —— 尤其是顶服务进程的 cwd —— 就是本轮要拆掉的那个谎。
10339
10459
  */
10340
10460
  root: string;
10461
+ /**
10462
+ * 当前所在的分支名(2026-10-20,`main`)。
10463
+ *
10464
+ * ## 为什么是 diff 响应里的字段,不是单独一条端点
10465
+ *
10466
+ * 它只在一个地方用得上:这一屏的头上那一行。单独开 `GET /api/sessions/:id/branch`
10467
+ * 等于让界面为了同一个目录多打一次网络往返,而这两条答案**必须来自同一刻** ——
10468
+ * 分开问的话,一次 `git checkout` 夹在中间就能让「这一屏的改动」和「这一屏说的分支」
10469
+ * 对不上,而那种不对屏幕上不报错。
10470
+ *
10471
+ * **缺席的三种情况说的是同一件事:这条信息这一发没有。**
10472
+ *
10473
+ * - 不是 git 仓库(`source: 'checkpoints' | 'none'`)—— 那条来路上压根没有分支;
10474
+ * - 仓库还没有 HEAD(刚 `git init`);
10475
+ * - detached HEAD(`git rev-parse --abbrev-ref HEAD` 回 `HEAD`)。
10476
+ *
10477
+ * ⚠️ 三种都**不给一个 `''` 或 `'HEAD'` 顶着**:界面上那格要么有一个真分支名,
10478
+ * 要么整格不画。同 `root` 那条「编一个路径顶上去就是谎」的判据。
10479
+ */
10480
+ branch?: string;
10481
+ /**
10482
+ * 当前分支的上游(`origin/main`)。没有配上游 / 上一条缺席时它一起缺席。
10483
+ *
10484
+ * ⚠️ 只给**配置里写着的那一个**(`@{upstream}`),不自己猜 `origin/<同名>` ——
10485
+ * 猜出来的那个在「本地分支还没推过」时是一条不存在的引用。
10486
+ */
10487
+ upstream?: string;
10341
10488
  files: readonly WireDiffFile[];
10342
10489
  /** 文件数被上限截断了。真值时 `notes` 里必有 `truncated` */
10343
10490
  truncated: boolean;
@@ -12745,6 +12892,43 @@ interface WirePluginCounts {
12745
12892
  denyRules: number;
12746
12893
  mcpServers: number;
12747
12894
  }
12895
+ /**
12896
+ * 插件自带的那一块面板(2026-10-20)。
12897
+ *
12898
+ * ## 它是**插件自己的一页**,不是我们画的一块
12899
+ *
12900
+ * 输入框上方那块地方(标题我们画、内容插件画)读的就是这一格。而「内容插件画」
12901
+ * 在不破安全线的前提下只有一条路:**插件在本机起一个 HTTP server,我们嵌
12902
+ * `<iframe>`**。另外两条都被否掉了,判据在 core 的 `plugin/manifest.ts` 那一格上
12903
+ * (内联 HTML 和服务端托管插件目录里的静态文件,两条都让那页落进**我们自己的源**)。
12904
+ *
12905
+ * ## ⚠️ 代价:插件得起一个小服务
12906
+ *
12907
+ * 端口没起 = 面板里是一块空白。而 iframe 的 `onError` **判不出来**(跨源),
12908
+ * 所以界面那一侧没有任何办法分清「还没加载完」和「那页根本没起来」——
12909
+ * 那一条退路只能画成一句常在的脚注 + 一个出口,判据在 web 的
12910
+ * `plugin-pane/index.tsx` 文件头。
12911
+ */
12912
+ interface WirePluginPanel {
12913
+ /**
12914
+ * 标题栏上印的那几个字。**省了就用插件的显示名**({@link WirePluginEntry.displayName}
12915
+ * 那一档,再退到 {@link WirePluginEntry.name})。
12916
+ *
12917
+ * ⚠️ 标题**由我们画**,不是插件页自己画一条。判据是那一条栏上还有一颗关闭键 ——
12918
+ * 让插件页画标题就得再开一条「插件能关掉我们这一层」的协议。
12919
+ */
12920
+ title?: string;
12921
+ /**
12922
+ * 那一页的地址。**只收本机回环**(`127.0.0.1` / `localhost`),http / https、
12923
+ * 端口不限 —— 闸的落点在 core 的 `manifest.ts`(`isLoopbackUrl`)。
12924
+ *
12925
+ * ⚠️ **不给 `data:` / 相对路径 / 别人的 https。** 前两者要么落进我们的源、
12926
+ * 要么根本没有源;第三条让一块第三方页面挂进用户正对着的输入框上方。
12927
+ */
12928
+ url: string;
12929
+ /** 面板多高(px)。省了用默认值,越界由界面夹回 —— 判据在 web 那一侧 */
12930
+ height?: number;
12931
+ }
12748
12932
  /** 装着的一个插件在浏览器眼里的样子 */
12749
12933
  interface WirePluginEntry {
12750
12934
  name: string;
@@ -12821,6 +13005,22 @@ interface WirePluginEntry {
12821
13005
  */
12822
13006
  updateAllowed: boolean;
12823
13007
  uninstallAllowed: boolean;
13008
+ /**
13009
+ * 包里清单写的外观预设(2026-10-19,`epoch-plugin.json` 的 `appearance` 段)。
13010
+ * `null` = 这个插件没带预设。**原样透传,服务端不判值域** —— 值域判定在消费侧
13011
+ * (设置页点下去那一刻过 protocol 的 `isAppearance*` guard,判据在 core 的
13012
+ * `plugin/manifest.ts` 那一格上)。
13013
+ */
13014
+ packageAppearance: readonly Record<string, unknown>[] | null;
13015
+ /**
13016
+ * 这个插件自带的那一块面板(2026-10-20)。`null` = 它没有面板,托盘那张菜单上
13017
+ * 它这一项**点了不出现那一层**。
13018
+ *
13019
+ * ⚠️ 和 {@link packageAppearance} 一样**原样透传、服务端不判值域** —— 值域
13020
+ * (回环 URL)在 core 读清单那一步就判完了,判不中的那一格在那边已经被丢掉并
13021
+ * 报过 issue。这一层再判一遍的话,两处分叉的表现是一块永远空白的面板。
13022
+ */
13023
+ panel: WirePluginPanel | null;
12824
13024
  }
12825
13025
  /** 市场里的一条 */
12826
13026
  interface WirePluginHit {
@@ -15357,7 +15557,8 @@ interface WireSettingsWriteResponse extends WireSettingPending {
15357
15557
  declare const WIRE_SETTINGS_WRITE_FIELDS: WireFields<WireSettingsWriteResponse>;
15358
15558
 
15359
15559
  /**
15360
- * 界面外观偏好(主题 / 语言)的值域 + `POST /api/appearance`(2026-09-29)。
15560
+ * 界面外观偏好(主题 / 语言)的值域 + `POST` / `GET /api/appearance`(2026-09-29,
15561
+ * GET 是 2026-10-19 补的)。
15361
15562
  *
15362
15563
  * ## 一、值域为什么定义在这儿
15363
15564
  *
@@ -15433,18 +15634,182 @@ declare const APPEARANCE_SIDEBAR_WIDTH: {
15433
15634
  };
15434
15635
  /** 一个合法的侧栏宽度:上下限之内的整数 px */
15435
15636
  declare function isAppearanceSidebarWidth(value: unknown): value is number;
15637
+ /**
15638
+ * 工作区 diff 那一屏右侧文件树的宽度上下限(px,2026-10-20 起可拖)。
15639
+ *
15640
+ * 和上面那组同一个理由住在这儿:界面拖它、服务端校验 `POST /api/appearance` 和首屏
15641
+ * 那个参数、引擎把它存进 `appearance.json` —— 三处要认同一个值域。**缺省值同样不在这儿**
15642
+ * (今天 268px,判据在 `web` 的 `workspace/tree-width.ts` 与 `workspace-diff.css`)。
15643
+ *
15644
+ * 上下限的理由:
15645
+ *
15646
+ * | | px | 为什么 |
15647
+ * | --- | --- | --- |
15648
+ * | 下限 | 180 | 树上那一行要装「缩进 + 6px 状态点 + 文件名 + `+N −M`」,再窄就只剩省略号 |
15649
+ * | 上限 | 560 | 再宽就是从 diff 正文身上切:1440 的窗口里正文只剩 600 出头,代码行会开始横向滚 |
15650
+ */
15651
+ declare const APPEARANCE_DIFF_TREE_WIDTH: {
15652
+ readonly min: 180;
15653
+ readonly max: 560;
15654
+ };
15655
+ /** 一个合法的文件树宽度:上下限之内的整数 px */
15656
+ declare function isAppearanceDiffTreeWidth(value: unknown): value is number;
15657
+ /** 强调色的封闭值域(2026-10-19)。**存色名不存色值**:色值的真源是 web 的 `tokens.css` */
15658
+ declare const APPEARANCE_ACCENTS: readonly ["default", "purple", "pink", "green", "orange", "gray"];
15659
+ /** 强调色。`default` = tokens.css 里那套系统蓝 */
15660
+ type AppearanceAccent = (typeof APPEARANCE_ACCENTS)[number];
15661
+ declare function isAppearanceAccent(value: unknown): value is AppearanceAccent;
15662
+ declare function isHexColor(value: unknown): value is string;
15663
+ /**
15664
+ * 强调色**取值的全集**:六个预设名 + 任意 `#rrggbb`。
15665
+ *
15666
+ * ⚠️ 两个类型刻意并存,别合并:{@link AppearanceAccent} 是「预设有哪几个」
15667
+ * (设置页画候选、`tokens.css` 给每色一段规则),这个是「这个字段能存什么」。
15668
+ * 合并的话,`tokens.css` 那六段会看起来覆盖了全部取值 —— 而自定义色不在其中,
15669
+ * 它靠行内的 CSS 变量生效(判据在 `theme/visual.ts` 的 `applyAccent`)。
15670
+ */
15671
+ type AppearanceAccentValue = AppearanceAccent | string;
15672
+ declare function isAppearanceAccentValue(value: unknown): value is AppearanceAccentValue;
15673
+ /**
15674
+ * 主题名(2026-10-19)。用户在设置页给这一套配色起的名字,跟着主题文件走。
15675
+ *
15676
+ * 值域和插件 `ui` 段的 `label` 同一条:**去换行、trim 之后 ≤ 40 码点**。
15677
+ * 理由也一样 —— 它要画在一行设置里、要能存进 json、要能手改。
15678
+ */
15679
+ declare const APPEARANCE_THEME_NAME_MAX = 40;
15680
+ declare function isAppearanceThemeName(value: unknown): value is string;
15681
+ /** 界面字号 / 代码字号的上下限(px,整数)。两格共用一个上下限各自收窄,见下面两个 guard */
15682
+ declare const APPEARANCE_FONT_SIZE: {
15683
+ readonly min: 12;
15684
+ readonly max: 18;
15685
+ };
15686
+ declare const APPEARANCE_CODE_FONT_SIZE: {
15687
+ readonly min: 10;
15688
+ readonly max: 16;
15689
+ };
15690
+ declare function isAppearanceFontSize(value: unknown): value is number;
15691
+ declare function isAppearanceCodeFontSize(value: unknown): value is number;
15692
+ /** 界面字体 / 代码字体的封闭值域。`system` = 系统默认栈(tokens.css 的原值) */
15693
+ declare const APPEARANCE_UI_FONTS: readonly ["system", "serif", "rounded"];
15694
+ type AppearanceUiFont = (typeof APPEARANCE_UI_FONTS)[number];
15695
+ declare function isAppearanceUiFont(value: unknown): value is AppearanceUiFont;
15696
+ declare const APPEARANCE_CODE_FONTS: readonly ["system", "jetbrains", "menlo"];
15697
+ type AppearanceCodeFont = (typeof APPEARANCE_CODE_FONTS)[number];
15698
+ declare function isAppearanceCodeFont(value: unknown): value is AppearanceCodeFont;
15699
+ /** 减少动态效果的三档。`system` = 跟随 `prefers-reduced-motion` */
15700
+ declare const APPEARANCE_MOTION: readonly ["system", "on", "off"];
15701
+ type AppearanceMotion = (typeof APPEARANCE_MOTION)[number];
15702
+ declare function isAppearanceMotion(value: unknown): value is AppearanceMotion;
15703
+ /** 对比度滑杆:0–100 整数。50 = 不动(真值),往两头微调 token 明度 */
15704
+ declare const APPEARANCE_CONTRAST: {
15705
+ readonly min: 0;
15706
+ readonly max: 100;
15707
+ };
15708
+ declare function isAppearanceContrast(value: unknown): value is number;
15709
+ /**
15710
+ * 半透明侧边栏(2026-10-20 从开关改成滑杆):**`--bg-chrome` 的 alpha 百分比**,
15711
+ * 0–100 整数。
15712
+ *
15713
+ * ⚠️ **100 = 不透明 = 关**,越小越透。用户原来只有一个开 / 关,开 = 72 ——
15714
+ * {@link APPEARANCE_TRANSLUCENT.legacyOn} 记的就是那个 72,老数据
15715
+ * (`appearance.json` 里的 `true`、localStorage 里的 `'1'`、首屏 URL 上的
15716
+ * `translucentSidebar=1`)一律归一成它,于是升级上来看到的第一帧和升级前一模一样。
15717
+ */
15718
+ declare const APPEARANCE_TRANSLUCENT: {
15719
+ readonly min: 0;
15720
+ readonly max: 100;
15721
+ readonly default: 100;
15722
+ readonly legacyOn: 72;
15723
+ };
15724
+ declare function isAppearanceTranslucent(value: unknown): value is number;
15725
+ /**
15726
+ * 把「半透明侧边栏」那一格归一成数字 —— **老布尔的唯一迁移点**。
15727
+ *
15728
+ * 三个来源都从这一道过:`appearance.json` 里的 `true` / `false`(core 读盘与 `set`)、
15729
+ * 导入的一份旧备份、localStorage 里的 `'1'` / `'0'`(web 的 `readTranslucentSidebar`)。
15730
+ * 不集中在 protocol 的话,「旧的 `true` 算 72 还是 100」会有三份答案,而分叉的表现是
15731
+ * 「升级之后有的入口开着、有的入口关了」。
15732
+ *
15733
+ * @returns 0–100 的整数;认不出来 = `undefined`(调用方按「这一格没给」处理)
15734
+ */
15735
+ declare function normalizeAppearanceTranslucent(value: unknown): number | undefined;
15736
+ /** 背景媒体的类型。`none` = 不要背景 */
15737
+ declare const APPEARANCE_BACKGROUND_KINDS: readonly ["none", "image", "gif", "video"];
15738
+ type AppearanceBackgroundKind = (typeof APPEARANCE_BACKGROUND_KINDS)[number];
15739
+ declare function isAppearanceBackgroundKind(value: unknown): value is AppearanceBackgroundKind;
15740
+ /** 背景铺满方式 */
15741
+ declare const APPEARANCE_BACKGROUND_FITS: readonly ["cover", "tile", "center"];
15742
+ type AppearanceBackgroundFit = (typeof APPEARANCE_BACKGROUND_FITS)[number];
15743
+ declare function isAppearanceBackgroundFit(value: unknown): value is AppearanceBackgroundFit;
15744
+ /**
15745
+ * 背景设置(kind / opacity / fit)。⚠️ **没有 `src` / `path` 那一格** ——
15746
+ * 文件本体住 `<homeDir>/background/` 那个目录(约定俗成的位置,server `background.ts`),
15747
+ * 这份 schema 里只记「是什么类型、压多透明、怎么铺」。把路径写进来的话,
15748
+ * 手改这份 json 就能把服务端指到盘上**任意一个文件**再经 `GET /api/background` 读出来
15749
+ * —— 那是拿一份偏好当路径穿越的入口。
15750
+ */
15751
+ interface AppearanceBackground {
15752
+ kind: AppearanceBackgroundKind;
15753
+ /** 0–100 整数,100 = 不透明 */
15754
+ opacity: number;
15755
+ fit: AppearanceBackgroundFit;
15756
+ }
15757
+ declare function isAppearanceBackground(value: unknown): value is AppearanceBackground;
15758
+ /**
15759
+ * 「分别设置浅色和深色」时,**每一档**各自能覆盖的那几格(2026-10-19)。
15760
+ *
15761
+ * ⚠️ **类型上写死不许再嵌 `perMode`** —— 「浅色的浅色」没有语义,而 schema 上留着那扇门,
15762
+ * 插件写歪一份清单出来的就是一份我们永远画不出来的偏好。它能覆盖的只有视觉四件套:
15763
+ * 强调色、字体、字号、背景。reduceMotion / translucentSidebar / contrast 是**机器级**的
15764
+ * 偏好(跟「这台机器在什么光线下」有关,跟「现在是深色还是浅色」无关),不分档。
15765
+ */
15766
+ interface AppearanceModePatch {
15767
+ /**
15768
+ * 强调色。**预设名或 `#rrggbb`**(2026-10-19 起收自定义色,判据在
15769
+ * {@link AppearanceAccentValue} 上)。缺席 = 用外层那一套。
15770
+ */
15771
+ accent?: AppearanceAccentValue;
15772
+ /** 主题名(这一档配色叫什么)。缺席 = 用外层那个 */
15773
+ themeName?: string;
15774
+ /** 画布底色(`#rrggbb`)。缺席 = 用 `tokens.css` 那一档 */
15775
+ canvasColor?: string;
15776
+ /** 前景墨色(`#rrggbb`)。缺席 = 用 `tokens.css` 那一档 */
15777
+ inkColor?: string;
15778
+ /**
15779
+ * 用户消息气泡的底色(`#rrggbb`,2026-10-20)。缺席 = 用 `tokens.css` 那一档。
15780
+ *
15781
+ * ⚠️ **它和画布 / 墨色一样分档**(这一格在 `AppearanceModePatch` 里):气泡在浅色档
15782
+ * 比画布**深**一档、在深色档比画布**亮**一档,两档的方向是反的(判据在 `--bg-said`
15783
+ * 那两段注释上)。一个不分档的值必然在某一档上读起来是错的。
15784
+ */
15785
+ saidColor?: string;
15786
+ uiFont?: AppearanceUiFont;
15787
+ codeFont?: AppearanceCodeFont;
15788
+ fontSize?: number;
15789
+ codeFontSize?: number;
15790
+ background?: AppearanceBackground;
15791
+ }
15792
+ declare function isAppearanceModePatch(value: unknown): value is AppearanceModePatch;
15436
15793
  /**
15437
15794
  * 一次偏好写入。**只写给了的那几格**(缺席 = 那一格不动),所以这是一次补丁。
15438
15795
  *
15439
- * ## 为什么没有 `GET`
15796
+ * ## 读回来有两条路,给两个不同的读者(`GET` 是 2026-10-19 补的)
15797
+ *
15798
+ * - **第一方界面**仍然只认首屏 URL 上那两个参数(`?theme=&lang=`)——
15799
+ * 它必须在**第一帧之前**拿到,而一次网络往返赶不上。`index.html` 那段内联脚本
15800
+ * 读的就是它。
15801
+ * - **嵌入宿主**画的是自己那层壳(侧栏 / 标题栏 / 窗口底色),它够不到 iframe
15802
+ * 里那条 URL —— 于是有了 `GET /api/appearance`。
15440
15803
  *
15441
- * 读这条路已经有了,而且**它必须在第一帧之前就到**:服务端把它拼进首屏 URL
15442
- * (`?theme=&lang=`),`index.html` 那段内联脚本在第一帧之前读它。再开一条
15443
- * `GET /api/appearance` 的话,界面会多出第二个「此刻是哪一档」的真源 ——
15444
- * 而它与 URL 上那一份**天然会不同步**(用户在设置页改完、还没重启时,
15445
- * 盘上已经是新的、而这一屏按的是刚写下的那个值)。
15804
+ * ⚠️ **这条 GET 不构成「第二真源」**:第一方界面从不请求它,两处答的本来就是
15805
+ * 两件事 —— URL 上是「这一屏打开时该按哪一档」,端点是「盘上此刻存着什么」。
15806
+ * 用户在设置页改完、还没重新导航时,两者天然会不同;宿主想要「现在」,
15807
+ * 那是它自己的轮询间隔(今天没有推送)。
15446
15808
  *
15447
- * 要排查「盘上到底存了什么」,`POST` 的回执原样带回来({@link WireAppearanceResponse})。
15809
+ * 两条路**共用同一份载荷形状**({@link WireAppearanceResponse})和同一道值域过滤:
15810
+ * 盘上被手改坏的 `"theme": "dracula"` 在两条路上都不上网线(当没选过)。
15811
+ *
15812
+ * 要排查「盘上到底存了什么」,`POST` 的回执原样带回来,`GET` 随时能再问一遍。
15448
15813
  *
15449
15814
  * ## 为什么是 POST 不是 PUT
15450
15815
  *
@@ -15478,17 +15843,71 @@ interface WireAppearanceRequest {
15478
15843
  * 「我存的和你发的不是一个数」,而界面那一侧发之前本来就夹过)
15479
15844
  */
15480
15845
  sidebarWidth?: number;
15481
- }
15482
- /**
15483
- * 写成功之后的回执:**盘上现在是什么**。
15846
+ /**
15847
+ * 工作区 diff 那一屏右侧文件树的宽度(px,2026-10-20)。缺席 = 不动。
15848
+ * 值域见 {@link APPEARANCE_DIFF_TREE_WIDTH},越界 / 非整数一律 400(同上面那格:
15849
+ * 不替用户夹)
15850
+ */
15851
+ diffTreeWidth?: number;
15852
+ /**
15853
+ * 强调色(预设名或 `#rrggbb`,值域见 {@link AppearanceAccentValue})。
15854
+ * ⚠️ 2026-10-19 起收自定义色 —— 那时它的类型从 `AppearanceAccent` 放宽了,
15855
+ * 而**预设那几个仍然按名字存**(`tokens.css` 给每色写死了一套,比现算稳)
15856
+ */
15857
+ accent?: AppearanceAccentValue;
15858
+ /** 主题名(这一套配色叫什么)。缺席 = 没起过名 */
15859
+ themeName?: string;
15860
+ /** 画布底色(`#rrggbb`)。缺席 = 用 `tokens.css` 那一档的默认值 */
15861
+ canvasColor?: string;
15862
+ /** 前景墨色(`#rrggbb`)。同上 */
15863
+ inkColor?: string;
15864
+ /** 用户消息气泡的底色(`#rrggbb`,2026-10-20)。同上 */
15865
+ saidColor?: string;
15866
+ /** 界面字号(px,整数 12–18) */
15867
+ fontSize?: number;
15868
+ /** 代码字号(px,整数 10–16) */
15869
+ codeFontSize?: number;
15870
+ /** 界面字体 */
15871
+ uiFont?: AppearanceUiFont;
15872
+ /** 代码字体 */
15873
+ codeFont?: AppearanceCodeFont;
15874
+ /** 减少动态效果(`system` = 跟随 `prefers-reduced-motion`) */
15875
+ reduceMotion?: AppearanceMotion;
15876
+ /**
15877
+ * 半透明侧边栏:`--bg-chrome` 的 alpha 百分比(0–100 整数,100 = 不透明)。
15878
+ * 值域见 {@link APPEARANCE_TRANSLUCENT}。⚠️ 2026-10-20 起是**数字**,
15879
+ * 旧客户端发的 `true` / `false` 由 {@link normalizeAppearanceTranslucent} 归一
15880
+ */
15881
+ translucentSidebar?: number;
15882
+ /** 对比度(0–100 整数,50 = 不动) */
15883
+ contrast?: number;
15884
+ /**
15885
+ * 「分别设置浅色和深色」的总开关。开了之后 {@link light} / {@link dark} 里
15886
+ * 那两档各自的覆盖才生效;关掉时那两格**存着但不生效**(不删 —— 用户来回切
15887
+ * 开关不该丢他已经调好的那两套)。
15888
+ */
15889
+ perMode?: boolean;
15890
+ /** perMode 开启时浅色档的覆盖。⚠️ 只嵌套一层,类型见 {@link AppearanceModePatch} */
15891
+ light?: AppearanceModePatch;
15892
+ /** perMode 开启时深色档的覆盖。同上 */
15893
+ dark?: AppearanceModePatch;
15894
+ /** 背景媒体(kind / opacity / fit,**不含路径**,见 {@link AppearanceBackground}) */
15895
+ background?: AppearanceBackground;
15896
+ }
15897
+ /**
15898
+ * 盘上现在是什么。**`POST` 的回执和 `GET /api/appearance` 的响应体是同一个形状**。
15484
15899
  *
15485
15900
  * 不是把请求原样回显 —— 两件不一样的事:请求里缺席的键在盘上有旧值(这一次没
15486
- * 动它),而回执答的是「这次写完之后那一份」。两个键都缺席 = 盘上还没有任何
15487
- * 用户偏好(宿主初值仍然生效)。
15901
+ * 动它),而这里答的是「现在那一份」。全部键都缺席 = 盘上还没有任何用户偏好
15902
+ * (宿主初值仍然生效)。
15488
15903
  *
15489
15904
  * 界面那一侧**不看这个回执**(它是 fire-and-forget,写不进去就静默降级,见
15490
15905
  * `web/src/prefs.ts`);它给的是**排查的人**和自己画前端的宿主:一条 200 加一份
15491
15906
  * 实际落盘状态,比让问题在「为什么每次重启都变回去」里查无实据强。
15907
+ *
15908
+ * ⚠️ **值域在这一层已经滤过一遍**(`server/src/appearance.ts` 的 `appearanceWire`):
15909
+ * 盘上手改坏的格子在这儿是**缺席**,不是原样透传 —— 否则「认不出来的值当没选过」
15910
+ * 这条判据只在内联脚本里成立,而宿主拿到的是另一个答案。
15492
15911
  */
15493
15912
  interface WireAppearanceResponse {
15494
15913
  ok: true;
@@ -15498,6 +15917,40 @@ interface WireAppearanceResponse {
15498
15917
  lang?: AppearanceLang;
15499
15918
  /** 盘上的侧栏宽度。同上 */
15500
15919
  sidebarWidth?: number;
15920
+ /** 盘上的工作区 diff 文件树宽度。同上 */
15921
+ diffTreeWidth?: number;
15922
+ /** 盘上的强调色。同上 */
15923
+ accent?: AppearanceAccentValue;
15924
+ /** 盘上的主题名。同上 */
15925
+ themeName?: string;
15926
+ /** 盘上的画布底色。同上 */
15927
+ canvasColor?: string;
15928
+ /** 盘上的前景墨色。同上 */
15929
+ inkColor?: string;
15930
+ /** 盘上的用户气泡底色。同上 */
15931
+ saidColor?: string;
15932
+ /** 盘上的界面字号。同上 */
15933
+ fontSize?: number;
15934
+ /** 盘上的代码字号。同上 */
15935
+ codeFontSize?: number;
15936
+ /** 盘上的界面字体。同上 */
15937
+ uiFont?: AppearanceUiFont;
15938
+ /** 盘上的代码字体。同上 */
15939
+ codeFont?: AppearanceCodeFont;
15940
+ /** 盘上的减少动态效果。同上 */
15941
+ reduceMotion?: AppearanceMotion;
15942
+ /** 盘上的半透明侧边栏(alpha 百分比,100 = 不透明)。同上 */
15943
+ translucentSidebar?: number;
15944
+ /** 盘上的对比度。同上 */
15945
+ contrast?: number;
15946
+ /** 盘上的 perMode 总开关。同上 */
15947
+ perMode?: boolean;
15948
+ /** 盘上的浅色档覆盖。同上 */
15949
+ light?: AppearanceModePatch;
15950
+ /** 盘上的深色档覆盖。同上 */
15951
+ dark?: AppearanceModePatch;
15952
+ /** 盘上的背景设置。同上 */
15953
+ background?: AppearanceBackground;
15501
15954
  }
15502
15955
  /**
15503
15956
  * 端点表用的判据。⚠️ **`theme` / `lang` 不在这张表上**:它们是可选键,
@@ -15506,6 +15959,242 @@ interface WireAppearanceResponse {
15506
15959
  */
15507
15960
  declare const WIRE_APPEARANCE_RESPONSE_FIELDS: WireFields<WireAppearanceResponse>;
15508
15961
 
15962
+ /**
15963
+ * 「盘上那份外观偏好」→「宿主该怎么画」(2026-10-20)。
15964
+ *
15965
+ * ## 它治的是什么
15966
+ *
15967
+ * `GET /api/appearance` 答的是**偏好**(用户点了哪些格子),不是**效果**:
15968
+ * 「强调色 = purple」里没有那四个 hex,「分别设置浅色和深色」的结果也没有合并,
15969
+ * 自定义 `#rrggbb` 的悬停 / 按下两档更是压根不存在(要现推)。
15970
+ * 嵌入宿主画自己那层壳(侧栏 / 标题栏 / 窗口底色)时,这三件都得它自己做。
15971
+ *
15972
+ * 在这一轮之前,那套语义**只有一份**,住在 `web/src/theme/visual.ts` 的
15973
+ * `resolveVisual` + `applyVisual` 上 —— 而 `web` 是 `private: true`,宿主
15974
+ * import 不到。于是宿主只有两条路:抄一份(升级就漂),或者不跟。
15975
+ *
15976
+ * 这一份是那条语义的**第二处实现**,也是给宿主的那一处。⚠️ 它和 web 那份
15977
+ * 是同一个意思的两种写法(web 那份读写的是 localStorage,形状不同),
15978
+ * **改判据要两边一起改**;`packages/protocol/__tests__/appearance-visual.test.ts`
15979
+ * 钉的是语义表(每档覆盖、缺省不落、吸附),不是「两份实现相等」。
15980
+ *
15981
+ * ## 输出的两样东西
15982
+ *
15983
+ * | 函数 | 给谁 | 是什么 |
15984
+ * | --- | --- | --- |
15985
+ * | {@link appearanceRootAttributes} | 宿主 | 该落在根元素上的 `data-*`(含 `data-theme`) |
15986
+ * | {@link appearanceVisualCss} | 宿主 | 该落成行内变量的那几格(+ 自定义强调色推出来的四个值) |
15987
+ *
15988
+ * 两样都由**同一个** {@link resolveAppearanceVisual} 算出来,所以它们不会各说各话。
15989
+ *
15990
+ * ## 宿主侧的三条硬要求(写进 EMBEDDING.md §9 了)
15991
+ *
15992
+ * 1. **先落属性,再注入 `GET /tokens.css`** —— 那张表的 `[data-theme='dark']`
15993
+ * 这类规则靠属性命中,只注入 CSS 不落属性等于没注入。
15994
+ * 2. **每轮先按 `APPEARANCE_ROOT_ATTRIBUTES` 把上一轮的属性全删掉再落** ——
15995
+ * 否则「自定义强调色 → 回到预设」时那个旧的 `data-accent` 会留着,
15996
+ * 而它会压过行内变量(判据在 `web/src/theme/visual.ts` 的 `applyAccent`)。
15997
+ * 3. **`theme` 是宿主决定的**(偏好是 `system` 时按 `prefers-color-scheme` 解),
15998
+ * 这份代码不猜。
15999
+ */
16000
+
16001
+ /** 生效主题。**不是偏好**(偏好还有一档 `system`,解成这两者之一才落属性) */
16002
+ type AppearanceEffectiveTheme = 'light' | 'dark';
16003
+ /**
16004
+ * 这份解析吃的东西。{@link WireAppearanceResponse} 和 runtime 的
16005
+ * `AppearancePrefsView` 都结构兼容它(两者都只是「一堆可选格子」)。
16006
+ *
16007
+ * ⚠️ **字段类型故意写宽**(`uiFont?: string` 而不是 `AppearanceUiFont`):
16008
+ * 这一层吃的是**盘上原样**,而盘上那份可以被用户拿编辑器改坏,也可以是一份
16009
+ * 老版本写下来的旧值。窄类型在这儿只会逼调用方在边界上强转,而强转正好把
16010
+ * 「认不出来」这件事藏起来 —— 那正是这一层要处理的东西。
16011
+ *
16012
+ * ⚠️ **每格在进来之后都会再滤一次值域**:`GET` 的响应(已滤过)和盘上原样都能吃,
16013
+ * 认不出来的格子当没设,判据同 `web/src/prefs.ts` 那条坏值策略。
16014
+ */
16015
+ interface AppearanceVisualSource {
16016
+ accent?: string;
16017
+ themeName?: string;
16018
+ canvasColor?: string;
16019
+ inkColor?: string;
16020
+ saidColor?: string;
16021
+ fontSize?: number;
16022
+ codeFontSize?: number;
16023
+ uiFont?: string;
16024
+ codeFont?: string;
16025
+ reduceMotion?: string;
16026
+ /** 0–100 的 alpha 百分比。旧数据可能是布尔(`true` = 72),由归一表兜住 */
16027
+ translucentSidebar?: number | boolean;
16028
+ contrast?: number;
16029
+ perMode?: boolean;
16030
+ /** 一档覆盖。**没有更窄的类型**:它同样可能是手改坏的形态 */
16031
+ light?: Record<string, unknown>;
16032
+ dark?: Record<string, unknown>;
16033
+ background?: Record<string, unknown>;
16034
+ }
16035
+ /**
16036
+ * 当前这一档**生效值**。缺省格在这里已经是缺省值(14 / 12 / `system` / 100 / 50),
16037
+ * 所以「用户没设过」和「用户设成了缺省值」在这里合流 —— 那是 `applyVisual`
16038
+ * 那条「缺省不落属性」判据要的形态。
16039
+ */
16040
+ interface ResolvedAppearanceVisual {
16041
+ theme: AppearanceEffectiveTheme;
16042
+ /** 预设名(含 `default`)或 `#rrggbb` */
16043
+ accent: string;
16044
+ themeName?: string;
16045
+ canvasColor?: string;
16046
+ inkColor?: string;
16047
+ saidColor?: string;
16048
+ fontSize: number;
16049
+ codeFontSize: number;
16050
+ uiFont: AppearanceUiFont;
16051
+ codeFont: AppearanceCodeFont;
16052
+ reduceMotion: AppearanceMotion;
16053
+ /** alpha 百分比,100 = 不透明 */
16054
+ translucentSidebar: number;
16055
+ contrast: number;
16056
+ background: AppearanceBackground | undefined;
16057
+ }
16058
+ /**
16059
+ * 根元素上**可能被落**的全部 `data-*`。宿主每一轮先按这张表清一遍再落新的。
16060
+ *
16061
+ * ⚠️ `data-theme` 在这里,但它的**值**是宿主决定的(`system` → 媒体查询)。
16062
+ */
16063
+ declare const APPEARANCE_ROOT_ATTRIBUTES: readonly ["data-theme", "data-accent", "data-font-size", "data-code-font-size", "data-ui-font", "data-code-font", "data-motion", "data-translucent-sidebar", "data-contrast", "data-background"];
16064
+ /** 字号 / 代码字号的缺省值。**等于它就不落属性**(`tokens.css` 的枚举里没有这两档) */
16065
+ declare const APPEARANCE_DEFAULT_FONT_SIZE = 14;
16066
+ declare const APPEARANCE_DEFAULT_CODE_FONT_SIZE = 12;
16067
+ /**
16068
+ * 对比度吸附到最近的 10,并夹进 0–100。
16069
+ *
16070
+ * ⚠️ **这一步是必需的**:`tokens.css` 只为 `data-contrast` 的 0 / 10 / … / 100
16071
+ * 十档写了规则(50 不写 = 出厂),一个 63 落上去**一条规则也不命中** ——
16072
+ * 表现是「滑杆拖了但没反应」。判据在 `web/src/theme/visual.ts` 的 `snapContrast`。
16073
+ */
16074
+ declare function snapAppearanceContrast(value: number): number;
16075
+ /**
16076
+ * 盘上(或响应里)那一份 → 当前这一档的生效值。
16077
+ *
16078
+ * @param theme 当前生效档。**只有强调色需要它**(深色档的悬停方向相反)
16079
+ */
16080
+ declare function resolveAppearanceVisual(source: AppearanceVisualSource, theme: AppearanceEffectiveTheme): ResolvedAppearanceVisual;
16081
+ /**
16082
+ * 该落在根元素上的属性。**只含真的该落的那些**(缺省不落),且以 `data-*` 全称
16083
+ * 为键 —— 让宿主直接 `setAttribute`,不用记 `dataset` 那套驼峰转写。
16084
+ *
16085
+ * ⚠️ **自定义强调色时这里没有 `data-accent`**,那四个值在
16086
+ * {@link appearanceVisualCss} 里当行内变量给。预设色为什么反过来(走属性不走行内)
16087
+ * 判据在 `web/src/theme/visual.ts` 的 `applyAccent`:`tokens.css` 给每个预设
16088
+ * 写死了一整套、且深浅两档不同,现推只会得到「浅色档的值也用在深色档上」。
16089
+ */
16090
+ declare function appearanceRootAttributes(resolved: ResolvedAppearanceVisual): Record<string, string>;
16091
+ /**
16092
+ * 该落成**行内变量**的那几格,一格一格给出来。
16093
+ *
16094
+ * ## 🔴 为什么是「一对一对」而不是一段 CSS 文本
16095
+ *
16096
+ * 这一段原来只导出一个「拼好的 CSS 块」,挂在 `html { … }` 上。**2026-10-20 真机
16097
+ * 一验就发现它是错的**:`tokens.css` 里 `[data-theme='dark'] { --accent: #339cff }`
16098
+ * 的特异度是 (0,1,1),而裸 `html` 是 (0,0,1) —— **tokens.css 那一份赢**,用户选的
16099
+ * 自定义强调色在深色档上被覆盖成缺省蓝。表现是「选了紫色,深色下还是蓝的」。
16100
+ *
16101
+ * 正确的形态就是 epoch 第一方界面用的那一种(`web/src/theme/visual.ts` 的
16102
+ * `applyAccent` / `applySurface`):**行内 style**。它的优先级高于任何选择器,
16103
+ * 不跟注入顺序、不跟特异度、不跟将来 tokens.css 加什么新规则。
16104
+ *
16105
+ * 所以这里是「名字 → 值」的清单,宿主逐格 `style.setProperty` 就是对的;
16106
+ * {@link appearanceVisualCss} 只是把同一份清单渲染成文本(给不跑脚本的宿主,
16107
+ * 那一档的选择器已经抬到能压过 tokens.css)。
16108
+ */
16109
+ declare function appearanceInlineVars(resolved: ResolvedAppearanceVisual): Record<string, string>;
16110
+ /**
16111
+ * 同一份清单渲染成一段可以直接注入的 CSS(给**不跑脚本**的宿主)。
16112
+ *
16113
+ * ⚠️ **选择器是 `html[data-theme='<档>']`,不是裸 `html`** —— 判据在
16114
+ * {@link appearanceInlineVars} 的 🔴 上:裸 `html` 会输给 tokens.css 的
16115
+ * `[data-theme='dark']`,表现是「自定义强调色在深色档上不生效」。
16116
+ * 抬到这里之后特异度是 (0,1,1),和 tokens.css 那一段持平,而**注入的在后面**
16117
+ * —— 同特异度下后出现的赢。
16118
+ *
16119
+ * 空的时候返回一段注释而不是空串 —— 宿主那边「注入了但还是不对」时,
16120
+ * 看得到一句「用户一格都没改」比看一段空白快。
16121
+ *
16122
+ * @example
16123
+ * ```css
16124
+ * /* epoch appearance (dark) - generated by appearanceVisualCss *\/
16125
+ * html[data-theme='dark'] {
16126
+ * --bg-canvas: #181818;
16127
+ * --accent: #8f5cf0;
16128
+ * }
16129
+ * ```
16130
+ */
16131
+ declare function appearanceVisualCss(resolved: ResolvedAppearanceVisual): string;
16132
+
16133
+ /**
16134
+ * 强调色的色彩换算(2026-10-20 从 `web/src/theme/color.ts` 搬来)。
16135
+ *
16136
+ * ## 为什么它在 protocol 而不在 web
16137
+ *
16138
+ * 这套换算原来只服务设置页的取色器(`web` 是 `private: true`,别人 import
16139
+ * 不到)。2026-10-20 起嵌入宿主也要它:用户选了自定义强调色时,那一套
16140
+ * `--accent` / `-hover` / `-press` / `-ink` 得由宿主自己落在壳上,而
16141
+ * 「深色档提亮、浅色档压深」这条判据**只能有一份** —— 抄一份到宿主里,
16142
+ * 升级时两边各改一半的表现是「宿主和 iframe 里的按钮悬停色不一样」,
16143
+ * 而这种漂没有人会去查。
16144
+ *
16145
+ * protocol 是唯一一处「宿主够得到、又不许有 I/O」的地方,判据同
16146
+ * `wire-appearance.ts` 文件头第一节那张表。
16147
+ *
16148
+ * ## 只搬了纯函数
16149
+ *
16150
+ * `pointToSv` / `pointToHue`(取色器那两个拖拽落点)留在 web:它们的入参是
16151
+ * `DOMRect`,宿主那边没有这个类型。搬过来只会让 protocol 依赖 DOM 类型。
16152
+ */
16153
+ /** HSV。H 是 0–360,S / V 是 0–100 */
16154
+ interface Hsv {
16155
+ h: number;
16156
+ s: number;
16157
+ v: number;
16158
+ }
16159
+ /**
16160
+ * HSV → `#rrggbb`。
16161
+ *
16162
+ * @param hsv 三个分量都会被夹进合法区间(拖拽时会短暂越界)
16163
+ */
16164
+ declare function hsvToHex(hsv: Hsv): string;
16165
+ /**
16166
+ * `#rrggbb` → HSV。
16167
+ *
16168
+ * ⚠️ **S = 0 时 H 回 0**(灰色没有色相)。这正是取色器要自己留一份 H 的原因 ——
16169
+ * 判据在 `web/src/theme/color.ts` 的文件头。
16170
+ */
16171
+ declare function hexToHsv(hex: string): Hsv;
16172
+ /** 相对亮度(WCAG)。只用来挑墨色,不参与门禁 */
16173
+ declare function relativeLuminance(hex: string): number;
16174
+ /**
16175
+ * 把一个自定义颜色推成它那一套 token(`--accent` / `-hover` / `-press` / `-ink`)。
16176
+ *
16177
+ * ## 为什么不是直接把用户选的那个值写进 `--accent`
16178
+ *
16179
+ * 那张皮上有四处同时读强调色:**当填充**(按钮底)、**当字**(链接、强调文本)、
16180
+ * 悬停态、按下态,外加一格压在填充上的墨色(`--accent-ink`)。只给一个值的话,
16181
+ * 悬停和按下两档要么没有(按钮不动),要么和静止态一模一样(看不出按下去了)。
16182
+ *
16183
+ * 做法:静止态用用户选的色;悬停往对比度更高的方向挪一格,按下再挪一格;
16184
+ * 墨色按相对亮度在近黑 / 白之间挑一个。**这三个推导都是保守的** ——
16185
+ * 用户选了一个压根读不清的色时,我们**不改他的选择**(那是他明确要的自由),
16186
+ * 只是让悬停和按下有反馈。
16187
+ *
16188
+ * @param hex 用户选的色
16189
+ * @param dark 当前是不是深色档(深色档的悬停是**提亮**,浅色档是**压深**)
16190
+ */
16191
+ declare function accentScale(hex: string, dark: boolean): {
16192
+ base: string;
16193
+ hover: string;
16194
+ press: string;
16195
+ ink: string;
16196
+ };
16197
+
15509
16198
  /**
15510
16199
  * 此刻生效的那个选择,投影成网线上那一份。和 core 的 `ModelSelection` 逐字同形。
15511
16200
  *
@@ -17114,6 +17803,128 @@ interface WireFileCandidatesResponse {
17114
17803
  }
17115
17804
  declare const WIRE_FILE_CANDIDATES_FIELDS: WireFields<WireFileCandidatesResponse>;
17116
17805
 
17806
+ /**
17807
+ * 插件面板里点了链接(2026-10-20)—— **出站**消息族的第三条。
17808
+ *
17809
+ * ## 为什么需要一条新消息
17810
+ *
17811
+ * 输入框上方那块面板是一枚 `<iframe>`,里面那页由**插件作者**画
17812
+ * (`epoch-plugin.json` 的 `panel.url`)。它落在**不透明源**里
17813
+ * (`PLUGIN_PANE_SANDBOX` 刻意不给 `allow-same-origin`,判据在 web 的
17814
+ * `iframe-sandbox.ts`),于是:**父文档收不到里面的任何点击**。
17815
+ * 浏览器不会把 iframe 内部的事件冒泡出去 —— 这是平台行为,不是我们少写了一个监听。
17816
+ *
17817
+ * 所以在插件页里点 `<a href="https://…">` 今天只有两条路,而**两条都不经过宿主**:
17818
+ *
17819
+ * | 插件页怎么写 | 今天发生什么 | 问题 |
17820
+ * | --- | --- | --- |
17821
+ * | 裸的 `<a href>` | 在**面板里**导航过去 | 插件画的那一页被换掉,而且回不来 |
17822
+ * | `target="_blank"` | 弹一个**逃出沙箱**的窗口 | `allow-popups-to-escape-sandbox` 让宿主完全不知情 |
17823
+ *
17824
+ * 这条消息是第三种:**插件页把 url 交出来,宿主决定怎么打开**(系统浏览器 /
17825
+ * 应用内置窗口 / 先在应用里预览 / 干脆拒绝)。判定权回到宿主手里 —— 那本来就是
17826
+ * 它嵌这张页时该有的东西。
17827
+ *
17828
+ * ## 名字是**陈述句**,因为它是出站
17829
+ *
17830
+ * 和 {@link LINK_CLICKED_MESSAGE_TYPE} 的两位前辈(`epoch:sidebar-menu` /
17831
+ * `epoch:user-menu`)同族,读作「有链接被点了」;与入站的 `epoch:open-settings`
17832
+ * (命令句式「打开设置」)刚好相反。一个宿主作者扫一眼常量表就分得清哪条是收、
17833
+ * 哪条是发 —— 那条规矩写在 [sidebar-menu.ts](./sidebar-menu.ts) 文件头,别在这儿破例。
17834
+ *
17835
+ * ## 载荷只有 `url`
17836
+ *
17837
+ * 不带「是哪个插件面板里的」(插件名)、不带链接文字、不带 `source`。理由同
17838
+ * `sidebar-menu.ts` 那条「几个键共用一条消息,不带来源」:宿主知道自己嵌的是什么,
17839
+ * 也读得到 `event.source`。**多带一格,宿主那句监听就得跟着改**,换来的是它本来
17840
+ * 就答得出的答案。
17841
+ *
17842
+ * ## 宿主那一侧怎么接
17843
+ *
17844
+ * ```js
17845
+ * window.addEventListener('message', (e) => {
17846
+ * if (e.data?.type !== 'epoch:link-clicked') return;
17847
+ * openInMyOwnBrowser(e.data.url); // 打开方式归你:shell.openExternal / 内置窗口 / 拒绝
17848
+ * });
17849
+ * ```
17850
+ *
17851
+ * ⚠️ **判 `type` 那一句不能省**:同一个 window 上跑着的别人(devtools 扩展、打包器的
17852
+ * 热更新通道)也在发 `message`。那个字面量的真源是 {@link LINK_CLICKED_MESSAGE_TYPE},
17853
+ * 别在宿主那边手抄第二遍。
17854
+ *
17855
+ * ⚠️ **`targetOrigin` 我们发的是 `'*'`**,理由和 `sidebar-menu.ts` 那两条不同,
17856
+ * 写在 web 的 `plugin-pane/host-link.ts` 上(一句话:收窄成一个可配的 origin
17857
+ * 只会多一个键,而它唯一的效果是让宿主更容易把自己的监听配错)。
17858
+ *
17859
+ * ## ⚠️ 这条协议是**插件作者 opt-in** 的
17860
+ *
17861
+ * 我们不能改插件页的代码(不透明源、进不去它的文档),所以一条裸的 `<a href>`
17862
+ * 照旧走上面那张表里的第一行。插件作者要在页面里写三行:
17863
+ *
17864
+ * ```js
17865
+ * document.addEventListener('click', (e) => {
17866
+ * const a = e.target.closest('a[href]');
17867
+ * if (!a) return;
17868
+ * e.preventDefault();
17869
+ * parent.postMessage({ epoch: 'open-url', url: a.href }, '*');
17870
+ * });
17871
+ * ```
17872
+ *
17873
+ * 那三行写在 [docs/PLUGINS.md](../../../docs/PLUGINS.md) 的 `panel` 那一节里 ——
17874
+ * 判据也一起写在那儿(为什么 `preventDefault` 不能省:不写的话这一下会**同时**
17875
+ * 在面板里导航一次,两个动作叠在一起)。
17876
+ */
17877
+ /** 那条出站消息的 `type`。宿主和我们共用这一个字面量,两边都别手抄 */
17878
+ declare const LINK_CLICKED_MESSAGE_TYPE = "epoch:link-clicked";
17879
+ /**
17880
+ * 「打开一个链接」认哪几种协议。
17881
+ *
17882
+ * - `http` / `https`:网页;
17883
+ * - `mailto`:**「打开一个链接」在桌面端本来就包含「写邮件给谁」** —— 插件页里
17884
+ * 一个「联系我们」的按钮落在这一档上,不收的话它就变成点了没反应。
17885
+ *
17886
+ * ⚠️ **不收 `file:`**:那是把宿主变成一条「打开本地任意路径」的执行入口,而这条路的
17887
+ * 起点是**第三方插件画的页**。要点开工作区里的文件,那条路是文件链接
17888
+ * (`web/src/thread/file-link.tsx`),它有自己的校验(路径真的存在才让它可点);
17889
+ * 同族的雷在 `wire-file-view.ts` 上也记过(`.wsf` 被 Windows Script Host 执行)。
17890
+ *
17891
+ * ⚠️ 也不收 `javascript:` / `data:` —— 那两个是**内容**不是**去处**,
17892
+ * 而这条消息的全部意思就是「给你一个去处」。
17893
+ */
17894
+ declare const OPENABLE_LINK_SCHEMES: readonly ["http:", "https:", "mailto:"];
17895
+ /**
17896
+ * 一个 url 最多多长(字符)。
17897
+ *
17898
+ * 2048 是「所有现实中的地址都装得下」那条线(IE 时代的老账,今天仍然好用)。
17899
+ * 不设上限的话,一个写坏的插件能塞一个几十 KB 的串进来,而那一串要
17900
+ * **过网线、进宿主的日志、再进它自己的窗口标题** —— 每一处都是一个放大器。
17901
+ */
17902
+ declare const MAX_LINK_URL = 2048;
17903
+ /**
17904
+ * 这个串能不能交出去。
17905
+ *
17906
+ * ⚠️ **用 `new URL()` 解析**,不拿正则判前缀:`https:evil`、`hTTps://x`、
17907
+ * `https:/\evil` 这几种写法在正则眼里和 `https://x` 分不出来,而 `URL` 是
17908
+ * 浏览器/Node 共用的那一份标准解析器 —— 判据同 web 的 `bridge.ts` 里 `isLoopback`
17909
+ * 那一格(它也是先 `new URL` 再判)。
17910
+ *
17911
+ * @returns 认得出、在白名单里、长度没超 → `true`
17912
+ */
17913
+ declare function isOpenableLink(raw: string): boolean;
17914
+ /**
17915
+ * 我们在父窗口那侧发出去的东西(插件面板点了链接)。
17916
+ *
17917
+ * ⚠️ 它**不是**插件页发进来的那条(那一条长这样:
17918
+ * `{ epoch: 'open-url', url }`,`epoch` 这个标记键在 web 的 `plugin-pane/bridge.ts` 上)。
17919
+ * 两层形状不同是刻意的:插件页那一侧只有「我们这条协议的标记」,而宿主这一侧
17920
+ * 听到的是**我们**的消息族 —— 两者共用同一套语义、不同一套信封,
17921
+ * 因为这个仓库里那两条既有消息也是这么分的。
17922
+ */
17923
+ interface LinkClickedMessage {
17924
+ type: typeof LINK_CLICKED_MESSAGE_TYPE;
17925
+ url: string;
17926
+ }
17927
+
17117
17928
  /**
17118
17929
  * 设置页那几个分区的 id —— **宿主够得着的词表**(2026-09-23)。
17119
17930
  *
@@ -17263,4 +18074,4 @@ declare const SECRET_SERVICE = "epoch-agent";
17263
18074
  */
17264
18075
  declare const MCP_DATA_KEY_NAME = "mcp-auth-data-key";
17265
18076
 
17266
- export { ACTION_CONTEXTS, AGENT_ROLE_NAME_PATTERN, API_KEY_ENV_VARS, APPEARANCE_LANGS, APPEARANCE_SIDEBAR_WIDTH, 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, BRAND_WHEN_SIDEBAR_COLLAPSED, type BackgroundTaskInfo, type BackgroundTaskKind, type BackgroundTaskStatus, type BlankCard, type BlankGreeting, type BoundKey, type BrandWhenSidebarCollapsed, type BudgetBreach, COMMAND_NAME_PATTERN, COMPLIANCE_ACTIONS, COMPLIANCE_CATEGORIES, CURRENCIES, type Catalogs, type ComplianceAction, type ComplianceCategory, type ContextBreakdown, type ContextNote, type ContextSegment, type ContextSegmentKind, type Currency, type CurrencyDisplay, type CustomCommandDef, type CustomCommandSource, DEFAULT_AGENT_ROLE, DEFAULT_LANG, type DecidedTrustLevel, type Diagnostic, DiagnosticSink, type DiagnosticStatus, ENTRY_REF_PREFIX, ENTRY_SECRET_PREFIX, 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, MODEL_ENTRY_PROTOCOLS, type MentionSet, type ModelEntry, type ModelEntryCapabilities, type ModelEntryProtocol, type ModelRef, type ModelSelection, type ModelSelectionOrigin, type MoneyDigits, NOOP_TELEMETRY, type NoticeCode, OPEN_SETTINGS_MESSAGE_TYPE, OPERATION_TYPES, OVERSIZE_RATIO, type OpenSettingsMessage, type Operation, type OperationType, PERMISSION_LEVELS, PLAN_OUTCOMES, PLUGIN_CATEGORY_DISPLAY_SEP, PLUGIN_MENU_MESSAGE_TYPE, PLUGIN_PREVIEW_STREAM_MIME, 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, REASONING_EFFORTS, REASONING_OFF, RESERVED_CHORDS, RESERVED_COMMAND_NAMES, type ReasoningChoice, type ReasoningEffort, type ReasoningState, type RejectReason, type RejectedKey, type RuleValue, SCHEDULE_DRAFT_TOOL, SCHEDULE_INTERVAL_MAX_MINUTES, SCHEDULE_INTERVAL_MIN_MINUTES, SCHEDULE_MAX_TIMES_PER_DAY, SCHEDULE_RUN_STATUSES, 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 ScheduleCronTrigger, 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 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 SidebarNavItem, 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, USER_MENU_MESSAGE_TYPE, type UserMenuMessage, 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_FOLDER_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_ENTRIES_FIELDS, WIRE_MODEL_ENTRY_MODELS_FIELDS, WIRE_MODEL_ENTRY_SAVE_FIELDS, WIRE_MODEL_ENTRY_TEST_FIELDS, WIRE_MODEL_FIELDS, WIRE_MODEL_SELECTION_FIELDS, WIRE_MODEL_SET_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_PROVIDER_GROUPS, 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_WITHDRAW_MESSAGE_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 WireAttachmentFolderResponse, 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 WireEffectiveModel, type WireEffectiveSlots, type WireEntryProbeCode, type WireEntryProvider, 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 WireHostBadgeRequest, type WireHostBadges, 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 WireModelEffortRequest, type WireModelEffortResponse, type WireModelEntriesResponse, type WireModelEntry, type WireModelEntryModelsResponse, type WireModelEntryProbeRequest, type WireModelEntryRefRequest, type WireModelEntryRefs, type WireModelEntrySaveRequest, type WireModelEntrySaveResponse, type WireModelEntryTestResponse, type WireModelRejection, type WireModelResponse, type WireModelSelection, type WireModelSetRequest, type WireModelSetResponse, 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 WirePluginDoc, type WirePluginDocs, 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 WirePluginPreviewStreamLine, type WirePluginProgressStep, 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 WireProviderGroup, 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 WireWithdrawMessageResponse, type WireWorkspaceBinding, type WireWorkspaceDiffResponse, type WireWorkspaceDirEntry, type WireWorkspaceDirsResponse, type WireWorkspaceRef, apiKeyEnvVar, assertNeverPart, assistantTurnText, attachSessionSurface, chordId, collectPendingApprovals, compressionThresholdTokens, conformsToWire, contentToText, cronTimes, diagnosticToLine, entryDisplayName, entryRef, entrySecretName, extractAllMentions, extractMentions, extractSessionMentions, filePartSummary, flattenCatalog, formatMoney, getProviderInfo, hasFailure, imagePartOmittedSummary, isAppearanceLang, isAppearanceSidebarWidth, isAppearanceTheme, isApprovalOutcome, isContextNearlyFull, isCurrency, isEntrySecretName, isHeadlessInputFormat, isHeadlessLifecycleEvent, isHeadlessOutputFormat, isKeyAction, isLang, isMentionableFilePath, isModelEntryId, isOperationType, isPermissionLevel, isPlanOutcome, isPromptOversize, isProviderType, isQuestionAnswerMap, isReasoningEffort, 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 };
18077
+ export { ACTION_CONTEXTS, AGENT_ROLE_NAME_PATTERN, API_KEY_ENV_VARS, APPEARANCE_ACCENTS, APPEARANCE_BACKGROUND_FITS, APPEARANCE_BACKGROUND_KINDS, APPEARANCE_CODE_FONTS, APPEARANCE_CODE_FONT_SIZE, APPEARANCE_CONTRAST, APPEARANCE_DEFAULT_CODE_FONT_SIZE, APPEARANCE_DEFAULT_FONT_SIZE, APPEARANCE_DIFF_TREE_WIDTH, APPEARANCE_FONT_SIZE, APPEARANCE_LANGS, APPEARANCE_MOTION, APPEARANCE_ROOT_ATTRIBUTES, APPEARANCE_SIDEBAR_WIDTH, APPEARANCE_THEMES, APPEARANCE_THEME_NAME_MAX, APPEARANCE_TRANSLUCENT, APPEARANCE_UI_FONTS, APPROVAL_OUTCOMES, type ActiveAgentRole, type AgentEvent, type AgentEventOf, type AgentEventType, type AgentRole, type AgentRoleScope, type AgentRoleSource, type AppearanceAccent, type AppearanceAccentValue, type AppearanceBackground, type AppearanceBackgroundFit, type AppearanceBackgroundKind, type AppearanceCodeFont, type AppearanceEffectiveTheme, type AppearanceLang, type AppearanceModePatch, type AppearanceMotion, type AppearanceTheme, type AppearanceUiFont, type AppearanceVisualSource, type ApprovalAnswer, type ApprovalOutcome, type ApprovalReply, type ApprovalRequest, type ApprovalScope, type ArtifactKind, type AttributeValue, type Attributes, BRAND_WHEN_SIDEBAR_COLLAPSED, type BackgroundTaskInfo, type BackgroundTaskKind, type BackgroundTaskStatus, type BlankCard, type BlankGreeting, type BoundKey, type BrandWhenSidebarCollapsed, type BudgetBreach, COMMAND_NAME_PATTERN, COMPLIANCE_ACTIONS, COMPLIANCE_CATEGORIES, CURRENCIES, type Catalogs, type ComplianceAction, type ComplianceCategory, type ContextBreakdown, type ContextNote, type ContextSegment, type ContextSegmentKind, type Currency, type CurrencyDisplay, type CustomCommandDef, type CustomCommandSource, DEFAULT_AGENT_ROLE, DEFAULT_LANG, type DecidedTrustLevel, type Diagnostic, DiagnosticSink, type DiagnosticStatus, ENTRY_REF_PREFIX, ENTRY_SECRET_PREFIX, 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 Hsv, type JsonSchema, KEY_ACTIONS, type KeyAction, type KeyChord, type KeyContext, type KeySequence, type KeybindingReport, type KeybindingSource, type KeybindingTable, LANGS, LINK_CLICKED_MESSAGE_TYPE, type Lang, type LinkClickedMessage, type LocalizedDetail, type LogFn, MAX_ATTACH_BYTES, MAX_ATTACH_FILES, MAX_ATTACH_TOTAL_BYTES, MAX_HEADER_CHARS, MAX_LINK_URL, MAX_OPTIONS, MAX_QUESTIONS, MAX_SESSION_ATTACH_BYTES, MAX_SESSION_REFS, MCP_DATA_KEY_NAME, METRIC, MIN_OPTIONS, MODEL_ENTRY_PROTOCOLS, type MentionSet, type ModelEntry, type ModelEntryCapabilities, type ModelEntryProtocol, type ModelRef, type ModelSelection, type ModelSelectionOrigin, type MoneyDigits, NOOP_TELEMETRY, type NoticeCode, OPENABLE_LINK_SCHEMES, OPEN_SETTINGS_MESSAGE_TYPE, OPERATION_TYPES, OVERSIZE_RATIO, type OpenSettingsMessage, type Operation, type OperationType, PERMISSION_LEVELS, PLAN_OUTCOMES, PLUGIN_CATEGORY_DISPLAY_SEP, PLUGIN_MENU_MESSAGE_TYPE, PLUGIN_PREVIEW_STREAM_MIME, 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, REASONING_EFFORTS, REASONING_OFF, RESERVED_CHORDS, RESERVED_COMMAND_NAMES, type ReasoningChoice, type ReasoningEffort, type ReasoningState, type RejectReason, type RejectedKey, type ResolvedAppearanceVisual, type RuleValue, SCHEDULE_DRAFT_TOOL, SCHEDULE_INTERVAL_MAX_MINUTES, SCHEDULE_INTERVAL_MIN_MINUTES, SCHEDULE_MAX_TIMES_PER_DAY, SCHEDULE_RUN_STATUSES, 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 ScheduleCronTrigger, 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 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 SidebarNavItem, 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, USER_MENU_MESSAGE_TYPE, type UserMenuMessage, 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_FOLDER_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_ENTRIES_FIELDS, WIRE_MODEL_ENTRY_MODELS_FIELDS, WIRE_MODEL_ENTRY_SAVE_FIELDS, WIRE_MODEL_ENTRY_TEST_FIELDS, WIRE_MODEL_FIELDS, WIRE_MODEL_SELECTION_FIELDS, WIRE_MODEL_SET_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_PROVIDER_GROUPS, 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_REVIVE_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_WITHDRAW_MESSAGE_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 WireAttachmentFolderResponse, 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 WireEffectiveModel, type WireEffectiveSlots, type WireEntryProbeCode, type WireEntryProvider, 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 WireHostBadgeRequest, type WireHostBadges, 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 WireModelEffortRequest, type WireModelEffortResponse, type WireModelEntriesResponse, type WireModelEntry, type WireModelEntryModelsResponse, type WireModelEntryProbeRequest, type WireModelEntryRefRequest, type WireModelEntryRefs, type WireModelEntrySaveRequest, type WireModelEntrySaveResponse, type WireModelEntryTestResponse, type WireModelRejection, type WireModelResponse, type WireModelSelection, type WireModelSetRequest, type WireModelSetResponse, 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 WirePluginDoc, type WirePluginDocs, type WirePluginEntry, type WirePluginHit, type WirePluginHookTally, type WirePluginInstallRequest, type WirePluginLocalInstallRequest, type WirePluginLocalRequest, type WirePluginMarketplace, type WirePluginMarketplaceRequest, type WirePluginMarketplaceResponse, type WirePluginMenuItem, type WirePluginNameRequest, type WirePluginPanel, type WirePluginPreview, type WirePluginPreviewRequest, type WirePluginPreviewResponse, type WirePluginPreviewStreamLine, type WirePluginProgressStep, 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 WireProviderGroup, type WireQuestionListResponse, type WireQuestionRequest, type WireReplayMessage, type WireResetReason, type WireRespondApprovalRequest, type WireRespondApprovalResponse, type WireRespondQuestionRequest, type WireRespondQuestionResponse, type WireReviveResponse, 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 WireWithdrawMessageResponse, type WireWorkspaceBinding, type WireWorkspaceDiffResponse, type WireWorkspaceDirEntry, type WireWorkspaceDirsResponse, type WireWorkspaceRef, accentScale, apiKeyEnvVar, appearanceInlineVars, appearanceRootAttributes, appearanceVisualCss, assertNeverPart, assistantTurnText, attachSessionSurface, chordId, collectPendingApprovals, compressionThresholdTokens, conformsToWire, contentToText, cronTimes, diagnosticToLine, entryDisplayName, entryRef, entrySecretName, extractAllMentions, extractMentions, extractSessionMentions, filePartSummary, flattenCatalog, formatMoney, getProviderInfo, hasFailure, hexToHsv, hsvToHex, imagePartOmittedSummary, isAppearanceAccent, isAppearanceAccentValue, isAppearanceBackground, isAppearanceBackgroundFit, isAppearanceBackgroundKind, isAppearanceCodeFont, isAppearanceCodeFontSize, isAppearanceContrast, isAppearanceDiffTreeWidth, isAppearanceFontSize, isAppearanceLang, isAppearanceModePatch, isAppearanceMotion, isAppearanceSidebarWidth, isAppearanceTheme, isAppearanceThemeName, isAppearanceTranslucent, isAppearanceUiFont, isApprovalOutcome, isContextNearlyFull, isCurrency, isEntrySecretName, isHeadlessInputFormat, isHeadlessLifecycleEvent, isHeadlessOutputFormat, isHexColor, isKeyAction, isLang, isMentionableFilePath, isModelEntryId, isOpenableLink, isOperationType, isPermissionLevel, isPlanOutcome, isPromptOversize, isProviderType, isQuestionAnswerMap, isReasoningEffort, isSearchProviderType, isSettingsPaneId, isValidAgentRoleName, isValidCommandName, isWireGoalPhase, isWireHubEvent, isWirePlanAction, isWirePluginArchiveName, isWireRewindScope, isWireSettingWriteLayer, isWireSkillDropName, joinUploadMulti, makeTranslate, mcpConnectorState, normalizeAppearanceTranslucent, normalizeApproval, packSessionSurface, parseChord, parseModelRef, parseSequence, perAction, placeholdersOf, promptTokens, relativeLuminance, resolveAppearanceVisual, resolveHostText, sequenceId, sessionPartSummary, snapAppearanceContrast, splitUploadMulti, stripSystemNote, systemNote, tableOf, totalUsageTokens, translatorFor, truncateToBudget, turnDigest, unfixedRules, utf8ByteLength, wireFields };