@epoch-agent/view 6.0.0 → 6.1.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 +18 -0
- package/package.json +2 -2
package/dist/index.d.ts
CHANGED
|
@@ -47,6 +47,24 @@ interface HistoryItemBase {
|
|
|
47
47
|
* 第一次调用)—— 用最后一帧会让回退目标往后漂。
|
|
48
48
|
*/
|
|
49
49
|
seq?: number;
|
|
50
|
+
/**
|
|
51
|
+
* 这一项对应那条**落盘消息**的主键(`messages.id`)。
|
|
52
|
+
*
|
|
53
|
+
* ## 它和 `seq` / `HistoryItem.id` 都不是一回事
|
|
54
|
+
*
|
|
55
|
+
* | 钥匙 | 谁发的 | 什么时候有 | 活多久 |
|
|
56
|
+
* | --- | --- | --- | --- |
|
|
57
|
+
* | `seq` | 服务进程的全局信封计数器 | 直播 | 进程重启就从 1 重新数 |
|
|
58
|
+
* | `id`(`HistoryItem.id`) | 浏览器自己的目录计数器 | 直播和回放都有 | 一次补拉就可能换 |
|
|
59
|
+
* | `msgId` | 会话库的主键 | **只有回放** | 永远不变 |
|
|
60
|
+
*
|
|
61
|
+
* 靠它做成的是「跨页稳定锚点」:历史分页之后,同一句提问在服务端那侧永远是
|
|
62
|
+
* 同一个 `msgId`,而本地 `id` 会随前置页平移。右侧刻度条落在
|
|
63
|
+
* `data-rail="m<msgId>"` 上就是这一格(判据在 web 的 `thread/rail.ts`)。
|
|
64
|
+
*
|
|
65
|
+
* 缺席是常态:直播那条路上没有它(帧里不带落盘主键),TUI 也从不填。
|
|
66
|
+
*/
|
|
67
|
+
msgId?: number;
|
|
50
68
|
}
|
|
51
69
|
type HistoryItemUser = HistoryItemBase & {
|
|
52
70
|
type: 'user';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@epoch-agent/view",
|
|
3
|
-
"version": "6.
|
|
3
|
+
"version": "6.1.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": "6.
|
|
25
|
+
"@epoch-agent/protocol": "6.1.0"
|
|
26
26
|
},
|
|
27
27
|
"devDependencies": {
|
|
28
28
|
"tsup": "^8.3.6",
|