import type { Checkpoint } from "../state/checkpointStore.js";
type BaseEvent = {
    step: number;
    nodeId: string;
    scopeName: string;
    moduleId: string;
    stepPath: string;
};
export type NodeEnterEvent = BaseEvent & {
    type: "node-enter";
    nodeName: string;
};
export type NodeExitEvent = BaseEvent & {
    type: "node-exit";
    nodeName: string;
};
export type FunctionEnterEvent = BaseEvent & {
    type: "function-enter";
    functionName: string;
    args: Record<string, any>;
};
export type FunctionExitEvent = BaseEvent & {
    type: "function-exit";
    functionName: string;
    returnValue?: any;
};
export type VariableSetEvent = BaseEvent & {
    type: "variable-set";
    variable: string;
    value: any;
    previousValue: any;
    scope: "local" | "global";
};
export type LlmCallEvent = BaseEvent & {
    type: "llm-call";
    prompt: string;
    response: string;
    toolCalls: Array<{
        name: string;
        arguments: any;
        result?: any;
    }>;
    tokenUsage: {
        inputTokens: number;
        outputTokens: number;
        cachedInputTokens: number;
        totalTokens: number;
    } | null;
};
export type ToolCallEvent = BaseEvent & {
    type: "tool-call";
    toolName: string;
    args: any;
    result: any;
};
export type InterruptThrownEvent = BaseEvent & {
    type: "interrupt-thrown";
    message: string;
};
export type InterruptResolvedEvent = BaseEvent & {
    type: "interrupt-resolved";
    outcome: "approve" | "reject" | "resolve";
    data?: any;
};
export type BranchEvent = BaseEvent & {
    type: "branch";
    condition: "if" | "else" | "while" | "for";
    iteration?: number;
};
export type TraceEvent = NodeEnterEvent | NodeExitEvent | FunctionEnterEvent | FunctionExitEvent | VariableSetEvent | LlmCallEvent | ToolCallEvent | InterruptThrownEvent | InterruptResolvedEvent | BranchEvent;
export declare function makeBaseEvent(checkpoint: Checkpoint, step: number): BaseEvent;
export declare function detectNodeTransitions(prev: Checkpoint | null, curr: Checkpoint, step: number): TraceEvent[];
export declare function detectStackChanges(prev: Checkpoint | null, curr: Checkpoint, step: number): TraceEvent[];
export declare function detectVariableChanges(prev: Checkpoint | null, curr: Checkpoint, step: number): TraceEvent[];
export declare function detectLlmCalls(prev: Checkpoint | null, curr: Checkpoint, step: number): TraceEvent[];
export declare function detectInterrupts(_prev: Checkpoint | null, _curr: Checkpoint, _step: number): TraceEvent[];
export declare function detectBranches(prev: Checkpoint | null, curr: Checkpoint, step: number): TraceEvent[];
export declare function generateEventLog(checkpoints: Checkpoint[]): TraceEvent[];
export {};
