/** * Compact Tool Result Formatting — Phase 2 of Advanced Token Optimization * * Replaces JSON.stringify for tool results in the LLM messages array. * Per-tool formatters strip JSON overhead (escaped newlines, metadata fields) * and produce a text format the LLM can parse just as well. * * Only affects what the LLM reads in its message history. * CLI formatters, events, and hooks still receive the raw ToolExecutionResult. */ /** * Format a tool result as compact text for LLM context. * Falls back to JSON.stringify for unknown tools or non-object results. */ export declare function compactToolResult(toolName: string, result: unknown, input?: Record): string;