@atlaswork/atlascode 0.1.126 → 0.1.128

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 (36) hide show
  1. package/dist/atlasweb-carrier.json +3 -3
  2. package/dist/cli.js +31 -7
  3. package/dist/web-contract/index.d.ts +8 -0
  4. package/dist/web-contract/index.js +5 -2
  5. package/dist/web-session-runtime/atlascode/web/limits.d.ts +2 -0
  6. package/dist/web-session-runtime/atlascode/web/projection.d.ts +6 -0
  7. package/dist/web-session-runtime/atlascode/web/readonlyRuntime.d.ts +24 -0
  8. package/dist/web-session-runtime/atlascode/web/replayPaging.d.ts +27 -0
  9. package/dist/web-session-runtime/engine/session/load.d.ts +47 -0
  10. package/dist/web-session-runtime/engine/session/predicates.d.ts +1 -1
  11. package/dist/web-session-runtime/engine/session/readonly.d.ts +2 -0
  12. package/dist/web-session-runtime/engine/session/replayScan.d.ts +45 -0
  13. package/dist/web-session-runtime/engine/session/types.d.ts +1 -1
  14. package/dist/web-session-runtime/index.js +373 -4
  15. package/dist/web-session-runtime/kernel/protocol/webSessionV0.d.ts +8 -0
  16. package/dist/web-session-runtime/shared/index.d.ts +1 -1
  17. package/dist/web-session-runtime-execution/atlascode/web/entry.d.ts +2 -0
  18. package/dist/web-session-runtime-execution/atlascode/web/limits.d.ts +2 -0
  19. package/dist/web-session-runtime-execution/atlascode/web/projection.d.ts +6 -0
  20. package/dist/web-session-runtime-execution/atlascode/web/readonlyRuntime.d.ts +24 -0
  21. package/dist/web-session-runtime-execution/atlascode/web/replayPaging.d.ts +27 -0
  22. package/dist/web-session-runtime-execution/engine/session/load.d.ts +47 -0
  23. package/dist/web-session-runtime-execution/engine/session/predicates.d.ts +1 -1
  24. package/dist/web-session-runtime-execution/engine/session/readonly.d.ts +2 -0
  25. package/dist/web-session-runtime-execution/engine/session/replayScan.d.ts +45 -0
  26. package/dist/web-session-runtime-execution/engine/session/types.d.ts +1 -1
  27. package/dist/web-session-runtime-execution/index.js +662 -8
  28. package/dist/web-session-runtime-execution/kernel/execution/executionComposition.d.ts +18 -0
  29. package/dist/web-session-runtime-execution/kernel/execution/executionKernel.d.ts +77 -0
  30. package/dist/web-session-runtime-execution/kernel/protocol/webSessionV0.d.ts +8 -0
  31. package/dist/web-session-runtime-execution/shared/index.d.ts +1 -1
  32. package/package.json +2 -2
  33. package/dist/web-session-runtime/atlascode/web/entry.d.ts +0 -21
  34. package/dist/web-session-runtime/atlascode/web/executionOutlet.d.ts +0 -60
  35. package/dist/web-session-runtime/kernel/execution/executionOutlet.d.ts +0 -60
  36. package/dist/web-session-runtime/kernel/protocol/webExecutionV0.d.ts +0 -542
@@ -0,0 +1,45 @@
1
+ /** skeleton 记录 = 链/恢复 pass 所需字段的窄结构面(内容已剥除)。 */
2
+ export interface ReplaySkeletonRecord {
3
+ uuid: string;
4
+ parentUuid: string | null;
5
+ type: string;
6
+ timestamp?: string | null;
7
+ isSidechain?: boolean;
8
+ compactMetadata?: unknown;
9
+ subtype?: string;
10
+ snipMetadata?: unknown;
11
+ message?: {
12
+ id?: string;
13
+ content?: unknown;
14
+ };
15
+ }
16
+ /** 行字节范围(文件绝对坐标;length 不含换行)。 */
17
+ export interface ReplayByteRange {
18
+ offset: number;
19
+ length: number;
20
+ }
21
+ export interface ReplayPageReader {
22
+ /** skeleton Map(last-wins;relink/snip 已施加)。 */
23
+ skeletons: Map<string, ReplaySkeletonRecord>;
24
+ /** uuid → 行字节范围(与 skeletons 同键集;被 relink/snip 剪枝的残键无害)。 */
25
+ ranges: Map<string, ReplayByteRange>;
26
+ /** open 后 fstat 身份(web 层 adapter stPost 三元组对表的 ino 侧)。 */
27
+ ino: number;
28
+ size: number;
29
+ /** pass2:按字节范围读页内记录原文(返回序 = 入参序;公共面用
30
+ * Uint8Array——S0-R 打包出口 d.ts 消费 tsconfig 无 node types,
31
+ * Buffer 类型名不入 .d.ts,实现体仍可用 Buffer)。 */
32
+ readRanges(ranges: ReadonlyArray<ReplayByteRange>): Promise<Uint8Array[]>;
33
+ close(): Promise<void>;
34
+ }
35
+ /**
36
+ * 打开 replay 分页读取器:open(O_NOFOLLOW 旗标,POSIX;Windows 守卫跳过
37
+ * ——load.ts S0-R4 F1 同形)→ fstat 身份/尺寸检查点 → 流式逐行 skeleton
38
+ * 扫描 → 装载期图变换(relink/snip)。fd 保持打开供 pass2 readRanges;
39
+ * close 恒由调用方 finally 触达(成功路径 fd 移交 reader,失败路径此处
40
+ * 关闭)。
41
+ */
42
+ export declare function openReplayPageReader(filePath: string, opts?: {
43
+ maxBytes?: number;
44
+ expectIno?: number;
45
+ }): Promise<ReplayPageReader>;
@@ -33,7 +33,7 @@
33
33
  * sourceToolAssistantUUID/attachment):旧仓 `(m as any).message.id` 类
34
34
  * cast 在域扩展型下直接可访,逐字块内按需去 cast(语义逐字不变)。
35
35
  */
36
- import type { ContentBlock, Message as BaseMessage, Usage } from '../../shared.js';
36
+ import type { ContentBlock, Message as BaseMessage, Usage } from '../../shared/types.js';
37
37
  export type UUID = string;
38
38
  /** 旧 types/ids brand → string(残余 ② 口径)。 */
39
39
  export type AgentId = string;