/** * Progressive-disclosure helpers (Spec 25 Phase C / P2–P5). * * OpenLore's answer to headroom's reversible compression: return the smallest * sufficient structural fact plus an *exact* expansion handle, and let a caller * fit the result to a token budget deterministically. Because our IDs are * deterministic, expansion is exact (call `get_function_body(directory, * filePath, name)`), never a fuzzy re-search. */ /** * Uniform expansion handle attached to every disclosable item: `name::filePath`. * An agent expands exactly one body with `get_function_body` only if it needs * the implementation — turning a would-be follow-up read into a cheap, optional, * one-shot call instead of a blind re-search (the P2 contract). */ export declare function expandHandle(name: string, filePath: string): string; export interface BudgetOutcome { kept: T[]; /** How many items were dropped to fit the budget (0 when none / no budget). */ omitted: number; } /** * Greedily keep score-ordered items until `budget` tokens are exhausted (P4). * Items are assumed already importance-ranked by the caller; at least one item * is always kept so a tiny budget still yields a usable answer. Deterministic: * same items + budget → same output (uses the char-based `estimateTokens`). */ export declare function applyTokenBudget(items: T[], budget: number | undefined): BudgetOutcome; /** * Collapse *exact* duplicates — same name AND signature AND docstring — to one * exemplar that lists the other locations in `duplicateOf` (P3, conservative). * Requiring an exact triple match means two genuinely different functions that * merely share a name are never merged; only true copies (generated code, * vendored duplicates, re-exports) collapse. Order is preserved. */ export declare function collapseExactDuplicates(items: T[]): Array; /** The omission note appended when a token budget drops items (P4). */ export declare function omissionNote(omitted: number, expandHint: string): string; //# sourceMappingURL=progressive.d.ts.map