|
| 1 | +import type { ModelInfo } from "../model.js" |
| 2 | + |
| 3 | +// https://ai-gateway.vercel.sh/v1/ |
| 4 | +export const vercelAiGatewayDefaultModelId = "anthropic/claude-sonnet-4" |
| 5 | + |
| 6 | +export const VERCEL_AI_GATEWAY_PROMPT_CACHING_MODELS = new Set([ |
| 7 | + "anthropic/claude-3-haiku", |
| 8 | + "anthropic/claude-3-opus", |
| 9 | + "anthropic/claude-3.5-haiku", |
| 10 | + "anthropic/claude-3.5-sonnet", |
| 11 | + "anthropic/claude-3.7-sonnet", |
| 12 | + "anthropic/claude-opus-4", |
| 13 | + "anthropic/claude-opus-4.1", |
| 14 | + "anthropic/claude-sonnet-4", |
| 15 | + "openai/gpt-4.1", |
| 16 | + "openai/gpt-4.1-mini", |
| 17 | + "openai/gpt-4.1-nano", |
| 18 | + "openai/gpt-4o", |
| 19 | + "openai/gpt-4o-mini", |
| 20 | + "openai/gpt-5", |
| 21 | + "openai/gpt-5-mini", |
| 22 | + "openai/gpt-5-nano", |
| 23 | + "openai/o1", |
| 24 | + "openai/o3", |
| 25 | + "openai/o3-mini", |
| 26 | + "openai/o4-mini", |
| 27 | +]) |
| 28 | + |
| 29 | +export const VERCEL_AI_GATEWAY_VISION_ONLY_MODELS = new Set([ |
| 30 | + "alibaba/qwen-3-14b", |
| 31 | + "alibaba/qwen-3-235b", |
| 32 | + "alibaba/qwen-3-30b", |
| 33 | + "alibaba/qwen-3-32b", |
| 34 | + "alibaba/qwen3-coder", |
| 35 | + "amazon/nova-pro", |
| 36 | + "anthropic/claude-3.5-haiku", |
| 37 | + "google/gemini-1.5-flash-8b", |
| 38 | + "google/gemini-2.0-flash-thinking", |
| 39 | + "google/gemma-3-27b", |
| 40 | + "mistral/devstral-small", |
| 41 | + "xai/grok-vision-beta", |
| 42 | +]) |
| 43 | + |
| 44 | +export const VERCEL_AI_GATEWAY_VISION_AND_TOOLS_MODELS = new Set([ |
| 45 | + "amazon/nova-lite", |
| 46 | + "anthropic/claude-3-haiku", |
| 47 | + "anthropic/claude-3-opus", |
| 48 | + "anthropic/claude-3-sonnet", |
| 49 | + "anthropic/claude-3.5-sonnet", |
| 50 | + "anthropic/claude-3.7-sonnet", |
| 51 | + "anthropic/claude-opus-4", |
| 52 | + "anthropic/claude-opus-4.1", |
| 53 | + "anthropic/claude-sonnet-4", |
| 54 | + "google/gemini-1.5-flash", |
| 55 | + "google/gemini-1.5-pro", |
| 56 | + "google/gemini-2.0-flash", |
| 57 | + "google/gemini-2.0-flash-lite", |
| 58 | + "google/gemini-2.0-pro", |
| 59 | + "google/gemini-2.5-flash", |
| 60 | + "google/gemini-2.5-flash-lite", |
| 61 | + "google/gemini-2.5-pro", |
| 62 | + "google/gemini-exp", |
| 63 | + "meta/llama-3.2-11b", |
| 64 | + "meta/llama-3.2-90b", |
| 65 | + "meta/llama-3.3", |
| 66 | + "meta/llama-4-maverick", |
| 67 | + "meta/llama-4-scout", |
| 68 | + "mistral/pixtral-12b", |
| 69 | + "mistral/pixtral-large", |
| 70 | + "moonshotai/kimi-k2", |
| 71 | + "openai/gpt-4-turbo", |
| 72 | + "openai/gpt-4.1", |
| 73 | + "openai/gpt-4.1-mini", |
| 74 | + "openai/gpt-4.1-nano", |
| 75 | + "openai/gpt-4.5-preview", |
| 76 | + "openai/gpt-4o", |
| 77 | + "openai/gpt-4o-mini", |
| 78 | + "openai/gpt-oss-120b", |
| 79 | + "openai/gpt-oss-20b", |
| 80 | + "openai/o3", |
| 81 | + "openai/o3-pro", |
| 82 | + "openai/o4-mini", |
| 83 | + "vercel/v0-1.0-md", |
| 84 | + "xai/grok-2-vision", |
| 85 | + "zai/glm-4.5v", |
| 86 | +]) |
| 87 | + |
| 88 | +export const vercelAiGatewayDefaultModelInfo: ModelInfo = { |
| 89 | + maxTokens: 64000, |
| 90 | + contextWindow: 200000, |
| 91 | + supportsImages: true, |
| 92 | + supportsComputerUse: true, |
| 93 | + supportsPromptCache: true, |
| 94 | + inputPrice: 3, |
| 95 | + outputPrice: 15, |
| 96 | + cacheWritesPrice: 3.75, |
| 97 | + cacheReadsPrice: 0.3, |
| 98 | + description: |
| 99 | + "Claude Sonnet 4 significantly improves on Sonnet 3.7's industry-leading capabilities, excelling in coding with a state-of-the-art 72.7% on SWE-bench. The model balances performance and efficiency for internal and external use cases, with enhanced steerability for greater control over implementations. While not matching Opus 4 in most domains, it delivers an optimal mix of capability and practicality.", |
| 100 | +} |
| 101 | + |
| 102 | +export const VERCEL_AI_GATEWAY_DEFAULT_TEMPERATURE = 0.7 |
0 commit comments