import { z } from "zod"; import type { SprintContract } from "../contracts/sprint-contract.js"; import type { PlanSpec } from "../contracts/spec.js"; export declare const PhaseSchema: z.ZodEnum<["init", "planning", "curating", "generating", "evaluating", "rework", "complete", "failed"]>; export type Phase = z.infer; export declare const HistoryEntrySchema: z.ZodObject<{ timestamp: z.ZodString; event: z.ZodString; phase: z.ZodEnum<["init", "planning", "curating", "generating", "evaluating", "rework", "complete", "failed"]>; sprintId: z.ZodOptional; details: z.ZodRecord; }, "strip", z.ZodTypeAny, { details: Record; timestamp: string; event: string; phase: "complete" | "failed" | "init" | "planning" | "curating" | "generating" | "evaluating" | "rework"; sprintId?: string | undefined; }, { details: Record; timestamp: string; event: string; phase: "complete" | "failed" | "init" | "planning" | "curating" | "generating" | "evaluating" | "rework"; sprintId?: string | undefined; }>; export type HistoryEntry = z.infer; /** * Append a history entry to the JSONL log file. * After appending, triggers rotation if active history exceeds maxActiveLines. * Rotation uses a hardcoded default of 2000 — do NOT call loadConfig here * (loadConfig throws when no bober.config.json exists in test fixtures). */ export declare function appendHistory(projectRoot: string, entry: HistoryEntry): Promise; /** * Load all history entries from both archive (if present) and active JSONL logs. * Returns entries in chronological order: archive (oldest) first, then active (newest). * Skips malformed lines. Signature is unchanged — always returns the full stream. */ export declare function loadHistory(projectRoot: string): Promise; /** * Load at most `limit` of the most-recent history entries from the ACTIVE log only. * Does NOT read from history.archive.jsonl — use loadHistory for the full stream. * Returns entries newest-last (ascending chronological order within the tail). */ export declare function loadRecentHistory(projectRoot: string, { limit }: { limit: number; }): Promise; /** * Update the human-readable progress.md file with current state. */ export declare function updateProgress(projectRoot: string, contracts: SprintContract[], spec: PlanSpec | null): Promise; //# sourceMappingURL=history.d.ts.map