import type { PrepareStepContext } from '../types/session/prepare-step.js'; interface QueryMessage { readonly position: number; readonly role: string; readonly text: string; readonly truncated: boolean; readonly source?: 'compaction-summary'; } export interface EvidenceQueryResolution { readonly terms: readonly string[]; /** Optional grounded subject words; discovery requires any one, not all of them. */ readonly focusTerms?: readonly string[]; readonly time: 'past' | 'unspecified'; readonly basis: readonly { position: number; role: string; quote: string; /** A derived lookup reference, never an original observation. */ source?: 'compaction-summary'; }[]; /** Distinct visible word spellings not offered within the planning input allowance. */ readonly omittedTokens?: number; } /** A planner interpretation of visible references, never authenticated evidence. */ export interface EvidenceQueryAmbiguity { readonly kind: 'ambiguous'; readonly basis: EvidenceQueryResolution['basis']; } type QueryPlan = EvidenceQueryResolution | EvidenceQueryAmbiguity | null | undefined; /** Internal planner input. IDs are local to this exact bounded input, never archive addresses. */ export declare function buildEvidenceQueryInput(current: string, history: readonly QueryMessage[]): { prompt: string; tokens: string[]; omittedTokens: number; } | undefined; /** Pure validation grounds the selected tokens in the supplied visible text. */ export declare function validateEvidenceQueryResolution(raw: string, current: string, history: readonly QueryMessage[]): QueryPlan; /** One cached plan for the same operator input; evidence bytes are never cached. */ export declare function createEvidenceQueryResolver(): (context: PrepareStepContext, query: string) => Promise; export {}; //# sourceMappingURL=evidence-query.d.ts.map