import type Anthropic from '@anthropic-ai/sdk'; import type { AnthropicInput } from '@langchain/anthropic'; import type { ChatBedrockConverseInput } from '@langchain/aws'; import type { ChatOpenAIFields } from '@langchain/openai'; import type OpenAI from 'openai'; export type ChatCompletionResponse = OpenAI.Chat.Completions.ChatCompletion; export type ChatCompletionMessage = OpenAI.Chat.Completions.ChatCompletionMessageParam; export type ChatCompletionTool = OpenAI.Chat.Completions.ChatCompletionTool; export type ChatCompletionToolChoice = OpenAI.Chat.Completions.ChatCompletionToolChoiceOption; export type AiProvider = 'openai' | 'anthropic' | 'bedrock'; /** * Base configuration common to all AI providers. */ export type BaseAiConfiguration = { name: string; provider: AiProvider; model: string; apiKey?: string; }; /** * OpenAI-specific configuration. * Extends base with all ChatOpenAI options (temperature, maxTokens, configuration, etc.) */ export type OpenAiConfiguration = Omit & Omit & { provider: 'openai'; model: OpenAI.ChatModel | (string & NonNullable); }; /** * Anthropic-specific configuration. * Extends base with all ChatAnthropic options (temperature, maxTokens, etc.) * Supports both `apiKey` (unified) and `anthropicApiKey` (native) for flexibility. */ export type AnthropicConfiguration = Omit & Omit & { provider: 'anthropic'; model: Anthropic.Messages.Model; }; export type BedrockConfiguration = Omit & Omit & { provider: 'bedrock'; model: string; }; export type AiConfiguration = OpenAiConfiguration | AnthropicConfiguration | BedrockConfiguration; //# sourceMappingURL=provider.d.ts.map