export interface ToolCallRecord {
    id: number;
    tool: string;
    args: string;
    result: string;
    status: 'ok' | 'error';
    duration_ms: number;
    tokens: number;
    timestamp: number;
}
export interface TelemetryFilter {
    tool?: string;
    status?: 'ok' | 'error';
    since?: number;
    until?: number;
    limit?: number;
}
export interface TelemetrySummary {
    total_calls: number;
    total_tokens: number;
    total_errors: number;
    total_duration_ms: number;
    by_tool: Record<string, {
        calls: number;
        tokens: number;
        errors: number;
        avg_duration_ms: number;
    }>;
}
export declare class TelemetryDB {
    private readonly store;
    constructor(dbPath?: string);
    init(): Promise<void>;
    recordToolCall(tool: string, args: Record<string, unknown>, result: Record<string, unknown>, duration: number, tokens: number): void;
    query(filter?: TelemetryFilter): ToolCallRecord[];
    getSummary(): TelemetrySummary;
    export(format?: 'json' | 'csv'): string;
    save(): Promise<boolean>;
    close(): void;
    get isReady(): boolean;
}
//# sourceMappingURL=telemetry.d.ts.map