/**
 * Artifact validators.
 *
 * Generic "score a produced artifact" primitive. Tax uses it for PDF form
 * correctness, research for sourced briefs, browser for task assertions, coding
 * for social posts. One interface, many validators; all plug into
 * `BenchmarkRunner` the same way.
 *
 * A validator receives an `Artifact` (file on disk, JSON blob, text, binary)
 * plus a `ValidationContext` (scenario id, the turns that produced it) and
 * returns a `ValidationResult` with pass/fail + 0..1 score + structured
 * issues.
 */
export interface Artifact {
    /** Logical kind — validators type-guard on this */
    kind: 'file' | 'json' | 'text' | 'binary' | string;
    /** Filesystem-style path, optional */
    path?: string;
    /** String content for text/json/file kinds */
    content?: string;
    /** Binary content (if kind === 'binary') */
    bytes?: Uint8Array;
    /** Caller-supplied metadata (mimeType, sha256, size, etc.) */
    metadata?: Record<string, unknown>;
}
export interface ValidationContext {
    scenarioId: string;
    turnIndex?: number;
    /** Prior artifacts for multi-artifact scenarios */
    priorArtifacts?: Artifact[];
    /** Free-form hints the validator uses for domain-specific checks */
    hints?: Record<string, unknown>;
}
export interface ValidationIssue {
    severity: 'error' | 'warning' | 'info';
    message: string;
    /** Optional path into the artifact (e.g. JSON path or byte offset) */
    locus?: string;
}
export interface ValidationResult {
    pass: boolean;
    /** 0–1 normalized score. Validators should be monotonic in pass-ness. */
    score: number;
    issues: ValidationIssue[];
    /** Diagnostic payload for reporters */
    evidence?: Record<string, unknown>;
}
export interface ArtifactValidator {
    /** Stable identifier for the validator; appears in reports. */
    name: string;
    /** Optional description for human-facing reports. */
    description?: string;
    /** Called once per artifact; validators are expected to be pure + idempotent. */
    validate(artifact: Artifact, context: ValidationContext): Promise<ValidationResult>;
}
/**
 * Run every validator on the same artifact; aggregate pass as AND, score as
 * (weighted) mean, issues concatenated. Weights default to 1 each.
 */
export declare function composeValidators(validators: ArtifactValidator[], options?: {
    name?: string;
    weights?: number[];
}): ArtifactValidator;
/** Pass if the artifact body matches a provided regex. */
export declare function regexMatch(name: string, pattern: RegExp): ArtifactValidator;
/** Pass if JSON parses and every required key is present. */
export declare function jsonHasKeys(name: string, requiredPaths: string[]): ArtifactValidator;
/** Pass if min ≤ byte length ≤ max. */
export declare function byteLengthRange(name: string, min: number, max: number): ArtifactValidator;
/** Pass if the artifact contains every required substring (case-insensitive by default). */
export declare function containsAll(name: string, required: string[], options?: {
    caseSensitive?: boolean;
}): ArtifactValidator;
//# sourceMappingURL=artifact-validator.d.ts.map