/** * AI Provider Router * * Centralized routing between Ollama (local/dev) and Vercel AI Gateway (production). * * Environment-based routing: * - AI_RUNTIME=vercel-gateway OR (VERCEL && NODE_ENV=production) -> Vercel AI Gateway * - Else -> Ollama * * Models: * - Ticket/Planning: 14B general model (OLLAMA_TICKET_MODEL, defaults to qwen2.5:14b) * - Code generation: Coder model (OLLAMA_CODE_MODEL, defaults to qwen2.5-coder:latest) */ export type AIIntent = 'ticket' | 'code' | 'demo'; export interface AIModelClient { /** * Generate text completion */ generate(prompt: string, options?: { systemPrompt?: string; temperature?: number; maxTokens?: number; }): Promise; /** * Generate chat completion (with messages array) */ chat(messages: Array<{ role: 'system' | 'user' | 'assistant'; content: string; }>, options?: { temperature?: number; maxTokens?: number; }): Promise; /** * Get the model name being used */ getModel(): string; /** * Get the provider name (ollama | vercel-gateway) */ getProvider(): string; } /** * Determine which AI runtime to use */ export declare function getAIRuntime(): 'ollama' | 'vercel-gateway'; /** * Get AI client for ticket/planning work (14B general model) */ export declare function getTicketModelClient(): Promise; /** * Get AI client for code generation work (coder model) */ export declare function getCodeModelClient(): Promise; /** * Get AI client for demo work (uses ticket model by default) */ export declare function getDemoModelClient(): Promise; /** * Get AI client by intent */ export declare function getModelClientByIntent(intent: AIIntent): Promise; //# sourceMappingURL=provider.d.ts.map