/** * Loop orchestrator (ADR-176 phase 8). * * Composes every gate into one pass: * OBSERVE → QUALIFY → BENCHMARK(held-out) → VERIFY(adversarial+drift) * → CANARY → ACCEPT(conjunction) → emit champion manifest. * * $0 + fail-closed by default: with no optimizer/verifier/canary wired, nothing * is promoted and the current signed champion stands. A champion manifest is * emitted ONLY when every accept() term holds — and it is emitted UNSIGNED here; * signing is a separate publish step (scripts/sign-proven-config.mjs, GCP key) * so key material never touches the loop. The daemon worker runs this bounded. */ import { AntiPatternArchive, type Trajectory, type ReplayFn } from './harness-qualification.js'; import { type HarnessBenchmarkCorpus, type EvalFn, type GradeFn, type AcceptResult } from './harness-benchmark.js'; import { type VerifyOptions, type VerifyResult } from './harness-verify.js'; import { type CanaryRunner, type CanaryTelemetry } from './harness-canary.js'; import type { ProvenConfigManifest } from '../config/proven-config.js'; export interface HarnessLoopOptions { trajectories: Trajectory[]; corpus: HarnessBenchmarkCorpus; baseline: C; candidate?: C; evalFn: EvalFn; gradeFn: GradeFn; replay?: ReplayFn; verify?: VerifyOptions; canaryRunner?: CanaryRunner; archive?: AntiPatternArchive; holdoutFrac?: number; driftThreshold?: number; layer?: string; policyRefOf?: (candidate: C) => string; now?: number; } export interface HarnessLoopResult { admitted: number; rejected: number; baselineScore?: number; candidateScore?: number; verify?: VerifyResult; canary?: { candidate: CanaryTelemetry; baseline: CanaryTelemetry; pass: boolean; }; verdict?: AcceptResult; accepted: boolean; manifest?: ProvenConfigManifest; reason: string; } export declare function runHarnessLoop(opts: HarnessLoopOptions): Promise; //# sourceMappingURL=harness-loop.d.ts.map