/** * 纯合成 Pi session v3 fixture 构建器(不含真实用户内容)。 */ export interface SessionHeaderInput { id?: string; cwd: string; parentSession?: string; timestamp?: string; } export interface MessageEntryInput { id?: string; parentId: string | null; role: "user" | "assistant" | "toolResult" | "custom"; text?: string; thinking?: string; toolName?: string; customType?: string; timestamp?: string; } export interface CompactionEntryInput { id?: string; parentId: string | null; summary: string; timestamp?: string; } export type FixtureEntry = MessageEntryInput | CompactionEntryInput | Record; export interface SessionFixtureSpec { name: string; header: SessionHeaderInput; entries: FixtureEntry[]; } /** * 生成 8 位 hex entry ID。 */ export declare function makeEntryId(seed?: string): string; /** * 构造 v3 session header JSON 对象。 */ export declare function buildHeader(input: SessionHeaderInput): Record; /** * 构造 message entry。 */ export declare function buildMessageEntry(input: MessageEntryInput): Record; /** * 构造 compaction summary entry。 */ export declare function buildCompactionEntry(input: CompactionEntryInput): Record; /** * 将 fixture 规格序列化为 JSONL 文本。 */ export declare function serializeSessionFixture(spec: SessionFixtureSpec): string; /** * 将一组 fixture 写到目录。 */ export declare function writeSessionFixtures(dir: string, specs: SessionFixtureSpec[]): string[]; //# sourceMappingURL=fixture-builder.d.ts.map