import { type ImageContent, type Message, type ProviderNativeContent, type TextContent, type ThinkingContent, type ToolCall } from "@earendil-works/pi-ai"; import type { AgentMessage } from "../../types.ts"; /** File paths touched by a session branch or compaction range. */ export interface FileOperations { /** Files read but not necessarily modified. */ read: Set; /** Files written by full-file write operations. */ written: Set; /** Files modified by edit operations. */ edited: Set; } /** Create an empty file-operation accumulator. */ export declare function createFileOps(): FileOperations; /** Add file operations from assistant tool calls to an accumulator. */ export declare function extractFileOpsFromMessage(message: AgentMessage, fileOps: FileOperations): void; /** Compute sorted read-only and modified file lists from accumulated operations. */ export declare function computeFileLists(fileOps: FileOperations): { readFiles: string[]; modifiedFiles: string[]; }; /** Format file lists as summary metadata tags. */ export declare function formatFileOperations(readFiles: string[], modifiedFiles: string[]): string; type SummaryContentBlock = TextContent | ImageContent | ThinkingContent | ToolCall | ProviderNativeContent; /** * Extract text from content that may retain provider-native replay blocks. * * Provider-native blocks must remain on the original assistant message for * same-provider replay, but are not part of pi-ai's portable `contentText` * contract. Normalize a filtered copy for summarization instead of casting or * mutating the persisted message. */ export declare function contentTextForSummary(content: string | readonly SummaryContentBlock[], separator?: string): string; /** Serialize LLM messages to plain text for summarization prompts. */ export declare function serializeConversation(messages: Message[]): string; export {}; //# sourceMappingURL=utils.d.ts.map