/**
 * ADR-PIPELINE-066: Unit Economics Loader
 *
 * Reads `.agentics/runs/<run-id>/unit-economics.json` (or a caller-supplied
 * directory) and returns a Zod-validated UnitEconomics record. Falls back to
 * null when the file is absent or invalid — callers decide whether to use the
 * heuristic fallback or throw.
 */
import { type UnitEconomics } from '../pipeline/types.js';
export interface LoadUnitEconomicsResult {
    readonly manifest: UnitEconomics | null;
    /** Absolute path inspected, even when the file was missing. Useful for logs. */
    readonly inspectedPath: string | null;
    readonly reason: 'loaded' | 'missing' | 'invalid-json' | 'schema-rejected';
    readonly error?: string;
}
/**
 * Load the unit-economics manifest for a run.
 *
 * Search order:
 *   1. `<runDir>/unit-economics.json`
 *   2. `<runDir>/artifacts/unit-economics.json`
 *
 * Returns {manifest: null} for any missing/invalid case. This function never
 * throws — the 3-tier precedence in renderFinancialAnalysis relies on a
 * permissive contract.
 */
export declare function loadUnitEconomics(runDir: string | null | undefined): LoadUnitEconomicsResult;
export interface UnitEconomicsFinancialModel {
    readonly budget: string;
    readonly roi: string;
    readonly npv: string;
    readonly payback: string;
    readonly revenue: string;
    readonly costSavings: string;
    readonly methodology: string;
    /** Scope ratio used for extrapolation (enterprise / measured). */
    readonly scopeRatio: number;
}
/**
 * Derive the FinancialData fields the executive renderer needs from a
 * unit-economics manifest. Uses the manifest's own numbers — no heuristic
 * substitution.
 */
export declare function buildFinancialModelFromUnitEconomics(manifest: UnitEconomics): UnitEconomicsFinancialModel;
export declare class UnitEconomicsConsistencyError extends Error {
    readonly code: string;
    constructor(message: string, code?: string);
}
export interface ConsistencyCheckResult {
    readonly passed: boolean;
    readonly violations: string[];
}
/**
 * Verify that numbers derived from the manifest still match the manifest
 * within tolerance. Used right before we emit a document so drift between
 * the manifest and the printed prose is caught.
 */
export declare function verifyManifestConsistency(manifest: UnitEconomics, printed: {
    measuredSavingsUsd?: number;
    enterpriseSavingsUsd?: number;
}, tolerancePct?: number): ConsistencyCheckResult;
/**
 * Entrypoint used by the renderer: run the check, then either throw (strict
 * mode) or return the violations for a soft warning.
 */
export declare function enforceManifestConsistency(manifest: UnitEconomics, printed: {
    measuredSavingsUsd?: number;
    enterpriseSavingsUsd?: number;
}): ConsistencyCheckResult;
//# sourceMappingURL=unit-economics-loader.d.ts.map