import { BalanceUpdateResult } from './BalanceService.js';
export type SessionType = 'chat' | 'compare' | 'brains' | 'models';
export interface BaseSessionData {
    userId: string;
    apiKeyId: string;
    clientMetadata?: {
        ipAddress?: string;
        userAgent?: string;
        requestId?: string;
    };
}
export interface ModelInteractionData {
    modelId: string;
    provider: string;
    modelName?: string;
    timeStarted?: Date;
    timeCompleted?: Date;
    latency: number;
    inputTokens: number;
    outputTokens: number;
    thinkingTokens?: number;
    totalTokens?: number;
    tokensUsed?: number;
    cost: number;
    inputCost?: number;
    outputCost?: number;
    thinkingCost?: number;
    temperature?: number;
    maxTokens?: number;
    reasoningEffort?: string;
    success: boolean;
    errorMessage?: string | undefined;
    errorType?: string;
    fullResponse?: string;
    webSearchEnabled?: boolean;
    webSearchUsed?: boolean;
    webSearchResults?: any[];
    reasoningUsed?: boolean;
    webSearch?: boolean;
    reasoning?: boolean;
    maxContextTokens?: number;
    latencySpeed?: string;
    timestamp?: string;
    requestMetadata?: any;
}
export declare class SessionService {
    private static instance;
    private ChatSessionModel;
    private CompareSessionModel;
    private BrainsSessionModel;
    private ModelsSessionModel;
    private constructor();
    static getInstance(): SessionService;
    initialize(): Promise<void>;
    createSession(type: SessionType, baseData: BaseSessionData, requestData: any): Promise<string>;
    addModelInteraction(sessionId: string, type: SessionType, interactionData: ModelInteractionData): Promise<void>;
    updateSessionCost(sessionId: string, type: SessionType, totalCost: number): Promise<void>;
    updateSessionBalance(sessionId: string, type: SessionType, balanceResult: BalanceUpdateResult): Promise<void>;
    private calculateAggregatedStats;
    completeSession(sessionId: string, type: SessionType, duration: number, status?: 'success' | 'partial' | 'error' | 'timeout'): Promise<void>;
    getSession(sessionId: string, type: SessionType): Promise<any>;
    getUserSessions(userId: string, type?: SessionType, limit?: number, skip?: number): Promise<any[]>;
    getSessionAnalytics(userId: string, days?: number): Promise<any>;
    private getModelByType;
}
export declare const sessionService: SessionService;
//# sourceMappingURL=SessionService.d.ts.map