/** * Resolves relative time expressions to absolute ranges at plan time. * * "How is Bekir's performance going for the last two weeks?" is only answerable * if every worker agrees on what "the last two weeks" means. Left to the model, * each task invents its own window, connector queries disagree, and the run is * unreproducible — re-running tomorrow silently asks a different question. * * So the range is computed once, in code, stamped into the trace, and handed to * the planner as a fact. Resolution is deliberately conservative: an expression * that cannot be resolved unambiguously is left alone rather than guessed at. */ export interface AbsoluteRange { /** Inclusive ISO-8601 start instant. */ since: string; /** Exclusive ISO-8601 end instant. */ until: string; /** The phrase this range was derived from. */ phrase: string; days: number; } export interface TemporalContext { /** The instant the run treats as "now". */ now: string; range?: AbsoluteRange; } /** * Extracts an absolute range from a query. Returns undefined when the query * contains no relative time expression, or one we cannot resolve confidently — * a wrong window is worse than no window, because it looks authoritative. */ export declare const resolveRelativeRange: (query: string, now?: Date) => AbsoluteRange | undefined; export declare const buildTemporalContext: (query: string, now?: Date) => TemporalContext; /** The lines handed to the planner so every task shares one window. */ export declare const renderTemporalContext: (context: TemporalContext) => string[]; //# sourceMappingURL=TemporalContext.d.ts.map