@epoch-agent/view 2.3.0 → 2.5.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.
Files changed (2) hide show
  1. package/dist/index.d.ts +20 -1
  2. package/package.json +2 -2
package/dist/index.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- import { WireSessionReference, WireFileReference, WireImageReference, ToolArtifact, AgentEvent } from '@epoch-agent/protocol';
1
+ import { WireSessionReference, WireFileReference, WireImageReference, EpochUserCommand, ToolArtifact, AgentEvent } from '@epoch-agent/protocol';
2
2
 
3
3
  /**
4
4
  * 展示项类型 — 基于 Google Gemini CLI types.ts
@@ -117,6 +117,25 @@ type HistoryItemUser = HistoryItemBase & {
117
117
  * 那一格的处置,是一次判断不是漏接)。
118
118
  */
119
119
  images?: readonly WireImageReference[];
120
+ /**
121
+ * 这一条是**按哪条命令**发出来的(2026-10-21)。
122
+ *
123
+ * 和 `text` 不重复:`text` 是展开之后的正文(模型看到的那一份),这一格是
124
+ * 「这行字是怎么来的」—— 渲染层据此把它画成一行 `/命令名 参数`,而不是把
125
+ * 几十行工作表指令冒充成用户说过的话。
126
+ *
127
+ * 三个来源各有一条填它的路,缺一不可:
128
+ *
129
+ * | 谁填 | 从哪来 |
130
+ * | --- | --- |
131
+ * | 回放(`GET /messages`) | `messages.command` 那一列 |
132
+ * | 刚发出去那一条 | `submit` action(浏览器只能带 `name` + 参数) |
133
+ * | 别的窗口发的那一条 | `user-message` 帧上的 `command` |
134
+ *
135
+ * 缺席 = 普通消息,或者这条是 v15 之前的库写的(那时候没这个信息,
136
+ * 推不出来就不编)。
137
+ */
138
+ command?: EpochUserCommand;
120
139
  };
121
140
  /**
122
141
  * 模型的回复正文。
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@epoch-agent/view",
3
- "version": "2.3.0",
3
+ "version": "2.5.0",
4
4
  "private": false,
5
5
  "description": "epoch-agent 展示层纯逻辑:AgentEvent → 可渲染 item,tui 与 web 共用",
6
6
  "repository": {
@@ -22,7 +22,7 @@
22
22
  "dist"
23
23
  ],
24
24
  "dependencies": {
25
- "@epoch-agent/protocol": "2.3.0"
25
+ "@epoch-agent/protocol": "2.5.0"
26
26
  },
27
27
  "devDependencies": {
28
28
  "tsup": "^8.3.6",