import { type LLMConfig, type LLMResult } from "./llm.js"; export type UsageSink = (usage: NonNullable) => void; export interface Plan { queries: string[]; reasoning: string; } export interface Critique { done: boolean; reasoning: string; queries: string[]; } /** * Date grounding for the planner/critic prompts. Without it the model * anchors "recent"/"latest" to its TRAINING-time sense of now and writes * stale queries — and when `--since` is in play, the recency filter then * culls most of what those stale queries return (the v0.23.0 bench * "recent" failure: 1 source kept against a 3-source minimum). */ export interface PlanContext { /** Epoch ms for "today". Defaults to Date.now(); injectable for tests. */ now?: number; /** * Resolved `--since` cutoff (epoch ms). When set, the prompts disclose * that sources published before it are dropped, so queries get shaped * to the surviving window instead of the model's idea of "recent". */ sinceMs?: number; } export declare function plannerSystem(ctx?: PlanContext): string; export declare function planQueries(question: string, config: LLMConfig, signal?: AbortSignal, onUsage?: UsageSink, ctx?: PlanContext): Promise; export declare function parsePlan(raw: string): Plan; export declare function criticSystem(ctx?: PlanContext): string; export interface WeakCite { sentence: string; citedIds: number[]; } export declare function critique(question: string, draftAnswer: string, priorQueries: string[], config: LLMConfig, signal?: AbortSignal, onUsage?: UsageSink, weakCites?: WeakCite[], ctx?: PlanContext): Promise; export declare function parseCritique(raw: string): Critique; //# sourceMappingURL=plan.d.ts.map