import type { BaseGrader } from "./baseGrader.js"; import type { AgentRun, Grade, Input } from "./types.js"; export type GraderGrade = { grader: BaseGrader; grade: Grade; }; export type InputGrades = { input: Input; run: AgentRun; grades: GraderGrade[]; gatesPassed: boolean; }; /** * Weighted mean of every grade for one input: a scalar grade contributes its * value, a binary grade contributes 1.0 (pass) or 0.0 (fail). `mustPass` is an * orthogonal gate (a failed gate zeroes the whole input via the Scorecard); it * does not change whether a grade contributes here. An input with no grades * scores 0. */ export declare function inputObjective(grades: GraderGrade[]): number; /** Per-candidate grading result: per-input grades plus derived gate/objective readouts. */ export declare class Scorecard { readonly perInput: InputGrades[]; constructor(perInput: InputGrades[]); gatesPassed(): boolean; /** Per-input objective; a gate-failed input scores 0. */ inputScores(): number[]; objective(): number; /** The canonical gate-aware comparison score: the raw objective when every * `mustPass` gate is satisfied, otherwise 0. This is what every optimizer * uses to compare candidates, and what `OptimizeResult.trainObjective` and * `baselineObjective` report. Prefer this over inlining * `s.gatesPassed() ? s.objective() : 0`. */ gatedObjective(): number; }