/** * `/api/v1/testing/default-evals*` (DES-DEFAULT-EVALS-001 ยง7): run the default evals over this daemon's own run * store, per project or across projects, and read the history. * * GET /testing/default-evals/suites what each suite checks, and whether crew can replay it * POST /testing/default-evals/run {project?: string | "all", suites?: SuiteId[], baseline?: boolean} * GET /testing/default-evals the history, newest first * GET /testing/default-evals/:id one run's report and its cases * * Everything is read from the run store (sessions, events, decisions, QE ledgers, the latest steering eval); the * only write is the report itself, under `/evals/default/`. */ import type { FastifyInstance } from 'fastify'; import type { EvalRunStore } from '../api/eval-store.js'; import { type DecisionLike, type EventLike, type RunLike } from './capture.js'; import type { ReplaySet } from './replay.js'; import type { DefaultEvalStore } from './store.js'; import { type DefaultEvalReport, type EvalCase, type SuiteId } from './types.js'; export interface DefaultEvalDeps { /** Where runs are kept. Absent (a directly-driven route set): a run is computed and answered, never stored. */ store?: DefaultEvalStore; /** Every run with its units (`adapter.sessionsDetail()`). */ runs: () => Promise; /** One run's recorded events (`adapter.runEvents(id)`); `null` when the engine predates the binding. */ events: (runId: string) => Promise; /** The operator's gate decisions (the decision ledger); empty when decision capture is off. */ decisions: () => DecisionLike[]; /** The steering evals' run history, for S5. */ steeringEvals?: EvalRunStore; replay: ReplaySet; now?: () => Date; newId?: () => string; } /** The cases this daemon's own store yields right now (and the baseline, when asked for). */ export declare function gatherCases(deps: DefaultEvalDeps, opts: { baseline: boolean; }): Promise; /** Run the default evals over this daemon's store and keep the report: the one path the route, the `run-evals` * workflow's launch and the schedule share. */ export declare function runAndRecord(deps: DefaultEvalDeps, opts: { project: string | null; baseline: boolean; suites?: SuiteId[]; id: string; now: Date; }): Promise; export declare function registerDefaultEvalRoutes(app: FastifyInstance, deps: DefaultEvalDeps): void; //# sourceMappingURL=routes.d.ts.map