/** * OpenRouter LLM adapter * * OpenRouter provides access to many models through a single API: * - OpenAI (GPT-4, GPT-3.5) * - Anthropic (Claude) * - Google (Gemini, PaLM) * - Meta (Llama) * - Mistral * - And many more * * @packageDocumentation */ import type { LLMProvider, OpenRouterConfig, CompletionRequest, CompletionResponse } from '../../types/llm.js'; import { BaseLLMAdapter } from './base.js'; /** * Popular models available on OpenRouter */ export declare const OPENROUTER_MODELS: { readonly 'openai/gpt-4o': "openai/gpt-4o"; readonly 'openai/gpt-4-turbo': "openai/gpt-4-turbo"; readonly 'openai/gpt-3.5-turbo': "openai/gpt-3.5-turbo"; readonly 'anthropic/claude-3.5-sonnet': "anthropic/claude-3.5-sonnet"; readonly 'anthropic/claude-3-opus': "anthropic/claude-3-opus"; readonly 'anthropic/claude-3-haiku': "anthropic/claude-3-haiku"; readonly 'google/gemini-pro': "google/gemini-pro"; readonly 'google/gemini-pro-1.5': "google/gemini-pro-1.5"; readonly 'meta-llama/llama-3.1-70b-instruct': "meta-llama/llama-3.1-70b-instruct"; readonly 'meta-llama/llama-3.1-8b-instruct': "meta-llama/llama-3.1-8b-instruct"; readonly 'mistralai/mistral-large': "mistralai/mistral-large"; readonly 'mistralai/mistral-medium': "mistralai/mistral-medium"; readonly 'mistralai/mixtral-8x7b-instruct': "mistralai/mixtral-8x7b-instruct"; readonly 'deepseek/deepseek-chat': "deepseek/deepseek-chat"; readonly 'deepseek/deepseek-coder': "deepseek/deepseek-coder"; readonly 'qwen/qwen-2.5-72b-instruct': "qwen/qwen-2.5-72b-instruct"; }; /** * Adapter for OpenRouter API * * OpenRouter provides unified access to 100+ models from various providers. * See https://openrouter.ai/docs for full documentation. */ export declare class OpenRouterAdapter extends BaseLLMAdapter { private readonly baseUrl; private readonly siteUrl?; private readonly appName?; constructor(config: OpenRouterConfig); get provider(): LLMProvider; complete(request: CompletionRequest): Promise; private buildRequest; private executeRequest; private parseResponse; } /** * Create an OpenRouter adapter from environment variables */ export declare function createOpenRouterAdapter(model?: string, overrides?: Partial): OpenRouterAdapter; //# sourceMappingURL=openrouter.d.ts.map