declare function estimateTotalTokens(messages: any[]): number; /** * If total exceeds threshold, return a new array where the first N * messages are collapsed into a single summary. * The summarization itself is delegated to the caller (e.g. via sub-agent). */ declare function shouldSummarize(messages: any[], model: string, thresholdPct?: number): boolean; /** Create a plain-text summary of older messages for compression. */ declare function summaryPrompt(olderMessages: any[]): string; export { estimateTotalTokens, shouldSummarize, summaryPrompt };