import { AIClient, AIClientOptions, AgentContext } from "../../interfaces/AIClient";
import { LivingContext } from "../../types/living-context";
export type AIProviderName = "github" | "openrouter" | "gemini" | "xai" | "claude" | "qwen";
export interface AICoreConfig {
    preferredProvider?: AIProviderName;
    fallbackEnabled: boolean;
    workingDirectory: string;
}
/**
 * AICore: The centralized logic for AI provider selection,
 * token injection, and unified interface for all agents.
 */
export declare class AICore {
    private static instance;
    private providers;
    private config;
    private static exhaustedModels;
    private constructor();
    static getInstance(config?: AICoreConfig): AICore;
    private loadEnvironmentVariables;
    refreshProviders(): void;
    /**
     * Force a complete refresh of environment variables and providers.
     * Useful when you need to ensure the latest .env values are loaded.
     */
    forceRefresh(): void;
    /**
     * Check if any AI provider has a valid key configured
     */
    hasAnyProvider(): boolean;
    getClient(name: AIProviderName): AIClient | undefined;
    getBestClient(): AIClient;
    /**
     * High-level generation utility that handles formatting and basic retries
     */
    generateStructuredText<T>(prompt: string, schema: string, options?: AIClientOptions): Promise<T>;
    /**
     * Record token usage to the Brain — fire-and-forget (never blocks generation)
     */
    private recordUsage;
    /**
     * Proxy for generateText with automatic fallback and circuit breaking
     */
    generateText(prompt: string, options?: AIClientOptions): Promise<string>;
    /**
     * Proxy for generateVisionText with automatic fallback
     */
    generateVisionText(prompt: string, imagePath: string, options?: AIClientOptions): Promise<string>;
    /**
     * Proxy for generateImage
     */
    generateImage(prompt: string, outputPath: string, options?: AIClientOptions): Promise<string>;
    private getAvailableClients;
    private getVisionClients;
    generateComponent(prompt: string, context?: AgentContext, options?: AIClientOptions): Promise<string>;
    generateComponentRefinement(componentCode: string, prompt: string, context?: AgentContext, options?: AIClientOptions): Promise<string>;
    getLivingContext(): Promise<LivingContext | null>;
    saveLivingContext(context: any): Promise<void>;
    updateLivingContext(updates: any): Promise<void>;
}
//# sourceMappingURL=AICore.d.ts.map