import { Response } from "express";
import { anthropic } from "@ai-sdk/anthropic";
import { deepseek } from "@ai-sdk/deepseek";
import { google } from "@ai-sdk/google";
import { mistral } from "@ai-sdk/mistral";
import { openai } from "@ai-sdk/openai";
import { AssistantModelMessage, SystemModelMessage, ToolModelMessage, UserModelMessage, generateText } from "ai";

//#region src/utils/AI/aiSdk.d.ts
type AnthropicModel = Parameters<typeof anthropic>[0];
type DeepSeekModel = Parameters<typeof deepseek>[0];
type MistralModel = Parameters<typeof mistral>[0];
type OpenAIModel = Parameters<typeof openai>[0];
type GoogleModel = Parameters<typeof google>[0];
type Messages = (SystemModelMessage | UserModelMessage | AssistantModelMessage | ToolModelMessage)[];
/**
 * Supported AI models
 */
type Model = AnthropicModel | DeepSeekModel | MistralModel | OpenAIModel | GoogleModel | (string & {});
/**
 * Supported AI SDK providers
 */
declare enum AIProvider {
  OPENAI = "openai",
  ANTHROPIC = "anthropic",
  MISTRAL = "mistral",
  DEEPSEEK = "deepseek",
  GEMINI = "gemini",
}
/**
 * Common options for all AI providers
 */
type AIOptions = {
  provider?: AIProvider;
  model?: Model;
  temperature?: number;
  apiKey?: string;
  applicationContext?: string;
};
type ChatCompletionRequestMessage = {
  role: 'system' | 'user' | 'assistant';
  content: string;
  timestamp?: Date;
};
type AccessType = 'apiKey' | 'registered_user' | 'premium_user' | 'public';
type AIConfig = Omit<Parameters<typeof generateText>[0], 'prompt'>;
type AIConfigOptions = {
  userOptions?: AIOptions;
  defaultOptions?: AIOptions;
  accessType?: AccessType[];
};
/**
 * Get AI model configuration based on the selected provider and options
 * This function handles the configuration for different AI providers
 *
 * @param options Configuration options including provider, API keys, models and temperature
 * @returns Configured AI model ready to use with generateText
 */
declare const getAIConfig: (res: Response, options: AIConfigOptions) => Promise<AIConfig>;
//#endregion
export { AIConfig, AIConfigOptions, AIOptions, AIProvider, ChatCompletionRequestMessage, Messages, Model, getAIConfig };
//# sourceMappingURL=aiSdk.d.ts.map