export interface BudgetTrackerStepConfig {
    stepName: string;
    agentName: string;
    maxTokens?: number;
}
export interface BudgetTrackerOptions {
    perAgent?: number;
    perWorkflow?: number;
    workflowBudget?: number;
    steps?: BudgetTrackerStepConfig[];
}
export interface TokenUsage {
    input: number;
    output: number;
    cacheRead: number;
    total: number;
}
export interface BudgetAvailability {
    allowed: boolean;
    reason?: string;
}
export interface OverBudgetResult {
    over: boolean;
    reason?: string;
}
export interface BudgetStatus {
    agentLimitExceeded: boolean;
    workflowBudgetExceeded: boolean;
    workflowBudgetExhausted: boolean;
}
export interface StepBudgetStatus {
    used?: number;
    limit?: number;
    over: boolean;
}
export interface WorkflowBudgetStatus {
    used: number;
    limit?: number;
    exhausted: boolean;
}
export interface RunSummaryBudgetData {
    steps: Map<string, StepBudgetStatus>;
    workflow?: WorkflowBudgetStatus;
}
export declare class BudgetExceededError extends Error {
    readonly stepName: string;
    readonly budgetType: 'agent' | 'workflow';
    readonly limit: number;
    readonly actual: number;
    readonly used: number;
    constructor(stepName: string, budgetType: 'agent' | 'workflow', limit: number, actual: number);
}
export declare class BudgetTracker {
    private readonly defaultAgentBudget?;
    private readonly workflowBudget?;
    private readonly stepLimits;
    private readonly stepUsage;
    private totalUsage;
    private workflowBudgetExhausted;
    constructor(options: BudgetTrackerOptions);
    recordUsage(stepName: string, usage: number | Partial<Omit<TokenUsage, 'total'>>): void;
    getStepUsage(stepName: string): TokenUsage;
    getTotalUsage(): TokenUsage;
    getRemainingBudget(): {
        agent?: number;
        workflow?: number;
    };
    checkCanSpawn(stepName: string): BudgetAvailability;
    isOverBudget(stepName: string): OverBudgetResult;
    getBudgetStatus(stepName: string): BudgetStatus;
    getStepBudgetStatus(stepName: string): StepBudgetStatus | undefined;
    getRunSummaryBudgetData(): RunSummaryBudgetData | undefined;
    private getStepLimit;
}
//# sourceMappingURL=budget-tracker.d.ts.map