# RubyLLM Documentation > Developer documentation for RubyLLM, a Ruby library for building AI applications with chat, agents, tools, embeddings, image generation, audio transcription, moderation, streaming, and Rails integration. ## About RubyLLM is one consistent Ruby framework for chat, image generation, embeddings, transcription, moderation, tools, agents, structured output, streaming, and Rails integration across OpenAI, Anthropic, Gemini, Bedrock, DeepSeek, Mistral, Ollama, OpenRouter, Perplexity, GPUStack, xAI, and OpenAI-compatible providers. ## Key Topics - Ruby - Ruby on Rails - Large language models - AI agents - Retrieval augmented generation - Function calling - Structured output - Vector embeddings - Streaming AI responses - Multi-modal AI - OpenAI - Anthropic Claude - Google Gemini - AWS Bedrock - DeepSeek - Mistral AI - xAI - OpenRouter - Perplexity - Ollama - Vertex AI - GPUStack - OpenAI-compatible APIs ## Canonical Resources - Documentation: https://rubyllm.com - Source code: https://github.com/crmne/ruby_llm - RubyGems package: https://rubygems.org/gems/ruby_llm ## Primary Topics RubyLLM covers provider-agnostic AI application development in Ruby, including OpenAI, Anthropic, Gemini, Bedrock, DeepSeek, Mistral, Ollama, OpenRouter, Perplexity, GPUStack, xAI, OpenAI-compatible APIs, agents, tools, structured output, embeddings, image generation, audio transcription, moderation, streaming, Rails integration, async workloads, model registry usage, and upgrade guidance. ## Getting Started ### Getting Started URL: https://rubyllm.com/getting-started/ Date: 2026-08-08 # Getting Started {: .no_toc } Start building AI apps in Ruby in 5 minutes. Chat, generate images, create embeddings - all with one gem. {: .fs-6 .fw-300 } ## Table of contents {: .no_toc .text-delta } 1. TOC {:toc} --- After reading this guide, you will know: * How to install RubyLLM. * How to perform minimal configuration. * How to start a simple chat conversation. * How to generate an image. * How to create a text embedding. ## Installation Add RubyLLM to your Gemfile: ```ruby bundle add ruby_llm ``` ### Rails Quick Setup For Rails applications, you can use the generator to set up database-backed conversations: ```bash bin/rails generate ruby_llm:install ``` This creates Chat and Message models with ActiveRecord persistence. Your conversations will be automatically saved to the database. ### Adding a Chat UI After running the install generator, you can optionally add a ready-to-use chat interface: ```bash bin/rails generate ruby_llm:chat_ui ``` This creates: - Controllers for managing chats and messages - Views with Turbo streaming for real-time updates - Background job for processing AI responses - Routes for the chat interface Then visit `http://localhost:3000/chats` to start chatting! See the [Rails Integration Guide](/rails/) for full details. ## Minimal Configuration RubyLLM needs API keys for the AI providers you want to use. Configure them once, typically when your application starts. ```ruby # config/initializers/ruby_llm.rb (in Rails) or at the start of your script require 'ruby_llm' RubyLLM.configure do |config| # Add keys ONLY for the providers you intend to use. # Using environment variables is highly recommended. config.openai_api_key = ENV.fetch('OPENAI_API_KEY', nil) # config.anthropic_api_key = ENV.fetch('ANTHROPIC_API_KEY', nil) end ``` > You only need to configure keys for the providers you actually plan to use. See the [Configuration Guide](/configuration/) for all options, including setting defaults and connecting to custom endpoints. {: .note } ## Your First Chat Interact with language models using `RubyLLM.chat`. ```ruby # Create a chat instance (uses the configured default model) chat = RubyLLM.chat # Ask a question response = chat.ask "What is Ruby on Rails?" # The response is a RubyLLM::Message object puts response.content # => "Ruby on Rails, often shortened to Rails, is a server-side web application..." ``` RubyLLM handles the conversation history automatically. See the [Chatting with AI Models Guide](/chat/) for more details. ## Generating an Image Generate images using models like DALL-E 3 via `RubyLLM.paint`. ```ruby # Generate an image (uses the default image model) image = RubyLLM.paint("A photorealistic red panda coding Ruby") # Access the image URL (or Base64 data depending on provider) if image.url puts image.url # => "https://oaidalleapiprodscus.blob.core.windows.net/..." else puts "Image data received (Base64)." end # Save the image locally image.save("red_panda.png") ``` Learn more in the [Image Generation Guide](/image-generation/). ## Creating an Embedding Create numerical vector representations of text using `RubyLLM.embed`. ```ruby # Create an embedding (uses the default embedding model) embedding = RubyLLM.embed("Ruby is optimized for programmer happiness.") # Access the vector (an array of floats) vector = embedding.vectors puts "Vector dimension: #{vector.length}" # e.g., 1536 # Access metadata puts "Model used: #{embedding.model}" ``` Explore further in the [Embeddings Guide](/embeddings/). ## What's Next? You've covered the basics! Now you're ready to explore RubyLLM's features in more detail: * [Chatting with AI Models](/chat/) * [Working with Models](/models/) (Choosing models, custom endpoints) * [Using Tools](/tools/) (Letting AI call your code) * [Streaming Responses](/streaming/) * [Rails Integration](/rails/) * [Configuration](/configuration/) * [Error Handling](/error-handling/) --- ### Overview URL: https://rubyllm.com/overview/ Date: 2026-08-08 # Overview {: .no_toc } Understand how RubyLLM works and how its components fit together {: .fs-6 .fw-300 } ## Table of contents {: .no_toc .text-delta } 1. TOC {:toc} --- After reading this guide, you will know: * How RubyLLM provides a unified interface to multiple AI providers * The core components and how they work together * The design principles that guide the framework * How providers are implemented and extended * The role of configuration in managing complexity ## Core Components RubyLLM consists of several core components that work together to provide its functionality. Understanding these components will help you use the framework more effectively. ### Chat The Chat component is the primary interface for conversational AI. When you create a chat instance with `RubyLLM.chat`, you're creating an object that manages a conversation with an AI model. ```ruby chat = RubyLLM.chat(model: "gpt-5-nano") ``` The chat object maintains conversation history, handles message formatting for the specific provider, and manages the request/response cycle. Each provider implements its own chat adapter that translates between RubyLLM's unified format and the provider's specific API requirements. ### Messages Messages are the fundamental unit of conversation in RubyLLM. Each message has a role (user, assistant, system, or tool) and content (text, images, or other data). The framework automatically manages message history and formatting. ```ruby response = chat.ask("What is Ruby?") # Creates a user message, sends it, and returns an assistant message ``` Messages can include various types of content depending on the model's capabilities. Vision-capable models can process images, while some models support audio or document analysis. ### Tools Tools allow AI models to call Ruby code during conversations. This powerful feature enables AI assistants to perform calculations, fetch data, or interact with external systems. ```ruby class Calculator < RubyLLM::Tool desc "Performs basic arithmetic" def execute(expression:) { result: eval(expression) } end end ``` When you provide tools to a chat, the AI model can decide when to use them based on the conversation context. The framework handles the complexity of tool calling protocols across different providers. ### Providers Providers are the adapters that connect RubyLLM to specific AI services. Each provider implements the same interface but handles the unique requirements of its service - authentication, request formatting, response parsing, and streaming protocols. The provider system allows RubyLLM to support many different AI services while maintaining a consistent interface. Whether you're using OpenAI, Anthropic, or a local model, your code stays the same. New providers can be added without changing the core framework. ### Configuration Configuration in RubyLLM works at three levels: global defaults, isolated contexts for multi-tenancy, and instance-specific settings. ```ruby # Global configuration - applies everywhere RubyLLM.configure do |config| config.openai_api_key = ENV["OPENAI_API_KEY"] config.default_model = "gpt-5-nano" end # Context configuration - isolated scope context = RubyLLM.context do |config| config.openai_api_key = tenant.api_key # Different credentials config.default_model = "gpt-5.4" # Different defaults end chat = context.chat # Uses context configuration # Instance configuration - what you need right now chat = RubyLLM.chat(model: "claude-opus-4-6", temperature: 0.7) ``` This layered approach supports everything from simple scripts to complex multi-tenant applications. ## Design Principles RubyLLM follows several key design principles that shape its architecture and API design. ### Provider Agnostic The framework treats all AI providers equally. Whether you're using OpenAI, Anthropic, or a local model through Ollama, the code looks the same. This principle extends to all features - chat, embeddings, image generation, and tools all work consistently across providers. ### Progressive Disclosure Simple things should be simple, and complex things should be possible. Basic chat requires just one line of code, but the framework supports advanced features like streaming, tool calling, and structured output when you need them. ```ruby # Simple response = RubyLLM.chat.ask("Hello") # Advanced chat = RubyLLM.chat(model: "gpt-5-nano", temperature: 0.2) .with_instructions("You are a helpful assistant") .with_tool(DatabaseQuery) .with_schema(ResponseFormat) ``` ### Ruby Conventions The framework follows Ruby idioms and conventions. Method names are descriptive, configuration uses blocks, and the API feels natural to Ruby developers. This extends to error handling, where provider-specific errors are wrapped in consistent RubyLLM exceptions. ### Minimal Dependencies RubyLLM depends only on essential gems: Faraday for HTTP, Zeitwerk for autoloading, and Marcel for file type detection. This keeps the framework lightweight and reduces potential conflicts in your application. ## How Providers Work Understanding how providers work helps you make better use of RubyLLM and even create custom providers if needed. ### Provider Detection When you specify a model, RubyLLM automatically determines which provider to use. The framework maintains a registry of known models and their providers, but you can also explicitly specify providers or use custom endpoints. ```ruby # Automatic detection chat = RubyLLM.chat(model: "gpt-5-nano") # Uses OpenAI # Explicit provider chat = RubyLLM.chat( model: "llama-3", provider: :ollama, ) ``` ### Capability Management Different models have different capabilities. Some support vision, others support tool calling, and some have specific context window sizes. RubyLLM tracks these capabilities and helps you use models appropriately. ```ruby model_info = RubyLLM.models.find("gpt-5.4") puts model_info.capabilities # => [:chat, :vision, :tools, :json_mode] ``` ### Response Normalization Each provider returns responses in different formats. RubyLLM normalizes these into consistent response objects, so your code doesn't need to handle provider-specific differences. ## Rails Integration RubyLLM integrates deeply with Rails through ActiveRecord mixins and generators. The `acts_as_chat` and `acts_as_message` methods add AI capabilities to your models while following Rails conventions. ```ruby class Conversation < ApplicationRecord acts_as_chat end # Now your model can interact with AI conversation = Conversation.create!(model: "gpt-5-nano") response = conversation.ask("How can I help you today?") ``` The Rails integration handles persistence, associations, and even real-time updates through Action Cable, making it easy to build AI-powered Rails applications. ## Next Steps Now that you understand how RubyLLM works, you're ready to dive deeper into specific features. We recommend following this learning path: 1. Complete the [Getting Started](/getting-started/) guide if you haven't already 2. Learn about [Chatting with AI Models](/chat/) for conversational features 3. Explore [Tools and Function Calling](/tools/) to give AI access to your code 4. For Rails developers, the [Rails Integration](/rails/) guide covers database persistence and real-time features Each guide builds on the concepts introduced here, gradually revealing more advanced features as you need them. --- ### Configuration URL: https://rubyllm.com/configuration/ Date: 2026-08-08 # Configuration {: .no_toc } Configure once, use everywhere. API keys, defaults, timeouts, and multi-tenant contexts made simple. {: .fs-6 .fw-300 } ## Table of contents {: .no_toc .text-delta } 1. TOC {:toc} --- After reading this guide, you will know: * How to configure API keys for different providers * How to set default models for chat, embeddings, and images * How to customize connection settings and timeouts * How to use custom endpoints and proxies * How to create isolated configurations with contexts * How to configure logging and debugging ## Quick Start The simplest configuration just sets your API keys: ```ruby RubyLLM.configure do |config| config.openai_api_key = ENV['OPENAI_API_KEY'] config.anthropic_api_key = ENV['ANTHROPIC_API_KEY'] end ``` That's it. RubyLLM uses sensible defaults for everything else. ## Provider Configuration ### API Keys Configure API keys only for the providers you use. RubyLLM won't complain about missing keys for providers you never touch. ```ruby RubyLLM.configure do |config| # Anthropic config.anthropic_api_key = ENV['ANTHROPIC_API_KEY'] config.anthropic_api_base = ENV['ANTHROPIC_API_BASE'] # Available in v1.13.0+ (optional custom Anthropic endpoint) # Azure config.azure_api_base = ENV['AZURE_API_BASE'] # Microsoft Foundry project endpoint config.azure_api_key = ENV['AZURE_API_KEY'] # use this or config.azure_ai_auth_token = ENV['AZURE_AI_AUTH_TOKEN'] # this # Bedrock config.bedrock_api_key = ENV['AWS_ACCESS_KEY_ID'] config.bedrock_secret_key = ENV['AWS_SECRET_ACCESS_KEY'] config.bedrock_region = ENV['AWS_REGION'] # Required for Bedrock config.bedrock_session_token = ENV['AWS_SESSION_TOKEN'] # For temporary credentials config.bedrock_api_base = ENV['BEDROCK_API_BASE'] # v1.16+ (optional custom Bedrock endpoint) # DeepSeek config.deepseek_api_key = ENV['DEEPSEEK_API_KEY'] config.deepseek_api_base = ENV['DEEPSEEK_API_BASE'] # Available in v1.13.0+ (optional custom DeepSeek endpoint) # Gemini config.gemini_api_key = ENV['GEMINI_API_KEY'] config.gemini_api_base = ENV['GEMINI_API_BASE'] # Available in v1.9.0+ (optional API version override) # GPUStack config.gpustack_api_base = ENV['GPUSTACK_API_BASE'] config.gpustack_api_key = ENV['GPUSTACK_API_KEY'] # Mistral config.mistral_api_key = ENV['MISTRAL_API_KEY'] config.mistral_api_base = ENV['MISTRAL_API_BASE'] # v1.16+ (optional custom Mistral endpoint) # Ollama config.ollama_api_base = 'http://localhost:11434/v1' config.ollama_api_key = ENV['OLLAMA_API_KEY'] # Available in v1.13.0+ (optional for authenticated/remote Ollama endpoints) # OpenAI config.openai_api_key = ENV['OPENAI_API_KEY'] config.openai_api_base = ENV['OPENAI_API_BASE'] # Optional custom OpenAI-compatible endpoint # OpenRouter config.openrouter_api_key = ENV['OPENROUTER_API_KEY'] config.openrouter_api_base = ENV['OPENROUTER_API_BASE'] # Available in v1.13.0+ (optional custom OpenRouter endpoint) # Perplexity config.perplexity_api_key = ENV['PERPLEXITY_API_KEY'] config.perplexity_api_base = ENV['PERPLEXITY_API_BASE'] # v1.16+ (optional custom Perplexity endpoint) # Vertex AI config.vertexai_project_id = ENV['GOOGLE_CLOUD_PROJECT'] # Available in v1.7.0+ config.vertexai_location = ENV['GOOGLE_CLOUD_LOCATION'] config.vertexai_service_account_key = ENV['VERTEXAI_SERVICE_ACCOUNT_KEY'] # Optional: service account JSON key config.vertexai_api_base = ENV['VERTEXAI_API_BASE'] # v1.16+ (optional custom Vertex AI endpoint) # xAI config.xai_api_key = ENV['XAI_API_KEY'] # Available in v1.11.0+ config.xai_api_base = ENV['XAI_API_BASE'] # v1.16+ (optional custom xAI endpoint) end ``` > Attempting to use an unconfigured provider will raise `RubyLLM::ConfigurationError`. Only configure what you need. {: .note } ### OpenAI Organization & Project Headers For OpenAI users with multiple organizations or projects: ```ruby RubyLLM.configure do |config| config.openai_api_key = ENV['OPENAI_API_KEY'] config.openai_organization_id = ENV['OPENAI_ORG_ID'] # Billing organization config.openai_project_id = ENV['OPENAI_PROJECT_ID'] # Usage tracking end ``` These headers are optional and only needed for organization-specific billing or project tracking. ### Vertex AI Authentication Configuration RubyLLM supports both Vertex AI authentication methods: - Application Default Credentials (ADC) - Service Account JSON key via `config.vertexai_service_account_key` If `vertexai_service_account_key` is not set, RubyLLM uses ADC. ## Custom Endpoints ### OpenAI-Compatible APIs Connect to any OpenAI-compatible API endpoint, including local models, proxies, and custom servers: ```ruby RubyLLM.configure do |config| # API key - use what your server expects config.openai_api_key = ENV['CUSTOM_API_KEY'] # Or 'dummy-key' if not required # Your custom endpoint config.openai_api_base = "http://localhost:8080/v1" # vLLM, LiteLLM, etc. end # Use your custom model name chat = RubyLLM.chat(model: 'my-custom-model', provider: :openai, assume_model_exists: true) ``` #### System Role Compatibility OpenAI's API now uses 'developer' role for system messages, but some OpenAI-compatible servers still require the traditional 'system' role: ```ruby RubyLLM.configure do |config| # For servers that require 'system' role (e.g., older vLLM, some local models) config.openai_use_system_role = true # Use 'system' role instead of 'developer' # Your OpenAI-compatible endpoint config.openai_api_base = "http://localhost:11434/v1" # Ollama, vLLM, etc. config.openai_api_key = "dummy-key" # If required by your server end ``` By default, RubyLLM uses the 'developer' role (matching OpenAI's current API). Set `openai_use_system_role` to true for compatibility with servers that still expect 'system'. ### Gemini API Versions {: .d-inline-block } v1.9.0+ {: .label .label-green } Gemini offers two API versions: `v1` (stable) and `v1beta` (early access). RubyLLM defaults to `v1beta` for access to the latest features, but you can switch to `v1` to support older models: ```ruby RubyLLM.configure do |config| config.gemini_api_key = ENV['GEMINI_API_KEY'] config.gemini_api_base = 'https://generativelanguage.googleapis.com/v1' end ``` Some models are only available on specific API versions. For example, `gemini-1.5-flash-8b` requires `v1`. Check the [Gemini API documentation](https://ai.google.dev/gemini-api/docs/api-versions) for version-specific model availability. ### Provider-Specific API Base URLs {: .d-inline-block } v1.16+ {: .label .label-green } Every provider exposes a provider-specific `*_api_base` setting in v1.16+. Use these when routing a native provider API through a proxy, gateway, private network endpoint, or compatible service: ```ruby RubyLLM.configure do |config| config.perplexity_api_base = ENV['PERPLEXITY_API_BASE'] config.mistral_api_base = ENV['MISTRAL_API_BASE'] config.xai_api_base = ENV['XAI_API_BASE'] config.bedrock_api_base = ENV['BEDROCK_API_BASE'] config.vertexai_api_base = ENV['VERTEXAI_API_BASE'] end ``` Blank strings are treated as unset, so environment variables can be wired directly without causing invalid URL errors. ## Default Models Set defaults for the convenience methods (`RubyLLM.chat`, `RubyLLM.embed`, `RubyLLM.paint`): ```ruby RubyLLM.configure do |config| config.default_model = 'claude-sonnet-4-6' # For RubyLLM.chat config.default_embedding_model = 'text-embedding-3-large' # For RubyLLM.embed config.default_image_model = 'dall-e-3' # For RubyLLM.paint end ``` Defaults if not configured: - Chat: `gpt-5-nano` - Embeddings: `text-embedding-3-small` - Images: `gpt-image-1.5` ## Model Registry File By default, RubyLLM reads model information from the bundled `models.json` file. If your gem directory is read-only, you can configure a writable location: ```ruby # First time: save to writable location RubyLLM.models.save_to_json('/var/app/models.json') # Configure to use new location (Available in v1.9.0+) RubyLLM.configure do |config| config.model_registry_file = '/var/app/models.json' end ``` After this one-time setup, RubyLLM will read from your configured path automatically. > `RubyLLM.models.refresh!` updates the in-memory registry only. To persist changes, call `RubyLLM.models.save_to_json`. {: .note } > If you're using the ActiveRecord integration, model data is stored in the database. This configuration doesn't apply. {: .note } ## Connection Settings ### Timeouts & Retries Fine-tune how RubyLLM handles network connections: ```ruby RubyLLM.configure do |config| # Basic settings config.request_timeout = 120 # Seconds to wait for response (default: 300) config.max_retries = 3 # Retry attempts on failure (default: 3) # Advanced retry behavior config.retry_interval = 0.1 # Initial retry delay in seconds (default: 0.1) config.retry_backoff_factor = 2 # Exponential backoff multiplier (default: 2) config.retry_interval_randomness = 0.5 # Jitter to prevent thundering herd (default: 0.5) end ``` Example for high-latency connections: ```ruby RubyLLM.configure do |config| config.request_timeout = 300 # 5 minutes for complex tasks config.max_retries = 5 # More retry attempts config.retry_interval = 1.0 # Start with 1 second delay config.retry_backoff_factor = 1.5 # Less aggressive backoff end ``` ### HTTP Proxy Support Route requests through a proxy: ```ruby RubyLLM.configure do |config| # Basic proxy config.http_proxy = "http://proxy.company.com:8080" # Authenticated proxy config.http_proxy = "http://user:pass@proxy.company.com:8080" # SOCKS5 proxy config.http_proxy = "socks5://proxy.company.com:1080" end ``` ## Logging & Debugging ### Basic Logging ```ruby RubyLLM.configure do |config| # Log to file config.log_file = '/var/log/ruby_llm.log' config.log_level = :info # :debug, :info, :warn # Or use Rails logger config.logger = Rails.logger # Overrides log_file and log_level end ``` Log levels: - `:debug` - Detailed request/response information - `:info` - General operational information - `:warn` - Non-critical issues > Setting `config.logger` overrides `log_file` and `log_level` settings. {: .note } ### Advanced Logging Options Use these options when you need deeper troubleshooting or safer handling of large debug payloads. ```ruby RubyLLM.configure do |config| # Enable verbose chunk-level stream debugging config.log_stream_debug = true # Available in v1.13.0+ # Timeout (seconds) used for regex-based log filtering config.log_regexp_timeout = 1.5 end ``` `log_stream_debug` notes: - Shows chunk-by-chunk streaming internals (accumulator state, parsing, tool chunks) - Useful for diagnosing streaming/provider parsing issues - Can also be enabled with `RUBYLLM_STREAM_DEBUG=true` `log_regexp_timeout` notes: - Available in `v1.13.0+` - Applies to regex filters used in request/response debug logging - Supported on Ruby `3.2+` (uses `Regexp.timeout`) - On Ruby `<3.2`, RubyLLM warns if set and continues without timeout - Helps bound regex execution time when debug logs contain very large payloads Built-in debug log redaction: - Large base64-like blobs are redacted as `[BASE64 DATA]` - Large embedding arrays are redacted as `[EMBEDDINGS ARRAY]` ### Debug Options ```ruby RubyLLM.configure do |config| # Enable debug logging via environment variable config.log_level = :debug if ENV['RUBYLLM_DEBUG'] == 'true' # Show detailed streaming chunks config.log_stream_debug = true # Or set RUBYLLM_STREAM_DEBUG=true end ``` Stream debug logging shows every chunk, accumulator state, and parsing decision - invaluable for debugging streaming issues. ## Contexts: Isolated Configurations Create temporary configuration scopes without affecting global settings. Perfect for multi-tenancy, testing, or specific task requirements. ### Basic Context Usage ```ruby # Global config uses production OpenAI RubyLLM.configure do |config| config.openai_api_key = ENV['OPENAI_PROD_KEY'] end # Create isolated context ctx = RubyLLM.context do |config| config.openai_api_key = ENV['ANOTHER_PROVIDER_KEY'] config.openai_api_base = "https://another-provider.com" config.request_timeout = 180 end # Use Azure for this specific task ctx_chat = ctx.chat(model: 'gpt-5.4') response = ctx_chat.ask("Process this with another provider...") # Global config unchanged regular_chat = RubyLLM.chat # Still uses production OpenAI ``` ### Multi-Tenant Applications ```ruby class TenantService def initialize(tenant) @context = RubyLLM.context do |config| config.openai_api_key = tenant.openai_key config.default_model = tenant.preferred_model config.request_timeout = tenant.timeout_seconds end end def chat @context.chat end end # Each tenant gets isolated configuration tenant_a_service = TenantService.new(tenant_a) tenant_b_service = TenantService.new(tenant_b) ``` ### Key Context Behaviors - **Inheritance**: Contexts start with a copy of global configuration - **Isolation**: Changes don't affect global `RubyLLM.config` - **Thread Safety**: Each context is independent and thread-safe ## Rails Integration For Rails applications, create an initializer: ```ruby # config/initializers/ruby_llm.rb RubyLLM.configure do |config| # Use Rails credentials config.openai_api_key = Rails.application.credentials.openai_api_key config.anthropic_api_key = Rails.application.credentials.anthropic_api_key config.anthropic_api_base = ENV['ANTHROPIC_API_BASE'] # Available in v1.13.0+ (optional custom Anthropic endpoint) config.ollama_api_key = ENV['OLLAMA_API_KEY'] # Available in v1.13.0+ (optional for remote/authenticated Ollama) # Use Rails logger config.logger = Rails.logger # Environment-specific settings config.request_timeout = Rails.env.production? ? 120 : 30 config.log_level = Rails.env.production? ? :info : :debug end ``` ### Initializer Load Timing Issue with `use_new_acts_as` **Important**: If you're using `config.use_new_acts_as = false`, you **cannot** set it in an initializer. Rails loads models before initializers run, so the new `acts_as` module will already be included by the time your initializer executes. Instead, configure it in `config/application.rb` **before** the `Application` class: ```ruby # config/application.rb require_relative "boot" require "rails/all" # Configure RubyLLM before Rails::Application is inherited RubyLLM.configure do |config| config.use_new_acts_as = false end module YourApp class Application < Rails::Application # ... end end ``` This ensures RubyLLM is configured before ActiveRecord loads your models. Other configuration options (API keys, timeouts, etc.) can still go in your initializer. > The legacy API will be removed in RubyLLM 2.0 {: .note } See the [Upgrading guide](/upgrading/#troubleshooting) for more details. ## Configuration Reference Here's a complete reference of all configuration options: ```ruby RubyLLM.configure do |config| # Anthropic config.anthropic_api_key = String config.anthropic_api_base = String # v1.13.0+ # Azure config.azure_api_base = String # v1.12.0+ config.azure_api_key = String # v1.12.0+ config.azure_ai_auth_token = String # v1.12.0+ # Bedrock config.bedrock_api_key = String config.bedrock_secret_key = String config.bedrock_region = String config.bedrock_session_token = String config.bedrock_api_base = String # v1.16+ # DeepSeek config.deepseek_api_key = String config.deepseek_api_base = String # v1.13.0+ # Gemini config.gemini_api_key = String config.gemini_api_base = String # v1.9.0+ # GPUStack config.gpustack_api_base = String config.gpustack_api_key = String # Mistral config.mistral_api_key = String config.mistral_api_base = String # v1.16+ # Ollama config.ollama_api_base = String config.ollama_api_key = String # v1.13.0+ # OpenAI config.openai_api_key = String config.openai_api_base = String config.openai_organization_id = String config.openai_project_id = String config.openai_use_system_role = Boolean # OpenRouter config.openrouter_api_key = String config.openrouter_api_base = String # v1.13.0+ # Perplexity config.perplexity_api_key = String config.perplexity_api_base = String # v1.16+ # Vertex AI config.vertexai_project_id = String # GCP project ID config.vertexai_location = String # e.g., 'us-central1' config.vertexai_service_account_key = String # Optional: service account JSON key (ADC used when unset) config.vertexai_api_base = String # v1.16+ # xAI config.xai_api_key = String config.xai_api_base = String # v1.16+ # Default Models config.default_model = String config.default_embedding_model = String config.default_image_model = String config.default_moderation_model = String config.default_transcription_model = String # Model Registry config.model_registry_file = String # Path to model registry JSON file (v1.9.0+) config.model_registry_class = String # Connection Settings config.request_timeout = Integer config.max_retries = Integer config.retry_interval = Float config.retry_backoff_factor = Integer config.retry_interval_randomness = Float config.http_proxy = String config.faraday_adapter = Symbol # Defaults to :net_http # Logging config.logger = Logger config.instrumenter = Object # Responds to instrument(name, payload) { ... } config.deprecation_behavior = :warn # :warn, :silence, or :raise config.log_file = String config.log_level = Symbol config.log_stream_debug = Boolean config.log_regexp_timeout = Numeric # v1.13.0+ (Ruby 3.2+ support) # Rails integration config.use_new_acts_as = true or false end ``` ## Next Steps Now that you've configured RubyLLM, you're ready to: - [Start chatting with AI models](/chat/) - [Work with different providers and models](/models/) - [Set up Rails integration](/rails/) --- ## Core Features ### Chat URL: https://rubyllm.com/chat/ Date: 2026-08-08 # Chat {: .no_toc } Learn how to have conversations with AI models, work with different providers, and handle multi-modal inputs {: .fs-6 .fw-300 } ## Table of contents {: .no_toc .text-delta } 1. TOC {:toc} --- After reading this guide, you will know: * How to start and continue conversations with AI models * How to select and work with different models and providers * How to guide AI behavior with system prompts * How to work with images, audio, documents, and other file types * How to control response creativity and format * How to get structured output with JSON schemas * How to track token usage and costs * How to handle streaming responses and events ## Starting a Conversation When you want to interact with an AI model, you create a chat instance. The simplest approach uses `RubyLLM.chat`, which creates a new conversation with your configured default model. ```ruby chat = RubyLLM.chat # The ask method sends a user message and returns the assistant's response response = chat.ask "Explain the concept of 'Convention over Configuration' in Rails." # The response is a RubyLLM::Message object puts response.content # => "Convention over Configuration (CoC) is a core principle of Ruby on Rails..." # The response object contains metadata puts "Model Used: #{response.model_id}" puts "Tokens Used: #{response.tokens.input} input, #{response.tokens.output} output" puts "Cache Reads: #{response.tokens.cache_read}" # v1.15+ puts "Cache Writes: #{response.tokens.cache_write}" # v1.15+ ``` The `ask` method adds your message to the conversation history with the `:user` role, sends the entire conversation history to the AI provider, and returns a `RubyLLM::Message` object containing the assistant's response. The `say` method is an alias for `ask`, so you can use whichever feels more natural in your code. ## Continuing the Conversation One of the key features of chat-based AI models is their ability to maintain context across multiple exchanges. The `Chat` object automatically manages this conversation history for you. ```ruby # Continuing the previous chat... response = chat.ask "Can you give a specific example in Rails?" puts response.content # => "Certainly! A classic example is database table naming..." # Access the full conversation history chat.messages.each do |message| puts "[#{message.role.to_s.upcase}] #{message.content.lines.first.strip}" end # => [USER] Explain the concept of 'Convention over Configuration' in Rails. # => [ASSISTANT] Convention over Configuration (CoC) is a core principle... # => [USER] Can you give a specific example in Rails? # => [ASSISTANT] Certainly! A classic example is database table naming... ``` Each time you call `ask`, RubyLLM sends the entire conversation history to the AI provider. This allows the model to understand the full context of your conversation, enabling natural follow-up questions and maintaining coherent dialogue. ## Guiding AI Behavior with System Prompts System prompts, also called instructions, allow you to set the overall behavior, personality, and constraints for the AI assistant. These instructions persist throughout the conversation and help ensure consistent responses. ```ruby chat = RubyLLM.chat # Set the initial instruction chat.with_instructions "You are a helpful assistant that explains Ruby concepts simply, like explaining to a five-year-old." response = chat.ask "What is a variable?" puts response.content # => "Imagine you have a special box, and you can put things in it..." # By default, with_instructions replaces the active system instruction chat.with_instructions "Always end your response with 'Got it?'" response = chat.ask "What is a loop?" puts response.content # => "A loop is like singing your favorite song over and over again... Got it?" # Append an additional system instruction only when needed chat.with_instructions "Use exactly one short paragraph.", append: true ``` System prompts are added to the conversation as messages with the `:system` role and are sent with every request to the AI provider. This ensures the model always considers your instructions when generating responses. > When using the [Rails Integration](/rails/), system messages are persisted in your database along with user and assistant messages, maintaining the full conversation context. {: .note } ## Working with Different Models RubyLLM supports over 600 models from various providers. While `RubyLLM.chat` uses your configured default model, you can specify different models: ```ruby # Use a specific model via ID or alias chat_claude = RubyLLM.chat(model: 'claude-sonnet-4-6') chat_gemini = RubyLLM.chat(model: 'gemini-3.1-pro-preview') # Change the model on an existing chat instance chat = RubyLLM.chat(model: 'gpt-5-nano') response1 = chat.ask "Initial question..." chat.with_model('claude-sonnet-4-6') response2 = chat.ask "Follow-up question..." ``` For detailed information about model selection, capabilities, aliases, and working with custom models, see the [Working with Models Guide](/models/). ## Multi-modal Conversations Many modern AI models can process multiple types of input beyond just text. RubyLLM provides a unified interface for working with images, audio, documents, and other file types through the `with:` parameter. ### Working with Images Vision-capable models can analyze images, answer questions about visual content, and even compare multiple images. ```ruby # Ensure you select a vision-capable model chat = RubyLLM.chat(model: 'gpt-5.4') # Ask about a local image file response = chat.ask "Describe this logo.", with: "path/to/ruby_logo.png" puts response.content # Ask about an image from a URL response = chat.ask "What kind of architecture is shown here?", with: "https://example.com/eiffel_tower.jpg" puts response.content # Send multiple images response = chat.ask "Compare the user interfaces in these two screenshots.", with: ["screenshot_v1.png", "screenshot_v2.png"] puts response.content ``` ### Working with Videos You can also analyze video files or URLs with video-capable models. RubyLLM will automatically detect video files and handle them appropriately. ```ruby # Ask about a local video file chat = RubyLLM.chat(model: 'gemini-2.5-flash') response = chat.ask "What happens in this video?", with: "path/to/demo.mp4" puts response.content # Ask about a video from a URL response = chat.ask "Summarize the main events in this video.", with: "https://example.com/demo_video.mp4" puts response.content # Combine videos with other file types response = chat.ask "Analyze these files for visual content.", with: ["diagram.png", "demo.mp4", "notes.txt"] puts response.content ``` > Supported video formats include .mp4, .mov, .avi, .webm, and others (provider-dependent). > > Only Google Gemini and VertexAI models currently support video input. > > Large video files may be subject to size or duration limits imposed by the provider. {: .note } RubyLLM automatically handles image encoding and formatting for each provider's API. Local images are read and encoded as needed, while URLs are passed directly when supported by the provider. ### Working with Audio Audio-capable models can transcribe speech, analyze audio content, and answer questions about what they hear. Currently, models like `gpt-4o-audio-preview` and Google's `gemini-2.5` series of models support audio input. ```ruby chat = RubyLLM.chat(model: 'gpt-4o-audio-preview') # Use an audio-capable model # Transcribe or ask questions about audio content response = chat.ask "Please transcribe this meeting recording.", with: "path/to/meeting.mp3" puts response.content # Ask follow-up questions based on the audio context response = chat.ask "What were the main action items discussed?" puts response.content # Gemini example gemini_chat = RubyLLM.chat(model: 'gemini-2.5-flash') response = gemini_chat.ask "Summarize this podcast.", with: "path/to/podcast.mp3" puts response.content ``` ### Working with Text Files You can provide text files directly to models for analysis, summarization, or question answering. This works with any text-based format including plain text, code files, CSV, JSON, and more. ```ruby chat = RubyLLM.chat(model: 'claude-sonnet-4-6') # Analyze a text file response = chat.ask "Summarize the key points in this document.", with: "path/to/document.txt" puts response.content # Ask questions about code files response = chat.ask "Explain what this Ruby file does.", with: "app/models/user.rb" puts response.content ``` ### Working with PDFs PDF support allows models to analyze complex documents including reports, manuals, and research papers. Currently, Claude 3+ and Gemini models offer the best PDF support. ```ruby # Use a model that supports PDFs chat = RubyLLM.chat(model: 'claude-sonnet-4-6') # Ask about a local PDF response = chat.ask "Summarize the key findings in this research paper.", with: "path/to/paper.pdf" puts response.content # Ask about a PDF via URL response = chat.ask "What are the terms and conditions outlined here?", with: "https://example.com/terms.pdf" puts response.content # Combine text and PDF context response = chat.ask "Based on section 3 of this document, what is the warranty period?", with: "manual.pdf" puts response.content ``` > Be mindful of provider-specific limits. For example, Anthropic Claude models currently have a 10MB per-file size limit, and the total size/token count of all PDFs must fit within the model's context window (e.g., 200,000 tokens for Claude 3 models). {: .note } ### Automatic File Type Detection RubyLLM automatically detects file types based on extensions and content, so you can pass files directly without specifying the type: ```ruby chat = RubyLLM.chat(model: 'claude-sonnet-4-6') # Single file - type automatically detected response = chat.ask "What's in this file?", with: "path/to/document.pdf" # Multiple files of different types response = chat.ask "Analyze these files", with: [ "diagram.png", "report.pdf", "meeting_notes.txt", "recording.mp3" ] # Still works with the explicit hash format if needed response = chat.ask "What's in this image?", with: { image: "photo.jpg" } ``` **Supported file types:** - **Images:** .jpg, .jpeg, .png, .gif, .webp, .bmp - **Videos:** .mp4, .mov, .avi, .webm - **Audio:** .mp3, .wav, .m4a, .ogg, .flac - **Documents:** .pdf, .txt, .md, .csv, .json, .xml - **Code:** .rb, .py, .js, .html, .css (and many others) ## Controlling Response Behavior ### Temperature and Creativity The temperature parameter controls the randomness of the model's responses. Understanding temperature helps you get the right balance between creativity and consistency for your use case. * **Low temperature (0.0 - 0.3)**: More deterministic and focused responses. Use for factual queries, technical explanations, or when consistency is important. * **Medium temperature (0.4 - 0.7)**: Balanced creativity and coherence. Good for general conversation and most applications. * **High temperature (0.8 - 1.0)**: More creative and varied responses. Use for brainstorming, creative writing, or when you want diverse outputs. ```ruby # Create a chat with low temperature for factual answers factual_chat = RubyLLM.chat.with_temperature(0.2) response1 = factual_chat.ask "What is the boiling point of water at sea level in Celsius?" puts response1.content # Create a chat with high temperature for creative writing creative_chat = RubyLLM.chat.with_temperature(0.9) response2 = creative_chat.ask "Write a short poem about the color blue." puts response2.content ``` The `with_temperature` method returns the chat instance, allowing you to chain multiple configuration calls together. ### Provider-Specific Parameters Different providers offer unique features and parameters. The `with_params` method lets you access these provider-specific capabilities while maintaining RubyLLM's unified interface. Parameters passed via `with_params` will override any defaults set by RubyLLM, giving you full control over the API request payload. ```ruby # response_format parameter is supported by :openai, :ollama, :deepseek chat = RubyLLM.chat.with_params(response_format: { type: 'json_object' }) response = chat.ask "What is the square root of 64? Answer with a JSON object with the key `result`." puts JSON.parse(response.content) ``` > **With great power comes great responsibility:** The `with_params` method can override any part of the request payload, including critical parameters like model, max_tokens, or tools. Use it carefully to avoid unintended behavior. Always verify that your overrides are compatible with the provider's API. To debug and see the exact request being sent, set the environment variable `RUBYLLM_DEBUG=true`. {: .warning } > Available parameters vary by provider and model. Always consult the provider's documentation for supported features. RubyLLM passes these parameters through without validation, so incorrect parameters may cause API errors. Parameters from `with_params` take precedence over RubyLLM's defaults, allowing you to override any aspect of the request payload. {: .warning } ## Raw Content Blocks {: .d-inline-block } v1.9.0+ {: .label .label-green } Most of the time you can rely on RubyLLM to format messages for each provider. When you need to send a custom payload as content, wrap it in `RubyLLM::Content::Raw`. The block is forwarded verbatim, with no additional processing. ```ruby raw_block = RubyLLM::Content::Raw.new([ { type: 'text', text: 'Reusable analysis prompt' }, { type: 'text', text: "Today's request: #{summary}" } ]) chat = RubyLLM.chat chat.add_message(role: :system, content: raw_block) chat.ask(raw_block) ``` Use raw blocks sparingly: they bypass cross-provider safeguards, so it is your responsibility to ensure the payload matches the provider's expectations. `Chat#ask`, `Chat#add_message`, tool results, and streaming accumulators all understand `Content::Raw` values. ### Anthropic Prompt Caching {: .d-inline-block } v1.9.0+ {: .label .label-green } One use case for Raw Content Blocks is Anthropic Prompt Caching. Anthropic lets you mark individual prompt blocks for caching, which can dramatically reduce costs on long conversations. RubyLLM provides a convenience builder that returns a `Content::Raw` instance with the proper structure: ```ruby system_block = RubyLLM::Providers::Anthropic::Content.new( "You are a release-notes assistant. Always group changes by subsystem.", cache: true # shorthand for cache_control: { type: 'ephemeral' } ) chat = RubyLLM.chat(model: 'claude-sonnet-4-6') chat.add_message(role: :system, content: system_block) response = chat.ask( RubyLLM::Providers::Anthropic::Content.new( "Summarize the API changes in this diff.", cache_control: { type: 'ephemeral', ttl: '1h' } ) ) ``` Need something even more custom? Build the payload manually and wrap it in `Content::Raw`: ```ruby raw_prompt = RubyLLM::Content::Raw.new([ { type: 'text', text: File.read('/a/large/file'), cache_control: { type: 'ephemeral' } }, { type: 'text', text: "Today's request: #{summary}" } ]) chat.ask(raw_prompt) ``` The same idea applies to tool definitions: ```ruby class ChangelogTool < RubyLLM::Tool description "Formats commits into human-readable changelog entries." param :commits, type: :array, desc: "List of commits to summarize" with_params cache_control: { type: 'ephemeral' } def execute(commits:) # ... end end ``` Providers that do not understand these extra fields silently ignore them, so you can reuse the same tools across models. See the [Tool Provider Parameters](/tools/#provider-specific-parameters) section for more detail. ### Custom HTTP Headers Some providers offer beta features or special capabilities through custom HTTP headers. The `with_headers` method lets you add these headers to your API requests while maintaining RubyLLM's security model. ```ruby # Enable Anthropic's beta features chat = RubyLLM.chat(model: 'claude-sonnet-4-6') .with_headers('anthropic-beta' => 'fine-grained-tool-streaming-2025-05-14') response = chat.ask "Tell me about the weather" ``` Headers are merged with provider defaults, with provider headers taking precedence for security. This means you can't override authentication or critical headers, but you can add supplementary headers for optional features. ```ruby # Chain with other configuration methods chat = RubyLLM.chat .with_temperature(0.5) .with_headers('X-Custom-Feature' => 'enabled') .with_params(max_tokens: 1000) ``` > Use custom headers with caution. They may enable experimental features that could change or be removed without notice. Always refer to your provider's documentation for supported headers and their behavior. {: .warning } ## Getting Structured Output When building applications, you often need AI responses in a specific format for parsing and processing. RubyLLM provides two approaches: JSON mode for valid JSON output, and structured output for guaranteed schema compliance. > JSON mode (using `with_params(response_format: { type: 'json_object' })`) guarantees valid JSON but not any specific structure. Structured output (`with_schema`) guarantees the response matches your exact schema with required fields and types. Use structured output when you need predictable, validated responses. {: .note } ```ruby # JSON mode - guarantees valid JSON, but no specific structure chat = RubyLLM.chat.with_params(response_format: { type: 'json_object' }) response = chat.ask("List 3 programming languages with their year created. Return as JSON.") # Could return any valid JSON structure # Structured output - guarantees exact schema class LanguagesSchema < RubyLLM::Schema array :languages do object do string :name integer :year end end end chat = RubyLLM.chat.with_schema(LanguagesSchema) response = chat.ask("List 3 programming languages with their year created") # Always returns: {"languages" => [{"name" => "...", "year" => ...}, ...]} ``` ### Using RubyLLM::Schema (Recommended) The easiest way to define schemas is with the [RubyLLM::Schema](https://github.com/danielfriis/ruby_llm-schema) gem: ```ruby # First, add to your Gemfile: # gem 'ruby_llm-schema' # # Then in your code: require 'ruby_llm/schema' # Define your schema as a class class PersonSchema < RubyLLM::Schema string :name, description: "Person's full name" integer :age, description: "Person's age in years" string :city, required: false, description: "City where they live" end # Use it with a chat chat = RubyLLM.chat response = chat.with_schema(PersonSchema).ask("Generate a person named Alice who is 30 years old") # The response is automatically parsed from JSON puts response.content # => {"name" => "Alice", "age" => 30} puts response.content.class # => Hash ``` > RubyLLM::Schema classes automatically use their class name (e.g., `PersonSchema`) as the schema name in API requests, which can help the model better understand the expected output structure. {: .note } ### Using Manual JSON Schemas If you prefer not to use RubyLLM::Schema, you can provide a JSON Schema directly: ```ruby person_schema = { type: 'object', properties: { name: { type: 'string' }, age: { type: 'integer' }, hobbies: { type: 'array', items: { type: 'string' } } }, required: ['name', 'age', 'hobbies'], additionalProperties: false # Required for OpenAI structured output } chat = RubyLLM.chat response = chat.with_schema(person_schema).ask("Generate a person who likes Ruby") # Response is automatically parsed puts response.content # => {"name" => "Bob", "age" => 25, "hobbies" => ["Ruby programming", "Open source"]} ``` > **OpenAI Requirement:** When using manual JSON schemas with OpenAI, you must include `additionalProperties: false` in your schema objects. RubyLLM::Schema handles this automatically. {: .warning } #### Custom Schema Names By default, schemas are named 'response' in API requests. You can provide a custom name that can influence model behavior and aid debugging: ```ruby # Provide a custom name with the full format person_schema = { name: 'PersonSchema', schema: { type: 'object', properties: { name: { type: 'string' }, age: { type: 'integer' } }, required: ['name', 'age'], additionalProperties: false } } chat = RubyLLM.chat response = chat.with_schema(person_schema).ask("Generate a person") ``` Custom schema names are useful for: - **Influencing model behavior** - Descriptive names can help the model better understand the expected output structure - **Debugging and logging** - Identifying which schema was used in API requests ### Complex Nested Schemas Structured output supports complex nested objects and arrays: ```ruby class CompanySchema < RubyLLM::Schema string :name, description: "Company name" array :employees do object do string :name string :role, enum: ["developer", "designer", "manager"] array :skills, of: :string end end object :metadata do integer :founded string :industry end end chat = RubyLLM.chat response = chat.with_schema(CompanySchema).ask("Generate a small tech startup") # Access nested data response.content["employees"].each do |employee| puts "#{employee['name']} - #{employee['role']}" end ``` ### Provider Support Not all models support structured output. Currently supported: - **OpenAI**: GPT-4o, GPT-4o-mini, and newer models - **Anthropic**: Claude 4.5+ models (Haiku, Sonnet, Opus) - **Gemini**: Gemini 1.5 Pro/Flash and newer Models that don't support structured output: ```ruby chat = RubyLLM.chat(model: 'gpt-3.5-turbo') chat.with_schema(schema) response = chat.ask('Generate a person') # Provider will return an error if unsupported ``` ### Multi-turn Conversations with Schemas You can add or remove schemas during a conversation: ```ruby # Start with a schema chat = RubyLLM.chat chat.with_schema(PersonSchema) person = chat.ask("Generate a person") # Remove the schema for free-form responses chat.with_schema(nil) analysis = chat.ask("Tell me about this person's potential career paths") # Add a different schema class CareerPlanSchema < RubyLLM::Schema string :title array :steps, of: :string integer :years_required end chat.with_schema(CareerPlanSchema) career = chat.ask("Now structure a career plan") puts person.content puts analysis.content puts career.content ``` ## Tracking Token Usage Understanding token usage is important for managing costs and staying within context limits. Each `RubyLLM::Message` returned by `ask` includes token counts. ```ruby response = chat.ask "Explain the Ruby Global Interpreter Lock (GIL)." input_tokens = response.tokens.input # Standard input tokens output_tokens = response.tokens.output # Billable output tokens cache_read_tokens = response.tokens.cache_read # Tokens served from the provider's prompt cache - v1.15+ cache_write_tokens = response.tokens.cache_write # Tokens written to cache - v1.15+ thinking_tokens = response.tokens.thinking # Thinking tokens when providers report them - v1.10.0+ request_side_input_tokens = input_tokens.to_i + cache_read_tokens.to_i + cache_write_tokens.to_i puts "Input Tokens: #{input_tokens}" puts "Output Tokens: #{output_tokens}" puts "Cache Read Tokens: #{cache_read_tokens}" # v1.15+ puts "Cache Write Tokens: #{cache_write_tokens}" # v1.15+ puts "Thinking Tokens: #{thinking_tokens}" # v1.10.0+ puts "Request-side Input Tokens: #{request_side_input_tokens}" # v1.15+ puts "Standard Tokens for this turn: #{input_tokens.to_i + output_tokens.to_i}" # Cost for this turn - v1.15+ puts "Input Cost: $#{format('%.6f', response.cost.input)}" if response.cost.input puts "Output Cost: $#{format('%.6f', response.cost.output)}" if response.cost.output puts "Cache Read Cost: $#{format('%.6f', response.cost.cache_read)}" if response.cost.cache_read puts "Cache Write Cost: $#{format('%.6f', response.cost.cache_write)}" if response.cost.cache_write puts "Thinking Cost: $#{format('%.6f', response.cost.thinking)}" if response.cost.thinking puts "Total Cost: $#{format('%.6f', response.cost.total)}" if response.cost.total # Total tokens for the entire conversation so far total_conversation_tokens = chat.messages.sum do |msg| msg.tokens&.input.to_i + msg.tokens&.output.to_i + msg.tokens&.cache_read.to_i + msg.tokens&.cache_write.to_i end puts "Total Conversation Tokens: #{total_conversation_tokens}" # Total cost for the entire conversation so far - v1.15+ puts "Total Conversation Cost: $#{format('%.6f', chat.cost.total)}" if chat.cost.total ``` RubyLLM handles provider token differences for you. From v1.15 onward, `tokens.input` means the standard input bucket used for pricing. Cache activity is exposed separately as `tokens.cache_read` and `tokens.cache_write`, even when the provider includes those tokens in a raw prompt total. | Provider | Raw provider usage | RubyLLM exposes | | --- | --- | --- | | OpenAI, Azure OpenAI, xAI, OpenAI-compatible | `prompt_tokens` can include `prompt_tokens_details.cached_tokens`; cache writes may appear as `cache_write_tokens`. | `tokens.input` excludes cache reads and writes. `tokens.cache_read` and `tokens.cache_write` receive the cache buckets. | | DeepSeek | `prompt_tokens` is split into `prompt_cache_hit_tokens` and `prompt_cache_miss_tokens`. | `tokens.input` is cache misses. `tokens.cache_read` is cache hits. | | OpenRouter | `prompt_tokens` can include cached tokens and cache-write tokens in `prompt_tokens_details`. | `tokens.input` excludes both cache buckets. `tokens.cache_read` and `tokens.cache_write` receive the cache buckets. | | Anthropic | `input_tokens` is already separate from `cache_read_input_tokens` and `cache_creation_input_tokens` or the `cache_creation` breakdown. | `tokens.input` passes through. Cache buckets map to `tokens.cache_read` and `tokens.cache_write`. | | Bedrock | `inputTokens` includes `cacheReadInputTokens` and `cacheWriteInputTokens`. | `tokens.input` excludes both cache buckets. Cache buckets are exposed separately. | | Gemini and Vertex AI | `promptTokenCount` includes `cachedContentTokenCount`. | `tokens.input` excludes cached content. `tokens.cache_read` receives cached content tokens. | | Providers without cache fields | Only standard input and output usage is reported. | Cache buckets stay `nil`; `tokens.input` stays as the provider input count. | This means the same RubyLLM code works across providers: `tokens.input` for standard input, `tokens.output` for output, `tokens.cache_read` for prompt cache reads, and `tokens.cache_write` for prompt cache writes. To display the full request-side input activity, add `tokens.input + tokens.cache_read + tokens.cache_write`. The top-level token helpers remain available for compatibility with v1.9.0+ code, but new code should prefer `response.tokens.*`. Thinking token usage is available via `response.tokens.thinking` when providers report it. For most providers, thinking/reasoning tokens are a breakdown of output work, not an extra bucket to add yourself. RubyLLM keeps `tokens.output` as the billable output bucket: OpenAI-style providers that include reasoning in completion tokens stay as-is, while OpenAI-compatible providers that report reasoning outside completion tokens are normalized so `tokens.output` includes the billable generated total. When a model has distinct reasoning-token pricing, `response.cost.thinking` prices that bucket separately. Otherwise, thinking tokens are treated as part of `response.cost.output` and `response.cost.thinking` stays `nil`. Cost helpers are available from v1.15+. RubyLLM uses token usage from the provider and pricing from the model registry. If the registry is missing pricing for tokens that were used, the affected cost and `cost.total` return `nil` instead of pretending the cost was zero. These helpers cover token-priced conversation usage; provider-specific add-ons such as search-query charges are left to the provider's raw usage payload. Refer to the [Working with Models Guide](/models/) for details on accessing model-specific pricing. ## Chat Event Handlers You can register blocks to be called when certain events occur during the chat lifecycle. This is particularly useful for UI updates, logging, analytics, or building real-time chat interfaces. ### Available Event Handlers RubyLLM provides two callback styles. The `on_*` handlers replace any previously registered handler for the same event, which is useful when you want to override behavior. The Rails-style `before_*` and `after_*` callbacks are additive, so multiple registrations for the same event all run. Additive callbacks are available from v1.15+. ```ruby chat = RubyLLM.chat # Called at first chunk received from the assistant chat.before_message do print "Assistant > " end # Called after the complete assistant message (including tool calls/results) is received chat.after_message do |message| puts "Response complete!" # Note: message might be nil if an error occurred during the request if message&.tokens&.output tokens = message.tokens.input.to_i + message.tokens.output.to_i + message.tokens.cache_read.to_i + message.tokens.cache_write.to_i puts "Used #{tokens} tokens" end end # Called when the AI decides to use a tool chat.before_tool_call do |tool_call| puts "AI is calling tool: #{tool_call.name} with arguments: #{tool_call.arguments}" end # Called after a tool returns its result chat.after_tool_result do |result| puts "Tool returned: #{result}" end # These callbacks work for both streaming and non-streaming requests chat.ask "What is metaprogramming in Ruby?" ``` The older `on_new_message`, `on_end_message`, `on_tool_call`, and `on_tool_result` handlers are still available and keep their replacing behavior. RubyLLM emits a deprecation warning when one of these handlers is used; prefer the additive Rails-style callbacks for new code. ## Raw Responses You can access the raw response from the API provider with `response.raw`. ```ruby response = chat.ask("What is the capital of France?") puts response.raw.body ``` The raw response is a `Faraday::Response` object, which you can use to access the headers, body, and status code. ## Next Steps This guide covered the core `Chat` interface. Now you might want to explore: * [Working with Models](/models/): Learn how to choose the best model and handle custom endpoints. * [Using Tools](/tools/): Enable the AI to call your Ruby code. * [Streaming Responses](/streaming/): Get real-time feedback from the AI. * [Rails Integration](/rails/): Persist your chat conversations easily. * [Error Handling](/error-handling/): Build robust applications that handle API issues. --- ### Tools URL: https://rubyllm.com/tools/ Date: 2026-08-08 # Tools {: .no_toc } Let AI call your Ruby code. Connect to databases, APIs, or any external system with function calling. {: .fs-6 .fw-300 } ## Table of contents {: .no_toc .text-delta } 1. TOC {:toc} --- After reading this guide, you will know: * What Tools are and why they are useful. * How to define a Tool using `RubyLLM::Tool`. * How to define parameters for your Tools (from quick helpers to full JSON Schema). * How to use Tools within a `RubyLLM::Chat`. * The execution flow when a model uses a Tool. * How to handle errors within Tools. * Security considerations when using Tools. ## What Are Tools? Tools bridge the gap between the AI model's conversational abilities and the real world. They allow the model to delegate tasks it cannot perform itself to your application code. Common use cases: * **Fetching Real-time Data:** Get current stock prices, weather forecasts, news headlines, or sports scores. * **Database Interaction:** Look up customer information, product details, or order statuses. * **Calculations:** Perform precise mathematical operations or complex financial modeling. * **External APIs:** Interact with third-party services (e.g., send an email, book a meeting, control smart home devices). * **Executing Code:** Run specific business logic or algorithms within your application. ## Creating a Tool Define a tool by creating a class that inherits from `RubyLLM::Tool`. ```ruby class Weather < RubyLLM::Tool desc "Gets current weather for a location" def execute(latitude:, longitude:) url = "https://api.open-meteo.com/v1/forecast?latitude=#{latitude}&longitude=#{longitude}¤t=temperature_2m,wind_speed_10m" response = Faraday.get(url) data = JSON.parse(response.body) rescue => e { error: e.message } end end ``` ### Tool Components 1. **Inheritance:** Must inherit from `RubyLLM::Tool`. 2. **`desc` / `description`:** A class method defining what the tool does. Crucial for the AI model to understand its purpose. Keep it clear and concise. 3. **`execute` Method:** The instance method containing your Ruby code. RubyLLM v1.15+ infers simple keyword parameters from this signature when no explicit parameter schema is declared. 4. **Parameter declarations:** Optional. Use `param` for simple descriptions and types, or `params` for nested objects, arrays, enums, and full JSON Schema control. > The tool's class name is automatically converted to a snake_case name used in the API call (e.g., `WeatherLookup` becomes `weather_lookup`). This is how the LLM would call it. You can override this by defining a `name` method in your tool class: > > ```ruby > class WeatherLookup < RubyLLM::Tool > def name > "Weather" > end > end > ``` {: .note } > If a model attempts to call a tool that doesn't exist (sometimes called "tool hallucination"), RubyLLM handles this gracefully by: > > 1. Returning an error message to the model indicating which tool it tried to call > 2. Listing the actually available tools > 3. Allowing the conversation to continue so the model can correct itself > > This prevents crashes and gives the model a chance to use the correct tool or respond appropriately. {: .note } ## Declaring Parameters RubyLLM ships with three complementary approaches: * **Signature inference** for simple flat arguments. * The **`param` helper** for quick, flat argument lists. (v1.0+) * The **`params` DSL** for expressive, structured inputs. (v1.9+) Start with the method signature. Add `param` when a flat argument needs a description, type, or optionality that is not obvious from Ruby alone. Use the `params` DSL whenever you need nested objects, arrays, enums, or union types. ### Signature Inference {: .d-inline-block } v1.15.0+ {: .label .label-green } When a tool has no `param` or `params` declaration, RubyLLM builds a JSON Schema from `execute` keyword arguments: ```ruby class Weather < RubyLLM::Tool desc "Gets current weather for a location" def execute(latitude:, longitude:, units: "metric") # ... end end ``` Required keywords become required string parameters. Optional keywords become optional string parameters. A tool with `def execute` receives an empty object schema. Ruby method signatures do not expose reliable JSON Schema types or descriptions, so add explicit declarations when those details matter. ### Using the `param` Helper for Simple Tools If your tool just needs a few scalar arguments with descriptions or non-string types, use the `param` helper. RubyLLM translates these declarations into JSON Schema under the hood. ```ruby class Distance < RubyLLM::Tool desc "Calculates distance between two cities" param :origin, desc: "Origin city name" param :destination, description: "Destination city name" param :units, type: :string, desc: "Unit system (metric or imperial)", required: false def execute(origin:, destination:, units: "metric") # ... end end ``` ### params DSL {: .d-inline-block } v1.9.0+ {: .label .label-green } When you need nested objects, arrays, enums, or union types, the `params do ... end` DSL produces the JSON Schema that function-calling models expect while staying Ruby-flavoured. ```ruby class Scheduler < RubyLLM::Tool desc "Books a meeting" params do object :window, description: "Time window to reserve" do string :start, description: "ISO8601 start time" string :finish, description: "ISO8601 end time" end array :participants, of: :string, description: "Email addresses to invite" any_of :format, description: "Optional meeting format" do string enum: %w[virtual in_person] null end end def execute(window:, participants:, format: nil) # ... end end ``` RubyLLM bundles the DSL through [`ruby_llm-schema`](https://github.com/danielfriis/ruby_llm-schema), so every project has the same schema builders out of the box. ### Supplying JSON Schema Manually {: .d-inline-block } v1.9.0+ {: .label .label-green } Prefer to own the JSON Schema yourself? Pass a schema hash (or a class/object responding to `#to_json_schema`) directly to `params`: ```ruby class Lookup < RubyLLM::Tool description "Performs catalog lookups" params type: "object", properties: { sku: { type: "string", description: "Product SKU" }, locale: { type: "string", description: "Country code", default: "US" } }, required: %w[sku], additionalProperties: false, strict: true def execute(sku:, locale: "US") # ... end end ``` RubyLLM normalizes symbol keys, deep duplicates the schema, and sends it to providers unchanged. This gives you full control when you need it. ## Returning Rich Content from Tools Tools can return `RubyLLM::Content` objects with file attachments, allowing you to pass images, documents, or other files from your tools to the AI model: ```ruby class AnalyzeTool < RubyLLM::Tool description "Analyzes data and returns results with visualizations" param :query, desc: "Analysis query" def execute(query:) # Generate analysis and create visualization chart_path = generate_chart(query) # Return Content with text and attachments RubyLLM::Content.new( "Analysis complete for: #{query}", [chart_path] # Attach the generated chart (array of paths/blobs) ) end private def generate_chart(query) # Your chart generation logic "/tmp/chart_#{Time.now.to_i}.png" end end chat = RubyLLM.chat.with_tool(AnalyzeTool) response = chat.ask("Analyze sales trends for Q4") # The AI receives both the text and the chart image ``` When a tool returns a `Content` object: - The text and attachments are preserved in the conversation history - Vision-capable models can see and analyze attached images - The AI can reference the attachments in its response This is particularly useful for: - **Data visualization:** Return charts, graphs, or diagrams - **Document processing:** Pass PDFs or documents for the AI to analyze - **Image generation:** Return generated or processed images - **Multi-modal workflows:** Combine text results with visual elements ## Custom Initialization Tools can have custom initialization: ```ruby class DocumentSearch < RubyLLM::Tool description "Searches documents by relevance" param :query, desc: "The search query" param :limit, type: :integer, desc: "Maximum number of results", required: false def initialize(database) @database = database end def execute(query:, limit: 5) # Search in @database @database.search(query, limit: limit) end end # Initialize with dependencies search_tool = DocumentSearch.new(MyDatabase) chat.with_tool(search_tool) ``` ## Using Tools in Chat Attach tools to a `Chat` instance using `with_tool` or `with_tools`. ```ruby # Create a chat instance chat = RubyLLM.chat(model: 'gpt-5.4') # Use a model that supports tools # Instantiate your tool if it requires arguments, otherwise use the class weather_tool = Weather.new # Add the tool(s) to the chat chat.with_tool(weather_tool) # Or add multiple: chat.with_tools(WeatherLookup, AnotherTool.new) # Replace all tools with new ones chat.with_tools(NewTool, AnotherTool, replace: true) # Clear all tools chat.with_tools(replace: true) # Ask a question that should trigger the tool response = chat.ask "What's the current weather like in Berlin? (Lat: 52.52, Long: 13.40)" puts response.content # => "Current weather at 52.52, 13.4: Temperature: 12.5°C, Wind Speed: 8.3 km/h, Conditions: Mainly clear, partly cloudy, and overcast." ``` ### Tool Call Controls {: .d-inline-block } v1.13.0+ {: .label .label-green } Control tool behavior with two options: - `choice` controls which tools the model is allowed/required to use. - `calls` controls how many tool calls can appear in one assistant response. #### Tool Choice (`choice`) Use `choice` to control whether the model can call tools and which one it can call. ```ruby # Model decides if a tool is needed chat.with_tools(Weather, Calculator, choice: :auto) # Model must call a tool chat.with_tools(Weather, Calculator, choice: :required) # Disable tool calls chat.with_tools(Weather, Calculator, choice: :none) # Force one specific tool (symbol or class) chat.with_tools(Weather, Calculator, choice: :weather) chat.with_tools(Weather, Calculator, choice: Weather) ``` Valid values: - `:auto` - `:required` - `:none` - tool name symbol/string or `ToolClass` > With `:required` or specific tool choices, `tool_choice` is automatically reset to `nil` after tool execution to prevent infinite loops. {: .note } #### "Parallel" Tool Calling (`calls`) > Providers usually call this **parallel tool calling**. We call it `calls` because "parallel" can be misleading: tools are not executed in parallel unless RubyLLM is configured to run them concurrently. `calls` describes the actual behavior directly: `:many` means multiple tool calls in one assistant response, `:one` means one tool call in one assistant response. {: .note } Use `calls` to control how many tool calls the model may return in a single assistant response. ```ruby # Allow multiple tool calls in one response chat.with_tools(Weather, Calculator, calls: :many) # Allow one tool call in one response chat.with_tools(Weather, Calculator, calls: :one) # equivalent: chat.with_tools(Weather, Calculator, calls: 1) ``` Valid values: - `:many` - `:one` - `1` If `calls` is not provided, RubyLLM uses provider/model defaults, which are usually equivalent to `calls: :many`. > Tool choice and call-count controls are provider/model dependent. {: .note } ### Concurrent Tool Execution {: .d-inline-block } v1.16.0+ {: .label .label-green } When a model returns multiple tool calls in one response, RubyLLM executes them sequentially by default. For I/O-bound tools, opt in to concurrent execution: ```ruby chat.with_tools(Weather, StockPrice, Currency, concurrency: true) ``` `concurrency: true` uses Ruby threads and requires no extra dependencies. You can also choose a mode explicitly: ```ruby chat.with_tools(Weather, StockPrice, Currency, concurrency: :threads) chat.with_tools(Weather, StockPrice, Currency, concurrency: :fibers) ``` The `:fibers` mode uses the optional `async` gem: ```ruby gem "async" ``` Enable concurrent tool execution globally: ```ruby RubyLLM.configure do |config| config.tool_concurrency = true end ``` Use `:threads`, `:fibers`, `true`, or `false`. Override it per chat when needed: ```ruby chat.with_tools(Weather, StockPrice, concurrency: false) ``` Rails chat records use the same setting and override: ```ruby chat_record.with_tools(Weather, StockPrice, concurrency: false) chat_record.with_tools(Weather, StockPrice, concurrency: :threads) chat_record.with_tools(Weather, StockPrice, concurrency: :fibers) ``` With concurrency enabled, tool results are added back to the conversation as each tool finishes. RubyLLM waits for all tool results before asking the model for the next response. ### Model Compatibility RubyLLM will attempt to use tools with any model. If the model doesn't support function calling, the provider will return an appropriate error when you call `ask`. ## The Tool Execution Flow When you `ask` a question that the model determines requires a tool: 1. **User Query:** Your message is sent to the model. 2. **Model Decision:** The model analyzes the query and its available tools (based on their descriptions). It decides the `WeatherLookup` tool is needed and extracts the latitude and longitude. 3. **Tool Call Request:** The model responds *not* with text, but with a special message indicating a tool call, including the tool name (`weather_lookup`) and arguments (`{ latitude: 52.52, longitude: 13.40 }`). 4. **RubyLLM Execution:** RubyLLM receives this tool call request. It finds the registered `WeatherLookup` tool and calls its `execute(latitude: 52.52, longitude: 13.40)` method. 5. **Tool Result:** Your `execute` method runs (calling the weather API) and returns a result string. 6. **Result Sent Back:** RubyLLM sends this result back to the AI model in a new message with the `:tool` role. 7. **Final Response Generation:** The model receives the tool result and uses it to generate a natural language response to your original query. 8. **Final Response Returned:** RubyLLM returns the final `RubyLLM::Message` object containing the text generated in step 7. This entire multi-step process happens behind the scenes within a single `chat.ask` call when a tool is invoked. ## Monitoring Tool Calls with Callbacks You can monitor tool execution using additive callbacks to track when tools are called and what they return. Available from v1.15+. ```ruby chat = RubyLLM.chat(model: 'gpt-5.4') .with_tool(Weather) .before_tool_call do |tool_call| # Called when the AI decides to use a tool puts "Calling tool: #{tool_call.name}" puts "Arguments: #{tool_call.arguments}" end .after_tool_result do |result| # Called after the tool returns its result puts "Tool returned: #{result}" end response = chat.ask "What's the weather in Paris?" # Output: # Calling tool: weather # Arguments: {"latitude": "48.8566", "longitude": "2.3522"} # Tool returned: {"temperature": 15, "conditions": "Partly cloudy"} ``` These callbacks are useful for: - **Logging and Analytics:** Track which tools are used most frequently - **UI Updates:** Show loading states or progress indicators - **Debugging:** Monitor tool inputs and outputs in production - **Auditing:** Record tool usage for compliance or billing ### Example: Limiting Tool Calls To prevent excessive API usage or infinite loops, you can use callbacks to limit tool calls: ```ruby # Limit total tool calls per conversation call_count = 0 max_calls = 10 chat = RubyLLM.chat(model: 'gpt-5.4') .with_tool(Weather) .before_tool_call do |tool_call| call_count += 1 if call_count > max_calls raise "Tool call limit exceeded (#{max_calls} calls)" end end # The conversation will stop if it tries to use tools more than 10 times chat.ask("Check weather for every major city...") ``` > Raising an exception in `before_tool_call` breaks the conversation flow - the LLM expects a tool response after requesting a tool call. This can leave the chat in an inconsistent state. Consider using better models or clearer tool descriptions to prevent loops instead of hard limits. {: .warning } ## Advanced Tool Metadata ### Provider-Specific Parameters {: .d-inline-block } v1.9.0+ {: .label .label-green } Some providers accept additional metadata alongside the JSON Schema—for example, Anthropic’s `cache_control` hints. Use `with_params` to declare these once on the tool class and RubyLLM will merge them into the payload when the provider supports the keys. ```ruby class TodoTool < RubyLLM::Tool description "Adds a task to the shared TODO list" params do string :title, description: "Human-friendly task description" end with_params cache_control: { type: "ephemeral" } def execute(title:) Todo.create!(title:) "Added “#{title}” to the list." end end ``` Provider metadata is passed through verbatim—turn on `RUBYLLM_DEBUG=true` if you want to inspect the final payload while experimenting. ## Advanced: Halting Tool Continuation After a tool executes, the LLM normally continues the conversation to explain what happened. In rare cases, you might want to skip this and return the tool result directly. ### What halt does The `halt` helper stops the LLM from continuing after your tool: ```ruby class SaveFileTool < RubyLLM::Tool description "Save content to a file" param :path, desc: "File path" param :content, desc: "File content" def execute(path:, content:) File.write(path, content) halt "Saved to #{path}" # Returns this directly, no LLM commentary end end # Without halt: LLM adds "I've successfully saved the file to config.yml..." # With halt: Just returns "Saved to config.yml" ``` ### When you might use it - **Token savings:** Skip the LLM's summary for simple confirmations - **Sub-agent delegation:** When another agent fully handles the response - **Precise responses:** When you need exact output without LLM interpretation > The LLM's continuation is usually helpful - it provides context and natural language formatting. Only use `halt` when you specifically need to bypass this behavior. {: .warning } ### Example with sub-agents ```ruby class DelegateTool < RubyLLM::Tool description "Delegate to expert" param :query, desc: "The query" def execute(query:) response = RubyLLM.chat .with_instructions("You are an expert...") .ask(query) { |chunk| print chunk } # Stream to user halt response.content # Skip router's commentary end end ``` > **Sub-agents work perfectly without halt!** You can create sub-agents and stream their responses without using `halt`. The router will simply summarize what the sub-agent said, which is often helpful. Use `halt` only when you specifically want to skip the router's summary. {: .note } ## Model Context Protocol (MCP) Support For MCP server integration, check out the community-maintained [`ruby_llm-mcp`](https://github.com/patvice/ruby_llm-mcp) gem. ## Debugging Tools Set the `RUBYLLM_DEBUG` environment variable to see detailed logging, including tool calls and results. ```bash export RUBYLLM_DEBUG=true # Run your script ``` You'll see log lines similar to: ``` D, [timestamp] -- RubyLLM: Tool weather_lookup called with: {:latitude=>52.52, :longitude=>13.4} D, [timestamp] -- RubyLLM: Tool weather_lookup returned: "Current weather at 52.52, 13.4: Temperature: 12.5°C, Wind Speed: 8.3 km/h, Conditions: Mainly clear, partly cloudy, and overcast." ``` See the [Error Handling Guide](/error-handling/#debugging) for more on debugging. ## Error Handling in Tools Tools should handle errors based on whether they're recoverable: - **Recoverable errors** (invalid parameters, external API failures): Return `{ error: "description" }` - **Unrecoverable errors** (missing configuration, database down): Raise an exception ```ruby def execute(location:) return { error: "Location too short" } if location.length < 3 # Fetch weather data... rescue Faraday::ConnectionFailed { error: "Weather service unavailable" } end ``` See the [Error Handling Guide](/error-handling/#handling-errors-within-tools) for more discussion. ## Security Considerations > Treat any arguments passed to your `execute` method as potentially untrusted user input, as the AI model generates them based on the conversation. {: .warning } * **NEVER** use methods like `eval`, `system`, `send`, or direct SQL interpolation with raw arguments from the AI. * **Validate and Sanitize:** Always validate parameter types, ranges, formats, and allowed values. Sanitize strings to prevent injection attacks if they are used in database queries or system commands (though ideally, avoid direct system commands). * **Principle of Least Privilege:** Ensure the code within `execute` only has access to the resources it absolutely needs. ## Next Steps * [Chatting with AI Models](/chat/) * [Streaming Responses](/streaming/) (See how tools interact with streaming) * [Rails Integration](/rails/) (Persisting tool calls and results) * [Error Handling](/error-handling/) --- ### Stream Responses URL: https://rubyllm.com/streaming/ Date: 2026-08-08 # Stream Responses {: .no_toc } Learn how to display AI responses in real-time as they're generated {: .fs-6 .fw-300 } ## Table of contents {: .no_toc .text-delta } 1. TOC {:toc} --- After reading this guide, you will know: * How to initiate a streaming chat request. * How to process the streamed `Chunk` objects. * How the final accumulated message is handled. * How to integrate streaming with web frameworks like Rails and Sinatra. * How streaming interacts with Tools. * Performance considerations for streaming. ## Basic Streaming To stream responses, simply provide a block to the `ask` method on a `Chat` object. ```ruby chat = RubyLLM.chat puts "Assistant:" chat.ask "Write a short story about a adventurous ruby gem." do |chunk| # The block receives RubyLLM::Chunk objects as they arrive print chunk.content # Print content fragment immediately end # => (Output appears incrementally) Once upon a time, in the vast digital... ``` RubyLLM normalizes different provider streaming formats (like Server-Sent Events) into standardized `Chunk` objects. ## Understanding Chunks Each object yielded to the block is an instance of `RubyLLM::Chunk`, which inherits from `RubyLLM::Message`. It contains the partial information received in that specific part of the stream. Key attributes of a `Chunk`: * `chunk.content`: The text fragment received in this chunk (can be `nil` or empty for some chunks, especially those containing only metadata or tool calls). * `chunk.role`: Always `:assistant` for streamed response chunks. * `chunk.model_id`: The model generating the response (usually present). * `chunk.tool_calls`: A hash containing partial or complete tool call information if the model is invoking a [Tool](/tools/). The arguments might be streamed incrementally. * `chunk.tokens&.input`: Standard input tokens for the request (often `nil` until the final chunk). From v1.15 onward, cache reads and writes are exposed separately as `chunk.tokens&.cache_read` and `chunk.tokens&.cache_write` when providers report them. * `chunk.tokens&.output`: Cumulative billable output tokens *up to this chunk* (behavior varies by provider, often only accurate in the final chunk). From v1.15 onward, this includes thinking/reasoning tokens when the provider bills them as output. * `chunk.thinking`: Optional thinking output when providers stream it. > Do not rely on token counts being present or accurate in every chunk. They are typically finalized only in the last chunk or the final returned message. {: .warning } ## Accumulated Response Even when you provide a block for streaming, the `ask` method *still* returns the complete, final `RubyLLM::Message` object once the entire response (including any tool interactions) is finished. ```ruby chat = RubyLLM.chat final_message = nil puts "Assistant:" final_message = chat.ask "Write a short haiku about programming." do |chunk| print chunk.content end # The block finishes, and ask returns the complete message puts "\n--- Final Message ---" puts final_message.content # => Code flows like water, # => Logic builds a new world now, # => Bugs swim in the stream. total_tokens = final_message.tokens.input.to_i + final_message.tokens.output.to_i + final_message.tokens.cache_read.to_i + final_message.tokens.cache_write.to_i puts "Total Tokens: #{total_tokens}" ``` This allows you to easily get the final result for storage or further processing, even after handling the stream for UI purposes. ## Web Application Integration Streaming is particularly useful in web applications for providing immediate feedback. ### Rails with Turbo Streams In a Rails application using Hotwire/Turbo, you can broadcast stream updates from a background job. ```ruby # app/jobs/chat_stream_job.rb class ChatStreamJob < ApplicationJob queue_as :default def perform(chat_id, user_message, stream_target_id) chat = Chat.find(chat_id) # Assuming acts_as_chat model full_response = "" # Broadcast an initial placeholder Turbo::StreamsChannel.broadcast_replace_to( "chat_#{chat.id}", target: stream_target_id, partial: "messages/streaming_message", locals: { content: "Thinking..." } ) chat.ask(user_message) do |chunk| full_response << (chunk.content || "") # Broadcast updates, replacing the placeholder content Turbo::StreamsChannel.broadcast_replace_to( "chat_#{chat.id}", target: stream_target_id, partial: "messages/streaming_message", locals: { content: full_response } # Send accumulated content ) end # Optionally broadcast a final state or confirmation end end # app/views/messages/_streaming_message.html.erb #
# <%= simple_format(content) %> #
# In your controller: # target_id = "stream_#{SecureRandom.uuid}" # Render initial UI with
# ChatStreamJob.perform_later(chat.id, params[:message], target_id) ``` See the [Rails Integration Guide](/rails/#streaming-responses-with-hotwireturbo) for more detailed examples. ### Sinatra with Server-Sent Events (SSE) SSE is a natural fit for streaming text responses. ```ruby require 'sinatra' require 'ruby_llm' # ... configuration ... get '/stream_chat' do content_type 'text/event-stream' stream(:keep_open) do |out| chat = RubyLLM.chat begin chat.ask(params[:prompt] || "Tell me a fun fact.") do |chunk| # Send each content chunk as an SSE data event out << "data: #{chunk.content.to_json}\n\n" if chunk.content end # Signal completion out << "event: complete\ndata: {}\n\n" rescue => e # Signal error out << "event: error\ndata: #{ { error: e.message }.to_json }\n\n" ensure out.close end end end ``` ## Error Handling During Streaming Errors (like network issues, rate limits, or provider errors) can occur mid-stream. The `ask` method will raise the appropriate `RubyLLM::Error` subclass after the block execution finishes or is interrupted by the error. ```ruby begin chat = RubyLLM.chat puts "Assistant:" chat.ask("Generate a very long response...") do |chunk| print chunk.content # Potential error occurs here end rescue RubyLLM::Error => e puts "\n--- Error during streaming ---" puts "Error Type: #{e.class}" puts "Message: #{e.message}" # Check e.response for more details if needed end ``` Refer to the [Error Handling Guide](/error-handling/) for details on specific error types. ## Streaming with Tools When a chat interaction involves [Tools](/tools/), the streaming behavior has distinct phases: 1. **Initial Response Stream:** Chunks are yielded as the model generates text *up to* the point where it decides to call a tool. 2. **Tool Call Chunk(s):** One or more chunks containing `chunk.tool_calls` information are yielded. The arguments might be streamed incrementally depending on the provider. 3. **Pause:** Streaming pauses while RubyLLM executes your tool's `execute` method. 4. **Resumed Response Stream:** After the tool result is sent back to the model, streaming resumes, yielding chunks containing the model's final response incorporating the tool's output. ```ruby chat = RubyLLM.chat(model: 'gpt-5.4').with_tool(Weather) # Assumes Weather tool is defined puts "Assistant:" chat.ask("What's the weather in Berlin (52.52, 13.40)?") do |chunk| if chunk.tool_calls puts "\n[TOOL CALL DETECTED: #{chunk.tool_calls.values.first.name}]" # Arguments might be partial here: chunk.tool_calls.values.first.arguments elsif chunk.content print chunk.content end end # Output might look like: # Assistant: # Okay, let me check the weather for Berlin. # [TOOL CALL DETECTED: weather] # Pause while tool executes # The current weather in Berlin (52.52, 13.4) is 15°C with wind at 10 km/h. ``` Your streaming block needs to be prepared to handle chunks that contain text content, tool call information, or potentially just metadata. ## Next Steps * [Using Tools](/tools/) * [Rails Integration](/rails/) * [Error Handling](/error-handling/) --- ### Embeddings URL: https://rubyllm.com/embeddings/ Date: 2026-08-08 # Embeddings {: .no_toc } Transform text into numerical vectors for semantic search, recommendations, and content similarity {: .fs-6 .fw-300 } ## Table of contents {: .no_toc .text-delta } 1. TOC {:toc} --- After reading this guide, you will know: * How to generate embeddings for single or multiple texts. * How to choose specific embedding models. * How to use the results, including calculating similarity. * How to handle errors during embedding generation. * Best practices for performance and large datasets. * How to integrate embeddings in a Rails application. ## Basic Embedding Generation The simplest way to create an embedding is with the global `RubyLLM.embed` method: ```ruby # Create an embedding for a single text embedding = RubyLLM.embed("Ruby is a programmer's best friend") # The vector representation (an array of floats) vector = embedding.vectors puts "Vector dimension: #{vector.length}" # e.g., 1536 for text-embedding-3-small # Access metadata puts "Model used: #{embedding.model}" puts "Input tokens: #{embedding.input_tokens}" ``` ## Embedding Multiple Texts You can efficiently embed multiple texts in a single API call: ```ruby texts = ["Ruby", "Python", "JavaScript"] embeddings = RubyLLM.embed(texts) # Each text gets its own vector within the `vectors` array puts "Number of vectors: #{embeddings.vectors.length}" # => 3 puts "First vector dimensions: #{embeddings.vectors.first.length}" puts "Model used: #{embeddings.model}" puts "Total input tokens: #{embeddings.input_tokens}" ``` > Batching multiple texts is generally more performant and cost-effective than making individual requests for each text. {: .note } ## Choosing Models By default, RubyLLM uses a capable default embedding model (like OpenAI's `text-embedding-3-small`), but you can specify a different one using the `model:` argument. ```ruby # Use a specific OpenAI model embedding_large = RubyLLM.embed( "This is a test sentence", model: "text-embedding-3-large" ) # Or use a Google model embedding_google = RubyLLM.embed( "This is another test sentence", model: "text-embedding-004" # Google's model ) # Use a model not in the registry (useful for custom endpoints) embedding_custom = RubyLLM.embed( "Custom model test", model: "my-custom-embedding-model", provider: :openai, assume_model_exists: true ) ``` You can configure the default embedding model globally: ```ruby RubyLLM.configure do |config| config.default_embedding_model = "text-embedding-3-large" end ``` Refer to the [Working with Models Guide](/models/) for details on finding available embedding models and their capabilities. ## Choosing Dimensions Each embedding model has its own default output dimensions. For example, OpenAI's `text-embedding-3-small` outputs 1536 dimensions by default, while `text-embedding-3-large` outputs 3072 dimensions. RubyLLM allows you to specify these dimensions per request: ```ruby embedding = RubyLLM.embed( "This is a test sentence", model: "text-embedding-3-small", dimensions: 512 ) ``` This is particularly useful when: - Working with vector databases that have specific dimension requirements - Ensuring consistent dimensionality across different requests - Optimizing storage and query performance in your vector database Note that not all models support custom dimensions. If you specify dimensions that aren't supported by the chosen model, RubyLLM will use the model's default dimensions. ## Using Embedding Results ### Vector Properties The embedding result contains useful information: ```ruby embedding = RubyLLM.embed("Example text") # The vector representation puts embedding.vectors.class # => Array puts embedding.vectors.first.class # => Float # The vector dimensions puts embedding.vectors.first.length # => 1536 # The model used puts embedding.model # => "text-embedding-3-small" ``` ## Using Embedding Results A primary use case for embeddings is measuring the semantic similarity between texts. Cosine similarity is a common metric. ```ruby require 'matrix' # Ruby's built-in Vector class requires 'matrix' embedding1 = RubyLLM.embed("I love Ruby programming") embedding2 = RubyLLM.embed("Ruby is my favorite language") # Convert embedding vectors to Ruby Vector objects vector1 = Vector.elements(embedding1.vectors) vector2 = Vector.elements(embedding2.vectors) # Calculate cosine similarity (value between -1 and 1, closer to 1 means more similar) similarity = vector1.inner_product(vector2) / (vector1.norm * vector2.norm) puts "Similarity: #{similarity.round(4)}" # => e.g., 0.9123 ``` ## Error Handling Embedding API calls can fail for various reasons. Handle errors gracefully: ```ruby begin embedding = RubyLLM.embed("Your text here") # Process embedding... rescue RubyLLM::Error => e # Handle API errors puts "Embedding failed: #{e.message}" end ``` For comprehensive error handling patterns and retry strategies, see the [Error Handling Guide](/error-handling/). ## Performance and Best Practices * **Batching:** Always embed multiple texts in a single call when possible. `RubyLLM.embed(["text1", "text2"])` is much faster than calling `RubyLLM.embed` twice. * **Caching/Persistence:** Embeddings are generally static for a given text and model. Store generated embeddings in your database or cache instead of regenerating them frequently. * **Dimensionality:** Different models produce vectors of different lengths (dimensions). Ensure your storage and similarity calculation methods handle the correct dimensionality (e.g., `text-embedding-3-small` uses 1536 dimensions, `text-embedding-3-large` uses 3072). * **Normalization:** Some vector databases and similarity algorithms perform better if vectors are normalized (scaled to have a length/magnitude of 1). Check the documentation for your specific use case or database. ## Rails Integration Example In a Rails application using PostgreSQL with the `pgvector` extension, you might store and search embeddings like this: ```ruby # Migration: # add_column :documents, :embedding, :vector, limit: 1536 # Match your model's dimensions # app/models/document.rb class Document < ApplicationRecord has_neighbors :embedding # From the neighbor gem for pgvector # Automatically generate embedding before saving if content changed before_save :generate_embedding, if: :content_changed? # Scope for nearest neighbor search scope :search_by_similarity, ->(query_text, limit: 5) { query_embedding = RubyLLM.embed(query_text).vectors nearest_neighbors(:embedding, query_embedding, distance: :cosine).limit(limit) } private def generate_embedding return if content.blank? puts "Generating embedding for Document #{id}..." begin embedding_result = RubyLLM.embed(content) # Uses default embedding model self.embedding = embedding_result.vectors rescue RubyLLM::Error => e errors.add(:base, "Failed to generate embedding: #{e.message}") # Prevent saving if embedding fails (optional, depending on requirements) throw :abort end end end # Usage in controller or console: # Document.create(title: "Intro to Ruby", content: "Ruby is a dynamic language...") # results = Document.search_by_similarity("What is Ruby?") # results.each { |doc| puts "- #{doc.title}" } ``` > This Rails example assumes you have the `pgvector` extension enabled in PostgreSQL and are using a gem like `neighbor` for ActiveRecord integration. {: .note } ## Next Steps Now that you understand embeddings, you might want to explore: * [Chatting with AI Models](/chat/) for interactive conversations. * [Using Tools](/tools/) to extend AI capabilities. * [Error Handling](/error-handling/) for building robust applications. --- ### Image Generation URL: https://rubyllm.com/image-generation/ Date: 2026-08-08 # Image Generation {: .no_toc } Generate images from text descriptions using AI models like DALL-E 3 and Imagen {: .fs-6 .fw-300 } ## Table of contents {: .no_toc .text-delta } 1. TOC {:toc} --- After reading this guide, you will know: * How to generate images from text prompts. * How to edit existing images with source images and masks. * How to select different image generation models. * How to specify image sizes (for supported models). * How to access and save generated image data (URL or Base64). * How to inspect token usage and calculate image costs. * How to integrate image generation with Rails Active Storage. * Tips for writing effective image prompts. * How to handle errors during image generation. ## Basic Image Generation The simplest way to generate an image is using the global `RubyLLM.paint` method: ```ruby # Generate an image using the default image model image = RubyLLM.paint("A photorealistic image of a red panda coding Ruby on a laptop") # For models returning a URL: if image.url puts "Image URL: #{image.url}" # => "https://oaidalleapiprodscus.blob.core.windows.net/..." end # For models returning Base64 data (like Imagen): if image.base64? puts "MIME Type: #{image.mime_type}" # => "image/png" or similar puts "Data size: ~#{image.data.length} bytes" end # Some models revise the prompt for better results if image.revised_prompt puts "Revised Prompt: #{image.revised_prompt}" # => "A photorealistic depiction of a red panda intently coding Ruby..." end puts "Model Used: #{image.model_id}" ``` The `paint` method abstracts the differences between provider APIs. ## Token Usage and Costs {: .d-inline-block } v1.15+ {: .label .label-green } When providers return image token usage, images expose the same cost shape as chats and messages: ```ruby image = RubyLLM.paint("A small watercolor robot", model: "gpt-image-1") image.tokens.input image.tokens.output image.cost.input image.cost.output image.cost.total ``` Image costs use provider usage data plus pricing from the model registry. For models that report separate text and image input token details, RubyLLM applies the right pricing bucket to each part and returns the combined value as `image.cost.input`. ## Editing Existing Images {: .d-inline-block } v1.15+ {: .label .label-green } Some models, such as OpenAI's GPT Image models, can edit an existing image instead of generating from scratch. Use `with:` to pass one or more source images, and `mask:` when you want to constrain which parts of the image may change. ```ruby image = RubyLLM.paint( "Turn the logo green and keep the background transparent", model: "gpt-image-1", with: "logo.png" ) ``` `with:` accepts the same kinds of sources RubyLLM already supports elsewhere for attachments: local files, URLs, IO-like objects, and Active Storage attachments. ### Editing With Multiple Images ```ruby image = RubyLLM.paint( "Combine these references into a postcard illustration", model: "gpt-image-1", with: ["person.png", "style-reference.png"] ) ``` ### Editing With a Mask ```ruby image = RubyLLM.paint( "Replace only the background with a sunset sky", model: "gpt-image-1", with: "portrait.png", mask: "portrait-mask.png", params: { size: "1024x1024" } ) ``` ## Choosing Models By default, RubyLLM uses the model specified in `config.default_image_model`, but you can specify a different one. ```ruby # Explicitly use GPT-Image-1 image_dalle = RubyLLM.paint( "Impressionist painting of a Parisian cafe", model: "gpt-image-1.5" ) # Use Google's Imagen 3 image_imagen = RubyLLM.paint( "Cyberpunk city street at night, raining, neon signs", model: "imagen-3.0-generate-002" ) # Use a model not in the registry (useful for custom endpoints) image_custom = RubyLLM.paint( "A sunset over mountains", model: "my-custom-image-model", provider: :openai, assume_model_exists: true ) ``` You can configure the default model globally: ```ruby RubyLLM.configure do |config| config.default_image_model = "gpt-image-1.5" # Or another available image model ID end ``` Refer to the [Working with Models Guide](/models/) and the [Available Models Guide](/available-models/) to find image models. ## Image Sizes Some models, like DALL-E 3, allow you to specify the desired image dimensions via the `size:` argument. ```ruby # Standard square (1024x1024 - default for DALL-E 3) image_square = RubyLLM.paint("a fluffy white cat", size: "1024x1024") # Wide landscape (1792x1024 for DALL-E 3) image_landscape = RubyLLM.paint( "a panoramic mountain landscape at dawn", size: "1792x1024" ) # Tall portrait (1024x1792 for DALL-E 3) image_portrait = RubyLLM.paint( "a knight standing before a castle gate", size: "1024x1792" ) ``` > Not all models support size customization. If a size is specified for a model that doesn't support it (like Google Imagen), RubyLLM may log a debug message indicating the size parameter is ignored. Check the provider's documentation or the [Available Models Guide](/available-models/) for supported sizes. {: .note } ## Working with Generated Images The `RubyLLM::Image` object provides access to the generated image data and metadata. ### Accessing Image Data * `image.url`: Returns the URL for providers like OpenAI. `nil` otherwise. * `image.data`: Returns the Base64-encoded image data string for providers like Google (Imagen). `nil` otherwise. * `image.mime_type`: Returns the MIME type (e.g., `"image/png"`, `"image/jpeg"`). * `image.base64?`: Returns `true` if the image data is Base64-encoded, `false` otherwise. ### Saving Images Locally The `save` method works regardless of whether the image was delivered via URL or Base64. It fetches the data if necessary and writes it to the specified file path. ```ruby # Generate an image image = RubyLLM.paint("A steampunk mechanical owl") # Save the image to a local file begin saved_path = image.save("steampunk_owl.png") puts "Image saved to #{saved_path}" rescue => e puts "Failed to save image: #{e.message}" end ``` ### Getting Raw Image Blob The `to_blob` method returns the raw binary image data (decoded from Base64 or downloaded from URL). This is useful for integration with other libraries or frameworks. ```ruby image = RubyLLM.paint("Abstract geometric patterns in pastel colors") image_blob = image.to_blob # Now you can use image_blob, e.g., upload to S3, process with MiniMagick, etc. puts "Image blob size: #{image_blob.bytesize} bytes" ``` ### Rails Active Storage Integration Use `to_blob` to easily attach generated images to Active Storage attributes. ```ruby # In a Rails model or job class Product < ApplicationRecord has_one_attached :generated_image end def generate_and_attach_image(product, prompt) puts "Generating image for Product #{product.id}..." image = RubyLLM.paint(prompt) # Or another model filename = "#{product.slug}-#{Time.current.to_i}.png" # Use StringIO to provide an IO object to Active Storage image_io = StringIO.new(image.to_blob) product.generated_image.attach( io: image_io, filename: filename, content_type: image.mime_type || 'image/png' # Use detected MIME type or default ) puts "Image attached successfully." # Optionally save metadata product.update( image_prompt: prompt, image_revised_prompt: image.revised_prompt, image_model: image.model_id ) rescue RubyLLM::Error => e puts "Image generation failed: #{e.message}" # Handle error appropriately rescue => e puts "Failed to attach image: #{e.message}" # Handle attachment error end # Usage: # product = Product.find(1) # generate_and_attach_image(product, "A sleek, modern logo for 'RubyLLM'") ``` ## Prompt Engineering for Images Crafting effective prompts is key to getting the desired image. Be descriptive! ```ruby # Simple prompt - often yields generic results image1 = RubyLLM.paint("dog") # Detailed prompt - better results image2 = RubyLLM.paint( "A photorealistic image of a golden retriever puppy playing fetch " \ "in a sunny park, shallow depth of field, captured with a DSLR camera." ) # Specify style image3 = RubyLLM.paint( "A majestic mountain range, oil painting in the style of Bob Ross" ) ``` **Tips for Better Prompts:** * **Subject:** Be specific (e.g., "red panda" vs. "animal"). * **Action/Setting:** Describe what's happening and where (e.g., "coding on a laptop in a cozy library"). * **Style:** Specify artistic style ("photorealistic", "watercolor", "pixel art", "impressionist painting", "3D render"). * **Details:** Add adjectives ("fluffy", "ancient", "glowing", "minimalist"). * **Composition:** Mention framing ("close-up", "wide angle", "overhead shot"). * **Lighting:** Describe the light ("soft morning light", "dramatic sunset", "neon glow"). * **Mood:** Convey the feeling ("serene", "chaotic", "mysterious"). ## Error Handling Image generation can fail due to content policy violations, rate limits, or API issues: ```ruby begin image = RubyLLM.paint("Your prompt here") puts "Image URL: #{image.url}" rescue RubyLLM::BadRequestError => e # Often indicates a content policy violation puts "Generation failed: #{e.message}" rescue RubyLLM::Error => e puts "Error: #{e.message}" end ``` See the [Error Handling Guide](/error-handling/) for comprehensive error handling strategies. ## Content Safety AI image generation services have content safety filters. Prompts requesting harmful, explicit, or otherwise prohibited content will usually result in a `BadRequestError`. Avoid generating: * Violent or hateful imagery. * Sexually explicit content. * Images of real people (especially public figures without consent, though policies vary). * Direct copies of copyrighted characters or artwork. ## Performance Considerations Image generation can take several seconds (typically 5-20 seconds depending on the model and load). * **Use Background Jobs:** In web applications, always perform image generation in a background job (like Sidekiq or GoodJob) to avoid blocking web requests. * **Timeouts:** Configure appropriate network timeouts in RubyLLM (see [Configuration Guide](/configuration/)). * **Caching:** Store generated images (e.g., using Active Storage, cloud storage) rather than regenerating them frequently if the prompt is the same. ## Next Steps * [Chatting with AI Models](/chat/): Learn about conversational AI. * [Embeddings](/embeddings/): Explore text vector representations. * [Error Handling](/error-handling/): Master handling API errors. --- ### Agents URL: https://rubyllm.com/agents/ Date: 2026-08-08 # Agents {: .d-inline-block .no_toc } New in 1.12 {: .label .label-green } Define reusable AI assistants with class-based configuration, runtime context, and prompt conventions {: .fs-6 .fw-300 } ## Table of contents {: .no_toc .text-delta } 1. TOC {:toc} --- After reading this guide, you will know: * How to define agents with a class-based DSL * How to use agents with plain Ruby chats and Rails-backed chats * How runtime context works (`chat`, `inputs`, and lazy evaluation) * How prompt conventions work in `app/prompts` * Which methods are available on agent instances ## What Are Agents? Agents are a class-based way to define a chat setup once and reuse it everywhere. For example, instead of re-adding the same instructions and tools in every controller, job, or service, you define them once in an agent class and call that agent wherever you need it. ```ruby class SupportAgent < RubyLLM::Agent model "gpt-5-nano" instructions "You are a concise support assistant." tools SearchDocs, LookupAccount end response = SupportAgent.new.ask "How do I reset my API key?" ``` In other words, an agent is a named wrapper around the same configuration you would otherwise apply progressively with `chat.with_*` calls (`with_instructions`, `with_tools`, `with_params`, and so on). Agents work in two modes: * Plain Ruby mode via `.chat` (returns `RubyLLM::Chat`) * Rails mode via `.create/.create!/.find` when `chat_model` is configured (returns your ActiveRecord chat model) Example of Rails mode: ```ruby class WorkAssistant < RubyLLM::Agent chat_model Chat # this activates the Rails integration model "gpt-5-nano" instructions "You are a helpful assistant." tools SearchDocs, LookupAccount end chat = WorkAssistant.create!(user: current_user) same_chat = WorkAssistant.find(chat.id) ``` ## Defining an Agent Create a class that inherits from `RubyLLM::Agent` and declare its configuration: ```ruby # app/agents/work_assistant.rb class WorkAssistant < RubyLLM::Agent model "gpt-5-nano" instructions "You are a helpful assistant." tools SearchDocs, LookupAccount temperature 0.2 params max_output_tokens: 256 end ``` Supported class macros: These macros use the same arguments you already know from `RubyLLM.chat(...)` and `Chat#with_*` methods. For example, `model` maps to `RubyLLM.chat(model:, provider:, ...)`, `tools` maps to `with_tools`, `instructions` maps to `with_instructions`, and so on. * `model` (see [Chat Basics](/chat/)) * `tools` (see [Tools](/tools/)) * `instructions` (see [Chat Basics](/chat/)) * `temperature` (see [Chat Basics](/chat/)) * `thinking` (see [Thinking](/thinking/)) * `params` (see [Chat Basics](/chat/)) * `headers` (see [Chat Basics](/chat/)) * `schema` (see [Chat Basics](/chat/)) * `context` (see [Configuration](/configuration/)) * `chat_model` (Rails-backed mode) * `inputs` (declared runtime inputs) `schema` supports: * A schema class (for example `PersonSchema`) - same as `with_schema` * A JSON schema hash - same as `with_schema` * An inline DSL block with `schema do ... end` - agent-specific convenience Inline DSL example: ```ruby class CriticAgent < RubyLLM::Agent schema do string :verdict, enum: ["pass", "revise"] string :feedback end end ``` ## Runtime Context and Inputs Agents support runtime-evaluated values using blocks and lambdas. Declare additional runtime inputs with `inputs`: ```ruby class WorkAssistant < RubyLLM::Agent chat_model Chat inputs :workspace instructions { "You are helping #{workspace.name}" } end ``` `chat` is always available in execution context: * In `.chat` mode, `chat` is a `RubyLLM::Chat` * In `.create/.create!/.find` mode, `chat` is your `chat_model` record This enables Rails-style usage: ```ruby class WorkAssistant < RubyLLM::Agent chat_model Chat instructions current_date_time: -> { Time.current.strftime("%B %d, %Y") }, display_name: -> { chat.user.display_name_or_email }, full_name: -> { chat.user.full_name.presence || chat.user.display_name_or_email } tools do [ TodoTool.new(chat: chat), GoogleDriveListTool.new(user: chat.user), GoogleDriveSearchTool.new(user: chat.user), GoogleDriveReadTool.new(user: chat.user) ] end end ``` Important: values that depend on runtime `chat` must be lazy (blocks/lambdas), not eager class-load expressions. ## Prompt Management and Conventions Agents have prompt conventions built in. ### Default instructions prompt Calling `instructions` with no arguments enables default prompt lookup: ```ruby class WorkAssistant < RubyLLM::Agent chat_model Chat instructions end ``` RubyLLM looks for: * `app/prompts/work_assistant/instructions.txt.erb` If the file exists, it is rendered and used as instructions. If it does not exist, RubyLLM raises `RubyLLM::PromptNotFoundError`. ### Prompt shorthand with locals You can pass locals directly: ```ruby class WorkAssistant < RubyLLM::Agent chat_model Chat instructions display_name: -> { chat.user.display_name_or_email } end ``` This also renders `instructions.txt.erb` for that agent path. ### Prompt helper in runtime blocks Within execution context you can call: ```ruby instructions { prompt("instructions", display_name: chat.user.display_name_or_email) } ``` ### Naming conventions Agent prompt path is derived from class name: * `WorkAssistant` -> `app/prompts/work_assistant/...` * `Admin::SupportAgent` -> `app/prompts/admin/support_agent/...` Prompt extension defaults to `.txt.erb`. ## Using an Agent ### Plain Ruby chat ```ruby chat = WorkAssistant.chat response = chat.ask("Hello") puts response.content ``` `WorkAssistant.chat(...)` returns a configured `RubyLLM::Chat`. ### Instance API You can still instantiate and use an agent instance directly: ```ruby agent = WorkAssistant.new response = agent.ask("Hello") response.cost.total # v1.15+ agent.cost.total # v1.15+ ``` Agent instances delegate the full `RubyLLM::Chat` instance API to the underlying chat object (or to `to_llm` when using a Rails-backed chat model). Delegated methods include: * `model`, `messages`, `tools`, `params`, `headers`, `schema` * `cost` (v1.15+) * `ask`, `say`, `complete` * `add_message`, `reset_messages!`, `each` * `with_tool`, `with_tools` * `with_model`, `with_temperature`, `with_thinking`, `with_context` * `with_params`, `with_headers`, `with_schema` * `before_message`, `after_message`, `before_tool_call`, `after_tool_result` (v1.15+) * Deprecated replacing callbacks: `on_new_message`, `on_end_message`, `on_tool_call`, `on_tool_result` You can always access the wrapped chat object directly via `agent.chat`. ## Rails-Backed Agents Set `chat_model` to use your ActiveRecord chat model: ```ruby class WorkAssistant < RubyLLM::Agent chat_model Chat model "gpt-5-nano" instructions "You are a helpful assistant." tools SearchDocs, LookupAccount end ``` Then you can: ```ruby # Create persisted chat with agent configuration applied chat = WorkAssistant.create!(user: current_user) # Load existing persisted chat with runtime config applied (no DB write) chat = WorkAssistant.find(params[:id]) # Explicitly persist/sync the current agent instructions if you've modified them WorkAssistant.sync_instructions!(chat) ``` `create/create!/find` require `chat_model`. Calling them without it raises an error. Instruction persistence contract in Rails mode: * `create/create!` applies and persists instructions * `find` applies instructions at runtime only (no persistence side effects) * `sync_instructions!` explicitly persists the current agent instructions ### Using an Existing Chat Record If you already have a `Chat` record, pass it to `Agent.new(chat:)` instead of calling `Agent.find`. This applies all agent configuration (instructions, tools, etc.) without an extra database query: ```ruby chat_record = Chat.find(params[:id]) chat = WorkAssistant.new(chat: chat_record) chat.ask("Hello") ``` ## When to Use Agents vs `RubyLLM.chat` Use `RubyLLM.chat` for one-off, inline conversations: ```ruby chat = RubyLLM.chat(model: "gpt-5-nano") chat.with_instructions "Explain this clearly." ``` Use agents when you want named, reusable behavior: ```ruby class WorkAssistant < RubyLLM::Agent model "gpt-5-nano" instructions "You are a helpful assistant." tools SearchDocs, LookupAccount end ``` Think of `RubyLLM.chat` as ad-hoc and `RubyLLM::Agent` as reusable application architecture. ## Agent vs `Chat#with_*` These two styles are equivalent in capability, but optimized for different contexts. Use progressive `Chat#with_*` when configuration is local and one-off: ```ruby chat = RubyLLM.chat(model: "gpt-5-nano") chat.with_instructions("You are a helpful assistant.") chat.with_tools(SearchDocs, LookupAccount) chat.ask("Help me find docs about callbacks.") ``` Use agents when that setup should be centralized and reused: ```ruby class WorkAssistant < RubyLLM::Agent model "gpt-5-nano" instructions "You are a helpful assistant." tools SearchDocs, LookupAccount end WorkAssistant.new.ask("Help me find docs about callbacks.") ``` ## Next Steps * Learn about [Chat Basics](/chat/) * Explore [Tools](/tools/) * Review [Rails Integration](/rails/) --- ### Audio Transcription URL: https://rubyllm.com/audio-transcription/ Date: 2026-08-08 # Audio Transcription {: .d-inline-block .no_toc } v1.9.0+ {: .label .label-green } Convert speech to text with support for multiple languages and speaker diarization {: .fs-6 .fw-300 } ## Table of contents {: .no_toc .text-delta } 1. TOC {:toc} --- After reading this guide, you will know: * How to transcribe audio files to text. * How to identify different speakers with diarization. * How to improve accuracy with language hints and prompts. * How to access segments and timestamps. ## Basic Transcription Transcribe audio with the global `RubyLLM.transcribe` method: ```ruby transcription = RubyLLM.transcribe("meeting.wav") puts transcription.text # => "Welcome to today's meeting. Let's discuss..." puts transcription.model # => "whisper-1" ``` Supports MP3, M4A, WAV, WebM, OGG, and more. ## Choosing Models ```ruby # Whisper-1 (default, good for general use) RubyLLM.transcribe("audio.mp3", model: "whisper-1") # GPT-4o Transcribe (faster, better for technical content) RubyLLM.transcribe("audio.mp3", model: "gpt-4o-transcribe") # GPT-4o Mini Transcribe (fastest, lowest cost) RubyLLM.transcribe("audio.mp3", model: "gpt-4o-mini-transcribe") # Diarization model (identifies speakers) RubyLLM.transcribe("meeting.wav", model: "gpt-4o-transcribe-diarize") # Gemini 2.5 Flash/Pro (Google's multimodal transcription) RubyLLM.transcribe( "lecture.wav", model: "gemini-2.5-flash", prompt: "Return only the verbatim transcript." ) ``` Configure the default globally: ```ruby RubyLLM.configure do |config| config.default_transcription_model = "gpt-4o-transcribe" end ``` ## Language Hints Improve accuracy by specifying the language: ```ruby RubyLLM.transcribe("entrevista.mp3", language: "es") RubyLLM.transcribe("conference.mp3", language: "fr") ``` Use ISO 639-1 codes (en, es, fr, de, etc.). ## Speaker Diarization The diarization model identifies different speakers: ```ruby transcription = RubyLLM.transcribe( "team-meeting.wav", model: "gpt-4o-transcribe-diarize" ) transcription.segments.each do |segment| puts "#{segment['speaker']}: #{segment['text']}" puts " (#{segment['start']}s - #{segment['end']}s)" end # Output: # A: Hi everyone. # (0.5s - 1.2s) # B: Happy to be here. # (2.8s - 3.5s) ``` ### Identifying Known Speakers Provide 2-10 second reference clips to map speakers to names: ```ruby transcription = RubyLLM.transcribe( "team-meeting.wav", model: "gpt-4o-transcribe-diarize", speaker_names: ["Alice", "Bob"], speaker_references: ["alice-voice.wav", "bob-voice.wav"] ) # Now segments use the provided names # Alice: Hi everyone. # Bob: Happy to be here. ``` Speaker references accept file paths, URLs, IO objects, or ActiveStorage attachments. > **Note:** Gemini models currently return plain text transcripts without segment metadata. Use OpenAI's diarization models when you need speaker labels or timestamps. ## Improving Accuracy with Prompts Guide the model with context about technical terms or domain-specific vocabulary: ```ruby RubyLLM.transcribe( "developer-talk.mp3", prompt: "Discussion about Ruby, Rails, PostgreSQL, and Redis." ) RubyLLM.transcribe( "product-demo.mp3", prompt: "Product demo for ZyntriQix, Digique Plus, and CynapseFive." ) ``` ### Gemini prompt tips Gemini treats transcription requests like any other conversation. Use the `prompt:` argument to steer formatting (for example, "Respond with plain text only."), and combine it with `language:` when you want a specific locale in the final transcript. RubyLLM automatically adds the language hint to the Gemini request. ## Segments and Timestamps Access detailed timing information: ```ruby transcription = RubyLLM.transcribe("interview.mp3", model: "gpt-4o-transcribe") puts "Duration: #{transcription.duration} seconds" transcription.segments.each do |segment| puts "#{segment['start']}s - #{segment['end']}s: #{segment['text']}" end ``` For OpenAI word-level timestamps, request verbose JSON with word granularity: ```ruby transcription = RubyLLM.transcribe( "interview.mp3", model: "whisper-1", provider: :openai, response_format: "verbose_json", timestamp_granularities: ["word"] ) transcription.words.each do |word| puts "#{word['start']}s - #{word['end']}s: #{word['word']}" end ``` ## Handling Longer Files The default timeout is 5 minutes. Increase it for longer audio: ```ruby RubyLLM.configure do |config| config.request_timeout = 600 # 10 minutes end ``` The API supports files up to 25 MB. For larger files, use compressed formats (MP3, M4A) or split into chunks. ## Error Handling ```ruby begin transcription = RubyLLM.transcribe("audio.mp3") puts transcription.text rescue RubyLLM::BadRequestError => e puts "Invalid request: #{e.message}" rescue RubyLLM::TimeoutError => e puts "Transcription timed out: #{e.message}" rescue RubyLLM::Error => e puts "Transcription failed: #{e.message}" end ``` ## Next Steps * [Chatting with AI Models](/chat/): Learn about conversational AI. * [Image Generation](/image-generation/): Generate images from text. * [Error Handling](/error-handling/): Master handling API errors. --- ### Moderation URL: https://rubyllm.com/moderation/ Date: 2026-08-08 # Moderation {: .no_toc .d-inline-block } Available in v1.8.0+ {: .label .label-green } Identify potentially harmful content in text using AI moderation models before sending to LLMs {: .fs-6 .fw-300 } ## Table of contents {: .no_toc .text-delta } 1. TOC {:toc} --- After reading this guide, you will know: * How to moderate text content for harmful material. * How to interpret moderation results and category scores. * How to use moderation as a safety layer before LLM requests. * How to configure moderation models and providers. * How to integrate moderation into your application workflows. * Best practices for content safety and user experience. ## Basic Content Moderation The simplest way to moderate content is using the global `RubyLLM.moderate` method: ```ruby # Moderate a text input result = RubyLLM.moderate("This is a safe message about Ruby programming") # Check if content was flagged puts result.flagged? # => false # Access the full results puts result.results # => [{"flagged" => false, "categories" => {...}, "category_scores" => {...}}] # Get basic information puts "Moderation ID: #{result.id}" # => "modr-ABC123..." puts "Model used: #{result.model}" # => "omni-moderation-latest" ``` The `moderate` method returns a `RubyLLM::Moderation` object containing the moderation results from the provider. ## Understanding Moderation Results Moderation results include categories and confidence scores for different types of potentially harmful content: ```ruby result = RubyLLM.moderate("Some user input text") # Check overall flagging status if result.flagged? puts "Content was flagged for: #{result.flagged_categories.join(', ')}" else puts "Content appears safe" end # Examine category scores (0.0 to 1.0, higher = more likely) scores = result.category_scores puts "Sexual content score: #{scores['sexual']}" puts "Harassment score: #{scores['harassment']}" puts "Violence score: #{scores['violence']}" # Get boolean flags for each category categories = result.categories puts "Contains hate speech: #{categories['hate']}" puts "Contains self-harm content: #{categories['self-harm']}" ``` ### Moderation Categories Current moderation models typically check for these categories: - **Sexual**: Sexually explicit or suggestive content - **Hate**: Content that promotes hate based on identity - **Harassment**: Content intended to harass, threaten, or bully - **Self-harm**: Content promoting self-harm or suicide - **Sexual/minors**: Sexual content involving minors - **Hate/threatening**: Hateful content that includes threats - **Violence**: Content promoting or glorifying violence - **Violence/graphic**: Graphic violent content - **Self-harm/intent**: Content expressing intent to self-harm - **Self-harm/instructions**: Instructions for self-harm - **Harassment/threatening**: Harassing content that includes threats ## Alternative Calling Methods You can also use the class method directly: ```ruby # Direct class method result = RubyLLM::Moderation.moderate("Your content here") # With explicit model specification result = RubyLLM.moderate( "User message", model: "text-moderation-007", provider: "openai" ) # Using assume_model_exists for custom models result = RubyLLM.moderate( "Content to check", provider: "openai", assume_model_exists: true ) ``` ## Choosing Models By default, RubyLLM uses OpenAI's latest moderation model (`omni-moderation-latest`), but you can specify different models: ```ruby # Use a specific OpenAI moderation model result = RubyLLM.moderate( "Content to moderate", model: "text-moderation-007" ) # Configure the default moderation model globally RubyLLM.configure do |config| config.default_moderation_model = "text-moderation-007" end ``` Refer to the [Available Models Reference](/available-models/) for details on moderation models and their capabilities. ## Integration Patterns ### Pre-Chat Moderation Use moderation as a safety layer before sending user input to LLMs: ```ruby def safe_chat_response(user_input) # Check content safety first moderation = RubyLLM.moderate(user_input) if moderation.flagged? flagged_categories = moderation.flagged_categories.join(', ') return { error: "Content flagged for: #{flagged_categories}", safe: false } end # Content is safe, proceed with chat response = RubyLLM.chat.ask(user_input) { content: response.content, safe: true } end ``` ### Custom Threshold Handling You might want to implement custom logic based on category scores: ```ruby def assess_content_risk(text) result = RubyLLM.moderate(text) scores = result.category_scores # Custom thresholds for different risk levels high_risk = scores.any? { |_, score| score > 0.8 } medium_risk = scores.any? { |_, score| score > 0.5 } case when high_risk { risk: :high, action: :block, message: "Content blocked" } when medium_risk { risk: :medium, action: :review, message: "Content flagged for review" } else { risk: :low, action: :allow, message: "Content approved" } end end # Usage assessment = assess_content_risk("Some user input") puts "Risk level: #{assessment[:risk]}" puts "Action: #{assessment[:action]}" ``` ## Error Handling Handle moderation errors gracefully: ```ruby begin result = RubyLLM.moderate("User content") if result.flagged? handle_unsafe_content(result) else process_safe_content(content) end rescue RubyLLM::ConfigurationError => e # Handle missing API key or configuration logger.error "Moderation not configured: #{e.message}" # Fallback: proceed with caution or block all content rescue RubyLLM::RateLimitError => e # Handle rate limits logger.warn "Moderation rate limited: #{e.message}" # Fallback: temporary approval or queue for later rescue RubyLLM::Error => e # Handle other API errors logger.error "Moderation failed: #{e.message}" # Fallback: proceed with caution end ``` ## Configuration Requirements Content moderation currently requires an OpenAI API key: ```ruby RubyLLM.configure do |config| config.openai_api_key = ENV['OPENAI_API_KEY'] # Optional: set default moderation model config.default_moderation_model = "omni-moderation-latest" end ``` For more details about OpenAI's moderation capabilities and policies, see the [OpenAI Moderation Guide](https://platform.openai.com/docs/guides/moderation). > Moderation API calls are typically less expensive than chat completions and have generous rate limits, making them suitable for screening all user inputs. {: .note } ## Best Practices ### Content Safety Strategy - **Always moderate user-generated content** before sending to LLMs - **Handle false positives gracefully** with human review processes - **Log moderation decisions** for auditing and improvement - **Provide clear feedback** to users about content policies ### Performance Considerations - **Cache moderation results** for repeated content (with appropriate TTL) - **Use background jobs** for non-blocking moderation of large volumes - **Implement fallbacks** for when moderation services are unavailable ### User Experience ```ruby def user_friendly_moderation(content) result = RubyLLM.moderate(content) return { approved: true } unless result.flagged? # Provide specific, actionable feedback categories = result.flagged_categories message = case when categories.include?('harassment') "Please keep interactions respectful and constructive." when categories.include?('sexual') "This content appears inappropriate for our platform." when categories.include?('violence') "Please avoid content that promotes violence or harm." else "This content doesn't meet our community guidelines." end { approved: false, message: message, categories: categories } end ``` ## Rails Integration When using moderation in Rails applications: ```ruby # In a controller or service class MessageController < ApplicationController def create content = params[:message] moderation_result = RubyLLM.moderate(content) if moderation_result.flagged? render json: { error: "Message not allowed", categories: moderation_result.flagged_categories }, status: :unprocessable_entity else # Process the safe message message = Message.create!(content: content, user: current_user) render json: message, status: :created end end end # Background job for batch moderation class ModerationJob < ApplicationJob def perform(message_ids) messages = Message.where(id: message_ids) messages.each do |message| result = RubyLLM.moderate(message.content) message.update!( moderation_flagged: result.flagged?, moderation_categories: result.flagged_categories, moderation_scores: result.category_scores ) end end end ``` This allows you to build robust content safety systems that protect both your application and your users while maintaining a good user experience. --- ### Extended Thinking URL: https://rubyllm.com/thinking/ Date: 2026-08-08 # Extended Thinking {: .d-inline-block .no_toc } New in 1.10 {: .label .label-green } Give reasoning models more time and budget to deliberate, with optional access to thinking output {: .fs-6 .fw-300 } ## Table of contents {: .no_toc .text-delta } 1. TOC {:toc} --- After reading this guide, you will know: * How to control extended thinking with `with_thinking` * How effort and budget are sent to providers * How to access thinking output in responses and streams * How to persist thinking data with ActiveRecord ## What is Extended Thinking? Extended Thinking gives supported models more time and a larger computation budget to deliberate before answering. It can improve results on multi-step tasks like coding, math, and logic, at the expense of latency and cost. Some providers can also return a thinking trace or signature alongside the final answer. ## Controlling Extended Thinking Use `with_thinking` to control models that support thinking. Some models think by default, so `with_thinking` is for tuning (or disabling) rather than turning it on. ```ruby chat = RubyLLM.chat(model: 'claude-opus-4.5') .with_thinking(effort: :high, budget: 8000) response = chat.ask("What is 15 * 23?") response.thinking&.text response.thinking&.signature response.content ``` `with_thinking` requires at least one of `effort` or `budget`: ```ruby chat.with_thinking(effort: :low) chat.with_thinking(budget: 10_000) chat.with_thinking(effort: :none) ``` ### Effort and Budget Use `effort` to pick a qualitative depth (`:low`, `:medium`, `:high`) and `budget` for models that accept a token cap. RubyLLM sends `effort` and `budget` exactly as provided. Check your provider's docs for supported values. ## Streaming with Thinking Thinking content is delivered alongside normal content in streaming chunks: ```ruby chat = RubyLLM.chat(model: 'claude-opus-4.5') .with_thinking(effort: :medium) chat.ask("Solve this step by step: What is 127 * 43?") do |chunk| print chunk.thinking&.text print chunk.content end ``` Some providers only expose thinking in the final response. In those cases, `response.thinking` is populated after the stream completes, and `chunk.thinking` stays empty. ## ActiveRecord Integration When using `acts_as_chat` and `acts_as_message`, thinking output is persisted to the message table: ```ruby # Migration (generated automatically with new installs) # t.text :thinking_text # t.text :thinking_signature # t.integer :thinking_tokens response = chat_record.ask("Explain quantum entanglement") response.thinking&.text response.thinking_tokens ``` `thinking_tokens` is usually a breakdown of generated output work. From v1.15 onward, RubyLLM normalizes `output_tokens` as the billable output bucket, so you should not add `thinking_tokens` to `output_tokens` for cost calculations. When a model has distinct reasoning-token pricing, the cost is exposed separately as `response.cost.thinking`. ### Upgrading Existing Installations For 1.10 upgrades, consider using the [upgrade guide](/upgrading/#upgrade-to-1-10) to run the generator. If you prefer manual migrations, add the columns to your message and tool calls tables: ```ruby class AddThinkingToMessages < ActiveRecord::Migration[7.1] def change add_column :messages, :thinking_text, :text add_column :messages, :thinking_signature, :text add_column :messages, :thinking_tokens, :integer add_column :tool_calls, :thought_signature, :string end end ``` ## Provider Notes - Claude uses budget-based or adaptive thinking depending on the model, and can return both text and signature. - Anthropic requires a thinking budget for older Claude models and effort-based adaptive thinking for newer models. - Bedrock thinking params are model-dependent; models may accept budget, effort, or provider-specific fields. - Gemini 2.5 uses a token budget; Gemini 3 uses effort levels. - OpenAI reasoning models accept `effort` but may not return thinking text or signatures. - Perplexity sonar reasoning models stream `` blocks inside content; RubyLLM extracts them after the response completes. - Mistral Magistral models always think and ignore `with_thinking` params. Non-magistral models warn if you pass them. - Ollama and GPUStack local-model thinking controls vary by backend and model. RubyLLM does not translate them; pass backend params explicitly with `with_params`. - Anthropic and Ollama integrations currently do not report thinking token counts. ## Next Steps * [Streaming Responses](/streaming/) * [Rails Integration](/rails/) * [Error Handling](/error-handling/) --- ## Advanced ### Rails Integration URL: https://rubyllm.com/rails/ Date: 2026-08-08 # Rails Integration {: .no_toc } Rails + AI made simple. Persist chats with ActiveRecord. Stream with Hotwire. Deploy with confidence. {: .fs-6 .fw-300 } ## Table of contents {: .no_toc .text-delta } 1. TOC {:toc} --- After reading this guide, you will know: * How to set up ActiveRecord models for persisting chats and messages * How the RubyLLM persistence flow works with Rails applications * How to use `acts_as_chat` and `acts_as_message` with your models * How to persist AI model metadata in your database with `acts_as_model` * How to send file attachments to AI models with ActiveStorage * How to store raw provider payloads (Anthropic prompt caching, etc.) * How to integrate streaming responses with Hotwire/Turbo Streams * How to customize the persistence behavior for validation-focused scenarios ## Understanding the Persistence Flow Before diving into setup, it's important to understand how RubyLLM handles message persistence in Rails. This design influences model validations and real-time UI updates. ### How It Works When calling `chat_record.ask("What is the capital of France?")`, RubyLLM: 1. **Saves the user message** with the question content 2. **Calls the `complete` method**, which: - Makes the API call to the AI provider - Creates an empty assistant message: - **With streaming**: On receiving the first chunk - **Without streaming**: Before the API call - Processes the response: - **Success**: Updates the assistant message with content and metadata - **Failure**: Automatically destroys the empty assistant message ### Why This Design? This approach optimizes for real-time experiences: 1. **Streaming optimized**: Creates DOM target on first chunk for immediate UI updates 2. **Turbo Streams ready**: Works with `after_create_commit` for real-time broadcasting 3. **Clean rollback**: Automatic cleanup on failure prevents orphaned records ### Content Validation Implications > **Important:** You cannot use `validates :content, presence: true` on your Message model. See [Customizing the Persistence Flow](#customizing-the-persistence-flow) for an alternative approach. {: .warning } ## Setting Up Your Rails Application ### Quick Setup with Generator The easiest way to get started is using the provided Rails generator: ```bash bin/rails generate ruby_llm:install ``` The generator: - Creates migrations for Chat, Message, ToolCall, and Model tables - Sets up model files with appropriate `acts_as` declarations - Installs ActiveStorage for file attachments - Configures the database model registry - Creates an initializer with sensible defaults - Creates conventional AI app directories (`v1.14.0+`) After running the generator: ```bash bin/rails db:migrate bin/rails ruby_llm:load_models # v1.13+ ``` Your Rails app is now AI-ready! ### Adding a Chat UI Want a ready-to-use chat interface? Run the chat UI generator: ```bash bin/rails generate ruby_llm:chat_ui ``` This creates a complete chat interface with: - **Controllers**: Handles chat and message creation with background processing - **Views**: Modern UI with Turbo Streams for real-time updates - **Jobs**: Background job for processing AI responses without blocking - **Routes**: RESTful routes for chats and messages After running the generator, start your server and visit `http://localhost:3000/chats` to begin chatting! The UI generator also supports custom model names: ```bash # Use your custom model names from the install generator bin/rails generate ruby_llm:chat_ui chat:Conversation message:ChatMessage model:AIModel ``` ### Conventional Directory Structure {: .d-inline-block } v1.14.0+ {: .label .label-green } RubyLLM's Rails generators now establish a default app structure: ```text app/ |-- agents/ |-- prompts/ |-- schemas/ `-- tools/ ``` The install generator creates these directories with `.gitkeep` files so teams start from one shared convention. These are conventions, not hard requirements: - Agents, tools, and schemas can live anywhere in your app autoload paths. - Prompt lookup convention: the `instructions` class macro resolves `instructions.txt.erb` from the agent class name. For prompt lookup, RubyLLM uses class name conventions: - `WorkAssistant` -> `app/prompts/work_assistant/instructions.txt.erb` - `Admin::SupportAgent` -> `app/prompts/admin/support_agent/instructions.txt.erb` See the [Agents guide](/agents/#default-instructions-prompt) for how `instructions` rendering works. ### Rails Generators for Agents, Tools, and Schemas {: .d-inline-block } v1.14.0+ {: .label .label-green } Alongside `ruby_llm:install` and `ruby_llm:chat_ui`, Rails apps can generate starter classes for common AI building blocks: ```bash bin/rails generate ruby_llm:agent Support bin/rails generate ruby_llm:tool Weather bin/rails generate ruby_llm:schema Product ``` What each generator creates: - `ruby_llm:agent`: `app/agents/support_agent.rb` and `app/prompts/support_agent/instructions.txt.erb` - `ruby_llm:tool`: `app/tools/weather_tool.rb` plus tool-specific chat UI partials under `app/views/messages/tool_calls` and `app/views/messages/tool_results` - `ruby_llm:schema`: `app/schemas/product_schema.rb` ### Chat UI View Conventions {: .d-inline-block } v1.14.0+ {: .label .label-green } The generated chat UI follows one convention: each message partial uses the local that matches its partial name. - `messages/_user.html.erb` gets `user` - `messages/_assistant.html.erb` gets `assistant` - `messages/_system.html.erb` gets `system` - `messages/_tool.html.erb` gets `tool` - `messages/_tool_calls.html.erb` gets `tool_calls` This comes from Rails partial rendering: `render @chat.messages` calls `to_partial_path`, and Rails injects a local named after that partial. For compatibility with model broadcasts (`broadcasts_to`), generated message partials also accept a `message` local as a fallback. #### Tool Call and Tool Result Partials Tool-specific partials are generated under `app/views/messages/tool_calls` and `app/views/messages/tool_results`: ```text app/views/messages/ |-- tool_calls/ | |-- _default.html.erb | `-- _your_tool.html.erb `-- tool_results/ |-- _default.html.erb `-- _your_tool.html.erb ``` Locals passed to those partials: - `messages/tool_calls/_your_tool.html.erb` receives `tool_calls` and `tool_call` - `messages/tool_results/_your_tool.html.erb` receives `tool` `ruby_llm:tool` creates `_your_tool.html.erb` files with the correct names so custom rendering hooks up automatically. Using fixed locals keeps the templates dumb and predictable. Turbo Stream templates used by the generated chat UI: - `messages/create.turbo_stream.erb` resets the message form for `MessagesController#create`. #### Generator Options The generator uses Rails-like syntax for custom model names: ```bash # Default - creates Chat, Message, ToolCall, Model bin/rails generate ruby_llm:install # Custom model names using Rails conventions bin/rails generate ruby_llm:install chat:Conversation message:ChatMessage bin/rails generate ruby_llm:install chat:Discussion message:DiscussionMessage tool_call:FunctionCall model:AIModel # Skip ActiveStorage if you don't need file attachments bin/rails generate ruby_llm:install --skip-active-storage ``` The `name:ClassName` syntax follows Rails conventions - specify only what you want to customize. For most apps, keep the default behavior (install ActiveStorage) so file attachments work out of the box. Use `--skip-active-storage` only when you're sure you won't send files to models. ### Setting Up ActiveStorage The generator automatically configures ActiveStorage for file attachments. If you skipped it during generation, add it manually: ```bash bin/rails active_storage:install bin/rails db:migrate ``` Then add to your Message model: ```ruby # app/models/message.rb class Message < ApplicationRecord acts_as_message has_many_attached :attachments # Required for file attachments end ``` This `:attachments` association is only required on RubyLLM message records. The ActiveStorage attachments you pass to `with:` from your own models can use any name. ### Working with Raw Provider Payloads, Anthropic Prompt Caching {: .d-inline-block } v1.9.0+ {: .label .label-green } Providers like Anthropic expose advanced features (prompt caching, fine-grained metadata) by embedding rich structures inside each prompt block. Use `RubyLLM::Content::Raw` to persist those blocks alongside your conversation history: ```ruby raw_block = RubyLLM::Content::Raw.new([ { type: 'text', text: 'Reusable analysis prompt', cache_control: { type: 'ephemeral' } }, { type: 'text', text: "Today's request: #{summary}" } ]) chat = Chat.create!(model: 'claude-sonnet-4-5') chat.ask(raw_block) ``` The v1.9 schema adds a `content_raw` column so raw payloads live alongside the plain-text `content` field. When you load messages via `acts_as_message`, RubyLLM reconstructs the original `Content::Raw` automatically. > Existing apps: run `bin/rails generate ruby_llm:upgrade_to_v1_9` to add cached-token tracking and raw content storage columns introduced in v1.9.0. New apps will get the proper columns from the install generator. {: .note } ### Configuring RubyLLM Set up your API keys and other configuration in the initializer: ```ruby # config/initializers/ruby_llm.rb RubyLLM.configure do |config| config.openai_api_key = ENV['OPENAI_API_KEY'] config.anthropic_api_key = ENV['ANTHROPIC_API_KEY'] config.gemini_api_key = ENV['GEMINI_API_KEY'] # For custom Model class names (defaults to 'Model') # config.model_registry_class = 'AIModel' end ``` ### Instrumentation {: .d-inline-block } v1.16.0+ {: .label .label-green } Rails apps automatically emit RubyLLM events through `ActiveSupport::Notifications`. See [Instrumentation](/instrumentation/) for events, payloads, and non-Rails instrumenters. ### Fiber-Safe ActiveRecord Connections for Async/Fiber Workloads {: .d-inline-block } Rails 7.2.1+ / 8.x {: .label .label-green } If your app performs database work inside Fibers (for example with async-based workflow stacks), use fiber-safe connection isolation: ```ruby # config/application.rb config.active_support.isolation_level = :fiber ``` Why: Rails defaults to thread-based connection isolation. In fiber-heavy flows, that can cause intermittent connection-state issues. `:fiber` scopes ActiveRecord connections per Fiber instead of per Thread. > If you use this setting, prefer Rails versions with fiber isolation fixes (Rails 7.2.1+ / 8.x). {: .note } ### Setting Up Models with `acts_as` Helpers Add RubyLLM capabilities to your models: #### With Model Registry (Default for new apps) {: .d-inline-block } Available in v1.7.0+ {: .label .label-green } ```ruby # app/models/chat.rb class Chat < ApplicationRecord # New API style - uses Rails association names as primary parameters acts_as_chat # Defaults: messages: :messages, model: :model # Or with custom associations: # acts_as_chat messages: :chat_messages, # model: :ai_model belongs_to :user, optional: true end # app/models/message.rb class Message < ApplicationRecord # New API style - uses Rails association names acts_as_message # Defaults: chat: :chat, tool_calls: :tool_calls, model: :model # Or with custom associations: # acts_as_message chat: :conversation, # tool_calls: :function_calls # Note: Do NOT add "validates :content, presence: true" validates :role, presence: true validates :chat, presence: true end # app/models/tool_call.rb class ToolCall < ApplicationRecord acts_as_tool_call # Defaults: message: :message, result: :result end # app/models/model.rb class Model < ApplicationRecord acts_as_model # Defaults: chats: :chats end ``` #### Legacy Mode (Without Model Registry) {: .d-inline-block } Pre-1.7.0 or opt-in {: .label .label-yellow } > Set `config.use_new_acts_as = false` to stay with this API until it will be removed in 2.0. {: .note } ```ruby # app/models/chat.rb class Chat < ApplicationRecord # Legacy API style - requires explicit class names acts_as_chat message_class: 'Message', tool_call_class: 'ToolCall' end # app/models/message.rb class Message < ApplicationRecord # Legacy API style - all class names and foreign keys explicit acts_as_message chat_class: 'Chat', chat_foreign_key: 'chat_id', tool_call_class: 'ToolCall' end # app/models/tool_call.rb class ToolCall < ApplicationRecord acts_as_tool_call message_class: 'Message', message_foreign_key: 'message_id' end # Note: No Model class in legacy mode - uses string fields instead ``` ### Provider Overrides {: .d-inline-block } Available in v1.7.0+ {: .label .label-green } Route models through different providers dynamically: ```ruby # Use a model through a different provider chat = Chat.create!( model: 'claude-sonnet-4-6', provider: 'bedrock' # Route this model through AWS Bedrock ) # The model registry handles the routing automatically chat.ask("Hello!") ``` ### Custom Contexts and Dynamic Models {: .d-inline-block } Available in v1.7.0+ {: .label .label-green } #### Using Custom Contexts Use different API keys per chat in multi-tenant applications: **With DB-backed model registry (default in v1.7.0+):** ```ruby # Create a custom context custom_context = RubyLLM.context do |config| config.openai_api_key = 'sk-customer-specific-key' end # Pass context when creating the chat chat = Chat.create!( model: 'gpt-5.4', context: custom_context ) ``` **Legacy mode (when using `--skip-model-registry`):** ```ruby # In legacy mode, you can set context after creation chat = Chat.create!(model: 'gpt-4') chat.with_context(custom_context) # This method only exists in legacy mode ``` > **Warning:** Context is not persisted. Set it after reloading chats. {: .warning } ```ruby # Later, in a different request or after restart chat = Chat.find(chat_id) chat.context = custom_context # Must set this! chat.ask("Continue our conversation") ``` For multi-tenant apps, consider using an `after_find` callback: ```ruby class Chat < ApplicationRecord acts_as_chat belongs_to :tenant after_find :set_tenant_context private def set_tenant_context self.context = RubyLLM.context do |config| config.openai_api_key = tenant.openai_api_key end end end ``` #### Dynamic Model Creation When using models not in the registry (e.g., new OpenRouter models): ```ruby # Create chat with a dynamic model chat = Chat.create!( model: 'experimental-llm-v2', provider: 'openrouter', assume_model_exists: true # Creates Model record automatically ) ``` > **Note:** Like context, `assume_model_exists` is not persisted. {: .note } ```ruby # When switching to another dynamic model later chat = Chat.find(chat_id) chat.assume_model_exists = true chat.with_model('another-experimental-model', provider: 'openrouter') ``` ## Working with Chats ### Basic Chat Operations The `acts_as_chat` helper provides all standard chat methods: ```ruby # Create a chat chat_record = Chat.create!(model: 'gpt-5-nano', user: current_user) # Ask a question - the persistence flow runs automatically begin # This saves the user message, then calls complete() which: # 1. Creates an empty assistant message # 2. Makes the API call # 3. Updates the message on success, or destroys it on failure response = chat_record.ask "What is the capital of France?" # Get the persisted message record from the database assistant_message_record = chat_record.messages.last puts assistant_message_record.content # => "The capital of France is Paris." rescue RubyLLM::Error => e puts "API Call Failed: #{e.message}" # The empty assistant message is automatically cleaned up on failure end # Continue the conversation chat_record.ask "Tell me more about that city" # Verify persistence puts "Conversation length: #{chat_record.messages.count}" # => 4 ``` ### Token Usage and Costs {: .d-inline-block } v1.15+ {: .label .label-green } Persisted chats and messages expose the same normalized token and cost helpers as regular RubyLLM objects: ```ruby message = chat_record.messages.last message.tokens.input # Standard input tokens message.tokens.output # Billable output tokens message.tokens.cache_read # Prompt cache reads message.tokens.cache_write # Prompt cache writes message.cost.total message.cost.thinking # When the model has distinct reasoning-token pricing chat_record.cost.total ``` `cache_read_tokens` and `cache_write_tokens` are aliases for the existing v1.9 `cached_tokens` and `cache_creation_tokens` columns, so apps that already ran the v1.9 migration do not need another migration for these names. RubyLLM normalizes provider-specific cache accounting before persisting token counts. See [Tracking Token Usage](/chat/#tracking-token-usage) for the provider comparison table. ### Database Model Registry {: .d-inline-block } Available in v1.7.0+ {: .label .label-green } When using the Model registry (created by default by the generator), your chats and messages get associations to model records: ```ruby # String automatically resolves to Model record chat = Chat.create!(model: 'gpt-5.4') chat.model # => # chat.model.name # => "GPT-5.4" chat.model.context_window # => 1050000 chat.model.supports_vision # => true # Populate/refresh models from models.json (v1.13+) bin/rails ruby_llm:load_models # Query based on model attributes Chat.joins(:model).where(models: { provider: 'anthropic' }) Model.left_joins(:chats).group(:id).order('COUNT(chats.id) DESC') # Find models with specific capabilities Model.where(supports_functions: true) Model.where(supports_vision: true) ``` If the model registry table is empty (or not available yet), RubyLLM falls back to `models.json` for lookups (v1.13+). ### System Instructions System prompts are persisted as messages with the `system` role: ```ruby chat_record = Chat.create!(model: 'gpt-5-nano') # This creates and saves a Message record with role: :system chat_record.with_instructions("You are a Ruby expert.") # By default, with_instructions replaces the active system instruction chat_record.with_instructions("You are a concise Ruby expert.") # Append only when you intentionally want multiple system prompts chat_record.with_instructions("Use short bullet points.", append: true) system_message = chat_record.messages.find_by(role: :system) puts system_message.content # => "You are a concise Ruby expert." ``` ### Using Tools Tools are Ruby classes that the AI can call. While the tool classes themselves aren't persisted, the tool calls and their results are saved as messages: ```ruby # Define a tool (this is just a Ruby class, not persisted) class Weather < RubyLLM::Tool description "Gets current weather for a location" param :city, desc: "City name" def execute(city:) "The weather in #{city} is sunny and 22°C." end end # Register the tool with your chat chat_record = Chat.create!(model: 'gpt-5-nano') chat_record.with_tool(Weather) # When the AI uses the tool, both the call and result are persisted response = chat_record.ask("What's the weather in Paris?") # Check persisted messages: # 1. User message: "What's the weather in Paris?" # 2. Assistant message with tool_calls (the AI's decision to use the tool) # 3. Tool result message (the output from Weather#execute) puts chat_record.messages.count # => 3 # The tool call details are stored in the ToolCall table tool_call = chat_record.messages.second.tool_calls.first puts tool_call.name # => "Weather" puts tool_call.arguments # => {"city" => "Paris"} ``` ### File Attachments Send files to AI models using ActiveStorage: ```ruby # Create a chat chat_record = Chat.create!(model: 'claude-sonnet-4-6') # Send a single file - type automatically detected chat_record.ask("What's in this file?", with: "app/assets/images/diagram.png") # Send multiple files of different types - all automatically detected chat_record.ask("What are in these files?", with: [ "app/assets/documents/report.pdf", "app/assets/images/chart.jpg", "app/assets/text/notes.txt", "app/assets/audio/recording.mp3" ]) # Works with file uploads from forms chat_record.ask("Analyze this file", with: params[:uploaded_file]) # Works with existing ActiveStorage attachments chat_record.ask("What's in this document?", with: user.profile_document) # has_one_attached chat_record.ask("Compare these documents", with: project.documents) # has_many_attached ``` File types are automatically detected from extensions or MIME types. ### Structured Output Generate and persist structured responses: ```ruby # Define a schema class PersonSchema < RubyLLM::Schema string :name integer :age string :city, required: false end # Use with your persisted chat chat_record = Chat.create!(model: 'gpt-5-nano') response = chat_record.with_schema(PersonSchema).ask("Generate a person from Paris") # The structured response is automatically parsed as a Hash puts response.content # => {"name" => "Marie", "age" => 28, "city" => "Paris"} # But it's stored as JSON in the database message = chat_record.messages.last puts message.content # => "{\"name\":\"Marie\",\"age\":28,\"city\":\"Paris\"}" puts JSON.parse(message.content) # => {"name" => "Marie", "age" => 28, "city" => "Paris"} ``` Schemas work in multi-turn conversations: ```ruby # Start with a schema chat_record.with_schema(PersonSchema) person = chat_record.ask("Generate a French person") # Remove the schema for analysis chat_record.with_schema(nil) analysis = chat_record.ask("What's interesting about this person?") # All messages are persisted correctly puts chat_record.messages.count # => 4 ``` ## Advanced Topics ### Handling Edge Cases #### Automatic Cleanup RubyLLM automatically cleans up empty assistant messages when API calls fail. This prevents orphaned records that could cause issues with providers that reject empty content. #### Provider Content Restrictions Some providers (like Gemini) reject conversations with empty message content. RubyLLM's automatic cleanup ensures this isn't an issue during normal operation. ### Customizing the Persistence Flow For applications requiring content validations, override the default persistence methods: ```ruby # app/models/chat.rb class Chat < ApplicationRecord acts_as_chat # Override the default persistence methods private def persist_new_message # Create a new message object but don't save it yet @message = messages.new(role: :assistant) end def persist_message_completion(message) return unless message # Fill in attributes and save once we have content @message.assign_attributes( content: message.content, model: Model.find_by(model_id: message.model_id), input_tokens: message.tokens.input, output_tokens: message.tokens.output, cached_tokens: message.tokens.cache_read, cache_creation_tokens: message.tokens.cache_write ) @message.save! # Handle tool calls if present persist_tool_calls(message.tool_calls) if message.tool_calls.present? end def persist_tool_calls(tool_calls) tool_calls.each_value do |tool_call| attributes = tool_call.to_h attributes[:tool_call_id] = attributes.delete(:id) @message.tool_calls.create!(**attributes) end end end # app/models/message.rb class Message < ApplicationRecord acts_as_message # Now you can safely add this validation validates :content, presence: true end ``` This approach trades streaming UI updates for content validation support: - ✅ Content validations work - ✅ No empty messages in database - ❌ No DOM target for streaming before API response ## Streaming Responses with Hotwire/Turbo The default persistence flow is designed to work seamlessly with streaming and Turbo Streams for real-time UI updates. ### Instant User Messages Show user messages immediately for better UX: ```ruby # app/controllers/messages_controller.rb class MessagesController < ApplicationController def create @chat = Chat.find(params[:chat_id]) # Create and persist the user message immediately @chat.add_message(role: :user, content: params[:content]) # Process AI response in background ChatStreamJob.perform_later(@chat.id) respond_to do |format| format.turbo_stream { head :ok } format.html { redirect_to @chat } end end end ``` The `add_message` method provides instant feedback while processing continues in the background. ### Full Streaming Implementation Complete example with background jobs and Turbo Streams: ```ruby # app/models/chat.rb class Chat < ApplicationRecord acts_as_chat end # app/models/message.rb class Message < ApplicationRecord acts_as_message broadcasts_to ->(message) { "chat_#{message.chat_id}" } # Helper to broadcast chunks during streaming def broadcast_append_chunk(chunk_content) broadcast_append_to "chat_#{chat_id}", target: "message_#{id}_content", partial: "messages/content", locals: { content: chunk_content } end end # app/jobs/chat_stream_job.rb class ChatStreamJob < ApplicationJob queue_as :default def perform(chat_id) chat = Chat.find(chat_id) # Process the latest user message chat.complete do |chunk| # Get the assistant message record (created before streaming starts) assistant_message = chat.messages.last if chunk.content && assistant_message # Append the chunk content to the message's target div assistant_message.broadcast_append_chunk(chunk.content) end end # Final assistant message is now fully persisted end end ``` ```erb <%# app/views/chats/show.html.erb %> <%= turbo_stream_from "chat_#{@chat.id}" %>

Chat <%= @chat.id %>

<%= render @chat.messages %>
<%= form_with(url: chat_messages_path(@chat), method: :post) do |f| %> <%= f.text_area :content %> <%= f.submit "Send" %> <% end %> <%# app/views/messages/_message.html.erb %>
<%= message.role.capitalize %>:
<%= message.content %>
``` This helper intentionally lives in your app model (via generator) rather than core RubyLLM methods, so streaming behavior stays explicit and customizable. This implementation provides: - Real-time UI updates during generation - Background processing to prevent timeouts - Automatic persistence of all messages and tool calls ### Message Ordering Issues Action Cable processes messages concurrently, which can cause out-of-order delivery: #### Solution 1: Client-Side Reordering (Recommended) Use Stimulus to maintain chronological order: ```javascript // app/javascript/controllers/message_ordering_controller.js // Note: This is an example implementation. Test thoroughly before production use. import { Controller } from "@hotwired/stimulus" export default class extends Controller { static targets = ["message"] connect() { this.reorderMessages() this.observeNewMessages() } observeNewMessages() { // Watch for new messages being added to the DOM const observer = new MutationObserver((mutations) => { let shouldReorder = false mutations.forEach((mutation) => { mutation.addedNodes.forEach((node) => { if (node.nodeType === 1 && node.matches('[data-message-ordering-target="message"]')) { shouldReorder = true } }) }) if (shouldReorder) { // Small delay to ensure all attributes are set setTimeout(() => this.reorderMessages(), 10) } }) observer.observe(this.element, { childList: true, subtree: true }) this.observer = observer } disconnect() { if (this.observer) { this.observer.disconnect() } } reorderMessages() { const messages = Array.from(this.messageTargets) // Sort by timestamp (created_at) messages.sort((a, b) => { const timeA = new Date(a.dataset.createdAt).getTime() const timeB = new Date(b.dataset.createdAt).getTime() return timeA - timeB }) // Reorder in DOM messages.forEach((message) => { this.element.appendChild(message) }) } } ``` Update your views to use the controller: ```erb <%# app/views/chats/show.html.erb %>
<%= render @chat.messages %>
<%# app/views/messages/_message.html.erb %> <%= turbo_frame_tag message, data: { message_ordering_target: "message", created_at: message.created_at.iso8601 } do %> <% end %> ``` #### Solution 2: Server-Side Ordering [AnyCable](https://anycable.io) provides order guarantees at the server level through "sticky concurrency" - ensuring messages from the same stream are processed by the same worker. This eliminates the need for client-side reordering code. #### Why This Happens Action Cable uses concurrent processing by design for performance. For strict ordering requirements, consider: - Server-sent events (SSE) for unidirectional streaming - WebSocket libraries with ordered stream support like [Lively](https://github.com/socketry/lively/tree/main/examples/chatbot) - AnyCable for server-side ordering guarantees > **Note:** The async Ruby stack (Falcon + async-cable) may improve behavior but doesn't guarantee ordering. {: .note } ## Customizing Models The `acts_as` helpers integrate seamlessly with standard Rails patterns. Add associations, validations, scopes, and callbacks as needed. ### Using Custom Model Names If your application uses different model names, you can configure the `acts_as` helpers accordingly: #### With Model Registry {: .d-inline-block } Available in v1.7.0+ {: .label .label-green } ```ruby # app/models/conversation.rb (instead of Chat) class Conversation < ApplicationRecord acts_as_chat messages: :chat_messages, # Association name model: :ai_model belongs_to :user, optional: true end # app/models/chat_message.rb (instead of Message) class ChatMessage < ApplicationRecord acts_as_message chat: :conversation, # Association name tool_calls: :ai_tool_calls, model: :ai_model end # app/models/ai_tool_call.rb (instead of ToolCall) class AiToolCall < ApplicationRecord acts_as_tool_call message: :chat_message, result: :result end # app/models/ai_model.rb (instead of Model) class AiModel < ApplicationRecord acts_as_model chats: :conversations end ``` The new API follows Rails association inference: the association name determines the default foreign key, and the `*_class` options only change the class name. For example, `tool_calls: :ai_tool_calls` uses `ai_tool_call_id`, while `tool_call_class: 'AiToolCall'` by itself still uses `tool_call_id`. #### Namespaced Models Example For namespaced models, you'll need to specify class names explicitly: ```ruby # app/models/admin/bot_chat.rb module Admin class BotChat < ApplicationRecord acts_as_chat messages: :bot_messages, message_class: 'Admin::BotMessage' # Required for namespace end end # app/models/admin/bot_message.rb module Admin class BotMessage < ApplicationRecord acts_as_message chat: :bot_chat, chat_class: 'Admin::BotChat', tool_calls: :bot_tool_calls, tool_call_class: 'Admin::BotToolCall' end end # app/models/admin/bot_tool_call.rb module Admin class BotToolCall < ApplicationRecord acts_as_tool_call message: :bot_message, message_class: 'Admin::BotMessage' end end ``` If you choose prefixed association names such as `llm_tool_calls`, configure the reverse association the same way you would in Rails: ```ruby class Llm::ToolCall < ApplicationRecord acts_as_tool_call message: :llm_message, message_class: 'Llm::Message', result_foreign_key: :llm_tool_call_id end ``` #### Legacy Mode {: .d-inline-block } Pre-1.7.0 or opt-in {: .label .label-yellow } ```ruby # app/models/conversation.rb class Conversation < ApplicationRecord acts_as_chat message_class: 'ChatMessage', tool_call_class: 'AiToolCall' end # app/models/chat_message.rb class ChatMessage < ApplicationRecord acts_as_message chat_class: 'Conversation', chat_foreign_key: 'conversation_id', tool_call_class: 'AiToolCall' end # app/models/ai_tool_call.rb class AiToolCall < ApplicationRecord acts_as_tool_call message_class: 'ChatMessage', message_foreign_key: 'chat_message_id' end ``` ### Common Customizations Extend your models with standard Rails patterns: ```ruby # app/models/chat.rb class Chat < ApplicationRecord acts_as_chat # Add typical Rails associations belongs_to :user has_many :favorites, dependent: :destroy # Add scopes scope :recent, -> { order(updated_at: :desc) } scope :with_responses, -> { joins(:messages).where(messages: { role: 'assistant' }).distinct } # Add custom methods def summary messages.last(2).map(&:content).join(' ... ') end # Add callbacks after_create :notify_administrators private def notify_administrators # Custom logic end end ``` ## Next Steps * [Chatting with AI Models](/chat/) * [Using Tools](/tools/) * [Streaming Responses](/streaming/) * [Working with Models](/models/) * [Error Handling](/error-handling/) --- ### Scale with Async URL: https://rubyllm.com/async/ Date: 2026-08-08 # Scale with Async {: .no_toc } Handle hundreds of concurrent AI requests on modest hardware. Ruby's async ecosystem meets AI. {: .fs-6 .fw-300 } ## Table of contents {: .no_toc .text-delta } 1. TOC {:toc} --- After reading this guide, you will know: * Why LLM applications benefit dramatically from async Ruby * How RubyLLM automatically works with async * How to perform concurrent LLM operations * How to use async-job for background processing * How to handle rate limits with semaphores For a deeper dive into Async, Threads, and why Async Ruby is perfect for LLM applications, including benchmarks and architectural comparisons, check out my blog post: [Async Ruby is the Future of AI Apps (And It's Already Here)](https://paolino.me/async-ruby-is-the-future/) ## Why Async for LLMs? LLM operations are unique - they take 5-60 seconds and spend 99% of that time waiting for tokens to stream back. Using traditional thread-based job queues (Sidekiq, GoodJob, SolidQueue) for LLM operations creates a problem: ```ruby # With 25 worker threads configured: class ChatResponseJob < ApplicationJob def perform(conversation_id, message) # This occupies 1 of your 25 slots for 30-60 seconds... response = RubyLLM.chat.ask(message) # ...even though the thread is 99% idle end end # Your 26th user? They're waiting in line. ``` Async solves this by using fibers instead of threads: - **Threads**: OS-managed, preemptive, heavy (each needs its own database connection) - **Fibers**: Userspace, cooperative, lightweight (thousands can share a few connections) ## How RubyLLM Works with Async The beautiful part: RubyLLM automatically becomes non-blocking when used in an async context. No configuration needed. ```ruby require 'async' require 'ruby_llm' # This is all you need for concurrent LLM calls Async do 10.times.map do Async do # RubyLLM automatically becomes non-blocking # because Net::HTTP knows how to yield to fibers message = RubyLLM.chat.ask "Explain quantum computing" puts message.content end end.map(&:wait) end ``` This works because RubyLLM uses `Net::HTTP`, which cooperates with Ruby's fiber scheduler. ## Concurrent Operations ### Multiple Chat Requests Process multiple questions concurrently: ```ruby require 'async' require 'ruby_llm' def process_questions(questions) Async do tasks = questions.map do |question| Async do response = RubyLLM.chat.ask(question) { question: question, answer: response.content } end end # Wait for all tasks and return results tasks.map(&:wait) end.result end questions = [ "What is Ruby?", "Explain metaprogramming", "What are symbols?" ] results = process_questions(questions) results.each do |result| puts "Q: #{result[:question]}" puts "A: #{result[:answer]}\n\n" end ``` ### Batch Embeddings Generate embeddings efficiently: ```ruby def generate_embeddings(texts, batch_size: 100) Async do embeddings = [] texts.each_slice(batch_size) do |batch| task = Async do response = RubyLLM.embed(batch) response.vectors end embeddings.concat(task.wait) end # Return text-embedding pairs texts.zip(embeddings) end.result end texts = ["Ruby is great", "Python is good", "JavaScript is popular"] pairs = generate_embeddings(texts) pairs.each do |text, embedding| puts "#{text}: #{embedding[0..5]}..." # Show first 6 dimensions end ``` ### Parallel Analysis Run multiple analyses concurrently: ```ruby def analyze_document(content) Async do summary_task = Async do RubyLLM.chat.ask("Summarize in one sentence: #{content}") end sentiment_task = Async do RubyLLM.chat.ask("Is this positive or negative: #{content}") end { summary: summary_task.wait.content, sentiment: sentiment_task.wait.content } end.result end result = analyze_document("Ruby is an amazing language with a wonderful community!") puts "Summary: #{result[:summary]}" puts "Sentiment: #{result[:sentiment]}" ``` ## Background Processing with `Async::Job` The real power comes from using `Async::Job` for background processing. Unlike traditional thread-based job processors that get blocked during long LLM operations, `Async::Job` uses fibers to handle thousands of concurrent jobs efficiently. ### Setup with Falcon (Recommended) Falcon is a Ruby application server built on fibers. With Falcon, async just works™. ```ruby # Gemfile gem 'falcon' gem 'async-job-adapter-active_job' ``` ```ruby # config/application.rb config.active_job.queue_adapter = :async_job ``` ```ruby # config/initializers/async_job_adapter.rb require 'async/job/processor/inline' Rails.application.configure do config.async_job.define_queue "default" do dequeue Async::Job::Processor::Inline end end ``` That's it. Start your server with `bin/dev` and enjoy concurrent job processing. Your jobs now run concurrently without any additional infrastructure. One process, thousands of concurrent LLM operations. ### Note on Puma Still using Puma? You'll need a Redis-backed job processor for concurrent execution: ```ruby # Gemfile additions gem 'async-job-processor-redis' # config/initializers/async_job_adapter.rb require 'async/job/processor/redis' Rails.application.configure do config.async_job.define_queue "default" do dequeue Async::Job::Processor::Redis end end ``` Then run these processes: **Option 1: Add to Procfile.dev (Recommended)** ```ruby # Procfile.dev web: bin/rails server css: bin/rails tailwindcss:watch # or your CSS processor redis: redis-server async_job: bundle exec async-job-adapter-active_job-server ``` Then just run `bin/dev` to start everything. **Option 2: Separate terminals** ```bash # Terminal 1: Redis redis-server # Terminal 2: Job processor (auto-scales to CPU cores) bundle exec async-job-adapter-active_job-server # Terminal 3: Rails bin/dev ``` This setup requires more infrastructure but still delivers the concurrency benefits of async for your LLM operations. ### Your Jobs Work Unchanged Here's the key insight: you don't need to modify your jobs at all. `Async::Job` runs each job inside an async context automatically: ```ruby class DocumentAnalyzerJob < ApplicationJob def perform(document_id) document = Document.find(document_id) # This automatically runs in an async context! # No need to wrap in Async blocks response = RubyLLM.chat.ask("Analyze: #{document.content}") document.update!( analysis: response.content, analyzed_at: Time.current ) end end ``` ### Mixing Job Adapters: Best of Both Worlds You don't have to go all-in. Use async-job only for LLM operations while keeping your existing job processor for everything else: ```ruby # Keep your existing adapter as default config.active_job.queue_adapter = :solid_queue # or :sidekiq, :good_job, etc. # Base class for all LLM jobs class LLMJob < ApplicationJob self.queue_adapter = :async_job end # LLM jobs inherit the async adapter class ChatResponseJob < LLMJob def perform(conversation_id, message) # Runs with async-job - perfect for streaming response = RubyLLM.chat.ask(message) # ... end end # Regular jobs use your default adapter class ImageProcessingJob < ApplicationJob def perform(image_id) # Runs with solid_queue - better for CPU work # ... end end ``` This approach lets you optimize each job type for its workload without disrupting your existing infrastructure. ## Rate Limiting with Semaphores When making many concurrent requests, use a semaphore to respect rate limits: ```ruby require 'async' require 'async/semaphore' class RateLimitedProcessor def initialize(max_concurrent: 10) @semaphore = Async::Semaphore.new(max_concurrent) end def process_items(items) Async do items.map do |item| Async do # Only 10 items processed at once @semaphore.acquire do response = RubyLLM.chat.ask("Process: #{item}") { item: item, result: response.content } end end end.map(&:wait) end.result end end # Usage processor = RateLimitedProcessor.new(max_concurrent: 5) items = ["Item 1", "Item 2", "Item 3", "Item 4", "Item 5", "Item 6"] results = processor.process_items(items) ``` The semaphore ensures only 5 requests run concurrently, preventing rate limit errors while still maintaining high throughput. ## Summary Key takeaways: - LLM operations are perfect for async (99% waiting for I/O) - RubyLLM automatically works with async - no configuration needed - Use async-job for LLM background jobs without changing your job code - Use semaphores to manage rate limits - Keep thread-based processors for CPU-intensive work The combination of RubyLLM and async Ruby gives you the ability to handle thousands of concurrent AI conversations on modest hardware - something that would require massive infrastructure with traditional thread-based approaches. Ready to dive deeper? Read the full architectural comparison: [Async Ruby is the Future of AI Apps](https://paolino.me/async-ruby-is-the-future/) --- ### Error Handling URL: https://rubyllm.com/error-handling/ Date: 2026-08-08 # Error Handling {: .no_toc } Learn how to handle errors gracefully when working with AI providers {: .fs-6 .fw-300 } ## Table of contents {: .no_toc .text-delta } 1. TOC {:toc} --- After reading this guide, you will know: * RubyLLM's error hierarchy. * How to rescue specific types of errors. * How to access details from the original API response. * How errors are handled during streaming. * Best practices for handling errors within Tools. * RubyLLM's automatic retry behavior. * How to enable debug logging. ## RubyLLM Error Hierarchy All errors raised directly by RubyLLM inherit from `RubyLLM::Error`. Specific errors map to common HTTP status codes or library-specific issues: ```ruby RubyLLM::Error # Base error class for API/network issues RubyLLM::BadRequestError # 400: Invalid request parameters RubyLLM::UnauthorizedError # 401: API key issues RubyLLM::PaymentRequiredError # 402: Billing issues RubyLLM::ForbiddenError # 403: Permission issues RubyLLM::ContextLengthExceededError # Context/token limits exceeded (provider-specific) RubyLLM::RateLimitError # 429: Rate limit exceeded RubyLLM::ServerError # 500: Provider server error RubyLLM::ServiceUnavailableError # 502/503/504: Service unavailable RubyLLM::OverloadedError # 529: Service overloaded (Specific providers) # Non-API Errors (inherit from StandardError) RubyLLM::ConfigurationError # Missing required configuration (e.g., API key) RubyLLM::ModelNotFoundError # Requested model ID not found in registry RubyLLM::InvalidRoleError # Invalid role symbol used for a message ``` ## Basic Error Handling The fundamental way to handle errors is using Ruby's `begin`/`rescue` block. Catching the base `RubyLLM::Error` will handle most API-related issues. ```ruby begin chat = RubyLLM.chat response = chat.ask "Translate 'hello' to French." puts response.content rescue RubyLLM::Error => e # Generic handling for API errors puts "An API error occurred: #{e.message}" # Log the error for debugging # logger.error "RubyLLM API Error: #{e.class} - #{e.message}" rescue RubyLLM::ConfigurationError => e # Handle missing configuration puts "Configuration missing: #{e.message}" # Abort or prompt for configuration end ``` ## Handling Specific Errors For more granular control, rescue specific error classes. This allows you to implement different recovery strategies based on the error type. ```ruby begin chat = RubyLLM.chat response = chat.ask "Generate a complex report." rescue RubyLLM::UnauthorizedError puts "Authentication failed. Please check your API key configuration." # Maybe exit or redirect to config settings rescue RubyLLM::PaymentRequiredError puts "Payment required. Please check your provider account balance or plan." # Notify admin or user rescue RubyLLM::RateLimitError puts "Rate limit hit. Please wait a moment before trying again." # Implement backoff/retry logic (though RubyLLM has some built-in retries) rescue RubyLLM::ContextLengthExceededError puts "Your prompt/conversation is too large for this model." # Reduce prompt size or use a model with a larger context window rescue RubyLLM::ServiceUnavailableError puts "The AI service is temporarily unavailable. Please try again later." # Maybe offer a fallback or notify user rescue RubyLLM::BadRequestError => e puts "Invalid request sent to the API: #{e.message}" # Check the data being sent rescue RubyLLM::ModelNotFoundError => e puts "Error: #{e.message}. Check available models with RubyLLM.models.all" rescue RubyLLM::Error => e # Catch any other API errors puts "An unexpected API error occurred: #{e.message}" end ``` ## Accessing API Response Details Instances of `RubyLLM::Error` (and its subclasses related to API responses) hold the original `Faraday::Response` object in the `response` attribute. This can be useful for debugging or extracting provider-specific error codes. ```ruby begin chat = RubyLLM.chat(model: 'gpt-5-nano') # Assume this requires a specific org sometimes response = chat.ask "Some specific query" rescue RubyLLM::ForbiddenError => e puts "Access forbidden: #{e.message}" # Inspect the raw response body for provider-specific details if e.response&.body&.include?('invalid_organization') puts "Hint: Check if your API key is enabled for the correct OpenAI organization." end puts "Status Code: #{e.response&.status}" # puts "Full Response Body: #{e.response&.body}" # For deep debugging end ``` ## Error Handling During Streaming When using streaming with a block, errors can occur *during* the stream after some chunks have already been processed. The `ask` method will raise the error *after* the block execution finishes or is interrupted by the error. ```ruby begin chat = RubyLLM.chat accumulated_content = "" chat.ask "Generate a very long story..." do |chunk| print chunk.content accumulated_content << chunk.content # Simulate an error occurring mid-stream (e.g., network drop) # In a real scenario, the error would be raised by the underlying HTTP request end puts "\nStream completed successfully." rescue RubyLLM::RateLimitError puts "\nStream interrupted by rate limit. Partial content received:" puts accumulated_content rescue RubyLLM::Error => e puts "\nStream failed: #{e.message}. Partial content received:" puts accumulated_content end ``` Your block will execute for chunks received *before* the error. The final return value of `ask` when an error occurs during streaming might be unpredictable (often `nil`), so rely on the rescued exception for error handling. ## Handling Errors Within Tools When building [Tools](/tools/), you need to decide how errors within the tool's `execute` method should be handled: 1. **Return Error to LLM:** If the error is something the LLM might be able to recover from (e.g., invalid parameters provided by the LLM, temporary lookup failure), return a Hash containing an `:error` key. The LLM will see this error message as the tool's output and may try again or use a different approach. ```ruby class Weather < RubyLLM::Tool # ... params ... def execute(location:) if location.blank? return { error: "Location cannot be blank. Please provide a city name." } end # ... perform API call ... rescue Faraday::TimeoutError { error: "Weather API timed out. Please try again later." } end end ``` 2. **Raise Error for Application:** If the error indicates a problem with the tool itself or the application's state (e.g., database connection lost, configuration error, unrecoverable external API failure), `raise` an exception as normal. This will halt the RubyLLM interaction and bubble up to your application's main error handling (`begin/rescue`). ```ruby class DatabaseQueryTool < RubyLLM::Tool # ... params ... def execute(query:) User.find_by_sql(query) # Example query rescue ActiveRecord::ConnectionNotEstablished => e # This is likely an application-level problem, not something the LLM can fix. raise e # Let the application's error handling take over. rescue StandardError => e # Maybe return less critical errors to the LLM { error: "Database query failed: #{e.message}" } end end ``` Distinguishing between these helps the LLM work effectively with recoverable issues while ensuring critical application failures are handled appropriately. ## Automatic Retries RubyLLM automatically retries requests that fail due to transient network or server issues using Faraday's retry middleware. Retries are driven by error classification (exception types), not raw HTTP status codes alone. Retries are attempted for: * Network timeouts (`Timeout::Error`, `Faraday::TimeoutError`, `Errno::ETIMEDOUT`) * Connection failures (`Faraday::ConnectionFailed`) * Rate limit errors (`RubyLLM::RateLimitError`, often HTTP 429) * Server-side errors (`RubyLLM::ServerError`, `RubyLLM::ServiceUnavailableError`, `RubyLLM::OverloadedError` / HTTP 500, 502, 503, 504, 529) `RubyLLM::ContextLengthExceededError` is not retried. You can configure retry behavior via `RubyLLM.configure`: ```ruby RubyLLM.configure do |config| config.max_retries = 5 # Default: 3 config.retry_interval = 0.5 # Default: 0.1 # config.retry_backoff_factor = 2 # Default: 2 # config.retry_interval_randomness = 0.5 # Default: 0.5 end ``` ## Debugging If you encounter unexpected errors or behavior, enable debug logging by setting the `RUBYLLM_DEBUG` environment variable: ```bash export RUBYLLM_DEBUG=true # Now run your Ruby script or Rails server ``` This will cause RubyLLM to log detailed information about API requests and responses, including headers and bodies (with sensitive data like API keys filtered), which can be invaluable for troubleshooting. ## Best Practices * **Be Specific:** Rescue specific error classes whenever possible for tailored recovery logic. * **Log Errors:** Always log errors, including relevant context (model used, input data if safe) for debugging. Consider using the `response` attribute on `RubyLLM::Error` for more details. * **User Feedback:** Provide clear, user-friendly feedback when an AI operation fails. Avoid exposing raw API error messages directly. * **Fallbacks:** Consider fallback mechanisms (e.g., trying a different model, using cached data, providing a default response) if the AI service is critical to your application's function. * **Monitor:** Track the frequency of different error types in production to identify recurring issues with providers or your implementation. ## Next Steps * [Using Tools](/tools/) * [Streaming Responses](/streaming/) * [Rails Integration](/rails/) --- ### Model Registry URL: https://rubyllm.com/models/ Date: 2026-08-08 # Model Registry {: .no_toc } Access hundreds of AI models from all major AI providers with one Ruby framework {: .fs-6 .fw-300 } ## Table of contents {: .no_toc .text-delta } 1. TOC {:toc} --- After reading this guide, you will know: * How RubyLLM discovers and registers models. * How to find and filter available models based on provider, type, or capabilities. * How to understand model capabilities and pricing using `Model::Info`. * How to use model aliases for convenience. * How to connect to custom endpoints (like Azure OpenAI, Anthropic proxies, or local gateways) using provider-specific `*_api_base` settings. * How to use models not listed in the default registry using `assume_model_exists`. ## The Model Registry RubyLLM maintains an internal registry of known AI models, typically stored in `lib/ruby_llm/models.json` within the gem. This registry is populated by running the `rake models:update` task, which queries the APIs of configured providers to discover their available models and capabilities. The registry stores crucial information about each model, including: * **`id`**: The unique identifier used by the provider (e.g., `gpt-4o-2024-08-06`). * **`provider`**: The source provider (`openai`, `anthropic`, etc.). * **`type`**: The model's primary function (`chat`, `embedding`, etc.). * **`name`**: A human-friendly name. * **`context_window`**: Max input tokens (e.g., `128_000`). * **`max_tokens`**: Max output tokens (e.g., `16_384`). * **`supports_vision`**: If it can process images and videos. * **`supports_functions`**: If it can use [Tools](/tools/). * **`input_price_per_million`**: Cost in USD per 1 million input tokens. * **`output_price_per_million`**: Cost in USD per 1 million output tokens. * **`cache_read_input_price_per_million`**: Cost in USD per 1 million cache read tokens, when available. v1.15+ * **`cache_write_input_price_per_million`**: Cost in USD per 1 million cache write tokens, when available. v1.15+ * **`family`**: A broader classification (e.g., `gpt4o`). This registry allows RubyLLM to validate models, route requests correctly, provide capability information, and offer convenient filtering. You can see the full list of currently registered models in the [Available Models Guide](/available-models/). ### Refreshing the Registry **For Application Developers:** The recommended way to refresh models in your application is to call `RubyLLM.models.refresh!` directly: ```ruby # In your application code (console, background job, etc.) RubyLLM.models.refresh! puts "Refreshed in-memory model list." ``` This refreshes the in-memory model registry and is what you want 99% of the time. This method is safe to call from Rails applications, background jobs, or any running Ruby process. **Important:** `refresh!` only updates the in-memory registry. To persist changes to disk, call: ```ruby RubyLLM.models.refresh! RubyLLM.models.save_to_json # Saves to configured model_registry_file (v1.9.0+) ``` If your gem directory is read-only, configure a writable location with `config.model_registry_file` (v1.9.0+). See the [Configuration Guide](/configuration/#model-registry-file) for details. **How refresh! Works:** The `refresh!` method performs the following steps: 1. **Fetches from configured providers**: Queries the APIs of all configured providers (OpenAI, Anthropic, Ollama, etc.) to get their current list of available models. 2. **Fetches from models.dev API**: Retrieves comprehensive model metadata from [models.dev](https://models.dev), which aggregates LLM documentation across providers. It provides details about model capabilities, pricing, context windows, and more. 3. **Merges the data**: Combines provider-specific data with models.dev metadata. Provider data takes precedence for availability, while models.dev enriches models with additional details. 4. **Updates the in-memory registry**: Replaces the current registry with the refreshed data. The method returns a chainable `Models` instance, allowing you to immediately query the updated registry: ```ruby # Refresh and immediately query chat_models = RubyLLM.models.refresh!.chat_models ``` **Note:** models.dev is the upstream registry for RubyLLM metadata. If you encounter issues with model data, please report them via the models.dev site or repo. **Local Provider Models:** By default, `refresh!` includes models from local providers like Ollama and GPUStack if they're configured. To exclude local providers and only fetch from remote APIs: ```ruby # Only fetch from remote providers (Anthropic, OpenAI, etc.) RubyLLM.models.refresh!(remote_only: true) ``` This is useful when you want to refresh only cloud-based models without querying local model servers. **For Gem Development:** The `rake models:update` task is designed for gem maintainers and updates the `models.json` file shipped with the gem: ```bash # Only for gem development - requires API keys and gem directory structure bundle exec rake models:update ``` This task is not intended for Rails applications as it writes to gem directories and requires the full gem development environment. **Persisting Models to Your Database:** For Rails applications, the install generator sets up everything automatically: ```bash bin/rails generate ruby_llm:install bin/rails db:migrate ``` This creates the Model table and loads model data from the gem's registry. To refresh model data from provider APIs: ```ruby # Fetches latest model info from configured providers (requires API keys) Model.refresh! ``` ## Exploring and Finding Models Use `RubyLLM.models` to explore the registry. ### Listing and Filtering ```ruby # Get a collection of all registered models all_models = RubyLLM.models.all # Filter by type chat_models = RubyLLM.models.chat_models embedding_models = RubyLLM.models.embedding_models # Filter by provider openai_models = RubyLLM.models.by_provider(:openai) # or 'openai' # Filter by model family (e.g., all Claude 3 Sonnet variants) claude3_sonnet_family = RubyLLM.models.by_family('claude3_sonnet') # Chain filters and use Enumerable methods openai_vision_models = RubyLLM.models.by_provider(:openai) .select(&:supports_vision?) puts "Found #{openai_vision_models.count} OpenAI vision models." ``` ### Finding a Specific Model Use `find` to get a `Model::Info` object containing details about a specific model. ```ruby # Find by exact ID or alias model_info = RubyLLM.models.find('gpt-5.4') if model_info puts "Model: #{model_info.name}" puts "Provider: #{model_info.provider}" puts "Context Window: #{model_info.context_window} tokens" else puts "Model not found." end # Find raises ModelNotFoundError if the ID is unknown # RubyLLM.models.find('no-such-model-exists') # => raises ModelNotFoundError ``` ### Model Aliases RubyLLM uses aliases (defined in `lib/ruby_llm/aliases.json`) for convenience, mapping common names to specific versions. ```ruby # 'claude-sonnet-4-6' might resolve to 'claude-3-5-sonnet-20241022' chat = RubyLLM.chat(model: 'claude-sonnet-4-6') puts chat.model.id # => "claude-3-5-sonnet-20241022" (or latest version) ``` When you call `find` **without** a provider, RubyLLM prioritizes exact ID matches before falling back to aliases. ### Provider-Specific Resolution Specify the provider if the same alias exists across multiple providers. ```ruby # Get Claude 3.5 Sonnet from Anthropic model_anthropic = RubyLLM.models.find('claude-sonnet-4-6', :anthropic) # Get Claude 3.5 Sonnet via AWS Bedrock model_bedrock = RubyLLM.models.find('claude-sonnet-4-6', :bedrock) ``` When you pass a provider, RubyLLM resolves aliases first. For Bedrock, it then applies region/inference-profile resolution (for example `us.` prefixes) before falling back to an exact ID match. ## Calculating Costs {: .d-inline-block } v1.15+ {: .label .label-green } Models can turn token usage into a `RubyLLM::Cost` object: ```ruby model = RubyLLM.models.find('gpt-5-nano') response = RubyLLM.chat(model: model.id, provider: model.provider).ask("Summarize Ruby's object model.") cost = model.cost_for(response.tokens) puts cost.input puts cost.output puts cost.cache_read puts cost.cache_write puts cost.thinking puts cost.total ``` Costs use RubyLLM's normalized token buckets: standard input, billable output, cache read, cache write, and separately priced thinking when the model registry exposes a distinct reasoning-token price. See [Tracking Token Usage](/chat/#tracking-token-usage) for the provider comparison table and what RubyLLM exposes consistently across providers. Most applications use the shorter helpers on messages, chats, and agents: ```ruby response.cost.total chat.cost.total agent.cost.total ``` To combine several cost objects yourself, use `RubyLLM::Cost.aggregate`: ```ruby cost = RubyLLM::Cost.aggregate(messages.map(&:cost)) cost.total ``` If pricing is incomplete for tokens that were used, the affected cost and `cost.total` return `nil`. Cost helpers cover token-priced conversation usage; provider-specific add-ons such as search-query charges remain available in the provider's raw usage payload. ## Connecting to Custom Endpoints & Using Unlisted Models {: .d-inline-block } Sometimes you need to interact with models or endpoints not covered by the standard registry, such as: * Azure OpenAI Service endpoints. * API Proxies & Gateways (LiteLLM, Fastly AI Accelerator). * Self-Hosted/Local Models (LM Studio, Ollama via OpenAI adapter). * Brand-new model releases. * Custom fine-tunes or deployments with unique names. RubyLLM offers two mechanisms for these cases: ### Custom OpenAI API Base URL (`openai_api_base`) If you need to target an endpoint that uses the **OpenAI API format** but has a different URL, configure `openai_api_base` in `RubyLLM.configure`. ```ruby # config/initializers/ruby_llm.rb RubyLLM.configure do |config| config.openai_api_key = ENV['AZURE_OPENAI_KEY'] # Key for your endpoint config.openai_api_base = "https://YOUR_AZURE_RESOURCE.openai.azure.com" # Your endpoint end ``` * This setting **only** affects requests made with `provider: :openai`. * It directs those requests to your specified URL instead of `https://api.openai.com/v1`. * See [Configuration Guide](/configuration/). ### Assuming Model Existence (`assume_model_exists`) To use a model identifier not listed in RubyLLM's registry, use the `assume_model_exists: true` flag. This tells RubyLLM to bypass its validation check. ```ruby # Example: Using a custom Azure deployment name # Assumes openai_api_base is configured for your Azure endpoint chat = RubyLLM.chat( model: 'my-company-secure-gpt4o', # Your custom deployment name provider: :openai, # MUST specify provider assume_model_exists: true # Bypass registry check ) response = chat.ask("Internal knowledge query...") puts response.content # You can also use it in .with_model chat.with_model( 'gpt-5-alpha', provider: :openai, # MUST specify provider assume_exists: true ) ``` The `assume_model_exists` flag also works with `RubyLLM.embed` and `RubyLLM.paint` for embedding and image generation models: ```ruby # Custom embedding model embedding = RubyLLM.embed( "Test text", model: 'my-custom-embedder', provider: :openai, assume_model_exists: true ) # Custom image model image = RubyLLM.paint( "A beautiful landscape", model: 'my-custom-dalle', provider: :openai, assume_model_exists: true ) ``` **Key Points when Assuming Existence:** * **`provider:` is Mandatory:** You must tell RubyLLM which API format to use (`ArgumentError` otherwise). * **No Validation:** RubyLLM won't check the registry for the model ID. * **Capability Assumptions:** Capability checks (like `supports_functions?`) are bypassed by assuming `true`. You are responsible for ensuring the model supports the features you use. * **Your Responsibility:** Ensure the model ID is correct for the target endpoint. * **Warning Log:** A warning is logged indicating validation was skipped. Use these features when the standard registry doesn't cover your specific model or endpoint needs. For standard models, rely on the registry for validation and capability awareness. See the [Chat Guide](/chat/) for more on using the `chat` object. --- ### Instrumentation URL: https://rubyllm.com/instrumentation/ Date: 2026-08-08 # Instrumentation {: .no_toc .d-inline-block } v1.16.0+ {: .label .label-green } Observe RubyLLM requests, chats, tool calls, embeddings, and model refreshes. {: .fs-6 .fw-300 } ## Table of contents {: .no_toc .text-delta } 1. TOC {:toc} --- After reading this guide, you will know: * How to subscribe to RubyLLM events in Rails. * How to connect RubyLLM instrumentation outside Rails. * Which events RubyLLM emits. * Which payload fields may contain sensitive application data. ## Rails Rails apps automatically emit RubyLLM events through `ActiveSupport::Notifications`. Subscribe to them the same way you would subscribe to Rails framework events: ```ruby # config/initializers/ruby_llm_instrumentation.rb ActiveSupport::Notifications.subscribe('chat.ruby_llm') do |_name, _start, _finish, _id, payload| Rails.logger.info( provider: payload[:provider], model: payload[:model], input_tokens: payload[:input_tokens], output_tokens: payload[:output_tokens] ) end ``` When an instrumented block raises, Rails adds the standard `:exception` and `:exception_object` payload keys. ## Outside Rails Outside Rails, set `config.instrumenter` to any object that responds to `instrument(name, payload) { ... }`: ```ruby class AppInstrumenter def instrument(name, payload) started_at = Process.clock_gettime(Process::CLOCK_MONOTONIC) result = yield if block_given? result rescue StandardError => error payload = payload.merge( exception: [error.class.name, error.message], exception_object: error ) raise ensure duration = Process.clock_gettime(Process::CLOCK_MONOTONIC) - started_at Observability.record(name, payload.merge(duration: duration)) end end RubyLLM.configure do |config| config.instrumenter = AppInstrumenter.new end ``` You can also set `instrumenter` on a [context](/configuration/#contexts-isolated-configurations) when you only want instrumentation around a specific operation. ## Events RubyLLM emits these events: * `request.ruby_llm` - HTTP request metadata such as provider, method, URL, and status * `chat.ruby_llm` - chat completion metadata including model, provider, messages, response, and token usage * `tool_call.ruby_llm` - tool name, arguments, and result * `embedding.ruby_llm` - embedding model, input, result, token usage, and vector dimensions * `image.ruby_llm` - image generation model, prompt, size, and result * `moderation.ruby_llm` - moderation model, input, result, and flagged status * `transcription.ruby_llm` - transcription model, language, result, and token usage * `models.refresh.ruby_llm` - model registry refresh metadata ## Payloads Payloads include the Ruby objects needed by observability adapters, but message content, tool arguments, and provider responses may be sensitive. Only export or log those fields when your application policy allows it. Non-Rails instrumenters control their own error payload behavior. If your instrumenter records exceptions, keep those payloads consistent with the rest of your observability stack. --- ### Agentic Workflows URL: https://rubyllm.com/agentic-workflows/ Date: 2026-08-08 # Agentic Workflows {: .no_toc } Build workflow-oriented AI systems with plain Ruby orchestration, from routing and parallelization to RAG {: .fs-6 .fw-300 } ## Table of contents {: .no_toc .text-delta } 1. TOC {:toc} --- After reading this guide, you will know: * How to implement common workflow patterns with plain Ruby classes * How to compose sequential, routing, parallel, and fan-in workflows * How to use evaluator loops when output quality needs iteration * How to implement RAG as part of a workflow ## Workflow Patterns A workflow is just orchestration code that coordinates one or more agents. In practice, this is often a small Ruby class with a single public method. ### Sequential Workflow Use this pattern when each step depends on the previous one. ```ruby class ResearchAgent < RubyLLM::Agent model "gemini-3.1-pro-preview" instructions "Given a topic, return concise, reliable key facts." end class WriterAgent < RubyLLM::Agent model "claude-sonnet-4-6" instructions "Given research notes, write a clear article." end class ResearchWriterWorkflow def create_article(topic) research = ResearchAgent.new.ask(topic).content WriterAgent.new.ask(research).content end end # Usage workflow = ResearchWriterWorkflow.new article = workflow.create_article("Ruby 3.3 features") ``` ### Routing Workflow Use this pattern when requests fall into clear categories that benefit from specialized agents or models. ```ruby class CodeAgent < RubyLLM::Agent model "gpt-5.4" instructions "You are a coding assistant. Be precise and practical." end class CreativeAgent < RubyLLM::Agent model "claude-opus-4-6" instructions "You are a creative writing assistant." end class FactualAgent < RubyLLM::Agent model "gemini-3.1-pro-preview" instructions "You are a factual assistant. Prioritize accuracy." end class TaskClassifierAgent < RubyLLM::Agent model "gpt-5-mini" instructions "Classify the request as one word only: code, creative, or factual." end class ModelRouterWorkflow def call(query) agent_for(query).new.ask(query).content end private def agent_for(query) case classify(query) when :code then CodeAgent when :creative then CreativeAgent when :factual then FactualAgent else FactualAgent end end def classify(query) TaskClassifierAgent.new.ask(query).content.downcase.to_sym end end # Usage workflow = ModelRouterWorkflow.new response = workflow.call("Write a Ruby function to parse JSON") ``` ### Parallel Workflow Use this pattern when independent analyses can run at the same time. ```ruby require 'async' class SentimentAgent < RubyLLM::Agent instructions "Given text, return one word sentiment: positive, negative, or neutral." end class SummaryAgent < RubyLLM::Agent instructions "Given text, summarize it in one concise sentence." end class KeywordAgent < RubyLLM::Agent instructions "Given text, extract exactly 5 relevant keywords." end class ParallelAnalyzer def analyze(text) Async do |task| sentiment = task.async { SentimentAgent.new.ask(text).content } summary = task.async { SummaryAgent.new.ask(text).content } keywords = task.async { KeywordAgent.new.ask(text).content } { sentiment: sentiment.wait, summary: summary.wait, keywords: keywords.wait } end.wait end end # Usage analyzer = ParallelAnalyzer.new insights = analyzer.analyze("Your text here...") # All three analyses run concurrently ``` ### Fan-Out/Fan-In Workflow Use this pattern when multiple specialists produce outputs that are later synthesized. ```ruby require 'async' class SecurityReviewAgent < RubyLLM::Agent model "claude-sonnet-4-6" instructions "Given code, review it for security issues." end class PerformanceReviewAgent < RubyLLM::Agent model "gpt-5.4" instructions "Given code, review it for performance issues." end class StyleReviewAgent < RubyLLM::Agent model "gpt-5-mini" instructions "Given code, review style against Ruby conventions." end class ReviewSynthesizerAgent < RubyLLM::Agent instructions "Given multiple code review reports, summarize prioritized findings." end class CodeReviewSystem def review_code(code) Async do |task| security = task.async { SecurityReviewAgent.new.ask(code).content } performance = task.async { PerformanceReviewAgent.new.ask(code).content } style = task.async { StyleReviewAgent.new.ask(code).content } ReviewSynthesizerAgent.new.ask( "security: #{security.wait}\n\n" \ "performance: #{performance.wait}\n\n" \ "style: #{style.wait}" ).content end.wait end end # Usage reviewer = CodeReviewSystem.new summary = reviewer.review_code("def calculate(x); x * 2; end") ``` ### Evaluation Loop (Evaluator-Optimizer) Use this pattern when you have clear quality criteria and want iterative refinement. ```ruby class DraftAgent < RubyLLM::Agent instructions "Given a task, produce the best possible draft response." end class CriticAgent < RubyLLM::Agent schema do string :verdict, enum: ["pass", "revise"], description: "Whether the draft passes or needs changes" string :feedback, description: "Specific feedback for improvement" end instructions "Review the draft against the task and return a verdict and specific feedback." end class EvaluatorOptimizerWorkflow MAX_ROUNDS = 3 def call(task) draft = DraftAgent.new.ask(task).content MAX_ROUNDS.times do verdict, feedback = review(task:, draft:) return draft if verdict == "pass" draft = revise(task:, draft:, feedback:) end draft end private def review(task:, draft:) result = CriticAgent.new.ask("Task:\n#{task}\n\nDraft:\n#{draft}").content [result.fetch("verdict"), result.fetch("feedback")] end def revise(task:, draft:, feedback:) DraftAgent.new.ask("Task:\n#{task}\n\nCurrent draft:\n#{draft}\n\nFeedback:\n#{feedback}").content end end # Usage workflow = EvaluatorOptimizerWorkflow.new final = workflow.call("Write a concise onboarding email for a new API customer") ``` ## RAG as a Workflow Step RAG is often just one step in a larger workflow: retrieve relevant context, then answer with that context. ### Setup ```ruby # Gemfile gem 'neighbor' gem 'ruby_llm' # Generate migration for pgvector bin/rails generate neighbor:vector bin/rails db:migrate # Create documents table class CreateDocuments < ActiveRecord::Migration[7.1] def change create_table :documents do |t| t.text :content t.string :title t.vector :embedding, limit: 1536 # OpenAI embedding size t.timestamps end add_index :documents, :embedding, using: :hnsw, opclass: :vector_l2_ops end end ``` ### Document Model with Embeddings ```ruby class Document < ApplicationRecord has_neighbors :embedding before_save :generate_embedding, if: :content_changed? private def generate_embedding response = RubyLLM.embed(content) self.embedding = response.vectors end end ``` ### Retrieval Tool ```ruby class DocumentSearch < RubyLLM::Tool description "Searches knowledge base for relevant information" param :query, desc: "Search query" def execute(query:) embedding = RubyLLM.embed(query).vectors documents = Document.nearest_neighbors( :embedding, embedding, distance: "euclidean" ).limit(3) documents.map do |doc| "#{doc.title}: #{doc.content.truncate(500)}" end.join("\n\n---\n\n") end end ``` ### Answering Agent ```ruby class SupportWithDocsAgent < RubyLLM::Agent tools DocumentSearch instructions "Search for context before answering. Cite sources." end # Usage agent = SupportWithDocsAgent.new response = agent.ask("What is our refund policy?").content ``` ## Error Handling For robust error handling in workflow code, leverage the patterns from the Tools guide: * Return `{ error: "description" }` for recoverable errors the LLM might fix * Raise exceptions for unrecoverable errors (missing config, service down) * Use the retry middleware for transient failures See the [Error Handling section in Tools](/tools/#error-handling-in-tools) for detailed patterns. ## Next Steps * [Agents](/agents/) - Define reusable agent classes * [Using Tools](/tools/) - Add capabilities and external actions * [Scale with Async](/async/) - Run concurrent workflow steps * [Error Handling](/error-handling/) - Build resilient systems --- ### Upgrading URL: https://rubyllm.com/upgrading/ Date: 2026-08-08 # Upgrading {: .no_toc } Upgrade guides for changes in data formats {: .fs-6 .fw-300 } ## Table of contents {: .no_toc .text-delta } 1. TOC {:toc} This guide focuses on upgrade-impacting changes: migrations, token semantics, deprecations, and compatibility notes. It is not a complete changelog. For every feature, fix, and patch note, see the [GitHub releases](https://github.com/crmne/ruby_llm/releases). {: .note } --- # Upgrade to 1.15 ## How to Upgrade No generator is required for the token and cost API changes in 1.15. If you use the Rails integration and already ran the v1.9 migration, no new columns are needed. The new `cache_read_tokens` and `cache_write_tokens` helpers use the existing `cached_tokens` and `cache_creation_tokens` columns. ## Token Semantics Changed RubyLLM now normalizes prompt cache usage before exposing token counts. From 1.15 onward, `response.tokens.input` means standard input tokens. When a provider includes cache reads or cache writes in its raw prompt token total, RubyLLM subtracts those cache buckets and exposes them separately. Use the new cache names in new code: ```ruby response.tokens.input response.tokens.output response.tokens.cache_read response.tokens.cache_write ``` The top-level token helpers still work for backwards compatibility: ```ruby response.input_tokens # Same as tokens.input response.output_tokens # Same as tokens.output response.cache_read_tokens # Same as tokens.cache_read response.cache_write_tokens # Same as tokens.cache_write response.cached_tokens # Same as cache_read_tokens response.cache_creation_tokens # Same as cache_write_tokens ``` If your app stored or displayed provider raw prompt totals, reconstruct the request-side input activity by adding the normalized buckets: ```ruby request_side_input_tokens = response.tokens.input.to_i + response.tokens.cache_read.to_i + response.tokens.cache_write.to_i ``` For costs, prefer the new cost helpers instead of multiplying token totals yourself: ```ruby response.cost.total chat.cost.total agent.cost.total ``` Cost helpers are available from 1.15 onward. They return `nil` for any cost bucket whose pricing is missing, and `cost.total` is also `nil` when a used bucket has incomplete pricing. `tokens.thinking` remains available from 1.10. From 1.15 onward, `tokens.output` is normalized as the billable output bucket. Do not add `tokens.thinking` to `tokens.output` yourself; RubyLLM includes thinking in output when the provider bills it as output, and exposes `cost.thinking` only for models with distinct reasoning-token pricing. See [Tracking Token Usage](/chat/#tracking-token-usage) for the provider comparison table and the exact normalized token semantics RubyLLM exposes. # Upgrade to 1.14 ## How to Upgrade ```bash # Run the upgrade generator bin/rails generate ruby_llm:upgrade_to_v1_14 # Run migrations bin/rails db:migrate ``` That's it! The generator: - Changes `thought_signature` on tool calls from `string` to `text` - Prevents thought signature truncation issues on MySQL/MariaDB ## What's New in 1.14 Among other features: - Safer Gemini thought signature persistence for Rails apps using ActiveRecord # Upgrade to 1.10 ## How to Upgrade ```bash # Run the upgrade generator bin/rails generate ruby_llm:upgrade_to_v1_10 # Run migrations bin/rails db:migrate ``` That's it! The generator: - Adds `thinking_text` and `thinking_signature` for storing extended thinking output - Adds `thinking_tokens` for tracking thinking token usage - Adds `thought_signature` to tool calls for Gemini 3 Pro function calling ## What's New in 1.10 Among other features: - Extended thinking support across providers with optional persistence - Thinking token tracking when providers report it # Upgrade to 1.9 ## How to Upgrade ```bash # Run the upgrade generator bin/rails generate ruby_llm:upgrade_to_v1_9 # Run migrations bin/rails db:migrate ``` That's it! The generator: - Adds the `cached_tokens` and `cache_creation_tokens` columns for tracking accessed cached tokens and created cache tokens respectively. - Adds the `content_raw` column for the new [Raw Content Blocks](/chat/#raw-content-blocks) feature ## What's New in 1.9 Among other features: - [Raw Content Blocks](/chat/#raw-content-blocks) to pass content verbatim to an LLM, e.g. useful to enable Anthropic Prompt Caching. - Cached token tracking to accurately track costs given cache hits # Upgrade to 1.7 Upgrade to the DB-backed model registry for better data integrity and rich model metadata. ## How to Upgrade ### From 1.6 to 1.7 (2 commands) ```bash # Run the upgrade generator bin/rails generate ruby_llm:upgrade_to_v1_7 # Run migrations bin/rails db:migrate ``` That's it! The generator: - Creates the models table if needed - Automatically adds `config.use_new_acts_as = true` to your initializer - Automatically updates your existing models' `acts_as` declarations to the new version - Migrates your existing data to use foreign keys - Loads the models in the db - Preserves all your data (old string columns renamed to `model_id_string`) ### Custom Model Names If you're using custom model names: ```bash bin/rails generate ruby_llm:upgrade_to_v1_7 chat:Conversation message:ChatMessage tool_call:MyToolCall model:MyModel bin/rails db:migrate ``` ### What happens without upgrading Your existing 1.6 app continues working without any changes. You'll see a deprecation warning on Rails boot: ``` !!! RubyLLM's legacy acts_as API is deprecated and will be removed in RubyLLM 2.0.0. ``` You can silence or raise RubyLLM deprecations while upgrading: ```ruby RubyLLM.configure do |config| config.deprecation_behavior = :silence # or :raise end ``` ## What's New in 1.7 Among other features, the DB-backed model registry replaces simple string fields with proper ActiveRecord associations. Additionally, the `acts_as` helpers have been redesigned with a more Rails-like API. ### Available with DB-backed Model Registry {: .d-inline-block } v1.7.0+ {: .label .label-green } **New Rails-like `acts_as` API** ```ruby # New API uses Rails association names as primary parameters acts_as_chat messages: :messages, model: :model acts_as_message chat: :chat, tool_calls: :tool_calls, model: :model # vs Legacy API which required explicit class names acts_as_chat message_class: 'Message', tool_call_class: 'ToolCall' acts_as_message chat_class: 'Chat', chat_foreign_key: 'chat_id' ``` **Rich model metadata** ```ruby chat.model.name # => "GPT-4" chat.model.context_window # => 128000 chat.model.supports_vision # => true chat.model.input_token_cost # => 2.50 ``` **Provider routing** ```ruby Chat.create!(model: "claude-sonnet-4-6", provider: "bedrock") ``` **Model associations and queries** ```ruby Chat.joins(:model).where(models: { provider: 'anthropic' }) Model.select { |m| m.supports_functions? } # Use delegated methods ``` **Model alias resolution** ```ruby Chat.create!(model: "gpt-5-nano", provider: "openrouter") # Resolves to openai/gpt-5-nano automatically ``` **Usage tracking** ```ruby Model.joins(:chats).group(:id).order('COUNT(chats.id) DESC') ``` ### Available without Model Registry {: .d-inline-block } Legacy mode {: .label .label-yellow } **Legacy `acts_as` API** - Still uses the old parameter style ```ruby acts_as_chat message_class: 'Message', tool_call_class: 'ToolCall' acts_as_message chat_class: 'Chat', tool_call_class: 'ToolCall' ``` **Basic functionality** - All core RubyLLM features work ```ruby chat.ask("Hello!") # Works fine chat.model_id # => "gpt-5.4" (string only, no metadata) ``` **Limited to:** - String-based model IDs only - Default provider routing ## If You Have Custom Model Names If you're using custom model names (e.g., `Conversation` instead of `Chat`), you may need to update your `acts_as` declarations to the new API: **Before (1.6):** ```ruby class Conversation < ApplicationRecord acts_as_chat message_class: 'ChatMessage', tool_call_class: 'AiToolCall' end class ChatMessage < ApplicationRecord acts_as_message chat_class: 'Conversation', chat_foreign_key: 'conversation_id' end ``` **After (1.7):** ```ruby class Conversation < ApplicationRecord acts_as_chat messages: :chat_messages # Association name end class ChatMessage < ApplicationRecord acts_as_message chat: :conversation, # Association name tool_calls: :ai_tool_calls end ``` The new API follows Rails association inference. Association names determine default foreign keys; class options only change the class name. For example, `tool_calls: :ai_tool_calls` uses `ai_tool_call_id`, while `tool_call_class: 'AiToolCall'` by itself still uses `tool_call_id`. ## New Chat UI Generator ### Instant Chat Interface {: .d-inline-block } v1.7.0+ {: .label .label-green } Add a fully-functional chat UI to your Rails app with Turbo streaming: ```bash # Default model names bin/rails generate ruby_llm:chat_ui # Or with custom model names (same as install generator) bin/rails generate ruby_llm:chat_ui chat:Conversation message:ChatMessage model:LLMModel ``` This creates: - Complete chat controller with streaming responses - Turbo-powered views with real-time updates - Styled chat interface (messages, input, model selector) - File attachment support - Token usage tracking - Copy-to-clipboard functionality The chat UI works with your existing Chat and Message models and includes: - Model selection dropdown - Real-time streaming responses - Markdown rendering - Code syntax highlighting - Responsive design ## Troubleshooting ### Config must be set before models load If you're setting `use_new_acts_as = true` in an initializer (like `config/initializers/ruby_llm.rb`), it won't work. Rails loads models before initializers run, causing various issues: **Symptoms:** - Legacy `acts_as` module gets included even though you set `use_new_acts_as = true` - `undefined local variable or method 'acts_as_model'` error during migration - Errors referencing `lib/ruby_llm/active_record/acts_as_legacy.rb` in backtraces - Works in development/staging but fails in production **Solution:** Add the configuration to `config/application.rb` **before** your Application class: ```ruby # config/application.rb require_relative "boot" require "rails/all" # Configure RubyLLM before Rails::Application is inherited RubyLLM.configure do |config| config.use_new_acts_as = true end module YourApp class Application < Rails::Application # ... end end ``` This ensures RubyLLM is configured before ActiveRecord loads your models. Other configuration options (API keys, timeouts, etc.) can still go in your initializer. > This limitation exists because both legacy and new `acts_as` APIs need to coexist during the 1.x series. It will be resolved in RubyLLM 2.0 when the legacy API is removed. {: .note } See the [Configuration guide](/configuration/#initializer-load-timing-issue-with-use_new_acts_as) for more details. ## New Applications Fresh installs get the model registry automatically: ```bash bin/rails generate ruby_llm:install bin/rails db:migrate # Optional: Add chat UI bin/rails generate ruby_llm:chat_ui ``` --- ## Reference ### Available Models URL: https://rubyllm.com/available-models/ Date: 2026-08-08 # Available Models {: .no_toc } Browse 1248 AI models across 11 remote providers. Updated 2026-08-08. {: .fs-6 .fw-300 } ## Table of contents {: .no_toc .text-delta } 1. TOC {:toc} --- _Updated 2026-08-08. This page lists the latest refreshed registry, also available as raw JSON at [rubyllm.com/models.json](https://rubyllm.com/models.json). It covers remote providers only; models on local providers (Ollama, GPUStack) are discovered from your own servers when you refresh._ Your installed gem may bundle an older snapshot of the registry. Refresh it to get the latest models in your app too: ```ruby RubyLLM.models.refresh! ``` See [the models guide](/models/) for how refreshing works in plain Ruby and Rails. ## Models by Provider ### Anthropic (13) | Model | Provider | I/O | Capabilities | Context | Max Output | Standard Pricing (per 1M tokens) | | :-- | :-- | :-- | :-- | --: | --: | :-- | | claude-fable-5 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, citations, tool_choice, parallel_tool_calls | 1000000 | 128000 | In: $10.00, Out: $50.00, Cache Read: $1.00, Cache Write: $12.50 | | claude-haiku-4-5-20251001 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, citations, tool_choice, parallel_tool_calls | 200000 | 64000 | In: $1.00, Out: $5.00, Cache Read: $0.10, Cache Write: $1.25 | | claude-haiku-4-5 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $1.00, Out: $5.00, Cache Read: $0.10, Cache Write: $1.25 | | claude-opus-4-5-20251101 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, citations, tool_choice, parallel_tool_calls | 200000 | 64000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | claude-opus-4-5 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | claude-opus-4-6 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, citations, tool_choice, parallel_tool_calls | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | claude-opus-4-7 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, citations, tool_choice, parallel_tool_calls | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | claude-opus-4-8 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, citations, tool_choice, parallel_tool_calls | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | claude-opus-5 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, citations, tool_choice, parallel_tool_calls | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | claude-sonnet-4-5-20250929 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, citations, tool_choice, parallel_tool_calls | 1000000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | claude-sonnet-4-5 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | claude-sonnet-4-6 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, citations, tool_choice, parallel_tool_calls | 1000000 | 128000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | claude-sonnet-5 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, citations, tool_choice, parallel_tool_calls | 1000000 | 128000 | In: $2.00, Out: $10.00, Cache Read: $0.20, Cache Write: $2.50 | ### Azure (311) | Model | Provider | I/O | Capabilities | Context | Max Output | Standard Pricing (per 1M tokens) | | :-- | :-- | :-- | :-- | --: | --: | :-- | | AI21-Jamba-1.5-Large | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | AI21-Jamba-1.5-Mini | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | AI21-Jamba-Instruct | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Codestral-2501-2 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Cohere-command-r | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Cohere-command-r-08-2024 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Cohere-command-r-plus | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Cohere-command-r-plus-08-2024 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Cohere-embed-v3-english | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Cohere-embed-v3-multilingual | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Cohere-rerank-v4.0-fast | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Cohere-rerank-v4.0-pro | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | DeepSeek-R1 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | DeepSeek-R1-0528 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | DeepSeek-V3 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | DeepSeek-V3-0324 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | DeepSeek-V3.1 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | DeepSeek-V3.2 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | DeepSeek-V3.2-Speciale | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | DeepSeek-V4-Flash-2026-04-23 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | DeepSeek-V4-Pro-2026-04-23 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | FLUX-1.1-pro | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | FLUX.1-Kontext-pro | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | FLUX.2-pro | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Kimi-K2-Thinking | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Kimi-K2.5 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Kimi-K2.6-2026-04-20 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Llama-3.2-11B-Vision-Instruct | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Llama-3.2-11B-Vision-Instruct-2 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Llama-3.2-90B-Vision-Instruct | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Llama-3.2-90B-Vision-Instruct-2 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Llama-3.2-90B-Vision-Instruct-3 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Llama-3.3-70B-Instruct | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Llama-3.3-70B-Instruct-2 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Llama-3.3-70B-Instruct-3 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Llama-3.3-70B-Instruct-4 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Llama-3.3-70B-Instruct-5 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Llama-3.3-70B-Instruct-9 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Llama-4-Maverick-17B-128E-Instruct-FP8 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Llama-4-Scout-17B-16E-Instruct | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | MAI-DS-R1 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | MAI-Image-2-2026-02-20 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | MAI-Image-2.5-2026-06-02 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | MAI-Image-2.5-Flash-2026-06-02 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | MAI-Image-2e-2026-04-09 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Meta-Llama-3-70B-Instruct-6 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Meta-Llama-3-70B-Instruct-7 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Meta-Llama-3-70B-Instruct-8 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Meta-Llama-3-70B-Instruct-9 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Meta-Llama-3-8B-Instruct-6 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Meta-Llama-3-8B-Instruct-7 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Meta-Llama-3-8B-Instruct-8 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Meta-Llama-3-8B-Instruct-9 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Meta-Llama-3.1-405B-Instruct | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Meta-Llama-3.1-70B-Instruct | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Meta-Llama-3.1-70B-Instruct-2 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Meta-Llama-3.1-70B-Instruct-3 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Meta-Llama-3.1-70B-Instruct-4 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Meta-Llama-3.1-8B-Instruct | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Meta-Llama-3.1-8B-Instruct-2 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Meta-Llama-3.1-8B-Instruct-3 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Meta-Llama-3.1-8B-Instruct-4 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Meta-Llama-3.1-8B-Instruct-5 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Ministral-3B | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Mistral-Large-2411-2 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Mistral-Large-3 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Mistral-Nemo | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Mistral-large | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Mistral-large-2407 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Mistral-small | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Phi-3-medium-128k-instruct-3 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Phi-3-medium-128k-instruct-4 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Phi-3-medium-128k-instruct-5 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Phi-3-medium-128k-instruct-6 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Phi-3-medium-128k-instruct-7 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Phi-3-medium-4k-instruct-3 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Phi-3-medium-4k-instruct-4 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Phi-3-medium-4k-instruct-5 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Phi-3-medium-4k-instruct-6 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Phi-3-mini-128k-instruct-10 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Phi-3-mini-128k-instruct-11 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Phi-3-mini-128k-instruct-12 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Phi-3-mini-128k-instruct-13 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Phi-3-mini-4k-instruct-10 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Phi-3-mini-4k-instruct-11 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Phi-3-mini-4k-instruct-13 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Phi-3-mini-4k-instruct-14 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Phi-3-mini-4k-instruct-15 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Phi-3-small-128k-instruct-3 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Phi-3-small-128k-instruct-4 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Phi-3-small-128k-instruct-5 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Phi-3-small-8k-instruct-3 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Phi-3-small-8k-instruct-4 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Phi-3-small-8k-instruct-5 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Phi-3.5-MoE-instruct-2 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Phi-3.5-MoE-instruct-3 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Phi-3.5-MoE-instruct-4 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Phi-3.5-MoE-instruct-5 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Phi-3.5-mini-instruct | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Phi-3.5-mini-instruct-2 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Phi-3.5-mini-instruct-3 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Phi-3.5-mini-instruct-4 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Phi-3.5-mini-instruct-6 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Phi-3.5-vision-instruct | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Phi-3.5-vision-instruct-2 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Phi-4-2 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Phi-4-3 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Phi-4-4 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Phi-4-5 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Phi-4-6 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Phi-4-7 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Phi-4-mini-instruct | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Phi-4-mini-reasoning | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Phi-4-multimodal-instruct | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Phi-4-reasoning | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Stable-Diffusion-3.5-Large | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Stable-Image-Core | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | Stable-Image-Ultra | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | ada | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | aoai-sora | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | aoai-sora-2025-02-28 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | babbage | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.40, Out: $0.40 | | claude-haiku-4-5-20251001 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | claude-opus-4-1-20250805 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | claude-opus-4-5-20251101 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | claude-opus-4-6 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | claude-opus-4-7 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | claude-sonnet-4-5-20250929 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | claude-sonnet-4-6 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | code-cushman-001 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | code-cushman-fine-tune-002 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | code-davinci-002 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | code-davinci-fine-tune-002 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | code-search-ada-code-001 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | code-search-ada-text-001 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | code-search-babbage-code-001 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | code-search-babbage-text-001 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | codex-mini-2025-05-16 | azure | In: -; Out: - | reasoning | 4096 | 16384 | In: $0.50, Out: $1.50 | | cohere-command-a | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | computer-use-preview-2025-04-15 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | curie | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | dall-e-2 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | dall-e-2-2.0 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | dall-e-3 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | dall-e-3-3.0 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | davinci | azure | In: -; Out: - | - | 4096 | 16384 | In: $2.00, Out: $2.00 | | embed-v-4-0 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | gpt-35-turbo | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | gpt-35-turbo-0125 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | gpt-35-turbo-0301 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | gpt-35-turbo-0613 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | gpt-35-turbo-1106 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | gpt-35-turbo-16k | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | gpt-35-turbo-16k-0613 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | gpt-35-turbo-instruct | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | gpt-35-turbo-instruct-0914 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | gpt-4 | azure | In: -; Out: - | function_calling, vision | 8192 | 8192 | In: $10.00, Out: $30.00 | | gpt-4-0125-Preview | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | gpt-4-0314 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | gpt-4-0613 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | gpt-4-1106-Preview | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | gpt-4-32k | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | gpt-4-32k-0314 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | gpt-4-32k-0613 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | gpt-4-turbo-2024-04-09 | azure | In: -; Out: - | function_calling, vision | 128000 | 16384 | In: $10.00, Out: $30.00 | | gpt-4-turbo-jp | azure | In: -; Out: - | function_calling, vision | 128000 | 16384 | In: $10.00, Out: $30.00 | | gpt-4-vision-preview | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | gpt-4.1 | azure | In: -; Out: - | function_calling, structured_output, vision | 1047576 | 32768 | In: $2.00, Out: $8.00, Cache Read: $0.50 | | gpt-4.1-2025-04-14 | azure | In: -; Out: - | function_calling, structured_output, vision | 1047576 | 32768 | In: $2.00, Out: $8.00, Cache Read: $0.50 | | gpt-4.1-2025-04-14-text | azure | In: -; Out: - | function_calling, structured_output, vision | 1047576 | 32768 | In: $2.00, Out: $8.00, Cache Read: $0.50 | | gpt-4.1-mini | azure | In: -; Out: - | function_calling, structured_output, vision | 1047576 | 32768 | In: $0.40, Out: $1.60, Cache Read: $0.10 | | gpt-4.1-mini-2025-04-14 | azure | In: -; Out: - | function_calling, structured_output, vision | 1047576 | 32768 | In: $0.40, Out: $1.60, Cache Read: $0.10 | | gpt-4.1-nano | azure | In: -; Out: - | function_calling, structured_output, vision | 1047576 | 32768 | In: $0.10, Out: $0.40 | | gpt-4.1-nano-2025-04-14 | azure | In: -; Out: - | function_calling, structured_output, vision | 1047576 | 32768 | In: $0.10, Out: $0.40 | | gpt-4o | azure | In: -; Out: - | function_calling, structured_output, vision | 128000 | 16384 | In: $2.50, Out: $10.00 | | gpt-4o-2024-05-13 | azure | In: -; Out: - | function_calling, structured_output, vision | 128000 | 16384 | In: $2.50, Out: $10.00 | | gpt-4o-2024-08-06 | azure | In: -; Out: - | function_calling, structured_output, vision | 128000 | 16384 | In: $2.50, Out: $10.00 | | gpt-4o-2024-11-20 | azure | In: -; Out: - | function_calling, structured_output, vision | 128000 | 16384 | In: $2.50, Out: $10.00 | | gpt-4o-audio-mai | azure | In: -; Out: - | - | 128000 | 16384 | In: $2.50, Out: $10.00 | | gpt-4o-audio-preview-2024-10-01 | azure | In: -; Out: - | - | 128000 | 16384 | In: $2.50, Out: $10.00 | | gpt-4o-audio-preview-2024-12-17 | azure | In: -; Out: - | - | 128000 | 16384 | In: $2.50, Out: $10.00 | | gpt-4o-audio-preview-2025-06-03 | azure | In: -; Out: - | - | 128000 | 16384 | In: $2.50, Out: $10.00 | | gpt-4o-canvas-2024-09-25 | azure | In: -; Out: - | function_calling, structured_output, vision | 128000 | 16384 | In: $2.50, Out: $10.00 | | gpt-4o-mini | azure | In: -; Out: - | function_calling, structured_output, vision | 128000 | 16384 | In: $0.15, Out: $0.60 | | gpt-4o-mini-2024-07-18 | azure | In: -; Out: - | function_calling, structured_output, vision | 128000 | 16384 | In: $0.15, Out: $0.60 | | gpt-4o-mini-audio-preview-2024-12-17 | azure | In: -; Out: - | - | 128000 | 16384 | In: $0.15, Out: $0.60 | | gpt-4o-mini-realtime-preview-2024-12-17 | azure | In: -; Out: - | - | 128000 | 16384 | In: $0.60, Out: $2.40 | | gpt-4o-mini-transcribe | azure | In: -; Out: - | - | 16000 | 2000 | In: $1.25, Out: $5.00 | | gpt-4o-mini-transcribe-2025-03-20 | azure | In: -; Out: - | - | 16000 | 2000 | In: $1.25, Out: $5.00 | | gpt-4o-mini-transcribe-2025-12-15 | azure | In: -; Out: - | - | 16000 | 2000 | In: $1.25, Out: $5.00 | | gpt-4o-mini-tts | azure | In: -; Out: - | - | - | - | In: $0.60, Out: $12.00 | | gpt-4o-mini-tts-2025-03-20 | azure | In: -; Out: - | - | - | - | In: $0.60, Out: $12.00 | | gpt-4o-mini-tts-2025-12-15 | azure | In: -; Out: - | - | - | - | In: $0.60, Out: $12.00 | | gpt-4o-realtime-preview | azure | In: -; Out: - | - | 128000 | 16384 | In: $5.00, Out: $20.00 | | gpt-4o-realtime-preview-2024-12-17 | azure | In: -; Out: - | - | 128000 | 16384 | In: $5.00, Out: $20.00 | | gpt-4o-realtime-preview-2025-06-03 | azure | In: -; Out: - | - | 128000 | 16384 | In: $5.00, Out: $20.00 | | gpt-4o-transcribe | azure | In: -; Out: - | - | 128000 | 16384 | In: $2.50, Out: $10.00 | | gpt-4o-transcribe-2025-03-20 | azure | In: -; Out: - | - | 128000 | 16384 | In: $2.50, Out: $10.00 | | gpt-4o-transcribe-diarize | azure | In: -; Out: - | - | 128000 | 16384 | In: $2.50, Out: $10.00 | | gpt-4o-transcribe-diarize-2025-10-15 | azure | In: -; Out: - | - | 128000 | 16384 | In: $2.50, Out: $10.00 | | gpt-5-2025-08-07 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5-chat-2025-08-07 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5-chat-2025-08-15 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5-chat-2025-10-03 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5-codex-2025-09-15 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5-mini-2025-08-07 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $0.25, Out: $2.00, Cache Read: $0.02 | | gpt-5-mini-2025-08-07-lite | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $0.25, Out: $2.00, Cache Read: $0.02 | | gpt-5-mini-lite-2025-08-07 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $0.25, Out: $2.00, Cache Read: $0.02 | | gpt-5-nano-2025-08-07 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $0.05, Out: $0.40, Cache Read: $0.01 | | gpt-5-pro-2025-10-06 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.1 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.1-2025-11-13 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.1-chat-2025-11-13 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.1-codex-2025-11-13 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.1-codex-max-2025-12-04 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.1-codex-mini-2025-11-13 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $0.25, Out: $2.00, Cache Read: $0.02 | | gpt-5.2-2025-12-11 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.2-chat-2025-12-11 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.2-chat-2026-02-10 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.2-codex-2026-01-14 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.3-chat-2026-03-03 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.3-codex-2026-02-20 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.3-codex-2026-02-24 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.4-2026-03-05 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.4-mini-2026-03-17 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $0.25, Out: $2.00, Cache Read: $0.02 | | gpt-5.4-nano-2026-03-17 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $0.05, Out: $0.40, Cache Read: $0.01 | | gpt-5.4-pro-2026-03-05 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.5-2026-04-24 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-audio-1.5-2026-02-23 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | gpt-audio-2025-08-28 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | gpt-audio-mini-2025-10-06 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | gpt-chat-latest-2026-05-05 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | gpt-chat-latest-2026-05-28 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | gpt-image-1 | azure | In: -; Out: - | vision | - | - | In: $5.00, Cache Read: $1.25 | | gpt-image-1-2025-04-15 | azure | In: -; Out: - | vision | - | - | In: $5.00, Cache Read: $1.25 | | gpt-image-1-mini | azure | In: -; Out: - | vision | - | - | In: $2.00, Cache Read: $0.20 | | gpt-image-1-mini-2025-10-06 | azure | In: -; Out: - | vision | - | - | In: $2.00, Cache Read: $0.20 | | gpt-image-1.5 | azure | In: -; Out: - | vision | - | - | In: $5.00, Cache Read: $1.25 | | gpt-image-1.5-2025-12-16 | azure | In: -; Out: - | vision | - | - | In: $5.00, Cache Read: $1.25 | | gpt-oss-120b | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | gpt-oss-20b-11 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | gpt-realtime-1.5-2026-02-23 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | gpt-realtime-2025-08-28 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | gpt-realtime-mini | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | gpt-realtime-mini-2025-10-06 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | gpt-realtime-mini-2025-12-15 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | gpt-realtime-whisper-2026-05-06 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | grok-3 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | grok-3-mini | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | grok-4-1-fast-non-reasoning | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | grok-4-1-fast-reasoning | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | grok-4-20-non-reasoning | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | grok-4-20-reasoning | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | grok-4-fast-non-reasoning | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | grok-4-fast-reasoning | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | grok-4.3 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | jais-30b-chat | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | jais-30b-chat-2 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | jais-30b-chat-3 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | mistral-document-ai-2505 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | mistral-document-ai-2512 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | mistral-medium-2505 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | mistral-small-2503 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | model-router | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | model-router-2025-05-19 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | model-router-2025-08-07 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | model-router-2025-11-18 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | o1-2024-12-17 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 200000 | 100000 | In: $15.00, Out: $60.00 | | o1-mini-2024-09-12 | azure | In: -; Out: - | reasoning | 128000 | 65536 | In: $1.10, Out: $4.40 | | o1-pro | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 200000 | 100000 | In: $150.00, Out: $600.00 | | o1-pro-2025-03-19 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 200000 | 100000 | In: $150.00, Out: $600.00 | | o3-deep-research-2025-06-26 | azure | In: -; Out: - | reasoning | 4096 | 16384 | In: $0.50, Out: $1.50 | | o3-deep-research-2025-06-26-ev3 | azure | In: -; Out: - | reasoning | 4096 | 16384 | In: $0.50, Out: $1.50 | | o3-mini | azure | In: -; Out: - | function_calling, structured_output, reasoning | 200000 | 100000 | In: $1.10, Out: $4.40 | | o3-mini-2025-01-31 | azure | In: -; Out: - | function_calling, structured_output, reasoning | 200000 | 100000 | In: $1.10, Out: $4.40 | | o3-mini-alpha | azure | In: -; Out: - | function_calling, structured_output, reasoning | 200000 | 100000 | In: $1.10, Out: $4.40 | | o3-mini-alpha-2024-12-17 | azure | In: -; Out: - | function_calling, structured_output, reasoning | 200000 | 100000 | In: $1.10, Out: $4.40 | | o4-mini | azure | In: -; Out: - | reasoning | 4096 | 16384 | In: $0.50, Out: $1.50 | | o4-mini-2025-04-16 | azure | In: -; Out: - | reasoning | 4096 | 16384 | In: $0.50, Out: $1.50 | | qwen-3-32b | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | qwen3-32b | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | sora | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | sora-2 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | sora-2-2025-10-06 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | sora-2-2025-12-08 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | sora-2025-05-02 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | text-ada-001 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | text-babbage-001 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | text-curie-001 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | text-davinci-001 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | text-davinci-002 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | text-davinci-003 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | text-davinci-fine-tune-002 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | text-embedding-3-large | azure | In: -; Out: - | - | - | - | In: $0.13, Out: $0.13 | | text-embedding-3-small | azure | In: -; Out: - | - | - | - | In: $0.02, Out: $0.02 | | text-embedding-ada-002 | azure | In: -; Out: - | - | - | - | In: $0.10, Out: $0.10 | | text-embedding-ada-002-2 | azure | In: -; Out: - | - | - | - | In: $0.10, Out: $0.10 | | text-search-ada-doc-001 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | text-search-ada-query-001 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | text-search-babbage-doc-001 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | text-search-babbage-query-001 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | text-search-curie-doc-001 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | text-search-curie-query-001 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | text-search-davinci-doc-001 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | text-search-davinci-query-001 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | text-similarity-ada-001 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | text-similarity-babbage-001 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | text-similarity-curie-001 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | text-similarity-davinci-001 | azure | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | whisper | azure | In: -; Out: - | - | - | - | In: $0.01, Out: $0.01 | | whisper-001 | azure | In: -; Out: - | - | - | - | In: $0.01, Out: $0.01 | ### Bedrock (176) | Model | Provider | I/O | Capabilities | Context | Max Output | Standard Pricing (per 1M tokens) | | :-- | :-- | :-- | :-- | --: | --: | :-- | | au.anthropic.claude-opus-4-6-v1 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 128000 | In: $16.50, Out: $82.50, Cache Read: $1.65, Cache Write: $20.62 | | au.anthropic.claude-sonnet-4-6 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 128000 | In: $3.30, Out: $16.50, Cache Read: $0.33, Cache Write: $4.12 | | anthropic.claude-3-haiku-20240307-v1:0 | bedrock | In: text, image; Out: text | streaming, function_calling | - | - | - | | anthropic.claude-3-haiku-20240307-v1:0:200k | bedrock | In: text, image; Out: text | streaming, function_calling | - | - | - | | anthropic.claude-3-haiku-20240307-v1:0:48k | bedrock | In: text, image; Out: text | streaming, function_calling | - | - | - | | anthropic.claude-fable-5 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $10.00, Out: $50.00, Cache Read: $1.00, Cache Write: $12.50 | | eu.anthropic.claude-fable-5 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $11.00, Out: $55.00, Cache Read: $1.10, Cache Write: $13.75 | | global.anthropic.claude-fable-5 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $10.00, Out: $50.00, Cache Read: $1.00, Cache Write: $12.50 | | us.anthropic.claude-fable-5 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 1000000 | 128000 | In: $10.00, Out: $50.00, Cache Read: $1.00, Cache Write: $12.50 | | anthropic.claude-haiku-4-5-20251001-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $1.00, Out: $5.00, Cache Read: $0.10, Cache Write: $1.25 | | au.anthropic.claude-haiku-4-5-20251001-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $1.00, Out: $5.00, Cache Read: $0.10, Cache Write: $1.25 | | eu.anthropic.claude-haiku-4-5-20251001-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $1.10, Out: $5.50, Cache Read: $0.11, Cache Write: $1.38 | | global.anthropic.claude-haiku-4-5-20251001-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $1.00, Out: $5.00, Cache Read: $0.10, Cache Write: $1.25 | | jp.anthropic.claude-haiku-4-5-20251001-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $1.00, Out: $5.00, Cache Read: $0.10, Cache Write: $1.25 | | us.anthropic.claude-haiku-4-5-20251001-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 64000 | In: $1.00, Out: $5.00, Cache Read: $0.10, Cache Write: $1.25 | | anthropic.claude-opus-4-1-20250805-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 200000 | 32000 | In: $15.00, Out: $75.00, Cache Read: $1.50, Cache Write: $18.75 | | us.anthropic.claude-opus-4-1-20250805-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 200000 | 32000 | In: $15.00, Out: $75.00, Cache Read: $1.50, Cache Write: $18.75 | | anthropic.claude-opus-4-5-20251101-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | eu.anthropic.claude-opus-4-5-20251101-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $5.50, Out: $27.50, Cache Read: $0.55, Cache Write: $6.88 | | global.anthropic.claude-opus-4-5-20251101-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | us.anthropic.claude-opus-4-5-20251101-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 64000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | anthropic.claude-opus-4-6-v1 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | eu.anthropic.claude-opus-4-6-v1 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 128000 | In: $5.50, Out: $27.50, Cache Read: $0.55, Cache Write: $6.88 | | global.anthropic.claude-opus-4-6-v1 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | us.anthropic.claude-opus-4-6-v1 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | anthropic.claude-opus-4-7 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | eu.anthropic.claude-opus-4-7 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $5.50, Out: $27.50, Cache Read: $0.55, Cache Write: $6.88 | | global.anthropic.claude-opus-4-7 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | jp.anthropic.claude-opus-4-7 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | us.anthropic.claude-opus-4-7 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | anthropic.claude-opus-4-8 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | au.anthropic.claude-opus-4-8 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | eu.anthropic.claude-opus-4-8 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $5.50, Out: $27.50, Cache Read: $0.55, Cache Write: $6.88 | | global.anthropic.claude-opus-4-8 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | jp.anthropic.claude-opus-4-8 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | us.anthropic.claude-opus-4-8 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | anthropic.claude-opus-5 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | au.anthropic.claude-opus-5 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | eu.anthropic.claude-opus-5 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $5.50, Out: $27.50, Cache Read: $0.55, Cache Write: $6.88 | | global.anthropic.claude-opus-5 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | jp.anthropic.claude-opus-5 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | us.anthropic.claude-opus-5 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | us.anthropic.claude-sonnet-4-20250514-v1:0 | bedrock | In: text, image; Out: text | streaming, function_calling, reasoning | 200000 | 8192 | - | | anthropic.claude-sonnet-4-5-20250929-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | au.anthropic.claude-sonnet-4-5-20250929-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | eu.anthropic.claude-sonnet-4-5-20250929-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $3.30, Out: $16.50, Cache Read: $0.33, Cache Write: $4.12 | | global.anthropic.claude-sonnet-4-5-20250929-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | jp.anthropic.claude-sonnet-4-5-20250929-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | us.anthropic.claude-sonnet-4-5-20250929-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | anthropic.claude-sonnet-4-6 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | eu.anthropic.claude-sonnet-4-6 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 64000 | In: $3.30, Out: $16.50, Cache Read: $0.33, Cache Write: $4.12 | | global.anthropic.claude-sonnet-4-6 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | jp.anthropic.claude-sonnet-4-6 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | us.anthropic.claude-sonnet-4-6 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | anthropic.claude-sonnet-5 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 128000 | In: $2.00, Out: $10.00, Cache Read: $0.20, Cache Write: $2.50 | | au.anthropic.claude-sonnet-5 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 128000 | In: $2.00, Out: $10.00, Cache Read: $0.20, Cache Write: $2.50 | | eu.anthropic.claude-sonnet-5 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 128000 | In: $2.20, Out: $11.00, Cache Read: $0.22, Cache Write: $2.75 | | global.anthropic.claude-sonnet-5 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 128000 | In: $2.00, Out: $10.00, Cache Read: $0.20, Cache Write: $2.50 | | jp.anthropic.claude-sonnet-5 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 128000 | In: $2.00, Out: $10.00, Cache Read: $0.20, Cache Write: $2.50 | | us.anthropic.claude-sonnet-5 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $2.00, Out: $10.00, Cache Read: $0.20, Cache Write: $2.50 | | cohere.command-r-v1:0 | bedrock | In: text; Out: text | streaming, function_calling | - | - | - | | cohere.command-r-plus-v1:0 | bedrock | In: text; Out: text | streaming, function_calling | - | - | - | | deepseek.r1-v1:0 | bedrock | In: text; Out: text | function_calling, reasoning | 128000 | 32768 | In: $1.35, Out: $5.40 | | us.deepseek.r1-v1:0 | bedrock | In: text; Out: text | function_calling, reasoning, streaming | 128000 | 32768 | In: $1.35, Out: $5.40 | | deepseek.v3-v1:0 | bedrock | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 163840 | 81920 | In: $0.58, Out: $1.68 | | deepseek.v3.2 | bedrock | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 163840 | 81920 | In: $0.62, Out: $1.85 | | mistral.devstral-2-123b | bedrock | In: text; Out: text | function_calling, structured_output, streaming | 256000 | 8192 | In: $0.40, Out: $2.00 | | cohere.embed-english-v3 | bedrock | In: text; Out: embeddings | function_calling | - | - | - | | cohere.embed-english-v3:0:512 | bedrock | In: text; Out: embeddings | function_calling | - | - | - | | cohere.embed-multilingual-v3 | bedrock | In: text; Out: embeddings | function_calling | - | - | - | | cohere.embed-multilingual-v3:0:512 | bedrock | In: text; Out: embeddings | function_calling | - | - | - | | us.cohere.embed-v4:0 | bedrock | In: text, image; Out: embeddings | function_calling | 128000 | - | - | | zai.glm-4.7 | bedrock | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 204800 | 131072 | In: $0.60, Out: $2.20 | | zai.glm-4.7-flash | bedrock | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 200000 | 131072 | In: $0.07, Out: $0.40 | | zai.glm-5 | bedrock | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 202752 | 101376 | In: $1.00, Out: $3.20 | | openai.gpt-oss-safeguard-120b | bedrock | In: text; Out: text | function_calling, structured_output, streaming | 128000 | 16384 | In: $0.15, Out: $0.60 | | openai.gpt-oss-safeguard-20b | bedrock | In: text; Out: text | function_calling, structured_output, streaming | 128000 | 16384 | In: $0.07, Out: $0.20 | | openai.gpt-5.4 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 272000 | 128000 | In: $2.75, Out: $16.50, Cache Read: $0.28 | | openai.gpt-5.5 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 272000 | 128000 | In: $5.50, Out: $33.00, Cache Read: $0.55 | | openai.gpt-5.6-luna | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 272000 | 128000 | In: $0.22, Out: $1.32, Cache Read: $0.02, Cache Write: $0.28 | | openai.gpt-5.6-sol | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 272000 | 128000 | In: $5.50, Out: $33.00, Cache Read: $0.55, Cache Write: $6.88 | | openai.gpt-5.6-terra | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 272000 | 128000 | In: $2.20, Out: $13.20, Cache Read: $0.22, Cache Write: $2.75 | | google.gemma-3-4b-it | bedrock | In: text, image; Out: text | function_calling, vision, streaming | 128000 | 4096 | In: $0.04, Out: $0.08 | | google.gemma-3-12b-it | bedrock | In: text, image; Out: text | structured_output, vision, streaming | 131072 | 8192 | In: $0.05, Out: $0.10 | | google.gemma-3-27b-it | bedrock | In: text, image; Out: text | function_calling, structured_output, vision, streaming | 202752 | 8192 | In: $0.12, Out: $0.20 | | xai.grok-4.3 | bedrock | In: text, image; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 131072 | In: $1.25, Out: $2.50, Cache Read: $0.20 | | moonshot.kimi-k2-thinking | bedrock | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 262143 | 16000 | In: $0.60, Out: $2.50 | | moonshotai.kimi-k2.5 | bedrock | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 262143 | 16000 | In: $0.60, Out: $3.00 | | meta.llama3-70b-instruct-v1:0 | bedrock | In: text; Out: text | streaming, function_calling | - | - | - | | meta.llama3-8b-instruct-v1:0 | bedrock | In: text; Out: text | streaming, function_calling | - | - | - | | meta.llama3-1-70b-instruct-v1:0 | bedrock | In: text; Out: text | function_calling, streaming | 128000 | 4096 | In: $0.72, Out: $0.72 | | meta.llama3-1-70b-instruct-v1:0:128k | bedrock | In: text; Out: text | function_calling, streaming | 128000 | 4096 | In: $0.72, Out: $0.72 | | meta.llama3-1-8b-instruct-v1:0 | bedrock | In: text; Out: text | function_calling, streaming | 128000 | 4096 | In: $0.22, Out: $0.22 | | meta.llama3-1-8b-instruct-v1:0:128k | bedrock | In: text; Out: text | function_calling, streaming | 128000 | 4096 | In: $0.22, Out: $0.22 | | meta.llama3-3-70b-instruct-v1:0 | bedrock | In: text; Out: text | function_calling | 128000 | 4096 | In: $0.72, Out: $0.72 | | meta.llama3-3-70b-instruct-v1:0:128k | bedrock | In: text; Out: text | function_calling, streaming | 128000 | 4096 | In: $0.72, Out: $0.72 | | us.meta.llama3-3-70b-instruct-v1:0 | bedrock | In: text; Out: text | function_calling, streaming | 128000 | 4096 | In: $0.72, Out: $0.72 | | meta.llama4-maverick-17b-instruct-v1:0 | bedrock | In: text, image; Out: text | function_calling, vision | 1000000 | 16384 | In: $0.24, Out: $0.97 | | us.meta.llama4-maverick-17b-instruct-v1:0 | bedrock | In: text, image; Out: text | function_calling, vision, streaming | 1000000 | 16384 | In: $0.24, Out: $0.97 | | meta.llama4-scout-17b-instruct-v1:0 | bedrock | In: text, image; Out: text | function_calling, vision | 3500000 | 16384 | In: $0.17, Out: $0.66 | | us.meta.llama4-scout-17b-instruct-v1:0 | bedrock | In: text, image; Out: text | function_calling, vision, streaming | 3500000 | 16384 | In: $0.17, Out: $0.66 | | mistral.magistral-small-2509 | bedrock | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 128000 | 40000 | In: $0.50, Out: $1.50 | | minimax.minimax-m2 | bedrock | In: text; Out: text | function_calling, reasoning, streaming | 204608 | 128000 | In: $0.30, Out: $1.20 | | minimax.minimax-m2.1 | bedrock | In: text; Out: text | function_calling, reasoning, streaming | 204800 | 131072 | In: $0.30, Out: $1.20 | | minimax.minimax-m2.5 | bedrock | In: text; Out: text | function_calling, reasoning, streaming | 196608 | 98304 | In: $0.30, Out: $1.20 | | mistral.ministral-3-14b-instruct | bedrock | In: text; Out: text | function_calling, structured_output, streaming | 128000 | 4096 | In: $0.20, Out: $0.20 | | mistral.ministral-3-3b-instruct | bedrock | In: text, image; Out: text | function_calling, structured_output, vision, streaming | 256000 | 8192 | In: $0.10, Out: $0.10 | | mistral.ministral-3-8b-instruct | bedrock | In: text; Out: text | function_calling, structured_output, streaming | 128000 | 4096 | In: $0.15, Out: $0.15 | | mistral.mistral-7b-instruct-v0:2 | bedrock | In: text; Out: text | streaming, function_calling | - | - | - | | mistral.mistral-large-2402-v1:0 | bedrock | In: text; Out: text | streaming, function_calling | - | - | - | | mistral.mistral-large-2407-v1:0 | bedrock | In: text; Out: text | streaming, function_calling | - | - | - | | mistral.mistral-large-3-675b-instruct | bedrock | In: text, image; Out: text | function_calling, structured_output, vision, streaming | 256000 | 8192 | In: $0.50, Out: $1.50 | | mistral.mixtral-8x7b-instruct-v0:1 | bedrock | In: text; Out: text | streaming, function_calling | - | - | - | | nvidia.nemotron-super-3-120b | bedrock | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 262144 | 131072 | In: $0.15, Out: $0.65 | | nvidia.nemotron-nano-12b-v2 | bedrock | In: text, image; Out: text | function_calling, structured_output, vision, streaming | 128000 | 4096 | In: $0.20, Out: $0.60 | | nvidia.nemotron-nano-3-30b | bedrock | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 128000 | 4096 | In: $0.06, Out: $0.24 | | nvidia.nemotron-nano-9b-v2 | bedrock | In: text; Out: text | function_calling, structured_output, streaming | 128000 | 4096 | In: $0.06, Out: $0.23 | | amazon.nova-2-lite-v1:0 | bedrock | In: text, image, video; Out: text | function_calling, reasoning, vision, video | 128000 | 4096 | In: $0.33, Out: $2.75 | | us.amazon.nova-2-lite-v1:0 | bedrock | In: text, image, video; Out: text | function_calling, reasoning, vision, video, streaming | 128000 | 4096 | In: $0.33, Out: $2.75 | | amazon.nova-2-sonic-v1:0 | bedrock | In: audio; Out: audio, text | streaming, function_calling | - | - | - | | amazon.nova-lite-v1:0 | bedrock | In: text, image, video; Out: text | function_calling, vision, video, streaming | 300000 | 8192 | In: $0.06, Out: $0.24, Cache Read: $0.02 | | amazon.nova-micro-v1:0 | bedrock | In: text; Out: text | function_calling | 128000 | 8192 | In: $0.04, Out: $0.14, Cache Read: $0.01 | | us.amazon.nova-micro-v1:0 | bedrock | In: text; Out: text | function_calling, streaming | 128000 | 8192 | In: $0.04, Out: $0.14, Cache Read: $0.01 | | amazon.nova-premier-v1:0:1000k | bedrock | In: text, image, video; Out: text | streaming, function_calling | - | - | - | | amazon.nova-premier-v1:0:20k | bedrock | In: text, image, video; Out: text | streaming, function_calling | - | - | - | | amazon.nova-premier-v1:0:8k | bedrock | In: text, image, video; Out: text | streaming, function_calling | - | - | - | | amazon.nova-premier-v1:0:mm | bedrock | In: text, image, video; Out: text | streaming, function_calling | - | - | - | | us.amazon.nova-premier-v1:0 | bedrock | In: text, image, video; Out: text | streaming, function_calling | - | - | - | | amazon.nova-pro-v1:0 | bedrock | In: text, image, video; Out: text | function_calling, vision, video | 300000 | 8192 | In: $0.80, Out: $3.20, Cache Read: $0.20 | | us.amazon.nova-pro-v1:0 | bedrock | In: text, image, video; Out: text | function_calling, vision, video, streaming | 300000 | 8192 | In: $0.80, Out: $3.20, Cache Read: $0.20 | | us.writer.palmyra-x4-v1:0 | bedrock | In: text; Out: text | function_calling, reasoning, streaming | 122880 | 8192 | In: $2.50, Out: $10.00 | | writer.palmyra-x4-v1:0 | bedrock | In: text; Out: text | function_calling, reasoning | 122880 | 8192 | In: $2.50, Out: $10.00 | | us.writer.palmyra-x5-v1:0 | bedrock | In: text; Out: text | function_calling, reasoning, streaming | 1040000 | 8192 | In: $0.60, Out: $6.00 | | writer.palmyra-x5-v1:0 | bedrock | In: text; Out: text | function_calling, reasoning | 1040000 | 8192 | In: $0.60, Out: $6.00 | | us.twelvelabs.pegasus-1-2-v1:0 | bedrock | In: text, video; Out: text | streaming, function_calling | - | - | - | | mistral.pixtral-large-2502-v1:0 | bedrock | In: text, image; Out: text | function_calling, vision | 128000 | 8192 | In: $2.00, Out: $6.00 | | us.mistral.pixtral-large-2502-v1:0 | bedrock | In: text, image; Out: text | function_calling, vision, streaming | 128000 | 8192 | In: $2.00, Out: $6.00 | | qwen.qwen3-next-80b-a3b | bedrock | In: text; Out: text | function_calling, structured_output, streaming | 262000 | 262000 | In: $0.14, Out: $1.40 | | qwen.qwen3-vl-235b-a22b | bedrock | In: text, image; Out: text | function_calling, structured_output, vision, streaming | 262000 | 262000 | In: $0.30, Out: $1.50 | | qwen.qwen3-235b-a22b-2507-v1:0 | bedrock | In: text; Out: text | function_calling, structured_output, streaming | 262144 | 131072 | In: $0.22, Out: $0.88 | | qwen.qwen3-32b-v1:0 | bedrock | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 16384 | 16384 | In: $0.15, Out: $0.60 | | qwen.qwen3-coder-30b-a3b-v1:0 | bedrock | In: text; Out: text | function_calling, structured_output, streaming | 262144 | 131072 | In: $0.15, Out: $0.60 | | qwen.qwen3-coder-480b-a35b-v1:0 | bedrock | In: text; Out: text | function_calling, structured_output, streaming | 131072 | 65536 | In: $0.22, Out: $1.80 | | qwen.qwen3-coder-next | bedrock | In: text; Out: text | function_calling, structured_output, reasoning | 131072 | 65536 | In: $0.22, Out: $1.80 | | luma.ray-v2:0 | bedrock | In: text; Out: video | function_calling | - | - | - | | amazon.rerank-v1:0 | bedrock | In: text; Out: text | function_calling | - | - | - | | cohere.rerank-v3-5:0 | bedrock | In: text; Out: text | function_calling | - | - | - | | stability.sd3-5-large-v1:0 | bedrock | In: text, image; Out: image | function_calling | - | - | - | | us.stability.stable-conservative-upscale-v1:0 | bedrock | In: text, image; Out: image | function_calling | - | - | - | | us.stability.stable-image-control-sketch-v1:0 | bedrock | In: text, image; Out: image | function_calling | - | - | - | | us.stability.stable-image-control-structure-v1:0 | bedrock | In: text, image; Out: image | function_calling | - | - | - | | stability.stable-image-core-v1:1 | bedrock | In: text; Out: image | function_calling | - | - | - | | us.stability.stable-creative-upscale-v1:0 | bedrock | In: text, image; Out: image | function_calling | - | - | - | | us.stability.stable-image-erase-object-v1:0 | bedrock | In: text, image; Out: image | function_calling | - | - | - | | us.stability.stable-fast-upscale-v1:0 | bedrock | In: text, image; Out: image | function_calling | - | - | - | | us.stability.stable-image-inpaint-v1:0 | bedrock | In: text, image; Out: image | function_calling | - | - | - | | us.stability.stable-outpaint-v1:0 | bedrock | In: text, image; Out: image | function_calling | - | - | - | | us.stability.stable-image-remove-background-v1:0 | bedrock | In: text, image; Out: image | function_calling | - | - | - | | us.stability.stable-image-search-recolor-v1:0 | bedrock | In: text, image; Out: image | function_calling | - | - | - | | us.stability.stable-image-search-replace-v1:0 | bedrock | In: text, image; Out: image | function_calling | - | - | - | | us.stability.stable-image-style-guide-v1:0 | bedrock | In: text, image; Out: image | function_calling | - | - | - | | us.stability.stable-style-transfer-v1:0 | bedrock | In: text, image; Out: image | function_calling | - | - | - | | stability.stable-image-ultra-v1:1 | bedrock | In: text; Out: image | function_calling | - | - | - | | amazon.titan-embed-text-v1 | bedrock | In: text; Out: embeddings | function_calling | - | - | - | | amazon.titan-embed-text-v1:2:8k | bedrock | In: text; Out: embeddings | function_calling | - | - | - | | amazon.titan-embed-image-v1 | bedrock | In: text, image; Out: embeddings | function_calling | - | - | - | | amazon.titan-embed-image-v1:0 | bedrock | In: text, image; Out: embeddings | function_calling | - | - | - | | amazon.titan-embed-text-v2:0 | bedrock | In: text; Out: embeddings | function_calling | - | - | - | | amazon.titan-embed-g1-text-02 | bedrock | In: text; Out: embeddings | function_calling | - | - | - | | mistral.voxtral-mini-3b-2507 | bedrock | In: audio, text; Out: text | function_calling, structured_output, streaming | 128000 | 4096 | In: $0.04, Out: $0.04 | | mistral.voxtral-small-24b-2507 | bedrock | In: text, audio; Out: text | function_calling, structured_output, streaming | 32000 | 8192 | In: $0.15, Out: $0.35 | | writer.palmyra-vision-7b | bedrock | In: text, image; Out: text | streaming, function_calling | - | 4096 | - | | openai.gpt-oss-120b | bedrock | In: text; Out: text | function_calling, structured_output, reasoning | 128000 | 16384 | In: $0.15, Out: $0.60 | | openai.gpt-oss-120b-1:0 | bedrock | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 128000 | 16384 | In: $0.15, Out: $0.60 | | openai.gpt-oss-20b | bedrock | In: text; Out: text | function_calling, structured_output, reasoning | 128000 | 16384 | In: $0.07, Out: $0.30 | | openai.gpt-oss-20b-1:0 | bedrock | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 128000 | 16384 | In: $0.07, Out: $0.30 | ### DeepSeek (4) | Model | Provider | I/O | Capabilities | Context | Max Output | Standard Pricing (per 1M tokens) | | :-- | :-- | :-- | :-- | --: | --: | :-- | | deepseek-chat | deepseek | In: text; Out: text | function_calling | 1000000 | 384000 | In: $0.14, Out: $0.28, Cache Read: $0.00 | | deepseek-reasoner | deepseek | In: text; Out: text | function_calling, reasoning | 1000000 | 384000 | In: $0.14, Out: $0.28, Cache Read: $0.00 | | deepseek-v4-flash | deepseek | In: text; Out: text | function_calling, structured_output, reasoning, tool_choice | 1000000 | 384000 | In: $0.14, Out: $0.28, Cache Read: $0.00 | | deepseek-v4-pro | deepseek | In: text; Out: text | function_calling, structured_output, reasoning, tool_choice | 1000000 | 384000 | In: $0.44, Out: $0.87, Cache Read: $0.00 | ### Gemini (54) | Model | Provider | I/O | Capabilities | Context | Max Output | Standard Pricing (per 1M tokens) | | :-- | :-- | :-- | :-- | --: | --: | :-- | | antigravity-preview-05-2026 | gemini | In: -; Out: - | - | 131072 | 65536 | In: $0.08, Out: $0.30 | | deep-research-max-preview-04-2026 | gemini | In: text, image, video, audio, pdf; Out: text, image | function_calling, reasoning, vision, video | 131072 | 65536 | In: $2.00, Out: $12.00, Cache Read: $0.20 | | deep-research-preview-04-2026 | gemini | In: text, image, video, audio, pdf; Out: text, image | function_calling, reasoning, vision, video | 131072 | 65536 | In: $2.00, Out: $12.00, Cache Read: $0.20 | | deep-research-pro-preview-12-2025 | gemini | In: -; Out: - | function_calling, tool_choice, structured_output, vision | 131072 | 65536 | In: $0.08, Out: $0.30 | | gemini-2.0-flash | gemini | In: text, image, audio, video, pdf; Out: text | function_calling, structured_output, vision, video, tool_choice | 1048576 | 8192 | In: $0.10, Out: $0.40, Cache Read: $0.02 | | gemini-2.0-flash-001 | gemini | In: -; Out: - | function_calling, tool_choice, structured_output, vision | 1048576 | 8192 | In: $0.10, Out: $0.40 | | gemini-2.0-flash-lite | gemini | In: text, image, audio, video, pdf; Out: text | function_calling, structured_output, vision, video | 1048576 | 8192 | In: $0.08, Out: $0.30 | | gemini-2.0-flash-lite-001 | gemini | In: -; Out: - | vision | 1048576 | 8192 | In: $0.08, Out: $0.30 | | gemini-2.5-computer-use-preview-10-2025 | gemini | In: text, image; Out: text | function_calling, reasoning, vision, tool_choice | 131072 | 65536 | In: $1.25, Out: $10.00 | | gemini-2.5-flash | gemini | In: text, image, audio, video, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, tool_choice | 1048576 | 65536 | In: $0.30, Out: $2.50, Cache Read: $0.03 | | gemini-2.5-flash-preview-tts | gemini | In: text; Out: audio | tool_choice | 8192 | 16384 | In: $0.50, Out: $10.00 | | gemini-2.5-flash-lite | gemini | In: text, image, audio, video, pdf; Out: text | function_calling, structured_output, reasoning, vision, video | 1048576 | 65536 | In: $0.10, Out: $0.40, Cache Read: $0.01 | | gemini-2.5-pro | gemini | In: text, image, audio, video, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, tool_choice | 1048576 | 65536 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gemini-2.5-pro-preview-tts | gemini | In: text; Out: audio | tool_choice | 8192 | 16384 | In: $1.00, Out: $20.00 | | gemini-3-flash-preview | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, tool_choice | 1048576 | 65536 | In: $0.50, Out: $3.00, Cache Read: $0.05 | | gemini-3-pro-preview | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, tool_choice | 1048576 | 65536 | In: $2.00, Out: $12.00, Cache Read: $0.20 | | gemini-3.1-flash-lite | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video | 1048576 | 65536 | In: $0.25, Out: $1.50, Cache Read: $0.02 | | gemini-3.1-flash-lite-preview | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video | 1048576 | 65536 | In: $0.25, Out: $1.50, Cache Read: $0.02 | | gemini-3.1-flash-live-preview | gemini | In: text, image, video, audio; Out: text, audio | function_calling, reasoning, vision, video | 131072 | 65536 | In: $0.75, Out: $4.50 | | gemini-3.1-flash-tts-preview | gemini | In: text; Out: audio | reasoning, tool_choice | 8192 | 16384 | In: $1.00, Out: $20.00 | | gemini-3.1-pro-preview | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, tool_choice | 1048576 | 65536 | In: $2.00, Out: $12.00, Cache Read: $0.20 | | gemini-3.1-pro-preview-customtools | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, tool_choice | 1048576 | 65536 | In: $2.00, Out: $12.00, Cache Read: $0.20 | | gemini-3.5-flash | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, tool_choice | 1048576 | 65536 | In: $1.50, Out: $9.00, Cache Read: $0.15 | | gemini-3.5-flash-lite | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video | 1048576 | 65536 | In: $0.30, Out: $2.50, Cache Read: $0.03 | | gemini-3.5-live-translate-preview | gemini | In: audio; Out: audio, text | - | 16384 | 32768 | In: $3.50, Out: $21.00 | | gemini-3.6-flash | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, tool_choice | 1048576 | 65536 | In: $1.50, Out: $7.50, Cache Read: $0.15 | | gemini-embedding-001 | gemini | In: text; Out: embeddings | - | 2048 | 1 | In: $0.15, Out: $0.00 | | gemini-embedding-2 | gemini | In: text, image, audio, video, pdf; Out: embeddings | vision, video, tool_choice | 8192 | 1 | In: $0.20, Out: $0.00 | | gemini-embedding-2-preview | gemini | In: -; Out: - | function_calling, tool_choice, structured_output, vision | 8192 | 1 | In: $0.00, Out: $0.00 | | gemini-flash-latest | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, tool_choice | 1048576 | 65536 | In: $1.50, Out: $9.00, Cache Read: $0.15 | | gemini-flash-lite-latest | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video | 1048576 | 65536 | In: $0.25, Out: $1.50, Cache Read: $0.02 | | gemini-omni-flash-preview | gemini | In: text, image, video; Out: video | reasoning, vision, video, tool_choice | 131072 | 65536 | In: $1.50, Out: $17.50 | | gemini-pro-latest | gemini | In: -; Out: - | function_calling, tool_choice, structured_output, vision | 1048576 | 65536 | In: $0.08, Out: $0.30 | | gemini-robotics-er-1.5-preview | gemini | In: -; Out: - | function_calling, tool_choice, structured_output, vision | 1048576 | 65536 | In: $0.08, Out: $0.30 | | gemini-robotics-er-1.6-preview | gemini | In: text, image, video, audio; Out: text | function_calling, structured_output, reasoning, vision, video, tool_choice | 131072 | 65536 | In: $1.00, Out: $5.00 | | gemini-robotics-er-2-preview | gemini | In: -; Out: - | function_calling, tool_choice, structured_output, vision | 131072 | 65536 | In: $0.08, Out: $0.30 | | gemma-4-26b-a4b-it | gemini | In: text, image; Out: text | function_calling, structured_output, reasoning, vision | 262144 | 32768 | In: $0.08, Out: $0.30 | | gemma-4-31b-it | gemini | In: text, image; Out: text | function_calling, structured_output, reasoning, vision | 262144 | 32768 | In: $0.08, Out: $0.30 | | imagen-4.0-generate-001 | gemini | In: -; Out: - | vision | 480 | 8192 | In: $0.03, Out: $0.03 | | imagen-4.0-fast-generate-001 | gemini | In: -; Out: - | vision | 480 | 8192 | In: $0.03, Out: $0.03 | | imagen-4.0-ultra-generate-001 | gemini | In: -; Out: - | vision | 480 | 8192 | In: $0.03, Out: $0.03 | | lyria-3-clip-preview | gemini | In: text, image; Out: text, audio | vision | 1048576 | 65536 | In: $0.00, Out: $0.00 | | lyria-3-pro-preview | gemini | In: text, image; Out: text, audio | vision, tool_choice | 1048576 | 65536 | In: $0.00, Out: $0.00 | | aqa | gemini | In: -; Out: - | - | 7168 | 1024 | In: $0.00, Out: $0.00 | | gemini-2.5-flash-image | gemini | In: text, image; Out: text, image | reasoning, vision, tool_choice | 32768 | 32768 | In: $0.30, Out: $30.00, Cache Read: $0.08 | | gemini-3.1-flash-image | gemini | In: text, image, video, pdf; Out: text, image | reasoning, vision, video, tool_choice | 65536 | 65536 | In: $0.50, Out: $60.00 | | gemini-3.1-flash-image-preview | gemini | In: text, image, pdf; Out: text, image | reasoning, vision, tool_choice | 65536 | 65536 | In: $0.50, Out: $60.00 | | gemini-3.1-flash-lite-image | gemini | In: text, image; Out: text, image | function_calling, reasoning, vision | 65536 | 65536 | In: $0.25, Out: $30.00 | | gemini-3-pro-image | gemini | In: text, image; Out: text, image | reasoning, vision, tool_choice | 131072 | 32768 | In: $2.00, Out: $120.00 | | gemini-3-pro-image-preview | gemini | In: text, image; Out: text, image | reasoning, vision, tool_choice | 131072 | 32768 | In: $2.00, Out: $120.00 | | nano-banana-pro-preview | gemini | In: -; Out: - | function_calling, tool_choice, structured_output, vision | 131072 | 32768 | In: $0.08, Out: $0.30 | | veo-3.1-generate-preview | gemini | In: text, image; Out: video | vision | 480 | 8192 | In: $0.08, Out: $0.30 | | veo-3.1-fast-generate-preview | gemini | In: text, image, video; Out: video | vision, video | 480 | 8192 | - | | veo-3.1-lite-generate-preview | gemini | In: text, image; Out: video | vision | 480 | 8192 | - | ### Mistral (74) | Model | Provider | I/O | Capabilities | Context | Max Output | Standard Pricing (per 1M tokens) | | :-- | :-- | :-- | :-- | --: | --: | :-- | | codestral-2508 | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, predicted_outputs, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | codestral-embed | mistral | In: text; Out: embeddings | predicted_outputs | 32768 | 8192 | - | | codestral-embed-2505 | mistral | In: text; Out: embeddings | predicted_outputs | 32768 | 8192 | - | | codestral-latest | mistral | In: text; Out: text | function_calling, streaming, batch, predicted_outputs, tool_choice, parallel_tool_calls | 256000 | 4096 | In: $0.30, Out: $0.90 | | devstral-2512 | mistral | In: text; Out: text | function_calling, streaming, batch, fine_tuning, tool_choice, parallel_tool_calls | 262144 | 262144 | In: $0.40, Out: $2.00 | | devstral-latest | mistral | In: text; Out: text | function_calling, streaming, batch, fine_tuning, tool_choice, parallel_tool_calls | 262144 | 262144 | In: $0.40, Out: $2.00 | | devstral-medium-latest | mistral | In: text; Out: text | function_calling, streaming, batch, fine_tuning, tool_choice, parallel_tool_calls | 262144 | 262144 | In: $0.40, Out: $2.00 | | devstral-medium-2507 | mistral | In: text; Out: text | function_calling, tool_choice, parallel_tool_calls | 128000 | 128000 | In: $0.40, Out: $2.00 | | devstral-small-2507 | mistral | In: text; Out: text | function_calling, tool_choice, parallel_tool_calls | 128000 | 128000 | In: $0.10, Out: $0.30 | | labs-devstral-small-2512 | mistral | In: text, image; Out: text | function_calling, vision, tool_choice, parallel_tool_calls | 256000 | 256000 | In: $0.00, Out: $0.00 | | devstral-small-2505 | mistral | In: text; Out: text | function_calling, tool_choice, parallel_tool_calls | 128000 | 128000 | In: $0.10, Out: $0.30 | | labs-leanstral-1-5 | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | labs-leanstral-1-5-1 | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | magistral-medium-latest | mistral | In: text; Out: text | function_calling, reasoning, streaming, batch, tool_choice, parallel_tool_calls | 128000 | 16384 | In: $2.00, Out: $5.00 | | magistral-medium-2509 | mistral | In: text; Out: text | streaming, function_calling, structured_output, reasoning, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | magistral-small | mistral | In: text; Out: text | function_calling, reasoning, tool_choice, parallel_tool_calls | 128000 | 128000 | In: $0.50, Out: $1.50 | | magistral-small-2509 | mistral | In: text; Out: text | streaming, function_calling, structured_output, reasoning, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | magistral-small-latest | mistral | In: text; Out: text | streaming, function_calling, structured_output, reasoning, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | ministral-14b-2512 | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, distillation, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | ministral-14b-latest | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, distillation, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | ministral-3b-2512 | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, distillation, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | ministral-3b-latest | mistral | In: text; Out: text | function_calling, streaming, batch, distillation, tool_choice, parallel_tool_calls | 128000 | 128000 | In: $0.04, Out: $0.04 | | ministral-8b-2512 | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, distillation, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | ministral-8b-latest | mistral | In: text; Out: text | function_calling, streaming, batch, distillation, tool_choice, parallel_tool_calls | 128000 | 128000 | In: $0.10, Out: $0.10 | | open-mistral-7b | mistral | In: text; Out: text | function_calling, tool_choice, parallel_tool_calls | 8000 | 8000 | In: $0.25, Out: $0.25 | | mistral-code-agent-latest | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | mistral-code-fim-latest | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | mistral-code-latest | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | mistral-embed | mistral | In: text; Out: text | - | 8000 | 3072 | In: $0.10, Out: $0.00 | | mistral-embed-2312 | mistral | In: text; Out: embeddings | - | 32768 | 8192 | - | | mistral-large-latest | mistral | In: text, image; Out: text | function_calling, vision, streaming, batch, fine_tuning, tool_choice, parallel_tool_calls | 262144 | 262144 | In: $0.50, Out: $1.50 | | mistral-large-2411 | mistral | In: text; Out: text | function_calling, tool_choice, parallel_tool_calls | 131072 | 16384 | In: $2.00, Out: $6.00 | | mistral-large-2512 | mistral | In: text, image; Out: text | function_calling, vision, streaming, batch, fine_tuning, tool_choice, parallel_tool_calls | 262144 | 262144 | In: $0.50, Out: $1.50 | | mistral-medium | mistral | In: text; Out: text | streaming, function_calling, structured_output, vision, batch, fine_tuning, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | mistral-medium-3 | mistral | In: text; Out: text | streaming, function_calling, structured_output, vision, reasoning, batch, fine_tuning, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | mistral-medium-3-5 | mistral | In: text; Out: text | streaming, function_calling, structured_output, vision, reasoning, batch, fine_tuning, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | mistral-medium-3.5 | mistral | In: text; Out: text | streaming, function_calling, structured_output, vision, reasoning, batch, fine_tuning, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | mistral-medium-latest | mistral | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming, batch, fine_tuning, tool_choice, parallel_tool_calls | 262144 | 262144 | In: $1.50, Out: $7.50 | | mistral-medium-2505 | mistral | In: text, image; Out: text | function_calling, vision, streaming, batch, fine_tuning, tool_choice, parallel_tool_calls | 131072 | 131072 | In: $0.40, Out: $2.00 | | mistral-medium-2508 | mistral | In: text, image; Out: text | function_calling, vision, streaming, batch, fine_tuning, tool_choice, parallel_tool_calls | 262144 | 262144 | In: $0.40, Out: $2.00 | | mistral-medium-2604 | mistral | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming, batch, fine_tuning, tool_choice, parallel_tool_calls | 262144 | 262144 | In: $1.50, Out: $7.50 | | mistral-moderation-2603 | mistral | In: text; Out: text | moderation | 32768 | 8192 | - | | mistral-nemo | mistral | In: text; Out: text | function_calling, tool_choice, parallel_tool_calls | 128000 | 128000 | In: $0.15, Out: $0.15 | | mistral-ocr-2512 | mistral | In: text; Out: text | vision | 32768 | 8192 | - | | mistral-ocr-3 | mistral | In: text; Out: text | vision | 32768 | 8192 | - | | mistral-ocr-3-0 | mistral | In: text; Out: text | vision | 32768 | 8192 | - | | mistral-ocr-4 | mistral | In: text; Out: text | vision | 32768 | 8192 | - | | mistral-ocr-4-0 | mistral | In: text; Out: text | vision | 32768 | 8192 | - | | mistral-ocr-latest | mistral | In: text; Out: text | vision | 32768 | 8192 | - | | mistral-small-latest | mistral | In: text, image; Out: text | function_calling, reasoning, vision, streaming, batch, fine_tuning, tool_choice, parallel_tool_calls | 256000 | 256000 | In: $0.15, Out: $0.60 | | mistral-small-2506 | mistral | In: text, image; Out: text | function_calling, vision, streaming, batch, fine_tuning, tool_choice, parallel_tool_calls | 128000 | 16384 | In: $0.10, Out: $0.30 | | mistral-small-2603 | mistral | In: text, image; Out: text | function_calling, reasoning, vision, streaming, batch, fine_tuning, tool_choice, parallel_tool_calls | 256000 | 256000 | In: $0.15, Out: $0.60 | | mistral-tiny-2407 | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | mistral-tiny-latest | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | mistral-vibe-cli-fast | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | mistral-vibe-cli-latest | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | mistral-vibe-cli-with-tools | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | open-mixtral-8x22b | mistral | In: text; Out: text | function_calling, tool_choice, parallel_tool_calls | 64000 | 64000 | In: $2.00, Out: $6.00 | | open-mixtral-8x7b | mistral | In: text; Out: text | function_calling, tool_choice, parallel_tool_calls | 32000 | 32000 | In: $0.70, Out: $0.70 | | open-mistral-nemo | mistral | In: text; Out: text | function_calling, streaming, batch, tool_choice, parallel_tool_calls | 128000 | 128000 | In: $0.15, Out: $0.15 | | open-mistral-nemo-2407 | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | pixtral-12b | mistral | In: text, image; Out: text | function_calling, vision, tool_choice, parallel_tool_calls | 128000 | 128000 | In: $0.15, Out: $0.15 | | pixtral-large-latest | mistral | In: text, image; Out: text | function_calling, vision, tool_choice, parallel_tool_calls | 128000 | 128000 | In: $2.00, Out: $6.00 | | voxtral-mini-latest | mistral | In: audio; Out: text | streaming | 0 | 0 | - | | voxtral-mini-2507 | mistral | In: text; Out: text | streaming | 32768 | 8192 | - | | voxtral-mini-2602 | mistral | In: text; Out: text | streaming | 32768 | 8192 | - | | voxtral-mini-realtime-2602 | mistral | In: text; Out: text | streaming | 32768 | 8192 | - | | voxtral-mini-realtime-latest | mistral | In: text; Out: text | streaming | 32768 | 8192 | - | | voxtral-mini-tts-latest | mistral | In: text; Out: audio | streaming | 0 | 0 | - | | voxtral-mini-transcribe-realtime-2602 | mistral | In: text; Out: text | transcription | 32768 | 8192 | - | | voxtral-mini-tts-2603 | mistral | In: text; Out: text | streaming | 32768 | 8192 | - | | voxtral-mini-tts-mellon-greek-2606-solutions | mistral | In: text; Out: text | streaming | 32768 | 8192 | - | | voxtral-small-latest | mistral | In: text, audio; Out: text | function_calling, streaming | 32000 | 32000 | In: $0.10, Out: $0.30 | | voxtral-small-2507 | mistral | In: text; Out: text | streaming | 32768 | 8192 | - | ### OpenAI (132) | Model | Provider | I/O | Capabilities | Context | Max Output | Standard Pricing (per 1M tokens) | | :-- | :-- | :-- | :-- | --: | --: | :-- | | gpt-3.5-turbo | openai | In: text; Out: text | - | 16385 | 4096 | In: $0.50, Out: $1.50, Cache Read: $0.00 | | gpt-4 | openai | In: text; Out: text | function_calling, tool_choice, parallel_tool_calls | 8192 | 8192 | In: $30.00, Out: $60.00 | | gpt-4-turbo | openai | In: text, image; Out: text | function_calling, vision, tool_choice, parallel_tool_calls | 128000 | 4096 | In: $10.00, Out: $30.00 | | gpt-4.1 | openai | In: text, image, pdf; Out: text | function_calling, structured_output, vision, tool_choice, parallel_tool_calls | 1047576 | 32768 | In: $2.00, Out: $8.00, Cache Read: $0.50 | | gpt-4.1-mini | openai | In: text, image, pdf; Out: text | function_calling, structured_output, vision, tool_choice, parallel_tool_calls | 1047576 | 32768 | In: $0.40, Out: $1.60, Cache Read: $0.10 | | gpt-4.1-nano | openai | In: text, image; Out: text | function_calling, structured_output, vision, tool_choice, parallel_tool_calls | 1047576 | 32768 | In: $0.10, Out: $0.40, Cache Read: $0.02 | | gpt-4o | openai | In: text, image, pdf; Out: text | function_calling, structured_output, vision, tool_choice, parallel_tool_calls | 128000 | 16384 | In: $2.50, Out: $10.00, Cache Read: $1.25 | | gpt-4o-2024-05-13 | openai | In: text, image; Out: text | function_calling, structured_output, vision, tool_choice, parallel_tool_calls | 128000 | 4096 | In: $5.00, Out: $15.00 | | gpt-4o-2024-08-06 | openai | In: text, image; Out: text | function_calling, structured_output, vision, tool_choice, parallel_tool_calls | 128000 | 16384 | In: $2.50, Out: $10.00, Cache Read: $1.25 | | gpt-4o-2024-11-20 | openai | In: text, image; Out: text | function_calling, structured_output, vision, tool_choice, parallel_tool_calls | 128000 | 16384 | In: $2.50, Out: $10.00, Cache Read: $1.25 | | gpt-4o-mini | openai | In: text, image, pdf; Out: text | function_calling, structured_output, vision, tool_choice, parallel_tool_calls | 128000 | 16384 | In: $0.15, Out: $0.60, Cache Read: $0.08 | | gpt-5 | openai | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 400000 | 128000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5-mini | openai | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 400000 | 128000 | In: $0.25, Out: $2.00, Cache Read: $0.02 | | gpt-5-nano | openai | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 400000 | 128000 | In: $0.05, Out: $0.40, Cache Read: $0.01 | | gpt-5-pro | openai | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 400000 | 272000 | In: $15.00, Out: $120.00 | | gpt-5.1 | openai | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 400000 | 128000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.2 | openai | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 400000 | 128000 | In: $1.75, Out: $14.00, Cache Read: $0.18 | | gpt-5.2-chat-latest | openai | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 128000 | 16384 | In: $1.75, Out: $14.00, Cache Read: $0.18 | | gpt-5.2-pro | openai | In: text, image; Out: text | function_calling, reasoning, vision, tool_choice, parallel_tool_calls | 400000 | 128000 | In: $21.00, Out: $168.00 | | gpt-5.3-chat-latest | openai | In: text, image; Out: text | function_calling, structured_output, vision, tool_choice, parallel_tool_calls | 128000 | 16384 | In: $1.75, Out: $14.00, Cache Read: $0.18 | | gpt-5.3-codex | openai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 400000 | 128000 | In: $1.75, Out: $14.00, Cache Read: $0.18 | | gpt-5.3-codex-spark | openai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 128000 | 32000 | In: $1.75, Out: $14.00, Cache Read: $0.18 | | gpt-5.4 | openai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 1050000 | 128000 | In: $2.50, Out: $15.00, Cache Read: $0.25 | | gpt-5.4-pro | openai | In: text, image; Out: text | function_calling, reasoning, vision, tool_choice, parallel_tool_calls | 1050000 | 128000 | In: $30.00, Out: $180.00 | | gpt-5.4-mini | openai | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 400000 | 128000 | In: $0.75, Out: $4.50, Cache Read: $0.08 | | gpt-5.4-nano | openai | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 400000 | 128000 | In: $0.20, Out: $1.25, Cache Read: $0.02 | | gpt-5.5 | openai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 1050000 | 128000 | In: $5.00, Out: $30.00, Cache Read: $0.50 | | gpt-5.5-pro | openai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 1050000 | 128000 | In: $30.00, Out: $180.00 | | gpt-5.6 | openai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1050000 | 128000 | In: $5.00, Out: $30.00, Cache Read: $0.50, Cache Write: $6.25 | | gpt-5.6-luna | openai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 1050000 | 128000 | In: $0.20, Out: $1.20, Cache Read: $0.02, Cache Write: $0.25 | | gpt-5.6-sol | openai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 1050000 | 128000 | In: $5.00, Out: $30.00, Cache Read: $0.50, Cache Write: $6.25 | | gpt-5.6-terra | openai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 1050000 | 128000 | In: $2.00, Out: $12.00, Cache Read: $0.20, Cache Write: $2.50 | | gpt-realtime-2.1 | openai | In: text, audio, image; Out: text, audio | function_calling, reasoning, vision | 128000 | 32000 | In: $4.00, Out: $24.00, Cache Read: $0.40 | | babbage-002 | openai | In: -; Out: - | - | 4096 | 16384 | In: $0.40, Out: $0.40 | | chat-latest | openai | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | chatgpt-image-latest | openai | In: text, image; Out: text, image | vision | 0 | 0 | In: $0.50, Out: $1.50 | | davinci-002 | openai | In: -; Out: - | - | 4096 | 16384 | In: $2.00, Out: $2.00 | | gpt-3.5-turbo-0125 | openai | In: -; Out: - | - | 16385 | 4096 | In: $0.50, Out: $1.50 | | gpt-3.5-turbo-1106 | openai | In: -; Out: - | - | 16385 | 4096 | In: $0.50, Out: $1.50 | | gpt-3.5-turbo-16k | openai | In: -; Out: - | - | 16385 | 4096 | In: $0.50, Out: $1.50 | | gpt-3.5-turbo-instruct | openai | In: -; Out: - | - | 16385 | 4096 | In: $0.50, Out: $1.50 | | gpt-3.5-turbo-instruct-0914 | openai | In: -; Out: - | - | 16385 | 4096 | In: $0.50, Out: $1.50 | | gpt-4-0613 | openai | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | gpt-4-turbo-2024-04-09 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, vision | 128000 | 16384 | In: $10.00, Out: $30.00 | | gpt-4.1-2025-04-14 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision | 1047576 | 32768 | In: $2.00, Out: $8.00, Cache Read: $0.50 | | gpt-4.1-mini-2025-04-14 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision | 1047576 | 32768 | In: $0.40, Out: $1.60, Cache Read: $0.10 | | gpt-4.1-nano-2025-04-14 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision | 1047576 | 32768 | In: $0.10, Out: $0.40 | | gpt-4o-mini-2024-07-18 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision | 128000 | 16384 | In: $0.15, Out: $0.60 | | gpt-4o-mini-search-preview | openai | In: -; Out: - | citations | 4096 | 16384 | In: $0.50, Out: $1.50 | | gpt-4o-mini-search-preview-2025-03-11 | openai | In: -; Out: - | citations | 4096 | 16384 | In: $0.50, Out: $1.50 | | gpt-4o-mini-transcribe | openai | In: -; Out: - | - | 16000 | 2000 | In: $1.25, Out: $5.00 | | gpt-4o-mini-transcribe-2025-03-20 | openai | In: -; Out: - | - | 16000 | 2000 | In: $1.25, Out: $5.00 | | gpt-4o-mini-transcribe-2025-12-15 | openai | In: -; Out: - | - | 16000 | 2000 | In: $1.25, Out: $5.00 | | gpt-4o-mini-tts | openai | In: -; Out: - | - | - | - | In: $0.60, Out: $12.00 | | gpt-4o-mini-tts-2025-03-20 | openai | In: -; Out: - | - | - | - | In: $0.60, Out: $12.00 | | gpt-4o-mini-tts-2025-12-15 | openai | In: -; Out: - | - | - | - | In: $0.60, Out: $12.00 | | gpt-4o-search-preview | openai | In: -; Out: - | vision, citations | 128000 | 16384 | In: $2.50, Out: $10.00 | | gpt-4o-search-preview-2025-03-11 | openai | In: -; Out: - | vision, citations | 128000 | 16384 | In: $2.50, Out: $10.00 | | gpt-4o-transcribe | openai | In: -; Out: - | - | 128000 | 16384 | In: $2.50, Out: $10.00 | | gpt-4o-transcribe-diarize | openai | In: -; Out: - | - | 128000 | 16384 | In: $2.50, Out: $10.00 | | gpt-5-2025-08-07 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5-chat-latest | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5-codex | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5-mini-2025-08-07 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 128000 | 400000 | In: $0.25, Out: $2.00, Cache Read: $0.02 | | gpt-5-nano-2025-08-07 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 128000 | 400000 | In: $0.05, Out: $0.40, Cache Read: $0.01 | | gpt-5-pro-2025-10-06 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5-search-api | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning, citations | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5-search-api-2025-10-14 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning, citations | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.1-2025-11-13 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.1-chat-latest | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.1-codex | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.1-codex-max | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.1-codex-mini | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 128000 | 400000 | In: $0.25, Out: $2.00, Cache Read: $0.02 | | gpt-5.2-2025-12-11 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.2-codex | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.2-pro-2025-12-11 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.4-2026-03-05 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.4-mini-2026-03-17 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 128000 | 400000 | In: $0.25, Out: $2.00, Cache Read: $0.02 | | gpt-5.4-nano-2026-03-17 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 128000 | 400000 | In: $0.05, Out: $0.40, Cache Read: $0.01 | | gpt-5.4-pro-2026-03-05 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.5-2026-04-23 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.5-pro-2026-04-23 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-audio | openai | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | gpt-audio-1.5 | openai | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | gpt-audio-2025-08-28 | openai | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | gpt-audio-mini | openai | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | gpt-audio-mini-2025-10-06 | openai | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | gpt-audio-mini-2025-12-15 | openai | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | gpt-image-1 | openai | In: text, image; Out: image | vision | 0 | 0 | In: $5.00, Cache Read: $1.25 | | gpt-image-1-mini | openai | In: text, image; Out: text, image | vision | 0 | 0 | In: $2.00, Cache Read: $0.20 | | gpt-image-1.5 | openai | In: text, image; Out: text, image | vision | 0 | 0 | In: $5.00, Cache Read: $1.25 | | gpt-image-2 | openai | In: text, image; Out: image | vision | 0 | 0 | In: $5.00, Out: $30.00, Cache Read: $1.25 | | gpt-image-2-2026-04-21 | openai | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | gpt-live-transcribe | openai | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | gpt-realtime | openai | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | gpt-realtime-1.5 | openai | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | gpt-realtime-2 | openai | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | gpt-realtime-2.1-mini | openai | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | gpt-realtime-2025-08-28 | openai | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | gpt-realtime-mini | openai | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | gpt-realtime-mini-2025-12-15 | openai | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | gpt-realtime-translate | openai | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | gpt-realtime-whisper | openai | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | gpt-transcribe | openai | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | o1 | openai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 200000 | 100000 | In: $15.00, Out: $60.00, Cache Read: $7.50 | | o1-2024-12-17 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 200000 | 100000 | In: $15.00, Out: $60.00 | | o1-pro | openai | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 200000 | 100000 | In: $150.00, Out: $600.00 | | o1-pro-2025-03-19 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 200000 | 100000 | In: $150.00, Out: $600.00 | | o3 | openai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 100000 | In: $2.00, Out: $8.00, Cache Read: $0.50 | | o3-2025-04-16 | openai | In: -; Out: - | reasoning | 4096 | 16384 | In: $0.50, Out: $1.50 | | o3-deep-research | openai | In: -; Out: - | reasoning | 4096 | 16384 | In: $0.50, Out: $1.50 | | o3-deep-research-2025-06-26 | openai | In: -; Out: - | reasoning | 4096 | 16384 | In: $0.50, Out: $1.50 | | o3-mini | openai | In: text; Out: text | function_calling, structured_output, reasoning, tool_choice, parallel_tool_calls | 200000 | 100000 | In: $1.10, Out: $4.40, Cache Read: $0.55 | | o3-mini-2025-01-31 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, reasoning | 200000 | 100000 | In: $1.10, Out: $4.40 | | o3-pro | openai | In: text, image; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 100000 | In: $20.00, Out: $80.00 | | o3-pro-2025-06-10 | openai | In: -; Out: - | reasoning | 4096 | 16384 | In: $0.50, Out: $1.50 | | o4-mini | openai | In: text, image; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 100000 | In: $1.10, Out: $4.40, Cache Read: $0.28 | | o4-mini-2025-04-16 | openai | In: -; Out: - | reasoning | 4096 | 16384 | In: $0.50, Out: $1.50 | | o4-mini-deep-research | openai | In: -; Out: - | reasoning | 4096 | 16384 | In: $0.50, Out: $1.50 | | o4-mini-deep-research-2025-06-26 | openai | In: -; Out: - | reasoning | 4096 | 16384 | In: $0.50, Out: $1.50 | | omni-moderation-2024-09-26 | openai | In: -; Out: - | vision | - | - | In: $0.00, Out: $0.00 | | omni-moderation-latest | openai | In: -; Out: - | vision | - | - | In: $0.00, Out: $0.00 | | sora-2 | openai | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | sora-2-pro | openai | In: -; Out: - | - | 4096 | 16384 | In: $0.50, Out: $1.50 | | text-embedding-3-large | openai | In: text; Out: embeddings | - | 8191 | 3072 | In: $0.13, Out: $0.00 | | text-embedding-3-small | openai | In: text; Out: embeddings | - | 8191 | 1536 | In: $0.02, Out: $0.00 | | text-embedding-ada-002 | openai | In: text; Out: embeddings | - | 8192 | 1536 | In: $0.10, Out: $0.00 | | tts-1 | openai | In: -; Out: - | - | - | - | In: $15.00, Out: $15.00 | | tts-1-1106 | openai | In: -; Out: - | - | - | - | In: $15.00, Out: $15.00 | | tts-1-hd | openai | In: -; Out: - | - | - | - | In: $30.00, Out: $30.00 | | tts-1-hd-1106 | openai | In: -; Out: - | - | - | - | In: $30.00, Out: $30.00 | | whisper-1 | openai | In: -; Out: - | - | - | - | In: $0.01, Out: $0.01 | ### OpenRouter (400) | Model | Provider | I/O | Capabilities | Context | Max Output | Standard Pricing (per 1M tokens) | | :-- | :-- | :-- | :-- | --: | --: | :-- | | aion-labs/aion-2.0 | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 131072 | 32768 | In: $0.80, Out: $1.60, Cache Read: $0.20 | | aion-labs/aion-3.0 | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 131072 | 32768 | In: $3.00, Out: $6.00, Cache Read: $0.75 | | aion-labs/aion-3.0-mini | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 131072 | 32768 | In: $0.70, Out: $1.40, Cache Read: $0.18 | | aion-labs/aion-rp-llama-3.1-8b | openrouter | In: text; Out: text | streaming | 32768 | 32768 | In: $0.80, Out: $1.60 | | ~anthropic/claude-haiku-latest | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 64000 | In: $1.00, Out: $5.00, Cache Read: $0.10, Cache Write: $1.25 | | ~anthropic/claude-sonnet-latest | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $2.00, Out: $10.00, Cache Read: $0.20, Cache Write: $2.50 | | anthropic/claude-fable-5:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50 | | anthropic/claude-haiku-4.5:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 200000 | 64000 | In: $0.50, Out: $2.50, Cache Read: $0.05 | | anthropic/claude-opus-4.1:batch | openrouter | In: image, text, file; Out: text | streaming, function_calling, structured_output | 200000 | 32000 | In: $7.50, Out: $37.50, Cache Read: $0.75 | | anthropic/claude-opus-4.5:batch | openrouter | In: file, image, text; Out: text | streaming, function_calling, structured_output | 200000 | 64000 | In: $2.50, Out: $12.50, Cache Read: $0.25 | | anthropic/claude-opus-4.6:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 1000000 | 128000 | In: $2.50, Out: $12.50, Cache Read: $0.25 | | anthropic/claude-opus-4.7:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 1000000 | 128000 | In: $2.50, Out: $12.50, Cache Read: $0.25 | | anthropic/claude-opus-4.8:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 1000000 | 128000 | In: $2.50, Out: $12.50, Cache Read: $0.25 | | anthropic/claude-sonnet-4.5:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 1000000 | 64000 | In: $1.50, Out: $7.50, Cache Read: $0.15 | | anthropic/claude-sonnet-4.6:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 1000000 | 128000 | In: $1.50, Out: $7.50, Cache Read: $0.15 | | anthropic/claude-sonnet-5:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 1000000 | 128000 | In: $1.00, Out: $5.00, Cache Read: $0.10 | | openrouter/auto | openrouter | In: text, image, audio, pdf, video; Out: text, image | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 2000000 | 2000000 | - | | openrouter/auto-beta | openrouter | In: text, image, audio, file, video; Out: text, image | streaming, function_calling, structured_output, predicted_outputs | 2000000 | - | - | | openrouter/bodybuilder | openrouter | In: text; Out: text | streaming | 128000 | 128000 | - | | anthropic/claude-3-haiku | openrouter | In: text, image; Out: text | function_calling, vision, streaming | 200000 | 4096 | In: $0.25, Out: $1.25, Cache Read: $0.03, Cache Write: $0.30 | | anthropic/claude-fable-5 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $10.00, Out: $50.00, Cache Read: $1.00, Cache Write: $12.50 | | ~anthropic/claude-fable-latest | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $10.00, Out: $50.00, Cache Read: $1.00, Cache Write: $12.50 | | anthropic/claude-haiku-4.5 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 64000 | In: $1.00, Out: $5.00, Cache Read: $0.10, Cache Write: $1.25 | | anthropic/claude-opus-4 | openrouter | In: image, text, pdf; Out: text | function_calling, reasoning, vision, streaming | 200000 | 32000 | In: $15.00, Out: $75.00, Cache Read: $1.50, Cache Write: $18.75 | | anthropic/claude-opus-4.1 | openrouter | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 200000 | 32000 | In: $15.00, Out: $75.00, Cache Read: $1.50, Cache Write: $18.75 | | anthropic/claude-opus-4.5 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 64000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | anthropic/claude-opus-4.6 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | anthropic/claude-opus-4.7 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | anthropic/claude-opus-4.7-fast | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $30.00, Out: $150.00, Cache Read: $3.00, Cache Write: $37.50 | | anthropic/claude-opus-4.8 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | anthropic/claude-opus-4.8-fast | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $10.00, Out: $50.00, Cache Read: $1.00, Cache Write: $12.50 | | anthropic/claude-opus-5 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | anthropic/claude-opus-5-fast | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $10.00, Out: $50.00, Cache Read: $1.00, Cache Write: $12.50 | | anthropic/claude-opus-5:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 1000000 | 128000 | In: $2.50, Out: $12.50, Cache Read: $0.25 | | ~anthropic/claude-opus-latest | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | anthropic/claude-sonnet-4 | openrouter | In: image, text, pdf; Out: text | function_calling, reasoning, vision, streaming | 1000000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | anthropic/claude-sonnet-4.5 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | anthropic/claude-sonnet-4.6 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | anthropic/claude-sonnet-5 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $2.00, Out: $10.00, Cache Read: $0.20, Cache Write: $2.50 | | mistralai/codestral-2508 | openrouter | In: text, pdf; Out: text | function_calling, structured_output, vision, streaming | 256000 | 256000 | In: $0.30, Out: $0.90, Cache Read: $0.03 | | deepcogito/cogito-v2.1-671b | openrouter | In: text; Out: text | structured_output, reasoning, streaming, predicted_outputs | 128000 | 128000 | In: $1.25, Out: $1.25 | | cohere/command-a | openrouter | In: text; Out: text | structured_output, streaming | 256000 | 8192 | In: $2.50, Out: $10.00 | | cohere/command-r-08-2024 | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 128000 | 4000 | In: $0.15, Out: $0.60 | | cohere/command-r-plus-08-2024 | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 128000 | 4000 | In: $2.50, Out: $10.00 | | cohere/command-r7b-12-2024 | openrouter | In: text; Out: text | structured_output, streaming | 128000 | 4000 | In: $0.04, Out: $0.15 | | thedrummer/cydonia-24b-v4.1 | openrouter | In: text; Out: text | structured_output, streaming, predicted_outputs | 131072 | 131072 | In: $0.30, Out: $0.50, Cache Read: $0.15 | | deepseek/deepseek-chat | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 163840 | 16000 | In: $0.26, Out: $1.03 | | deepseek/deepseek-chat-v3-0324 | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 163840 | 65536 | In: $0.27, Out: $1.12, Cache Read: $0.14 | | deepseek/deepseek-chat-v3.1 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 163840 | 32768 | In: $0.25, Out: $0.95, Cache Read: $0.13 | | deepseek/deepseek-v3.1-terminus | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 163840 | 32768 | In: $0.27, Out: $1.00, Cache Read: $0.14 | | deepseek/deepseek-v3.2 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 163840 | 65536 | In: $0.27, Out: $0.40, Cache Read: $0.13 | | deepseek/deepseek-v3.2-exp | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 163840 | 65536 | In: $0.27, Out: $0.41 | | deepseek/deepseek-v4-flash | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 1048576 | 393216 | In: $0.14, Out: $0.28, Cache Read: $0.03 | | deepseek/deepseek-v4-flash-0731 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 1048576 | 65536 | In: $0.09, Out: $0.18, Cache Read: $0.02 | | ~deepseek/deepseek-v4-flash-latest | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 1048576 | 65536 | In: $0.09, Out: $0.18, Cache Read: $0.02 | | deepseek/deepseek-v4-pro | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 1048576 | 384000 | In: $0.44, Out: $0.87, Cache Read: $0.00 | | deepseek/deepseek-r1 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 163840 | 16000 | In: $0.70, Out: $2.50 | | baidu/ernie-4.5-vl-424b-a47b | openrouter | In: image, text; Out: text | reasoning, vision, streaming | 123000 | 16000 | In: $0.42, Out: $1.25 | | openrouter/free | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 8000 | In: $0.00, Out: $0.00 | | sakana/fugu-ultra | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $30.00, Cache Read: $0.50 | | openrouter/fusion | openrouter | In: text; Out: text | streaming | 1000000 | 128000 | - | | z-ai/glm-4.5 | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 131072 | 98304 | In: $0.60, Out: $2.20, Cache Read: $0.11 | | z-ai/glm-4.5-air | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 131072 | 98304 | In: $0.13, Out: $0.85, Cache Read: $0.02 | | z-ai/glm-4.5v | openrouter | In: text, image; Out: text | function_calling, reasoning, vision, streaming | 65536 | 16384 | In: $0.60, Out: $1.80, Cache Read: $0.11 | | z-ai/glm-4.6 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 204800 | 131072 | In: $0.50, Out: $2.00, Cache Read: $0.10 | | z-ai/glm-4.6v | openrouter | In: text, image, video; Out: text | function_calling, reasoning, vision, video, streaming | 131072 | 32768 | In: $0.30, Out: $0.90, Cache Read: $0.06 | | z-ai/glm-4.7 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 204800 | 131072 | In: $0.40, Out: $1.75, Cache Read: $0.08 | | z-ai/glm-4.7-flash | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 202752 | 16384 | In: $0.06, Out: $0.40, Cache Read: $0.01 | | z-ai/glm-5 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 204800 | 131072 | In: $0.95, Out: $2.55, Cache Read: $0.20 | | z-ai/glm-5-turbo | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 202752 | 131072 | In: $1.20, Out: $4.00, Cache Read: $0.24 | | z-ai/glm-5.1 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 204800 | 131072 | In: $0.95, Out: $2.99, Cache Read: $0.18 | | z-ai/glm-5.2 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 1048576 | 131072 | In: $0.46, Out: $1.45, Cache Read: $0.09 | | z-ai/glm-5v-turbo | openrouter | In: image, text, video; Out: text | function_calling, reasoning, vision, video, streaming | 202752 | 131072 | In: $1.20, Out: $4.00, Cache Read: $0.24 | | openai/gpt-audio | openrouter | In: text, audio; Out: text, audio | function_calling, structured_output, streaming | 128000 | 16384 | In: $2.50, Out: $10.00 | | openai/gpt-audio-mini | openrouter | In: text, audio; Out: text, audio | function_calling, structured_output, streaming | 128000 | 16384 | In: $0.60, Out: $2.40 | | openai/gpt-chat-latest | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 400000 | 128000 | In: $5.00, Out: $30.00, Cache Read: $0.50 | | openai/gpt-oss-120b | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 131072 | 131072 | In: $0.04, Out: $0.17 | | openai/gpt-oss-20b | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 131072 | 131072 | In: $0.03, Out: $0.13, Cache Read: $0.03 | | openai/gpt-3.5-turbo-0613 | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 4095 | 4096 | In: $1.00, Out: $2.00 | | openai/gpt-3.5-turbo-16k | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 16385 | 4096 | In: $3.00, Out: $4.00 | | openai/gpt-3.5-turbo-instruct | openrouter | In: text; Out: text | structured_output, streaming | 4095 | 4096 | In: $1.50, Out: $2.00 | | openai/gpt-3.5-turbo | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 16385 | 4096 | In: $0.50, Out: $1.50 | | openai/gpt-4 | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 8191 | 4096 | In: $30.00, Out: $60.00 | | openai/gpt-4-turbo | openrouter | In: text, image; Out: text | function_calling, structured_output, vision, streaming | 128000 | 4096 | In: $10.00, Out: $30.00 | | openai/gpt-4-turbo-preview | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 128000 | 4096 | In: $10.00, Out: $30.00 | | openai/gpt-4.1 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 1047576 | 32768 | In: $2.00, Out: $8.00, Cache Read: $0.50 | | openai/gpt-4.1-mini | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 1047576 | 32768 | In: $0.40, Out: $1.60, Cache Read: $0.10 | | openai/gpt-4.1-nano | openrouter | In: image, text, pdf; Out: text | function_calling, structured_output, vision, streaming | 1047576 | 32768 | In: $0.10, Out: $0.40, Cache Read: $0.02 | | openai/gpt-4o | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 128000 | 16384 | In: $2.50, Out: $10.00, Cache Read: $1.25 | | openai/gpt-4o-2024-05-13 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 128000 | 4096 | In: $5.00, Out: $15.00 | | openai/gpt-4o-2024-08-06 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 128000 | 16384 | In: $2.50, Out: $10.00, Cache Read: $1.25 | | openai/gpt-4o-2024-11-20 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 128000 | 16384 | In: $2.50, Out: $10.00, Cache Read: $1.25 | | openai/gpt-4o-mini | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 128000 | 16384 | In: $0.15, Out: $0.60, Cache Read: $0.08 | | openai/gpt-4o-mini-2024-07-18 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 128000 | 16384 | In: $0.15, Out: $0.60, Cache Read: $0.08 | | openai/gpt-5 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | openai/gpt-5-image | openrouter | In: image, text, pdf; Out: image, text | structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $10.00, Out: $10.00, Cache Read: $1.25 | | openai/gpt-5-image-mini | openrouter | In: pdf, image, text; Out: image, text | structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $2.50, Out: $2.00, Cache Read: $0.25 | | openai/gpt-5-mini | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $0.25, Out: $2.00, Cache Read: $0.02 | | openai/gpt-5-nano | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $0.05, Out: $0.40, Cache Read: $0.01 | | openai/gpt-5-pro | openrouter | In: image, text, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $15.00, Out: $120.00 | | openai/gpt-5.1 | openrouter | In: image, text, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | openai/gpt-5.1-codex | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $1.25, Out: $10.00, Cache Read: $0.13 | | openai/gpt-5.1-codex-max | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | openai/gpt-5.1-codex-mini | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $0.25, Out: $2.00, Cache Read: $0.03 | | openai/gpt-5.2 | openrouter | In: pdf, image, text; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $1.75, Out: $14.00, Cache Read: $0.18 | | openai/gpt-5.2-chat | openrouter | In: pdf, image, text; Out: text | function_calling, structured_output, vision, streaming | 128000 | 16384 | In: $1.75, Out: $14.00, Cache Read: $0.18 | | openai/gpt-5.2-codex | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $1.75, Out: $14.00, Cache Read: $0.18 | | openai/gpt-5.2-pro | openrouter | In: image, text, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $21.00, Out: $168.00 | | openai/gpt-5.3-chat | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 128000 | 16384 | In: $1.75, Out: $14.00, Cache Read: $0.18 | | openai/gpt-5.3-codex | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $1.75, Out: $14.00, Cache Read: $0.18 | | openai/gpt-5.4 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $2.50, Out: $15.00, Cache Read: $0.25 | | openai/gpt-5.4-image-2 | openrouter | In: image, text, pdf; Out: image, text | structured_output, reasoning, vision, streaming | 272000 | 128000 | In: $8.00, Out: $15.00, Cache Read: $2.00 | | openai/gpt-5.4-pro | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $30.00, Out: $180.00 | | openai/gpt-5.4-mini | openrouter | In: pdf, image, text; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $0.75, Out: $4.50, Cache Read: $0.08 | | openai/gpt-5.4-nano | openrouter | In: pdf, image, text; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $0.20, Out: $1.25, Cache Read: $0.02 | | openai/gpt-5.5 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $5.00, Out: $30.00, Cache Read: $0.50 | | openai/gpt-5.5-pro | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $30.00, Out: $180.00 | | openai/gpt-5.6-luna | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $0.10, Out: $0.60, Cache Read: $0.01, Cache Write: $0.12 | | openai/gpt-5.6-luna-pro | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $0.10, Out: $0.60, Cache Read: $0.01, Cache Write: $0.12 | | openai/gpt-5.6-sol | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $5.00, Out: $30.00, Cache Read: $0.50, Cache Write: $6.25 | | openai/gpt-5.6-sol-pro | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $5.00, Out: $30.00, Cache Read: $0.50, Cache Write: $6.25 | | openai/gpt-5.6-terra | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $1.00, Out: $6.00, Cache Read: $0.10, Cache Write: $1.25 | | openai/gpt-5.6-terra-pro | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $1.00, Out: $6.00, Cache Read: $0.10, Cache Write: $1.25 | | google/gemini-2.5-flash | openrouter | In: text, image, audio, video, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65535 | In: $0.30, Out: $2.50, Cache Read: $0.03, Cache Write: $0.08 | | google/gemini-2.5-flash-lite | openrouter | In: text, image, audio, video, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65535 | In: $0.10, Out: $0.40, Cache Read: $0.01, Cache Write: $0.08 | | google/gemini-2.5-pro | openrouter | In: text, image, audio, video, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $1.25, Out: $10.00, Cache Read: $0.12, Cache Write: $0.38 | | google/gemini-2.5-pro-preview-05-06 | openrouter | In: text, image, pdf, audio, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65535 | In: $1.25, Out: $10.00, Cache Read: $0.12, Cache Write: $0.38 | | google/gemini-2.5-pro-preview | openrouter | In: pdf, image, text, audio; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1048576 | 65536 | In: $1.25, Out: $10.00, Cache Read: $0.12, Cache Write: $0.38 | | google/gemini-3-flash-preview | openrouter | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $0.50, Out: $3.00, Cache Read: $0.05, Cache Write: $0.08 | | google/gemini-3.1-flash-lite | openrouter | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $0.25, Out: $1.50, Cache Read: $0.02, Cache Write: $0.08 | | google/gemini-3.1-flash-lite-preview | openrouter | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $0.25, Out: $1.50, Cache Read: $0.02, Cache Write: $0.08 | | google/gemini-3.1-pro-preview | openrouter | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $2.00, Out: $12.00, Cache Read: $0.20, Cache Write: $0.38 | | google/gemini-3.1-pro-preview-customtools | openrouter | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $2.00, Out: $12.00, Cache Read: $0.20, Cache Write: $0.38 | | google/gemini-3.5-flash | openrouter | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $1.50, Out: $9.00, Cache Read: $0.15, Cache Write: $0.08 | | google/gemini-3.5-flash-lite | openrouter | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $0.30, Out: $2.50, Cache Read: $0.03, Cache Write: $0.08 | | google/gemini-3.6-flash | openrouter | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $1.50, Out: $7.50, Cache Read: $0.15, Cache Write: $0.08 | | google/gemma-2-27b-it | openrouter | In: text; Out: text | structured_output, streaming | 8192 | 2048 | In: $0.65, Out: $0.65 | | google/gemma-3-12b-it | openrouter | In: text, image; Out: text | function_calling, structured_output, vision, streaming, predicted_outputs | 131072 | 16384 | In: $0.05, Out: $0.15 | | google/gemma-3-27b-it | openrouter | In: text, image; Out: text | function_calling, structured_output, vision, streaming, predicted_outputs | 262144 | 131072 | In: $0.08, Out: $0.45, Cache Read: $0.04 | | google/gemma-3-4b-it | openrouter | In: text, image; Out: text | structured_output, vision, streaming, predicted_outputs | 131072 | 16384 | In: $0.05, Out: $0.10 | | google/gemma-3n-e4b-it | openrouter | In: text; Out: text | structured_output, streaming, predicted_outputs | 32768 | 32768 | In: $0.06, Out: $0.12 | | google/gemma-4-26b-a4b-it:free | openrouter | In: image, text, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 262144 | 32768 | In: $0.00, Out: $0.00 | | google/gemma-4-26b-a4b-it | openrouter | In: image, text, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 262144 | 16384 | In: $0.07, Out: $0.34 | | google/gemma-4-31b-it:free | openrouter | In: image, text, video; Out: text | function_calling, reasoning, vision, video, streaming | 262144 | 32768 | In: $0.00, Out: $0.00 | | google/gemma-4-31b-it | openrouter | In: image, text, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 262144 | 262144 | In: $0.10, Out: $0.34, Cache Read: $0.10 | | ~google/gemini-flash-latest | openrouter | In: text, image, video, pdf, audio; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $1.50, Out: $7.50, Cache Read: $0.15, Cache Write: $0.08 | | ~google/gemini-pro-latest | openrouter | In: audio, pdf, image, text, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $2.00, Out: $12.00, Cache Read: $0.20, Cache Write: $0.38 | | google/gemini-2.5-flash:batch | openrouter | In: file, image, text, audio, video; Out: text | streaming, function_calling, structured_output | 1048576 | 65535 | In: $0.15, Out: $1.25, Cache Read: $0.03 | | google/gemini-2.5-flash-lite:batch | openrouter | In: text, image, file, audio, video; Out: text | streaming, function_calling, structured_output | 1048576 | 65535 | In: $0.05, Out: $0.20, Cache Read: $0.01 | | google/gemini-2.5-pro:batch | openrouter | In: text, image, file, audio, video; Out: text | streaming, function_calling, structured_output | 1048576 | 65536 | In: $0.62, Out: $5.00, Cache Read: $0.12 | | google/gemini-3-flash-preview:batch | openrouter | In: text, image, file, audio, video; Out: text | streaming, function_calling, structured_output | 1048576 | 65536 | In: $0.25, Out: $1.50 | | google/gemini-3.1-flash-lite:batch | openrouter | In: text, image, video, file, audio; Out: text | streaming, function_calling, structured_output | 1048576 | 65536 | In: $0.12, Out: $0.75, Cache Read: $0.01 | | google/gemini-3.1-pro-preview:batch | openrouter | In: audio, file, image, text, video; Out: text | streaming, function_calling, structured_output | 1048576 | 65536 | In: $1.00, Out: $6.00 | | google/gemini-3.5-flash:batch | openrouter | In: text, image, video, file, audio; Out: text | streaming, function_calling, structured_output | 1048576 | 65536 | In: $0.75, Out: $4.50, Cache Read: $0.08 | | google/gemini-3.5-flash-lite:batch | openrouter | In: text, image, video, file, audio; Out: text | streaming, function_calling, structured_output | 1048576 | 65536 | In: $0.15, Out: $1.25, Cache Read: $0.02 | | google/gemini-3.6-flash:batch | openrouter | In: text, image, video, file, audio; Out: text | streaming, function_calling, structured_output | 1048576 | 65536 | In: $0.75, Out: $3.75, Cache Read: $0.08 | | ibm-granite/granite-4.0-h-micro | openrouter | In: text; Out: text | streaming, predicted_outputs | 131000 | 131000 | In: $0.02, Out: $0.11 | | ibm-granite/granite-4.1-8b | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 131072 | 131072 | In: $0.05, Out: $0.10, Cache Read: $0.05 | | x-ai/grok-4.20 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 2000000 | 2000000 | In: $1.25, Out: $2.50, Cache Read: $0.20 | | x-ai/grok-4.20-multi-agent | openrouter | In: text, image, pdf; Out: text | structured_output, reasoning, vision, streaming | 2000000 | 2000000 | In: $1.25, Out: $2.50, Cache Read: $0.20 | | x-ai/grok-4.3 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 1000000 | In: $1.25, Out: $2.50, Cache Read: $0.20 | | x-ai/grok-4.5 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 500000 | 500000 | In: $2.00, Out: $6.00, Cache Read: $0.30 | | x-ai/grok-build-0.1 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 256000 | 256000 | In: $1.00, Out: $2.00, Cache Read: $0.20 | | ~x-ai/grok-latest | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 500000 | 1000000 | In: $2.00, Out: $6.00, Cache Read: $0.30 | | nousresearch/hermes-3-llama-3.1-405b | openrouter | In: text; Out: text | structured_output, streaming, predicted_outputs | 131072 | 16384 | In: $1.00, Out: $1.00 | | nousresearch/hermes-3-llama-3.1-70b | openrouter | In: text; Out: text | structured_output, streaming, predicted_outputs | 131072 | 16384 | In: $0.70, Out: $0.70 | | nousresearch/hermes-4-405b | openrouter | In: text; Out: text | reasoning, streaming | 131072 | 131072 | In: $1.00, Out: $3.00 | | nousresearch/hermes-4-70b | openrouter | In: text; Out: text | reasoning, streaming | 131072 | 131072 | In: $0.13, Out: $0.40 | | tencent/hunyuan-a13b-instruct | openrouter | In: text; Out: text | structured_output, reasoning, streaming | 131072 | 131072 | In: $0.14, Out: $0.57 | | tencent/hy3 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 262144 | 128000 | In: $0.13, Out: $0.53, Cache Read: $0.03 | | tencent/hy3-preview | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 262144 | 262144 | In: $0.06, Out: $0.21, Cache Read: $0.02 | | thinkingmachines/inkling | openrouter | In: text, image, audio; Out: text | function_calling, reasoning, vision, streaming, predicted_outputs | 1048576 | 1048576 | In: $1.00, Out: $4.05, Cache Read: $0.17 | | thinkingmachines/inkling-small | openrouter | In: text, image, audio; Out: text | function_calling, reasoning, vision, streaming, predicted_outputs | 524288 | 262144 | In: $0.45, Out: $1.20, Cache Read: $0.10 | | ai21/jamba-large-1.7 | openrouter | In: text; Out: text | function_calling, streaming | 256000 | 4096 | In: $2.00, Out: $8.00 | | kwaipilot/kat-coder-air-v2.5 | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 256000 | 80000 | In: $0.15, Out: $0.60, Cache Read: $0.03 | | kwaipilot/kat-coder-pro-v2 | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 262144 | 80000 | In: $0.30, Out: $1.20, Cache Read: $0.06 | | kwaipilot/kat-coder-pro-v2.5 | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 256000 | 80000 | In: $0.74, Out: $2.96, Cache Read: $0.15 | | moonshotai/kimi-k2 | openrouter | In: text; Out: text | function_calling, streaming | 131072 | 100352 | In: $0.57, Out: $2.30 | | moonshotai/kimi-k2-0905 | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 262144 | 100352 | In: $0.60, Out: $2.50 | | moonshotai/kimi-k2-thinking | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 262144 | 100352 | In: $0.60, Out: $2.50, Cache Read: $0.15 | | moonshotai/kimi-k2.5 | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming, predicted_outputs | 262144 | 262144 | In: $0.57, Out: $2.85, Cache Read: $0.10 | | moonshotai/kimi-k2.6 | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming, predicted_outputs | 262144 | 262144 | In: $0.58, Out: $2.44, Cache Read: $0.10 | | moonshotai/kimi-k2.7-code | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming, predicted_outputs | 262144 | 262144 | In: $0.70, Out: $3.50, Cache Read: $0.15 | | moonshotai/kimi-k3 | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming, predicted_outputs | 1048576 | 1048576 | In: $3.00, Out: $15.00, Cache Read: $0.30 | | poolside/laguna-s-2.1 | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 1048576 | 131072 | In: $0.09, Out: $0.18, Cache Read: $0.01 | | poolside/laguna-s-2.1:free | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 262144 | 32768 | In: $0.00, Out: $0.00 | | poolside/laguna-xs-2.1 | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 262144 | 32768 | In: $0.06, Out: $0.12, Cache Read: $0.03 | | poolside/laguna-xs-2.1:free | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 262144 | 32768 | In: $0.00, Out: $0.00 | | inclusionai/ling-3.0-tiny:free | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 262144 | 32768 | In: $0.00, Out: $0.00 | | inclusionai/ling-2.6-1t | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 262144 | 32768 | In: $0.08, Out: $0.62, Cache Read: $0.02 | | inclusionai/ling-2.6-flash | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 262144 | 32768 | In: $0.01, Out: $0.03, Cache Read: $0.00 | | inclusionai/ling-3.0-flash | openrouter | In: text; Out: text | function_calling, reasoning, streaming, predicted_outputs | 262144 | 32768 | In: $0.02, Out: $0.06, Cache Read: $0.00 | | sao10k/l3-lunaris-8b | openrouter | In: text; Out: text | structured_output, streaming, predicted_outputs | 8192 | 16384 | In: $0.04, Out: $0.05 | | meta-llama/llama-3.1-70b-instruct | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 131072 | 16384 | In: $0.40, Out: $0.40 | | meta-llama/llama-3.1-8b-instruct | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 131072 | 131072 | In: $0.05, Out: $0.08, Cache Read: $0.02 | | sao10k/l3.1-euryale-70b | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 131072 | 16384 | In: $0.85, Out: $0.85 | | meta-llama/llama-3.2-1b-instruct | openrouter | In: text; Out: text | streaming, predicted_outputs | 60000 | 60000 | In: $0.03, Out: $0.20 | | meta-llama/llama-3.2-3b-instruct | openrouter | In: text; Out: text | structured_output, streaming, predicted_outputs | 131072 | 131072 | In: $0.05, Out: $0.33 | | sao10k/l3.3-euryale-70b | openrouter | In: text; Out: text | structured_output, streaming | 131072 | 16384 | In: $0.65, Out: $0.75 | | meta-llama/llama-4-maverick | openrouter | In: text, image; Out: text | function_calling, structured_output, vision, streaming, predicted_outputs | 1048576 | 16384 | In: $0.20, Out: $0.80 | | meta-llama/llama-4-scout | openrouter | In: text, image; Out: text | function_calling, structured_output, vision, streaming, predicted_outputs | 1310720 | 16384 | In: $0.10, Out: $0.30 | | meta-llama/llama-guard-4-12b | openrouter | In: image, text; Out: text | vision, streaming, predicted_outputs | 1048576 | 16384 | In: $0.18, Out: $0.18 | | meta-llama/llama-3.3-70b-instruct | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 131072 | 16384 | In: $0.10, Out: $0.32 | | meituan/longcat-2.0 | openrouter | In: text; Out: text | function_calling, reasoning, streaming, predicted_outputs | 1048756 | 262144 | In: $0.30, Out: $1.20, Cache Read: $0.01 | | google/lyria-3-clip-preview | openrouter | In: text, image; Out: text, audio | vision, streaming | 1048576 | 65536 | In: $0.00, Out: $0.00 | | google/lyria-3-pro-preview | openrouter | In: text, image; Out: text, audio | vision, streaming | 1048576 | 65536 | In: $0.00, Out: $0.00 | | anthracite-org/magnum-v4-72b | openrouter | In: text; Out: text | structured_output, streaming, predicted_outputs | 16384 | 2048 | In: $3.00, Out: $5.00 | | inception/mercury-2 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 128000 | 50000 | In: $0.25, Out: $0.75, Cache Read: $0.02 | | xiaomi/mimo-v2.5 | openrouter | In: text, image, audio, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 1050000 | 131072 | In: $0.14, Out: $0.28, Cache Read: $0.00 | | xiaomi/mimo-v2.5-pro | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 1050000 | 131072 | In: $0.44, Out: $0.87, Cache Read: $0.00 | | minimax/minimax-m1 | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 1000000 | 40000 | In: $0.55, Out: $2.20 | | minimax/minimax-m2-her | openrouter | In: text; Out: text | streaming | 65536 | 2048 | In: $0.30, Out: $1.20, Cache Read: $0.03 | | minimax/minimax-01 | openrouter | In: text, image; Out: text | vision, streaming | 1000192 | 1000192 | In: $0.20, Out: $1.10 | | minimax/minimax-m2 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 204800 | 131072 | In: $0.26, Out: $1.02 | | minimax/minimax-m2.1 | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 204800 | 131072 | In: $0.30, Out: $1.20, Cache Read: $0.03 | | minimax/minimax-m2.5 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 204800 | 196608 | In: $0.22, Out: $0.90, Cache Read: $0.05 | | minimax/minimax-m2.7 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 204800 | 131072 | In: $0.27, Out: $1.08, Cache Read: $0.05 | | minimax/minimax-m3 | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 1048576 | 512000 | In: $0.30, Out: $1.20, Cache Read: $0.06 | | minimax/minimax-m3:batch | openrouter | In: text, image, video; Out: text | streaming, function_calling, structured_output, predicted_outputs | 524288 | - | In: $0.15, Out: $0.60, Cache Read: $0.03 | | mistralai/ministral-14b-2512 | openrouter | In: text, image; Out: text | function_calling, structured_output, vision, streaming | 262144 | 262144 | In: $0.20, Out: $0.20, Cache Read: $0.02 | | mistralai/ministral-3b-2512 | openrouter | In: text, image; Out: text | function_calling, structured_output, vision, streaming | 131072 | 131072 | In: $0.10, Out: $0.10, Cache Read: $0.01 | | mistralai/ministral-8b-2512 | openrouter | In: text, image; Out: text | function_calling, structured_output, vision, streaming | 262144 | 262144 | In: $0.15, Out: $0.15, Cache Read: $0.02 | | mistralai/mistral-large | openrouter | In: text, pdf; Out: text | function_calling, structured_output, vision, streaming | 128000 | 128000 | In: $2.00, Out: $6.00, Cache Read: $0.20 | | mistralai/mistral-large-2407 | openrouter | In: text, pdf; Out: text | function_calling, structured_output, vision, streaming | 131072 | 131072 | In: $2.00, Out: $6.00, Cache Read: $0.20 | | mistralai/mistral-large-2512 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 262144 | 262144 | In: $0.50, Out: $1.50, Cache Read: $0.05 | | mistralai/mistral-medium-3 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 131072 | 131072 | In: $0.40, Out: $2.00, Cache Read: $0.04 | | mistralai/mistral-medium-3.1 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 131072 | 262144 | In: $0.40, Out: $2.00, Cache Read: $0.04 | | mistralai/mistral-medium-3-5 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 262144 | 262144 | In: $1.50, Out: $7.50 | | mistralai/mistral-nemo | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 131072 | 16384 | In: $0.02, Out: $0.03 | | mistralai/mistral-small-24b-instruct-2501 | openrouter | In: text; Out: text | structured_output, streaming, predicted_outputs | 32768 | 16384 | In: $0.05, Out: $0.08 | | mistralai/mistral-small-3.1-24b-instruct | openrouter | In: text, image; Out: text | vision, streaming, predicted_outputs | 128000 | 128000 | In: $0.35, Out: $0.56 | | mistralai/mistral-small-3.2-24b-instruct | openrouter | In: image, text; Out: text | function_calling, structured_output, vision, streaming, predicted_outputs | 256000 | 16384 | In: $0.09, Out: $0.25 | | mistralai/mistral-small-2603 | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 262144 | 262144 | In: $0.15, Out: $0.60, Cache Read: $0.02 | | mistralai/mixtral-8x22b-instruct | openrouter | In: text, pdf; Out: text | function_calling, structured_output, vision, streaming | 65536 | 65536 | In: $2.00, Out: $6.00, Cache Read: $0.20 | | ~moonshotai/kimi-latest | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming, predicted_outputs | 1048576 | 1048576 | In: $2.50, Out: $14.00, Cache Read: $0.29 | | moonshotai/kimi-k2.7-code:batch | openrouter | In: text, image; Out: text | streaming, function_calling, structured_output, predicted_outputs | 262144 | - | In: $0.48, Out: $2.00, Cache Read: $0.10 | | morph/morph-v3-fast | openrouter | In: text; Out: text | streaming | 81920 | 38000 | In: $0.80, Out: $1.20 | | morph/morph-v3-large | openrouter | In: text; Out: text | structured_output, streaming | 262144 | 131072 | In: $0.90, Out: $1.90 | | meta/muse-spark-1.1 | openrouter | In: text, image, video, pdf, audio; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 1048576 | In: $1.25, Out: $4.25, Cache Read: $0.15 | | meta/muse-spark-1.2 | openrouter | In: text, image, video, pdf, audio; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 1048576 | In: $1.25, Out: $4.25, Cache Read: $0.15 | | gryphe/mythomax-l2-13b | openrouter | In: text; Out: text | structured_output, streaming, predicted_outputs | 8192 | 4096 | In: $0.08, Out: $0.11 | | nvidia/nemotron-3-ultra-550b-a55b:batch | openrouter | In: text; Out: text | streaming, function_calling, structured_output, predicted_outputs | 512288 | - | In: $0.30, Out: $1.80, Cache Read: $0.10 | | google/gemini-2.5-flash-image | openrouter | In: text, image; Out: text, image | structured_output, vision, streaming | 32768 | 8192 | In: $0.30, Out: $2.50, Cache Read: $0.03, Cache Write: $0.08 | | google/gemini-3.1-flash-image | openrouter | In: text, image; Out: text, image | structured_output, reasoning, vision, streaming | 131072 | 32768 | In: $0.50, Out: $3.00 | | google/gemini-3.1-flash-image-preview | openrouter | In: image, text; Out: text, image | structured_output, reasoning, vision, streaming | 65536 | 65536 | In: $0.50, Out: $3.00 | | google/gemini-3.1-flash-lite-image | openrouter | In: text, image; Out: text, image | reasoning, vision, streaming | 65536 | 65536 | In: $0.25, Out: $1.50 | | google/gemini-3-pro-image | openrouter | In: text, image; Out: text, image | function_calling, structured_output, reasoning, vision, streaming | 131072 | 32768 | In: $2.00, Out: $12.00, Cache Read: $0.20, Cache Write: $0.38 | | google/gemini-3-pro-image-preview | openrouter | In: text, image; Out: text, image | structured_output, reasoning, vision, streaming | 65536 | 32768 | In: $2.00, Out: $12.00, Cache Read: $0.20, Cache Write: $0.38 | | nvidia/nemotron-3-nano-30b-a3b | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 262144 | 262144 | In: $0.05, Out: $0.20, Cache Read: $0.03 | | nvidia/nemotron-3-nano-30b-a3b:free | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 256000 | 256000 | In: $0.00, Out: $0.00 | | nvidia/nemotron-3-nano-omni-30b-a3b-reasoning:free | openrouter | In: text, image, video, audio; Out: text | function_calling, reasoning, vision, video, streaming | 256000 | 65536 | In: $0.00, Out: $0.00 | | nvidia/nemotron-3-super-120b-a12b:free | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 262144 | 262144 | In: $0.00, Out: $0.00 | | nvidia/nemotron-3-super-120b-a12b | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 1000000 | 16384 | In: $0.08, Out: $0.40 | | nvidia/nemotron-3-ultra-550b-a55b:free | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 1000000 | 65536 | In: $0.00, Out: $0.00 | | nvidia/nemotron-3-ultra-550b-a55b | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 512288 | 16384 | In: $0.60, Out: $3.60, Cache Read: $0.20 | | nvidia/nemotron-3.5-content-safety:free | openrouter | In: text, image; Out: text | reasoning, vision, streaming | 128000 | 8192 | In: $0.00, Out: $0.00 | | nvidia/nemotron-nano-12b-v2-vl:free | openrouter | In: text, image, video; Out: text | function_calling, reasoning, vision, video, streaming | 128000 | 128000 | In: $0.00, Out: $0.00 | | nvidia/nemotron-nano-9b-v2:free | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 128000 | 128000 | In: $0.00, Out: $0.00 | | nex-agi/nex-n2-mini | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 262144 | 262144 | In: $0.02, Out: $0.10, Cache Read: $0.00 | | nex-agi/nex-n2-pro | openrouter | In: text, image; Out: text | function_calling, reasoning, vision, streaming | 262144 | 262144 | In: $0.25, Out: $1.00, Cache Read: $0.02 | | cohere/north-mini-code:free | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 256000 | 64000 | In: $0.00, Out: $0.00 | | amazon/nova-2-lite-v1 | openrouter | In: text, image, video, pdf; Out: text | function_calling, reasoning, vision, video, streaming | 1000000 | 65535 | In: $0.30, Out: $2.50 | | amazon/nova-lite-v1 | openrouter | In: text, image; Out: text | function_calling, vision, streaming | 300000 | 5120 | In: $0.06, Out: $0.24 | | amazon/nova-micro-v1 | openrouter | In: text; Out: text | function_calling, streaming | 128000 | 5120 | In: $0.04, Out: $0.14 | | amazon/nova-premier-v1 | openrouter | In: text, image; Out: text | function_calling, vision, streaming | 1000000 | 32000 | In: $2.50, Out: $12.50, Cache Read: $0.62 | | amazon/nova-pro-v1 | openrouter | In: text, image; Out: text | function_calling, vision, streaming | 300000 | 5120 | In: $0.80, Out: $3.20 | | allenai/olmo-3-32b-think | openrouter | In: text; Out: text | structured_output, reasoning, streaming, predicted_outputs | 65536 | 65536 | In: $0.15, Out: $0.50 | | ~openai/gpt-latest | openrouter | In: pdf, image, text; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $5.00, Out: $30.00, Cache Read: $0.50, Cache Write: $6.25 | | ~openai/gpt-mini-latest | openrouter | In: pdf, image, text; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $0.75, Out: $4.50, Cache Read: $0.08 | | openai/gpt-3.5-turbo:batch | openrouter | In: text; Out: text | streaming, function_calling, structured_output | 16385 | 4096 | In: $0.25, Out: $0.75 | | openai/gpt-4-turbo:batch | openrouter | In: text, image; Out: text | streaming, function_calling, structured_output | 128000 | 4096 | In: $5.00, Out: $15.00 | | openai/gpt-4.1:batch | openrouter | In: image, text, file; Out: text | streaming, function_calling, structured_output | 1047576 | 32768 | In: $1.00, Out: $4.00, Cache Read: $0.25 | | openai/gpt-4.1-mini:batch | openrouter | In: image, text, file; Out: text | streaming, function_calling, structured_output | 1047576 | 32768 | In: $0.20, Out: $0.80, Cache Read: $0.05 | | openai/gpt-4.1-nano:batch | openrouter | In: image, text, file; Out: text | streaming, function_calling, structured_output | 1047576 | 32768 | In: $0.05, Out: $0.20, Cache Read: $0.01 | | openai/gpt-4o:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 128000 | 16384 | In: $1.25, Out: $5.00, Cache Read: $0.62 | | openai/gpt-4o-mini:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 128000 | 16384 | In: $0.08, Out: $0.30, Cache Read: $0.04 | | openai/gpt-5:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 400000 | 128000 | In: $0.62, Out: $5.00, Cache Read: $0.06 | | openai/gpt-5-codex:batch | openrouter | In: text, image; Out: text | streaming, function_calling, structured_output | 400000 | 128000 | In: $0.62, Out: $5.00, Cache Read: $0.06 | | openai/gpt-5-mini:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 400000 | 128000 | In: $0.12, Out: $1.00, Cache Read: $0.01 | | openai/gpt-5-nano:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 400000 | 128000 | In: $0.02, Out: $0.20, Cache Read: $0.00 | | openai/gpt-5-pro:batch | openrouter | In: image, text, file; Out: text | streaming, function_calling, structured_output | 400000 | 128000 | In: $7.50, Out: $60.00 | | openai/gpt-5.1:batch | openrouter | In: image, text, file; Out: text | streaming, function_calling, structured_output | 400000 | 128000 | In: $0.62, Out: $5.00, Cache Read: $0.06 | | openai/gpt-5.2:batch | openrouter | In: file, image, text; Out: text | streaming, function_calling, structured_output | 400000 | 128000 | In: $0.88, Out: $7.00, Cache Read: $0.09 | | openai/gpt-5.2-pro:batch | openrouter | In: image, text, file; Out: text | streaming, function_calling, structured_output | 400000 | 128000 | In: $10.50, Out: $84.00 | | openai/gpt-5.4:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 1050000 | 128000 | In: $1.25, Out: $7.50, Cache Read: $0.12 | | openai/gpt-5.4-mini:batch | openrouter | In: file, image, text; Out: text | streaming, function_calling, structured_output | 400000 | 128000 | In: $0.38, Out: $2.25, Cache Read: $0.04 | | openai/gpt-5.4-nano:batch | openrouter | In: file, image, text; Out: text | streaming, function_calling, structured_output | 400000 | 128000 | In: $0.10, Out: $0.62, Cache Read: $0.01 | | openai/gpt-5.4-pro:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 1050000 | 128000 | In: $15.00, Out: $90.00 | | openai/gpt-5.5:batch | openrouter | In: file, image, text; Out: text | streaming, function_calling, structured_output | 1050000 | 128000 | In: $2.50, Out: $15.00, Cache Read: $0.25 | | openai/gpt-5.5-pro:batch | openrouter | In: file, image, text; Out: text | streaming, function_calling, structured_output | 1050000 | 128000 | In: $15.00, Out: $90.00 | | openai/gpt-5.6-luna:batch | openrouter | In: file, image, text; Out: text | streaming, function_calling, structured_output | 1050000 | 128000 | In: $0.10, Out: $0.60, Cache Read: $0.01 | | openai/gpt-5.6-luna-pro:batch | openrouter | In: file, image, text; Out: text | streaming, function_calling, structured_output | 1050000 | 128000 | In: $0.10, Out: $0.60, Cache Read: $0.01 | | openai/gpt-5.6-sol:batch | openrouter | In: file, image, text; Out: text | streaming, function_calling, structured_output | 1050000 | 128000 | In: $2.50, Out: $15.00, Cache Read: $0.25 | | openai/gpt-5.6-sol-pro:batch | openrouter | In: file, image, text; Out: text | streaming, function_calling, structured_output | 1050000 | 128000 | In: $2.50, Out: $15.00, Cache Read: $0.25 | | openai/gpt-5.6-terra:batch | openrouter | In: file, image, text; Out: text | streaming, function_calling, structured_output | 1050000 | 128000 | In: $1.00, Out: $6.00, Cache Read: $0.10 | | openai/gpt-5.6-terra-pro:batch | openrouter | In: file, image, text; Out: text | streaming, function_calling, structured_output | 1050000 | 128000 | In: $1.00, Out: $6.00, Cache Read: $0.10 | | openai/o1:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 200000 | 100000 | In: $7.50, Out: $30.00, Cache Read: $3.75 | | openai/o1-pro:batch | openrouter | In: text, image, file; Out: text | streaming, structured_output | 200000 | 100000 | In: $75.00, Out: $300.00 | | openai/o3:batch | openrouter | In: image, text, file; Out: text | streaming, function_calling, structured_output | 200000 | 100000 | In: $1.00, Out: $4.00, Cache Read: $0.25 | | openai/o3-mini:batch | openrouter | In: text, file; Out: text | streaming, function_calling, structured_output | 200000 | 100000 | In: $0.55, Out: $2.20, Cache Read: $0.28 | | openai/o3-mini-high:batch | openrouter | In: text, file; Out: text | streaming, function_calling, structured_output | 200000 | 100000 | In: $0.55, Out: $2.20, Cache Read: $0.28 | | openai/o3-pro:batch | openrouter | In: text, file, image; Out: text | streaming, function_calling, structured_output | 200000 | 100000 | In: $10.00, Out: $40.00 | | openai/o4-mini:batch | openrouter | In: image, text, file; Out: text | streaming, function_calling, structured_output | 200000 | 100000 | In: $0.55, Out: $2.20, Cache Read: $0.14 | | openai/o4-mini-high:batch | openrouter | In: image, text, file; Out: text | streaming, function_calling, structured_output | 200000 | 100000 | In: $0.55, Out: $2.20, Cache Read: $0.14 | | writer/palmyra-x5 | openrouter | In: text; Out: text | streaming | 1040000 | 8192 | In: $0.60, Out: $6.00 | | openrouter/pareto-code | openrouter | In: text; Out: text | streaming | 2000000 | 200000 | - | | perceptron/perceptron-mk1 | openrouter | In: text, image, video; Out: text | structured_output, reasoning, vision, video, streaming | 32768 | 8192 | In: $0.15, Out: $1.50 | | microsoft/phi-4 | openrouter | In: text; Out: text | structured_output, streaming, predicted_outputs | 16384 | 16384 | In: $0.07, Out: $0.14 | | qwen/qwen-plus | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 1000000 | 32768 | In: $0.26, Out: $0.78, Cache Read: $0.05, Cache Write: $0.32 | | qwen/qwen-plus-2025-07-28 | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 1000000 | 32768 | In: $0.26, Out: $0.78 | | qwen/qwen-plus-2025-07-28:thinking | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 1000000 | 32768 | In: $0.40, Out: $1.20, Cache Write: $0.50 | | qwen/qwen-2.5-72b-instruct | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 32768 | 16384 | In: $0.36, Out: $0.40 | | qwen/qwen-2.5-7b-instruct | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 32768 | 32768 | In: $0.10, Out: $0.20 | | qwen/qwen-2.5-coder-32b-instruct | openrouter | In: text; Out: text | streaming, predicted_outputs | 32768 | 32768 | In: $0.66, Out: $1.00 | | qwen/qwen2.5-vl-72b-instruct | openrouter | In: text, image; Out: text | structured_output, vision, streaming, predicted_outputs | 128000 | 128000 | In: $0.25, Out: $0.75 | | qwen/qwen3-14b | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 131072 | 8192 | In: $0.23, Out: $0.91 | | qwen/qwen3-235b-a22b-2507 | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 262144 | 16384 | In: $0.09, Out: $0.55 | | qwen/qwen3-235b-a22b-thinking-2507 | openrouter | In: text; Out: text | function_calling, reasoning, streaming, predicted_outputs | 262144 | 32768 | In: $0.23, Out: $2.30 | | qwen/qwen3-235b-a22b | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 131072 | 8192 | In: $0.46, Out: $1.82 | | qwen/qwen3-30b-a3b | openrouter | In: text; Out: text | function_calling, reasoning, streaming, predicted_outputs | 131072 | 16384 | In: $0.12, Out: $0.50 | | qwen/qwen3-30b-a3b-instruct-2507 | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 262144 | 32000 | In: $0.05, Out: $0.19 | | qwen/qwen3-30b-a3b-thinking-2507 | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 81920 | 32768 | In: $0.20, Out: $2.40 | | qwen/qwen3-32b | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 131072 | 16384 | In: $0.08, Out: $0.28 | | qwen/qwen3-8b | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 131072 | 8192 | In: $0.12, Out: $0.46 | | qwen/qwen3-coder | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 262144 | 65536 | In: $0.30, Out: $1.00, Cache Read: $0.10 | | qwen/qwen3-coder-flash | openrouter | In: text; Out: text | function_calling, streaming | 1000000 | 65536 | In: $0.20, Out: $0.98, Cache Read: $0.04, Cache Write: $0.24 | | qwen/qwen3-coder-next | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 262144 | 262144 | In: $0.12, Out: $0.80, Cache Read: $0.07 | | qwen/qwen3-coder-plus | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 1000000 | 65536 | In: $0.65, Out: $3.25, Cache Read: $0.13, Cache Write: $0.81 | | qwen/qwen3-max | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 262144 | 65536 | In: $0.78, Out: $3.90, Cache Read: $0.16, Cache Write: $0.98 | | qwen/qwen3-max-thinking | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 262144 | 65536 | In: $0.78, Out: $3.90 | | qwen/qwen3-vl-235b-a22b-instruct | openrouter | In: text, image; Out: text | function_calling, structured_output, vision, streaming, predicted_outputs | 262144 | 32768 | In: $0.21, Out: $1.90, Cache Read: $0.10 | | qwen/qwen3-vl-235b-a22b-thinking | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 131072 | 32768 | In: $0.40, Out: $4.00 | | qwen/qwen3-vl-30b-a3b-instruct | openrouter | In: text, image; Out: text | function_calling, structured_output, vision, streaming, predicted_outputs | 262144 | 16384 | In: $0.15, Out: $0.60 | | qwen/qwen3-vl-30b-a3b-thinking | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 262144 | 32768 | In: $0.20, Out: $2.40 | | qwen/qwen3-vl-32b-instruct | openrouter | In: text, image; Out: text | function_calling, structured_output, vision, streaming | 131072 | 32768 | In: $0.10, Out: $0.42 | | qwen/qwen3-vl-8b-instruct | openrouter | In: image, text; Out: text | function_calling, structured_output, vision, streaming, predicted_outputs | 262144 | 32768 | In: $0.12, Out: $0.46 | | qwen/qwen3-vl-8b-thinking | openrouter | In: image, text; Out: text | function_calling, structured_output, reasoning, vision, streaming | 131072 | 32768 | In: $0.18, Out: $2.10 | | qwen/qwen3-coder-30b-a3b-instruct | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 262144 | 32768 | In: $0.07, Out: $0.27 | | qwen/qwen3-next-80b-a3b-thinking | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 262144 | 262144 | In: $0.15, Out: $1.20 | | qwen/qwen3-next-80b-a3b-instruct | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 262144 | 16384 | In: $0.09, Out: $1.10 | | qwen/qwen3.5-122b-a10b | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 262144 | 81920 | In: $0.29, Out: $2.40 | | qwen/qwen3.5-27b | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 262144 | 65536 | In: $0.20, Out: $1.56 | | qwen/qwen3.5-35b-a3b | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 262144 | 262144 | In: $0.14, Out: $1.00 | | qwen/qwen3.5-397b-a17b | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 262144 | 65536 | In: $0.39, Out: $2.34 | | qwen/qwen3.5-9b | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 262144 | 262144 | In: $0.10, Out: $0.15 | | qwen/qwen3.5-plus-02-15 | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1000000 | 65536 | In: $0.26, Out: $1.56 | | qwen/qwen3.5-plus-20260420 | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1000000 | 65536 | In: $0.30, Out: $1.80, Cache Write: $0.38 | | qwen/qwen3.5-flash-02-23 | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1000000 | 65536 | In: $0.06, Out: $0.26 | | qwen/qwen3.6-27b | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 262144 | 262144 | In: $0.60, Out: $3.60, Cache Read: $0.12 | | qwen/qwen3.6-35b-a3b | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 262144 | 262144 | In: $0.14, Out: $1.00, Cache Read: $0.05 | | qwen/qwen3.6-flash | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1000000 | 65536 | In: $0.19, Out: $1.12, Cache Write: $0.23 | | qwen/qwen3.6-max-preview | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 262144 | 65536 | In: $1.03, Out: $6.16, Cache Write: $1.28 | | qwen/qwen3.6-plus | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1000000 | 65536 | In: $0.32, Out: $1.95, Cache Write: $0.41 | | qwen/qwen3.7-flash | openrouter | In: text, image, video; Out: text | function_calling, reasoning, vision, video, streaming | 1000000 | 65536 | In: $0.03, Out: $0.13, Cache Read: $0.01, Cache Write: $0.04 | | qwen/qwen3.7-max | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 1000000 | 131072 | In: $1.48, Out: $4.42, Cache Read: $0.30, Cache Write: $1.84 | | qwen/qwen3.7-plus | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 131072 | In: $0.32, Out: $1.28, Cache Read: $0.06, Cache Write: $0.40 | | qwen/qwen3.8-max | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1000000 | 131072 | In: $2.00, Out: $6.00, Cache Read: $0.25, Cache Write: $2.50 | | deepseek/deepseek-r1-0528 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 163840 | 32768 | In: $0.50, Out: $2.15, Cache Read: $0.35 | | deepseek/deepseek-r1-distill-llama-70b | openrouter | In: text; Out: text | reasoning, streaming | 8192 | 8192 | In: $0.80, Out: $0.80 | | undi95/remm-slerp-l2-13b | openrouter | In: text; Out: text | structured_output, streaming, predicted_outputs | 6144 | 6144 | In: $0.45, Out: $0.65 | | rekaai/reka-edge | openrouter | In: image, text, video; Out: text | function_calling, structured_output, vision, video, streaming | 16384 | 16384 | In: $0.10, Out: $0.10 | | rekaai/reka-flash-3 | openrouter | In: text; Out: text | structured_output, reasoning, streaming | 65536 | 65536 | In: $0.10, Out: $0.20 | | relace/relace-apply-3 | openrouter | In: text; Out: text | streaming | 256000 | 128000 | In: $0.85, Out: $1.25 | | relace/relace-search | openrouter | In: text; Out: text | function_calling, streaming | 256000 | 128000 | In: $1.00, Out: $3.00 | | inclusionai/ring-2.6-1t | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 262144 | 65536 | In: $0.08, Out: $0.62, Cache Read: $0.02 | | thedrummer/rocinante-12b | openrouter | In: text; Out: text | structured_output, streaming, predicted_outputs | 65536 | 65536 | In: $0.25, Out: $0.50 | | mistralai/mistral-saba | openrouter | In: text, pdf; Out: text | function_calling, structured_output, vision, streaming | 32768 | 32768 | In: $0.20, Out: $0.60, Cache Read: $0.02 | | bytedance-seed/seed-1.6 | openrouter | In: image, text, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 262144 | 32768 | In: $0.25, Out: $2.00 | | bytedance-seed/seed-1.6-flash | openrouter | In: image, text, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 262144 | 32768 | In: $0.08, Out: $0.30 | | bytedance-seed/seed-2.0-lite | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 262144 | 131072 | In: $0.25, Out: $2.00 | | bytedance-seed/seed-2.0-mini | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 262144 | 131072 | In: $0.10, Out: $0.40 | | thedrummer/skyfall-36b-v2 | openrouter | In: text; Out: text | structured_output, streaming, predicted_outputs | 32768 | 32768 | In: $0.55, Out: $0.80, Cache Read: $0.25 | | upstage/solar-pro-3 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 131072 | 131072 | In: $0.15, Out: $0.60, Cache Read: $0.02 | | perplexity/sonar | openrouter | In: text, image; Out: text | vision, streaming | 127072 | 127072 | In: $1.00, Out: $1.00 | | perplexity/sonar-deep-research | openrouter | In: text; Out: text | reasoning, streaming | 128000 | 128000 | In: $2.00, Out: $8.00 | | perplexity/sonar-pro | openrouter | In: text, image; Out: text | vision, streaming | 200000 | 8000 | In: $3.00, Out: $15.00 | | perplexity/sonar-pro-search | openrouter | In: text, image; Out: text | structured_output, reasoning, vision, streaming | 200000 | 8000 | In: $3.00, Out: $15.00 | | perplexity/sonar-reasoning-pro | openrouter | In: text, image; Out: text | reasoning, vision, streaming | 128000 | 128000 | In: $2.00, Out: $8.00 | | stepfun/step-3.5-flash | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 262144 | 65536 | In: $0.10, Out: $0.30 | | stepfun/step-3.7-flash | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 262144 | 256000 | In: $0.20, Out: $1.15, Cache Read: $0.04 | | thinkingmachines/inkling:batch | openrouter | In: text, image, audio; Out: text | streaming, function_calling, predicted_outputs | 524288 | - | In: $0.50, Out: $2.02, Cache Read: $0.08 | | arcee-ai/trinity-large-thinking | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 262144 | 262144 | In: $0.22, Out: $0.85, Cache Read: $0.06 | | bytedance/ui-tars-1.5-7b | openrouter | In: image, text; Out: text | structured_output, vision, streaming, predicted_outputs | 128000 | 2048 | In: $0.10, Out: $0.20, Cache Read: $0.10 | | cognitivecomputations/dolphin-mistral-24b-venice-edition | openrouter | In: text; Out: text | streaming | 128000 | 8192 | In: $0.20, Out: $0.90 | | thedrummer/unslopnemo-12b | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 1024000 | 1024000 | In: $0.40, Out: $0.40 | | arcee-ai/virtuoso-large | openrouter | In: text; Out: text | function_calling, streaming, predicted_outputs | 131072 | 64000 | In: $0.75, Out: $1.20 | | mistralai/voxtral-small-24b-2507 | openrouter | In: text, audio, pdf; Out: text | function_calling, structured_output, vision, streaming | 32000 | 32000 | In: $0.10, Out: $0.30, Cache Read: $0.01 | | mancer/weaver | openrouter | In: text; Out: text | structured_output, streaming, predicted_outputs | 8000 | 6000 | In: $0.50, Out: $0.75 | | microsoft/wizardlm-2-8x22b | openrouter | In: text; Out: text | streaming | 65535 | 8000 | In: $0.62, Out: $0.62 | | z-ai/glm-5.2:batch | openrouter | In: text; Out: text | streaming, function_calling, structured_output, predicted_outputs | 512000 | - | In: $0.70, Out: $2.20, Cache Read: $0.13 | | openai/gpt-oss-20b:free | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 131072 | 32768 | In: $0.00, Out: $0.00 | | openai/gpt-oss-safeguard-20b | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 131072 | 65536 | In: $0.08, Out: $0.30, Cache Read: $0.04 | | openai/o1 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 100000 | In: $15.00, Out: $60.00, Cache Read: $7.50 | | openai/o1-pro | openrouter | In: text, image, pdf; Out: text | structured_output, reasoning, vision, streaming | 200000 | 100000 | In: $150.00, Out: $600.00 | | openai/o3 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 100000 | In: $2.00, Out: $8.00, Cache Read: $0.50 | | openai/o3-mini-high | openrouter | In: text, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 100000 | In: $1.10, Out: $4.40, Cache Read: $0.55 | | openai/o3-mini | openrouter | In: text, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 100000 | In: $1.10, Out: $4.40, Cache Read: $0.55 | | openai/o3-pro | openrouter | In: text, pdf, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 100000 | In: $20.00, Out: $80.00 | | openai/o4-mini-high | openrouter | In: image, text, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 100000 | In: $1.10, Out: $4.40, Cache Read: $0.28 | | openai/o4-mini | openrouter | In: image, text, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 100000 | In: $1.10, Out: $4.40, Cache Read: $0.28 | ### Perplexity (5) | Model | Provider | I/O | Capabilities | Context | Max Output | Standard Pricing (per 1M tokens) | | :-- | :-- | :-- | :-- | --: | --: | :-- | | sonar-deep-research | perplexity | In: text; Out: text | reasoning, citations | 128000 | 32768 | In: $2.00, Out: $8.00 | | sonar | perplexity | In: text; Out: text | citations | 128000 | 4096 | In: $1.00, Out: $1.00 | | sonar-pro | perplexity | In: text, image; Out: text | vision, citations | 200000 | 8192 | In: $3.00, Out: $15.00 | | sonar-reasoning-pro | perplexity | In: text, image; Out: text | reasoning, vision, citations | 128000 | 4096 | In: $2.00, Out: $8.00 | | sonar-reasoning | perplexity | In: -; Out: - | citations, vision, reasoning | 128000 | 4096 | In: $1.00, Out: $5.00 | ### VertexAI (69) | Model | Provider | I/O | Capabilities | Context | Max Output | Standard Pricing (per 1M tokens) | | :-- | :-- | :-- | :-- | --: | --: | :-- | | claude-3-5-haiku | vertexai | In: text, image, pdf; Out: text | function_calling, vision | 200000 | 8192 | In: $0.80, Out: $4.00, Cache Read: $0.08, Cache Write: $1.00 | | claude-haiku-4-5 | vertexai | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 200000 | 64000 | In: $1.00, Out: $5.00, Cache Read: $0.10, Cache Write: $1.25 | | claude-opus-4 | vertexai | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 200000 | 32000 | In: $15.00, Out: $75.00, Cache Read: $1.50, Cache Write: $18.75 | | claude-opus-4-1 | vertexai | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 200000 | 32000 | In: $15.00, Out: $75.00, Cache Read: $1.50, Cache Write: $18.75 | | claude-opus-4-5 | vertexai | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 200000 | 64000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | claude-opus-4-6 | vertexai | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | claude-opus-4-7 | vertexai | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | claude-opus-4-8 | vertexai | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | claude-opus-5 | vertexai | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | claude-sonnet-4 | vertexai | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 200000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | claude-sonnet-4-5 | vertexai | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 200000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | claude-sonnet-4-6 | vertexai | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 1000000 | 128000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | claude-sonnet-5 | vertexai | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 1000000 | 128000 | In: $2.00, Out: $10.00, Cache Read: $0.20, Cache Write: $2.50 | | deepseek-ai/deepseek-v3.1-maas | vertexai | In: text, pdf; Out: text | function_calling, structured_output, reasoning, vision | 163840 | 32768 | In: $0.60, Out: $1.70 | | deepseek-ai/deepseek-v3.2-maas | vertexai | In: text, pdf; Out: text | function_calling, structured_output, reasoning, vision | 163840 | 65536 | In: $0.56, Out: $1.68, Cache Read: $0.06 | | zai-org/glm-4.7-maas | vertexai | In: text, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 128000 | In: $0.60, Out: $2.20 | | zai-org/glm-5-maas | vertexai | In: text; Out: text | function_calling, reasoning | 202752 | 131072 | In: $1.00, Out: $3.20, Cache Read: $0.10 | | openai/gpt-oss-120b-maas | vertexai | In: text; Out: text | function_calling, reasoning | 131072 | 32768 | In: $0.09, Out: $0.36 | | openai/gpt-oss-20b-maas | vertexai | In: text; Out: text | function_calling, reasoning | 131072 | 32768 | In: $0.07, Out: $0.25 | | gemini-2.0-flash | vertexai | In: text, image, audio, video, pdf; Out: text | function_calling, structured_output, vision, video, streaming | 1048576 | 8192 | In: $0.10, Out: $0.40, Cache Read: $0.02 | | gemini-2.5-flash | vertexai | In: text, image, audio, video, pdf; Out: text | function_calling, reasoning, vision, video, streaming | 1048576 | 65536 | In: $0.30, Out: $2.50, Cache Read: $0.08, Cache Write: $0.38 | | gemini-2.5-flash-tts | vertexai | In: text; Out: audio | streaming | 32768 | 16384 | In: $0.50, Out: $10.00 | | gemini-2.5-flash-lite | vertexai | In: text, image, audio, video, pdf; Out: text | function_calling, reasoning, vision, video, streaming | 1048576 | 65536 | In: $0.10, Out: $0.40, Cache Read: $0.01 | | gemini-2.5-pro | vertexai | In: text, image, audio, video, pdf; Out: text | function_calling, reasoning, vision, video, streaming | 1048576 | 65536 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gemini-2.5-pro-tts | vertexai | In: text; Out: audio | streaming | 32768 | 16384 | In: $1.00, Out: $20.00 | | gemini-3-flash-preview | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $0.50, Out: $3.00, Cache Read: $0.05 | | gemini-3.1-flash-lite | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $0.25, Out: $1.50, Cache Read: $0.02 | | gemini-3.1-flash-lite-preview | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $0.25, Out: $1.50, Cache Read: $0.02 | | gemini-3.1-pro-preview | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $2.00, Out: $12.00, Cache Read: $0.20 | | gemini-3.1-pro-preview-customtools | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video | 1048576 | 65536 | In: $2.00, Out: $12.00, Cache Read: $0.20 | | gemini-3.5-flash | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $1.50, Out: $9.00, Cache Read: $0.15 | | gemini-3.5-flash-lite | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video | 1048576 | 65536 | In: $0.30, Out: $2.50, Cache Read: $0.03 | | gemini-3.6-flash | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video | 1048576 | 65536 | In: $1.50, Out: $7.50, Cache Read: $0.15 | | gemini-embedding-001 | vertexai | In: text; Out: embeddings | streaming | 2048 | 1 | In: $0.15, Out: $0.00 | | gemini-embedding-2 | vertexai | In: text, image, audio, video, pdf; Out: embeddings | vision, video, streaming | 8192 | 1 | In: $0.20, Out: $0.00 | | gemini-flash-latest | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video | 1048576 | 65536 | In: $1.50, Out: $9.00, Cache Read: $0.15 | | gemini-flash-lite-latest | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, reasoning, vision, video | 1048576 | 65536 | In: $0.25, Out: $1.50, Cache Read: $0.02 | | moonshotai/kimi-k2-thinking-maas | vertexai | In: text; Out: text | function_calling, structured_output, reasoning | 262144 | 262144 | In: $0.60, Out: $2.50 | | meta/llama-3.3-70b-instruct-maas | vertexai | In: text; Out: text | function_calling, structured_output | 128000 | 8192 | In: $0.72, Out: $0.72 | | meta/llama-4-maverick-17b-128e-instruct-maas | vertexai | In: text, image; Out: text | function_calling, structured_output, vision | 524288 | 8192 | In: $0.35, Out: $1.15 | | gemini-2.5-flash-image | vertexai | In: text, image; Out: text, image | vision | 32768 | 32768 | In: $0.30, Out: $30.00 | | gemini-3.1-flash-image | vertexai | In: text, image, video, pdf; Out: text, image | reasoning, vision, video, streaming | 131072 | 32768 | In: $0.50, Out: $60.00 | | gemini-3.1-flash-image-preview | vertexai | In: text, image, pdf; Out: text, image | reasoning, vision, streaming | 65536 | 65536 | In: $0.50, Out: $60.00 | | gemini-3.1-flash-lite-image | vertexai | In: text, image; Out: text, image | function_calling, reasoning, vision, streaming | 65536 | 65536 | In: $0.25, Out: $30.00 | | gemini-3-pro-image | vertexai | In: text, image; Out: text, image | reasoning, vision, streaming | 65536 | 32768 | In: $2.00, Out: $120.00 | | qwen/qwen3-235b-a22b-instruct-2507-maas | vertexai | In: text; Out: text | function_calling, structured_output, reasoning | 262144 | 16384 | In: $0.22, Out: $0.88 | | claude-fable-5 | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | codestral-2 | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | gemini-1.5-flash | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | gemini-1.5-flash-002 | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | gemini-1.5-flash-8b | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | gemini-1.5-pro | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | gemini-1.5-pro-002 | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | gemini-2.0-flash-001 | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | gemini-2.0-flash-exp | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | gemini-2.0-flash-lite-001 | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | gemini-2.5-flash-preview-04-17 | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | gemini-2.5-pro-exp-03-25 | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | gemini-exp-1121 | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | gemini-exp-1206 | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | gemini-live-2.5-flash-native-audio | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | gemini-pro | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | gemini-pro-vision | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | mistral-medium-3 | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | mistral-ocr-2505 | vertexai | In: -; Out: - | streaming | - | - | - | | mistral-small-2503 | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | text-embedding-004 | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | text-embedding-005 | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | text-multilingual-embedding-002 | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | ### XAI (10) | Model | Provider | I/O | Capabilities | Context | Max Output | Standard Pricing (per 1M tokens) | | :-- | :-- | :-- | :-- | --: | --: | :-- | | grok-4.20-0309-non-reasoning | xai | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 1000000 | 30000 | In: $1.25, Out: $2.50, Cache Read: $0.20 | | grok-4.20-0309-reasoning | xai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 30000 | In: $1.25, Out: $2.50, Cache Read: $0.20 | | grok-4.20-multi-agent-0309 | xai | In: text, image, pdf; Out: text | structured_output, reasoning, vision, streaming | 1000000 | 30000 | In: $1.25, Out: $2.50, Cache Read: $0.20 | | grok-4.3 | xai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 30000 | In: $1.25, Out: $2.50, Cache Read: $0.20 | | grok-4.5 | xai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 500000 | 500000 | In: $2.00, Out: $6.00, Cache Read: $0.30 | | grok-build-0.1 | xai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 256000 | 256000 | In: $1.00, Out: $2.00, Cache Read: $0.20 | | grok-imagine-image | xai | In: text, image, pdf; Out: image | vision | 8000 | 0 | - | | grok-imagine-image-quality | xai | In: text, image, pdf; Out: image | vision | 8000 | 0 | - | | grok-imagine-video | xai | In: text, image, video, pdf; Out: video | vision, video | 1024 | 0 | - | | grok-imagine-video-1.5 | xai | In: text, image, audio, pdf; Out: video | vision | 1024 | 0 | - | ## Models by Capability ### Function Calling (794) | Model | Provider | I/O | Capabilities | Context | Max Output | Standard Pricing (per 1M tokens) | | :-- | :-- | :-- | :-- | --: | --: | :-- | | claude-fable-5 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, citations, tool_choice, parallel_tool_calls | 1000000 | 128000 | In: $10.00, Out: $50.00, Cache Read: $1.00, Cache Write: $12.50 | | claude-haiku-4-5-20251001 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, citations, tool_choice, parallel_tool_calls | 200000 | 64000 | In: $1.00, Out: $5.00, Cache Read: $0.10, Cache Write: $1.25 | | claude-haiku-4-5 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $1.00, Out: $5.00, Cache Read: $0.10, Cache Write: $1.25 | | claude-opus-4-5-20251101 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, citations, tool_choice, parallel_tool_calls | 200000 | 64000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | claude-opus-4-5 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | claude-opus-4-6 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, citations, tool_choice, parallel_tool_calls | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | claude-opus-4-7 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, citations, tool_choice, parallel_tool_calls | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | claude-opus-4-8 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, citations, tool_choice, parallel_tool_calls | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | claude-opus-5 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, citations, tool_choice, parallel_tool_calls | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | claude-sonnet-4-5-20250929 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, citations, tool_choice, parallel_tool_calls | 1000000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | claude-sonnet-4-5 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | claude-sonnet-4-6 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, citations, tool_choice, parallel_tool_calls | 1000000 | 128000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | claude-sonnet-5 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, citations, tool_choice, parallel_tool_calls | 1000000 | 128000 | In: $2.00, Out: $10.00, Cache Read: $0.20, Cache Write: $2.50 | | gpt-4 | azure | In: -; Out: - | function_calling, vision | 8192 | 8192 | In: $10.00, Out: $30.00 | | gpt-4-turbo-2024-04-09 | azure | In: -; Out: - | function_calling, vision | 128000 | 16384 | In: $10.00, Out: $30.00 | | gpt-4-turbo-jp | azure | In: -; Out: - | function_calling, vision | 128000 | 16384 | In: $10.00, Out: $30.00 | | gpt-4.1 | azure | In: -; Out: - | function_calling, structured_output, vision | 1047576 | 32768 | In: $2.00, Out: $8.00, Cache Read: $0.50 | | gpt-4.1-2025-04-14 | azure | In: -; Out: - | function_calling, structured_output, vision | 1047576 | 32768 | In: $2.00, Out: $8.00, Cache Read: $0.50 | | gpt-4.1-2025-04-14-text | azure | In: -; Out: - | function_calling, structured_output, vision | 1047576 | 32768 | In: $2.00, Out: $8.00, Cache Read: $0.50 | | gpt-4.1-mini | azure | In: -; Out: - | function_calling, structured_output, vision | 1047576 | 32768 | In: $0.40, Out: $1.60, Cache Read: $0.10 | | gpt-4.1-mini-2025-04-14 | azure | In: -; Out: - | function_calling, structured_output, vision | 1047576 | 32768 | In: $0.40, Out: $1.60, Cache Read: $0.10 | | gpt-4.1-nano | azure | In: -; Out: - | function_calling, structured_output, vision | 1047576 | 32768 | In: $0.10, Out: $0.40 | | gpt-4.1-nano-2025-04-14 | azure | In: -; Out: - | function_calling, structured_output, vision | 1047576 | 32768 | In: $0.10, Out: $0.40 | | gpt-4o | azure | In: -; Out: - | function_calling, structured_output, vision | 128000 | 16384 | In: $2.50, Out: $10.00 | | gpt-4o-2024-05-13 | azure | In: -; Out: - | function_calling, structured_output, vision | 128000 | 16384 | In: $2.50, Out: $10.00 | | gpt-4o-2024-08-06 | azure | In: -; Out: - | function_calling, structured_output, vision | 128000 | 16384 | In: $2.50, Out: $10.00 | | gpt-4o-2024-11-20 | azure | In: -; Out: - | function_calling, structured_output, vision | 128000 | 16384 | In: $2.50, Out: $10.00 | | gpt-4o-canvas-2024-09-25 | azure | In: -; Out: - | function_calling, structured_output, vision | 128000 | 16384 | In: $2.50, Out: $10.00 | | gpt-4o-mini | azure | In: -; Out: - | function_calling, structured_output, vision | 128000 | 16384 | In: $0.15, Out: $0.60 | | gpt-4o-mini-2024-07-18 | azure | In: -; Out: - | function_calling, structured_output, vision | 128000 | 16384 | In: $0.15, Out: $0.60 | | gpt-5-2025-08-07 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5-chat-2025-08-07 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5-chat-2025-08-15 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5-chat-2025-10-03 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5-codex-2025-09-15 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5-mini-2025-08-07 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $0.25, Out: $2.00, Cache Read: $0.02 | | gpt-5-mini-2025-08-07-lite | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $0.25, Out: $2.00, Cache Read: $0.02 | | gpt-5-mini-lite-2025-08-07 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $0.25, Out: $2.00, Cache Read: $0.02 | | gpt-5-nano-2025-08-07 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $0.05, Out: $0.40, Cache Read: $0.01 | | gpt-5-pro-2025-10-06 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.1 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.1-2025-11-13 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.1-chat-2025-11-13 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.1-codex-2025-11-13 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.1-codex-max-2025-12-04 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.1-codex-mini-2025-11-13 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $0.25, Out: $2.00, Cache Read: $0.02 | | gpt-5.2-2025-12-11 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.2-chat-2025-12-11 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.2-chat-2026-02-10 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.2-codex-2026-01-14 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.3-chat-2026-03-03 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.3-codex-2026-02-20 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.3-codex-2026-02-24 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.4-2026-03-05 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.4-mini-2026-03-17 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $0.25, Out: $2.00, Cache Read: $0.02 | | gpt-5.4-nano-2026-03-17 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $0.05, Out: $0.40, Cache Read: $0.01 | | gpt-5.4-pro-2026-03-05 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.5-2026-04-24 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | o1-2024-12-17 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 200000 | 100000 | In: $15.00, Out: $60.00 | | o1-pro | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 200000 | 100000 | In: $150.00, Out: $600.00 | | o1-pro-2025-03-19 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 200000 | 100000 | In: $150.00, Out: $600.00 | | o3-mini | azure | In: -; Out: - | function_calling, structured_output, reasoning | 200000 | 100000 | In: $1.10, Out: $4.40 | | o3-mini-2025-01-31 | azure | In: -; Out: - | function_calling, structured_output, reasoning | 200000 | 100000 | In: $1.10, Out: $4.40 | | o3-mini-alpha | azure | In: -; Out: - | function_calling, structured_output, reasoning | 200000 | 100000 | In: $1.10, Out: $4.40 | | o3-mini-alpha-2024-12-17 | azure | In: -; Out: - | function_calling, structured_output, reasoning | 200000 | 100000 | In: $1.10, Out: $4.40 | | au.anthropic.claude-opus-4-6-v1 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 128000 | In: $16.50, Out: $82.50, Cache Read: $1.65, Cache Write: $20.62 | | au.anthropic.claude-sonnet-4-6 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 128000 | In: $3.30, Out: $16.50, Cache Read: $0.33, Cache Write: $4.12 | | anthropic.claude-3-haiku-20240307-v1:0 | bedrock | In: text, image; Out: text | streaming, function_calling | - | - | - | | anthropic.claude-3-haiku-20240307-v1:0:200k | bedrock | In: text, image; Out: text | streaming, function_calling | - | - | - | | anthropic.claude-3-haiku-20240307-v1:0:48k | bedrock | In: text, image; Out: text | streaming, function_calling | - | - | - | | anthropic.claude-fable-5 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $10.00, Out: $50.00, Cache Read: $1.00, Cache Write: $12.50 | | eu.anthropic.claude-fable-5 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $11.00, Out: $55.00, Cache Read: $1.10, Cache Write: $13.75 | | global.anthropic.claude-fable-5 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $10.00, Out: $50.00, Cache Read: $1.00, Cache Write: $12.50 | | us.anthropic.claude-fable-5 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 1000000 | 128000 | In: $10.00, Out: $50.00, Cache Read: $1.00, Cache Write: $12.50 | | anthropic.claude-haiku-4-5-20251001-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $1.00, Out: $5.00, Cache Read: $0.10, Cache Write: $1.25 | | au.anthropic.claude-haiku-4-5-20251001-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $1.00, Out: $5.00, Cache Read: $0.10, Cache Write: $1.25 | | eu.anthropic.claude-haiku-4-5-20251001-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $1.10, Out: $5.50, Cache Read: $0.11, Cache Write: $1.38 | | global.anthropic.claude-haiku-4-5-20251001-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $1.00, Out: $5.00, Cache Read: $0.10, Cache Write: $1.25 | | jp.anthropic.claude-haiku-4-5-20251001-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $1.00, Out: $5.00, Cache Read: $0.10, Cache Write: $1.25 | | us.anthropic.claude-haiku-4-5-20251001-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 64000 | In: $1.00, Out: $5.00, Cache Read: $0.10, Cache Write: $1.25 | | anthropic.claude-opus-4-1-20250805-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 200000 | 32000 | In: $15.00, Out: $75.00, Cache Read: $1.50, Cache Write: $18.75 | | us.anthropic.claude-opus-4-1-20250805-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 200000 | 32000 | In: $15.00, Out: $75.00, Cache Read: $1.50, Cache Write: $18.75 | | anthropic.claude-opus-4-5-20251101-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | eu.anthropic.claude-opus-4-5-20251101-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $5.50, Out: $27.50, Cache Read: $0.55, Cache Write: $6.88 | | global.anthropic.claude-opus-4-5-20251101-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | us.anthropic.claude-opus-4-5-20251101-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 64000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | anthropic.claude-opus-4-6-v1 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | eu.anthropic.claude-opus-4-6-v1 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 128000 | In: $5.50, Out: $27.50, Cache Read: $0.55, Cache Write: $6.88 | | global.anthropic.claude-opus-4-6-v1 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | us.anthropic.claude-opus-4-6-v1 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | anthropic.claude-opus-4-7 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | eu.anthropic.claude-opus-4-7 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $5.50, Out: $27.50, Cache Read: $0.55, Cache Write: $6.88 | | global.anthropic.claude-opus-4-7 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | jp.anthropic.claude-opus-4-7 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | us.anthropic.claude-opus-4-7 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | anthropic.claude-opus-4-8 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | au.anthropic.claude-opus-4-8 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | eu.anthropic.claude-opus-4-8 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $5.50, Out: $27.50, Cache Read: $0.55, Cache Write: $6.88 | | global.anthropic.claude-opus-4-8 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | jp.anthropic.claude-opus-4-8 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | us.anthropic.claude-opus-4-8 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | anthropic.claude-opus-5 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | au.anthropic.claude-opus-5 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | eu.anthropic.claude-opus-5 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $5.50, Out: $27.50, Cache Read: $0.55, Cache Write: $6.88 | | global.anthropic.claude-opus-5 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | jp.anthropic.claude-opus-5 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | us.anthropic.claude-opus-5 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | us.anthropic.claude-sonnet-4-20250514-v1:0 | bedrock | In: text, image; Out: text | streaming, function_calling, reasoning | 200000 | 8192 | - | | anthropic.claude-sonnet-4-5-20250929-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | au.anthropic.claude-sonnet-4-5-20250929-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | eu.anthropic.claude-sonnet-4-5-20250929-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $3.30, Out: $16.50, Cache Read: $0.33, Cache Write: $4.12 | | global.anthropic.claude-sonnet-4-5-20250929-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | jp.anthropic.claude-sonnet-4-5-20250929-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | us.anthropic.claude-sonnet-4-5-20250929-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | anthropic.claude-sonnet-4-6 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | eu.anthropic.claude-sonnet-4-6 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 64000 | In: $3.30, Out: $16.50, Cache Read: $0.33, Cache Write: $4.12 | | global.anthropic.claude-sonnet-4-6 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | jp.anthropic.claude-sonnet-4-6 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | us.anthropic.claude-sonnet-4-6 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | anthropic.claude-sonnet-5 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 128000 | In: $2.00, Out: $10.00, Cache Read: $0.20, Cache Write: $2.50 | | au.anthropic.claude-sonnet-5 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 128000 | In: $2.00, Out: $10.00, Cache Read: $0.20, Cache Write: $2.50 | | eu.anthropic.claude-sonnet-5 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 128000 | In: $2.20, Out: $11.00, Cache Read: $0.22, Cache Write: $2.75 | | global.anthropic.claude-sonnet-5 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 128000 | In: $2.00, Out: $10.00, Cache Read: $0.20, Cache Write: $2.50 | | jp.anthropic.claude-sonnet-5 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 128000 | In: $2.00, Out: $10.00, Cache Read: $0.20, Cache Write: $2.50 | | us.anthropic.claude-sonnet-5 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $2.00, Out: $10.00, Cache Read: $0.20, Cache Write: $2.50 | | cohere.command-r-v1:0 | bedrock | In: text; Out: text | streaming, function_calling | - | - | - | | cohere.command-r-plus-v1:0 | bedrock | In: text; Out: text | streaming, function_calling | - | - | - | | deepseek.r1-v1:0 | bedrock | In: text; Out: text | function_calling, reasoning | 128000 | 32768 | In: $1.35, Out: $5.40 | | us.deepseek.r1-v1:0 | bedrock | In: text; Out: text | function_calling, reasoning, streaming | 128000 | 32768 | In: $1.35, Out: $5.40 | | deepseek.v3-v1:0 | bedrock | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 163840 | 81920 | In: $0.58, Out: $1.68 | | deepseek.v3.2 | bedrock | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 163840 | 81920 | In: $0.62, Out: $1.85 | | mistral.devstral-2-123b | bedrock | In: text; Out: text | function_calling, structured_output, streaming | 256000 | 8192 | In: $0.40, Out: $2.00 | | cohere.embed-english-v3 | bedrock | In: text; Out: embeddings | function_calling | - | - | - | | cohere.embed-english-v3:0:512 | bedrock | In: text; Out: embeddings | function_calling | - | - | - | | cohere.embed-multilingual-v3 | bedrock | In: text; Out: embeddings | function_calling | - | - | - | | cohere.embed-multilingual-v3:0:512 | bedrock | In: text; Out: embeddings | function_calling | - | - | - | | us.cohere.embed-v4:0 | bedrock | In: text, image; Out: embeddings | function_calling | 128000 | - | - | | zai.glm-4.7 | bedrock | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 204800 | 131072 | In: $0.60, Out: $2.20 | | zai.glm-4.7-flash | bedrock | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 200000 | 131072 | In: $0.07, Out: $0.40 | | zai.glm-5 | bedrock | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 202752 | 101376 | In: $1.00, Out: $3.20 | | openai.gpt-oss-safeguard-120b | bedrock | In: text; Out: text | function_calling, structured_output, streaming | 128000 | 16384 | In: $0.15, Out: $0.60 | | openai.gpt-oss-safeguard-20b | bedrock | In: text; Out: text | function_calling, structured_output, streaming | 128000 | 16384 | In: $0.07, Out: $0.20 | | openai.gpt-5.4 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 272000 | 128000 | In: $2.75, Out: $16.50, Cache Read: $0.28 | | openai.gpt-5.5 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 272000 | 128000 | In: $5.50, Out: $33.00, Cache Read: $0.55 | | openai.gpt-5.6-luna | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 272000 | 128000 | In: $0.22, Out: $1.32, Cache Read: $0.02, Cache Write: $0.28 | | openai.gpt-5.6-sol | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 272000 | 128000 | In: $5.50, Out: $33.00, Cache Read: $0.55, Cache Write: $6.88 | | openai.gpt-5.6-terra | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 272000 | 128000 | In: $2.20, Out: $13.20, Cache Read: $0.22, Cache Write: $2.75 | | google.gemma-3-4b-it | bedrock | In: text, image; Out: text | function_calling, vision, streaming | 128000 | 4096 | In: $0.04, Out: $0.08 | | google.gemma-3-27b-it | bedrock | In: text, image; Out: text | function_calling, structured_output, vision, streaming | 202752 | 8192 | In: $0.12, Out: $0.20 | | xai.grok-4.3 | bedrock | In: text, image; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 131072 | In: $1.25, Out: $2.50, Cache Read: $0.20 | | moonshot.kimi-k2-thinking | bedrock | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 262143 | 16000 | In: $0.60, Out: $2.50 | | moonshotai.kimi-k2.5 | bedrock | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 262143 | 16000 | In: $0.60, Out: $3.00 | | meta.llama3-70b-instruct-v1:0 | bedrock | In: text; Out: text | streaming, function_calling | - | - | - | | meta.llama3-8b-instruct-v1:0 | bedrock | In: text; Out: text | streaming, function_calling | - | - | - | | meta.llama3-1-70b-instruct-v1:0 | bedrock | In: text; Out: text | function_calling, streaming | 128000 | 4096 | In: $0.72, Out: $0.72 | | meta.llama3-1-70b-instruct-v1:0:128k | bedrock | In: text; Out: text | function_calling, streaming | 128000 | 4096 | In: $0.72, Out: $0.72 | | meta.llama3-1-8b-instruct-v1:0 | bedrock | In: text; Out: text | function_calling, streaming | 128000 | 4096 | In: $0.22, Out: $0.22 | | meta.llama3-1-8b-instruct-v1:0:128k | bedrock | In: text; Out: text | function_calling, streaming | 128000 | 4096 | In: $0.22, Out: $0.22 | | meta.llama3-3-70b-instruct-v1:0 | bedrock | In: text; Out: text | function_calling | 128000 | 4096 | In: $0.72, Out: $0.72 | | meta.llama3-3-70b-instruct-v1:0:128k | bedrock | In: text; Out: text | function_calling, streaming | 128000 | 4096 | In: $0.72, Out: $0.72 | | us.meta.llama3-3-70b-instruct-v1:0 | bedrock | In: text; Out: text | function_calling, streaming | 128000 | 4096 | In: $0.72, Out: $0.72 | | meta.llama4-maverick-17b-instruct-v1:0 | bedrock | In: text, image; Out: text | function_calling, vision | 1000000 | 16384 | In: $0.24, Out: $0.97 | | us.meta.llama4-maverick-17b-instruct-v1:0 | bedrock | In: text, image; Out: text | function_calling, vision, streaming | 1000000 | 16384 | In: $0.24, Out: $0.97 | | meta.llama4-scout-17b-instruct-v1:0 | bedrock | In: text, image; Out: text | function_calling, vision | 3500000 | 16384 | In: $0.17, Out: $0.66 | | us.meta.llama4-scout-17b-instruct-v1:0 | bedrock | In: text, image; Out: text | function_calling, vision, streaming | 3500000 | 16384 | In: $0.17, Out: $0.66 | | mistral.magistral-small-2509 | bedrock | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 128000 | 40000 | In: $0.50, Out: $1.50 | | minimax.minimax-m2 | bedrock | In: text; Out: text | function_calling, reasoning, streaming | 204608 | 128000 | In: $0.30, Out: $1.20 | | minimax.minimax-m2.1 | bedrock | In: text; Out: text | function_calling, reasoning, streaming | 204800 | 131072 | In: $0.30, Out: $1.20 | | minimax.minimax-m2.5 | bedrock | In: text; Out: text | function_calling, reasoning, streaming | 196608 | 98304 | In: $0.30, Out: $1.20 | | mistral.ministral-3-14b-instruct | bedrock | In: text; Out: text | function_calling, structured_output, streaming | 128000 | 4096 | In: $0.20, Out: $0.20 | | mistral.ministral-3-3b-instruct | bedrock | In: text, image; Out: text | function_calling, structured_output, vision, streaming | 256000 | 8192 | In: $0.10, Out: $0.10 | | mistral.ministral-3-8b-instruct | bedrock | In: text; Out: text | function_calling, structured_output, streaming | 128000 | 4096 | In: $0.15, Out: $0.15 | | mistral.mistral-7b-instruct-v0:2 | bedrock | In: text; Out: text | streaming, function_calling | - | - | - | | mistral.mistral-large-2402-v1:0 | bedrock | In: text; Out: text | streaming, function_calling | - | - | - | | mistral.mistral-large-2407-v1:0 | bedrock | In: text; Out: text | streaming, function_calling | - | - | - | | mistral.mistral-large-3-675b-instruct | bedrock | In: text, image; Out: text | function_calling, structured_output, vision, streaming | 256000 | 8192 | In: $0.50, Out: $1.50 | | mistral.mixtral-8x7b-instruct-v0:1 | bedrock | In: text; Out: text | streaming, function_calling | - | - | - | | nvidia.nemotron-super-3-120b | bedrock | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 262144 | 131072 | In: $0.15, Out: $0.65 | | nvidia.nemotron-nano-12b-v2 | bedrock | In: text, image; Out: text | function_calling, structured_output, vision, streaming | 128000 | 4096 | In: $0.20, Out: $0.60 | | nvidia.nemotron-nano-3-30b | bedrock | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 128000 | 4096 | In: $0.06, Out: $0.24 | | nvidia.nemotron-nano-9b-v2 | bedrock | In: text; Out: text | function_calling, structured_output, streaming | 128000 | 4096 | In: $0.06, Out: $0.23 | | amazon.nova-2-lite-v1:0 | bedrock | In: text, image, video; Out: text | function_calling, reasoning, vision, video | 128000 | 4096 | In: $0.33, Out: $2.75 | | us.amazon.nova-2-lite-v1:0 | bedrock | In: text, image, video; Out: text | function_calling, reasoning, vision, video, streaming | 128000 | 4096 | In: $0.33, Out: $2.75 | | amazon.nova-2-sonic-v1:0 | bedrock | In: audio; Out: audio, text | streaming, function_calling | - | - | - | | amazon.nova-lite-v1:0 | bedrock | In: text, image, video; Out: text | function_calling, vision, video, streaming | 300000 | 8192 | In: $0.06, Out: $0.24, Cache Read: $0.02 | | amazon.nova-micro-v1:0 | bedrock | In: text; Out: text | function_calling | 128000 | 8192 | In: $0.04, Out: $0.14, Cache Read: $0.01 | | us.amazon.nova-micro-v1:0 | bedrock | In: text; Out: text | function_calling, streaming | 128000 | 8192 | In: $0.04, Out: $0.14, Cache Read: $0.01 | | amazon.nova-premier-v1:0:1000k | bedrock | In: text, image, video; Out: text | streaming, function_calling | - | - | - | | amazon.nova-premier-v1:0:20k | bedrock | In: text, image, video; Out: text | streaming, function_calling | - | - | - | | amazon.nova-premier-v1:0:8k | bedrock | In: text, image, video; Out: text | streaming, function_calling | - | - | - | | amazon.nova-premier-v1:0:mm | bedrock | In: text, image, video; Out: text | streaming, function_calling | - | - | - | | us.amazon.nova-premier-v1:0 | bedrock | In: text, image, video; Out: text | streaming, function_calling | - | - | - | | amazon.nova-pro-v1:0 | bedrock | In: text, image, video; Out: text | function_calling, vision, video | 300000 | 8192 | In: $0.80, Out: $3.20, Cache Read: $0.20 | | us.amazon.nova-pro-v1:0 | bedrock | In: text, image, video; Out: text | function_calling, vision, video, streaming | 300000 | 8192 | In: $0.80, Out: $3.20, Cache Read: $0.20 | | us.writer.palmyra-x4-v1:0 | bedrock | In: text; Out: text | function_calling, reasoning, streaming | 122880 | 8192 | In: $2.50, Out: $10.00 | | writer.palmyra-x4-v1:0 | bedrock | In: text; Out: text | function_calling, reasoning | 122880 | 8192 | In: $2.50, Out: $10.00 | | us.writer.palmyra-x5-v1:0 | bedrock | In: text; Out: text | function_calling, reasoning, streaming | 1040000 | 8192 | In: $0.60, Out: $6.00 | | writer.palmyra-x5-v1:0 | bedrock | In: text; Out: text | function_calling, reasoning | 1040000 | 8192 | In: $0.60, Out: $6.00 | | us.twelvelabs.pegasus-1-2-v1:0 | bedrock | In: text, video; Out: text | streaming, function_calling | - | - | - | | mistral.pixtral-large-2502-v1:0 | bedrock | In: text, image; Out: text | function_calling, vision | 128000 | 8192 | In: $2.00, Out: $6.00 | | us.mistral.pixtral-large-2502-v1:0 | bedrock | In: text, image; Out: text | function_calling, vision, streaming | 128000 | 8192 | In: $2.00, Out: $6.00 | | qwen.qwen3-next-80b-a3b | bedrock | In: text; Out: text | function_calling, structured_output, streaming | 262000 | 262000 | In: $0.14, Out: $1.40 | | qwen.qwen3-vl-235b-a22b | bedrock | In: text, image; Out: text | function_calling, structured_output, vision, streaming | 262000 | 262000 | In: $0.30, Out: $1.50 | | qwen.qwen3-235b-a22b-2507-v1:0 | bedrock | In: text; Out: text | function_calling, structured_output, streaming | 262144 | 131072 | In: $0.22, Out: $0.88 | | qwen.qwen3-32b-v1:0 | bedrock | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 16384 | 16384 | In: $0.15, Out: $0.60 | | qwen.qwen3-coder-30b-a3b-v1:0 | bedrock | In: text; Out: text | function_calling, structured_output, streaming | 262144 | 131072 | In: $0.15, Out: $0.60 | | qwen.qwen3-coder-480b-a35b-v1:0 | bedrock | In: text; Out: text | function_calling, structured_output, streaming | 131072 | 65536 | In: $0.22, Out: $1.80 | | qwen.qwen3-coder-next | bedrock | In: text; Out: text | function_calling, structured_output, reasoning | 131072 | 65536 | In: $0.22, Out: $1.80 | | luma.ray-v2:0 | bedrock | In: text; Out: video | function_calling | - | - | - | | amazon.rerank-v1:0 | bedrock | In: text; Out: text | function_calling | - | - | - | | cohere.rerank-v3-5:0 | bedrock | In: text; Out: text | function_calling | - | - | - | | stability.sd3-5-large-v1:0 | bedrock | In: text, image; Out: image | function_calling | - | - | - | | us.stability.stable-conservative-upscale-v1:0 | bedrock | In: text, image; Out: image | function_calling | - | - | - | | us.stability.stable-image-control-sketch-v1:0 | bedrock | In: text, image; Out: image | function_calling | - | - | - | | us.stability.stable-image-control-structure-v1:0 | bedrock | In: text, image; Out: image | function_calling | - | - | - | | stability.stable-image-core-v1:1 | bedrock | In: text; Out: image | function_calling | - | - | - | | us.stability.stable-creative-upscale-v1:0 | bedrock | In: text, image; Out: image | function_calling | - | - | - | | us.stability.stable-image-erase-object-v1:0 | bedrock | In: text, image; Out: image | function_calling | - | - | - | | us.stability.stable-fast-upscale-v1:0 | bedrock | In: text, image; Out: image | function_calling | - | - | - | | us.stability.stable-image-inpaint-v1:0 | bedrock | In: text, image; Out: image | function_calling | - | - | - | | us.stability.stable-outpaint-v1:0 | bedrock | In: text, image; Out: image | function_calling | - | - | - | | us.stability.stable-image-remove-background-v1:0 | bedrock | In: text, image; Out: image | function_calling | - | - | - | | us.stability.stable-image-search-recolor-v1:0 | bedrock | In: text, image; Out: image | function_calling | - | - | - | | us.stability.stable-image-search-replace-v1:0 | bedrock | In: text, image; Out: image | function_calling | - | - | - | | us.stability.stable-image-style-guide-v1:0 | bedrock | In: text, image; Out: image | function_calling | - | - | - | | us.stability.stable-style-transfer-v1:0 | bedrock | In: text, image; Out: image | function_calling | - | - | - | | stability.stable-image-ultra-v1:1 | bedrock | In: text; Out: image | function_calling | - | - | - | | amazon.titan-embed-text-v1 | bedrock | In: text; Out: embeddings | function_calling | - | - | - | | amazon.titan-embed-text-v1:2:8k | bedrock | In: text; Out: embeddings | function_calling | - | - | - | | amazon.titan-embed-image-v1 | bedrock | In: text, image; Out: embeddings | function_calling | - | - | - | | amazon.titan-embed-image-v1:0 | bedrock | In: text, image; Out: embeddings | function_calling | - | - | - | | amazon.titan-embed-text-v2:0 | bedrock | In: text; Out: embeddings | function_calling | - | - | - | | amazon.titan-embed-g1-text-02 | bedrock | In: text; Out: embeddings | function_calling | - | - | - | | mistral.voxtral-mini-3b-2507 | bedrock | In: audio, text; Out: text | function_calling, structured_output, streaming | 128000 | 4096 | In: $0.04, Out: $0.04 | | mistral.voxtral-small-24b-2507 | bedrock | In: text, audio; Out: text | function_calling, structured_output, streaming | 32000 | 8192 | In: $0.15, Out: $0.35 | | writer.palmyra-vision-7b | bedrock | In: text, image; Out: text | streaming, function_calling | - | 4096 | - | | openai.gpt-oss-120b | bedrock | In: text; Out: text | function_calling, structured_output, reasoning | 128000 | 16384 | In: $0.15, Out: $0.60 | | openai.gpt-oss-120b-1:0 | bedrock | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 128000 | 16384 | In: $0.15, Out: $0.60 | | openai.gpt-oss-20b | bedrock | In: text; Out: text | function_calling, structured_output, reasoning | 128000 | 16384 | In: $0.07, Out: $0.30 | | openai.gpt-oss-20b-1:0 | bedrock | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 128000 | 16384 | In: $0.07, Out: $0.30 | | deepseek-chat | deepseek | In: text; Out: text | function_calling | 1000000 | 384000 | In: $0.14, Out: $0.28, Cache Read: $0.00 | | deepseek-reasoner | deepseek | In: text; Out: text | function_calling, reasoning | 1000000 | 384000 | In: $0.14, Out: $0.28, Cache Read: $0.00 | | deepseek-v4-flash | deepseek | In: text; Out: text | function_calling, structured_output, reasoning, tool_choice | 1000000 | 384000 | In: $0.14, Out: $0.28, Cache Read: $0.00 | | deepseek-v4-pro | deepseek | In: text; Out: text | function_calling, structured_output, reasoning, tool_choice | 1000000 | 384000 | In: $0.44, Out: $0.87, Cache Read: $0.00 | | deep-research-max-preview-04-2026 | gemini | In: text, image, video, audio, pdf; Out: text, image | function_calling, reasoning, vision, video | 131072 | 65536 | In: $2.00, Out: $12.00, Cache Read: $0.20 | | deep-research-preview-04-2026 | gemini | In: text, image, video, audio, pdf; Out: text, image | function_calling, reasoning, vision, video | 131072 | 65536 | In: $2.00, Out: $12.00, Cache Read: $0.20 | | deep-research-pro-preview-12-2025 | gemini | In: -; Out: - | function_calling, tool_choice, structured_output, vision | 131072 | 65536 | In: $0.08, Out: $0.30 | | gemini-2.0-flash | gemini | In: text, image, audio, video, pdf; Out: text | function_calling, structured_output, vision, video, tool_choice | 1048576 | 8192 | In: $0.10, Out: $0.40, Cache Read: $0.02 | | gemini-2.0-flash-001 | gemini | In: -; Out: - | function_calling, tool_choice, structured_output, vision | 1048576 | 8192 | In: $0.10, Out: $0.40 | | gemini-2.0-flash-lite | gemini | In: text, image, audio, video, pdf; Out: text | function_calling, structured_output, vision, video | 1048576 | 8192 | In: $0.08, Out: $0.30 | | gemini-2.5-computer-use-preview-10-2025 | gemini | In: text, image; Out: text | function_calling, reasoning, vision, tool_choice | 131072 | 65536 | In: $1.25, Out: $10.00 | | gemini-2.5-flash | gemini | In: text, image, audio, video, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, tool_choice | 1048576 | 65536 | In: $0.30, Out: $2.50, Cache Read: $0.03 | | gemini-2.5-flash-lite | gemini | In: text, image, audio, video, pdf; Out: text | function_calling, structured_output, reasoning, vision, video | 1048576 | 65536 | In: $0.10, Out: $0.40, Cache Read: $0.01 | | gemini-2.5-pro | gemini | In: text, image, audio, video, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, tool_choice | 1048576 | 65536 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gemini-3-flash-preview | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, tool_choice | 1048576 | 65536 | In: $0.50, Out: $3.00, Cache Read: $0.05 | | gemini-3-pro-preview | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, tool_choice | 1048576 | 65536 | In: $2.00, Out: $12.00, Cache Read: $0.20 | | gemini-3.1-flash-lite | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video | 1048576 | 65536 | In: $0.25, Out: $1.50, Cache Read: $0.02 | | gemini-3.1-flash-lite-preview | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video | 1048576 | 65536 | In: $0.25, Out: $1.50, Cache Read: $0.02 | | gemini-3.1-flash-live-preview | gemini | In: text, image, video, audio; Out: text, audio | function_calling, reasoning, vision, video | 131072 | 65536 | In: $0.75, Out: $4.50 | | gemini-3.1-pro-preview | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, tool_choice | 1048576 | 65536 | In: $2.00, Out: $12.00, Cache Read: $0.20 | | gemini-3.1-pro-preview-customtools | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, tool_choice | 1048576 | 65536 | In: $2.00, Out: $12.00, Cache Read: $0.20 | | gemini-3.5-flash | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, tool_choice | 1048576 | 65536 | In: $1.50, Out: $9.00, Cache Read: $0.15 | | gemini-3.5-flash-lite | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video | 1048576 | 65536 | In: $0.30, Out: $2.50, Cache Read: $0.03 | | gemini-3.6-flash | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, tool_choice | 1048576 | 65536 | In: $1.50, Out: $7.50, Cache Read: $0.15 | | gemini-embedding-2-preview | gemini | In: -; Out: - | function_calling, tool_choice, structured_output, vision | 8192 | 1 | In: $0.00, Out: $0.00 | | gemini-flash-latest | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, tool_choice | 1048576 | 65536 | In: $1.50, Out: $9.00, Cache Read: $0.15 | | gemini-flash-lite-latest | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video | 1048576 | 65536 | In: $0.25, Out: $1.50, Cache Read: $0.02 | | gemini-pro-latest | gemini | In: -; Out: - | function_calling, tool_choice, structured_output, vision | 1048576 | 65536 | In: $0.08, Out: $0.30 | | gemini-robotics-er-1.5-preview | gemini | In: -; Out: - | function_calling, tool_choice, structured_output, vision | 1048576 | 65536 | In: $0.08, Out: $0.30 | | gemini-robotics-er-1.6-preview | gemini | In: text, image, video, audio; Out: text | function_calling, structured_output, reasoning, vision, video, tool_choice | 131072 | 65536 | In: $1.00, Out: $5.00 | | gemini-robotics-er-2-preview | gemini | In: -; Out: - | function_calling, tool_choice, structured_output, vision | 131072 | 65536 | In: $0.08, Out: $0.30 | | gemma-4-26b-a4b-it | gemini | In: text, image; Out: text | function_calling, structured_output, reasoning, vision | 262144 | 32768 | In: $0.08, Out: $0.30 | | gemma-4-31b-it | gemini | In: text, image; Out: text | function_calling, structured_output, reasoning, vision | 262144 | 32768 | In: $0.08, Out: $0.30 | | gemini-3.1-flash-lite-image | gemini | In: text, image; Out: text, image | function_calling, reasoning, vision | 65536 | 65536 | In: $0.25, Out: $30.00 | | nano-banana-pro-preview | gemini | In: -; Out: - | function_calling, tool_choice, structured_output, vision | 131072 | 32768 | In: $0.08, Out: $0.30 | | codestral-2508 | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, predicted_outputs, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | codestral-latest | mistral | In: text; Out: text | function_calling, streaming, batch, predicted_outputs, tool_choice, parallel_tool_calls | 256000 | 4096 | In: $0.30, Out: $0.90 | | devstral-2512 | mistral | In: text; Out: text | function_calling, streaming, batch, fine_tuning, tool_choice, parallel_tool_calls | 262144 | 262144 | In: $0.40, Out: $2.00 | | devstral-latest | mistral | In: text; Out: text | function_calling, streaming, batch, fine_tuning, tool_choice, parallel_tool_calls | 262144 | 262144 | In: $0.40, Out: $2.00 | | devstral-medium-latest | mistral | In: text; Out: text | function_calling, streaming, batch, fine_tuning, tool_choice, parallel_tool_calls | 262144 | 262144 | In: $0.40, Out: $2.00 | | devstral-medium-2507 | mistral | In: text; Out: text | function_calling, tool_choice, parallel_tool_calls | 128000 | 128000 | In: $0.40, Out: $2.00 | | devstral-small-2507 | mistral | In: text; Out: text | function_calling, tool_choice, parallel_tool_calls | 128000 | 128000 | In: $0.10, Out: $0.30 | | labs-devstral-small-2512 | mistral | In: text, image; Out: text | function_calling, vision, tool_choice, parallel_tool_calls | 256000 | 256000 | In: $0.00, Out: $0.00 | | devstral-small-2505 | mistral | In: text; Out: text | function_calling, tool_choice, parallel_tool_calls | 128000 | 128000 | In: $0.10, Out: $0.30 | | labs-leanstral-1-5 | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | labs-leanstral-1-5-1 | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | magistral-medium-latest | mistral | In: text; Out: text | function_calling, reasoning, streaming, batch, tool_choice, parallel_tool_calls | 128000 | 16384 | In: $2.00, Out: $5.00 | | magistral-medium-2509 | mistral | In: text; Out: text | streaming, function_calling, structured_output, reasoning, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | magistral-small | mistral | In: text; Out: text | function_calling, reasoning, tool_choice, parallel_tool_calls | 128000 | 128000 | In: $0.50, Out: $1.50 | | magistral-small-2509 | mistral | In: text; Out: text | streaming, function_calling, structured_output, reasoning, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | magistral-small-latest | mistral | In: text; Out: text | streaming, function_calling, structured_output, reasoning, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | ministral-14b-2512 | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, distillation, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | ministral-14b-latest | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, distillation, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | ministral-3b-2512 | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, distillation, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | ministral-3b-latest | mistral | In: text; Out: text | function_calling, streaming, batch, distillation, tool_choice, parallel_tool_calls | 128000 | 128000 | In: $0.04, Out: $0.04 | | ministral-8b-2512 | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, distillation, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | ministral-8b-latest | mistral | In: text; Out: text | function_calling, streaming, batch, distillation, tool_choice, parallel_tool_calls | 128000 | 128000 | In: $0.10, Out: $0.10 | | open-mistral-7b | mistral | In: text; Out: text | function_calling, tool_choice, parallel_tool_calls | 8000 | 8000 | In: $0.25, Out: $0.25 | | mistral-code-agent-latest | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | mistral-code-fim-latest | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | mistral-code-latest | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | mistral-large-latest | mistral | In: text, image; Out: text | function_calling, vision, streaming, batch, fine_tuning, tool_choice, parallel_tool_calls | 262144 | 262144 | In: $0.50, Out: $1.50 | | mistral-large-2411 | mistral | In: text; Out: text | function_calling, tool_choice, parallel_tool_calls | 131072 | 16384 | In: $2.00, Out: $6.00 | | mistral-large-2512 | mistral | In: text, image; Out: text | function_calling, vision, streaming, batch, fine_tuning, tool_choice, parallel_tool_calls | 262144 | 262144 | In: $0.50, Out: $1.50 | | mistral-medium | mistral | In: text; Out: text | streaming, function_calling, structured_output, vision, batch, fine_tuning, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | mistral-medium-3 | mistral | In: text; Out: text | streaming, function_calling, structured_output, vision, reasoning, batch, fine_tuning, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | mistral-medium-3-5 | mistral | In: text; Out: text | streaming, function_calling, structured_output, vision, reasoning, batch, fine_tuning, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | mistral-medium-3.5 | mistral | In: text; Out: text | streaming, function_calling, structured_output, vision, reasoning, batch, fine_tuning, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | mistral-medium-latest | mistral | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming, batch, fine_tuning, tool_choice, parallel_tool_calls | 262144 | 262144 | In: $1.50, Out: $7.50 | | mistral-medium-2505 | mistral | In: text, image; Out: text | function_calling, vision, streaming, batch, fine_tuning, tool_choice, parallel_tool_calls | 131072 | 131072 | In: $0.40, Out: $2.00 | | mistral-medium-2508 | mistral | In: text, image; Out: text | function_calling, vision, streaming, batch, fine_tuning, tool_choice, parallel_tool_calls | 262144 | 262144 | In: $0.40, Out: $2.00 | | mistral-medium-2604 | mistral | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming, batch, fine_tuning, tool_choice, parallel_tool_calls | 262144 | 262144 | In: $1.50, Out: $7.50 | | mistral-nemo | mistral | In: text; Out: text | function_calling, tool_choice, parallel_tool_calls | 128000 | 128000 | In: $0.15, Out: $0.15 | | mistral-small-latest | mistral | In: text, image; Out: text | function_calling, reasoning, vision, streaming, batch, fine_tuning, tool_choice, parallel_tool_calls | 256000 | 256000 | In: $0.15, Out: $0.60 | | mistral-small-2506 | mistral | In: text, image; Out: text | function_calling, vision, streaming, batch, fine_tuning, tool_choice, parallel_tool_calls | 128000 | 16384 | In: $0.10, Out: $0.30 | | mistral-small-2603 | mistral | In: text, image; Out: text | function_calling, reasoning, vision, streaming, batch, fine_tuning, tool_choice, parallel_tool_calls | 256000 | 256000 | In: $0.15, Out: $0.60 | | mistral-tiny-2407 | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | mistral-tiny-latest | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | mistral-vibe-cli-fast | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | mistral-vibe-cli-latest | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | mistral-vibe-cli-with-tools | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | open-mixtral-8x22b | mistral | In: text; Out: text | function_calling, tool_choice, parallel_tool_calls | 64000 | 64000 | In: $2.00, Out: $6.00 | | open-mixtral-8x7b | mistral | In: text; Out: text | function_calling, tool_choice, parallel_tool_calls | 32000 | 32000 | In: $0.70, Out: $0.70 | | open-mistral-nemo | mistral | In: text; Out: text | function_calling, streaming, batch, tool_choice, parallel_tool_calls | 128000 | 128000 | In: $0.15, Out: $0.15 | | open-mistral-nemo-2407 | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | pixtral-12b | mistral | In: text, image; Out: text | function_calling, vision, tool_choice, parallel_tool_calls | 128000 | 128000 | In: $0.15, Out: $0.15 | | pixtral-large-latest | mistral | In: text, image; Out: text | function_calling, vision, tool_choice, parallel_tool_calls | 128000 | 128000 | In: $2.00, Out: $6.00 | | voxtral-small-latest | mistral | In: text, audio; Out: text | function_calling, streaming | 32000 | 32000 | In: $0.10, Out: $0.30 | | gpt-4 | openai | In: text; Out: text | function_calling, tool_choice, parallel_tool_calls | 8192 | 8192 | In: $30.00, Out: $60.00 | | gpt-4-turbo | openai | In: text, image; Out: text | function_calling, vision, tool_choice, parallel_tool_calls | 128000 | 4096 | In: $10.00, Out: $30.00 | | gpt-4.1 | openai | In: text, image, pdf; Out: text | function_calling, structured_output, vision, tool_choice, parallel_tool_calls | 1047576 | 32768 | In: $2.00, Out: $8.00, Cache Read: $0.50 | | gpt-4.1-mini | openai | In: text, image, pdf; Out: text | function_calling, structured_output, vision, tool_choice, parallel_tool_calls | 1047576 | 32768 | In: $0.40, Out: $1.60, Cache Read: $0.10 | | gpt-4.1-nano | openai | In: text, image; Out: text | function_calling, structured_output, vision, tool_choice, parallel_tool_calls | 1047576 | 32768 | In: $0.10, Out: $0.40, Cache Read: $0.02 | | gpt-4o | openai | In: text, image, pdf; Out: text | function_calling, structured_output, vision, tool_choice, parallel_tool_calls | 128000 | 16384 | In: $2.50, Out: $10.00, Cache Read: $1.25 | | gpt-4o-2024-05-13 | openai | In: text, image; Out: text | function_calling, structured_output, vision, tool_choice, parallel_tool_calls | 128000 | 4096 | In: $5.00, Out: $15.00 | | gpt-4o-2024-08-06 | openai | In: text, image; Out: text | function_calling, structured_output, vision, tool_choice, parallel_tool_calls | 128000 | 16384 | In: $2.50, Out: $10.00, Cache Read: $1.25 | | gpt-4o-2024-11-20 | openai | In: text, image; Out: text | function_calling, structured_output, vision, tool_choice, parallel_tool_calls | 128000 | 16384 | In: $2.50, Out: $10.00, Cache Read: $1.25 | | gpt-4o-mini | openai | In: text, image, pdf; Out: text | function_calling, structured_output, vision, tool_choice, parallel_tool_calls | 128000 | 16384 | In: $0.15, Out: $0.60, Cache Read: $0.08 | | gpt-5 | openai | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 400000 | 128000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5-mini | openai | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 400000 | 128000 | In: $0.25, Out: $2.00, Cache Read: $0.02 | | gpt-5-nano | openai | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 400000 | 128000 | In: $0.05, Out: $0.40, Cache Read: $0.01 | | gpt-5-pro | openai | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 400000 | 272000 | In: $15.00, Out: $120.00 | | gpt-5.1 | openai | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 400000 | 128000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.2 | openai | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 400000 | 128000 | In: $1.75, Out: $14.00, Cache Read: $0.18 | | gpt-5.2-chat-latest | openai | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 128000 | 16384 | In: $1.75, Out: $14.00, Cache Read: $0.18 | | gpt-5.2-pro | openai | In: text, image; Out: text | function_calling, reasoning, vision, tool_choice, parallel_tool_calls | 400000 | 128000 | In: $21.00, Out: $168.00 | | gpt-5.3-chat-latest | openai | In: text, image; Out: text | function_calling, structured_output, vision, tool_choice, parallel_tool_calls | 128000 | 16384 | In: $1.75, Out: $14.00, Cache Read: $0.18 | | gpt-5.3-codex | openai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 400000 | 128000 | In: $1.75, Out: $14.00, Cache Read: $0.18 | | gpt-5.3-codex-spark | openai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 128000 | 32000 | In: $1.75, Out: $14.00, Cache Read: $0.18 | | gpt-5.4 | openai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 1050000 | 128000 | In: $2.50, Out: $15.00, Cache Read: $0.25 | | gpt-5.4-pro | openai | In: text, image; Out: text | function_calling, reasoning, vision, tool_choice, parallel_tool_calls | 1050000 | 128000 | In: $30.00, Out: $180.00 | | gpt-5.4-mini | openai | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 400000 | 128000 | In: $0.75, Out: $4.50, Cache Read: $0.08 | | gpt-5.4-nano | openai | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 400000 | 128000 | In: $0.20, Out: $1.25, Cache Read: $0.02 | | gpt-5.5 | openai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 1050000 | 128000 | In: $5.00, Out: $30.00, Cache Read: $0.50 | | gpt-5.5-pro | openai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 1050000 | 128000 | In: $30.00, Out: $180.00 | | gpt-5.6 | openai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1050000 | 128000 | In: $5.00, Out: $30.00, Cache Read: $0.50, Cache Write: $6.25 | | gpt-5.6-luna | openai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 1050000 | 128000 | In: $0.20, Out: $1.20, Cache Read: $0.02, Cache Write: $0.25 | | gpt-5.6-sol | openai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 1050000 | 128000 | In: $5.00, Out: $30.00, Cache Read: $0.50, Cache Write: $6.25 | | gpt-5.6-terra | openai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 1050000 | 128000 | In: $2.00, Out: $12.00, Cache Read: $0.20, Cache Write: $2.50 | | gpt-realtime-2.1 | openai | In: text, audio, image; Out: text, audio | function_calling, reasoning, vision | 128000 | 32000 | In: $4.00, Out: $24.00, Cache Read: $0.40 | | gpt-4-turbo-2024-04-09 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, vision | 128000 | 16384 | In: $10.00, Out: $30.00 | | gpt-4.1-2025-04-14 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision | 1047576 | 32768 | In: $2.00, Out: $8.00, Cache Read: $0.50 | | gpt-4.1-mini-2025-04-14 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision | 1047576 | 32768 | In: $0.40, Out: $1.60, Cache Read: $0.10 | | gpt-4.1-nano-2025-04-14 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision | 1047576 | 32768 | In: $0.10, Out: $0.40 | | gpt-4o-mini-2024-07-18 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision | 128000 | 16384 | In: $0.15, Out: $0.60 | | gpt-5-2025-08-07 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5-chat-latest | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5-codex | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5-mini-2025-08-07 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 128000 | 400000 | In: $0.25, Out: $2.00, Cache Read: $0.02 | | gpt-5-nano-2025-08-07 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 128000 | 400000 | In: $0.05, Out: $0.40, Cache Read: $0.01 | | gpt-5-pro-2025-10-06 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5-search-api | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning, citations | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5-search-api-2025-10-14 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning, citations | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.1-2025-11-13 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.1-chat-latest | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.1-codex | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.1-codex-max | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.1-codex-mini | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 128000 | 400000 | In: $0.25, Out: $2.00, Cache Read: $0.02 | | gpt-5.2-2025-12-11 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.2-codex | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.2-pro-2025-12-11 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.4-2026-03-05 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.4-mini-2026-03-17 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 128000 | 400000 | In: $0.25, Out: $2.00, Cache Read: $0.02 | | gpt-5.4-nano-2026-03-17 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 128000 | 400000 | In: $0.05, Out: $0.40, Cache Read: $0.01 | | gpt-5.4-pro-2026-03-05 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.5-2026-04-23 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.5-pro-2026-04-23 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | o1 | openai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 200000 | 100000 | In: $15.00, Out: $60.00, Cache Read: $7.50 | | o1-2024-12-17 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 200000 | 100000 | In: $15.00, Out: $60.00 | | o1-pro | openai | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 200000 | 100000 | In: $150.00, Out: $600.00 | | o1-pro-2025-03-19 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 200000 | 100000 | In: $150.00, Out: $600.00 | | o3 | openai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 100000 | In: $2.00, Out: $8.00, Cache Read: $0.50 | | o3-mini | openai | In: text; Out: text | function_calling, structured_output, reasoning, tool_choice, parallel_tool_calls | 200000 | 100000 | In: $1.10, Out: $4.40, Cache Read: $0.55 | | o3-mini-2025-01-31 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, reasoning | 200000 | 100000 | In: $1.10, Out: $4.40 | | o3-pro | openai | In: text, image; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 100000 | In: $20.00, Out: $80.00 | | o4-mini | openai | In: text, image; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 100000 | In: $1.10, Out: $4.40, Cache Read: $0.28 | | aion-labs/aion-2.0 | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 131072 | 32768 | In: $0.80, Out: $1.60, Cache Read: $0.20 | | aion-labs/aion-3.0 | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 131072 | 32768 | In: $3.00, Out: $6.00, Cache Read: $0.75 | | aion-labs/aion-3.0-mini | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 131072 | 32768 | In: $0.70, Out: $1.40, Cache Read: $0.18 | | ~anthropic/claude-haiku-latest | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 64000 | In: $1.00, Out: $5.00, Cache Read: $0.10, Cache Write: $1.25 | | ~anthropic/claude-sonnet-latest | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $2.00, Out: $10.00, Cache Read: $0.20, Cache Write: $2.50 | | anthropic/claude-fable-5:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50 | | anthropic/claude-haiku-4.5:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 200000 | 64000 | In: $0.50, Out: $2.50, Cache Read: $0.05 | | anthropic/claude-opus-4.1:batch | openrouter | In: image, text, file; Out: text | streaming, function_calling, structured_output | 200000 | 32000 | In: $7.50, Out: $37.50, Cache Read: $0.75 | | anthropic/claude-opus-4.5:batch | openrouter | In: file, image, text; Out: text | streaming, function_calling, structured_output | 200000 | 64000 | In: $2.50, Out: $12.50, Cache Read: $0.25 | | anthropic/claude-opus-4.6:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 1000000 | 128000 | In: $2.50, Out: $12.50, Cache Read: $0.25 | | anthropic/claude-opus-4.7:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 1000000 | 128000 | In: $2.50, Out: $12.50, Cache Read: $0.25 | | anthropic/claude-opus-4.8:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 1000000 | 128000 | In: $2.50, Out: $12.50, Cache Read: $0.25 | | anthropic/claude-sonnet-4.5:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 1000000 | 64000 | In: $1.50, Out: $7.50, Cache Read: $0.15 | | anthropic/claude-sonnet-4.6:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 1000000 | 128000 | In: $1.50, Out: $7.50, Cache Read: $0.15 | | anthropic/claude-sonnet-5:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 1000000 | 128000 | In: $1.00, Out: $5.00, Cache Read: $0.10 | | openrouter/auto | openrouter | In: text, image, audio, pdf, video; Out: text, image | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 2000000 | 2000000 | - | | openrouter/auto-beta | openrouter | In: text, image, audio, file, video; Out: text, image | streaming, function_calling, structured_output, predicted_outputs | 2000000 | - | - | | anthropic/claude-3-haiku | openrouter | In: text, image; Out: text | function_calling, vision, streaming | 200000 | 4096 | In: $0.25, Out: $1.25, Cache Read: $0.03, Cache Write: $0.30 | | anthropic/claude-fable-5 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $10.00, Out: $50.00, Cache Read: $1.00, Cache Write: $12.50 | | ~anthropic/claude-fable-latest | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $10.00, Out: $50.00, Cache Read: $1.00, Cache Write: $12.50 | | anthropic/claude-haiku-4.5 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 64000 | In: $1.00, Out: $5.00, Cache Read: $0.10, Cache Write: $1.25 | | anthropic/claude-opus-4 | openrouter | In: image, text, pdf; Out: text | function_calling, reasoning, vision, streaming | 200000 | 32000 | In: $15.00, Out: $75.00, Cache Read: $1.50, Cache Write: $18.75 | | anthropic/claude-opus-4.1 | openrouter | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 200000 | 32000 | In: $15.00, Out: $75.00, Cache Read: $1.50, Cache Write: $18.75 | | anthropic/claude-opus-4.5 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 64000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | anthropic/claude-opus-4.6 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | anthropic/claude-opus-4.7 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | anthropic/claude-opus-4.7-fast | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $30.00, Out: $150.00, Cache Read: $3.00, Cache Write: $37.50 | | anthropic/claude-opus-4.8 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | anthropic/claude-opus-4.8-fast | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $10.00, Out: $50.00, Cache Read: $1.00, Cache Write: $12.50 | | anthropic/claude-opus-5 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | anthropic/claude-opus-5-fast | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $10.00, Out: $50.00, Cache Read: $1.00, Cache Write: $12.50 | | anthropic/claude-opus-5:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 1000000 | 128000 | In: $2.50, Out: $12.50, Cache Read: $0.25 | | ~anthropic/claude-opus-latest | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | anthropic/claude-sonnet-4 | openrouter | In: image, text, pdf; Out: text | function_calling, reasoning, vision, streaming | 1000000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | anthropic/claude-sonnet-4.5 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | anthropic/claude-sonnet-4.6 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | anthropic/claude-sonnet-5 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $2.00, Out: $10.00, Cache Read: $0.20, Cache Write: $2.50 | | mistralai/codestral-2508 | openrouter | In: text, pdf; Out: text | function_calling, structured_output, vision, streaming | 256000 | 256000 | In: $0.30, Out: $0.90, Cache Read: $0.03 | | cohere/command-r-08-2024 | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 128000 | 4000 | In: $0.15, Out: $0.60 | | cohere/command-r-plus-08-2024 | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 128000 | 4000 | In: $2.50, Out: $10.00 | | deepseek/deepseek-chat | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 163840 | 16000 | In: $0.26, Out: $1.03 | | deepseek/deepseek-chat-v3-0324 | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 163840 | 65536 | In: $0.27, Out: $1.12, Cache Read: $0.14 | | deepseek/deepseek-chat-v3.1 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 163840 | 32768 | In: $0.25, Out: $0.95, Cache Read: $0.13 | | deepseek/deepseek-v3.1-terminus | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 163840 | 32768 | In: $0.27, Out: $1.00, Cache Read: $0.14 | | deepseek/deepseek-v3.2 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 163840 | 65536 | In: $0.27, Out: $0.40, Cache Read: $0.13 | | deepseek/deepseek-v3.2-exp | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 163840 | 65536 | In: $0.27, Out: $0.41 | | deepseek/deepseek-v4-flash | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 1048576 | 393216 | In: $0.14, Out: $0.28, Cache Read: $0.03 | | deepseek/deepseek-v4-flash-0731 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 1048576 | 65536 | In: $0.09, Out: $0.18, Cache Read: $0.02 | | ~deepseek/deepseek-v4-flash-latest | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 1048576 | 65536 | In: $0.09, Out: $0.18, Cache Read: $0.02 | | deepseek/deepseek-v4-pro | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 1048576 | 384000 | In: $0.44, Out: $0.87, Cache Read: $0.00 | | deepseek/deepseek-r1 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 163840 | 16000 | In: $0.70, Out: $2.50 | | openrouter/free | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 8000 | In: $0.00, Out: $0.00 | | sakana/fugu-ultra | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $30.00, Cache Read: $0.50 | | z-ai/glm-4.5 | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 131072 | 98304 | In: $0.60, Out: $2.20, Cache Read: $0.11 | | z-ai/glm-4.5-air | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 131072 | 98304 | In: $0.13, Out: $0.85, Cache Read: $0.02 | | z-ai/glm-4.5v | openrouter | In: text, image; Out: text | function_calling, reasoning, vision, streaming | 65536 | 16384 | In: $0.60, Out: $1.80, Cache Read: $0.11 | | z-ai/glm-4.6 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 204800 | 131072 | In: $0.50, Out: $2.00, Cache Read: $0.10 | | z-ai/glm-4.6v | openrouter | In: text, image, video; Out: text | function_calling, reasoning, vision, video, streaming | 131072 | 32768 | In: $0.30, Out: $0.90, Cache Read: $0.06 | | z-ai/glm-4.7 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 204800 | 131072 | In: $0.40, Out: $1.75, Cache Read: $0.08 | | z-ai/glm-4.7-flash | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 202752 | 16384 | In: $0.06, Out: $0.40, Cache Read: $0.01 | | z-ai/glm-5 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 204800 | 131072 | In: $0.95, Out: $2.55, Cache Read: $0.20 | | z-ai/glm-5-turbo | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 202752 | 131072 | In: $1.20, Out: $4.00, Cache Read: $0.24 | | z-ai/glm-5.1 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 204800 | 131072 | In: $0.95, Out: $2.99, Cache Read: $0.18 | | z-ai/glm-5.2 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 1048576 | 131072 | In: $0.46, Out: $1.45, Cache Read: $0.09 | | z-ai/glm-5v-turbo | openrouter | In: image, text, video; Out: text | function_calling, reasoning, vision, video, streaming | 202752 | 131072 | In: $1.20, Out: $4.00, Cache Read: $0.24 | | openai/gpt-audio | openrouter | In: text, audio; Out: text, audio | function_calling, structured_output, streaming | 128000 | 16384 | In: $2.50, Out: $10.00 | | openai/gpt-audio-mini | openrouter | In: text, audio; Out: text, audio | function_calling, structured_output, streaming | 128000 | 16384 | In: $0.60, Out: $2.40 | | openai/gpt-chat-latest | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 400000 | 128000 | In: $5.00, Out: $30.00, Cache Read: $0.50 | | openai/gpt-oss-120b | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 131072 | 131072 | In: $0.04, Out: $0.17 | | openai/gpt-oss-20b | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 131072 | 131072 | In: $0.03, Out: $0.13, Cache Read: $0.03 | | openai/gpt-3.5-turbo-0613 | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 4095 | 4096 | In: $1.00, Out: $2.00 | | openai/gpt-3.5-turbo-16k | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 16385 | 4096 | In: $3.00, Out: $4.00 | | openai/gpt-3.5-turbo | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 16385 | 4096 | In: $0.50, Out: $1.50 | | openai/gpt-4 | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 8191 | 4096 | In: $30.00, Out: $60.00 | | openai/gpt-4-turbo | openrouter | In: text, image; Out: text | function_calling, structured_output, vision, streaming | 128000 | 4096 | In: $10.00, Out: $30.00 | | openai/gpt-4-turbo-preview | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 128000 | 4096 | In: $10.00, Out: $30.00 | | openai/gpt-4.1 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 1047576 | 32768 | In: $2.00, Out: $8.00, Cache Read: $0.50 | | openai/gpt-4.1-mini | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 1047576 | 32768 | In: $0.40, Out: $1.60, Cache Read: $0.10 | | openai/gpt-4.1-nano | openrouter | In: image, text, pdf; Out: text | function_calling, structured_output, vision, streaming | 1047576 | 32768 | In: $0.10, Out: $0.40, Cache Read: $0.02 | | openai/gpt-4o | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 128000 | 16384 | In: $2.50, Out: $10.00, Cache Read: $1.25 | | openai/gpt-4o-2024-05-13 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 128000 | 4096 | In: $5.00, Out: $15.00 | | openai/gpt-4o-2024-08-06 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 128000 | 16384 | In: $2.50, Out: $10.00, Cache Read: $1.25 | | openai/gpt-4o-2024-11-20 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 128000 | 16384 | In: $2.50, Out: $10.00, Cache Read: $1.25 | | openai/gpt-4o-mini | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 128000 | 16384 | In: $0.15, Out: $0.60, Cache Read: $0.08 | | openai/gpt-4o-mini-2024-07-18 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 128000 | 16384 | In: $0.15, Out: $0.60, Cache Read: $0.08 | | openai/gpt-5 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | openai/gpt-5-mini | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $0.25, Out: $2.00, Cache Read: $0.02 | | openai/gpt-5-nano | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $0.05, Out: $0.40, Cache Read: $0.01 | | openai/gpt-5-pro | openrouter | In: image, text, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $15.00, Out: $120.00 | | openai/gpt-5.1 | openrouter | In: image, text, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | openai/gpt-5.1-codex | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $1.25, Out: $10.00, Cache Read: $0.13 | | openai/gpt-5.1-codex-max | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | openai/gpt-5.1-codex-mini | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $0.25, Out: $2.00, Cache Read: $0.03 | | openai/gpt-5.2 | openrouter | In: pdf, image, text; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $1.75, Out: $14.00, Cache Read: $0.18 | | openai/gpt-5.2-chat | openrouter | In: pdf, image, text; Out: text | function_calling, structured_output, vision, streaming | 128000 | 16384 | In: $1.75, Out: $14.00, Cache Read: $0.18 | | openai/gpt-5.2-codex | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $1.75, Out: $14.00, Cache Read: $0.18 | | openai/gpt-5.2-pro | openrouter | In: image, text, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $21.00, Out: $168.00 | | openai/gpt-5.3-chat | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 128000 | 16384 | In: $1.75, Out: $14.00, Cache Read: $0.18 | | openai/gpt-5.3-codex | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $1.75, Out: $14.00, Cache Read: $0.18 | | openai/gpt-5.4 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $2.50, Out: $15.00, Cache Read: $0.25 | | openai/gpt-5.4-pro | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $30.00, Out: $180.00 | | openai/gpt-5.4-mini | openrouter | In: pdf, image, text; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $0.75, Out: $4.50, Cache Read: $0.08 | | openai/gpt-5.4-nano | openrouter | In: pdf, image, text; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $0.20, Out: $1.25, Cache Read: $0.02 | | openai/gpt-5.5 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $5.00, Out: $30.00, Cache Read: $0.50 | | openai/gpt-5.5-pro | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $30.00, Out: $180.00 | | openai/gpt-5.6-luna | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $0.10, Out: $0.60, Cache Read: $0.01, Cache Write: $0.12 | | openai/gpt-5.6-luna-pro | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $0.10, Out: $0.60, Cache Read: $0.01, Cache Write: $0.12 | | openai/gpt-5.6-sol | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $5.00, Out: $30.00, Cache Read: $0.50, Cache Write: $6.25 | | openai/gpt-5.6-sol-pro | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $5.00, Out: $30.00, Cache Read: $0.50, Cache Write: $6.25 | | openai/gpt-5.6-terra | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $1.00, Out: $6.00, Cache Read: $0.10, Cache Write: $1.25 | | openai/gpt-5.6-terra-pro | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $1.00, Out: $6.00, Cache Read: $0.10, Cache Write: $1.25 | | google/gemini-2.5-flash | openrouter | In: text, image, audio, video, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65535 | In: $0.30, Out: $2.50, Cache Read: $0.03, Cache Write: $0.08 | | google/gemini-2.5-flash-lite | openrouter | In: text, image, audio, video, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65535 | In: $0.10, Out: $0.40, Cache Read: $0.01, Cache Write: $0.08 | | google/gemini-2.5-pro | openrouter | In: text, image, audio, video, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $1.25, Out: $10.00, Cache Read: $0.12, Cache Write: $0.38 | | google/gemini-2.5-pro-preview-05-06 | openrouter | In: text, image, pdf, audio, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65535 | In: $1.25, Out: $10.00, Cache Read: $0.12, Cache Write: $0.38 | | google/gemini-2.5-pro-preview | openrouter | In: pdf, image, text, audio; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1048576 | 65536 | In: $1.25, Out: $10.00, Cache Read: $0.12, Cache Write: $0.38 | | google/gemini-3-flash-preview | openrouter | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $0.50, Out: $3.00, Cache Read: $0.05, Cache Write: $0.08 | | google/gemini-3.1-flash-lite | openrouter | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $0.25, Out: $1.50, Cache Read: $0.02, Cache Write: $0.08 | | google/gemini-3.1-flash-lite-preview | openrouter | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $0.25, Out: $1.50, Cache Read: $0.02, Cache Write: $0.08 | | google/gemini-3.1-pro-preview | openrouter | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $2.00, Out: $12.00, Cache Read: $0.20, Cache Write: $0.38 | | google/gemini-3.1-pro-preview-customtools | openrouter | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $2.00, Out: $12.00, Cache Read: $0.20, Cache Write: $0.38 | | google/gemini-3.5-flash | openrouter | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $1.50, Out: $9.00, Cache Read: $0.15, Cache Write: $0.08 | | google/gemini-3.5-flash-lite | openrouter | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $0.30, Out: $2.50, Cache Read: $0.03, Cache Write: $0.08 | | google/gemini-3.6-flash | openrouter | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $1.50, Out: $7.50, Cache Read: $0.15, Cache Write: $0.08 | | google/gemma-3-12b-it | openrouter | In: text, image; Out: text | function_calling, structured_output, vision, streaming, predicted_outputs | 131072 | 16384 | In: $0.05, Out: $0.15 | | google/gemma-3-27b-it | openrouter | In: text, image; Out: text | function_calling, structured_output, vision, streaming, predicted_outputs | 262144 | 131072 | In: $0.08, Out: $0.45, Cache Read: $0.04 | | google/gemma-4-26b-a4b-it:free | openrouter | In: image, text, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 262144 | 32768 | In: $0.00, Out: $0.00 | | google/gemma-4-26b-a4b-it | openrouter | In: image, text, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 262144 | 16384 | In: $0.07, Out: $0.34 | | google/gemma-4-31b-it:free | openrouter | In: image, text, video; Out: text | function_calling, reasoning, vision, video, streaming | 262144 | 32768 | In: $0.00, Out: $0.00 | | google/gemma-4-31b-it | openrouter | In: image, text, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 262144 | 262144 | In: $0.10, Out: $0.34, Cache Read: $0.10 | | ~google/gemini-flash-latest | openrouter | In: text, image, video, pdf, audio; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $1.50, Out: $7.50, Cache Read: $0.15, Cache Write: $0.08 | | ~google/gemini-pro-latest | openrouter | In: audio, pdf, image, text, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $2.00, Out: $12.00, Cache Read: $0.20, Cache Write: $0.38 | | google/gemini-2.5-flash:batch | openrouter | In: file, image, text, audio, video; Out: text | streaming, function_calling, structured_output | 1048576 | 65535 | In: $0.15, Out: $1.25, Cache Read: $0.03 | | google/gemini-2.5-flash-lite:batch | openrouter | In: text, image, file, audio, video; Out: text | streaming, function_calling, structured_output | 1048576 | 65535 | In: $0.05, Out: $0.20, Cache Read: $0.01 | | google/gemini-2.5-pro:batch | openrouter | In: text, image, file, audio, video; Out: text | streaming, function_calling, structured_output | 1048576 | 65536 | In: $0.62, Out: $5.00, Cache Read: $0.12 | | google/gemini-3-flash-preview:batch | openrouter | In: text, image, file, audio, video; Out: text | streaming, function_calling, structured_output | 1048576 | 65536 | In: $0.25, Out: $1.50 | | google/gemini-3.1-flash-lite:batch | openrouter | In: text, image, video, file, audio; Out: text | streaming, function_calling, structured_output | 1048576 | 65536 | In: $0.12, Out: $0.75, Cache Read: $0.01 | | google/gemini-3.1-pro-preview:batch | openrouter | In: audio, file, image, text, video; Out: text | streaming, function_calling, structured_output | 1048576 | 65536 | In: $1.00, Out: $6.00 | | google/gemini-3.5-flash:batch | openrouter | In: text, image, video, file, audio; Out: text | streaming, function_calling, structured_output | 1048576 | 65536 | In: $0.75, Out: $4.50, Cache Read: $0.08 | | google/gemini-3.5-flash-lite:batch | openrouter | In: text, image, video, file, audio; Out: text | streaming, function_calling, structured_output | 1048576 | 65536 | In: $0.15, Out: $1.25, Cache Read: $0.02 | | google/gemini-3.6-flash:batch | openrouter | In: text, image, video, file, audio; Out: text | streaming, function_calling, structured_output | 1048576 | 65536 | In: $0.75, Out: $3.75, Cache Read: $0.08 | | ibm-granite/granite-4.1-8b | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 131072 | 131072 | In: $0.05, Out: $0.10, Cache Read: $0.05 | | x-ai/grok-4.20 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 2000000 | 2000000 | In: $1.25, Out: $2.50, Cache Read: $0.20 | | x-ai/grok-4.3 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 1000000 | In: $1.25, Out: $2.50, Cache Read: $0.20 | | x-ai/grok-4.5 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 500000 | 500000 | In: $2.00, Out: $6.00, Cache Read: $0.30 | | x-ai/grok-build-0.1 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 256000 | 256000 | In: $1.00, Out: $2.00, Cache Read: $0.20 | | ~x-ai/grok-latest | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 500000 | 1000000 | In: $2.00, Out: $6.00, Cache Read: $0.30 | | tencent/hy3 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 262144 | 128000 | In: $0.13, Out: $0.53, Cache Read: $0.03 | | tencent/hy3-preview | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 262144 | 262144 | In: $0.06, Out: $0.21, Cache Read: $0.02 | | thinkingmachines/inkling | openrouter | In: text, image, audio; Out: text | function_calling, reasoning, vision, streaming, predicted_outputs | 1048576 | 1048576 | In: $1.00, Out: $4.05, Cache Read: $0.17 | | thinkingmachines/inkling-small | openrouter | In: text, image, audio; Out: text | function_calling, reasoning, vision, streaming, predicted_outputs | 524288 | 262144 | In: $0.45, Out: $1.20, Cache Read: $0.10 | | ai21/jamba-large-1.7 | openrouter | In: text; Out: text | function_calling, streaming | 256000 | 4096 | In: $2.00, Out: $8.00 | | kwaipilot/kat-coder-air-v2.5 | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 256000 | 80000 | In: $0.15, Out: $0.60, Cache Read: $0.03 | | kwaipilot/kat-coder-pro-v2 | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 262144 | 80000 | In: $0.30, Out: $1.20, Cache Read: $0.06 | | kwaipilot/kat-coder-pro-v2.5 | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 256000 | 80000 | In: $0.74, Out: $2.96, Cache Read: $0.15 | | moonshotai/kimi-k2 | openrouter | In: text; Out: text | function_calling, streaming | 131072 | 100352 | In: $0.57, Out: $2.30 | | moonshotai/kimi-k2-0905 | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 262144 | 100352 | In: $0.60, Out: $2.50 | | moonshotai/kimi-k2-thinking | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 262144 | 100352 | In: $0.60, Out: $2.50, Cache Read: $0.15 | | moonshotai/kimi-k2.5 | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming, predicted_outputs | 262144 | 262144 | In: $0.57, Out: $2.85, Cache Read: $0.10 | | moonshotai/kimi-k2.6 | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming, predicted_outputs | 262144 | 262144 | In: $0.58, Out: $2.44, Cache Read: $0.10 | | moonshotai/kimi-k2.7-code | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming, predicted_outputs | 262144 | 262144 | In: $0.70, Out: $3.50, Cache Read: $0.15 | | moonshotai/kimi-k3 | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming, predicted_outputs | 1048576 | 1048576 | In: $3.00, Out: $15.00, Cache Read: $0.30 | | poolside/laguna-s-2.1 | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 1048576 | 131072 | In: $0.09, Out: $0.18, Cache Read: $0.01 | | poolside/laguna-s-2.1:free | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 262144 | 32768 | In: $0.00, Out: $0.00 | | poolside/laguna-xs-2.1 | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 262144 | 32768 | In: $0.06, Out: $0.12, Cache Read: $0.03 | | poolside/laguna-xs-2.1:free | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 262144 | 32768 | In: $0.00, Out: $0.00 | | inclusionai/ling-3.0-tiny:free | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 262144 | 32768 | In: $0.00, Out: $0.00 | | inclusionai/ling-2.6-1t | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 262144 | 32768 | In: $0.08, Out: $0.62, Cache Read: $0.02 | | inclusionai/ling-2.6-flash | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 262144 | 32768 | In: $0.01, Out: $0.03, Cache Read: $0.00 | | inclusionai/ling-3.0-flash | openrouter | In: text; Out: text | function_calling, reasoning, streaming, predicted_outputs | 262144 | 32768 | In: $0.02, Out: $0.06, Cache Read: $0.00 | | meta-llama/llama-3.1-70b-instruct | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 131072 | 16384 | In: $0.40, Out: $0.40 | | meta-llama/llama-3.1-8b-instruct | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 131072 | 131072 | In: $0.05, Out: $0.08, Cache Read: $0.02 | | sao10k/l3.1-euryale-70b | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 131072 | 16384 | In: $0.85, Out: $0.85 | | meta-llama/llama-4-maverick | openrouter | In: text, image; Out: text | function_calling, structured_output, vision, streaming, predicted_outputs | 1048576 | 16384 | In: $0.20, Out: $0.80 | | meta-llama/llama-4-scout | openrouter | In: text, image; Out: text | function_calling, structured_output, vision, streaming, predicted_outputs | 1310720 | 16384 | In: $0.10, Out: $0.30 | | meta-llama/llama-3.3-70b-instruct | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 131072 | 16384 | In: $0.10, Out: $0.32 | | meituan/longcat-2.0 | openrouter | In: text; Out: text | function_calling, reasoning, streaming, predicted_outputs | 1048756 | 262144 | In: $0.30, Out: $1.20, Cache Read: $0.01 | | inception/mercury-2 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 128000 | 50000 | In: $0.25, Out: $0.75, Cache Read: $0.02 | | xiaomi/mimo-v2.5 | openrouter | In: text, image, audio, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 1050000 | 131072 | In: $0.14, Out: $0.28, Cache Read: $0.00 | | xiaomi/mimo-v2.5-pro | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 1050000 | 131072 | In: $0.44, Out: $0.87, Cache Read: $0.00 | | minimax/minimax-m1 | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 1000000 | 40000 | In: $0.55, Out: $2.20 | | minimax/minimax-m2 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 204800 | 131072 | In: $0.26, Out: $1.02 | | minimax/minimax-m2.1 | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 204800 | 131072 | In: $0.30, Out: $1.20, Cache Read: $0.03 | | minimax/minimax-m2.5 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 204800 | 196608 | In: $0.22, Out: $0.90, Cache Read: $0.05 | | minimax/minimax-m2.7 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 204800 | 131072 | In: $0.27, Out: $1.08, Cache Read: $0.05 | | minimax/minimax-m3 | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 1048576 | 512000 | In: $0.30, Out: $1.20, Cache Read: $0.06 | | minimax/minimax-m3:batch | openrouter | In: text, image, video; Out: text | streaming, function_calling, structured_output, predicted_outputs | 524288 | - | In: $0.15, Out: $0.60, Cache Read: $0.03 | | mistralai/ministral-14b-2512 | openrouter | In: text, image; Out: text | function_calling, structured_output, vision, streaming | 262144 | 262144 | In: $0.20, Out: $0.20, Cache Read: $0.02 | | mistralai/ministral-3b-2512 | openrouter | In: text, image; Out: text | function_calling, structured_output, vision, streaming | 131072 | 131072 | In: $0.10, Out: $0.10, Cache Read: $0.01 | | mistralai/ministral-8b-2512 | openrouter | In: text, image; Out: text | function_calling, structured_output, vision, streaming | 262144 | 262144 | In: $0.15, Out: $0.15, Cache Read: $0.02 | | mistralai/mistral-large | openrouter | In: text, pdf; Out: text | function_calling, structured_output, vision, streaming | 128000 | 128000 | In: $2.00, Out: $6.00, Cache Read: $0.20 | | mistralai/mistral-large-2407 | openrouter | In: text, pdf; Out: text | function_calling, structured_output, vision, streaming | 131072 | 131072 | In: $2.00, Out: $6.00, Cache Read: $0.20 | | mistralai/mistral-large-2512 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 262144 | 262144 | In: $0.50, Out: $1.50, Cache Read: $0.05 | | mistralai/mistral-medium-3 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 131072 | 131072 | In: $0.40, Out: $2.00, Cache Read: $0.04 | | mistralai/mistral-medium-3.1 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 131072 | 262144 | In: $0.40, Out: $2.00, Cache Read: $0.04 | | mistralai/mistral-medium-3-5 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 262144 | 262144 | In: $1.50, Out: $7.50 | | mistralai/mistral-nemo | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 131072 | 16384 | In: $0.02, Out: $0.03 | | mistralai/mistral-small-3.2-24b-instruct | openrouter | In: image, text; Out: text | function_calling, structured_output, vision, streaming, predicted_outputs | 256000 | 16384 | In: $0.09, Out: $0.25 | | mistralai/mistral-small-2603 | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 262144 | 262144 | In: $0.15, Out: $0.60, Cache Read: $0.02 | | mistralai/mixtral-8x22b-instruct | openrouter | In: text, pdf; Out: text | function_calling, structured_output, vision, streaming | 65536 | 65536 | In: $2.00, Out: $6.00, Cache Read: $0.20 | | ~moonshotai/kimi-latest | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming, predicted_outputs | 1048576 | 1048576 | In: $2.50, Out: $14.00, Cache Read: $0.29 | | moonshotai/kimi-k2.7-code:batch | openrouter | In: text, image; Out: text | streaming, function_calling, structured_output, predicted_outputs | 262144 | - | In: $0.48, Out: $2.00, Cache Read: $0.10 | | meta/muse-spark-1.1 | openrouter | In: text, image, video, pdf, audio; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 1048576 | In: $1.25, Out: $4.25, Cache Read: $0.15 | | meta/muse-spark-1.2 | openrouter | In: text, image, video, pdf, audio; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 1048576 | In: $1.25, Out: $4.25, Cache Read: $0.15 | | nvidia/nemotron-3-ultra-550b-a55b:batch | openrouter | In: text; Out: text | streaming, function_calling, structured_output, predicted_outputs | 512288 | - | In: $0.30, Out: $1.80, Cache Read: $0.10 | | google/gemini-3-pro-image | openrouter | In: text, image; Out: text, image | function_calling, structured_output, reasoning, vision, streaming | 131072 | 32768 | In: $2.00, Out: $12.00, Cache Read: $0.20, Cache Write: $0.38 | | nvidia/nemotron-3-nano-30b-a3b | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 262144 | 262144 | In: $0.05, Out: $0.20, Cache Read: $0.03 | | nvidia/nemotron-3-nano-30b-a3b:free | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 256000 | 256000 | In: $0.00, Out: $0.00 | | nvidia/nemotron-3-nano-omni-30b-a3b-reasoning:free | openrouter | In: text, image, video, audio; Out: text | function_calling, reasoning, vision, video, streaming | 256000 | 65536 | In: $0.00, Out: $0.00 | | nvidia/nemotron-3-super-120b-a12b:free | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 262144 | 262144 | In: $0.00, Out: $0.00 | | nvidia/nemotron-3-super-120b-a12b | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 1000000 | 16384 | In: $0.08, Out: $0.40 | | nvidia/nemotron-3-ultra-550b-a55b:free | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 1000000 | 65536 | In: $0.00, Out: $0.00 | | nvidia/nemotron-3-ultra-550b-a55b | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 512288 | 16384 | In: $0.60, Out: $3.60, Cache Read: $0.20 | | nvidia/nemotron-nano-12b-v2-vl:free | openrouter | In: text, image, video; Out: text | function_calling, reasoning, vision, video, streaming | 128000 | 128000 | In: $0.00, Out: $0.00 | | nvidia/nemotron-nano-9b-v2:free | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 128000 | 128000 | In: $0.00, Out: $0.00 | | nex-agi/nex-n2-mini | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 262144 | 262144 | In: $0.02, Out: $0.10, Cache Read: $0.00 | | nex-agi/nex-n2-pro | openrouter | In: text, image; Out: text | function_calling, reasoning, vision, streaming | 262144 | 262144 | In: $0.25, Out: $1.00, Cache Read: $0.02 | | cohere/north-mini-code:free | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 256000 | 64000 | In: $0.00, Out: $0.00 | | amazon/nova-2-lite-v1 | openrouter | In: text, image, video, pdf; Out: text | function_calling, reasoning, vision, video, streaming | 1000000 | 65535 | In: $0.30, Out: $2.50 | | amazon/nova-lite-v1 | openrouter | In: text, image; Out: text | function_calling, vision, streaming | 300000 | 5120 | In: $0.06, Out: $0.24 | | amazon/nova-micro-v1 | openrouter | In: text; Out: text | function_calling, streaming | 128000 | 5120 | In: $0.04, Out: $0.14 | | amazon/nova-premier-v1 | openrouter | In: text, image; Out: text | function_calling, vision, streaming | 1000000 | 32000 | In: $2.50, Out: $12.50, Cache Read: $0.62 | | amazon/nova-pro-v1 | openrouter | In: text, image; Out: text | function_calling, vision, streaming | 300000 | 5120 | In: $0.80, Out: $3.20 | | ~openai/gpt-latest | openrouter | In: pdf, image, text; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $5.00, Out: $30.00, Cache Read: $0.50, Cache Write: $6.25 | | ~openai/gpt-mini-latest | openrouter | In: pdf, image, text; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $0.75, Out: $4.50, Cache Read: $0.08 | | openai/gpt-3.5-turbo:batch | openrouter | In: text; Out: text | streaming, function_calling, structured_output | 16385 | 4096 | In: $0.25, Out: $0.75 | | openai/gpt-4-turbo:batch | openrouter | In: text, image; Out: text | streaming, function_calling, structured_output | 128000 | 4096 | In: $5.00, Out: $15.00 | | openai/gpt-4.1:batch | openrouter | In: image, text, file; Out: text | streaming, function_calling, structured_output | 1047576 | 32768 | In: $1.00, Out: $4.00, Cache Read: $0.25 | | openai/gpt-4.1-mini:batch | openrouter | In: image, text, file; Out: text | streaming, function_calling, structured_output | 1047576 | 32768 | In: $0.20, Out: $0.80, Cache Read: $0.05 | | openai/gpt-4.1-nano:batch | openrouter | In: image, text, file; Out: text | streaming, function_calling, structured_output | 1047576 | 32768 | In: $0.05, Out: $0.20, Cache Read: $0.01 | | openai/gpt-4o:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 128000 | 16384 | In: $1.25, Out: $5.00, Cache Read: $0.62 | | openai/gpt-4o-mini:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 128000 | 16384 | In: $0.08, Out: $0.30, Cache Read: $0.04 | | openai/gpt-5:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 400000 | 128000 | In: $0.62, Out: $5.00, Cache Read: $0.06 | | openai/gpt-5-codex:batch | openrouter | In: text, image; Out: text | streaming, function_calling, structured_output | 400000 | 128000 | In: $0.62, Out: $5.00, Cache Read: $0.06 | | openai/gpt-5-mini:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 400000 | 128000 | In: $0.12, Out: $1.00, Cache Read: $0.01 | | openai/gpt-5-nano:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 400000 | 128000 | In: $0.02, Out: $0.20, Cache Read: $0.00 | | openai/gpt-5-pro:batch | openrouter | In: image, text, file; Out: text | streaming, function_calling, structured_output | 400000 | 128000 | In: $7.50, Out: $60.00 | | openai/gpt-5.1:batch | openrouter | In: image, text, file; Out: text | streaming, function_calling, structured_output | 400000 | 128000 | In: $0.62, Out: $5.00, Cache Read: $0.06 | | openai/gpt-5.2:batch | openrouter | In: file, image, text; Out: text | streaming, function_calling, structured_output | 400000 | 128000 | In: $0.88, Out: $7.00, Cache Read: $0.09 | | openai/gpt-5.2-pro:batch | openrouter | In: image, text, file; Out: text | streaming, function_calling, structured_output | 400000 | 128000 | In: $10.50, Out: $84.00 | | openai/gpt-5.4:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 1050000 | 128000 | In: $1.25, Out: $7.50, Cache Read: $0.12 | | openai/gpt-5.4-mini:batch | openrouter | In: file, image, text; Out: text | streaming, function_calling, structured_output | 400000 | 128000 | In: $0.38, Out: $2.25, Cache Read: $0.04 | | openai/gpt-5.4-nano:batch | openrouter | In: file, image, text; Out: text | streaming, function_calling, structured_output | 400000 | 128000 | In: $0.10, Out: $0.62, Cache Read: $0.01 | | openai/gpt-5.4-pro:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 1050000 | 128000 | In: $15.00, Out: $90.00 | | openai/gpt-5.5:batch | openrouter | In: file, image, text; Out: text | streaming, function_calling, structured_output | 1050000 | 128000 | In: $2.50, Out: $15.00, Cache Read: $0.25 | | openai/gpt-5.5-pro:batch | openrouter | In: file, image, text; Out: text | streaming, function_calling, structured_output | 1050000 | 128000 | In: $15.00, Out: $90.00 | | openai/gpt-5.6-luna:batch | openrouter | In: file, image, text; Out: text | streaming, function_calling, structured_output | 1050000 | 128000 | In: $0.10, Out: $0.60, Cache Read: $0.01 | | openai/gpt-5.6-luna-pro:batch | openrouter | In: file, image, text; Out: text | streaming, function_calling, structured_output | 1050000 | 128000 | In: $0.10, Out: $0.60, Cache Read: $0.01 | | openai/gpt-5.6-sol:batch | openrouter | In: file, image, text; Out: text | streaming, function_calling, structured_output | 1050000 | 128000 | In: $2.50, Out: $15.00, Cache Read: $0.25 | | openai/gpt-5.6-sol-pro:batch | openrouter | In: file, image, text; Out: text | streaming, function_calling, structured_output | 1050000 | 128000 | In: $2.50, Out: $15.00, Cache Read: $0.25 | | openai/gpt-5.6-terra:batch | openrouter | In: file, image, text; Out: text | streaming, function_calling, structured_output | 1050000 | 128000 | In: $1.00, Out: $6.00, Cache Read: $0.10 | | openai/gpt-5.6-terra-pro:batch | openrouter | In: file, image, text; Out: text | streaming, function_calling, structured_output | 1050000 | 128000 | In: $1.00, Out: $6.00, Cache Read: $0.10 | | openai/o1:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 200000 | 100000 | In: $7.50, Out: $30.00, Cache Read: $3.75 | | openai/o3:batch | openrouter | In: image, text, file; Out: text | streaming, function_calling, structured_output | 200000 | 100000 | In: $1.00, Out: $4.00, Cache Read: $0.25 | | openai/o3-mini:batch | openrouter | In: text, file; Out: text | streaming, function_calling, structured_output | 200000 | 100000 | In: $0.55, Out: $2.20, Cache Read: $0.28 | | openai/o3-mini-high:batch | openrouter | In: text, file; Out: text | streaming, function_calling, structured_output | 200000 | 100000 | In: $0.55, Out: $2.20, Cache Read: $0.28 | | openai/o3-pro:batch | openrouter | In: text, file, image; Out: text | streaming, function_calling, structured_output | 200000 | 100000 | In: $10.00, Out: $40.00 | | openai/o4-mini:batch | openrouter | In: image, text, file; Out: text | streaming, function_calling, structured_output | 200000 | 100000 | In: $0.55, Out: $2.20, Cache Read: $0.14 | | openai/o4-mini-high:batch | openrouter | In: image, text, file; Out: text | streaming, function_calling, structured_output | 200000 | 100000 | In: $0.55, Out: $2.20, Cache Read: $0.14 | | qwen/qwen-plus | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 1000000 | 32768 | In: $0.26, Out: $0.78, Cache Read: $0.05, Cache Write: $0.32 | | qwen/qwen-plus-2025-07-28 | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 1000000 | 32768 | In: $0.26, Out: $0.78 | | qwen/qwen-plus-2025-07-28:thinking | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 1000000 | 32768 | In: $0.40, Out: $1.20, Cache Write: $0.50 | | qwen/qwen-2.5-72b-instruct | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 32768 | 16384 | In: $0.36, Out: $0.40 | | qwen/qwen-2.5-7b-instruct | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 32768 | 32768 | In: $0.10, Out: $0.20 | | qwen/qwen3-14b | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 131072 | 8192 | In: $0.23, Out: $0.91 | | qwen/qwen3-235b-a22b-2507 | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 262144 | 16384 | In: $0.09, Out: $0.55 | | qwen/qwen3-235b-a22b-thinking-2507 | openrouter | In: text; Out: text | function_calling, reasoning, streaming, predicted_outputs | 262144 | 32768 | In: $0.23, Out: $2.30 | | qwen/qwen3-235b-a22b | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 131072 | 8192 | In: $0.46, Out: $1.82 | | qwen/qwen3-30b-a3b | openrouter | In: text; Out: text | function_calling, reasoning, streaming, predicted_outputs | 131072 | 16384 | In: $0.12, Out: $0.50 | | qwen/qwen3-30b-a3b-instruct-2507 | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 262144 | 32000 | In: $0.05, Out: $0.19 | | qwen/qwen3-30b-a3b-thinking-2507 | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 81920 | 32768 | In: $0.20, Out: $2.40 | | qwen/qwen3-32b | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 131072 | 16384 | In: $0.08, Out: $0.28 | | qwen/qwen3-8b | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 131072 | 8192 | In: $0.12, Out: $0.46 | | qwen/qwen3-coder | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 262144 | 65536 | In: $0.30, Out: $1.00, Cache Read: $0.10 | | qwen/qwen3-coder-flash | openrouter | In: text; Out: text | function_calling, streaming | 1000000 | 65536 | In: $0.20, Out: $0.98, Cache Read: $0.04, Cache Write: $0.24 | | qwen/qwen3-coder-next | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 262144 | 262144 | In: $0.12, Out: $0.80, Cache Read: $0.07 | | qwen/qwen3-coder-plus | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 1000000 | 65536 | In: $0.65, Out: $3.25, Cache Read: $0.13, Cache Write: $0.81 | | qwen/qwen3-max | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 262144 | 65536 | In: $0.78, Out: $3.90, Cache Read: $0.16, Cache Write: $0.98 | | qwen/qwen3-max-thinking | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 262144 | 65536 | In: $0.78, Out: $3.90 | | qwen/qwen3-vl-235b-a22b-instruct | openrouter | In: text, image; Out: text | function_calling, structured_output, vision, streaming, predicted_outputs | 262144 | 32768 | In: $0.21, Out: $1.90, Cache Read: $0.10 | | qwen/qwen3-vl-235b-a22b-thinking | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 131072 | 32768 | In: $0.40, Out: $4.00 | | qwen/qwen3-vl-30b-a3b-instruct | openrouter | In: text, image; Out: text | function_calling, structured_output, vision, streaming, predicted_outputs | 262144 | 16384 | In: $0.15, Out: $0.60 | | qwen/qwen3-vl-30b-a3b-thinking | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 262144 | 32768 | In: $0.20, Out: $2.40 | | qwen/qwen3-vl-32b-instruct | openrouter | In: text, image; Out: text | function_calling, structured_output, vision, streaming | 131072 | 32768 | In: $0.10, Out: $0.42 | | qwen/qwen3-vl-8b-instruct | openrouter | In: image, text; Out: text | function_calling, structured_output, vision, streaming, predicted_outputs | 262144 | 32768 | In: $0.12, Out: $0.46 | | qwen/qwen3-vl-8b-thinking | openrouter | In: image, text; Out: text | function_calling, structured_output, reasoning, vision, streaming | 131072 | 32768 | In: $0.18, Out: $2.10 | | qwen/qwen3-coder-30b-a3b-instruct | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 262144 | 32768 | In: $0.07, Out: $0.27 | | qwen/qwen3-next-80b-a3b-thinking | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 262144 | 262144 | In: $0.15, Out: $1.20 | | qwen/qwen3-next-80b-a3b-instruct | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 262144 | 16384 | In: $0.09, Out: $1.10 | | qwen/qwen3.5-122b-a10b | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 262144 | 81920 | In: $0.29, Out: $2.40 | | qwen/qwen3.5-27b | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 262144 | 65536 | In: $0.20, Out: $1.56 | | qwen/qwen3.5-35b-a3b | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 262144 | 262144 | In: $0.14, Out: $1.00 | | qwen/qwen3.5-397b-a17b | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 262144 | 65536 | In: $0.39, Out: $2.34 | | qwen/qwen3.5-9b | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 262144 | 262144 | In: $0.10, Out: $0.15 | | qwen/qwen3.5-plus-02-15 | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1000000 | 65536 | In: $0.26, Out: $1.56 | | qwen/qwen3.5-plus-20260420 | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1000000 | 65536 | In: $0.30, Out: $1.80, Cache Write: $0.38 | | qwen/qwen3.5-flash-02-23 | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1000000 | 65536 | In: $0.06, Out: $0.26 | | qwen/qwen3.6-27b | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 262144 | 262144 | In: $0.60, Out: $3.60, Cache Read: $0.12 | | qwen/qwen3.6-35b-a3b | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 262144 | 262144 | In: $0.14, Out: $1.00, Cache Read: $0.05 | | qwen/qwen3.6-flash | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1000000 | 65536 | In: $0.19, Out: $1.12, Cache Write: $0.23 | | qwen/qwen3.6-max-preview | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 262144 | 65536 | In: $1.03, Out: $6.16, Cache Write: $1.28 | | qwen/qwen3.6-plus | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1000000 | 65536 | In: $0.32, Out: $1.95, Cache Write: $0.41 | | qwen/qwen3.7-flash | openrouter | In: text, image, video; Out: text | function_calling, reasoning, vision, video, streaming | 1000000 | 65536 | In: $0.03, Out: $0.13, Cache Read: $0.01, Cache Write: $0.04 | | qwen/qwen3.7-max | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 1000000 | 131072 | In: $1.48, Out: $4.42, Cache Read: $0.30, Cache Write: $1.84 | | qwen/qwen3.7-plus | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 131072 | In: $0.32, Out: $1.28, Cache Read: $0.06, Cache Write: $0.40 | | qwen/qwen3.8-max | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1000000 | 131072 | In: $2.00, Out: $6.00, Cache Read: $0.25, Cache Write: $2.50 | | deepseek/deepseek-r1-0528 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 163840 | 32768 | In: $0.50, Out: $2.15, Cache Read: $0.35 | | rekaai/reka-edge | openrouter | In: image, text, video; Out: text | function_calling, structured_output, vision, video, streaming | 16384 | 16384 | In: $0.10, Out: $0.10 | | relace/relace-search | openrouter | In: text; Out: text | function_calling, streaming | 256000 | 128000 | In: $1.00, Out: $3.00 | | inclusionai/ring-2.6-1t | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 262144 | 65536 | In: $0.08, Out: $0.62, Cache Read: $0.02 | | mistralai/mistral-saba | openrouter | In: text, pdf; Out: text | function_calling, structured_output, vision, streaming | 32768 | 32768 | In: $0.20, Out: $0.60, Cache Read: $0.02 | | bytedance-seed/seed-1.6 | openrouter | In: image, text, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 262144 | 32768 | In: $0.25, Out: $2.00 | | bytedance-seed/seed-1.6-flash | openrouter | In: image, text, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 262144 | 32768 | In: $0.08, Out: $0.30 | | bytedance-seed/seed-2.0-lite | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 262144 | 131072 | In: $0.25, Out: $2.00 | | bytedance-seed/seed-2.0-mini | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 262144 | 131072 | In: $0.10, Out: $0.40 | | upstage/solar-pro-3 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 131072 | 131072 | In: $0.15, Out: $0.60, Cache Read: $0.02 | | stepfun/step-3.5-flash | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 262144 | 65536 | In: $0.10, Out: $0.30 | | stepfun/step-3.7-flash | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 262144 | 256000 | In: $0.20, Out: $1.15, Cache Read: $0.04 | | thinkingmachines/inkling:batch | openrouter | In: text, image, audio; Out: text | streaming, function_calling, predicted_outputs | 524288 | - | In: $0.50, Out: $2.02, Cache Read: $0.08 | | arcee-ai/trinity-large-thinking | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 262144 | 262144 | In: $0.22, Out: $0.85, Cache Read: $0.06 | | thedrummer/unslopnemo-12b | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 1024000 | 1024000 | In: $0.40, Out: $0.40 | | arcee-ai/virtuoso-large | openrouter | In: text; Out: text | function_calling, streaming, predicted_outputs | 131072 | 64000 | In: $0.75, Out: $1.20 | | mistralai/voxtral-small-24b-2507 | openrouter | In: text, audio, pdf; Out: text | function_calling, structured_output, vision, streaming | 32000 | 32000 | In: $0.10, Out: $0.30, Cache Read: $0.01 | | z-ai/glm-5.2:batch | openrouter | In: text; Out: text | streaming, function_calling, structured_output, predicted_outputs | 512000 | - | In: $0.70, Out: $2.20, Cache Read: $0.13 | | openai/gpt-oss-20b:free | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 131072 | 32768 | In: $0.00, Out: $0.00 | | openai/gpt-oss-safeguard-20b | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 131072 | 65536 | In: $0.08, Out: $0.30, Cache Read: $0.04 | | openai/o1 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 100000 | In: $15.00, Out: $60.00, Cache Read: $7.50 | | openai/o3 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 100000 | In: $2.00, Out: $8.00, Cache Read: $0.50 | | openai/o3-mini-high | openrouter | In: text, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 100000 | In: $1.10, Out: $4.40, Cache Read: $0.55 | | openai/o3-mini | openrouter | In: text, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 100000 | In: $1.10, Out: $4.40, Cache Read: $0.55 | | openai/o3-pro | openrouter | In: text, pdf, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 100000 | In: $20.00, Out: $80.00 | | openai/o4-mini-high | openrouter | In: image, text, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 100000 | In: $1.10, Out: $4.40, Cache Read: $0.28 | | openai/o4-mini | openrouter | In: image, text, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 100000 | In: $1.10, Out: $4.40, Cache Read: $0.28 | | claude-3-5-haiku | vertexai | In: text, image, pdf; Out: text | function_calling, vision | 200000 | 8192 | In: $0.80, Out: $4.00, Cache Read: $0.08, Cache Write: $1.00 | | claude-haiku-4-5 | vertexai | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 200000 | 64000 | In: $1.00, Out: $5.00, Cache Read: $0.10, Cache Write: $1.25 | | claude-opus-4 | vertexai | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 200000 | 32000 | In: $15.00, Out: $75.00, Cache Read: $1.50, Cache Write: $18.75 | | claude-opus-4-1 | vertexai | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 200000 | 32000 | In: $15.00, Out: $75.00, Cache Read: $1.50, Cache Write: $18.75 | | claude-opus-4-5 | vertexai | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 200000 | 64000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | claude-opus-4-6 | vertexai | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | claude-opus-4-7 | vertexai | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | claude-opus-4-8 | vertexai | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | claude-opus-5 | vertexai | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | claude-sonnet-4 | vertexai | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 200000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | claude-sonnet-4-5 | vertexai | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 200000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | claude-sonnet-4-6 | vertexai | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 1000000 | 128000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | claude-sonnet-5 | vertexai | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 1000000 | 128000 | In: $2.00, Out: $10.00, Cache Read: $0.20, Cache Write: $2.50 | | deepseek-ai/deepseek-v3.1-maas | vertexai | In: text, pdf; Out: text | function_calling, structured_output, reasoning, vision | 163840 | 32768 | In: $0.60, Out: $1.70 | | deepseek-ai/deepseek-v3.2-maas | vertexai | In: text, pdf; Out: text | function_calling, structured_output, reasoning, vision | 163840 | 65536 | In: $0.56, Out: $1.68, Cache Read: $0.06 | | zai-org/glm-4.7-maas | vertexai | In: text, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 128000 | In: $0.60, Out: $2.20 | | zai-org/glm-5-maas | vertexai | In: text; Out: text | function_calling, reasoning | 202752 | 131072 | In: $1.00, Out: $3.20, Cache Read: $0.10 | | openai/gpt-oss-120b-maas | vertexai | In: text; Out: text | function_calling, reasoning | 131072 | 32768 | In: $0.09, Out: $0.36 | | openai/gpt-oss-20b-maas | vertexai | In: text; Out: text | function_calling, reasoning | 131072 | 32768 | In: $0.07, Out: $0.25 | | gemini-2.0-flash | vertexai | In: text, image, audio, video, pdf; Out: text | function_calling, structured_output, vision, video, streaming | 1048576 | 8192 | In: $0.10, Out: $0.40, Cache Read: $0.02 | | gemini-2.5-flash | vertexai | In: text, image, audio, video, pdf; Out: text | function_calling, reasoning, vision, video, streaming | 1048576 | 65536 | In: $0.30, Out: $2.50, Cache Read: $0.08, Cache Write: $0.38 | | gemini-2.5-flash-lite | vertexai | In: text, image, audio, video, pdf; Out: text | function_calling, reasoning, vision, video, streaming | 1048576 | 65536 | In: $0.10, Out: $0.40, Cache Read: $0.01 | | gemini-2.5-pro | vertexai | In: text, image, audio, video, pdf; Out: text | function_calling, reasoning, vision, video, streaming | 1048576 | 65536 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gemini-3-flash-preview | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $0.50, Out: $3.00, Cache Read: $0.05 | | gemini-3.1-flash-lite | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $0.25, Out: $1.50, Cache Read: $0.02 | | gemini-3.1-flash-lite-preview | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $0.25, Out: $1.50, Cache Read: $0.02 | | gemini-3.1-pro-preview | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $2.00, Out: $12.00, Cache Read: $0.20 | | gemini-3.1-pro-preview-customtools | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video | 1048576 | 65536 | In: $2.00, Out: $12.00, Cache Read: $0.20 | | gemini-3.5-flash | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $1.50, Out: $9.00, Cache Read: $0.15 | | gemini-3.5-flash-lite | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video | 1048576 | 65536 | In: $0.30, Out: $2.50, Cache Read: $0.03 | | gemini-3.6-flash | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video | 1048576 | 65536 | In: $1.50, Out: $7.50, Cache Read: $0.15 | | gemini-flash-latest | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video | 1048576 | 65536 | In: $1.50, Out: $9.00, Cache Read: $0.15 | | gemini-flash-lite-latest | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, reasoning, vision, video | 1048576 | 65536 | In: $0.25, Out: $1.50, Cache Read: $0.02 | | moonshotai/kimi-k2-thinking-maas | vertexai | In: text; Out: text | function_calling, structured_output, reasoning | 262144 | 262144 | In: $0.60, Out: $2.50 | | meta/llama-3.3-70b-instruct-maas | vertexai | In: text; Out: text | function_calling, structured_output | 128000 | 8192 | In: $0.72, Out: $0.72 | | meta/llama-4-maverick-17b-128e-instruct-maas | vertexai | In: text, image; Out: text | function_calling, structured_output, vision | 524288 | 8192 | In: $0.35, Out: $1.15 | | gemini-3.1-flash-lite-image | vertexai | In: text, image; Out: text, image | function_calling, reasoning, vision, streaming | 65536 | 65536 | In: $0.25, Out: $30.00 | | qwen/qwen3-235b-a22b-instruct-2507-maas | vertexai | In: text; Out: text | function_calling, structured_output, reasoning | 262144 | 16384 | In: $0.22, Out: $0.88 | | claude-fable-5 | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | codestral-2 | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | gemini-1.5-flash | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | gemini-1.5-flash-002 | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | gemini-1.5-flash-8b | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | gemini-1.5-pro | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | gemini-1.5-pro-002 | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | gemini-2.0-flash-001 | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | gemini-2.0-flash-exp | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | gemini-2.0-flash-lite-001 | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | gemini-2.5-flash-preview-04-17 | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | gemini-2.5-pro-exp-03-25 | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | gemini-exp-1121 | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | gemini-exp-1206 | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | gemini-live-2.5-flash-native-audio | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | gemini-pro | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | gemini-pro-vision | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | mistral-medium-3 | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | mistral-small-2503 | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | text-embedding-004 | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | text-embedding-005 | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | text-multilingual-embedding-002 | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | grok-4.20-0309-non-reasoning | xai | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 1000000 | 30000 | In: $1.25, Out: $2.50, Cache Read: $0.20 | | grok-4.20-0309-reasoning | xai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 30000 | In: $1.25, Out: $2.50, Cache Read: $0.20 | | grok-4.3 | xai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 30000 | In: $1.25, Out: $2.50, Cache Read: $0.20 | | grok-4.5 | xai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 500000 | 500000 | In: $2.00, Out: $6.00, Cache Read: $0.30 | | grok-build-0.1 | xai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 256000 | 256000 | In: $1.00, Out: $2.00, Cache Read: $0.20 | ### Structured Output (594) | Model | Provider | I/O | Capabilities | Context | Max Output | Standard Pricing (per 1M tokens) | | :-- | :-- | :-- | :-- | --: | --: | :-- | | claude-fable-5 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, citations, tool_choice, parallel_tool_calls | 1000000 | 128000 | In: $10.00, Out: $50.00, Cache Read: $1.00, Cache Write: $12.50 | | claude-haiku-4-5-20251001 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, citations, tool_choice, parallel_tool_calls | 200000 | 64000 | In: $1.00, Out: $5.00, Cache Read: $0.10, Cache Write: $1.25 | | claude-haiku-4-5 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $1.00, Out: $5.00, Cache Read: $0.10, Cache Write: $1.25 | | claude-opus-4-5-20251101 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, citations, tool_choice, parallel_tool_calls | 200000 | 64000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | claude-opus-4-5 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | claude-opus-4-6 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, citations, tool_choice, parallel_tool_calls | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | claude-opus-4-7 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, citations, tool_choice, parallel_tool_calls | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | claude-opus-4-8 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, citations, tool_choice, parallel_tool_calls | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | claude-opus-5 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, citations, tool_choice, parallel_tool_calls | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | claude-sonnet-4-5-20250929 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, citations, tool_choice, parallel_tool_calls | 1000000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | claude-sonnet-4-5 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | claude-sonnet-4-6 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, citations, tool_choice, parallel_tool_calls | 1000000 | 128000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | claude-sonnet-5 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, citations, tool_choice, parallel_tool_calls | 1000000 | 128000 | In: $2.00, Out: $10.00, Cache Read: $0.20, Cache Write: $2.50 | | gpt-4.1 | azure | In: -; Out: - | function_calling, structured_output, vision | 1047576 | 32768 | In: $2.00, Out: $8.00, Cache Read: $0.50 | | gpt-4.1-2025-04-14 | azure | In: -; Out: - | function_calling, structured_output, vision | 1047576 | 32768 | In: $2.00, Out: $8.00, Cache Read: $0.50 | | gpt-4.1-2025-04-14-text | azure | In: -; Out: - | function_calling, structured_output, vision | 1047576 | 32768 | In: $2.00, Out: $8.00, Cache Read: $0.50 | | gpt-4.1-mini | azure | In: -; Out: - | function_calling, structured_output, vision | 1047576 | 32768 | In: $0.40, Out: $1.60, Cache Read: $0.10 | | gpt-4.1-mini-2025-04-14 | azure | In: -; Out: - | function_calling, structured_output, vision | 1047576 | 32768 | In: $0.40, Out: $1.60, Cache Read: $0.10 | | gpt-4.1-nano | azure | In: -; Out: - | function_calling, structured_output, vision | 1047576 | 32768 | In: $0.10, Out: $0.40 | | gpt-4.1-nano-2025-04-14 | azure | In: -; Out: - | function_calling, structured_output, vision | 1047576 | 32768 | In: $0.10, Out: $0.40 | | gpt-4o | azure | In: -; Out: - | function_calling, structured_output, vision | 128000 | 16384 | In: $2.50, Out: $10.00 | | gpt-4o-2024-05-13 | azure | In: -; Out: - | function_calling, structured_output, vision | 128000 | 16384 | In: $2.50, Out: $10.00 | | gpt-4o-2024-08-06 | azure | In: -; Out: - | function_calling, structured_output, vision | 128000 | 16384 | In: $2.50, Out: $10.00 | | gpt-4o-2024-11-20 | azure | In: -; Out: - | function_calling, structured_output, vision | 128000 | 16384 | In: $2.50, Out: $10.00 | | gpt-4o-canvas-2024-09-25 | azure | In: -; Out: - | function_calling, structured_output, vision | 128000 | 16384 | In: $2.50, Out: $10.00 | | gpt-4o-mini | azure | In: -; Out: - | function_calling, structured_output, vision | 128000 | 16384 | In: $0.15, Out: $0.60 | | gpt-4o-mini-2024-07-18 | azure | In: -; Out: - | function_calling, structured_output, vision | 128000 | 16384 | In: $0.15, Out: $0.60 | | gpt-5-2025-08-07 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5-chat-2025-08-07 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5-chat-2025-08-15 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5-chat-2025-10-03 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5-codex-2025-09-15 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5-mini-2025-08-07 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $0.25, Out: $2.00, Cache Read: $0.02 | | gpt-5-mini-2025-08-07-lite | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $0.25, Out: $2.00, Cache Read: $0.02 | | gpt-5-mini-lite-2025-08-07 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $0.25, Out: $2.00, Cache Read: $0.02 | | gpt-5-nano-2025-08-07 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $0.05, Out: $0.40, Cache Read: $0.01 | | gpt-5-pro-2025-10-06 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.1 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.1-2025-11-13 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.1-chat-2025-11-13 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.1-codex-2025-11-13 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.1-codex-max-2025-12-04 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.1-codex-mini-2025-11-13 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $0.25, Out: $2.00, Cache Read: $0.02 | | gpt-5.2-2025-12-11 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.2-chat-2025-12-11 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.2-chat-2026-02-10 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.2-codex-2026-01-14 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.3-chat-2026-03-03 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.3-codex-2026-02-20 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.3-codex-2026-02-24 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.4-2026-03-05 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.4-mini-2026-03-17 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $0.25, Out: $2.00, Cache Read: $0.02 | | gpt-5.4-nano-2026-03-17 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $0.05, Out: $0.40, Cache Read: $0.01 | | gpt-5.4-pro-2026-03-05 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.5-2026-04-24 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | o1-2024-12-17 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 200000 | 100000 | In: $15.00, Out: $60.00 | | o1-pro | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 200000 | 100000 | In: $150.00, Out: $600.00 | | o1-pro-2025-03-19 | azure | In: -; Out: - | function_calling, structured_output, vision, reasoning | 200000 | 100000 | In: $150.00, Out: $600.00 | | o3-mini | azure | In: -; Out: - | function_calling, structured_output, reasoning | 200000 | 100000 | In: $1.10, Out: $4.40 | | o3-mini-2025-01-31 | azure | In: -; Out: - | function_calling, structured_output, reasoning | 200000 | 100000 | In: $1.10, Out: $4.40 | | o3-mini-alpha | azure | In: -; Out: - | function_calling, structured_output, reasoning | 200000 | 100000 | In: $1.10, Out: $4.40 | | o3-mini-alpha-2024-12-17 | azure | In: -; Out: - | function_calling, structured_output, reasoning | 200000 | 100000 | In: $1.10, Out: $4.40 | | au.anthropic.claude-opus-4-6-v1 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 128000 | In: $16.50, Out: $82.50, Cache Read: $1.65, Cache Write: $20.62 | | au.anthropic.claude-sonnet-4-6 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 128000 | In: $3.30, Out: $16.50, Cache Read: $0.33, Cache Write: $4.12 | | anthropic.claude-haiku-4-5-20251001-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $1.00, Out: $5.00, Cache Read: $0.10, Cache Write: $1.25 | | au.anthropic.claude-haiku-4-5-20251001-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $1.00, Out: $5.00, Cache Read: $0.10, Cache Write: $1.25 | | eu.anthropic.claude-haiku-4-5-20251001-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $1.10, Out: $5.50, Cache Read: $0.11, Cache Write: $1.38 | | global.anthropic.claude-haiku-4-5-20251001-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $1.00, Out: $5.00, Cache Read: $0.10, Cache Write: $1.25 | | jp.anthropic.claude-haiku-4-5-20251001-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $1.00, Out: $5.00, Cache Read: $0.10, Cache Write: $1.25 | | us.anthropic.claude-haiku-4-5-20251001-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 64000 | In: $1.00, Out: $5.00, Cache Read: $0.10, Cache Write: $1.25 | | anthropic.claude-opus-4-5-20251101-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | eu.anthropic.claude-opus-4-5-20251101-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $5.50, Out: $27.50, Cache Read: $0.55, Cache Write: $6.88 | | global.anthropic.claude-opus-4-5-20251101-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | us.anthropic.claude-opus-4-5-20251101-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 64000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | anthropic.claude-opus-4-6-v1 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | eu.anthropic.claude-opus-4-6-v1 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 128000 | In: $5.50, Out: $27.50, Cache Read: $0.55, Cache Write: $6.88 | | global.anthropic.claude-opus-4-6-v1 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | us.anthropic.claude-opus-4-6-v1 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | anthropic.claude-sonnet-4-5-20250929-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | au.anthropic.claude-sonnet-4-5-20250929-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | eu.anthropic.claude-sonnet-4-5-20250929-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $3.30, Out: $16.50, Cache Read: $0.33, Cache Write: $4.12 | | global.anthropic.claude-sonnet-4-5-20250929-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | jp.anthropic.claude-sonnet-4-5-20250929-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | us.anthropic.claude-sonnet-4-5-20250929-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | anthropic.claude-sonnet-4-6 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | eu.anthropic.claude-sonnet-4-6 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 64000 | In: $3.30, Out: $16.50, Cache Read: $0.33, Cache Write: $4.12 | | global.anthropic.claude-sonnet-4-6 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | jp.anthropic.claude-sonnet-4-6 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | us.anthropic.claude-sonnet-4-6 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | anthropic.claude-sonnet-5 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 128000 | In: $2.00, Out: $10.00, Cache Read: $0.20, Cache Write: $2.50 | | au.anthropic.claude-sonnet-5 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 128000 | In: $2.00, Out: $10.00, Cache Read: $0.20, Cache Write: $2.50 | | eu.anthropic.claude-sonnet-5 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 128000 | In: $2.20, Out: $11.00, Cache Read: $0.22, Cache Write: $2.75 | | global.anthropic.claude-sonnet-5 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 128000 | In: $2.00, Out: $10.00, Cache Read: $0.20, Cache Write: $2.50 | | jp.anthropic.claude-sonnet-5 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 128000 | In: $2.00, Out: $10.00, Cache Read: $0.20, Cache Write: $2.50 | | us.anthropic.claude-sonnet-5 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $2.00, Out: $10.00, Cache Read: $0.20, Cache Write: $2.50 | | deepseek.v3-v1:0 | bedrock | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 163840 | 81920 | In: $0.58, Out: $1.68 | | deepseek.v3.2 | bedrock | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 163840 | 81920 | In: $0.62, Out: $1.85 | | mistral.devstral-2-123b | bedrock | In: text; Out: text | function_calling, structured_output, streaming | 256000 | 8192 | In: $0.40, Out: $2.00 | | zai.glm-4.7 | bedrock | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 204800 | 131072 | In: $0.60, Out: $2.20 | | zai.glm-4.7-flash | bedrock | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 200000 | 131072 | In: $0.07, Out: $0.40 | | zai.glm-5 | bedrock | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 202752 | 101376 | In: $1.00, Out: $3.20 | | openai.gpt-oss-safeguard-120b | bedrock | In: text; Out: text | function_calling, structured_output, streaming | 128000 | 16384 | In: $0.15, Out: $0.60 | | openai.gpt-oss-safeguard-20b | bedrock | In: text; Out: text | function_calling, structured_output, streaming | 128000 | 16384 | In: $0.07, Out: $0.20 | | openai.gpt-5.4 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 272000 | 128000 | In: $2.75, Out: $16.50, Cache Read: $0.28 | | openai.gpt-5.5 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 272000 | 128000 | In: $5.50, Out: $33.00, Cache Read: $0.55 | | openai.gpt-5.6-luna | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 272000 | 128000 | In: $0.22, Out: $1.32, Cache Read: $0.02, Cache Write: $0.28 | | openai.gpt-5.6-sol | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 272000 | 128000 | In: $5.50, Out: $33.00, Cache Read: $0.55, Cache Write: $6.88 | | openai.gpt-5.6-terra | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 272000 | 128000 | In: $2.20, Out: $13.20, Cache Read: $0.22, Cache Write: $2.75 | | google.gemma-3-12b-it | bedrock | In: text, image; Out: text | structured_output, vision, streaming | 131072 | 8192 | In: $0.05, Out: $0.10 | | google.gemma-3-27b-it | bedrock | In: text, image; Out: text | function_calling, structured_output, vision, streaming | 202752 | 8192 | In: $0.12, Out: $0.20 | | xai.grok-4.3 | bedrock | In: text, image; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 131072 | In: $1.25, Out: $2.50, Cache Read: $0.20 | | moonshot.kimi-k2-thinking | bedrock | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 262143 | 16000 | In: $0.60, Out: $2.50 | | moonshotai.kimi-k2.5 | bedrock | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 262143 | 16000 | In: $0.60, Out: $3.00 | | mistral.magistral-small-2509 | bedrock | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 128000 | 40000 | In: $0.50, Out: $1.50 | | mistral.ministral-3-14b-instruct | bedrock | In: text; Out: text | function_calling, structured_output, streaming | 128000 | 4096 | In: $0.20, Out: $0.20 | | mistral.ministral-3-3b-instruct | bedrock | In: text, image; Out: text | function_calling, structured_output, vision, streaming | 256000 | 8192 | In: $0.10, Out: $0.10 | | mistral.ministral-3-8b-instruct | bedrock | In: text; Out: text | function_calling, structured_output, streaming | 128000 | 4096 | In: $0.15, Out: $0.15 | | mistral.mistral-large-3-675b-instruct | bedrock | In: text, image; Out: text | function_calling, structured_output, vision, streaming | 256000 | 8192 | In: $0.50, Out: $1.50 | | nvidia.nemotron-super-3-120b | bedrock | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 262144 | 131072 | In: $0.15, Out: $0.65 | | nvidia.nemotron-nano-12b-v2 | bedrock | In: text, image; Out: text | function_calling, structured_output, vision, streaming | 128000 | 4096 | In: $0.20, Out: $0.60 | | nvidia.nemotron-nano-3-30b | bedrock | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 128000 | 4096 | In: $0.06, Out: $0.24 | | nvidia.nemotron-nano-9b-v2 | bedrock | In: text; Out: text | function_calling, structured_output, streaming | 128000 | 4096 | In: $0.06, Out: $0.23 | | qwen.qwen3-next-80b-a3b | bedrock | In: text; Out: text | function_calling, structured_output, streaming | 262000 | 262000 | In: $0.14, Out: $1.40 | | qwen.qwen3-vl-235b-a22b | bedrock | In: text, image; Out: text | function_calling, structured_output, vision, streaming | 262000 | 262000 | In: $0.30, Out: $1.50 | | qwen.qwen3-235b-a22b-2507-v1:0 | bedrock | In: text; Out: text | function_calling, structured_output, streaming | 262144 | 131072 | In: $0.22, Out: $0.88 | | qwen.qwen3-32b-v1:0 | bedrock | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 16384 | 16384 | In: $0.15, Out: $0.60 | | qwen.qwen3-coder-30b-a3b-v1:0 | bedrock | In: text; Out: text | function_calling, structured_output, streaming | 262144 | 131072 | In: $0.15, Out: $0.60 | | qwen.qwen3-coder-480b-a35b-v1:0 | bedrock | In: text; Out: text | function_calling, structured_output, streaming | 131072 | 65536 | In: $0.22, Out: $1.80 | | qwen.qwen3-coder-next | bedrock | In: text; Out: text | function_calling, structured_output, reasoning | 131072 | 65536 | In: $0.22, Out: $1.80 | | mistral.voxtral-mini-3b-2507 | bedrock | In: audio, text; Out: text | function_calling, structured_output, streaming | 128000 | 4096 | In: $0.04, Out: $0.04 | | mistral.voxtral-small-24b-2507 | bedrock | In: text, audio; Out: text | function_calling, structured_output, streaming | 32000 | 8192 | In: $0.15, Out: $0.35 | | openai.gpt-oss-120b | bedrock | In: text; Out: text | function_calling, structured_output, reasoning | 128000 | 16384 | In: $0.15, Out: $0.60 | | openai.gpt-oss-120b-1:0 | bedrock | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 128000 | 16384 | In: $0.15, Out: $0.60 | | openai.gpt-oss-20b | bedrock | In: text; Out: text | function_calling, structured_output, reasoning | 128000 | 16384 | In: $0.07, Out: $0.30 | | openai.gpt-oss-20b-1:0 | bedrock | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 128000 | 16384 | In: $0.07, Out: $0.30 | | deepseek-v4-flash | deepseek | In: text; Out: text | function_calling, structured_output, reasoning, tool_choice | 1000000 | 384000 | In: $0.14, Out: $0.28, Cache Read: $0.00 | | deepseek-v4-pro | deepseek | In: text; Out: text | function_calling, structured_output, reasoning, tool_choice | 1000000 | 384000 | In: $0.44, Out: $0.87, Cache Read: $0.00 | | deep-research-pro-preview-12-2025 | gemini | In: -; Out: - | function_calling, tool_choice, structured_output, vision | 131072 | 65536 | In: $0.08, Out: $0.30 | | gemini-2.0-flash | gemini | In: text, image, audio, video, pdf; Out: text | function_calling, structured_output, vision, video, tool_choice | 1048576 | 8192 | In: $0.10, Out: $0.40, Cache Read: $0.02 | | gemini-2.0-flash-001 | gemini | In: -; Out: - | function_calling, tool_choice, structured_output, vision | 1048576 | 8192 | In: $0.10, Out: $0.40 | | gemini-2.0-flash-lite | gemini | In: text, image, audio, video, pdf; Out: text | function_calling, structured_output, vision, video | 1048576 | 8192 | In: $0.08, Out: $0.30 | | gemini-2.5-flash | gemini | In: text, image, audio, video, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, tool_choice | 1048576 | 65536 | In: $0.30, Out: $2.50, Cache Read: $0.03 | | gemini-2.5-flash-lite | gemini | In: text, image, audio, video, pdf; Out: text | function_calling, structured_output, reasoning, vision, video | 1048576 | 65536 | In: $0.10, Out: $0.40, Cache Read: $0.01 | | gemini-2.5-pro | gemini | In: text, image, audio, video, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, tool_choice | 1048576 | 65536 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gemini-3-flash-preview | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, tool_choice | 1048576 | 65536 | In: $0.50, Out: $3.00, Cache Read: $0.05 | | gemini-3-pro-preview | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, tool_choice | 1048576 | 65536 | In: $2.00, Out: $12.00, Cache Read: $0.20 | | gemini-3.1-flash-lite | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video | 1048576 | 65536 | In: $0.25, Out: $1.50, Cache Read: $0.02 | | gemini-3.1-flash-lite-preview | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video | 1048576 | 65536 | In: $0.25, Out: $1.50, Cache Read: $0.02 | | gemini-3.1-pro-preview | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, tool_choice | 1048576 | 65536 | In: $2.00, Out: $12.00, Cache Read: $0.20 | | gemini-3.1-pro-preview-customtools | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, tool_choice | 1048576 | 65536 | In: $2.00, Out: $12.00, Cache Read: $0.20 | | gemini-3.5-flash | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, tool_choice | 1048576 | 65536 | In: $1.50, Out: $9.00, Cache Read: $0.15 | | gemini-3.5-flash-lite | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video | 1048576 | 65536 | In: $0.30, Out: $2.50, Cache Read: $0.03 | | gemini-3.6-flash | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, tool_choice | 1048576 | 65536 | In: $1.50, Out: $7.50, Cache Read: $0.15 | | gemini-embedding-2-preview | gemini | In: -; Out: - | function_calling, tool_choice, structured_output, vision | 8192 | 1 | In: $0.00, Out: $0.00 | | gemini-flash-latest | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, tool_choice | 1048576 | 65536 | In: $1.50, Out: $9.00, Cache Read: $0.15 | | gemini-flash-lite-latest | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video | 1048576 | 65536 | In: $0.25, Out: $1.50, Cache Read: $0.02 | | gemini-pro-latest | gemini | In: -; Out: - | function_calling, tool_choice, structured_output, vision | 1048576 | 65536 | In: $0.08, Out: $0.30 | | gemini-robotics-er-1.5-preview | gemini | In: -; Out: - | function_calling, tool_choice, structured_output, vision | 1048576 | 65536 | In: $0.08, Out: $0.30 | | gemini-robotics-er-1.6-preview | gemini | In: text, image, video, audio; Out: text | function_calling, structured_output, reasoning, vision, video, tool_choice | 131072 | 65536 | In: $1.00, Out: $5.00 | | gemini-robotics-er-2-preview | gemini | In: -; Out: - | function_calling, tool_choice, structured_output, vision | 131072 | 65536 | In: $0.08, Out: $0.30 | | gemma-4-26b-a4b-it | gemini | In: text, image; Out: text | function_calling, structured_output, reasoning, vision | 262144 | 32768 | In: $0.08, Out: $0.30 | | gemma-4-31b-it | gemini | In: text, image; Out: text | function_calling, structured_output, reasoning, vision | 262144 | 32768 | In: $0.08, Out: $0.30 | | nano-banana-pro-preview | gemini | In: -; Out: - | function_calling, tool_choice, structured_output, vision | 131072 | 32768 | In: $0.08, Out: $0.30 | | codestral-2508 | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, predicted_outputs, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | labs-leanstral-1-5 | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | labs-leanstral-1-5-1 | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | magistral-medium-2509 | mistral | In: text; Out: text | streaming, function_calling, structured_output, reasoning, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | magistral-small-2509 | mistral | In: text; Out: text | streaming, function_calling, structured_output, reasoning, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | magistral-small-latest | mistral | In: text; Out: text | streaming, function_calling, structured_output, reasoning, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | ministral-14b-2512 | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, distillation, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | ministral-14b-latest | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, distillation, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | ministral-3b-2512 | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, distillation, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | ministral-8b-2512 | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, distillation, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | mistral-code-agent-latest | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | mistral-code-fim-latest | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | mistral-code-latest | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | mistral-medium | mistral | In: text; Out: text | streaming, function_calling, structured_output, vision, batch, fine_tuning, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | mistral-medium-3 | mistral | In: text; Out: text | streaming, function_calling, structured_output, vision, reasoning, batch, fine_tuning, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | mistral-medium-3-5 | mistral | In: text; Out: text | streaming, function_calling, structured_output, vision, reasoning, batch, fine_tuning, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | mistral-medium-3.5 | mistral | In: text; Out: text | streaming, function_calling, structured_output, vision, reasoning, batch, fine_tuning, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | mistral-medium-latest | mistral | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming, batch, fine_tuning, tool_choice, parallel_tool_calls | 262144 | 262144 | In: $1.50, Out: $7.50 | | mistral-medium-2604 | mistral | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming, batch, fine_tuning, tool_choice, parallel_tool_calls | 262144 | 262144 | In: $1.50, Out: $7.50 | | mistral-tiny-2407 | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | mistral-tiny-latest | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | mistral-vibe-cli-fast | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | mistral-vibe-cli-latest | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | mistral-vibe-cli-with-tools | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | open-mistral-nemo-2407 | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | gpt-4.1 | openai | In: text, image, pdf; Out: text | function_calling, structured_output, vision, tool_choice, parallel_tool_calls | 1047576 | 32768 | In: $2.00, Out: $8.00, Cache Read: $0.50 | | gpt-4.1-mini | openai | In: text, image, pdf; Out: text | function_calling, structured_output, vision, tool_choice, parallel_tool_calls | 1047576 | 32768 | In: $0.40, Out: $1.60, Cache Read: $0.10 | | gpt-4.1-nano | openai | In: text, image; Out: text | function_calling, structured_output, vision, tool_choice, parallel_tool_calls | 1047576 | 32768 | In: $0.10, Out: $0.40, Cache Read: $0.02 | | gpt-4o | openai | In: text, image, pdf; Out: text | function_calling, structured_output, vision, tool_choice, parallel_tool_calls | 128000 | 16384 | In: $2.50, Out: $10.00, Cache Read: $1.25 | | gpt-4o-2024-05-13 | openai | In: text, image; Out: text | function_calling, structured_output, vision, tool_choice, parallel_tool_calls | 128000 | 4096 | In: $5.00, Out: $15.00 | | gpt-4o-2024-08-06 | openai | In: text, image; Out: text | function_calling, structured_output, vision, tool_choice, parallel_tool_calls | 128000 | 16384 | In: $2.50, Out: $10.00, Cache Read: $1.25 | | gpt-4o-2024-11-20 | openai | In: text, image; Out: text | function_calling, structured_output, vision, tool_choice, parallel_tool_calls | 128000 | 16384 | In: $2.50, Out: $10.00, Cache Read: $1.25 | | gpt-4o-mini | openai | In: text, image, pdf; Out: text | function_calling, structured_output, vision, tool_choice, parallel_tool_calls | 128000 | 16384 | In: $0.15, Out: $0.60, Cache Read: $0.08 | | gpt-5 | openai | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 400000 | 128000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5-mini | openai | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 400000 | 128000 | In: $0.25, Out: $2.00, Cache Read: $0.02 | | gpt-5-nano | openai | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 400000 | 128000 | In: $0.05, Out: $0.40, Cache Read: $0.01 | | gpt-5-pro | openai | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 400000 | 272000 | In: $15.00, Out: $120.00 | | gpt-5.1 | openai | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 400000 | 128000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.2 | openai | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 400000 | 128000 | In: $1.75, Out: $14.00, Cache Read: $0.18 | | gpt-5.2-chat-latest | openai | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 128000 | 16384 | In: $1.75, Out: $14.00, Cache Read: $0.18 | | gpt-5.3-chat-latest | openai | In: text, image; Out: text | function_calling, structured_output, vision, tool_choice, parallel_tool_calls | 128000 | 16384 | In: $1.75, Out: $14.00, Cache Read: $0.18 | | gpt-5.3-codex | openai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 400000 | 128000 | In: $1.75, Out: $14.00, Cache Read: $0.18 | | gpt-5.3-codex-spark | openai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 128000 | 32000 | In: $1.75, Out: $14.00, Cache Read: $0.18 | | gpt-5.4 | openai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 1050000 | 128000 | In: $2.50, Out: $15.00, Cache Read: $0.25 | | gpt-5.4-mini | openai | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 400000 | 128000 | In: $0.75, Out: $4.50, Cache Read: $0.08 | | gpt-5.4-nano | openai | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 400000 | 128000 | In: $0.20, Out: $1.25, Cache Read: $0.02 | | gpt-5.5 | openai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 1050000 | 128000 | In: $5.00, Out: $30.00, Cache Read: $0.50 | | gpt-5.5-pro | openai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 1050000 | 128000 | In: $30.00, Out: $180.00 | | gpt-5.6 | openai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1050000 | 128000 | In: $5.00, Out: $30.00, Cache Read: $0.50, Cache Write: $6.25 | | gpt-5.6-luna | openai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 1050000 | 128000 | In: $0.20, Out: $1.20, Cache Read: $0.02, Cache Write: $0.25 | | gpt-5.6-sol | openai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 1050000 | 128000 | In: $5.00, Out: $30.00, Cache Read: $0.50, Cache Write: $6.25 | | gpt-5.6-terra | openai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 1050000 | 128000 | In: $2.00, Out: $12.00, Cache Read: $0.20, Cache Write: $2.50 | | gpt-4.1-2025-04-14 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision | 1047576 | 32768 | In: $2.00, Out: $8.00, Cache Read: $0.50 | | gpt-4.1-mini-2025-04-14 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision | 1047576 | 32768 | In: $0.40, Out: $1.60, Cache Read: $0.10 | | gpt-4.1-nano-2025-04-14 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision | 1047576 | 32768 | In: $0.10, Out: $0.40 | | gpt-4o-mini-2024-07-18 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision | 128000 | 16384 | In: $0.15, Out: $0.60 | | gpt-5-2025-08-07 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5-chat-latest | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5-codex | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5-mini-2025-08-07 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 128000 | 400000 | In: $0.25, Out: $2.00, Cache Read: $0.02 | | gpt-5-nano-2025-08-07 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 128000 | 400000 | In: $0.05, Out: $0.40, Cache Read: $0.01 | | gpt-5-pro-2025-10-06 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5-search-api | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning, citations | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5-search-api-2025-10-14 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning, citations | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.1-2025-11-13 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.1-chat-latest | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.1-codex | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.1-codex-max | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.1-codex-mini | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 128000 | 400000 | In: $0.25, Out: $2.00, Cache Read: $0.02 | | gpt-5.2-2025-12-11 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.2-codex | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.2-pro-2025-12-11 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.4-2026-03-05 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.4-mini-2026-03-17 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 128000 | 400000 | In: $0.25, Out: $2.00, Cache Read: $0.02 | | gpt-5.4-nano-2026-03-17 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 128000 | 400000 | In: $0.05, Out: $0.40, Cache Read: $0.01 | | gpt-5.4-pro-2026-03-05 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.5-2026-04-23 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.5-pro-2026-04-23 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 128000 | 400000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | o1 | openai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 200000 | 100000 | In: $15.00, Out: $60.00, Cache Read: $7.50 | | o1-2024-12-17 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 200000 | 100000 | In: $15.00, Out: $60.00 | | o1-pro | openai | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 200000 | 100000 | In: $150.00, Out: $600.00 | | o1-pro-2025-03-19 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, vision, reasoning | 200000 | 100000 | In: $150.00, Out: $600.00 | | o3 | openai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 100000 | In: $2.00, Out: $8.00, Cache Read: $0.50 | | o3-mini | openai | In: text; Out: text | function_calling, structured_output, reasoning, tool_choice, parallel_tool_calls | 200000 | 100000 | In: $1.10, Out: $4.40, Cache Read: $0.55 | | o3-mini-2025-01-31 | openai | In: -; Out: - | function_calling, tool_choice, parallel_tool_calls, structured_output, reasoning | 200000 | 100000 | In: $1.10, Out: $4.40 | | o3-pro | openai | In: text, image; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 100000 | In: $20.00, Out: $80.00 | | o4-mini | openai | In: text, image; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 100000 | In: $1.10, Out: $4.40, Cache Read: $0.28 | | ~anthropic/claude-haiku-latest | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 64000 | In: $1.00, Out: $5.00, Cache Read: $0.10, Cache Write: $1.25 | | ~anthropic/claude-sonnet-latest | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $2.00, Out: $10.00, Cache Read: $0.20, Cache Write: $2.50 | | anthropic/claude-fable-5:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50 | | anthropic/claude-haiku-4.5:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 200000 | 64000 | In: $0.50, Out: $2.50, Cache Read: $0.05 | | anthropic/claude-opus-4.1:batch | openrouter | In: image, text, file; Out: text | streaming, function_calling, structured_output | 200000 | 32000 | In: $7.50, Out: $37.50, Cache Read: $0.75 | | anthropic/claude-opus-4.5:batch | openrouter | In: file, image, text; Out: text | streaming, function_calling, structured_output | 200000 | 64000 | In: $2.50, Out: $12.50, Cache Read: $0.25 | | anthropic/claude-opus-4.6:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 1000000 | 128000 | In: $2.50, Out: $12.50, Cache Read: $0.25 | | anthropic/claude-opus-4.7:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 1000000 | 128000 | In: $2.50, Out: $12.50, Cache Read: $0.25 | | anthropic/claude-opus-4.8:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 1000000 | 128000 | In: $2.50, Out: $12.50, Cache Read: $0.25 | | anthropic/claude-sonnet-4.5:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 1000000 | 64000 | In: $1.50, Out: $7.50, Cache Read: $0.15 | | anthropic/claude-sonnet-4.6:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 1000000 | 128000 | In: $1.50, Out: $7.50, Cache Read: $0.15 | | anthropic/claude-sonnet-5:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 1000000 | 128000 | In: $1.00, Out: $5.00, Cache Read: $0.10 | | openrouter/auto | openrouter | In: text, image, audio, pdf, video; Out: text, image | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 2000000 | 2000000 | - | | openrouter/auto-beta | openrouter | In: text, image, audio, file, video; Out: text, image | streaming, function_calling, structured_output, predicted_outputs | 2000000 | - | - | | anthropic/claude-fable-5 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $10.00, Out: $50.00, Cache Read: $1.00, Cache Write: $12.50 | | ~anthropic/claude-fable-latest | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $10.00, Out: $50.00, Cache Read: $1.00, Cache Write: $12.50 | | anthropic/claude-haiku-4.5 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 64000 | In: $1.00, Out: $5.00, Cache Read: $0.10, Cache Write: $1.25 | | anthropic/claude-opus-4.5 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 64000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | anthropic/claude-opus-4.6 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | anthropic/claude-opus-4.7 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | anthropic/claude-opus-4.7-fast | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $30.00, Out: $150.00, Cache Read: $3.00, Cache Write: $37.50 | | anthropic/claude-opus-4.8 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | anthropic/claude-opus-4.8-fast | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $10.00, Out: $50.00, Cache Read: $1.00, Cache Write: $12.50 | | anthropic/claude-opus-5 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | anthropic/claude-opus-5-fast | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $10.00, Out: $50.00, Cache Read: $1.00, Cache Write: $12.50 | | anthropic/claude-opus-5:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 1000000 | 128000 | In: $2.50, Out: $12.50, Cache Read: $0.25 | | ~anthropic/claude-opus-latest | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | anthropic/claude-sonnet-4.5 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | anthropic/claude-sonnet-4.6 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | anthropic/claude-sonnet-5 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $2.00, Out: $10.00, Cache Read: $0.20, Cache Write: $2.50 | | mistralai/codestral-2508 | openrouter | In: text, pdf; Out: text | function_calling, structured_output, vision, streaming | 256000 | 256000 | In: $0.30, Out: $0.90, Cache Read: $0.03 | | deepcogito/cogito-v2.1-671b | openrouter | In: text; Out: text | structured_output, reasoning, streaming, predicted_outputs | 128000 | 128000 | In: $1.25, Out: $1.25 | | cohere/command-a | openrouter | In: text; Out: text | structured_output, streaming | 256000 | 8192 | In: $2.50, Out: $10.00 | | cohere/command-r-08-2024 | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 128000 | 4000 | In: $0.15, Out: $0.60 | | cohere/command-r-plus-08-2024 | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 128000 | 4000 | In: $2.50, Out: $10.00 | | cohere/command-r7b-12-2024 | openrouter | In: text; Out: text | structured_output, streaming | 128000 | 4000 | In: $0.04, Out: $0.15 | | thedrummer/cydonia-24b-v4.1 | openrouter | In: text; Out: text | structured_output, streaming, predicted_outputs | 131072 | 131072 | In: $0.30, Out: $0.50, Cache Read: $0.15 | | deepseek/deepseek-chat | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 163840 | 16000 | In: $0.26, Out: $1.03 | | deepseek/deepseek-chat-v3-0324 | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 163840 | 65536 | In: $0.27, Out: $1.12, Cache Read: $0.14 | | deepseek/deepseek-chat-v3.1 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 163840 | 32768 | In: $0.25, Out: $0.95, Cache Read: $0.13 | | deepseek/deepseek-v3.1-terminus | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 163840 | 32768 | In: $0.27, Out: $1.00, Cache Read: $0.14 | | deepseek/deepseek-v3.2 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 163840 | 65536 | In: $0.27, Out: $0.40, Cache Read: $0.13 | | deepseek/deepseek-v3.2-exp | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 163840 | 65536 | In: $0.27, Out: $0.41 | | deepseek/deepseek-v4-flash | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 1048576 | 393216 | In: $0.14, Out: $0.28, Cache Read: $0.03 | | deepseek/deepseek-v4-flash-0731 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 1048576 | 65536 | In: $0.09, Out: $0.18, Cache Read: $0.02 | | ~deepseek/deepseek-v4-flash-latest | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 1048576 | 65536 | In: $0.09, Out: $0.18, Cache Read: $0.02 | | deepseek/deepseek-v4-pro | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 1048576 | 384000 | In: $0.44, Out: $0.87, Cache Read: $0.00 | | deepseek/deepseek-r1 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 163840 | 16000 | In: $0.70, Out: $2.50 | | openrouter/free | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 8000 | In: $0.00, Out: $0.00 | | sakana/fugu-ultra | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $30.00, Cache Read: $0.50 | | z-ai/glm-4.6 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 204800 | 131072 | In: $0.50, Out: $2.00, Cache Read: $0.10 | | z-ai/glm-4.7 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 204800 | 131072 | In: $0.40, Out: $1.75, Cache Read: $0.08 | | z-ai/glm-4.7-flash | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 202752 | 16384 | In: $0.06, Out: $0.40, Cache Read: $0.01 | | z-ai/glm-5 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 204800 | 131072 | In: $0.95, Out: $2.55, Cache Read: $0.20 | | z-ai/glm-5.1 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 204800 | 131072 | In: $0.95, Out: $2.99, Cache Read: $0.18 | | z-ai/glm-5.2 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 1048576 | 131072 | In: $0.46, Out: $1.45, Cache Read: $0.09 | | openai/gpt-audio | openrouter | In: text, audio; Out: text, audio | function_calling, structured_output, streaming | 128000 | 16384 | In: $2.50, Out: $10.00 | | openai/gpt-audio-mini | openrouter | In: text, audio; Out: text, audio | function_calling, structured_output, streaming | 128000 | 16384 | In: $0.60, Out: $2.40 | | openai/gpt-chat-latest | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 400000 | 128000 | In: $5.00, Out: $30.00, Cache Read: $0.50 | | openai/gpt-oss-120b | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 131072 | 131072 | In: $0.04, Out: $0.17 | | openai/gpt-oss-20b | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 131072 | 131072 | In: $0.03, Out: $0.13, Cache Read: $0.03 | | openai/gpt-3.5-turbo-0613 | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 4095 | 4096 | In: $1.00, Out: $2.00 | | openai/gpt-3.5-turbo-16k | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 16385 | 4096 | In: $3.00, Out: $4.00 | | openai/gpt-3.5-turbo-instruct | openrouter | In: text; Out: text | structured_output, streaming | 4095 | 4096 | In: $1.50, Out: $2.00 | | openai/gpt-3.5-turbo | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 16385 | 4096 | In: $0.50, Out: $1.50 | | openai/gpt-4 | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 8191 | 4096 | In: $30.00, Out: $60.00 | | openai/gpt-4-turbo | openrouter | In: text, image; Out: text | function_calling, structured_output, vision, streaming | 128000 | 4096 | In: $10.00, Out: $30.00 | | openai/gpt-4-turbo-preview | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 128000 | 4096 | In: $10.00, Out: $30.00 | | openai/gpt-4.1 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 1047576 | 32768 | In: $2.00, Out: $8.00, Cache Read: $0.50 | | openai/gpt-4.1-mini | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 1047576 | 32768 | In: $0.40, Out: $1.60, Cache Read: $0.10 | | openai/gpt-4.1-nano | openrouter | In: image, text, pdf; Out: text | function_calling, structured_output, vision, streaming | 1047576 | 32768 | In: $0.10, Out: $0.40, Cache Read: $0.02 | | openai/gpt-4o | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 128000 | 16384 | In: $2.50, Out: $10.00, Cache Read: $1.25 | | openai/gpt-4o-2024-05-13 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 128000 | 4096 | In: $5.00, Out: $15.00 | | openai/gpt-4o-2024-08-06 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 128000 | 16384 | In: $2.50, Out: $10.00, Cache Read: $1.25 | | openai/gpt-4o-2024-11-20 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 128000 | 16384 | In: $2.50, Out: $10.00, Cache Read: $1.25 | | openai/gpt-4o-mini | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 128000 | 16384 | In: $0.15, Out: $0.60, Cache Read: $0.08 | | openai/gpt-4o-mini-2024-07-18 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 128000 | 16384 | In: $0.15, Out: $0.60, Cache Read: $0.08 | | openai/gpt-5 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | openai/gpt-5-image | openrouter | In: image, text, pdf; Out: image, text | structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $10.00, Out: $10.00, Cache Read: $1.25 | | openai/gpt-5-image-mini | openrouter | In: pdf, image, text; Out: image, text | structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $2.50, Out: $2.00, Cache Read: $0.25 | | openai/gpt-5-mini | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $0.25, Out: $2.00, Cache Read: $0.02 | | openai/gpt-5-nano | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $0.05, Out: $0.40, Cache Read: $0.01 | | openai/gpt-5-pro | openrouter | In: image, text, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $15.00, Out: $120.00 | | openai/gpt-5.1 | openrouter | In: image, text, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | openai/gpt-5.1-codex | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $1.25, Out: $10.00, Cache Read: $0.13 | | openai/gpt-5.1-codex-max | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | openai/gpt-5.1-codex-mini | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $0.25, Out: $2.00, Cache Read: $0.03 | | openai/gpt-5.2 | openrouter | In: pdf, image, text; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $1.75, Out: $14.00, Cache Read: $0.18 | | openai/gpt-5.2-chat | openrouter | In: pdf, image, text; Out: text | function_calling, structured_output, vision, streaming | 128000 | 16384 | In: $1.75, Out: $14.00, Cache Read: $0.18 | | openai/gpt-5.2-codex | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $1.75, Out: $14.00, Cache Read: $0.18 | | openai/gpt-5.2-pro | openrouter | In: image, text, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $21.00, Out: $168.00 | | openai/gpt-5.3-chat | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 128000 | 16384 | In: $1.75, Out: $14.00, Cache Read: $0.18 | | openai/gpt-5.3-codex | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $1.75, Out: $14.00, Cache Read: $0.18 | | openai/gpt-5.4 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $2.50, Out: $15.00, Cache Read: $0.25 | | openai/gpt-5.4-image-2 | openrouter | In: image, text, pdf; Out: image, text | structured_output, reasoning, vision, streaming | 272000 | 128000 | In: $8.00, Out: $15.00, Cache Read: $2.00 | | openai/gpt-5.4-pro | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $30.00, Out: $180.00 | | openai/gpt-5.4-mini | openrouter | In: pdf, image, text; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $0.75, Out: $4.50, Cache Read: $0.08 | | openai/gpt-5.4-nano | openrouter | In: pdf, image, text; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $0.20, Out: $1.25, Cache Read: $0.02 | | openai/gpt-5.5 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $5.00, Out: $30.00, Cache Read: $0.50 | | openai/gpt-5.5-pro | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $30.00, Out: $180.00 | | openai/gpt-5.6-luna | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $0.10, Out: $0.60, Cache Read: $0.01, Cache Write: $0.12 | | openai/gpt-5.6-luna-pro | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $0.10, Out: $0.60, Cache Read: $0.01, Cache Write: $0.12 | | openai/gpt-5.6-sol | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $5.00, Out: $30.00, Cache Read: $0.50, Cache Write: $6.25 | | openai/gpt-5.6-sol-pro | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $5.00, Out: $30.00, Cache Read: $0.50, Cache Write: $6.25 | | openai/gpt-5.6-terra | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $1.00, Out: $6.00, Cache Read: $0.10, Cache Write: $1.25 | | openai/gpt-5.6-terra-pro | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $1.00, Out: $6.00, Cache Read: $0.10, Cache Write: $1.25 | | google/gemini-2.5-flash | openrouter | In: text, image, audio, video, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65535 | In: $0.30, Out: $2.50, Cache Read: $0.03, Cache Write: $0.08 | | google/gemini-2.5-flash-lite | openrouter | In: text, image, audio, video, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65535 | In: $0.10, Out: $0.40, Cache Read: $0.01, Cache Write: $0.08 | | google/gemini-2.5-pro | openrouter | In: text, image, audio, video, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $1.25, Out: $10.00, Cache Read: $0.12, Cache Write: $0.38 | | google/gemini-2.5-pro-preview-05-06 | openrouter | In: text, image, pdf, audio, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65535 | In: $1.25, Out: $10.00, Cache Read: $0.12, Cache Write: $0.38 | | google/gemini-2.5-pro-preview | openrouter | In: pdf, image, text, audio; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1048576 | 65536 | In: $1.25, Out: $10.00, Cache Read: $0.12, Cache Write: $0.38 | | google/gemini-3-flash-preview | openrouter | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $0.50, Out: $3.00, Cache Read: $0.05, Cache Write: $0.08 | | google/gemini-3.1-flash-lite | openrouter | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $0.25, Out: $1.50, Cache Read: $0.02, Cache Write: $0.08 | | google/gemini-3.1-flash-lite-preview | openrouter | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $0.25, Out: $1.50, Cache Read: $0.02, Cache Write: $0.08 | | google/gemini-3.1-pro-preview | openrouter | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $2.00, Out: $12.00, Cache Read: $0.20, Cache Write: $0.38 | | google/gemini-3.1-pro-preview-customtools | openrouter | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $2.00, Out: $12.00, Cache Read: $0.20, Cache Write: $0.38 | | google/gemini-3.5-flash | openrouter | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $1.50, Out: $9.00, Cache Read: $0.15, Cache Write: $0.08 | | google/gemini-3.5-flash-lite | openrouter | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $0.30, Out: $2.50, Cache Read: $0.03, Cache Write: $0.08 | | google/gemini-3.6-flash | openrouter | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $1.50, Out: $7.50, Cache Read: $0.15, Cache Write: $0.08 | | google/gemma-2-27b-it | openrouter | In: text; Out: text | structured_output, streaming | 8192 | 2048 | In: $0.65, Out: $0.65 | | google/gemma-3-12b-it | openrouter | In: text, image; Out: text | function_calling, structured_output, vision, streaming, predicted_outputs | 131072 | 16384 | In: $0.05, Out: $0.15 | | google/gemma-3-27b-it | openrouter | In: text, image; Out: text | function_calling, structured_output, vision, streaming, predicted_outputs | 262144 | 131072 | In: $0.08, Out: $0.45, Cache Read: $0.04 | | google/gemma-3-4b-it | openrouter | In: text, image; Out: text | structured_output, vision, streaming, predicted_outputs | 131072 | 16384 | In: $0.05, Out: $0.10 | | google/gemma-3n-e4b-it | openrouter | In: text; Out: text | structured_output, streaming, predicted_outputs | 32768 | 32768 | In: $0.06, Out: $0.12 | | google/gemma-4-26b-a4b-it:free | openrouter | In: image, text, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 262144 | 32768 | In: $0.00, Out: $0.00 | | google/gemma-4-26b-a4b-it | openrouter | In: image, text, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 262144 | 16384 | In: $0.07, Out: $0.34 | | google/gemma-4-31b-it | openrouter | In: image, text, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 262144 | 262144 | In: $0.10, Out: $0.34, Cache Read: $0.10 | | ~google/gemini-flash-latest | openrouter | In: text, image, video, pdf, audio; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $1.50, Out: $7.50, Cache Read: $0.15, Cache Write: $0.08 | | ~google/gemini-pro-latest | openrouter | In: audio, pdf, image, text, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $2.00, Out: $12.00, Cache Read: $0.20, Cache Write: $0.38 | | google/gemini-2.5-flash:batch | openrouter | In: file, image, text, audio, video; Out: text | streaming, function_calling, structured_output | 1048576 | 65535 | In: $0.15, Out: $1.25, Cache Read: $0.03 | | google/gemini-2.5-flash-lite:batch | openrouter | In: text, image, file, audio, video; Out: text | streaming, function_calling, structured_output | 1048576 | 65535 | In: $0.05, Out: $0.20, Cache Read: $0.01 | | google/gemini-2.5-pro:batch | openrouter | In: text, image, file, audio, video; Out: text | streaming, function_calling, structured_output | 1048576 | 65536 | In: $0.62, Out: $5.00, Cache Read: $0.12 | | google/gemini-3-flash-preview:batch | openrouter | In: text, image, file, audio, video; Out: text | streaming, function_calling, structured_output | 1048576 | 65536 | In: $0.25, Out: $1.50 | | google/gemini-3.1-flash-lite:batch | openrouter | In: text, image, video, file, audio; Out: text | streaming, function_calling, structured_output | 1048576 | 65536 | In: $0.12, Out: $0.75, Cache Read: $0.01 | | google/gemini-3.1-pro-preview:batch | openrouter | In: audio, file, image, text, video; Out: text | streaming, function_calling, structured_output | 1048576 | 65536 | In: $1.00, Out: $6.00 | | google/gemini-3.5-flash:batch | openrouter | In: text, image, video, file, audio; Out: text | streaming, function_calling, structured_output | 1048576 | 65536 | In: $0.75, Out: $4.50, Cache Read: $0.08 | | google/gemini-3.5-flash-lite:batch | openrouter | In: text, image, video, file, audio; Out: text | streaming, function_calling, structured_output | 1048576 | 65536 | In: $0.15, Out: $1.25, Cache Read: $0.02 | | google/gemini-3.6-flash:batch | openrouter | In: text, image, video, file, audio; Out: text | streaming, function_calling, structured_output | 1048576 | 65536 | In: $0.75, Out: $3.75, Cache Read: $0.08 | | ibm-granite/granite-4.1-8b | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 131072 | 131072 | In: $0.05, Out: $0.10, Cache Read: $0.05 | | x-ai/grok-4.20 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 2000000 | 2000000 | In: $1.25, Out: $2.50, Cache Read: $0.20 | | x-ai/grok-4.20-multi-agent | openrouter | In: text, image, pdf; Out: text | structured_output, reasoning, vision, streaming | 2000000 | 2000000 | In: $1.25, Out: $2.50, Cache Read: $0.20 | | x-ai/grok-4.3 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 1000000 | In: $1.25, Out: $2.50, Cache Read: $0.20 | | x-ai/grok-4.5 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 500000 | 500000 | In: $2.00, Out: $6.00, Cache Read: $0.30 | | x-ai/grok-build-0.1 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 256000 | 256000 | In: $1.00, Out: $2.00, Cache Read: $0.20 | | ~x-ai/grok-latest | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 500000 | 1000000 | In: $2.00, Out: $6.00, Cache Read: $0.30 | | nousresearch/hermes-3-llama-3.1-405b | openrouter | In: text; Out: text | structured_output, streaming, predicted_outputs | 131072 | 16384 | In: $1.00, Out: $1.00 | | nousresearch/hermes-3-llama-3.1-70b | openrouter | In: text; Out: text | structured_output, streaming, predicted_outputs | 131072 | 16384 | In: $0.70, Out: $0.70 | | tencent/hunyuan-a13b-instruct | openrouter | In: text; Out: text | structured_output, reasoning, streaming | 131072 | 131072 | In: $0.14, Out: $0.57 | | tencent/hy3 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 262144 | 128000 | In: $0.13, Out: $0.53, Cache Read: $0.03 | | kwaipilot/kat-coder-air-v2.5 | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 256000 | 80000 | In: $0.15, Out: $0.60, Cache Read: $0.03 | | kwaipilot/kat-coder-pro-v2 | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 262144 | 80000 | In: $0.30, Out: $1.20, Cache Read: $0.06 | | kwaipilot/kat-coder-pro-v2.5 | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 256000 | 80000 | In: $0.74, Out: $2.96, Cache Read: $0.15 | | moonshotai/kimi-k2-0905 | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 262144 | 100352 | In: $0.60, Out: $2.50 | | moonshotai/kimi-k2-thinking | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 262144 | 100352 | In: $0.60, Out: $2.50, Cache Read: $0.15 | | moonshotai/kimi-k2.5 | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming, predicted_outputs | 262144 | 262144 | In: $0.57, Out: $2.85, Cache Read: $0.10 | | moonshotai/kimi-k2.6 | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming, predicted_outputs | 262144 | 262144 | In: $0.58, Out: $2.44, Cache Read: $0.10 | | moonshotai/kimi-k2.7-code | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming, predicted_outputs | 262144 | 262144 | In: $0.70, Out: $3.50, Cache Read: $0.15 | | moonshotai/kimi-k3 | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming, predicted_outputs | 1048576 | 1048576 | In: $3.00, Out: $15.00, Cache Read: $0.30 | | inclusionai/ling-2.6-1t | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 262144 | 32768 | In: $0.08, Out: $0.62, Cache Read: $0.02 | | inclusionai/ling-2.6-flash | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 262144 | 32768 | In: $0.01, Out: $0.03, Cache Read: $0.00 | | sao10k/l3-lunaris-8b | openrouter | In: text; Out: text | structured_output, streaming, predicted_outputs | 8192 | 16384 | In: $0.04, Out: $0.05 | | meta-llama/llama-3.1-70b-instruct | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 131072 | 16384 | In: $0.40, Out: $0.40 | | meta-llama/llama-3.1-8b-instruct | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 131072 | 131072 | In: $0.05, Out: $0.08, Cache Read: $0.02 | | sao10k/l3.1-euryale-70b | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 131072 | 16384 | In: $0.85, Out: $0.85 | | meta-llama/llama-3.2-3b-instruct | openrouter | In: text; Out: text | structured_output, streaming, predicted_outputs | 131072 | 131072 | In: $0.05, Out: $0.33 | | sao10k/l3.3-euryale-70b | openrouter | In: text; Out: text | structured_output, streaming | 131072 | 16384 | In: $0.65, Out: $0.75 | | meta-llama/llama-4-maverick | openrouter | In: text, image; Out: text | function_calling, structured_output, vision, streaming, predicted_outputs | 1048576 | 16384 | In: $0.20, Out: $0.80 | | meta-llama/llama-4-scout | openrouter | In: text, image; Out: text | function_calling, structured_output, vision, streaming, predicted_outputs | 1310720 | 16384 | In: $0.10, Out: $0.30 | | meta-llama/llama-3.3-70b-instruct | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 131072 | 16384 | In: $0.10, Out: $0.32 | | anthracite-org/magnum-v4-72b | openrouter | In: text; Out: text | structured_output, streaming, predicted_outputs | 16384 | 2048 | In: $3.00, Out: $5.00 | | inception/mercury-2 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 128000 | 50000 | In: $0.25, Out: $0.75, Cache Read: $0.02 | | xiaomi/mimo-v2.5 | openrouter | In: text, image, audio, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 1050000 | 131072 | In: $0.14, Out: $0.28, Cache Read: $0.00 | | xiaomi/mimo-v2.5-pro | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 1050000 | 131072 | In: $0.44, Out: $0.87, Cache Read: $0.00 | | minimax/minimax-m2 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 204800 | 131072 | In: $0.26, Out: $1.02 | | minimax/minimax-m2.5 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 204800 | 196608 | In: $0.22, Out: $0.90, Cache Read: $0.05 | | minimax/minimax-m2.7 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 204800 | 131072 | In: $0.27, Out: $1.08, Cache Read: $0.05 | | minimax/minimax-m3 | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 1048576 | 512000 | In: $0.30, Out: $1.20, Cache Read: $0.06 | | minimax/minimax-m3:batch | openrouter | In: text, image, video; Out: text | streaming, function_calling, structured_output, predicted_outputs | 524288 | - | In: $0.15, Out: $0.60, Cache Read: $0.03 | | mistralai/ministral-14b-2512 | openrouter | In: text, image; Out: text | function_calling, structured_output, vision, streaming | 262144 | 262144 | In: $0.20, Out: $0.20, Cache Read: $0.02 | | mistralai/ministral-3b-2512 | openrouter | In: text, image; Out: text | function_calling, structured_output, vision, streaming | 131072 | 131072 | In: $0.10, Out: $0.10, Cache Read: $0.01 | | mistralai/ministral-8b-2512 | openrouter | In: text, image; Out: text | function_calling, structured_output, vision, streaming | 262144 | 262144 | In: $0.15, Out: $0.15, Cache Read: $0.02 | | mistralai/mistral-large | openrouter | In: text, pdf; Out: text | function_calling, structured_output, vision, streaming | 128000 | 128000 | In: $2.00, Out: $6.00, Cache Read: $0.20 | | mistralai/mistral-large-2407 | openrouter | In: text, pdf; Out: text | function_calling, structured_output, vision, streaming | 131072 | 131072 | In: $2.00, Out: $6.00, Cache Read: $0.20 | | mistralai/mistral-large-2512 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 262144 | 262144 | In: $0.50, Out: $1.50, Cache Read: $0.05 | | mistralai/mistral-medium-3 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 131072 | 131072 | In: $0.40, Out: $2.00, Cache Read: $0.04 | | mistralai/mistral-medium-3.1 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 131072 | 262144 | In: $0.40, Out: $2.00, Cache Read: $0.04 | | mistralai/mistral-medium-3-5 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 262144 | 262144 | In: $1.50, Out: $7.50 | | mistralai/mistral-nemo | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 131072 | 16384 | In: $0.02, Out: $0.03 | | mistralai/mistral-small-24b-instruct-2501 | openrouter | In: text; Out: text | structured_output, streaming, predicted_outputs | 32768 | 16384 | In: $0.05, Out: $0.08 | | mistralai/mistral-small-3.2-24b-instruct | openrouter | In: image, text; Out: text | function_calling, structured_output, vision, streaming, predicted_outputs | 256000 | 16384 | In: $0.09, Out: $0.25 | | mistralai/mistral-small-2603 | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 262144 | 262144 | In: $0.15, Out: $0.60, Cache Read: $0.02 | | mistralai/mixtral-8x22b-instruct | openrouter | In: text, pdf; Out: text | function_calling, structured_output, vision, streaming | 65536 | 65536 | In: $2.00, Out: $6.00, Cache Read: $0.20 | | ~moonshotai/kimi-latest | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming, predicted_outputs | 1048576 | 1048576 | In: $2.50, Out: $14.00, Cache Read: $0.29 | | moonshotai/kimi-k2.7-code:batch | openrouter | In: text, image; Out: text | streaming, function_calling, structured_output, predicted_outputs | 262144 | - | In: $0.48, Out: $2.00, Cache Read: $0.10 | | morph/morph-v3-large | openrouter | In: text; Out: text | structured_output, streaming | 262144 | 131072 | In: $0.90, Out: $1.90 | | meta/muse-spark-1.1 | openrouter | In: text, image, video, pdf, audio; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 1048576 | In: $1.25, Out: $4.25, Cache Read: $0.15 | | meta/muse-spark-1.2 | openrouter | In: text, image, video, pdf, audio; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 1048576 | In: $1.25, Out: $4.25, Cache Read: $0.15 | | gryphe/mythomax-l2-13b | openrouter | In: text; Out: text | structured_output, streaming, predicted_outputs | 8192 | 4096 | In: $0.08, Out: $0.11 | | nvidia/nemotron-3-ultra-550b-a55b:batch | openrouter | In: text; Out: text | streaming, function_calling, structured_output, predicted_outputs | 512288 | - | In: $0.30, Out: $1.80, Cache Read: $0.10 | | google/gemini-2.5-flash-image | openrouter | In: text, image; Out: text, image | structured_output, vision, streaming | 32768 | 8192 | In: $0.30, Out: $2.50, Cache Read: $0.03, Cache Write: $0.08 | | google/gemini-3.1-flash-image | openrouter | In: text, image; Out: text, image | structured_output, reasoning, vision, streaming | 131072 | 32768 | In: $0.50, Out: $3.00 | | google/gemini-3.1-flash-image-preview | openrouter | In: image, text; Out: text, image | structured_output, reasoning, vision, streaming | 65536 | 65536 | In: $0.50, Out: $3.00 | | google/gemini-3-pro-image | openrouter | In: text, image; Out: text, image | function_calling, structured_output, reasoning, vision, streaming | 131072 | 32768 | In: $2.00, Out: $12.00, Cache Read: $0.20, Cache Write: $0.38 | | google/gemini-3-pro-image-preview | openrouter | In: text, image; Out: text, image | structured_output, reasoning, vision, streaming | 65536 | 32768 | In: $2.00, Out: $12.00, Cache Read: $0.20, Cache Write: $0.38 | | nvidia/nemotron-3-nano-30b-a3b | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 262144 | 262144 | In: $0.05, Out: $0.20, Cache Read: $0.03 | | nvidia/nemotron-3-super-120b-a12b:free | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 262144 | 262144 | In: $0.00, Out: $0.00 | | nvidia/nemotron-3-super-120b-a12b | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 1000000 | 16384 | In: $0.08, Out: $0.40 | | nvidia/nemotron-3-ultra-550b-a55b | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 512288 | 16384 | In: $0.60, Out: $3.60, Cache Read: $0.20 | | nvidia/nemotron-nano-9b-v2:free | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 128000 | 128000 | In: $0.00, Out: $0.00 | | nex-agi/nex-n2-mini | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 262144 | 262144 | In: $0.02, Out: $0.10, Cache Read: $0.00 | | allenai/olmo-3-32b-think | openrouter | In: text; Out: text | structured_output, reasoning, streaming, predicted_outputs | 65536 | 65536 | In: $0.15, Out: $0.50 | | ~openai/gpt-latest | openrouter | In: pdf, image, text; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $5.00, Out: $30.00, Cache Read: $0.50, Cache Write: $6.25 | | ~openai/gpt-mini-latest | openrouter | In: pdf, image, text; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $0.75, Out: $4.50, Cache Read: $0.08 | | openai/gpt-3.5-turbo:batch | openrouter | In: text; Out: text | streaming, function_calling, structured_output | 16385 | 4096 | In: $0.25, Out: $0.75 | | openai/gpt-4-turbo:batch | openrouter | In: text, image; Out: text | streaming, function_calling, structured_output | 128000 | 4096 | In: $5.00, Out: $15.00 | | openai/gpt-4.1:batch | openrouter | In: image, text, file; Out: text | streaming, function_calling, structured_output | 1047576 | 32768 | In: $1.00, Out: $4.00, Cache Read: $0.25 | | openai/gpt-4.1-mini:batch | openrouter | In: image, text, file; Out: text | streaming, function_calling, structured_output | 1047576 | 32768 | In: $0.20, Out: $0.80, Cache Read: $0.05 | | openai/gpt-4.1-nano:batch | openrouter | In: image, text, file; Out: text | streaming, function_calling, structured_output | 1047576 | 32768 | In: $0.05, Out: $0.20, Cache Read: $0.01 | | openai/gpt-4o:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 128000 | 16384 | In: $1.25, Out: $5.00, Cache Read: $0.62 | | openai/gpt-4o-mini:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 128000 | 16384 | In: $0.08, Out: $0.30, Cache Read: $0.04 | | openai/gpt-5:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 400000 | 128000 | In: $0.62, Out: $5.00, Cache Read: $0.06 | | openai/gpt-5-codex:batch | openrouter | In: text, image; Out: text | streaming, function_calling, structured_output | 400000 | 128000 | In: $0.62, Out: $5.00, Cache Read: $0.06 | | openai/gpt-5-mini:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 400000 | 128000 | In: $0.12, Out: $1.00, Cache Read: $0.01 | | openai/gpt-5-nano:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 400000 | 128000 | In: $0.02, Out: $0.20, Cache Read: $0.00 | | openai/gpt-5-pro:batch | openrouter | In: image, text, file; Out: text | streaming, function_calling, structured_output | 400000 | 128000 | In: $7.50, Out: $60.00 | | openai/gpt-5.1:batch | openrouter | In: image, text, file; Out: text | streaming, function_calling, structured_output | 400000 | 128000 | In: $0.62, Out: $5.00, Cache Read: $0.06 | | openai/gpt-5.2:batch | openrouter | In: file, image, text; Out: text | streaming, function_calling, structured_output | 400000 | 128000 | In: $0.88, Out: $7.00, Cache Read: $0.09 | | openai/gpt-5.2-pro:batch | openrouter | In: image, text, file; Out: text | streaming, function_calling, structured_output | 400000 | 128000 | In: $10.50, Out: $84.00 | | openai/gpt-5.4:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 1050000 | 128000 | In: $1.25, Out: $7.50, Cache Read: $0.12 | | openai/gpt-5.4-mini:batch | openrouter | In: file, image, text; Out: text | streaming, function_calling, structured_output | 400000 | 128000 | In: $0.38, Out: $2.25, Cache Read: $0.04 | | openai/gpt-5.4-nano:batch | openrouter | In: file, image, text; Out: text | streaming, function_calling, structured_output | 400000 | 128000 | In: $0.10, Out: $0.62, Cache Read: $0.01 | | openai/gpt-5.4-pro:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 1050000 | 128000 | In: $15.00, Out: $90.00 | | openai/gpt-5.5:batch | openrouter | In: file, image, text; Out: text | streaming, function_calling, structured_output | 1050000 | 128000 | In: $2.50, Out: $15.00, Cache Read: $0.25 | | openai/gpt-5.5-pro:batch | openrouter | In: file, image, text; Out: text | streaming, function_calling, structured_output | 1050000 | 128000 | In: $15.00, Out: $90.00 | | openai/gpt-5.6-luna:batch | openrouter | In: file, image, text; Out: text | streaming, function_calling, structured_output | 1050000 | 128000 | In: $0.10, Out: $0.60, Cache Read: $0.01 | | openai/gpt-5.6-luna-pro:batch | openrouter | In: file, image, text; Out: text | streaming, function_calling, structured_output | 1050000 | 128000 | In: $0.10, Out: $0.60, Cache Read: $0.01 | | openai/gpt-5.6-sol:batch | openrouter | In: file, image, text; Out: text | streaming, function_calling, structured_output | 1050000 | 128000 | In: $2.50, Out: $15.00, Cache Read: $0.25 | | openai/gpt-5.6-sol-pro:batch | openrouter | In: file, image, text; Out: text | streaming, function_calling, structured_output | 1050000 | 128000 | In: $2.50, Out: $15.00, Cache Read: $0.25 | | openai/gpt-5.6-terra:batch | openrouter | In: file, image, text; Out: text | streaming, function_calling, structured_output | 1050000 | 128000 | In: $1.00, Out: $6.00, Cache Read: $0.10 | | openai/gpt-5.6-terra-pro:batch | openrouter | In: file, image, text; Out: text | streaming, function_calling, structured_output | 1050000 | 128000 | In: $1.00, Out: $6.00, Cache Read: $0.10 | | openai/o1:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 200000 | 100000 | In: $7.50, Out: $30.00, Cache Read: $3.75 | | openai/o1-pro:batch | openrouter | In: text, image, file; Out: text | streaming, structured_output | 200000 | 100000 | In: $75.00, Out: $300.00 | | openai/o3:batch | openrouter | In: image, text, file; Out: text | streaming, function_calling, structured_output | 200000 | 100000 | In: $1.00, Out: $4.00, Cache Read: $0.25 | | openai/o3-mini:batch | openrouter | In: text, file; Out: text | streaming, function_calling, structured_output | 200000 | 100000 | In: $0.55, Out: $2.20, Cache Read: $0.28 | | openai/o3-mini-high:batch | openrouter | In: text, file; Out: text | streaming, function_calling, structured_output | 200000 | 100000 | In: $0.55, Out: $2.20, Cache Read: $0.28 | | openai/o3-pro:batch | openrouter | In: text, file, image; Out: text | streaming, function_calling, structured_output | 200000 | 100000 | In: $10.00, Out: $40.00 | | openai/o4-mini:batch | openrouter | In: image, text, file; Out: text | streaming, function_calling, structured_output | 200000 | 100000 | In: $0.55, Out: $2.20, Cache Read: $0.14 | | openai/o4-mini-high:batch | openrouter | In: image, text, file; Out: text | streaming, function_calling, structured_output | 200000 | 100000 | In: $0.55, Out: $2.20, Cache Read: $0.14 | | perceptron/perceptron-mk1 | openrouter | In: text, image, video; Out: text | structured_output, reasoning, vision, video, streaming | 32768 | 8192 | In: $0.15, Out: $1.50 | | microsoft/phi-4 | openrouter | In: text; Out: text | structured_output, streaming, predicted_outputs | 16384 | 16384 | In: $0.07, Out: $0.14 | | qwen/qwen-plus | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 1000000 | 32768 | In: $0.26, Out: $0.78, Cache Read: $0.05, Cache Write: $0.32 | | qwen/qwen-plus-2025-07-28 | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 1000000 | 32768 | In: $0.26, Out: $0.78 | | qwen/qwen-plus-2025-07-28:thinking | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 1000000 | 32768 | In: $0.40, Out: $1.20, Cache Write: $0.50 | | qwen/qwen-2.5-72b-instruct | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 32768 | 16384 | In: $0.36, Out: $0.40 | | qwen/qwen-2.5-7b-instruct | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 32768 | 32768 | In: $0.10, Out: $0.20 | | qwen/qwen2.5-vl-72b-instruct | openrouter | In: text, image; Out: text | structured_output, vision, streaming, predicted_outputs | 128000 | 128000 | In: $0.25, Out: $0.75 | | qwen/qwen3-14b | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 131072 | 8192 | In: $0.23, Out: $0.91 | | qwen/qwen3-235b-a22b-2507 | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 262144 | 16384 | In: $0.09, Out: $0.55 | | qwen/qwen3-30b-a3b-instruct-2507 | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 262144 | 32000 | In: $0.05, Out: $0.19 | | qwen/qwen3-32b | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 131072 | 16384 | In: $0.08, Out: $0.28 | | qwen/qwen3-coder | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 262144 | 65536 | In: $0.30, Out: $1.00, Cache Read: $0.10 | | qwen/qwen3-coder-next | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 262144 | 262144 | In: $0.12, Out: $0.80, Cache Read: $0.07 | | qwen/qwen3-coder-plus | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 1000000 | 65536 | In: $0.65, Out: $3.25, Cache Read: $0.13, Cache Write: $0.81 | | qwen/qwen3-max | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 262144 | 65536 | In: $0.78, Out: $3.90, Cache Read: $0.16, Cache Write: $0.98 | | qwen/qwen3-max-thinking | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 262144 | 65536 | In: $0.78, Out: $3.90 | | qwen/qwen3-vl-235b-a22b-instruct | openrouter | In: text, image; Out: text | function_calling, structured_output, vision, streaming, predicted_outputs | 262144 | 32768 | In: $0.21, Out: $1.90, Cache Read: $0.10 | | qwen/qwen3-vl-235b-a22b-thinking | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 131072 | 32768 | In: $0.40, Out: $4.00 | | qwen/qwen3-vl-30b-a3b-instruct | openrouter | In: text, image; Out: text | function_calling, structured_output, vision, streaming, predicted_outputs | 262144 | 16384 | In: $0.15, Out: $0.60 | | qwen/qwen3-vl-30b-a3b-thinking | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 262144 | 32768 | In: $0.20, Out: $2.40 | | qwen/qwen3-vl-32b-instruct | openrouter | In: text, image; Out: text | function_calling, structured_output, vision, streaming | 131072 | 32768 | In: $0.10, Out: $0.42 | | qwen/qwen3-vl-8b-instruct | openrouter | In: image, text; Out: text | function_calling, structured_output, vision, streaming, predicted_outputs | 262144 | 32768 | In: $0.12, Out: $0.46 | | qwen/qwen3-vl-8b-thinking | openrouter | In: image, text; Out: text | function_calling, structured_output, reasoning, vision, streaming | 131072 | 32768 | In: $0.18, Out: $2.10 | | qwen/qwen3-coder-30b-a3b-instruct | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 262144 | 32768 | In: $0.07, Out: $0.27 | | qwen/qwen3-next-80b-a3b-thinking | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 262144 | 262144 | In: $0.15, Out: $1.20 | | qwen/qwen3-next-80b-a3b-instruct | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 262144 | 16384 | In: $0.09, Out: $1.10 | | qwen/qwen3.5-122b-a10b | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 262144 | 81920 | In: $0.29, Out: $2.40 | | qwen/qwen3.5-27b | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 262144 | 65536 | In: $0.20, Out: $1.56 | | qwen/qwen3.5-35b-a3b | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 262144 | 262144 | In: $0.14, Out: $1.00 | | qwen/qwen3.5-397b-a17b | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 262144 | 65536 | In: $0.39, Out: $2.34 | | qwen/qwen3.5-9b | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 262144 | 262144 | In: $0.10, Out: $0.15 | | qwen/qwen3.5-plus-02-15 | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1000000 | 65536 | In: $0.26, Out: $1.56 | | qwen/qwen3.5-plus-20260420 | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1000000 | 65536 | In: $0.30, Out: $1.80, Cache Write: $0.38 | | qwen/qwen3.5-flash-02-23 | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1000000 | 65536 | In: $0.06, Out: $0.26 | | qwen/qwen3.6-27b | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 262144 | 262144 | In: $0.60, Out: $3.60, Cache Read: $0.12 | | qwen/qwen3.6-35b-a3b | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 262144 | 262144 | In: $0.14, Out: $1.00, Cache Read: $0.05 | | qwen/qwen3.6-flash | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1000000 | 65536 | In: $0.19, Out: $1.12, Cache Write: $0.23 | | qwen/qwen3.6-max-preview | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 262144 | 65536 | In: $1.03, Out: $6.16, Cache Write: $1.28 | | qwen/qwen3.6-plus | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1000000 | 65536 | In: $0.32, Out: $1.95, Cache Write: $0.41 | | qwen/qwen3.7-max | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 1000000 | 131072 | In: $1.48, Out: $4.42, Cache Read: $0.30, Cache Write: $1.84 | | qwen/qwen3.7-plus | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 131072 | In: $0.32, Out: $1.28, Cache Read: $0.06, Cache Write: $0.40 | | qwen/qwen3.8-max | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1000000 | 131072 | In: $2.00, Out: $6.00, Cache Read: $0.25, Cache Write: $2.50 | | deepseek/deepseek-r1-0528 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 163840 | 32768 | In: $0.50, Out: $2.15, Cache Read: $0.35 | | undi95/remm-slerp-l2-13b | openrouter | In: text; Out: text | structured_output, streaming, predicted_outputs | 6144 | 6144 | In: $0.45, Out: $0.65 | | rekaai/reka-edge | openrouter | In: image, text, video; Out: text | function_calling, structured_output, vision, video, streaming | 16384 | 16384 | In: $0.10, Out: $0.10 | | rekaai/reka-flash-3 | openrouter | In: text; Out: text | structured_output, reasoning, streaming | 65536 | 65536 | In: $0.10, Out: $0.20 | | thedrummer/rocinante-12b | openrouter | In: text; Out: text | structured_output, streaming, predicted_outputs | 65536 | 65536 | In: $0.25, Out: $0.50 | | mistralai/mistral-saba | openrouter | In: text, pdf; Out: text | function_calling, structured_output, vision, streaming | 32768 | 32768 | In: $0.20, Out: $0.60, Cache Read: $0.02 | | bytedance-seed/seed-1.6 | openrouter | In: image, text, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 262144 | 32768 | In: $0.25, Out: $2.00 | | bytedance-seed/seed-1.6-flash | openrouter | In: image, text, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 262144 | 32768 | In: $0.08, Out: $0.30 | | bytedance-seed/seed-2.0-lite | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 262144 | 131072 | In: $0.25, Out: $2.00 | | bytedance-seed/seed-2.0-mini | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 262144 | 131072 | In: $0.10, Out: $0.40 | | thedrummer/skyfall-36b-v2 | openrouter | In: text; Out: text | structured_output, streaming, predicted_outputs | 32768 | 32768 | In: $0.55, Out: $0.80, Cache Read: $0.25 | | upstage/solar-pro-3 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 131072 | 131072 | In: $0.15, Out: $0.60, Cache Read: $0.02 | | perplexity/sonar-pro-search | openrouter | In: text, image; Out: text | structured_output, reasoning, vision, streaming | 200000 | 8000 | In: $3.00, Out: $15.00 | | stepfun/step-3.7-flash | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 262144 | 256000 | In: $0.20, Out: $1.15, Cache Read: $0.04 | | arcee-ai/trinity-large-thinking | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 262144 | 262144 | In: $0.22, Out: $0.85, Cache Read: $0.06 | | bytedance/ui-tars-1.5-7b | openrouter | In: image, text; Out: text | structured_output, vision, streaming, predicted_outputs | 128000 | 2048 | In: $0.10, Out: $0.20, Cache Read: $0.10 | | thedrummer/unslopnemo-12b | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 1024000 | 1024000 | In: $0.40, Out: $0.40 | | mistralai/voxtral-small-24b-2507 | openrouter | In: text, audio, pdf; Out: text | function_calling, structured_output, vision, streaming | 32000 | 32000 | In: $0.10, Out: $0.30, Cache Read: $0.01 | | mancer/weaver | openrouter | In: text; Out: text | structured_output, streaming, predicted_outputs | 8000 | 6000 | In: $0.50, Out: $0.75 | | z-ai/glm-5.2:batch | openrouter | In: text; Out: text | streaming, function_calling, structured_output, predicted_outputs | 512000 | - | In: $0.70, Out: $2.20, Cache Read: $0.13 | | openai/gpt-oss-20b:free | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 131072 | 32768 | In: $0.00, Out: $0.00 | | openai/gpt-oss-safeguard-20b | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 131072 | 65536 | In: $0.08, Out: $0.30, Cache Read: $0.04 | | openai/o1 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 100000 | In: $15.00, Out: $60.00, Cache Read: $7.50 | | openai/o1-pro | openrouter | In: text, image, pdf; Out: text | structured_output, reasoning, vision, streaming | 200000 | 100000 | In: $150.00, Out: $600.00 | | openai/o3 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 100000 | In: $2.00, Out: $8.00, Cache Read: $0.50 | | openai/o3-mini-high | openrouter | In: text, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 100000 | In: $1.10, Out: $4.40, Cache Read: $0.55 | | openai/o3-mini | openrouter | In: text, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 100000 | In: $1.10, Out: $4.40, Cache Read: $0.55 | | openai/o3-pro | openrouter | In: text, pdf, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 100000 | In: $20.00, Out: $80.00 | | openai/o4-mini-high | openrouter | In: image, text, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 100000 | In: $1.10, Out: $4.40, Cache Read: $0.28 | | openai/o4-mini | openrouter | In: image, text, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 100000 | In: $1.10, Out: $4.40, Cache Read: $0.28 | | deepseek-ai/deepseek-v3.1-maas | vertexai | In: text, pdf; Out: text | function_calling, structured_output, reasoning, vision | 163840 | 32768 | In: $0.60, Out: $1.70 | | deepseek-ai/deepseek-v3.2-maas | vertexai | In: text, pdf; Out: text | function_calling, structured_output, reasoning, vision | 163840 | 65536 | In: $0.56, Out: $1.68, Cache Read: $0.06 | | zai-org/glm-4.7-maas | vertexai | In: text, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 128000 | In: $0.60, Out: $2.20 | | gemini-2.0-flash | vertexai | In: text, image, audio, video, pdf; Out: text | function_calling, structured_output, vision, video, streaming | 1048576 | 8192 | In: $0.10, Out: $0.40, Cache Read: $0.02 | | gemini-3-flash-preview | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $0.50, Out: $3.00, Cache Read: $0.05 | | gemini-3.1-flash-lite | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $0.25, Out: $1.50, Cache Read: $0.02 | | gemini-3.1-flash-lite-preview | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $0.25, Out: $1.50, Cache Read: $0.02 | | gemini-3.1-pro-preview | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $2.00, Out: $12.00, Cache Read: $0.20 | | gemini-3.1-pro-preview-customtools | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video | 1048576 | 65536 | In: $2.00, Out: $12.00, Cache Read: $0.20 | | gemini-3.5-flash | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $1.50, Out: $9.00, Cache Read: $0.15 | | gemini-3.5-flash-lite | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video | 1048576 | 65536 | In: $0.30, Out: $2.50, Cache Read: $0.03 | | gemini-3.6-flash | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video | 1048576 | 65536 | In: $1.50, Out: $7.50, Cache Read: $0.15 | | gemini-flash-latest | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video | 1048576 | 65536 | In: $1.50, Out: $9.00, Cache Read: $0.15 | | moonshotai/kimi-k2-thinking-maas | vertexai | In: text; Out: text | function_calling, structured_output, reasoning | 262144 | 262144 | In: $0.60, Out: $2.50 | | meta/llama-3.3-70b-instruct-maas | vertexai | In: text; Out: text | function_calling, structured_output | 128000 | 8192 | In: $0.72, Out: $0.72 | | meta/llama-4-maverick-17b-128e-instruct-maas | vertexai | In: text, image; Out: text | function_calling, structured_output, vision | 524288 | 8192 | In: $0.35, Out: $1.15 | | qwen/qwen3-235b-a22b-instruct-2507-maas | vertexai | In: text; Out: text | function_calling, structured_output, reasoning | 262144 | 16384 | In: $0.22, Out: $0.88 | | grok-4.20-0309-non-reasoning | xai | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 1000000 | 30000 | In: $1.25, Out: $2.50, Cache Read: $0.20 | | grok-4.20-0309-reasoning | xai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 30000 | In: $1.25, Out: $2.50, Cache Read: $0.20 | | grok-4.20-multi-agent-0309 | xai | In: text, image, pdf; Out: text | structured_output, reasoning, vision, streaming | 1000000 | 30000 | In: $1.25, Out: $2.50, Cache Read: $0.20 | | grok-4.3 | xai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 30000 | In: $1.25, Out: $2.50, Cache Read: $0.20 | | grok-4.5 | xai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 500000 | 500000 | In: $2.00, Out: $6.00, Cache Read: $0.30 | | grok-build-0.1 | xai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 256000 | 256000 | In: $1.00, Out: $2.00, Cache Read: $0.20 | ### Streaming (587) | Model | Provider | I/O | Capabilities | Context | Max Output | Standard Pricing (per 1M tokens) | | :-- | :-- | :-- | :-- | --: | --: | :-- | | anthropic.claude-3-haiku-20240307-v1:0 | bedrock | In: text, image; Out: text | streaming, function_calling | - | - | - | | anthropic.claude-3-haiku-20240307-v1:0:200k | bedrock | In: text, image; Out: text | streaming, function_calling | - | - | - | | anthropic.claude-3-haiku-20240307-v1:0:48k | bedrock | In: text, image; Out: text | streaming, function_calling | - | - | - | | us.anthropic.claude-fable-5 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 1000000 | 128000 | In: $10.00, Out: $50.00, Cache Read: $1.00, Cache Write: $12.50 | | us.anthropic.claude-haiku-4-5-20251001-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 64000 | In: $1.00, Out: $5.00, Cache Read: $0.10, Cache Write: $1.25 | | us.anthropic.claude-opus-4-1-20250805-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 200000 | 32000 | In: $15.00, Out: $75.00, Cache Read: $1.50, Cache Write: $18.75 | | us.anthropic.claude-opus-4-5-20251101-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 64000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | us.anthropic.claude-opus-4-6-v1 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | us.anthropic.claude-opus-4-7 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | us.anthropic.claude-opus-4-8 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | us.anthropic.claude-opus-5 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | us.anthropic.claude-sonnet-4-20250514-v1:0 | bedrock | In: text, image; Out: text | streaming, function_calling, reasoning | 200000 | 8192 | - | | us.anthropic.claude-sonnet-4-5-20250929-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | us.anthropic.claude-sonnet-4-6 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | us.anthropic.claude-sonnet-5 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $2.00, Out: $10.00, Cache Read: $0.20, Cache Write: $2.50 | | cohere.command-r-v1:0 | bedrock | In: text; Out: text | streaming, function_calling | - | - | - | | cohere.command-r-plus-v1:0 | bedrock | In: text; Out: text | streaming, function_calling | - | - | - | | us.deepseek.r1-v1:0 | bedrock | In: text; Out: text | function_calling, reasoning, streaming | 128000 | 32768 | In: $1.35, Out: $5.40 | | deepseek.v3-v1:0 | bedrock | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 163840 | 81920 | In: $0.58, Out: $1.68 | | deepseek.v3.2 | bedrock | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 163840 | 81920 | In: $0.62, Out: $1.85 | | mistral.devstral-2-123b | bedrock | In: text; Out: text | function_calling, structured_output, streaming | 256000 | 8192 | In: $0.40, Out: $2.00 | | zai.glm-4.7 | bedrock | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 204800 | 131072 | In: $0.60, Out: $2.20 | | zai.glm-4.7-flash | bedrock | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 200000 | 131072 | In: $0.07, Out: $0.40 | | zai.glm-5 | bedrock | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 202752 | 101376 | In: $1.00, Out: $3.20 | | openai.gpt-oss-safeguard-120b | bedrock | In: text; Out: text | function_calling, structured_output, streaming | 128000 | 16384 | In: $0.15, Out: $0.60 | | openai.gpt-oss-safeguard-20b | bedrock | In: text; Out: text | function_calling, structured_output, streaming | 128000 | 16384 | In: $0.07, Out: $0.20 | | google.gemma-3-4b-it | bedrock | In: text, image; Out: text | function_calling, vision, streaming | 128000 | 4096 | In: $0.04, Out: $0.08 | | google.gemma-3-12b-it | bedrock | In: text, image; Out: text | structured_output, vision, streaming | 131072 | 8192 | In: $0.05, Out: $0.10 | | google.gemma-3-27b-it | bedrock | In: text, image; Out: text | function_calling, structured_output, vision, streaming | 202752 | 8192 | In: $0.12, Out: $0.20 | | moonshot.kimi-k2-thinking | bedrock | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 262143 | 16000 | In: $0.60, Out: $2.50 | | moonshotai.kimi-k2.5 | bedrock | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 262143 | 16000 | In: $0.60, Out: $3.00 | | meta.llama3-70b-instruct-v1:0 | bedrock | In: text; Out: text | streaming, function_calling | - | - | - | | meta.llama3-8b-instruct-v1:0 | bedrock | In: text; Out: text | streaming, function_calling | - | - | - | | meta.llama3-1-70b-instruct-v1:0 | bedrock | In: text; Out: text | function_calling, streaming | 128000 | 4096 | In: $0.72, Out: $0.72 | | meta.llama3-1-70b-instruct-v1:0:128k | bedrock | In: text; Out: text | function_calling, streaming | 128000 | 4096 | In: $0.72, Out: $0.72 | | meta.llama3-1-8b-instruct-v1:0 | bedrock | In: text; Out: text | function_calling, streaming | 128000 | 4096 | In: $0.22, Out: $0.22 | | meta.llama3-1-8b-instruct-v1:0:128k | bedrock | In: text; Out: text | function_calling, streaming | 128000 | 4096 | In: $0.22, Out: $0.22 | | meta.llama3-3-70b-instruct-v1:0:128k | bedrock | In: text; Out: text | function_calling, streaming | 128000 | 4096 | In: $0.72, Out: $0.72 | | us.meta.llama3-3-70b-instruct-v1:0 | bedrock | In: text; Out: text | function_calling, streaming | 128000 | 4096 | In: $0.72, Out: $0.72 | | us.meta.llama4-maverick-17b-instruct-v1:0 | bedrock | In: text, image; Out: text | function_calling, vision, streaming | 1000000 | 16384 | In: $0.24, Out: $0.97 | | us.meta.llama4-scout-17b-instruct-v1:0 | bedrock | In: text, image; Out: text | function_calling, vision, streaming | 3500000 | 16384 | In: $0.17, Out: $0.66 | | mistral.magistral-small-2509 | bedrock | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 128000 | 40000 | In: $0.50, Out: $1.50 | | minimax.minimax-m2 | bedrock | In: text; Out: text | function_calling, reasoning, streaming | 204608 | 128000 | In: $0.30, Out: $1.20 | | minimax.minimax-m2.1 | bedrock | In: text; Out: text | function_calling, reasoning, streaming | 204800 | 131072 | In: $0.30, Out: $1.20 | | minimax.minimax-m2.5 | bedrock | In: text; Out: text | function_calling, reasoning, streaming | 196608 | 98304 | In: $0.30, Out: $1.20 | | mistral.ministral-3-14b-instruct | bedrock | In: text; Out: text | function_calling, structured_output, streaming | 128000 | 4096 | In: $0.20, Out: $0.20 | | mistral.ministral-3-3b-instruct | bedrock | In: text, image; Out: text | function_calling, structured_output, vision, streaming | 256000 | 8192 | In: $0.10, Out: $0.10 | | mistral.ministral-3-8b-instruct | bedrock | In: text; Out: text | function_calling, structured_output, streaming | 128000 | 4096 | In: $0.15, Out: $0.15 | | mistral.mistral-7b-instruct-v0:2 | bedrock | In: text; Out: text | streaming, function_calling | - | - | - | | mistral.mistral-large-2402-v1:0 | bedrock | In: text; Out: text | streaming, function_calling | - | - | - | | mistral.mistral-large-2407-v1:0 | bedrock | In: text; Out: text | streaming, function_calling | - | - | - | | mistral.mistral-large-3-675b-instruct | bedrock | In: text, image; Out: text | function_calling, structured_output, vision, streaming | 256000 | 8192 | In: $0.50, Out: $1.50 | | mistral.mixtral-8x7b-instruct-v0:1 | bedrock | In: text; Out: text | streaming, function_calling | - | - | - | | nvidia.nemotron-super-3-120b | bedrock | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 262144 | 131072 | In: $0.15, Out: $0.65 | | nvidia.nemotron-nano-12b-v2 | bedrock | In: text, image; Out: text | function_calling, structured_output, vision, streaming | 128000 | 4096 | In: $0.20, Out: $0.60 | | nvidia.nemotron-nano-3-30b | bedrock | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 128000 | 4096 | In: $0.06, Out: $0.24 | | nvidia.nemotron-nano-9b-v2 | bedrock | In: text; Out: text | function_calling, structured_output, streaming | 128000 | 4096 | In: $0.06, Out: $0.23 | | us.amazon.nova-2-lite-v1:0 | bedrock | In: text, image, video; Out: text | function_calling, reasoning, vision, video, streaming | 128000 | 4096 | In: $0.33, Out: $2.75 | | amazon.nova-2-sonic-v1:0 | bedrock | In: audio; Out: audio, text | streaming, function_calling | - | - | - | | amazon.nova-lite-v1:0 | bedrock | In: text, image, video; Out: text | function_calling, vision, video, streaming | 300000 | 8192 | In: $0.06, Out: $0.24, Cache Read: $0.02 | | us.amazon.nova-micro-v1:0 | bedrock | In: text; Out: text | function_calling, streaming | 128000 | 8192 | In: $0.04, Out: $0.14, Cache Read: $0.01 | | amazon.nova-premier-v1:0:1000k | bedrock | In: text, image, video; Out: text | streaming, function_calling | - | - | - | | amazon.nova-premier-v1:0:20k | bedrock | In: text, image, video; Out: text | streaming, function_calling | - | - | - | | amazon.nova-premier-v1:0:8k | bedrock | In: text, image, video; Out: text | streaming, function_calling | - | - | - | | amazon.nova-premier-v1:0:mm | bedrock | In: text, image, video; Out: text | streaming, function_calling | - | - | - | | us.amazon.nova-premier-v1:0 | bedrock | In: text, image, video; Out: text | streaming, function_calling | - | - | - | | us.amazon.nova-pro-v1:0 | bedrock | In: text, image, video; Out: text | function_calling, vision, video, streaming | 300000 | 8192 | In: $0.80, Out: $3.20, Cache Read: $0.20 | | us.writer.palmyra-x4-v1:0 | bedrock | In: text; Out: text | function_calling, reasoning, streaming | 122880 | 8192 | In: $2.50, Out: $10.00 | | us.writer.palmyra-x5-v1:0 | bedrock | In: text; Out: text | function_calling, reasoning, streaming | 1040000 | 8192 | In: $0.60, Out: $6.00 | | us.twelvelabs.pegasus-1-2-v1:0 | bedrock | In: text, video; Out: text | streaming, function_calling | - | - | - | | us.mistral.pixtral-large-2502-v1:0 | bedrock | In: text, image; Out: text | function_calling, vision, streaming | 128000 | 8192 | In: $2.00, Out: $6.00 | | qwen.qwen3-next-80b-a3b | bedrock | In: text; Out: text | function_calling, structured_output, streaming | 262000 | 262000 | In: $0.14, Out: $1.40 | | qwen.qwen3-vl-235b-a22b | bedrock | In: text, image; Out: text | function_calling, structured_output, vision, streaming | 262000 | 262000 | In: $0.30, Out: $1.50 | | qwen.qwen3-235b-a22b-2507-v1:0 | bedrock | In: text; Out: text | function_calling, structured_output, streaming | 262144 | 131072 | In: $0.22, Out: $0.88 | | qwen.qwen3-32b-v1:0 | bedrock | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 16384 | 16384 | In: $0.15, Out: $0.60 | | qwen.qwen3-coder-30b-a3b-v1:0 | bedrock | In: text; Out: text | function_calling, structured_output, streaming | 262144 | 131072 | In: $0.15, Out: $0.60 | | qwen.qwen3-coder-480b-a35b-v1:0 | bedrock | In: text; Out: text | function_calling, structured_output, streaming | 131072 | 65536 | In: $0.22, Out: $1.80 | | mistral.voxtral-mini-3b-2507 | bedrock | In: audio, text; Out: text | function_calling, structured_output, streaming | 128000 | 4096 | In: $0.04, Out: $0.04 | | mistral.voxtral-small-24b-2507 | bedrock | In: text, audio; Out: text | function_calling, structured_output, streaming | 32000 | 8192 | In: $0.15, Out: $0.35 | | writer.palmyra-vision-7b | bedrock | In: text, image; Out: text | streaming, function_calling | - | 4096 | - | | openai.gpt-oss-120b-1:0 | bedrock | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 128000 | 16384 | In: $0.15, Out: $0.60 | | openai.gpt-oss-20b-1:0 | bedrock | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 128000 | 16384 | In: $0.07, Out: $0.30 | | codestral-2508 | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, predicted_outputs, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | codestral-latest | mistral | In: text; Out: text | function_calling, streaming, batch, predicted_outputs, tool_choice, parallel_tool_calls | 256000 | 4096 | In: $0.30, Out: $0.90 | | devstral-2512 | mistral | In: text; Out: text | function_calling, streaming, batch, fine_tuning, tool_choice, parallel_tool_calls | 262144 | 262144 | In: $0.40, Out: $2.00 | | devstral-latest | mistral | In: text; Out: text | function_calling, streaming, batch, fine_tuning, tool_choice, parallel_tool_calls | 262144 | 262144 | In: $0.40, Out: $2.00 | | devstral-medium-latest | mistral | In: text; Out: text | function_calling, streaming, batch, fine_tuning, tool_choice, parallel_tool_calls | 262144 | 262144 | In: $0.40, Out: $2.00 | | labs-leanstral-1-5 | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | labs-leanstral-1-5-1 | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | magistral-medium-latest | mistral | In: text; Out: text | function_calling, reasoning, streaming, batch, tool_choice, parallel_tool_calls | 128000 | 16384 | In: $2.00, Out: $5.00 | | magistral-medium-2509 | mistral | In: text; Out: text | streaming, function_calling, structured_output, reasoning, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | magistral-small-2509 | mistral | In: text; Out: text | streaming, function_calling, structured_output, reasoning, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | magistral-small-latest | mistral | In: text; Out: text | streaming, function_calling, structured_output, reasoning, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | ministral-14b-2512 | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, distillation, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | ministral-14b-latest | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, distillation, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | ministral-3b-2512 | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, distillation, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | ministral-3b-latest | mistral | In: text; Out: text | function_calling, streaming, batch, distillation, tool_choice, parallel_tool_calls | 128000 | 128000 | In: $0.04, Out: $0.04 | | ministral-8b-2512 | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, distillation, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | ministral-8b-latest | mistral | In: text; Out: text | function_calling, streaming, batch, distillation, tool_choice, parallel_tool_calls | 128000 | 128000 | In: $0.10, Out: $0.10 | | mistral-code-agent-latest | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | mistral-code-fim-latest | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | mistral-code-latest | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | mistral-large-latest | mistral | In: text, image; Out: text | function_calling, vision, streaming, batch, fine_tuning, tool_choice, parallel_tool_calls | 262144 | 262144 | In: $0.50, Out: $1.50 | | mistral-large-2512 | mistral | In: text, image; Out: text | function_calling, vision, streaming, batch, fine_tuning, tool_choice, parallel_tool_calls | 262144 | 262144 | In: $0.50, Out: $1.50 | | mistral-medium | mistral | In: text; Out: text | streaming, function_calling, structured_output, vision, batch, fine_tuning, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | mistral-medium-3 | mistral | In: text; Out: text | streaming, function_calling, structured_output, vision, reasoning, batch, fine_tuning, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | mistral-medium-3-5 | mistral | In: text; Out: text | streaming, function_calling, structured_output, vision, reasoning, batch, fine_tuning, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | mistral-medium-3.5 | mistral | In: text; Out: text | streaming, function_calling, structured_output, vision, reasoning, batch, fine_tuning, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | mistral-medium-latest | mistral | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming, batch, fine_tuning, tool_choice, parallel_tool_calls | 262144 | 262144 | In: $1.50, Out: $7.50 | | mistral-medium-2505 | mistral | In: text, image; Out: text | function_calling, vision, streaming, batch, fine_tuning, tool_choice, parallel_tool_calls | 131072 | 131072 | In: $0.40, Out: $2.00 | | mistral-medium-2508 | mistral | In: text, image; Out: text | function_calling, vision, streaming, batch, fine_tuning, tool_choice, parallel_tool_calls | 262144 | 262144 | In: $0.40, Out: $2.00 | | mistral-medium-2604 | mistral | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming, batch, fine_tuning, tool_choice, parallel_tool_calls | 262144 | 262144 | In: $1.50, Out: $7.50 | | mistral-small-latest | mistral | In: text, image; Out: text | function_calling, reasoning, vision, streaming, batch, fine_tuning, tool_choice, parallel_tool_calls | 256000 | 256000 | In: $0.15, Out: $0.60 | | mistral-small-2506 | mistral | In: text, image; Out: text | function_calling, vision, streaming, batch, fine_tuning, tool_choice, parallel_tool_calls | 128000 | 16384 | In: $0.10, Out: $0.30 | | mistral-small-2603 | mistral | In: text, image; Out: text | function_calling, reasoning, vision, streaming, batch, fine_tuning, tool_choice, parallel_tool_calls | 256000 | 256000 | In: $0.15, Out: $0.60 | | mistral-tiny-2407 | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | mistral-tiny-latest | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | mistral-vibe-cli-fast | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | mistral-vibe-cli-latest | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | mistral-vibe-cli-with-tools | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | open-mistral-nemo | mistral | In: text; Out: text | function_calling, streaming, batch, tool_choice, parallel_tool_calls | 128000 | 128000 | In: $0.15, Out: $0.15 | | open-mistral-nemo-2407 | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | voxtral-mini-latest | mistral | In: audio; Out: text | streaming | 0 | 0 | - | | voxtral-mini-2507 | mistral | In: text; Out: text | streaming | 32768 | 8192 | - | | voxtral-mini-2602 | mistral | In: text; Out: text | streaming | 32768 | 8192 | - | | voxtral-mini-realtime-2602 | mistral | In: text; Out: text | streaming | 32768 | 8192 | - | | voxtral-mini-realtime-latest | mistral | In: text; Out: text | streaming | 32768 | 8192 | - | | voxtral-mini-tts-latest | mistral | In: text; Out: audio | streaming | 0 | 0 | - | | voxtral-mini-tts-2603 | mistral | In: text; Out: text | streaming | 32768 | 8192 | - | | voxtral-mini-tts-mellon-greek-2606-solutions | mistral | In: text; Out: text | streaming | 32768 | 8192 | - | | voxtral-small-latest | mistral | In: text, audio; Out: text | function_calling, streaming | 32000 | 32000 | In: $0.10, Out: $0.30 | | voxtral-small-2507 | mistral | In: text; Out: text | streaming | 32768 | 8192 | - | | aion-labs/aion-2.0 | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 131072 | 32768 | In: $0.80, Out: $1.60, Cache Read: $0.20 | | aion-labs/aion-3.0 | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 131072 | 32768 | In: $3.00, Out: $6.00, Cache Read: $0.75 | | aion-labs/aion-3.0-mini | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 131072 | 32768 | In: $0.70, Out: $1.40, Cache Read: $0.18 | | aion-labs/aion-rp-llama-3.1-8b | openrouter | In: text; Out: text | streaming | 32768 | 32768 | In: $0.80, Out: $1.60 | | ~anthropic/claude-haiku-latest | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 64000 | In: $1.00, Out: $5.00, Cache Read: $0.10, Cache Write: $1.25 | | ~anthropic/claude-sonnet-latest | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $2.00, Out: $10.00, Cache Read: $0.20, Cache Write: $2.50 | | anthropic/claude-fable-5:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50 | | anthropic/claude-haiku-4.5:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 200000 | 64000 | In: $0.50, Out: $2.50, Cache Read: $0.05 | | anthropic/claude-opus-4.1:batch | openrouter | In: image, text, file; Out: text | streaming, function_calling, structured_output | 200000 | 32000 | In: $7.50, Out: $37.50, Cache Read: $0.75 | | anthropic/claude-opus-4.5:batch | openrouter | In: file, image, text; Out: text | streaming, function_calling, structured_output | 200000 | 64000 | In: $2.50, Out: $12.50, Cache Read: $0.25 | | anthropic/claude-opus-4.6:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 1000000 | 128000 | In: $2.50, Out: $12.50, Cache Read: $0.25 | | anthropic/claude-opus-4.7:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 1000000 | 128000 | In: $2.50, Out: $12.50, Cache Read: $0.25 | | anthropic/claude-opus-4.8:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 1000000 | 128000 | In: $2.50, Out: $12.50, Cache Read: $0.25 | | anthropic/claude-sonnet-4.5:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 1000000 | 64000 | In: $1.50, Out: $7.50, Cache Read: $0.15 | | anthropic/claude-sonnet-4.6:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 1000000 | 128000 | In: $1.50, Out: $7.50, Cache Read: $0.15 | | anthropic/claude-sonnet-5:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 1000000 | 128000 | In: $1.00, Out: $5.00, Cache Read: $0.10 | | openrouter/auto | openrouter | In: text, image, audio, pdf, video; Out: text, image | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 2000000 | 2000000 | - | | openrouter/auto-beta | openrouter | In: text, image, audio, file, video; Out: text, image | streaming, function_calling, structured_output, predicted_outputs | 2000000 | - | - | | openrouter/bodybuilder | openrouter | In: text; Out: text | streaming | 128000 | 128000 | - | | anthropic/claude-3-haiku | openrouter | In: text, image; Out: text | function_calling, vision, streaming | 200000 | 4096 | In: $0.25, Out: $1.25, Cache Read: $0.03, Cache Write: $0.30 | | anthropic/claude-fable-5 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $10.00, Out: $50.00, Cache Read: $1.00, Cache Write: $12.50 | | ~anthropic/claude-fable-latest | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $10.00, Out: $50.00, Cache Read: $1.00, Cache Write: $12.50 | | anthropic/claude-haiku-4.5 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 64000 | In: $1.00, Out: $5.00, Cache Read: $0.10, Cache Write: $1.25 | | anthropic/claude-opus-4 | openrouter | In: image, text, pdf; Out: text | function_calling, reasoning, vision, streaming | 200000 | 32000 | In: $15.00, Out: $75.00, Cache Read: $1.50, Cache Write: $18.75 | | anthropic/claude-opus-4.1 | openrouter | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 200000 | 32000 | In: $15.00, Out: $75.00, Cache Read: $1.50, Cache Write: $18.75 | | anthropic/claude-opus-4.5 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 64000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | anthropic/claude-opus-4.6 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | anthropic/claude-opus-4.7 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | anthropic/claude-opus-4.7-fast | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $30.00, Out: $150.00, Cache Read: $3.00, Cache Write: $37.50 | | anthropic/claude-opus-4.8 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | anthropic/claude-opus-4.8-fast | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $10.00, Out: $50.00, Cache Read: $1.00, Cache Write: $12.50 | | anthropic/claude-opus-5 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | anthropic/claude-opus-5-fast | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $10.00, Out: $50.00, Cache Read: $1.00, Cache Write: $12.50 | | anthropic/claude-opus-5:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 1000000 | 128000 | In: $2.50, Out: $12.50, Cache Read: $0.25 | | ~anthropic/claude-opus-latest | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | anthropic/claude-sonnet-4 | openrouter | In: image, text, pdf; Out: text | function_calling, reasoning, vision, streaming | 1000000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | anthropic/claude-sonnet-4.5 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | anthropic/claude-sonnet-4.6 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | anthropic/claude-sonnet-5 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $2.00, Out: $10.00, Cache Read: $0.20, Cache Write: $2.50 | | mistralai/codestral-2508 | openrouter | In: text, pdf; Out: text | function_calling, structured_output, vision, streaming | 256000 | 256000 | In: $0.30, Out: $0.90, Cache Read: $0.03 | | deepcogito/cogito-v2.1-671b | openrouter | In: text; Out: text | structured_output, reasoning, streaming, predicted_outputs | 128000 | 128000 | In: $1.25, Out: $1.25 | | cohere/command-a | openrouter | In: text; Out: text | structured_output, streaming | 256000 | 8192 | In: $2.50, Out: $10.00 | | cohere/command-r-08-2024 | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 128000 | 4000 | In: $0.15, Out: $0.60 | | cohere/command-r-plus-08-2024 | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 128000 | 4000 | In: $2.50, Out: $10.00 | | cohere/command-r7b-12-2024 | openrouter | In: text; Out: text | structured_output, streaming | 128000 | 4000 | In: $0.04, Out: $0.15 | | thedrummer/cydonia-24b-v4.1 | openrouter | In: text; Out: text | structured_output, streaming, predicted_outputs | 131072 | 131072 | In: $0.30, Out: $0.50, Cache Read: $0.15 | | deepseek/deepseek-chat | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 163840 | 16000 | In: $0.26, Out: $1.03 | | deepseek/deepseek-chat-v3-0324 | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 163840 | 65536 | In: $0.27, Out: $1.12, Cache Read: $0.14 | | deepseek/deepseek-chat-v3.1 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 163840 | 32768 | In: $0.25, Out: $0.95, Cache Read: $0.13 | | deepseek/deepseek-v3.1-terminus | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 163840 | 32768 | In: $0.27, Out: $1.00, Cache Read: $0.14 | | deepseek/deepseek-v3.2 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 163840 | 65536 | In: $0.27, Out: $0.40, Cache Read: $0.13 | | deepseek/deepseek-v3.2-exp | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 163840 | 65536 | In: $0.27, Out: $0.41 | | deepseek/deepseek-v4-flash | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 1048576 | 393216 | In: $0.14, Out: $0.28, Cache Read: $0.03 | | deepseek/deepseek-v4-flash-0731 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 1048576 | 65536 | In: $0.09, Out: $0.18, Cache Read: $0.02 | | ~deepseek/deepseek-v4-flash-latest | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 1048576 | 65536 | In: $0.09, Out: $0.18, Cache Read: $0.02 | | deepseek/deepseek-v4-pro | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 1048576 | 384000 | In: $0.44, Out: $0.87, Cache Read: $0.00 | | deepseek/deepseek-r1 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 163840 | 16000 | In: $0.70, Out: $2.50 | | baidu/ernie-4.5-vl-424b-a47b | openrouter | In: image, text; Out: text | reasoning, vision, streaming | 123000 | 16000 | In: $0.42, Out: $1.25 | | openrouter/free | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 8000 | In: $0.00, Out: $0.00 | | sakana/fugu-ultra | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $30.00, Cache Read: $0.50 | | openrouter/fusion | openrouter | In: text; Out: text | streaming | 1000000 | 128000 | - | | z-ai/glm-4.5 | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 131072 | 98304 | In: $0.60, Out: $2.20, Cache Read: $0.11 | | z-ai/glm-4.5-air | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 131072 | 98304 | In: $0.13, Out: $0.85, Cache Read: $0.02 | | z-ai/glm-4.5v | openrouter | In: text, image; Out: text | function_calling, reasoning, vision, streaming | 65536 | 16384 | In: $0.60, Out: $1.80, Cache Read: $0.11 | | z-ai/glm-4.6 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 204800 | 131072 | In: $0.50, Out: $2.00, Cache Read: $0.10 | | z-ai/glm-4.6v | openrouter | In: text, image, video; Out: text | function_calling, reasoning, vision, video, streaming | 131072 | 32768 | In: $0.30, Out: $0.90, Cache Read: $0.06 | | z-ai/glm-4.7 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 204800 | 131072 | In: $0.40, Out: $1.75, Cache Read: $0.08 | | z-ai/glm-4.7-flash | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 202752 | 16384 | In: $0.06, Out: $0.40, Cache Read: $0.01 | | z-ai/glm-5 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 204800 | 131072 | In: $0.95, Out: $2.55, Cache Read: $0.20 | | z-ai/glm-5-turbo | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 202752 | 131072 | In: $1.20, Out: $4.00, Cache Read: $0.24 | | z-ai/glm-5.1 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 204800 | 131072 | In: $0.95, Out: $2.99, Cache Read: $0.18 | | z-ai/glm-5.2 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 1048576 | 131072 | In: $0.46, Out: $1.45, Cache Read: $0.09 | | z-ai/glm-5v-turbo | openrouter | In: image, text, video; Out: text | function_calling, reasoning, vision, video, streaming | 202752 | 131072 | In: $1.20, Out: $4.00, Cache Read: $0.24 | | openai/gpt-audio | openrouter | In: text, audio; Out: text, audio | function_calling, structured_output, streaming | 128000 | 16384 | In: $2.50, Out: $10.00 | | openai/gpt-audio-mini | openrouter | In: text, audio; Out: text, audio | function_calling, structured_output, streaming | 128000 | 16384 | In: $0.60, Out: $2.40 | | openai/gpt-chat-latest | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 400000 | 128000 | In: $5.00, Out: $30.00, Cache Read: $0.50 | | openai/gpt-oss-120b | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 131072 | 131072 | In: $0.04, Out: $0.17 | | openai/gpt-oss-20b | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 131072 | 131072 | In: $0.03, Out: $0.13, Cache Read: $0.03 | | openai/gpt-3.5-turbo-0613 | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 4095 | 4096 | In: $1.00, Out: $2.00 | | openai/gpt-3.5-turbo-16k | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 16385 | 4096 | In: $3.00, Out: $4.00 | | openai/gpt-3.5-turbo-instruct | openrouter | In: text; Out: text | structured_output, streaming | 4095 | 4096 | In: $1.50, Out: $2.00 | | openai/gpt-3.5-turbo | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 16385 | 4096 | In: $0.50, Out: $1.50 | | openai/gpt-4 | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 8191 | 4096 | In: $30.00, Out: $60.00 | | openai/gpt-4-turbo | openrouter | In: text, image; Out: text | function_calling, structured_output, vision, streaming | 128000 | 4096 | In: $10.00, Out: $30.00 | | openai/gpt-4-turbo-preview | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 128000 | 4096 | In: $10.00, Out: $30.00 | | openai/gpt-4.1 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 1047576 | 32768 | In: $2.00, Out: $8.00, Cache Read: $0.50 | | openai/gpt-4.1-mini | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 1047576 | 32768 | In: $0.40, Out: $1.60, Cache Read: $0.10 | | openai/gpt-4.1-nano | openrouter | In: image, text, pdf; Out: text | function_calling, structured_output, vision, streaming | 1047576 | 32768 | In: $0.10, Out: $0.40, Cache Read: $0.02 | | openai/gpt-4o | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 128000 | 16384 | In: $2.50, Out: $10.00, Cache Read: $1.25 | | openai/gpt-4o-2024-05-13 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 128000 | 4096 | In: $5.00, Out: $15.00 | | openai/gpt-4o-2024-08-06 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 128000 | 16384 | In: $2.50, Out: $10.00, Cache Read: $1.25 | | openai/gpt-4o-2024-11-20 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 128000 | 16384 | In: $2.50, Out: $10.00, Cache Read: $1.25 | | openai/gpt-4o-mini | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 128000 | 16384 | In: $0.15, Out: $0.60, Cache Read: $0.08 | | openai/gpt-4o-mini-2024-07-18 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 128000 | 16384 | In: $0.15, Out: $0.60, Cache Read: $0.08 | | openai/gpt-5 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | openai/gpt-5-image | openrouter | In: image, text, pdf; Out: image, text | structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $10.00, Out: $10.00, Cache Read: $1.25 | | openai/gpt-5-image-mini | openrouter | In: pdf, image, text; Out: image, text | structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $2.50, Out: $2.00, Cache Read: $0.25 | | openai/gpt-5-mini | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $0.25, Out: $2.00, Cache Read: $0.02 | | openai/gpt-5-nano | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $0.05, Out: $0.40, Cache Read: $0.01 | | openai/gpt-5-pro | openrouter | In: image, text, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $15.00, Out: $120.00 | | openai/gpt-5.1 | openrouter | In: image, text, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | openai/gpt-5.1-codex | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $1.25, Out: $10.00, Cache Read: $0.13 | | openai/gpt-5.1-codex-max | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | openai/gpt-5.1-codex-mini | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $0.25, Out: $2.00, Cache Read: $0.03 | | openai/gpt-5.2 | openrouter | In: pdf, image, text; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $1.75, Out: $14.00, Cache Read: $0.18 | | openai/gpt-5.2-chat | openrouter | In: pdf, image, text; Out: text | function_calling, structured_output, vision, streaming | 128000 | 16384 | In: $1.75, Out: $14.00, Cache Read: $0.18 | | openai/gpt-5.2-codex | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $1.75, Out: $14.00, Cache Read: $0.18 | | openai/gpt-5.2-pro | openrouter | In: image, text, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $21.00, Out: $168.00 | | openai/gpt-5.3-chat | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 128000 | 16384 | In: $1.75, Out: $14.00, Cache Read: $0.18 | | openai/gpt-5.3-codex | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $1.75, Out: $14.00, Cache Read: $0.18 | | openai/gpt-5.4 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $2.50, Out: $15.00, Cache Read: $0.25 | | openai/gpt-5.4-image-2 | openrouter | In: image, text, pdf; Out: image, text | structured_output, reasoning, vision, streaming | 272000 | 128000 | In: $8.00, Out: $15.00, Cache Read: $2.00 | | openai/gpt-5.4-pro | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $30.00, Out: $180.00 | | openai/gpt-5.4-mini | openrouter | In: pdf, image, text; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $0.75, Out: $4.50, Cache Read: $0.08 | | openai/gpt-5.4-nano | openrouter | In: pdf, image, text; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $0.20, Out: $1.25, Cache Read: $0.02 | | openai/gpt-5.5 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $5.00, Out: $30.00, Cache Read: $0.50 | | openai/gpt-5.5-pro | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $30.00, Out: $180.00 | | openai/gpt-5.6-luna | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $0.10, Out: $0.60, Cache Read: $0.01, Cache Write: $0.12 | | openai/gpt-5.6-luna-pro | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $0.10, Out: $0.60, Cache Read: $0.01, Cache Write: $0.12 | | openai/gpt-5.6-sol | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $5.00, Out: $30.00, Cache Read: $0.50, Cache Write: $6.25 | | openai/gpt-5.6-sol-pro | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $5.00, Out: $30.00, Cache Read: $0.50, Cache Write: $6.25 | | openai/gpt-5.6-terra | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $1.00, Out: $6.00, Cache Read: $0.10, Cache Write: $1.25 | | openai/gpt-5.6-terra-pro | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $1.00, Out: $6.00, Cache Read: $0.10, Cache Write: $1.25 | | google/gemini-2.5-flash | openrouter | In: text, image, audio, video, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65535 | In: $0.30, Out: $2.50, Cache Read: $0.03, Cache Write: $0.08 | | google/gemini-2.5-flash-lite | openrouter | In: text, image, audio, video, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65535 | In: $0.10, Out: $0.40, Cache Read: $0.01, Cache Write: $0.08 | | google/gemini-2.5-pro | openrouter | In: text, image, audio, video, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $1.25, Out: $10.00, Cache Read: $0.12, Cache Write: $0.38 | | google/gemini-2.5-pro-preview-05-06 | openrouter | In: text, image, pdf, audio, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65535 | In: $1.25, Out: $10.00, Cache Read: $0.12, Cache Write: $0.38 | | google/gemini-2.5-pro-preview | openrouter | In: pdf, image, text, audio; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1048576 | 65536 | In: $1.25, Out: $10.00, Cache Read: $0.12, Cache Write: $0.38 | | google/gemini-3-flash-preview | openrouter | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $0.50, Out: $3.00, Cache Read: $0.05, Cache Write: $0.08 | | google/gemini-3.1-flash-lite | openrouter | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $0.25, Out: $1.50, Cache Read: $0.02, Cache Write: $0.08 | | google/gemini-3.1-flash-lite-preview | openrouter | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $0.25, Out: $1.50, Cache Read: $0.02, Cache Write: $0.08 | | google/gemini-3.1-pro-preview | openrouter | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $2.00, Out: $12.00, Cache Read: $0.20, Cache Write: $0.38 | | google/gemini-3.1-pro-preview-customtools | openrouter | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $2.00, Out: $12.00, Cache Read: $0.20, Cache Write: $0.38 | | google/gemini-3.5-flash | openrouter | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $1.50, Out: $9.00, Cache Read: $0.15, Cache Write: $0.08 | | google/gemini-3.5-flash-lite | openrouter | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $0.30, Out: $2.50, Cache Read: $0.03, Cache Write: $0.08 | | google/gemini-3.6-flash | openrouter | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $1.50, Out: $7.50, Cache Read: $0.15, Cache Write: $0.08 | | google/gemma-2-27b-it | openrouter | In: text; Out: text | structured_output, streaming | 8192 | 2048 | In: $0.65, Out: $0.65 | | google/gemma-3-12b-it | openrouter | In: text, image; Out: text | function_calling, structured_output, vision, streaming, predicted_outputs | 131072 | 16384 | In: $0.05, Out: $0.15 | | google/gemma-3-27b-it | openrouter | In: text, image; Out: text | function_calling, structured_output, vision, streaming, predicted_outputs | 262144 | 131072 | In: $0.08, Out: $0.45, Cache Read: $0.04 | | google/gemma-3-4b-it | openrouter | In: text, image; Out: text | structured_output, vision, streaming, predicted_outputs | 131072 | 16384 | In: $0.05, Out: $0.10 | | google/gemma-3n-e4b-it | openrouter | In: text; Out: text | structured_output, streaming, predicted_outputs | 32768 | 32768 | In: $0.06, Out: $0.12 | | google/gemma-4-26b-a4b-it:free | openrouter | In: image, text, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 262144 | 32768 | In: $0.00, Out: $0.00 | | google/gemma-4-26b-a4b-it | openrouter | In: image, text, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 262144 | 16384 | In: $0.07, Out: $0.34 | | google/gemma-4-31b-it:free | openrouter | In: image, text, video; Out: text | function_calling, reasoning, vision, video, streaming | 262144 | 32768 | In: $0.00, Out: $0.00 | | google/gemma-4-31b-it | openrouter | In: image, text, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 262144 | 262144 | In: $0.10, Out: $0.34, Cache Read: $0.10 | | ~google/gemini-flash-latest | openrouter | In: text, image, video, pdf, audio; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $1.50, Out: $7.50, Cache Read: $0.15, Cache Write: $0.08 | | ~google/gemini-pro-latest | openrouter | In: audio, pdf, image, text, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $2.00, Out: $12.00, Cache Read: $0.20, Cache Write: $0.38 | | google/gemini-2.5-flash:batch | openrouter | In: file, image, text, audio, video; Out: text | streaming, function_calling, structured_output | 1048576 | 65535 | In: $0.15, Out: $1.25, Cache Read: $0.03 | | google/gemini-2.5-flash-lite:batch | openrouter | In: text, image, file, audio, video; Out: text | streaming, function_calling, structured_output | 1048576 | 65535 | In: $0.05, Out: $0.20, Cache Read: $0.01 | | google/gemini-2.5-pro:batch | openrouter | In: text, image, file, audio, video; Out: text | streaming, function_calling, structured_output | 1048576 | 65536 | In: $0.62, Out: $5.00, Cache Read: $0.12 | | google/gemini-3-flash-preview:batch | openrouter | In: text, image, file, audio, video; Out: text | streaming, function_calling, structured_output | 1048576 | 65536 | In: $0.25, Out: $1.50 | | google/gemini-3.1-flash-lite:batch | openrouter | In: text, image, video, file, audio; Out: text | streaming, function_calling, structured_output | 1048576 | 65536 | In: $0.12, Out: $0.75, Cache Read: $0.01 | | google/gemini-3.1-pro-preview:batch | openrouter | In: audio, file, image, text, video; Out: text | streaming, function_calling, structured_output | 1048576 | 65536 | In: $1.00, Out: $6.00 | | google/gemini-3.5-flash:batch | openrouter | In: text, image, video, file, audio; Out: text | streaming, function_calling, structured_output | 1048576 | 65536 | In: $0.75, Out: $4.50, Cache Read: $0.08 | | google/gemini-3.5-flash-lite:batch | openrouter | In: text, image, video, file, audio; Out: text | streaming, function_calling, structured_output | 1048576 | 65536 | In: $0.15, Out: $1.25, Cache Read: $0.02 | | google/gemini-3.6-flash:batch | openrouter | In: text, image, video, file, audio; Out: text | streaming, function_calling, structured_output | 1048576 | 65536 | In: $0.75, Out: $3.75, Cache Read: $0.08 | | ibm-granite/granite-4.0-h-micro | openrouter | In: text; Out: text | streaming, predicted_outputs | 131000 | 131000 | In: $0.02, Out: $0.11 | | ibm-granite/granite-4.1-8b | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 131072 | 131072 | In: $0.05, Out: $0.10, Cache Read: $0.05 | | x-ai/grok-4.20 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 2000000 | 2000000 | In: $1.25, Out: $2.50, Cache Read: $0.20 | | x-ai/grok-4.20-multi-agent | openrouter | In: text, image, pdf; Out: text | structured_output, reasoning, vision, streaming | 2000000 | 2000000 | In: $1.25, Out: $2.50, Cache Read: $0.20 | | x-ai/grok-4.3 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 1000000 | In: $1.25, Out: $2.50, Cache Read: $0.20 | | x-ai/grok-4.5 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 500000 | 500000 | In: $2.00, Out: $6.00, Cache Read: $0.30 | | x-ai/grok-build-0.1 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 256000 | 256000 | In: $1.00, Out: $2.00, Cache Read: $0.20 | | ~x-ai/grok-latest | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 500000 | 1000000 | In: $2.00, Out: $6.00, Cache Read: $0.30 | | nousresearch/hermes-3-llama-3.1-405b | openrouter | In: text; Out: text | structured_output, streaming, predicted_outputs | 131072 | 16384 | In: $1.00, Out: $1.00 | | nousresearch/hermes-3-llama-3.1-70b | openrouter | In: text; Out: text | structured_output, streaming, predicted_outputs | 131072 | 16384 | In: $0.70, Out: $0.70 | | nousresearch/hermes-4-405b | openrouter | In: text; Out: text | reasoning, streaming | 131072 | 131072 | In: $1.00, Out: $3.00 | | nousresearch/hermes-4-70b | openrouter | In: text; Out: text | reasoning, streaming | 131072 | 131072 | In: $0.13, Out: $0.40 | | tencent/hunyuan-a13b-instruct | openrouter | In: text; Out: text | structured_output, reasoning, streaming | 131072 | 131072 | In: $0.14, Out: $0.57 | | tencent/hy3 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 262144 | 128000 | In: $0.13, Out: $0.53, Cache Read: $0.03 | | tencent/hy3-preview | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 262144 | 262144 | In: $0.06, Out: $0.21, Cache Read: $0.02 | | thinkingmachines/inkling | openrouter | In: text, image, audio; Out: text | function_calling, reasoning, vision, streaming, predicted_outputs | 1048576 | 1048576 | In: $1.00, Out: $4.05, Cache Read: $0.17 | | thinkingmachines/inkling-small | openrouter | In: text, image, audio; Out: text | function_calling, reasoning, vision, streaming, predicted_outputs | 524288 | 262144 | In: $0.45, Out: $1.20, Cache Read: $0.10 | | ai21/jamba-large-1.7 | openrouter | In: text; Out: text | function_calling, streaming | 256000 | 4096 | In: $2.00, Out: $8.00 | | kwaipilot/kat-coder-air-v2.5 | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 256000 | 80000 | In: $0.15, Out: $0.60, Cache Read: $0.03 | | kwaipilot/kat-coder-pro-v2 | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 262144 | 80000 | In: $0.30, Out: $1.20, Cache Read: $0.06 | | kwaipilot/kat-coder-pro-v2.5 | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 256000 | 80000 | In: $0.74, Out: $2.96, Cache Read: $0.15 | | moonshotai/kimi-k2 | openrouter | In: text; Out: text | function_calling, streaming | 131072 | 100352 | In: $0.57, Out: $2.30 | | moonshotai/kimi-k2-0905 | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 262144 | 100352 | In: $0.60, Out: $2.50 | | moonshotai/kimi-k2-thinking | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 262144 | 100352 | In: $0.60, Out: $2.50, Cache Read: $0.15 | | moonshotai/kimi-k2.5 | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming, predicted_outputs | 262144 | 262144 | In: $0.57, Out: $2.85, Cache Read: $0.10 | | moonshotai/kimi-k2.6 | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming, predicted_outputs | 262144 | 262144 | In: $0.58, Out: $2.44, Cache Read: $0.10 | | moonshotai/kimi-k2.7-code | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming, predicted_outputs | 262144 | 262144 | In: $0.70, Out: $3.50, Cache Read: $0.15 | | moonshotai/kimi-k3 | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming, predicted_outputs | 1048576 | 1048576 | In: $3.00, Out: $15.00, Cache Read: $0.30 | | poolside/laguna-s-2.1 | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 1048576 | 131072 | In: $0.09, Out: $0.18, Cache Read: $0.01 | | poolside/laguna-s-2.1:free | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 262144 | 32768 | In: $0.00, Out: $0.00 | | poolside/laguna-xs-2.1 | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 262144 | 32768 | In: $0.06, Out: $0.12, Cache Read: $0.03 | | poolside/laguna-xs-2.1:free | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 262144 | 32768 | In: $0.00, Out: $0.00 | | inclusionai/ling-3.0-tiny:free | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 262144 | 32768 | In: $0.00, Out: $0.00 | | inclusionai/ling-2.6-1t | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 262144 | 32768 | In: $0.08, Out: $0.62, Cache Read: $0.02 | | inclusionai/ling-2.6-flash | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 262144 | 32768 | In: $0.01, Out: $0.03, Cache Read: $0.00 | | inclusionai/ling-3.0-flash | openrouter | In: text; Out: text | function_calling, reasoning, streaming, predicted_outputs | 262144 | 32768 | In: $0.02, Out: $0.06, Cache Read: $0.00 | | sao10k/l3-lunaris-8b | openrouter | In: text; Out: text | structured_output, streaming, predicted_outputs | 8192 | 16384 | In: $0.04, Out: $0.05 | | meta-llama/llama-3.1-70b-instruct | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 131072 | 16384 | In: $0.40, Out: $0.40 | | meta-llama/llama-3.1-8b-instruct | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 131072 | 131072 | In: $0.05, Out: $0.08, Cache Read: $0.02 | | sao10k/l3.1-euryale-70b | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 131072 | 16384 | In: $0.85, Out: $0.85 | | meta-llama/llama-3.2-1b-instruct | openrouter | In: text; Out: text | streaming, predicted_outputs | 60000 | 60000 | In: $0.03, Out: $0.20 | | meta-llama/llama-3.2-3b-instruct | openrouter | In: text; Out: text | structured_output, streaming, predicted_outputs | 131072 | 131072 | In: $0.05, Out: $0.33 | | sao10k/l3.3-euryale-70b | openrouter | In: text; Out: text | structured_output, streaming | 131072 | 16384 | In: $0.65, Out: $0.75 | | meta-llama/llama-4-maverick | openrouter | In: text, image; Out: text | function_calling, structured_output, vision, streaming, predicted_outputs | 1048576 | 16384 | In: $0.20, Out: $0.80 | | meta-llama/llama-4-scout | openrouter | In: text, image; Out: text | function_calling, structured_output, vision, streaming, predicted_outputs | 1310720 | 16384 | In: $0.10, Out: $0.30 | | meta-llama/llama-guard-4-12b | openrouter | In: image, text; Out: text | vision, streaming, predicted_outputs | 1048576 | 16384 | In: $0.18, Out: $0.18 | | meta-llama/llama-3.3-70b-instruct | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 131072 | 16384 | In: $0.10, Out: $0.32 | | meituan/longcat-2.0 | openrouter | In: text; Out: text | function_calling, reasoning, streaming, predicted_outputs | 1048756 | 262144 | In: $0.30, Out: $1.20, Cache Read: $0.01 | | google/lyria-3-clip-preview | openrouter | In: text, image; Out: text, audio | vision, streaming | 1048576 | 65536 | In: $0.00, Out: $0.00 | | google/lyria-3-pro-preview | openrouter | In: text, image; Out: text, audio | vision, streaming | 1048576 | 65536 | In: $0.00, Out: $0.00 | | anthracite-org/magnum-v4-72b | openrouter | In: text; Out: text | structured_output, streaming, predicted_outputs | 16384 | 2048 | In: $3.00, Out: $5.00 | | inception/mercury-2 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 128000 | 50000 | In: $0.25, Out: $0.75, Cache Read: $0.02 | | xiaomi/mimo-v2.5 | openrouter | In: text, image, audio, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 1050000 | 131072 | In: $0.14, Out: $0.28, Cache Read: $0.00 | | xiaomi/mimo-v2.5-pro | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 1050000 | 131072 | In: $0.44, Out: $0.87, Cache Read: $0.00 | | minimax/minimax-m1 | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 1000000 | 40000 | In: $0.55, Out: $2.20 | | minimax/minimax-m2-her | openrouter | In: text; Out: text | streaming | 65536 | 2048 | In: $0.30, Out: $1.20, Cache Read: $0.03 | | minimax/minimax-01 | openrouter | In: text, image; Out: text | vision, streaming | 1000192 | 1000192 | In: $0.20, Out: $1.10 | | minimax/minimax-m2 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 204800 | 131072 | In: $0.26, Out: $1.02 | | minimax/minimax-m2.1 | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 204800 | 131072 | In: $0.30, Out: $1.20, Cache Read: $0.03 | | minimax/minimax-m2.5 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 204800 | 196608 | In: $0.22, Out: $0.90, Cache Read: $0.05 | | minimax/minimax-m2.7 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 204800 | 131072 | In: $0.27, Out: $1.08, Cache Read: $0.05 | | minimax/minimax-m3 | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 1048576 | 512000 | In: $0.30, Out: $1.20, Cache Read: $0.06 | | minimax/minimax-m3:batch | openrouter | In: text, image, video; Out: text | streaming, function_calling, structured_output, predicted_outputs | 524288 | - | In: $0.15, Out: $0.60, Cache Read: $0.03 | | mistralai/ministral-14b-2512 | openrouter | In: text, image; Out: text | function_calling, structured_output, vision, streaming | 262144 | 262144 | In: $0.20, Out: $0.20, Cache Read: $0.02 | | mistralai/ministral-3b-2512 | openrouter | In: text, image; Out: text | function_calling, structured_output, vision, streaming | 131072 | 131072 | In: $0.10, Out: $0.10, Cache Read: $0.01 | | mistralai/ministral-8b-2512 | openrouter | In: text, image; Out: text | function_calling, structured_output, vision, streaming | 262144 | 262144 | In: $0.15, Out: $0.15, Cache Read: $0.02 | | mistralai/mistral-large | openrouter | In: text, pdf; Out: text | function_calling, structured_output, vision, streaming | 128000 | 128000 | In: $2.00, Out: $6.00, Cache Read: $0.20 | | mistralai/mistral-large-2407 | openrouter | In: text, pdf; Out: text | function_calling, structured_output, vision, streaming | 131072 | 131072 | In: $2.00, Out: $6.00, Cache Read: $0.20 | | mistralai/mistral-large-2512 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 262144 | 262144 | In: $0.50, Out: $1.50, Cache Read: $0.05 | | mistralai/mistral-medium-3 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 131072 | 131072 | In: $0.40, Out: $2.00, Cache Read: $0.04 | | mistralai/mistral-medium-3.1 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 131072 | 262144 | In: $0.40, Out: $2.00, Cache Read: $0.04 | | mistralai/mistral-medium-3-5 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 262144 | 262144 | In: $1.50, Out: $7.50 | | mistralai/mistral-nemo | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 131072 | 16384 | In: $0.02, Out: $0.03 | | mistralai/mistral-small-24b-instruct-2501 | openrouter | In: text; Out: text | structured_output, streaming, predicted_outputs | 32768 | 16384 | In: $0.05, Out: $0.08 | | mistralai/mistral-small-3.1-24b-instruct | openrouter | In: text, image; Out: text | vision, streaming, predicted_outputs | 128000 | 128000 | In: $0.35, Out: $0.56 | | mistralai/mistral-small-3.2-24b-instruct | openrouter | In: image, text; Out: text | function_calling, structured_output, vision, streaming, predicted_outputs | 256000 | 16384 | In: $0.09, Out: $0.25 | | mistralai/mistral-small-2603 | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 262144 | 262144 | In: $0.15, Out: $0.60, Cache Read: $0.02 | | mistralai/mixtral-8x22b-instruct | openrouter | In: text, pdf; Out: text | function_calling, structured_output, vision, streaming | 65536 | 65536 | In: $2.00, Out: $6.00, Cache Read: $0.20 | | ~moonshotai/kimi-latest | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming, predicted_outputs | 1048576 | 1048576 | In: $2.50, Out: $14.00, Cache Read: $0.29 | | moonshotai/kimi-k2.7-code:batch | openrouter | In: text, image; Out: text | streaming, function_calling, structured_output, predicted_outputs | 262144 | - | In: $0.48, Out: $2.00, Cache Read: $0.10 | | morph/morph-v3-fast | openrouter | In: text; Out: text | streaming | 81920 | 38000 | In: $0.80, Out: $1.20 | | morph/morph-v3-large | openrouter | In: text; Out: text | structured_output, streaming | 262144 | 131072 | In: $0.90, Out: $1.90 | | meta/muse-spark-1.1 | openrouter | In: text, image, video, pdf, audio; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 1048576 | In: $1.25, Out: $4.25, Cache Read: $0.15 | | meta/muse-spark-1.2 | openrouter | In: text, image, video, pdf, audio; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 1048576 | In: $1.25, Out: $4.25, Cache Read: $0.15 | | gryphe/mythomax-l2-13b | openrouter | In: text; Out: text | structured_output, streaming, predicted_outputs | 8192 | 4096 | In: $0.08, Out: $0.11 | | nvidia/nemotron-3-ultra-550b-a55b:batch | openrouter | In: text; Out: text | streaming, function_calling, structured_output, predicted_outputs | 512288 | - | In: $0.30, Out: $1.80, Cache Read: $0.10 | | google/gemini-2.5-flash-image | openrouter | In: text, image; Out: text, image | structured_output, vision, streaming | 32768 | 8192 | In: $0.30, Out: $2.50, Cache Read: $0.03, Cache Write: $0.08 | | google/gemini-3.1-flash-image | openrouter | In: text, image; Out: text, image | structured_output, reasoning, vision, streaming | 131072 | 32768 | In: $0.50, Out: $3.00 | | google/gemini-3.1-flash-image-preview | openrouter | In: image, text; Out: text, image | structured_output, reasoning, vision, streaming | 65536 | 65536 | In: $0.50, Out: $3.00 | | google/gemini-3.1-flash-lite-image | openrouter | In: text, image; Out: text, image | reasoning, vision, streaming | 65536 | 65536 | In: $0.25, Out: $1.50 | | google/gemini-3-pro-image | openrouter | In: text, image; Out: text, image | function_calling, structured_output, reasoning, vision, streaming | 131072 | 32768 | In: $2.00, Out: $12.00, Cache Read: $0.20, Cache Write: $0.38 | | google/gemini-3-pro-image-preview | openrouter | In: text, image; Out: text, image | structured_output, reasoning, vision, streaming | 65536 | 32768 | In: $2.00, Out: $12.00, Cache Read: $0.20, Cache Write: $0.38 | | nvidia/nemotron-3-nano-30b-a3b | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 262144 | 262144 | In: $0.05, Out: $0.20, Cache Read: $0.03 | | nvidia/nemotron-3-nano-30b-a3b:free | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 256000 | 256000 | In: $0.00, Out: $0.00 | | nvidia/nemotron-3-nano-omni-30b-a3b-reasoning:free | openrouter | In: text, image, video, audio; Out: text | function_calling, reasoning, vision, video, streaming | 256000 | 65536 | In: $0.00, Out: $0.00 | | nvidia/nemotron-3-super-120b-a12b:free | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 262144 | 262144 | In: $0.00, Out: $0.00 | | nvidia/nemotron-3-super-120b-a12b | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 1000000 | 16384 | In: $0.08, Out: $0.40 | | nvidia/nemotron-3-ultra-550b-a55b:free | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 1000000 | 65536 | In: $0.00, Out: $0.00 | | nvidia/nemotron-3-ultra-550b-a55b | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 512288 | 16384 | In: $0.60, Out: $3.60, Cache Read: $0.20 | | nvidia/nemotron-3.5-content-safety:free | openrouter | In: text, image; Out: text | reasoning, vision, streaming | 128000 | 8192 | In: $0.00, Out: $0.00 | | nvidia/nemotron-nano-12b-v2-vl:free | openrouter | In: text, image, video; Out: text | function_calling, reasoning, vision, video, streaming | 128000 | 128000 | In: $0.00, Out: $0.00 | | nvidia/nemotron-nano-9b-v2:free | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 128000 | 128000 | In: $0.00, Out: $0.00 | | nex-agi/nex-n2-mini | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 262144 | 262144 | In: $0.02, Out: $0.10, Cache Read: $0.00 | | nex-agi/nex-n2-pro | openrouter | In: text, image; Out: text | function_calling, reasoning, vision, streaming | 262144 | 262144 | In: $0.25, Out: $1.00, Cache Read: $0.02 | | cohere/north-mini-code:free | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 256000 | 64000 | In: $0.00, Out: $0.00 | | amazon/nova-2-lite-v1 | openrouter | In: text, image, video, pdf; Out: text | function_calling, reasoning, vision, video, streaming | 1000000 | 65535 | In: $0.30, Out: $2.50 | | amazon/nova-lite-v1 | openrouter | In: text, image; Out: text | function_calling, vision, streaming | 300000 | 5120 | In: $0.06, Out: $0.24 | | amazon/nova-micro-v1 | openrouter | In: text; Out: text | function_calling, streaming | 128000 | 5120 | In: $0.04, Out: $0.14 | | amazon/nova-premier-v1 | openrouter | In: text, image; Out: text | function_calling, vision, streaming | 1000000 | 32000 | In: $2.50, Out: $12.50, Cache Read: $0.62 | | amazon/nova-pro-v1 | openrouter | In: text, image; Out: text | function_calling, vision, streaming | 300000 | 5120 | In: $0.80, Out: $3.20 | | allenai/olmo-3-32b-think | openrouter | In: text; Out: text | structured_output, reasoning, streaming, predicted_outputs | 65536 | 65536 | In: $0.15, Out: $0.50 | | ~openai/gpt-latest | openrouter | In: pdf, image, text; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $5.00, Out: $30.00, Cache Read: $0.50, Cache Write: $6.25 | | ~openai/gpt-mini-latest | openrouter | In: pdf, image, text; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $0.75, Out: $4.50, Cache Read: $0.08 | | openai/gpt-3.5-turbo:batch | openrouter | In: text; Out: text | streaming, function_calling, structured_output | 16385 | 4096 | In: $0.25, Out: $0.75 | | openai/gpt-4-turbo:batch | openrouter | In: text, image; Out: text | streaming, function_calling, structured_output | 128000 | 4096 | In: $5.00, Out: $15.00 | | openai/gpt-4.1:batch | openrouter | In: image, text, file; Out: text | streaming, function_calling, structured_output | 1047576 | 32768 | In: $1.00, Out: $4.00, Cache Read: $0.25 | | openai/gpt-4.1-mini:batch | openrouter | In: image, text, file; Out: text | streaming, function_calling, structured_output | 1047576 | 32768 | In: $0.20, Out: $0.80, Cache Read: $0.05 | | openai/gpt-4.1-nano:batch | openrouter | In: image, text, file; Out: text | streaming, function_calling, structured_output | 1047576 | 32768 | In: $0.05, Out: $0.20, Cache Read: $0.01 | | openai/gpt-4o:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 128000 | 16384 | In: $1.25, Out: $5.00, Cache Read: $0.62 | | openai/gpt-4o-mini:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 128000 | 16384 | In: $0.08, Out: $0.30, Cache Read: $0.04 | | openai/gpt-5:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 400000 | 128000 | In: $0.62, Out: $5.00, Cache Read: $0.06 | | openai/gpt-5-codex:batch | openrouter | In: text, image; Out: text | streaming, function_calling, structured_output | 400000 | 128000 | In: $0.62, Out: $5.00, Cache Read: $0.06 | | openai/gpt-5-mini:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 400000 | 128000 | In: $0.12, Out: $1.00, Cache Read: $0.01 | | openai/gpt-5-nano:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 400000 | 128000 | In: $0.02, Out: $0.20, Cache Read: $0.00 | | openai/gpt-5-pro:batch | openrouter | In: image, text, file; Out: text | streaming, function_calling, structured_output | 400000 | 128000 | In: $7.50, Out: $60.00 | | openai/gpt-5.1:batch | openrouter | In: image, text, file; Out: text | streaming, function_calling, structured_output | 400000 | 128000 | In: $0.62, Out: $5.00, Cache Read: $0.06 | | openai/gpt-5.2:batch | openrouter | In: file, image, text; Out: text | streaming, function_calling, structured_output | 400000 | 128000 | In: $0.88, Out: $7.00, Cache Read: $0.09 | | openai/gpt-5.2-pro:batch | openrouter | In: image, text, file; Out: text | streaming, function_calling, structured_output | 400000 | 128000 | In: $10.50, Out: $84.00 | | openai/gpt-5.4:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 1050000 | 128000 | In: $1.25, Out: $7.50, Cache Read: $0.12 | | openai/gpt-5.4-mini:batch | openrouter | In: file, image, text; Out: text | streaming, function_calling, structured_output | 400000 | 128000 | In: $0.38, Out: $2.25, Cache Read: $0.04 | | openai/gpt-5.4-nano:batch | openrouter | In: file, image, text; Out: text | streaming, function_calling, structured_output | 400000 | 128000 | In: $0.10, Out: $0.62, Cache Read: $0.01 | | openai/gpt-5.4-pro:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 1050000 | 128000 | In: $15.00, Out: $90.00 | | openai/gpt-5.5:batch | openrouter | In: file, image, text; Out: text | streaming, function_calling, structured_output | 1050000 | 128000 | In: $2.50, Out: $15.00, Cache Read: $0.25 | | openai/gpt-5.5-pro:batch | openrouter | In: file, image, text; Out: text | streaming, function_calling, structured_output | 1050000 | 128000 | In: $15.00, Out: $90.00 | | openai/gpt-5.6-luna:batch | openrouter | In: file, image, text; Out: text | streaming, function_calling, structured_output | 1050000 | 128000 | In: $0.10, Out: $0.60, Cache Read: $0.01 | | openai/gpt-5.6-luna-pro:batch | openrouter | In: file, image, text; Out: text | streaming, function_calling, structured_output | 1050000 | 128000 | In: $0.10, Out: $0.60, Cache Read: $0.01 | | openai/gpt-5.6-sol:batch | openrouter | In: file, image, text; Out: text | streaming, function_calling, structured_output | 1050000 | 128000 | In: $2.50, Out: $15.00, Cache Read: $0.25 | | openai/gpt-5.6-sol-pro:batch | openrouter | In: file, image, text; Out: text | streaming, function_calling, structured_output | 1050000 | 128000 | In: $2.50, Out: $15.00, Cache Read: $0.25 | | openai/gpt-5.6-terra:batch | openrouter | In: file, image, text; Out: text | streaming, function_calling, structured_output | 1050000 | 128000 | In: $1.00, Out: $6.00, Cache Read: $0.10 | | openai/gpt-5.6-terra-pro:batch | openrouter | In: file, image, text; Out: text | streaming, function_calling, structured_output | 1050000 | 128000 | In: $1.00, Out: $6.00, Cache Read: $0.10 | | openai/o1:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 200000 | 100000 | In: $7.50, Out: $30.00, Cache Read: $3.75 | | openai/o1-pro:batch | openrouter | In: text, image, file; Out: text | streaming, structured_output | 200000 | 100000 | In: $75.00, Out: $300.00 | | openai/o3:batch | openrouter | In: image, text, file; Out: text | streaming, function_calling, structured_output | 200000 | 100000 | In: $1.00, Out: $4.00, Cache Read: $0.25 | | openai/o3-mini:batch | openrouter | In: text, file; Out: text | streaming, function_calling, structured_output | 200000 | 100000 | In: $0.55, Out: $2.20, Cache Read: $0.28 | | openai/o3-mini-high:batch | openrouter | In: text, file; Out: text | streaming, function_calling, structured_output | 200000 | 100000 | In: $0.55, Out: $2.20, Cache Read: $0.28 | | openai/o3-pro:batch | openrouter | In: text, file, image; Out: text | streaming, function_calling, structured_output | 200000 | 100000 | In: $10.00, Out: $40.00 | | openai/o4-mini:batch | openrouter | In: image, text, file; Out: text | streaming, function_calling, structured_output | 200000 | 100000 | In: $0.55, Out: $2.20, Cache Read: $0.14 | | openai/o4-mini-high:batch | openrouter | In: image, text, file; Out: text | streaming, function_calling, structured_output | 200000 | 100000 | In: $0.55, Out: $2.20, Cache Read: $0.14 | | writer/palmyra-x5 | openrouter | In: text; Out: text | streaming | 1040000 | 8192 | In: $0.60, Out: $6.00 | | openrouter/pareto-code | openrouter | In: text; Out: text | streaming | 2000000 | 200000 | - | | perceptron/perceptron-mk1 | openrouter | In: text, image, video; Out: text | structured_output, reasoning, vision, video, streaming | 32768 | 8192 | In: $0.15, Out: $1.50 | | microsoft/phi-4 | openrouter | In: text; Out: text | structured_output, streaming, predicted_outputs | 16384 | 16384 | In: $0.07, Out: $0.14 | | qwen/qwen-plus | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 1000000 | 32768 | In: $0.26, Out: $0.78, Cache Read: $0.05, Cache Write: $0.32 | | qwen/qwen-plus-2025-07-28 | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 1000000 | 32768 | In: $0.26, Out: $0.78 | | qwen/qwen-plus-2025-07-28:thinking | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 1000000 | 32768 | In: $0.40, Out: $1.20, Cache Write: $0.50 | | qwen/qwen-2.5-72b-instruct | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 32768 | 16384 | In: $0.36, Out: $0.40 | | qwen/qwen-2.5-7b-instruct | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 32768 | 32768 | In: $0.10, Out: $0.20 | | qwen/qwen-2.5-coder-32b-instruct | openrouter | In: text; Out: text | streaming, predicted_outputs | 32768 | 32768 | In: $0.66, Out: $1.00 | | qwen/qwen2.5-vl-72b-instruct | openrouter | In: text, image; Out: text | structured_output, vision, streaming, predicted_outputs | 128000 | 128000 | In: $0.25, Out: $0.75 | | qwen/qwen3-14b | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 131072 | 8192 | In: $0.23, Out: $0.91 | | qwen/qwen3-235b-a22b-2507 | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 262144 | 16384 | In: $0.09, Out: $0.55 | | qwen/qwen3-235b-a22b-thinking-2507 | openrouter | In: text; Out: text | function_calling, reasoning, streaming, predicted_outputs | 262144 | 32768 | In: $0.23, Out: $2.30 | | qwen/qwen3-235b-a22b | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 131072 | 8192 | In: $0.46, Out: $1.82 | | qwen/qwen3-30b-a3b | openrouter | In: text; Out: text | function_calling, reasoning, streaming, predicted_outputs | 131072 | 16384 | In: $0.12, Out: $0.50 | | qwen/qwen3-30b-a3b-instruct-2507 | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 262144 | 32000 | In: $0.05, Out: $0.19 | | qwen/qwen3-30b-a3b-thinking-2507 | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 81920 | 32768 | In: $0.20, Out: $2.40 | | qwen/qwen3-32b | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 131072 | 16384 | In: $0.08, Out: $0.28 | | qwen/qwen3-8b | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 131072 | 8192 | In: $0.12, Out: $0.46 | | qwen/qwen3-coder | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 262144 | 65536 | In: $0.30, Out: $1.00, Cache Read: $0.10 | | qwen/qwen3-coder-flash | openrouter | In: text; Out: text | function_calling, streaming | 1000000 | 65536 | In: $0.20, Out: $0.98, Cache Read: $0.04, Cache Write: $0.24 | | qwen/qwen3-coder-next | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 262144 | 262144 | In: $0.12, Out: $0.80, Cache Read: $0.07 | | qwen/qwen3-coder-plus | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 1000000 | 65536 | In: $0.65, Out: $3.25, Cache Read: $0.13, Cache Write: $0.81 | | qwen/qwen3-max | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 262144 | 65536 | In: $0.78, Out: $3.90, Cache Read: $0.16, Cache Write: $0.98 | | qwen/qwen3-max-thinking | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 262144 | 65536 | In: $0.78, Out: $3.90 | | qwen/qwen3-vl-235b-a22b-instruct | openrouter | In: text, image; Out: text | function_calling, structured_output, vision, streaming, predicted_outputs | 262144 | 32768 | In: $0.21, Out: $1.90, Cache Read: $0.10 | | qwen/qwen3-vl-235b-a22b-thinking | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 131072 | 32768 | In: $0.40, Out: $4.00 | | qwen/qwen3-vl-30b-a3b-instruct | openrouter | In: text, image; Out: text | function_calling, structured_output, vision, streaming, predicted_outputs | 262144 | 16384 | In: $0.15, Out: $0.60 | | qwen/qwen3-vl-30b-a3b-thinking | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 262144 | 32768 | In: $0.20, Out: $2.40 | | qwen/qwen3-vl-32b-instruct | openrouter | In: text, image; Out: text | function_calling, structured_output, vision, streaming | 131072 | 32768 | In: $0.10, Out: $0.42 | | qwen/qwen3-vl-8b-instruct | openrouter | In: image, text; Out: text | function_calling, structured_output, vision, streaming, predicted_outputs | 262144 | 32768 | In: $0.12, Out: $0.46 | | qwen/qwen3-vl-8b-thinking | openrouter | In: image, text; Out: text | function_calling, structured_output, reasoning, vision, streaming | 131072 | 32768 | In: $0.18, Out: $2.10 | | qwen/qwen3-coder-30b-a3b-instruct | openrouter | In: text; Out: text | function_calling, structured_output, streaming | 262144 | 32768 | In: $0.07, Out: $0.27 | | qwen/qwen3-next-80b-a3b-thinking | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 262144 | 262144 | In: $0.15, Out: $1.20 | | qwen/qwen3-next-80b-a3b-instruct | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 262144 | 16384 | In: $0.09, Out: $1.10 | | qwen/qwen3.5-122b-a10b | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 262144 | 81920 | In: $0.29, Out: $2.40 | | qwen/qwen3.5-27b | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 262144 | 65536 | In: $0.20, Out: $1.56 | | qwen/qwen3.5-35b-a3b | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 262144 | 262144 | In: $0.14, Out: $1.00 | | qwen/qwen3.5-397b-a17b | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 262144 | 65536 | In: $0.39, Out: $2.34 | | qwen/qwen3.5-9b | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 262144 | 262144 | In: $0.10, Out: $0.15 | | qwen/qwen3.5-plus-02-15 | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1000000 | 65536 | In: $0.26, Out: $1.56 | | qwen/qwen3.5-plus-20260420 | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1000000 | 65536 | In: $0.30, Out: $1.80, Cache Write: $0.38 | | qwen/qwen3.5-flash-02-23 | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1000000 | 65536 | In: $0.06, Out: $0.26 | | qwen/qwen3.6-27b | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 262144 | 262144 | In: $0.60, Out: $3.60, Cache Read: $0.12 | | qwen/qwen3.6-35b-a3b | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 262144 | 262144 | In: $0.14, Out: $1.00, Cache Read: $0.05 | | qwen/qwen3.6-flash | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1000000 | 65536 | In: $0.19, Out: $1.12, Cache Write: $0.23 | | qwen/qwen3.6-max-preview | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 262144 | 65536 | In: $1.03, Out: $6.16, Cache Write: $1.28 | | qwen/qwen3.6-plus | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1000000 | 65536 | In: $0.32, Out: $1.95, Cache Write: $0.41 | | qwen/qwen3.7-flash | openrouter | In: text, image, video; Out: text | function_calling, reasoning, vision, video, streaming | 1000000 | 65536 | In: $0.03, Out: $0.13, Cache Read: $0.01, Cache Write: $0.04 | | qwen/qwen3.7-max | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 1000000 | 131072 | In: $1.48, Out: $4.42, Cache Read: $0.30, Cache Write: $1.84 | | qwen/qwen3.7-plus | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 131072 | In: $0.32, Out: $1.28, Cache Read: $0.06, Cache Write: $0.40 | | qwen/qwen3.8-max | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1000000 | 131072 | In: $2.00, Out: $6.00, Cache Read: $0.25, Cache Write: $2.50 | | deepseek/deepseek-r1-0528 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 163840 | 32768 | In: $0.50, Out: $2.15, Cache Read: $0.35 | | deepseek/deepseek-r1-distill-llama-70b | openrouter | In: text; Out: text | reasoning, streaming | 8192 | 8192 | In: $0.80, Out: $0.80 | | undi95/remm-slerp-l2-13b | openrouter | In: text; Out: text | structured_output, streaming, predicted_outputs | 6144 | 6144 | In: $0.45, Out: $0.65 | | rekaai/reka-edge | openrouter | In: image, text, video; Out: text | function_calling, structured_output, vision, video, streaming | 16384 | 16384 | In: $0.10, Out: $0.10 | | rekaai/reka-flash-3 | openrouter | In: text; Out: text | structured_output, reasoning, streaming | 65536 | 65536 | In: $0.10, Out: $0.20 | | relace/relace-apply-3 | openrouter | In: text; Out: text | streaming | 256000 | 128000 | In: $0.85, Out: $1.25 | | relace/relace-search | openrouter | In: text; Out: text | function_calling, streaming | 256000 | 128000 | In: $1.00, Out: $3.00 | | inclusionai/ring-2.6-1t | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 262144 | 65536 | In: $0.08, Out: $0.62, Cache Read: $0.02 | | thedrummer/rocinante-12b | openrouter | In: text; Out: text | structured_output, streaming, predicted_outputs | 65536 | 65536 | In: $0.25, Out: $0.50 | | mistralai/mistral-saba | openrouter | In: text, pdf; Out: text | function_calling, structured_output, vision, streaming | 32768 | 32768 | In: $0.20, Out: $0.60, Cache Read: $0.02 | | bytedance-seed/seed-1.6 | openrouter | In: image, text, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 262144 | 32768 | In: $0.25, Out: $2.00 | | bytedance-seed/seed-1.6-flash | openrouter | In: image, text, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 262144 | 32768 | In: $0.08, Out: $0.30 | | bytedance-seed/seed-2.0-lite | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 262144 | 131072 | In: $0.25, Out: $2.00 | | bytedance-seed/seed-2.0-mini | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 262144 | 131072 | In: $0.10, Out: $0.40 | | thedrummer/skyfall-36b-v2 | openrouter | In: text; Out: text | structured_output, streaming, predicted_outputs | 32768 | 32768 | In: $0.55, Out: $0.80, Cache Read: $0.25 | | upstage/solar-pro-3 | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 131072 | 131072 | In: $0.15, Out: $0.60, Cache Read: $0.02 | | perplexity/sonar | openrouter | In: text, image; Out: text | vision, streaming | 127072 | 127072 | In: $1.00, Out: $1.00 | | perplexity/sonar-deep-research | openrouter | In: text; Out: text | reasoning, streaming | 128000 | 128000 | In: $2.00, Out: $8.00 | | perplexity/sonar-pro | openrouter | In: text, image; Out: text | vision, streaming | 200000 | 8000 | In: $3.00, Out: $15.00 | | perplexity/sonar-pro-search | openrouter | In: text, image; Out: text | structured_output, reasoning, vision, streaming | 200000 | 8000 | In: $3.00, Out: $15.00 | | perplexity/sonar-reasoning-pro | openrouter | In: text, image; Out: text | reasoning, vision, streaming | 128000 | 128000 | In: $2.00, Out: $8.00 | | stepfun/step-3.5-flash | openrouter | In: text; Out: text | function_calling, reasoning, streaming | 262144 | 65536 | In: $0.10, Out: $0.30 | | stepfun/step-3.7-flash | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 262144 | 256000 | In: $0.20, Out: $1.15, Cache Read: $0.04 | | thinkingmachines/inkling:batch | openrouter | In: text, image, audio; Out: text | streaming, function_calling, predicted_outputs | 524288 | - | In: $0.50, Out: $2.02, Cache Read: $0.08 | | arcee-ai/trinity-large-thinking | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming, predicted_outputs | 262144 | 262144 | In: $0.22, Out: $0.85, Cache Read: $0.06 | | bytedance/ui-tars-1.5-7b | openrouter | In: image, text; Out: text | structured_output, vision, streaming, predicted_outputs | 128000 | 2048 | In: $0.10, Out: $0.20, Cache Read: $0.10 | | cognitivecomputations/dolphin-mistral-24b-venice-edition | openrouter | In: text; Out: text | streaming | 128000 | 8192 | In: $0.20, Out: $0.90 | | thedrummer/unslopnemo-12b | openrouter | In: text; Out: text | function_calling, structured_output, streaming, predicted_outputs | 1024000 | 1024000 | In: $0.40, Out: $0.40 | | arcee-ai/virtuoso-large | openrouter | In: text; Out: text | function_calling, streaming, predicted_outputs | 131072 | 64000 | In: $0.75, Out: $1.20 | | mistralai/voxtral-small-24b-2507 | openrouter | In: text, audio, pdf; Out: text | function_calling, structured_output, vision, streaming | 32000 | 32000 | In: $0.10, Out: $0.30, Cache Read: $0.01 | | mancer/weaver | openrouter | In: text; Out: text | structured_output, streaming, predicted_outputs | 8000 | 6000 | In: $0.50, Out: $0.75 | | microsoft/wizardlm-2-8x22b | openrouter | In: text; Out: text | streaming | 65535 | 8000 | In: $0.62, Out: $0.62 | | z-ai/glm-5.2:batch | openrouter | In: text; Out: text | streaming, function_calling, structured_output, predicted_outputs | 512000 | - | In: $0.70, Out: $2.20, Cache Read: $0.13 | | openai/gpt-oss-20b:free | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 131072 | 32768 | In: $0.00, Out: $0.00 | | openai/gpt-oss-safeguard-20b | openrouter | In: text; Out: text | function_calling, structured_output, reasoning, streaming | 131072 | 65536 | In: $0.08, Out: $0.30, Cache Read: $0.04 | | openai/o1 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 100000 | In: $15.00, Out: $60.00, Cache Read: $7.50 | | openai/o1-pro | openrouter | In: text, image, pdf; Out: text | structured_output, reasoning, vision, streaming | 200000 | 100000 | In: $150.00, Out: $600.00 | | openai/o3 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 100000 | In: $2.00, Out: $8.00, Cache Read: $0.50 | | openai/o3-mini-high | openrouter | In: text, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 100000 | In: $1.10, Out: $4.40, Cache Read: $0.55 | | openai/o3-mini | openrouter | In: text, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 100000 | In: $1.10, Out: $4.40, Cache Read: $0.55 | | openai/o3-pro | openrouter | In: text, pdf, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 100000 | In: $20.00, Out: $80.00 | | openai/o4-mini-high | openrouter | In: image, text, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 100000 | In: $1.10, Out: $4.40, Cache Read: $0.28 | | openai/o4-mini | openrouter | In: image, text, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 100000 | In: $1.10, Out: $4.40, Cache Read: $0.28 | | claude-haiku-4-5 | vertexai | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 200000 | 64000 | In: $1.00, Out: $5.00, Cache Read: $0.10, Cache Write: $1.25 | | claude-opus-4-1 | vertexai | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 200000 | 32000 | In: $15.00, Out: $75.00, Cache Read: $1.50, Cache Write: $18.75 | | claude-opus-4-5 | vertexai | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 200000 | 64000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | claude-opus-4-6 | vertexai | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | claude-opus-4-7 | vertexai | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | claude-opus-4-8 | vertexai | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | claude-sonnet-4-5 | vertexai | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 200000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | claude-sonnet-4-6 | vertexai | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 1000000 | 128000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | claude-sonnet-5 | vertexai | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 1000000 | 128000 | In: $2.00, Out: $10.00, Cache Read: $0.20, Cache Write: $2.50 | | gemini-2.0-flash | vertexai | In: text, image, audio, video, pdf; Out: text | function_calling, structured_output, vision, video, streaming | 1048576 | 8192 | In: $0.10, Out: $0.40, Cache Read: $0.02 | | gemini-2.5-flash | vertexai | In: text, image, audio, video, pdf; Out: text | function_calling, reasoning, vision, video, streaming | 1048576 | 65536 | In: $0.30, Out: $2.50, Cache Read: $0.08, Cache Write: $0.38 | | gemini-2.5-flash-tts | vertexai | In: text; Out: audio | streaming | 32768 | 16384 | In: $0.50, Out: $10.00 | | gemini-2.5-flash-lite | vertexai | In: text, image, audio, video, pdf; Out: text | function_calling, reasoning, vision, video, streaming | 1048576 | 65536 | In: $0.10, Out: $0.40, Cache Read: $0.01 | | gemini-2.5-pro | vertexai | In: text, image, audio, video, pdf; Out: text | function_calling, reasoning, vision, video, streaming | 1048576 | 65536 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gemini-2.5-pro-tts | vertexai | In: text; Out: audio | streaming | 32768 | 16384 | In: $1.00, Out: $20.00 | | gemini-3-flash-preview | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $0.50, Out: $3.00, Cache Read: $0.05 | | gemini-3.1-flash-lite | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $0.25, Out: $1.50, Cache Read: $0.02 | | gemini-3.1-flash-lite-preview | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $0.25, Out: $1.50, Cache Read: $0.02 | | gemini-3.1-pro-preview | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $2.00, Out: $12.00, Cache Read: $0.20 | | gemini-3.5-flash | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $1.50, Out: $9.00, Cache Read: $0.15 | | gemini-embedding-001 | vertexai | In: text; Out: embeddings | streaming | 2048 | 1 | In: $0.15, Out: $0.00 | | gemini-embedding-2 | vertexai | In: text, image, audio, video, pdf; Out: embeddings | vision, video, streaming | 8192 | 1 | In: $0.20, Out: $0.00 | | gemini-3.1-flash-image | vertexai | In: text, image, video, pdf; Out: text, image | reasoning, vision, video, streaming | 131072 | 32768 | In: $0.50, Out: $60.00 | | gemini-3.1-flash-image-preview | vertexai | In: text, image, pdf; Out: text, image | reasoning, vision, streaming | 65536 | 65536 | In: $0.50, Out: $60.00 | | gemini-3.1-flash-lite-image | vertexai | In: text, image; Out: text, image | function_calling, reasoning, vision, streaming | 65536 | 65536 | In: $0.25, Out: $30.00 | | gemini-3-pro-image | vertexai | In: text, image; Out: text, image | reasoning, vision, streaming | 65536 | 32768 | In: $2.00, Out: $120.00 | | claude-fable-5 | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | codestral-2 | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | gemini-1.5-flash | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | gemini-1.5-flash-002 | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | gemini-1.5-flash-8b | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | gemini-1.5-pro | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | gemini-1.5-pro-002 | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | gemini-2.0-flash-001 | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | gemini-2.0-flash-exp | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | gemini-2.0-flash-lite-001 | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | gemini-2.5-flash-preview-04-17 | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | gemini-2.5-pro-exp-03-25 | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | gemini-exp-1121 | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | gemini-exp-1206 | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | gemini-live-2.5-flash-native-audio | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | gemini-pro | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | gemini-pro-vision | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | mistral-medium-3 | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | mistral-ocr-2505 | vertexai | In: -; Out: - | streaming | - | - | - | | mistral-small-2503 | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | text-embedding-004 | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | text-embedding-005 | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | text-multilingual-embedding-002 | vertexai | In: -; Out: - | streaming, function_calling | - | - | - | | grok-4.20-0309-non-reasoning | xai | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 1000000 | 30000 | In: $1.25, Out: $2.50, Cache Read: $0.20 | | grok-4.20-0309-reasoning | xai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 30000 | In: $1.25, Out: $2.50, Cache Read: $0.20 | | grok-4.20-multi-agent-0309 | xai | In: text, image, pdf; Out: text | structured_output, reasoning, vision, streaming | 1000000 | 30000 | In: $1.25, Out: $2.50, Cache Read: $0.20 | | grok-4.3 | xai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 30000 | In: $1.25, Out: $2.50, Cache Read: $0.20 | | grok-4.5 | xai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 500000 | 500000 | In: $2.00, Out: $6.00, Cache Read: $0.30 | | grok-build-0.1 | xai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 256000 | 256000 | In: $1.00, Out: $2.00, Cache Read: $0.20 | ### Batch Processing (40) | Model | Provider | I/O | Capabilities | Context | Max Output | Standard Pricing (per 1M tokens) | | :-- | :-- | :-- | :-- | --: | --: | :-- | | codestral-2508 | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, predicted_outputs, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | codestral-latest | mistral | In: text; Out: text | function_calling, streaming, batch, predicted_outputs, tool_choice, parallel_tool_calls | 256000 | 4096 | In: $0.30, Out: $0.90 | | devstral-2512 | mistral | In: text; Out: text | function_calling, streaming, batch, fine_tuning, tool_choice, parallel_tool_calls | 262144 | 262144 | In: $0.40, Out: $2.00 | | devstral-latest | mistral | In: text; Out: text | function_calling, streaming, batch, fine_tuning, tool_choice, parallel_tool_calls | 262144 | 262144 | In: $0.40, Out: $2.00 | | devstral-medium-latest | mistral | In: text; Out: text | function_calling, streaming, batch, fine_tuning, tool_choice, parallel_tool_calls | 262144 | 262144 | In: $0.40, Out: $2.00 | | labs-leanstral-1-5 | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | labs-leanstral-1-5-1 | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | magistral-medium-latest | mistral | In: text; Out: text | function_calling, reasoning, streaming, batch, tool_choice, parallel_tool_calls | 128000 | 16384 | In: $2.00, Out: $5.00 | | magistral-medium-2509 | mistral | In: text; Out: text | streaming, function_calling, structured_output, reasoning, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | magistral-small-2509 | mistral | In: text; Out: text | streaming, function_calling, structured_output, reasoning, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | magistral-small-latest | mistral | In: text; Out: text | streaming, function_calling, structured_output, reasoning, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | ministral-14b-2512 | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, distillation, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | ministral-14b-latest | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, distillation, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | ministral-3b-2512 | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, distillation, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | ministral-3b-latest | mistral | In: text; Out: text | function_calling, streaming, batch, distillation, tool_choice, parallel_tool_calls | 128000 | 128000 | In: $0.04, Out: $0.04 | | ministral-8b-2512 | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, distillation, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | ministral-8b-latest | mistral | In: text; Out: text | function_calling, streaming, batch, distillation, tool_choice, parallel_tool_calls | 128000 | 128000 | In: $0.10, Out: $0.10 | | mistral-code-agent-latest | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | mistral-code-fim-latest | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | mistral-code-latest | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | mistral-large-latest | mistral | In: text, image; Out: text | function_calling, vision, streaming, batch, fine_tuning, tool_choice, parallel_tool_calls | 262144 | 262144 | In: $0.50, Out: $1.50 | | mistral-large-2512 | mistral | In: text, image; Out: text | function_calling, vision, streaming, batch, fine_tuning, tool_choice, parallel_tool_calls | 262144 | 262144 | In: $0.50, Out: $1.50 | | mistral-medium | mistral | In: text; Out: text | streaming, function_calling, structured_output, vision, batch, fine_tuning, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | mistral-medium-3 | mistral | In: text; Out: text | streaming, function_calling, structured_output, vision, reasoning, batch, fine_tuning, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | mistral-medium-3-5 | mistral | In: text; Out: text | streaming, function_calling, structured_output, vision, reasoning, batch, fine_tuning, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | mistral-medium-3.5 | mistral | In: text; Out: text | streaming, function_calling, structured_output, vision, reasoning, batch, fine_tuning, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | mistral-medium-latest | mistral | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming, batch, fine_tuning, tool_choice, parallel_tool_calls | 262144 | 262144 | In: $1.50, Out: $7.50 | | mistral-medium-2505 | mistral | In: text, image; Out: text | function_calling, vision, streaming, batch, fine_tuning, tool_choice, parallel_tool_calls | 131072 | 131072 | In: $0.40, Out: $2.00 | | mistral-medium-2508 | mistral | In: text, image; Out: text | function_calling, vision, streaming, batch, fine_tuning, tool_choice, parallel_tool_calls | 262144 | 262144 | In: $0.40, Out: $2.00 | | mistral-medium-2604 | mistral | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming, batch, fine_tuning, tool_choice, parallel_tool_calls | 262144 | 262144 | In: $1.50, Out: $7.50 | | mistral-small-latest | mistral | In: text, image; Out: text | function_calling, reasoning, vision, streaming, batch, fine_tuning, tool_choice, parallel_tool_calls | 256000 | 256000 | In: $0.15, Out: $0.60 | | mistral-small-2506 | mistral | In: text, image; Out: text | function_calling, vision, streaming, batch, fine_tuning, tool_choice, parallel_tool_calls | 128000 | 16384 | In: $0.10, Out: $0.30 | | mistral-small-2603 | mistral | In: text, image; Out: text | function_calling, reasoning, vision, streaming, batch, fine_tuning, tool_choice, parallel_tool_calls | 256000 | 256000 | In: $0.15, Out: $0.60 | | mistral-tiny-2407 | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | mistral-tiny-latest | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | mistral-vibe-cli-fast | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | mistral-vibe-cli-latest | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | mistral-vibe-cli-with-tools | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | | open-mistral-nemo | mistral | In: text; Out: text | function_calling, streaming, batch, tool_choice, parallel_tool_calls | 128000 | 128000 | In: $0.15, Out: $0.15 | | open-mistral-nemo-2407 | mistral | In: text; Out: text | streaming, function_calling, structured_output, batch, tool_choice, parallel_tool_calls | 32768 | 8192 | - | ## Models by Modality ### Vision Models (494) Models that can process images: | Model | Provider | I/O | Capabilities | Context | Max Output | Standard Pricing (per 1M tokens) | | :-- | :-- | :-- | :-- | --: | --: | :-- | | claude-fable-5 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, citations, tool_choice, parallel_tool_calls | 1000000 | 128000 | In: $10.00, Out: $50.00, Cache Read: $1.00, Cache Write: $12.50 | | claude-haiku-4-5-20251001 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, citations, tool_choice, parallel_tool_calls | 200000 | 64000 | In: $1.00, Out: $5.00, Cache Read: $0.10, Cache Write: $1.25 | | claude-haiku-4-5 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $1.00, Out: $5.00, Cache Read: $0.10, Cache Write: $1.25 | | claude-opus-4-5-20251101 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, citations, tool_choice, parallel_tool_calls | 200000 | 64000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | claude-opus-4-5 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | claude-opus-4-6 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, citations, tool_choice, parallel_tool_calls | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | claude-opus-4-7 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, citations, tool_choice, parallel_tool_calls | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | claude-opus-4-8 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, citations, tool_choice, parallel_tool_calls | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | claude-opus-5 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, citations, tool_choice, parallel_tool_calls | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | claude-sonnet-4-5-20250929 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, citations, tool_choice, parallel_tool_calls | 1000000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | claude-sonnet-4-5 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | claude-sonnet-4-6 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, citations, tool_choice, parallel_tool_calls | 1000000 | 128000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | claude-sonnet-5 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, citations, tool_choice, parallel_tool_calls | 1000000 | 128000 | In: $2.00, Out: $10.00, Cache Read: $0.20, Cache Write: $2.50 | | au.anthropic.claude-opus-4-6-v1 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 128000 | In: $16.50, Out: $82.50, Cache Read: $1.65, Cache Write: $20.62 | | au.anthropic.claude-sonnet-4-6 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 128000 | In: $3.30, Out: $16.50, Cache Read: $0.33, Cache Write: $4.12 | | anthropic.claude-3-haiku-20240307-v1:0 | bedrock | In: text, image; Out: text | streaming, function_calling | - | - | - | | anthropic.claude-3-haiku-20240307-v1:0:200k | bedrock | In: text, image; Out: text | streaming, function_calling | - | - | - | | anthropic.claude-3-haiku-20240307-v1:0:48k | bedrock | In: text, image; Out: text | streaming, function_calling | - | - | - | | anthropic.claude-fable-5 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $10.00, Out: $50.00, Cache Read: $1.00, Cache Write: $12.50 | | eu.anthropic.claude-fable-5 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $11.00, Out: $55.00, Cache Read: $1.10, Cache Write: $13.75 | | global.anthropic.claude-fable-5 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $10.00, Out: $50.00, Cache Read: $1.00, Cache Write: $12.50 | | us.anthropic.claude-fable-5 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 1000000 | 128000 | In: $10.00, Out: $50.00, Cache Read: $1.00, Cache Write: $12.50 | | anthropic.claude-haiku-4-5-20251001-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $1.00, Out: $5.00, Cache Read: $0.10, Cache Write: $1.25 | | au.anthropic.claude-haiku-4-5-20251001-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $1.00, Out: $5.00, Cache Read: $0.10, Cache Write: $1.25 | | eu.anthropic.claude-haiku-4-5-20251001-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $1.10, Out: $5.50, Cache Read: $0.11, Cache Write: $1.38 | | global.anthropic.claude-haiku-4-5-20251001-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $1.00, Out: $5.00, Cache Read: $0.10, Cache Write: $1.25 | | jp.anthropic.claude-haiku-4-5-20251001-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $1.00, Out: $5.00, Cache Read: $0.10, Cache Write: $1.25 | | us.anthropic.claude-haiku-4-5-20251001-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 64000 | In: $1.00, Out: $5.00, Cache Read: $0.10, Cache Write: $1.25 | | anthropic.claude-opus-4-1-20250805-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 200000 | 32000 | In: $15.00, Out: $75.00, Cache Read: $1.50, Cache Write: $18.75 | | us.anthropic.claude-opus-4-1-20250805-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 200000 | 32000 | In: $15.00, Out: $75.00, Cache Read: $1.50, Cache Write: $18.75 | | anthropic.claude-opus-4-5-20251101-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | eu.anthropic.claude-opus-4-5-20251101-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $5.50, Out: $27.50, Cache Read: $0.55, Cache Write: $6.88 | | global.anthropic.claude-opus-4-5-20251101-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | us.anthropic.claude-opus-4-5-20251101-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 64000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | anthropic.claude-opus-4-6-v1 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | eu.anthropic.claude-opus-4-6-v1 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 128000 | In: $5.50, Out: $27.50, Cache Read: $0.55, Cache Write: $6.88 | | global.anthropic.claude-opus-4-6-v1 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | us.anthropic.claude-opus-4-6-v1 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | anthropic.claude-opus-4-7 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | eu.anthropic.claude-opus-4-7 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $5.50, Out: $27.50, Cache Read: $0.55, Cache Write: $6.88 | | global.anthropic.claude-opus-4-7 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | jp.anthropic.claude-opus-4-7 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | us.anthropic.claude-opus-4-7 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | anthropic.claude-opus-4-8 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | au.anthropic.claude-opus-4-8 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | eu.anthropic.claude-opus-4-8 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $5.50, Out: $27.50, Cache Read: $0.55, Cache Write: $6.88 | | global.anthropic.claude-opus-4-8 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | jp.anthropic.claude-opus-4-8 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | us.anthropic.claude-opus-4-8 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | anthropic.claude-opus-5 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | au.anthropic.claude-opus-5 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | eu.anthropic.claude-opus-5 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $5.50, Out: $27.50, Cache Read: $0.55, Cache Write: $6.88 | | global.anthropic.claude-opus-5 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | jp.anthropic.claude-opus-5 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | us.anthropic.claude-opus-5 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | us.anthropic.claude-sonnet-4-20250514-v1:0 | bedrock | In: text, image; Out: text | streaming, function_calling, reasoning | 200000 | 8192 | - | | anthropic.claude-sonnet-4-5-20250929-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | au.anthropic.claude-sonnet-4-5-20250929-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | eu.anthropic.claude-sonnet-4-5-20250929-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $3.30, Out: $16.50, Cache Read: $0.33, Cache Write: $4.12 | | global.anthropic.claude-sonnet-4-5-20250929-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | jp.anthropic.claude-sonnet-4-5-20250929-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | us.anthropic.claude-sonnet-4-5-20250929-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | anthropic.claude-sonnet-4-6 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | eu.anthropic.claude-sonnet-4-6 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 64000 | In: $3.30, Out: $16.50, Cache Read: $0.33, Cache Write: $4.12 | | global.anthropic.claude-sonnet-4-6 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | jp.anthropic.claude-sonnet-4-6 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | us.anthropic.claude-sonnet-4-6 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | anthropic.claude-sonnet-5 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 128000 | In: $2.00, Out: $10.00, Cache Read: $0.20, Cache Write: $2.50 | | au.anthropic.claude-sonnet-5 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 128000 | In: $2.00, Out: $10.00, Cache Read: $0.20, Cache Write: $2.50 | | eu.anthropic.claude-sonnet-5 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 128000 | In: $2.20, Out: $11.00, Cache Read: $0.22, Cache Write: $2.75 | | global.anthropic.claude-sonnet-5 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 128000 | In: $2.00, Out: $10.00, Cache Read: $0.20, Cache Write: $2.50 | | jp.anthropic.claude-sonnet-5 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 128000 | In: $2.00, Out: $10.00, Cache Read: $0.20, Cache Write: $2.50 | | us.anthropic.claude-sonnet-5 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $2.00, Out: $10.00, Cache Read: $0.20, Cache Write: $2.50 | | us.cohere.embed-v4:0 | bedrock | In: text, image; Out: embeddings | function_calling | 128000 | - | - | | openai.gpt-5.4 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 272000 | 128000 | In: $2.75, Out: $16.50, Cache Read: $0.28 | | openai.gpt-5.5 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 272000 | 128000 | In: $5.50, Out: $33.00, Cache Read: $0.55 | | openai.gpt-5.6-luna | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 272000 | 128000 | In: $0.22, Out: $1.32, Cache Read: $0.02, Cache Write: $0.28 | | openai.gpt-5.6-sol | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 272000 | 128000 | In: $5.50, Out: $33.00, Cache Read: $0.55, Cache Write: $6.88 | | openai.gpt-5.6-terra | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 272000 | 128000 | In: $2.20, Out: $13.20, Cache Read: $0.22, Cache Write: $2.75 | | google.gemma-3-4b-it | bedrock | In: text, image; Out: text | function_calling, vision, streaming | 128000 | 4096 | In: $0.04, Out: $0.08 | | google.gemma-3-12b-it | bedrock | In: text, image; Out: text | structured_output, vision, streaming | 131072 | 8192 | In: $0.05, Out: $0.10 | | google.gemma-3-27b-it | bedrock | In: text, image; Out: text | function_calling, structured_output, vision, streaming | 202752 | 8192 | In: $0.12, Out: $0.20 | | xai.grok-4.3 | bedrock | In: text, image; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 131072 | In: $1.25, Out: $2.50, Cache Read: $0.20 | | moonshotai.kimi-k2.5 | bedrock | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 262143 | 16000 | In: $0.60, Out: $3.00 | | meta.llama4-maverick-17b-instruct-v1:0 | bedrock | In: text, image; Out: text | function_calling, vision | 1000000 | 16384 | In: $0.24, Out: $0.97 | | us.meta.llama4-maverick-17b-instruct-v1:0 | bedrock | In: text, image; Out: text | function_calling, vision, streaming | 1000000 | 16384 | In: $0.24, Out: $0.97 | | meta.llama4-scout-17b-instruct-v1:0 | bedrock | In: text, image; Out: text | function_calling, vision | 3500000 | 16384 | In: $0.17, Out: $0.66 | | us.meta.llama4-scout-17b-instruct-v1:0 | bedrock | In: text, image; Out: text | function_calling, vision, streaming | 3500000 | 16384 | In: $0.17, Out: $0.66 | | mistral.magistral-small-2509 | bedrock | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 128000 | 40000 | In: $0.50, Out: $1.50 | | mistral.ministral-3-3b-instruct | bedrock | In: text, image; Out: text | function_calling, structured_output, vision, streaming | 256000 | 8192 | In: $0.10, Out: $0.10 | | mistral.mistral-large-3-675b-instruct | bedrock | In: text, image; Out: text | function_calling, structured_output, vision, streaming | 256000 | 8192 | In: $0.50, Out: $1.50 | | nvidia.nemotron-nano-12b-v2 | bedrock | In: text, image; Out: text | function_calling, structured_output, vision, streaming | 128000 | 4096 | In: $0.20, Out: $0.60 | | amazon.nova-2-lite-v1:0 | bedrock | In: text, image, video; Out: text | function_calling, reasoning, vision, video | 128000 | 4096 | In: $0.33, Out: $2.75 | | us.amazon.nova-2-lite-v1:0 | bedrock | In: text, image, video; Out: text | function_calling, reasoning, vision, video, streaming | 128000 | 4096 | In: $0.33, Out: $2.75 | | amazon.nova-lite-v1:0 | bedrock | In: text, image, video; Out: text | function_calling, vision, video, streaming | 300000 | 8192 | In: $0.06, Out: $0.24, Cache Read: $0.02 | | amazon.nova-premier-v1:0:1000k | bedrock | In: text, image, video; Out: text | streaming, function_calling | - | - | - | | amazon.nova-premier-v1:0:20k | bedrock | In: text, image, video; Out: text | streaming, function_calling | - | - | - | | amazon.nova-premier-v1:0:8k | bedrock | In: text, image, video; Out: text | streaming, function_calling | - | - | - | | amazon.nova-premier-v1:0:mm | bedrock | In: text, image, video; Out: text | streaming, function_calling | - | - | - | | us.amazon.nova-premier-v1:0 | bedrock | In: text, image, video; Out: text | streaming, function_calling | - | - | - | | amazon.nova-pro-v1:0 | bedrock | In: text, image, video; Out: text | function_calling, vision, video | 300000 | 8192 | In: $0.80, Out: $3.20, Cache Read: $0.20 | | us.amazon.nova-pro-v1:0 | bedrock | In: text, image, video; Out: text | function_calling, vision, video, streaming | 300000 | 8192 | In: $0.80, Out: $3.20, Cache Read: $0.20 | | mistral.pixtral-large-2502-v1:0 | bedrock | In: text, image; Out: text | function_calling, vision | 128000 | 8192 | In: $2.00, Out: $6.00 | | us.mistral.pixtral-large-2502-v1:0 | bedrock | In: text, image; Out: text | function_calling, vision, streaming | 128000 | 8192 | In: $2.00, Out: $6.00 | | qwen.qwen3-vl-235b-a22b | bedrock | In: text, image; Out: text | function_calling, structured_output, vision, streaming | 262000 | 262000 | In: $0.30, Out: $1.50 | | stability.sd3-5-large-v1:0 | bedrock | In: text, image; Out: image | function_calling | - | - | - | | us.stability.stable-conservative-upscale-v1:0 | bedrock | In: text, image; Out: image | function_calling | - | - | - | | us.stability.stable-image-control-sketch-v1:0 | bedrock | In: text, image; Out: image | function_calling | - | - | - | | us.stability.stable-image-control-structure-v1:0 | bedrock | In: text, image; Out: image | function_calling | - | - | - | | us.stability.stable-creative-upscale-v1:0 | bedrock | In: text, image; Out: image | function_calling | - | - | - | | us.stability.stable-image-erase-object-v1:0 | bedrock | In: text, image; Out: image | function_calling | - | - | - | | us.stability.stable-fast-upscale-v1:0 | bedrock | In: text, image; Out: image | function_calling | - | - | - | | us.stability.stable-image-inpaint-v1:0 | bedrock | In: text, image; Out: image | function_calling | - | - | - | | us.stability.stable-outpaint-v1:0 | bedrock | In: text, image; Out: image | function_calling | - | - | - | | us.stability.stable-image-remove-background-v1:0 | bedrock | In: text, image; Out: image | function_calling | - | - | - | | us.stability.stable-image-search-recolor-v1:0 | bedrock | In: text, image; Out: image | function_calling | - | - | - | | us.stability.stable-image-search-replace-v1:0 | bedrock | In: text, image; Out: image | function_calling | - | - | - | | us.stability.stable-image-style-guide-v1:0 | bedrock | In: text, image; Out: image | function_calling | - | - | - | | us.stability.stable-style-transfer-v1:0 | bedrock | In: text, image; Out: image | function_calling | - | - | - | | amazon.titan-embed-image-v1 | bedrock | In: text, image; Out: embeddings | function_calling | - | - | - | | amazon.titan-embed-image-v1:0 | bedrock | In: text, image; Out: embeddings | function_calling | - | - | - | | writer.palmyra-vision-7b | bedrock | In: text, image; Out: text | streaming, function_calling | - | 4096 | - | | deep-research-max-preview-04-2026 | gemini | In: text, image, video, audio, pdf; Out: text, image | function_calling, reasoning, vision, video | 131072 | 65536 | In: $2.00, Out: $12.00, Cache Read: $0.20 | | deep-research-preview-04-2026 | gemini | In: text, image, video, audio, pdf; Out: text, image | function_calling, reasoning, vision, video | 131072 | 65536 | In: $2.00, Out: $12.00, Cache Read: $0.20 | | gemini-2.0-flash | gemini | In: text, image, audio, video, pdf; Out: text | function_calling, structured_output, vision, video, tool_choice | 1048576 | 8192 | In: $0.10, Out: $0.40, Cache Read: $0.02 | | gemini-2.0-flash-lite | gemini | In: text, image, audio, video, pdf; Out: text | function_calling, structured_output, vision, video | 1048576 | 8192 | In: $0.08, Out: $0.30 | | gemini-2.5-computer-use-preview-10-2025 | gemini | In: text, image; Out: text | function_calling, reasoning, vision, tool_choice | 131072 | 65536 | In: $1.25, Out: $10.00 | | gemini-2.5-flash | gemini | In: text, image, audio, video, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, tool_choice | 1048576 | 65536 | In: $0.30, Out: $2.50, Cache Read: $0.03 | | gemini-2.5-flash-lite | gemini | In: text, image, audio, video, pdf; Out: text | function_calling, structured_output, reasoning, vision, video | 1048576 | 65536 | In: $0.10, Out: $0.40, Cache Read: $0.01 | | gemini-2.5-pro | gemini | In: text, image, audio, video, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, tool_choice | 1048576 | 65536 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gemini-3-flash-preview | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, tool_choice | 1048576 | 65536 | In: $0.50, Out: $3.00, Cache Read: $0.05 | | gemini-3-pro-preview | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, tool_choice | 1048576 | 65536 | In: $2.00, Out: $12.00, Cache Read: $0.20 | | gemini-3.1-flash-lite | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video | 1048576 | 65536 | In: $0.25, Out: $1.50, Cache Read: $0.02 | | gemini-3.1-flash-lite-preview | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video | 1048576 | 65536 | In: $0.25, Out: $1.50, Cache Read: $0.02 | | gemini-3.1-flash-live-preview | gemini | In: text, image, video, audio; Out: text, audio | function_calling, reasoning, vision, video | 131072 | 65536 | In: $0.75, Out: $4.50 | | gemini-3.1-pro-preview | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, tool_choice | 1048576 | 65536 | In: $2.00, Out: $12.00, Cache Read: $0.20 | | gemini-3.1-pro-preview-customtools | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, tool_choice | 1048576 | 65536 | In: $2.00, Out: $12.00, Cache Read: $0.20 | | gemini-3.5-flash | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, tool_choice | 1048576 | 65536 | In: $1.50, Out: $9.00, Cache Read: $0.15 | | gemini-3.5-flash-lite | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video | 1048576 | 65536 | In: $0.30, Out: $2.50, Cache Read: $0.03 | | gemini-3.6-flash | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, tool_choice | 1048576 | 65536 | In: $1.50, Out: $7.50, Cache Read: $0.15 | | gemini-embedding-2 | gemini | In: text, image, audio, video, pdf; Out: embeddings | vision, video, tool_choice | 8192 | 1 | In: $0.20, Out: $0.00 | | gemini-flash-latest | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, tool_choice | 1048576 | 65536 | In: $1.50, Out: $9.00, Cache Read: $0.15 | | gemini-flash-lite-latest | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video | 1048576 | 65536 | In: $0.25, Out: $1.50, Cache Read: $0.02 | | gemini-omni-flash-preview | gemini | In: text, image, video; Out: video | reasoning, vision, video, tool_choice | 131072 | 65536 | In: $1.50, Out: $17.50 | | gemini-robotics-er-1.6-preview | gemini | In: text, image, video, audio; Out: text | function_calling, structured_output, reasoning, vision, video, tool_choice | 131072 | 65536 | In: $1.00, Out: $5.00 | | gemma-4-26b-a4b-it | gemini | In: text, image; Out: text | function_calling, structured_output, reasoning, vision | 262144 | 32768 | In: $0.08, Out: $0.30 | | gemma-4-31b-it | gemini | In: text, image; Out: text | function_calling, structured_output, reasoning, vision | 262144 | 32768 | In: $0.08, Out: $0.30 | | lyria-3-clip-preview | gemini | In: text, image; Out: text, audio | vision | 1048576 | 65536 | In: $0.00, Out: $0.00 | | lyria-3-pro-preview | gemini | In: text, image; Out: text, audio | vision, tool_choice | 1048576 | 65536 | In: $0.00, Out: $0.00 | | gemini-2.5-flash-image | gemini | In: text, image; Out: text, image | reasoning, vision, tool_choice | 32768 | 32768 | In: $0.30, Out: $30.00, Cache Read: $0.08 | | gemini-3.1-flash-image | gemini | In: text, image, video, pdf; Out: text, image | reasoning, vision, video, tool_choice | 65536 | 65536 | In: $0.50, Out: $60.00 | | gemini-3.1-flash-image-preview | gemini | In: text, image, pdf; Out: text, image | reasoning, vision, tool_choice | 65536 | 65536 | In: $0.50, Out: $60.00 | | gemini-3.1-flash-lite-image | gemini | In: text, image; Out: text, image | function_calling, reasoning, vision | 65536 | 65536 | In: $0.25, Out: $30.00 | | gemini-3-pro-image | gemini | In: text, image; Out: text, image | reasoning, vision, tool_choice | 131072 | 32768 | In: $2.00, Out: $120.00 | | gemini-3-pro-image-preview | gemini | In: text, image; Out: text, image | reasoning, vision, tool_choice | 131072 | 32768 | In: $2.00, Out: $120.00 | | veo-3.1-generate-preview | gemini | In: text, image; Out: video | vision | 480 | 8192 | In: $0.08, Out: $0.30 | | veo-3.1-fast-generate-preview | gemini | In: text, image, video; Out: video | vision, video | 480 | 8192 | - | | veo-3.1-lite-generate-preview | gemini | In: text, image; Out: video | vision | 480 | 8192 | - | | labs-devstral-small-2512 | mistral | In: text, image; Out: text | function_calling, vision, tool_choice, parallel_tool_calls | 256000 | 256000 | In: $0.00, Out: $0.00 | | mistral-large-latest | mistral | In: text, image; Out: text | function_calling, vision, streaming, batch, fine_tuning, tool_choice, parallel_tool_calls | 262144 | 262144 | In: $0.50, Out: $1.50 | | mistral-large-2512 | mistral | In: text, image; Out: text | function_calling, vision, streaming, batch, fine_tuning, tool_choice, parallel_tool_calls | 262144 | 262144 | In: $0.50, Out: $1.50 | | mistral-medium-latest | mistral | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming, batch, fine_tuning, tool_choice, parallel_tool_calls | 262144 | 262144 | In: $1.50, Out: $7.50 | | mistral-medium-2505 | mistral | In: text, image; Out: text | function_calling, vision, streaming, batch, fine_tuning, tool_choice, parallel_tool_calls | 131072 | 131072 | In: $0.40, Out: $2.00 | | mistral-medium-2508 | mistral | In: text, image; Out: text | function_calling, vision, streaming, batch, fine_tuning, tool_choice, parallel_tool_calls | 262144 | 262144 | In: $0.40, Out: $2.00 | | mistral-medium-2604 | mistral | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming, batch, fine_tuning, tool_choice, parallel_tool_calls | 262144 | 262144 | In: $1.50, Out: $7.50 | | mistral-small-latest | mistral | In: text, image; Out: text | function_calling, reasoning, vision, streaming, batch, fine_tuning, tool_choice, parallel_tool_calls | 256000 | 256000 | In: $0.15, Out: $0.60 | | mistral-small-2506 | mistral | In: text, image; Out: text | function_calling, vision, streaming, batch, fine_tuning, tool_choice, parallel_tool_calls | 128000 | 16384 | In: $0.10, Out: $0.30 | | mistral-small-2603 | mistral | In: text, image; Out: text | function_calling, reasoning, vision, streaming, batch, fine_tuning, tool_choice, parallel_tool_calls | 256000 | 256000 | In: $0.15, Out: $0.60 | | pixtral-12b | mistral | In: text, image; Out: text | function_calling, vision, tool_choice, parallel_tool_calls | 128000 | 128000 | In: $0.15, Out: $0.15 | | pixtral-large-latest | mistral | In: text, image; Out: text | function_calling, vision, tool_choice, parallel_tool_calls | 128000 | 128000 | In: $2.00, Out: $6.00 | | gpt-4-turbo | openai | In: text, image; Out: text | function_calling, vision, tool_choice, parallel_tool_calls | 128000 | 4096 | In: $10.00, Out: $30.00 | | gpt-4.1 | openai | In: text, image, pdf; Out: text | function_calling, structured_output, vision, tool_choice, parallel_tool_calls | 1047576 | 32768 | In: $2.00, Out: $8.00, Cache Read: $0.50 | | gpt-4.1-mini | openai | In: text, image, pdf; Out: text | function_calling, structured_output, vision, tool_choice, parallel_tool_calls | 1047576 | 32768 | In: $0.40, Out: $1.60, Cache Read: $0.10 | | gpt-4.1-nano | openai | In: text, image; Out: text | function_calling, structured_output, vision, tool_choice, parallel_tool_calls | 1047576 | 32768 | In: $0.10, Out: $0.40, Cache Read: $0.02 | | gpt-4o | openai | In: text, image, pdf; Out: text | function_calling, structured_output, vision, tool_choice, parallel_tool_calls | 128000 | 16384 | In: $2.50, Out: $10.00, Cache Read: $1.25 | | gpt-4o-2024-05-13 | openai | In: text, image; Out: text | function_calling, structured_output, vision, tool_choice, parallel_tool_calls | 128000 | 4096 | In: $5.00, Out: $15.00 | | gpt-4o-2024-08-06 | openai | In: text, image; Out: text | function_calling, structured_output, vision, tool_choice, parallel_tool_calls | 128000 | 16384 | In: $2.50, Out: $10.00, Cache Read: $1.25 | | gpt-4o-2024-11-20 | openai | In: text, image; Out: text | function_calling, structured_output, vision, tool_choice, parallel_tool_calls | 128000 | 16384 | In: $2.50, Out: $10.00, Cache Read: $1.25 | | gpt-4o-mini | openai | In: text, image, pdf; Out: text | function_calling, structured_output, vision, tool_choice, parallel_tool_calls | 128000 | 16384 | In: $0.15, Out: $0.60, Cache Read: $0.08 | | gpt-5 | openai | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 400000 | 128000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5-mini | openai | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 400000 | 128000 | In: $0.25, Out: $2.00, Cache Read: $0.02 | | gpt-5-nano | openai | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 400000 | 128000 | In: $0.05, Out: $0.40, Cache Read: $0.01 | | gpt-5-pro | openai | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 400000 | 272000 | In: $15.00, Out: $120.00 | | gpt-5.1 | openai | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 400000 | 128000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gpt-5.2 | openai | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 400000 | 128000 | In: $1.75, Out: $14.00, Cache Read: $0.18 | | gpt-5.2-chat-latest | openai | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 128000 | 16384 | In: $1.75, Out: $14.00, Cache Read: $0.18 | | gpt-5.2-pro | openai | In: text, image; Out: text | function_calling, reasoning, vision, tool_choice, parallel_tool_calls | 400000 | 128000 | In: $21.00, Out: $168.00 | | gpt-5.3-chat-latest | openai | In: text, image; Out: text | function_calling, structured_output, vision, tool_choice, parallel_tool_calls | 128000 | 16384 | In: $1.75, Out: $14.00, Cache Read: $0.18 | | gpt-5.3-codex | openai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 400000 | 128000 | In: $1.75, Out: $14.00, Cache Read: $0.18 | | gpt-5.3-codex-spark | openai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 128000 | 32000 | In: $1.75, Out: $14.00, Cache Read: $0.18 | | gpt-5.4 | openai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 1050000 | 128000 | In: $2.50, Out: $15.00, Cache Read: $0.25 | | gpt-5.4-pro | openai | In: text, image; Out: text | function_calling, reasoning, vision, tool_choice, parallel_tool_calls | 1050000 | 128000 | In: $30.00, Out: $180.00 | | gpt-5.4-mini | openai | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 400000 | 128000 | In: $0.75, Out: $4.50, Cache Read: $0.08 | | gpt-5.4-nano | openai | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 400000 | 128000 | In: $0.20, Out: $1.25, Cache Read: $0.02 | | gpt-5.5 | openai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 1050000 | 128000 | In: $5.00, Out: $30.00, Cache Read: $0.50 | | gpt-5.5-pro | openai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 1050000 | 128000 | In: $30.00, Out: $180.00 | | gpt-5.6 | openai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1050000 | 128000 | In: $5.00, Out: $30.00, Cache Read: $0.50, Cache Write: $6.25 | | gpt-5.6-luna | openai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 1050000 | 128000 | In: $0.20, Out: $1.20, Cache Read: $0.02, Cache Write: $0.25 | | gpt-5.6-sol | openai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 1050000 | 128000 | In: $5.00, Out: $30.00, Cache Read: $0.50, Cache Write: $6.25 | | gpt-5.6-terra | openai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 1050000 | 128000 | In: $2.00, Out: $12.00, Cache Read: $0.20, Cache Write: $2.50 | | gpt-realtime-2.1 | openai | In: text, audio, image; Out: text, audio | function_calling, reasoning, vision | 128000 | 32000 | In: $4.00, Out: $24.00, Cache Read: $0.40 | | chatgpt-image-latest | openai | In: text, image; Out: text, image | vision | 0 | 0 | In: $0.50, Out: $1.50 | | gpt-image-1 | openai | In: text, image; Out: image | vision | 0 | 0 | In: $5.00, Cache Read: $1.25 | | gpt-image-1-mini | openai | In: text, image; Out: text, image | vision | 0 | 0 | In: $2.00, Cache Read: $0.20 | | gpt-image-1.5 | openai | In: text, image; Out: text, image | vision | 0 | 0 | In: $5.00, Cache Read: $1.25 | | gpt-image-2 | openai | In: text, image; Out: image | vision | 0 | 0 | In: $5.00, Out: $30.00, Cache Read: $1.25 | | o1 | openai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 200000 | 100000 | In: $15.00, Out: $60.00, Cache Read: $7.50 | | o1-pro | openai | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 200000 | 100000 | In: $150.00, Out: $600.00 | | o3 | openai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 100000 | In: $2.00, Out: $8.00, Cache Read: $0.50 | | o3-pro | openai | In: text, image; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 100000 | In: $20.00, Out: $80.00 | | o4-mini | openai | In: text, image; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 100000 | In: $1.10, Out: $4.40, Cache Read: $0.28 | | ~anthropic/claude-haiku-latest | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 64000 | In: $1.00, Out: $5.00, Cache Read: $0.10, Cache Write: $1.25 | | ~anthropic/claude-sonnet-latest | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $2.00, Out: $10.00, Cache Read: $0.20, Cache Write: $2.50 | | anthropic/claude-fable-5:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50 | | anthropic/claude-haiku-4.5:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 200000 | 64000 | In: $0.50, Out: $2.50, Cache Read: $0.05 | | anthropic/claude-opus-4.1:batch | openrouter | In: image, text, file; Out: text | streaming, function_calling, structured_output | 200000 | 32000 | In: $7.50, Out: $37.50, Cache Read: $0.75 | | anthropic/claude-opus-4.5:batch | openrouter | In: file, image, text; Out: text | streaming, function_calling, structured_output | 200000 | 64000 | In: $2.50, Out: $12.50, Cache Read: $0.25 | | anthropic/claude-opus-4.6:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 1000000 | 128000 | In: $2.50, Out: $12.50, Cache Read: $0.25 | | anthropic/claude-opus-4.7:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 1000000 | 128000 | In: $2.50, Out: $12.50, Cache Read: $0.25 | | anthropic/claude-opus-4.8:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 1000000 | 128000 | In: $2.50, Out: $12.50, Cache Read: $0.25 | | anthropic/claude-sonnet-4.5:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 1000000 | 64000 | In: $1.50, Out: $7.50, Cache Read: $0.15 | | anthropic/claude-sonnet-4.6:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 1000000 | 128000 | In: $1.50, Out: $7.50, Cache Read: $0.15 | | anthropic/claude-sonnet-5:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 1000000 | 128000 | In: $1.00, Out: $5.00, Cache Read: $0.10 | | openrouter/auto | openrouter | In: text, image, audio, pdf, video; Out: text, image | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 2000000 | 2000000 | - | | openrouter/auto-beta | openrouter | In: text, image, audio, file, video; Out: text, image | streaming, function_calling, structured_output, predicted_outputs | 2000000 | - | - | | anthropic/claude-3-haiku | openrouter | In: text, image; Out: text | function_calling, vision, streaming | 200000 | 4096 | In: $0.25, Out: $1.25, Cache Read: $0.03, Cache Write: $0.30 | | anthropic/claude-fable-5 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $10.00, Out: $50.00, Cache Read: $1.00, Cache Write: $12.50 | | ~anthropic/claude-fable-latest | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $10.00, Out: $50.00, Cache Read: $1.00, Cache Write: $12.50 | | anthropic/claude-haiku-4.5 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 64000 | In: $1.00, Out: $5.00, Cache Read: $0.10, Cache Write: $1.25 | | anthropic/claude-opus-4 | openrouter | In: image, text, pdf; Out: text | function_calling, reasoning, vision, streaming | 200000 | 32000 | In: $15.00, Out: $75.00, Cache Read: $1.50, Cache Write: $18.75 | | anthropic/claude-opus-4.1 | openrouter | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 200000 | 32000 | In: $15.00, Out: $75.00, Cache Read: $1.50, Cache Write: $18.75 | | anthropic/claude-opus-4.5 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 64000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | anthropic/claude-opus-4.6 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | anthropic/claude-opus-4.7 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | anthropic/claude-opus-4.7-fast | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $30.00, Out: $150.00, Cache Read: $3.00, Cache Write: $37.50 | | anthropic/claude-opus-4.8 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | anthropic/claude-opus-4.8-fast | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $10.00, Out: $50.00, Cache Read: $1.00, Cache Write: $12.50 | | anthropic/claude-opus-5 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | anthropic/claude-opus-5-fast | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $10.00, Out: $50.00, Cache Read: $1.00, Cache Write: $12.50 | | anthropic/claude-opus-5:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 1000000 | 128000 | In: $2.50, Out: $12.50, Cache Read: $0.25 | | ~anthropic/claude-opus-latest | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | anthropic/claude-sonnet-4 | openrouter | In: image, text, pdf; Out: text | function_calling, reasoning, vision, streaming | 1000000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | anthropic/claude-sonnet-4.5 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | anthropic/claude-sonnet-4.6 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | anthropic/claude-sonnet-5 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $2.00, Out: $10.00, Cache Read: $0.20, Cache Write: $2.50 | | baidu/ernie-4.5-vl-424b-a47b | openrouter | In: image, text; Out: text | reasoning, vision, streaming | 123000 | 16000 | In: $0.42, Out: $1.25 | | openrouter/free | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 8000 | In: $0.00, Out: $0.00 | | sakana/fugu-ultra | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $30.00, Cache Read: $0.50 | | z-ai/glm-4.5v | openrouter | In: text, image; Out: text | function_calling, reasoning, vision, streaming | 65536 | 16384 | In: $0.60, Out: $1.80, Cache Read: $0.11 | | z-ai/glm-4.6v | openrouter | In: text, image, video; Out: text | function_calling, reasoning, vision, video, streaming | 131072 | 32768 | In: $0.30, Out: $0.90, Cache Read: $0.06 | | z-ai/glm-5v-turbo | openrouter | In: image, text, video; Out: text | function_calling, reasoning, vision, video, streaming | 202752 | 131072 | In: $1.20, Out: $4.00, Cache Read: $0.24 | | openai/gpt-chat-latest | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 400000 | 128000 | In: $5.00, Out: $30.00, Cache Read: $0.50 | | openai/gpt-4-turbo | openrouter | In: text, image; Out: text | function_calling, structured_output, vision, streaming | 128000 | 4096 | In: $10.00, Out: $30.00 | | openai/gpt-4.1 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 1047576 | 32768 | In: $2.00, Out: $8.00, Cache Read: $0.50 | | openai/gpt-4.1-mini | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 1047576 | 32768 | In: $0.40, Out: $1.60, Cache Read: $0.10 | | openai/gpt-4.1-nano | openrouter | In: image, text, pdf; Out: text | function_calling, structured_output, vision, streaming | 1047576 | 32768 | In: $0.10, Out: $0.40, Cache Read: $0.02 | | openai/gpt-4o | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 128000 | 16384 | In: $2.50, Out: $10.00, Cache Read: $1.25 | | openai/gpt-4o-2024-05-13 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 128000 | 4096 | In: $5.00, Out: $15.00 | | openai/gpt-4o-2024-08-06 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 128000 | 16384 | In: $2.50, Out: $10.00, Cache Read: $1.25 | | openai/gpt-4o-2024-11-20 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 128000 | 16384 | In: $2.50, Out: $10.00, Cache Read: $1.25 | | openai/gpt-4o-mini | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 128000 | 16384 | In: $0.15, Out: $0.60, Cache Read: $0.08 | | openai/gpt-4o-mini-2024-07-18 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 128000 | 16384 | In: $0.15, Out: $0.60, Cache Read: $0.08 | | openai/gpt-5 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | openai/gpt-5-image | openrouter | In: image, text, pdf; Out: image, text | structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $10.00, Out: $10.00, Cache Read: $1.25 | | openai/gpt-5-image-mini | openrouter | In: pdf, image, text; Out: image, text | structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $2.50, Out: $2.00, Cache Read: $0.25 | | openai/gpt-5-mini | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $0.25, Out: $2.00, Cache Read: $0.02 | | openai/gpt-5-nano | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $0.05, Out: $0.40, Cache Read: $0.01 | | openai/gpt-5-pro | openrouter | In: image, text, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $15.00, Out: $120.00 | | openai/gpt-5.1 | openrouter | In: image, text, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | openai/gpt-5.1-codex | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $1.25, Out: $10.00, Cache Read: $0.13 | | openai/gpt-5.1-codex-max | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | openai/gpt-5.1-codex-mini | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $0.25, Out: $2.00, Cache Read: $0.03 | | openai/gpt-5.2 | openrouter | In: pdf, image, text; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $1.75, Out: $14.00, Cache Read: $0.18 | | openai/gpt-5.2-chat | openrouter | In: pdf, image, text; Out: text | function_calling, structured_output, vision, streaming | 128000 | 16384 | In: $1.75, Out: $14.00, Cache Read: $0.18 | | openai/gpt-5.2-codex | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $1.75, Out: $14.00, Cache Read: $0.18 | | openai/gpt-5.2-pro | openrouter | In: image, text, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $21.00, Out: $168.00 | | openai/gpt-5.3-chat | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 128000 | 16384 | In: $1.75, Out: $14.00, Cache Read: $0.18 | | openai/gpt-5.3-codex | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $1.75, Out: $14.00, Cache Read: $0.18 | | openai/gpt-5.4 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $2.50, Out: $15.00, Cache Read: $0.25 | | openai/gpt-5.4-image-2 | openrouter | In: image, text, pdf; Out: image, text | structured_output, reasoning, vision, streaming | 272000 | 128000 | In: $8.00, Out: $15.00, Cache Read: $2.00 | | openai/gpt-5.4-pro | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $30.00, Out: $180.00 | | openai/gpt-5.4-mini | openrouter | In: pdf, image, text; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $0.75, Out: $4.50, Cache Read: $0.08 | | openai/gpt-5.4-nano | openrouter | In: pdf, image, text; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $0.20, Out: $1.25, Cache Read: $0.02 | | openai/gpt-5.5 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $5.00, Out: $30.00, Cache Read: $0.50 | | openai/gpt-5.5-pro | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $30.00, Out: $180.00 | | openai/gpt-5.6-luna | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $0.10, Out: $0.60, Cache Read: $0.01, Cache Write: $0.12 | | openai/gpt-5.6-luna-pro | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $0.10, Out: $0.60, Cache Read: $0.01, Cache Write: $0.12 | | openai/gpt-5.6-sol | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $5.00, Out: $30.00, Cache Read: $0.50, Cache Write: $6.25 | | openai/gpt-5.6-sol-pro | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $5.00, Out: $30.00, Cache Read: $0.50, Cache Write: $6.25 | | openai/gpt-5.6-terra | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $1.00, Out: $6.00, Cache Read: $0.10, Cache Write: $1.25 | | openai/gpt-5.6-terra-pro | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $1.00, Out: $6.00, Cache Read: $0.10, Cache Write: $1.25 | | google/gemini-2.5-flash | openrouter | In: text, image, audio, video, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65535 | In: $0.30, Out: $2.50, Cache Read: $0.03, Cache Write: $0.08 | | google/gemini-2.5-flash-lite | openrouter | In: text, image, audio, video, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65535 | In: $0.10, Out: $0.40, Cache Read: $0.01, Cache Write: $0.08 | | google/gemini-2.5-pro | openrouter | In: text, image, audio, video, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $1.25, Out: $10.00, Cache Read: $0.12, Cache Write: $0.38 | | google/gemini-2.5-pro-preview-05-06 | openrouter | In: text, image, pdf, audio, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65535 | In: $1.25, Out: $10.00, Cache Read: $0.12, Cache Write: $0.38 | | google/gemini-2.5-pro-preview | openrouter | In: pdf, image, text, audio; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1048576 | 65536 | In: $1.25, Out: $10.00, Cache Read: $0.12, Cache Write: $0.38 | | google/gemini-3-flash-preview | openrouter | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $0.50, Out: $3.00, Cache Read: $0.05, Cache Write: $0.08 | | google/gemini-3.1-flash-lite | openrouter | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $0.25, Out: $1.50, Cache Read: $0.02, Cache Write: $0.08 | | google/gemini-3.1-flash-lite-preview | openrouter | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $0.25, Out: $1.50, Cache Read: $0.02, Cache Write: $0.08 | | google/gemini-3.1-pro-preview | openrouter | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $2.00, Out: $12.00, Cache Read: $0.20, Cache Write: $0.38 | | google/gemini-3.1-pro-preview-customtools | openrouter | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $2.00, Out: $12.00, Cache Read: $0.20, Cache Write: $0.38 | | google/gemini-3.5-flash | openrouter | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $1.50, Out: $9.00, Cache Read: $0.15, Cache Write: $0.08 | | google/gemini-3.5-flash-lite | openrouter | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $0.30, Out: $2.50, Cache Read: $0.03, Cache Write: $0.08 | | google/gemini-3.6-flash | openrouter | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $1.50, Out: $7.50, Cache Read: $0.15, Cache Write: $0.08 | | google/gemma-3-12b-it | openrouter | In: text, image; Out: text | function_calling, structured_output, vision, streaming, predicted_outputs | 131072 | 16384 | In: $0.05, Out: $0.15 | | google/gemma-3-27b-it | openrouter | In: text, image; Out: text | function_calling, structured_output, vision, streaming, predicted_outputs | 262144 | 131072 | In: $0.08, Out: $0.45, Cache Read: $0.04 | | google/gemma-3-4b-it | openrouter | In: text, image; Out: text | structured_output, vision, streaming, predicted_outputs | 131072 | 16384 | In: $0.05, Out: $0.10 | | google/gemma-4-26b-a4b-it:free | openrouter | In: image, text, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 262144 | 32768 | In: $0.00, Out: $0.00 | | google/gemma-4-26b-a4b-it | openrouter | In: image, text, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 262144 | 16384 | In: $0.07, Out: $0.34 | | google/gemma-4-31b-it:free | openrouter | In: image, text, video; Out: text | function_calling, reasoning, vision, video, streaming | 262144 | 32768 | In: $0.00, Out: $0.00 | | google/gemma-4-31b-it | openrouter | In: image, text, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 262144 | 262144 | In: $0.10, Out: $0.34, Cache Read: $0.10 | | ~google/gemini-flash-latest | openrouter | In: text, image, video, pdf, audio; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $1.50, Out: $7.50, Cache Read: $0.15, Cache Write: $0.08 | | ~google/gemini-pro-latest | openrouter | In: audio, pdf, image, text, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $2.00, Out: $12.00, Cache Read: $0.20, Cache Write: $0.38 | | google/gemini-2.5-flash:batch | openrouter | In: file, image, text, audio, video; Out: text | streaming, function_calling, structured_output | 1048576 | 65535 | In: $0.15, Out: $1.25, Cache Read: $0.03 | | google/gemini-2.5-flash-lite:batch | openrouter | In: text, image, file, audio, video; Out: text | streaming, function_calling, structured_output | 1048576 | 65535 | In: $0.05, Out: $0.20, Cache Read: $0.01 | | google/gemini-2.5-pro:batch | openrouter | In: text, image, file, audio, video; Out: text | streaming, function_calling, structured_output | 1048576 | 65536 | In: $0.62, Out: $5.00, Cache Read: $0.12 | | google/gemini-3-flash-preview:batch | openrouter | In: text, image, file, audio, video; Out: text | streaming, function_calling, structured_output | 1048576 | 65536 | In: $0.25, Out: $1.50 | | google/gemini-3.1-flash-lite:batch | openrouter | In: text, image, video, file, audio; Out: text | streaming, function_calling, structured_output | 1048576 | 65536 | In: $0.12, Out: $0.75, Cache Read: $0.01 | | google/gemini-3.1-pro-preview:batch | openrouter | In: audio, file, image, text, video; Out: text | streaming, function_calling, structured_output | 1048576 | 65536 | In: $1.00, Out: $6.00 | | google/gemini-3.5-flash:batch | openrouter | In: text, image, video, file, audio; Out: text | streaming, function_calling, structured_output | 1048576 | 65536 | In: $0.75, Out: $4.50, Cache Read: $0.08 | | google/gemini-3.5-flash-lite:batch | openrouter | In: text, image, video, file, audio; Out: text | streaming, function_calling, structured_output | 1048576 | 65536 | In: $0.15, Out: $1.25, Cache Read: $0.02 | | google/gemini-3.6-flash:batch | openrouter | In: text, image, video, file, audio; Out: text | streaming, function_calling, structured_output | 1048576 | 65536 | In: $0.75, Out: $3.75, Cache Read: $0.08 | | x-ai/grok-4.20 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 2000000 | 2000000 | In: $1.25, Out: $2.50, Cache Read: $0.20 | | x-ai/grok-4.20-multi-agent | openrouter | In: text, image, pdf; Out: text | structured_output, reasoning, vision, streaming | 2000000 | 2000000 | In: $1.25, Out: $2.50, Cache Read: $0.20 | | x-ai/grok-4.3 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 1000000 | In: $1.25, Out: $2.50, Cache Read: $0.20 | | x-ai/grok-4.5 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 500000 | 500000 | In: $2.00, Out: $6.00, Cache Read: $0.30 | | x-ai/grok-build-0.1 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 256000 | 256000 | In: $1.00, Out: $2.00, Cache Read: $0.20 | | ~x-ai/grok-latest | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 500000 | 1000000 | In: $2.00, Out: $6.00, Cache Read: $0.30 | | thinkingmachines/inkling | openrouter | In: text, image, audio; Out: text | function_calling, reasoning, vision, streaming, predicted_outputs | 1048576 | 1048576 | In: $1.00, Out: $4.05, Cache Read: $0.17 | | thinkingmachines/inkling-small | openrouter | In: text, image, audio; Out: text | function_calling, reasoning, vision, streaming, predicted_outputs | 524288 | 262144 | In: $0.45, Out: $1.20, Cache Read: $0.10 | | moonshotai/kimi-k2.5 | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming, predicted_outputs | 262144 | 262144 | In: $0.57, Out: $2.85, Cache Read: $0.10 | | moonshotai/kimi-k2.6 | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming, predicted_outputs | 262144 | 262144 | In: $0.58, Out: $2.44, Cache Read: $0.10 | | moonshotai/kimi-k2.7-code | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming, predicted_outputs | 262144 | 262144 | In: $0.70, Out: $3.50, Cache Read: $0.15 | | moonshotai/kimi-k3 | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming, predicted_outputs | 1048576 | 1048576 | In: $3.00, Out: $15.00, Cache Read: $0.30 | | meta-llama/llama-4-maverick | openrouter | In: text, image; Out: text | function_calling, structured_output, vision, streaming, predicted_outputs | 1048576 | 16384 | In: $0.20, Out: $0.80 | | meta-llama/llama-4-scout | openrouter | In: text, image; Out: text | function_calling, structured_output, vision, streaming, predicted_outputs | 1310720 | 16384 | In: $0.10, Out: $0.30 | | meta-llama/llama-guard-4-12b | openrouter | In: image, text; Out: text | vision, streaming, predicted_outputs | 1048576 | 16384 | In: $0.18, Out: $0.18 | | google/lyria-3-clip-preview | openrouter | In: text, image; Out: text, audio | vision, streaming | 1048576 | 65536 | In: $0.00, Out: $0.00 | | google/lyria-3-pro-preview | openrouter | In: text, image; Out: text, audio | vision, streaming | 1048576 | 65536 | In: $0.00, Out: $0.00 | | xiaomi/mimo-v2.5 | openrouter | In: text, image, audio, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 1050000 | 131072 | In: $0.14, Out: $0.28, Cache Read: $0.00 | | minimax/minimax-01 | openrouter | In: text, image; Out: text | vision, streaming | 1000192 | 1000192 | In: $0.20, Out: $1.10 | | minimax/minimax-m3 | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 1048576 | 512000 | In: $0.30, Out: $1.20, Cache Read: $0.06 | | minimax/minimax-m3:batch | openrouter | In: text, image, video; Out: text | streaming, function_calling, structured_output, predicted_outputs | 524288 | - | In: $0.15, Out: $0.60, Cache Read: $0.03 | | mistralai/ministral-14b-2512 | openrouter | In: text, image; Out: text | function_calling, structured_output, vision, streaming | 262144 | 262144 | In: $0.20, Out: $0.20, Cache Read: $0.02 | | mistralai/ministral-3b-2512 | openrouter | In: text, image; Out: text | function_calling, structured_output, vision, streaming | 131072 | 131072 | In: $0.10, Out: $0.10, Cache Read: $0.01 | | mistralai/ministral-8b-2512 | openrouter | In: text, image; Out: text | function_calling, structured_output, vision, streaming | 262144 | 262144 | In: $0.15, Out: $0.15, Cache Read: $0.02 | | mistralai/mistral-large-2512 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 262144 | 262144 | In: $0.50, Out: $1.50, Cache Read: $0.05 | | mistralai/mistral-medium-3 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 131072 | 131072 | In: $0.40, Out: $2.00, Cache Read: $0.04 | | mistralai/mistral-medium-3.1 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 131072 | 262144 | In: $0.40, Out: $2.00, Cache Read: $0.04 | | mistralai/mistral-medium-3-5 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 262144 | 262144 | In: $1.50, Out: $7.50 | | mistralai/mistral-small-3.1-24b-instruct | openrouter | In: text, image; Out: text | vision, streaming, predicted_outputs | 128000 | 128000 | In: $0.35, Out: $0.56 | | mistralai/mistral-small-3.2-24b-instruct | openrouter | In: image, text; Out: text | function_calling, structured_output, vision, streaming, predicted_outputs | 256000 | 16384 | In: $0.09, Out: $0.25 | | mistralai/mistral-small-2603 | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 262144 | 262144 | In: $0.15, Out: $0.60, Cache Read: $0.02 | | ~moonshotai/kimi-latest | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming, predicted_outputs | 1048576 | 1048576 | In: $2.50, Out: $14.00, Cache Read: $0.29 | | moonshotai/kimi-k2.7-code:batch | openrouter | In: text, image; Out: text | streaming, function_calling, structured_output, predicted_outputs | 262144 | - | In: $0.48, Out: $2.00, Cache Read: $0.10 | | meta/muse-spark-1.1 | openrouter | In: text, image, video, pdf, audio; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 1048576 | In: $1.25, Out: $4.25, Cache Read: $0.15 | | meta/muse-spark-1.2 | openrouter | In: text, image, video, pdf, audio; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 1048576 | In: $1.25, Out: $4.25, Cache Read: $0.15 | | google/gemini-2.5-flash-image | openrouter | In: text, image; Out: text, image | structured_output, vision, streaming | 32768 | 8192 | In: $0.30, Out: $2.50, Cache Read: $0.03, Cache Write: $0.08 | | google/gemini-3.1-flash-image | openrouter | In: text, image; Out: text, image | structured_output, reasoning, vision, streaming | 131072 | 32768 | In: $0.50, Out: $3.00 | | google/gemini-3.1-flash-image-preview | openrouter | In: image, text; Out: text, image | structured_output, reasoning, vision, streaming | 65536 | 65536 | In: $0.50, Out: $3.00 | | google/gemini-3.1-flash-lite-image | openrouter | In: text, image; Out: text, image | reasoning, vision, streaming | 65536 | 65536 | In: $0.25, Out: $1.50 | | google/gemini-3-pro-image | openrouter | In: text, image; Out: text, image | function_calling, structured_output, reasoning, vision, streaming | 131072 | 32768 | In: $2.00, Out: $12.00, Cache Read: $0.20, Cache Write: $0.38 | | google/gemini-3-pro-image-preview | openrouter | In: text, image; Out: text, image | structured_output, reasoning, vision, streaming | 65536 | 32768 | In: $2.00, Out: $12.00, Cache Read: $0.20, Cache Write: $0.38 | | nvidia/nemotron-3-nano-omni-30b-a3b-reasoning:free | openrouter | In: text, image, video, audio; Out: text | function_calling, reasoning, vision, video, streaming | 256000 | 65536 | In: $0.00, Out: $0.00 | | nvidia/nemotron-3.5-content-safety:free | openrouter | In: text, image; Out: text | reasoning, vision, streaming | 128000 | 8192 | In: $0.00, Out: $0.00 | | nvidia/nemotron-nano-12b-v2-vl:free | openrouter | In: text, image, video; Out: text | function_calling, reasoning, vision, video, streaming | 128000 | 128000 | In: $0.00, Out: $0.00 | | nex-agi/nex-n2-mini | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 262144 | 262144 | In: $0.02, Out: $0.10, Cache Read: $0.00 | | nex-agi/nex-n2-pro | openrouter | In: text, image; Out: text | function_calling, reasoning, vision, streaming | 262144 | 262144 | In: $0.25, Out: $1.00, Cache Read: $0.02 | | amazon/nova-2-lite-v1 | openrouter | In: text, image, video, pdf; Out: text | function_calling, reasoning, vision, video, streaming | 1000000 | 65535 | In: $0.30, Out: $2.50 | | amazon/nova-lite-v1 | openrouter | In: text, image; Out: text | function_calling, vision, streaming | 300000 | 5120 | In: $0.06, Out: $0.24 | | amazon/nova-premier-v1 | openrouter | In: text, image; Out: text | function_calling, vision, streaming | 1000000 | 32000 | In: $2.50, Out: $12.50, Cache Read: $0.62 | | amazon/nova-pro-v1 | openrouter | In: text, image; Out: text | function_calling, vision, streaming | 300000 | 5120 | In: $0.80, Out: $3.20 | | ~openai/gpt-latest | openrouter | In: pdf, image, text; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $5.00, Out: $30.00, Cache Read: $0.50, Cache Write: $6.25 | | ~openai/gpt-mini-latest | openrouter | In: pdf, image, text; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $0.75, Out: $4.50, Cache Read: $0.08 | | openai/gpt-4-turbo:batch | openrouter | In: text, image; Out: text | streaming, function_calling, structured_output | 128000 | 4096 | In: $5.00, Out: $15.00 | | openai/gpt-4.1:batch | openrouter | In: image, text, file; Out: text | streaming, function_calling, structured_output | 1047576 | 32768 | In: $1.00, Out: $4.00, Cache Read: $0.25 | | openai/gpt-4.1-mini:batch | openrouter | In: image, text, file; Out: text | streaming, function_calling, structured_output | 1047576 | 32768 | In: $0.20, Out: $0.80, Cache Read: $0.05 | | openai/gpt-4.1-nano:batch | openrouter | In: image, text, file; Out: text | streaming, function_calling, structured_output | 1047576 | 32768 | In: $0.05, Out: $0.20, Cache Read: $0.01 | | openai/gpt-4o:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 128000 | 16384 | In: $1.25, Out: $5.00, Cache Read: $0.62 | | openai/gpt-4o-mini:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 128000 | 16384 | In: $0.08, Out: $0.30, Cache Read: $0.04 | | openai/gpt-5:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 400000 | 128000 | In: $0.62, Out: $5.00, Cache Read: $0.06 | | openai/gpt-5-codex:batch | openrouter | In: text, image; Out: text | streaming, function_calling, structured_output | 400000 | 128000 | In: $0.62, Out: $5.00, Cache Read: $0.06 | | openai/gpt-5-mini:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 400000 | 128000 | In: $0.12, Out: $1.00, Cache Read: $0.01 | | openai/gpt-5-nano:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 400000 | 128000 | In: $0.02, Out: $0.20, Cache Read: $0.00 | | openai/gpt-5-pro:batch | openrouter | In: image, text, file; Out: text | streaming, function_calling, structured_output | 400000 | 128000 | In: $7.50, Out: $60.00 | | openai/gpt-5.1:batch | openrouter | In: image, text, file; Out: text | streaming, function_calling, structured_output | 400000 | 128000 | In: $0.62, Out: $5.00, Cache Read: $0.06 | | openai/gpt-5.2:batch | openrouter | In: file, image, text; Out: text | streaming, function_calling, structured_output | 400000 | 128000 | In: $0.88, Out: $7.00, Cache Read: $0.09 | | openai/gpt-5.2-pro:batch | openrouter | In: image, text, file; Out: text | streaming, function_calling, structured_output | 400000 | 128000 | In: $10.50, Out: $84.00 | | openai/gpt-5.4:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 1050000 | 128000 | In: $1.25, Out: $7.50, Cache Read: $0.12 | | openai/gpt-5.4-mini:batch | openrouter | In: file, image, text; Out: text | streaming, function_calling, structured_output | 400000 | 128000 | In: $0.38, Out: $2.25, Cache Read: $0.04 | | openai/gpt-5.4-nano:batch | openrouter | In: file, image, text; Out: text | streaming, function_calling, structured_output | 400000 | 128000 | In: $0.10, Out: $0.62, Cache Read: $0.01 | | openai/gpt-5.4-pro:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 1050000 | 128000 | In: $15.00, Out: $90.00 | | openai/gpt-5.5:batch | openrouter | In: file, image, text; Out: text | streaming, function_calling, structured_output | 1050000 | 128000 | In: $2.50, Out: $15.00, Cache Read: $0.25 | | openai/gpt-5.5-pro:batch | openrouter | In: file, image, text; Out: text | streaming, function_calling, structured_output | 1050000 | 128000 | In: $15.00, Out: $90.00 | | openai/gpt-5.6-luna:batch | openrouter | In: file, image, text; Out: text | streaming, function_calling, structured_output | 1050000 | 128000 | In: $0.10, Out: $0.60, Cache Read: $0.01 | | openai/gpt-5.6-luna-pro:batch | openrouter | In: file, image, text; Out: text | streaming, function_calling, structured_output | 1050000 | 128000 | In: $0.10, Out: $0.60, Cache Read: $0.01 | | openai/gpt-5.6-sol:batch | openrouter | In: file, image, text; Out: text | streaming, function_calling, structured_output | 1050000 | 128000 | In: $2.50, Out: $15.00, Cache Read: $0.25 | | openai/gpt-5.6-sol-pro:batch | openrouter | In: file, image, text; Out: text | streaming, function_calling, structured_output | 1050000 | 128000 | In: $2.50, Out: $15.00, Cache Read: $0.25 | | openai/gpt-5.6-terra:batch | openrouter | In: file, image, text; Out: text | streaming, function_calling, structured_output | 1050000 | 128000 | In: $1.00, Out: $6.00, Cache Read: $0.10 | | openai/gpt-5.6-terra-pro:batch | openrouter | In: file, image, text; Out: text | streaming, function_calling, structured_output | 1050000 | 128000 | In: $1.00, Out: $6.00, Cache Read: $0.10 | | openai/o1:batch | openrouter | In: text, image, file; Out: text | streaming, function_calling, structured_output | 200000 | 100000 | In: $7.50, Out: $30.00, Cache Read: $3.75 | | openai/o1-pro:batch | openrouter | In: text, image, file; Out: text | streaming, structured_output | 200000 | 100000 | In: $75.00, Out: $300.00 | | openai/o3:batch | openrouter | In: image, text, file; Out: text | streaming, function_calling, structured_output | 200000 | 100000 | In: $1.00, Out: $4.00, Cache Read: $0.25 | | openai/o3-pro:batch | openrouter | In: text, file, image; Out: text | streaming, function_calling, structured_output | 200000 | 100000 | In: $10.00, Out: $40.00 | | openai/o4-mini:batch | openrouter | In: image, text, file; Out: text | streaming, function_calling, structured_output | 200000 | 100000 | In: $0.55, Out: $2.20, Cache Read: $0.14 | | openai/o4-mini-high:batch | openrouter | In: image, text, file; Out: text | streaming, function_calling, structured_output | 200000 | 100000 | In: $0.55, Out: $2.20, Cache Read: $0.14 | | perceptron/perceptron-mk1 | openrouter | In: text, image, video; Out: text | structured_output, reasoning, vision, video, streaming | 32768 | 8192 | In: $0.15, Out: $1.50 | | qwen/qwen2.5-vl-72b-instruct | openrouter | In: text, image; Out: text | structured_output, vision, streaming, predicted_outputs | 128000 | 128000 | In: $0.25, Out: $0.75 | | qwen/qwen3-vl-235b-a22b-instruct | openrouter | In: text, image; Out: text | function_calling, structured_output, vision, streaming, predicted_outputs | 262144 | 32768 | In: $0.21, Out: $1.90, Cache Read: $0.10 | | qwen/qwen3-vl-235b-a22b-thinking | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 131072 | 32768 | In: $0.40, Out: $4.00 | | qwen/qwen3-vl-30b-a3b-instruct | openrouter | In: text, image; Out: text | function_calling, structured_output, vision, streaming, predicted_outputs | 262144 | 16384 | In: $0.15, Out: $0.60 | | qwen/qwen3-vl-30b-a3b-thinking | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 262144 | 32768 | In: $0.20, Out: $2.40 | | qwen/qwen3-vl-32b-instruct | openrouter | In: text, image; Out: text | function_calling, structured_output, vision, streaming | 131072 | 32768 | In: $0.10, Out: $0.42 | | qwen/qwen3-vl-8b-instruct | openrouter | In: image, text; Out: text | function_calling, structured_output, vision, streaming, predicted_outputs | 262144 | 32768 | In: $0.12, Out: $0.46 | | qwen/qwen3-vl-8b-thinking | openrouter | In: image, text; Out: text | function_calling, structured_output, reasoning, vision, streaming | 131072 | 32768 | In: $0.18, Out: $2.10 | | qwen/qwen3.5-122b-a10b | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 262144 | 81920 | In: $0.29, Out: $2.40 | | qwen/qwen3.5-27b | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 262144 | 65536 | In: $0.20, Out: $1.56 | | qwen/qwen3.5-35b-a3b | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 262144 | 262144 | In: $0.14, Out: $1.00 | | qwen/qwen3.5-397b-a17b | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 262144 | 65536 | In: $0.39, Out: $2.34 | | qwen/qwen3.5-9b | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 262144 | 262144 | In: $0.10, Out: $0.15 | | qwen/qwen3.5-plus-02-15 | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1000000 | 65536 | In: $0.26, Out: $1.56 | | qwen/qwen3.5-plus-20260420 | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1000000 | 65536 | In: $0.30, Out: $1.80, Cache Write: $0.38 | | qwen/qwen3.5-flash-02-23 | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1000000 | 65536 | In: $0.06, Out: $0.26 | | qwen/qwen3.6-27b | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 262144 | 262144 | In: $0.60, Out: $3.60, Cache Read: $0.12 | | qwen/qwen3.6-35b-a3b | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 262144 | 262144 | In: $0.14, Out: $1.00, Cache Read: $0.05 | | qwen/qwen3.6-flash | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1000000 | 65536 | In: $0.19, Out: $1.12, Cache Write: $0.23 | | qwen/qwen3.6-plus | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1000000 | 65536 | In: $0.32, Out: $1.95, Cache Write: $0.41 | | qwen/qwen3.7-flash | openrouter | In: text, image, video; Out: text | function_calling, reasoning, vision, video, streaming | 1000000 | 65536 | In: $0.03, Out: $0.13, Cache Read: $0.01, Cache Write: $0.04 | | qwen/qwen3.7-plus | openrouter | In: text, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 131072 | In: $0.32, Out: $1.28, Cache Read: $0.06, Cache Write: $0.40 | | qwen/qwen3.8-max | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1000000 | 131072 | In: $2.00, Out: $6.00, Cache Read: $0.25, Cache Write: $2.50 | | rekaai/reka-edge | openrouter | In: image, text, video; Out: text | function_calling, structured_output, vision, video, streaming | 16384 | 16384 | In: $0.10, Out: $0.10 | | bytedance-seed/seed-1.6 | openrouter | In: image, text, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 262144 | 32768 | In: $0.25, Out: $2.00 | | bytedance-seed/seed-1.6-flash | openrouter | In: image, text, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 262144 | 32768 | In: $0.08, Out: $0.30 | | bytedance-seed/seed-2.0-lite | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 262144 | 131072 | In: $0.25, Out: $2.00 | | bytedance-seed/seed-2.0-mini | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 262144 | 131072 | In: $0.10, Out: $0.40 | | perplexity/sonar | openrouter | In: text, image; Out: text | vision, streaming | 127072 | 127072 | In: $1.00, Out: $1.00 | | perplexity/sonar-pro | openrouter | In: text, image; Out: text | vision, streaming | 200000 | 8000 | In: $3.00, Out: $15.00 | | perplexity/sonar-pro-search | openrouter | In: text, image; Out: text | structured_output, reasoning, vision, streaming | 200000 | 8000 | In: $3.00, Out: $15.00 | | perplexity/sonar-reasoning-pro | openrouter | In: text, image; Out: text | reasoning, vision, streaming | 128000 | 128000 | In: $2.00, Out: $8.00 | | stepfun/step-3.7-flash | openrouter | In: text, image, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 262144 | 256000 | In: $0.20, Out: $1.15, Cache Read: $0.04 | | thinkingmachines/inkling:batch | openrouter | In: text, image, audio; Out: text | streaming, function_calling, predicted_outputs | 524288 | - | In: $0.50, Out: $2.02, Cache Read: $0.08 | | bytedance/ui-tars-1.5-7b | openrouter | In: image, text; Out: text | structured_output, vision, streaming, predicted_outputs | 128000 | 2048 | In: $0.10, Out: $0.20, Cache Read: $0.10 | | openai/o1 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 100000 | In: $15.00, Out: $60.00, Cache Read: $7.50 | | openai/o1-pro | openrouter | In: text, image, pdf; Out: text | structured_output, reasoning, vision, streaming | 200000 | 100000 | In: $150.00, Out: $600.00 | | openai/o3 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 100000 | In: $2.00, Out: $8.00, Cache Read: $0.50 | | openai/o3-pro | openrouter | In: text, pdf, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 100000 | In: $20.00, Out: $80.00 | | openai/o4-mini-high | openrouter | In: image, text, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 100000 | In: $1.10, Out: $4.40, Cache Read: $0.28 | | openai/o4-mini | openrouter | In: image, text, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 100000 | In: $1.10, Out: $4.40, Cache Read: $0.28 | | sonar-pro | perplexity | In: text, image; Out: text | vision, citations | 200000 | 8192 | In: $3.00, Out: $15.00 | | sonar-reasoning-pro | perplexity | In: text, image; Out: text | reasoning, vision, citations | 128000 | 4096 | In: $2.00, Out: $8.00 | | claude-3-5-haiku | vertexai | In: text, image, pdf; Out: text | function_calling, vision | 200000 | 8192 | In: $0.80, Out: $4.00, Cache Read: $0.08, Cache Write: $1.00 | | claude-haiku-4-5 | vertexai | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 200000 | 64000 | In: $1.00, Out: $5.00, Cache Read: $0.10, Cache Write: $1.25 | | claude-opus-4 | vertexai | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 200000 | 32000 | In: $15.00, Out: $75.00, Cache Read: $1.50, Cache Write: $18.75 | | claude-opus-4-1 | vertexai | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 200000 | 32000 | In: $15.00, Out: $75.00, Cache Read: $1.50, Cache Write: $18.75 | | claude-opus-4-5 | vertexai | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 200000 | 64000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | claude-opus-4-6 | vertexai | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | claude-opus-4-7 | vertexai | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | claude-opus-4-8 | vertexai | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | claude-opus-5 | vertexai | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | claude-sonnet-4 | vertexai | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 200000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | claude-sonnet-4-5 | vertexai | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 200000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | claude-sonnet-4-6 | vertexai | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 1000000 | 128000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | claude-sonnet-5 | vertexai | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 1000000 | 128000 | In: $2.00, Out: $10.00, Cache Read: $0.20, Cache Write: $2.50 | | gemini-2.0-flash | vertexai | In: text, image, audio, video, pdf; Out: text | function_calling, structured_output, vision, video, streaming | 1048576 | 8192 | In: $0.10, Out: $0.40, Cache Read: $0.02 | | gemini-2.5-flash | vertexai | In: text, image, audio, video, pdf; Out: text | function_calling, reasoning, vision, video, streaming | 1048576 | 65536 | In: $0.30, Out: $2.50, Cache Read: $0.08, Cache Write: $0.38 | | gemini-2.5-flash-lite | vertexai | In: text, image, audio, video, pdf; Out: text | function_calling, reasoning, vision, video, streaming | 1048576 | 65536 | In: $0.10, Out: $0.40, Cache Read: $0.01 | | gemini-2.5-pro | vertexai | In: text, image, audio, video, pdf; Out: text | function_calling, reasoning, vision, video, streaming | 1048576 | 65536 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gemini-3-flash-preview | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $0.50, Out: $3.00, Cache Read: $0.05 | | gemini-3.1-flash-lite | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $0.25, Out: $1.50, Cache Read: $0.02 | | gemini-3.1-flash-lite-preview | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $0.25, Out: $1.50, Cache Read: $0.02 | | gemini-3.1-pro-preview | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $2.00, Out: $12.00, Cache Read: $0.20 | | gemini-3.1-pro-preview-customtools | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video | 1048576 | 65536 | In: $2.00, Out: $12.00, Cache Read: $0.20 | | gemini-3.5-flash | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $1.50, Out: $9.00, Cache Read: $0.15 | | gemini-3.5-flash-lite | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video | 1048576 | 65536 | In: $0.30, Out: $2.50, Cache Read: $0.03 | | gemini-3.6-flash | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video | 1048576 | 65536 | In: $1.50, Out: $7.50, Cache Read: $0.15 | | gemini-embedding-2 | vertexai | In: text, image, audio, video, pdf; Out: embeddings | vision, video, streaming | 8192 | 1 | In: $0.20, Out: $0.00 | | gemini-flash-latest | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video | 1048576 | 65536 | In: $1.50, Out: $9.00, Cache Read: $0.15 | | gemini-flash-lite-latest | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, reasoning, vision, video | 1048576 | 65536 | In: $0.25, Out: $1.50, Cache Read: $0.02 | | meta/llama-4-maverick-17b-128e-instruct-maas | vertexai | In: text, image; Out: text | function_calling, structured_output, vision | 524288 | 8192 | In: $0.35, Out: $1.15 | | gemini-2.5-flash-image | vertexai | In: text, image; Out: text, image | vision | 32768 | 32768 | In: $0.30, Out: $30.00 | | gemini-3.1-flash-image | vertexai | In: text, image, video, pdf; Out: text, image | reasoning, vision, video, streaming | 131072 | 32768 | In: $0.50, Out: $60.00 | | gemini-3.1-flash-image-preview | vertexai | In: text, image, pdf; Out: text, image | reasoning, vision, streaming | 65536 | 65536 | In: $0.50, Out: $60.00 | | gemini-3.1-flash-lite-image | vertexai | In: text, image; Out: text, image | function_calling, reasoning, vision, streaming | 65536 | 65536 | In: $0.25, Out: $30.00 | | gemini-3-pro-image | vertexai | In: text, image; Out: text, image | reasoning, vision, streaming | 65536 | 32768 | In: $2.00, Out: $120.00 | | grok-4.20-0309-non-reasoning | xai | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 1000000 | 30000 | In: $1.25, Out: $2.50, Cache Read: $0.20 | | grok-4.20-0309-reasoning | xai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 30000 | In: $1.25, Out: $2.50, Cache Read: $0.20 | | grok-4.20-multi-agent-0309 | xai | In: text, image, pdf; Out: text | structured_output, reasoning, vision, streaming | 1000000 | 30000 | In: $1.25, Out: $2.50, Cache Read: $0.20 | | grok-4.3 | xai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 30000 | In: $1.25, Out: $2.50, Cache Read: $0.20 | | grok-4.5 | xai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 500000 | 500000 | In: $2.00, Out: $6.00, Cache Read: $0.30 | | grok-build-0.1 | xai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 256000 | 256000 | In: $1.00, Out: $2.00, Cache Read: $0.20 | | grok-imagine-image | xai | In: text, image, pdf; Out: image | vision | 8000 | 0 | - | | grok-imagine-image-quality | xai | In: text, image, pdf; Out: image | vision | 8000 | 0 | - | | grok-imagine-video | xai | In: text, image, video, pdf; Out: video | vision, video | 1024 | 0 | - | | grok-imagine-video-1.5 | xai | In: text, image, audio, pdf; Out: video | vision | 1024 | 0 | - | ### Audio Input Models (80) Models that can process audio: | Model | Provider | I/O | Capabilities | Context | Max Output | Standard Pricing (per 1M tokens) | | :-- | :-- | :-- | :-- | --: | --: | :-- | | amazon.nova-2-sonic-v1:0 | bedrock | In: audio; Out: audio, text | streaming, function_calling | - | - | - | | mistral.voxtral-mini-3b-2507 | bedrock | In: audio, text; Out: text | function_calling, structured_output, streaming | 128000 | 4096 | In: $0.04, Out: $0.04 | | mistral.voxtral-small-24b-2507 | bedrock | In: text, audio; Out: text | function_calling, structured_output, streaming | 32000 | 8192 | In: $0.15, Out: $0.35 | | deep-research-max-preview-04-2026 | gemini | In: text, image, video, audio, pdf; Out: text, image | function_calling, reasoning, vision, video | 131072 | 65536 | In: $2.00, Out: $12.00, Cache Read: $0.20 | | deep-research-preview-04-2026 | gemini | In: text, image, video, audio, pdf; Out: text, image | function_calling, reasoning, vision, video | 131072 | 65536 | In: $2.00, Out: $12.00, Cache Read: $0.20 | | gemini-2.0-flash | gemini | In: text, image, audio, video, pdf; Out: text | function_calling, structured_output, vision, video, tool_choice | 1048576 | 8192 | In: $0.10, Out: $0.40, Cache Read: $0.02 | | gemini-2.0-flash-lite | gemini | In: text, image, audio, video, pdf; Out: text | function_calling, structured_output, vision, video | 1048576 | 8192 | In: $0.08, Out: $0.30 | | gemini-2.5-flash | gemini | In: text, image, audio, video, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, tool_choice | 1048576 | 65536 | In: $0.30, Out: $2.50, Cache Read: $0.03 | | gemini-2.5-flash-lite | gemini | In: text, image, audio, video, pdf; Out: text | function_calling, structured_output, reasoning, vision, video | 1048576 | 65536 | In: $0.10, Out: $0.40, Cache Read: $0.01 | | gemini-2.5-pro | gemini | In: text, image, audio, video, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, tool_choice | 1048576 | 65536 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gemini-3-flash-preview | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, tool_choice | 1048576 | 65536 | In: $0.50, Out: $3.00, Cache Read: $0.05 | | gemini-3-pro-preview | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, tool_choice | 1048576 | 65536 | In: $2.00, Out: $12.00, Cache Read: $0.20 | | gemini-3.1-flash-lite | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video | 1048576 | 65536 | In: $0.25, Out: $1.50, Cache Read: $0.02 | | gemini-3.1-flash-lite-preview | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video | 1048576 | 65536 | In: $0.25, Out: $1.50, Cache Read: $0.02 | | gemini-3.1-flash-live-preview | gemini | In: text, image, video, audio; Out: text, audio | function_calling, reasoning, vision, video | 131072 | 65536 | In: $0.75, Out: $4.50 | | gemini-3.1-pro-preview | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, tool_choice | 1048576 | 65536 | In: $2.00, Out: $12.00, Cache Read: $0.20 | | gemini-3.1-pro-preview-customtools | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, tool_choice | 1048576 | 65536 | In: $2.00, Out: $12.00, Cache Read: $0.20 | | gemini-3.5-flash | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, tool_choice | 1048576 | 65536 | In: $1.50, Out: $9.00, Cache Read: $0.15 | | gemini-3.5-flash-lite | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video | 1048576 | 65536 | In: $0.30, Out: $2.50, Cache Read: $0.03 | | gemini-3.5-live-translate-preview | gemini | In: audio; Out: audio, text | - | 16384 | 32768 | In: $3.50, Out: $21.00 | | gemini-3.6-flash | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, tool_choice | 1048576 | 65536 | In: $1.50, Out: $7.50, Cache Read: $0.15 | | gemini-embedding-2 | gemini | In: text, image, audio, video, pdf; Out: embeddings | vision, video, tool_choice | 8192 | 1 | In: $0.20, Out: $0.00 | | gemini-flash-latest | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, tool_choice | 1048576 | 65536 | In: $1.50, Out: $9.00, Cache Read: $0.15 | | gemini-flash-lite-latest | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video | 1048576 | 65536 | In: $0.25, Out: $1.50, Cache Read: $0.02 | | gemini-robotics-er-1.6-preview | gemini | In: text, image, video, audio; Out: text | function_calling, structured_output, reasoning, vision, video, tool_choice | 131072 | 65536 | In: $1.00, Out: $5.00 | | voxtral-mini-latest | mistral | In: audio; Out: text | streaming | 0 | 0 | - | | voxtral-small-latest | mistral | In: text, audio; Out: text | function_calling, streaming | 32000 | 32000 | In: $0.10, Out: $0.30 | | gpt-realtime-2.1 | openai | In: text, audio, image; Out: text, audio | function_calling, reasoning, vision | 128000 | 32000 | In: $4.00, Out: $24.00, Cache Read: $0.40 | | openrouter/auto | openrouter | In: text, image, audio, pdf, video; Out: text, image | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 2000000 | 2000000 | - | | openrouter/auto-beta | openrouter | In: text, image, audio, file, video; Out: text, image | streaming, function_calling, structured_output, predicted_outputs | 2000000 | - | - | | openai/gpt-audio | openrouter | In: text, audio; Out: text, audio | function_calling, structured_output, streaming | 128000 | 16384 | In: $2.50, Out: $10.00 | | openai/gpt-audio-mini | openrouter | In: text, audio; Out: text, audio | function_calling, structured_output, streaming | 128000 | 16384 | In: $0.60, Out: $2.40 | | google/gemini-2.5-flash | openrouter | In: text, image, audio, video, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65535 | In: $0.30, Out: $2.50, Cache Read: $0.03, Cache Write: $0.08 | | google/gemini-2.5-flash-lite | openrouter | In: text, image, audio, video, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65535 | In: $0.10, Out: $0.40, Cache Read: $0.01, Cache Write: $0.08 | | google/gemini-2.5-pro | openrouter | In: text, image, audio, video, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $1.25, Out: $10.00, Cache Read: $0.12, Cache Write: $0.38 | | google/gemini-2.5-pro-preview-05-06 | openrouter | In: text, image, pdf, audio, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65535 | In: $1.25, Out: $10.00, Cache Read: $0.12, Cache Write: $0.38 | | google/gemini-2.5-pro-preview | openrouter | In: pdf, image, text, audio; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1048576 | 65536 | In: $1.25, Out: $10.00, Cache Read: $0.12, Cache Write: $0.38 | | google/gemini-3-flash-preview | openrouter | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $0.50, Out: $3.00, Cache Read: $0.05, Cache Write: $0.08 | | google/gemini-3.1-flash-lite | openrouter | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $0.25, Out: $1.50, Cache Read: $0.02, Cache Write: $0.08 | | google/gemini-3.1-flash-lite-preview | openrouter | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $0.25, Out: $1.50, Cache Read: $0.02, Cache Write: $0.08 | | google/gemini-3.1-pro-preview | openrouter | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $2.00, Out: $12.00, Cache Read: $0.20, Cache Write: $0.38 | | google/gemini-3.1-pro-preview-customtools | openrouter | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $2.00, Out: $12.00, Cache Read: $0.20, Cache Write: $0.38 | | google/gemini-3.5-flash | openrouter | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $1.50, Out: $9.00, Cache Read: $0.15, Cache Write: $0.08 | | google/gemini-3.5-flash-lite | openrouter | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $0.30, Out: $2.50, Cache Read: $0.03, Cache Write: $0.08 | | google/gemini-3.6-flash | openrouter | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $1.50, Out: $7.50, Cache Read: $0.15, Cache Write: $0.08 | | ~google/gemini-flash-latest | openrouter | In: text, image, video, pdf, audio; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $1.50, Out: $7.50, Cache Read: $0.15, Cache Write: $0.08 | | ~google/gemini-pro-latest | openrouter | In: audio, pdf, image, text, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $2.00, Out: $12.00, Cache Read: $0.20, Cache Write: $0.38 | | google/gemini-2.5-flash:batch | openrouter | In: file, image, text, audio, video; Out: text | streaming, function_calling, structured_output | 1048576 | 65535 | In: $0.15, Out: $1.25, Cache Read: $0.03 | | google/gemini-2.5-flash-lite:batch | openrouter | In: text, image, file, audio, video; Out: text | streaming, function_calling, structured_output | 1048576 | 65535 | In: $0.05, Out: $0.20, Cache Read: $0.01 | | google/gemini-2.5-pro:batch | openrouter | In: text, image, file, audio, video; Out: text | streaming, function_calling, structured_output | 1048576 | 65536 | In: $0.62, Out: $5.00, Cache Read: $0.12 | | google/gemini-3-flash-preview:batch | openrouter | In: text, image, file, audio, video; Out: text | streaming, function_calling, structured_output | 1048576 | 65536 | In: $0.25, Out: $1.50 | | google/gemini-3.1-flash-lite:batch | openrouter | In: text, image, video, file, audio; Out: text | streaming, function_calling, structured_output | 1048576 | 65536 | In: $0.12, Out: $0.75, Cache Read: $0.01 | | google/gemini-3.1-pro-preview:batch | openrouter | In: audio, file, image, text, video; Out: text | streaming, function_calling, structured_output | 1048576 | 65536 | In: $1.00, Out: $6.00 | | google/gemini-3.5-flash:batch | openrouter | In: text, image, video, file, audio; Out: text | streaming, function_calling, structured_output | 1048576 | 65536 | In: $0.75, Out: $4.50, Cache Read: $0.08 | | google/gemini-3.5-flash-lite:batch | openrouter | In: text, image, video, file, audio; Out: text | streaming, function_calling, structured_output | 1048576 | 65536 | In: $0.15, Out: $1.25, Cache Read: $0.02 | | google/gemini-3.6-flash:batch | openrouter | In: text, image, video, file, audio; Out: text | streaming, function_calling, structured_output | 1048576 | 65536 | In: $0.75, Out: $3.75, Cache Read: $0.08 | | thinkingmachines/inkling | openrouter | In: text, image, audio; Out: text | function_calling, reasoning, vision, streaming, predicted_outputs | 1048576 | 1048576 | In: $1.00, Out: $4.05, Cache Read: $0.17 | | thinkingmachines/inkling-small | openrouter | In: text, image, audio; Out: text | function_calling, reasoning, vision, streaming, predicted_outputs | 524288 | 262144 | In: $0.45, Out: $1.20, Cache Read: $0.10 | | xiaomi/mimo-v2.5 | openrouter | In: text, image, audio, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 1050000 | 131072 | In: $0.14, Out: $0.28, Cache Read: $0.00 | | meta/muse-spark-1.1 | openrouter | In: text, image, video, pdf, audio; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 1048576 | In: $1.25, Out: $4.25, Cache Read: $0.15 | | meta/muse-spark-1.2 | openrouter | In: text, image, video, pdf, audio; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 1048576 | In: $1.25, Out: $4.25, Cache Read: $0.15 | | nvidia/nemotron-3-nano-omni-30b-a3b-reasoning:free | openrouter | In: text, image, video, audio; Out: text | function_calling, reasoning, vision, video, streaming | 256000 | 65536 | In: $0.00, Out: $0.00 | | thinkingmachines/inkling:batch | openrouter | In: text, image, audio; Out: text | streaming, function_calling, predicted_outputs | 524288 | - | In: $0.50, Out: $2.02, Cache Read: $0.08 | | mistralai/voxtral-small-24b-2507 | openrouter | In: text, audio, pdf; Out: text | function_calling, structured_output, vision, streaming | 32000 | 32000 | In: $0.10, Out: $0.30, Cache Read: $0.01 | | gemini-2.0-flash | vertexai | In: text, image, audio, video, pdf; Out: text | function_calling, structured_output, vision, video, streaming | 1048576 | 8192 | In: $0.10, Out: $0.40, Cache Read: $0.02 | | gemini-2.5-flash | vertexai | In: text, image, audio, video, pdf; Out: text | function_calling, reasoning, vision, video, streaming | 1048576 | 65536 | In: $0.30, Out: $2.50, Cache Read: $0.08, Cache Write: $0.38 | | gemini-2.5-flash-lite | vertexai | In: text, image, audio, video, pdf; Out: text | function_calling, reasoning, vision, video, streaming | 1048576 | 65536 | In: $0.10, Out: $0.40, Cache Read: $0.01 | | gemini-2.5-pro | vertexai | In: text, image, audio, video, pdf; Out: text | function_calling, reasoning, vision, video, streaming | 1048576 | 65536 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gemini-3-flash-preview | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $0.50, Out: $3.00, Cache Read: $0.05 | | gemini-3.1-flash-lite | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $0.25, Out: $1.50, Cache Read: $0.02 | | gemini-3.1-flash-lite-preview | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $0.25, Out: $1.50, Cache Read: $0.02 | | gemini-3.1-pro-preview | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $2.00, Out: $12.00, Cache Read: $0.20 | | gemini-3.1-pro-preview-customtools | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video | 1048576 | 65536 | In: $2.00, Out: $12.00, Cache Read: $0.20 | | gemini-3.5-flash | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $1.50, Out: $9.00, Cache Read: $0.15 | | gemini-3.5-flash-lite | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video | 1048576 | 65536 | In: $0.30, Out: $2.50, Cache Read: $0.03 | | gemini-3.6-flash | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video | 1048576 | 65536 | In: $1.50, Out: $7.50, Cache Read: $0.15 | | gemini-embedding-2 | vertexai | In: text, image, audio, video, pdf; Out: embeddings | vision, video, streaming | 8192 | 1 | In: $0.20, Out: $0.00 | | gemini-flash-latest | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video | 1048576 | 65536 | In: $1.50, Out: $9.00, Cache Read: $0.15 | | gemini-flash-lite-latest | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, reasoning, vision, video | 1048576 | 65536 | In: $0.25, Out: $1.50, Cache Read: $0.02 | | grok-imagine-video-1.5 | xai | In: text, image, audio, pdf; Out: video | vision | 1024 | 0 | - | ### PDF Models (253) Models that can process PDF documents: | Model | Provider | I/O | Capabilities | Context | Max Output | Standard Pricing (per 1M tokens) | | :-- | :-- | :-- | :-- | --: | --: | :-- | | claude-fable-5 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, citations, tool_choice, parallel_tool_calls | 1000000 | 128000 | In: $10.00, Out: $50.00, Cache Read: $1.00, Cache Write: $12.50 | | claude-haiku-4-5-20251001 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, citations, tool_choice, parallel_tool_calls | 200000 | 64000 | In: $1.00, Out: $5.00, Cache Read: $0.10, Cache Write: $1.25 | | claude-haiku-4-5 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $1.00, Out: $5.00, Cache Read: $0.10, Cache Write: $1.25 | | claude-opus-4-5-20251101 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, citations, tool_choice, parallel_tool_calls | 200000 | 64000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | claude-opus-4-5 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | claude-opus-4-6 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, citations, tool_choice, parallel_tool_calls | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | claude-opus-4-7 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, citations, tool_choice, parallel_tool_calls | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | claude-opus-4-8 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, citations, tool_choice, parallel_tool_calls | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | claude-opus-5 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, citations, tool_choice, parallel_tool_calls | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | claude-sonnet-4-5-20250929 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, citations, tool_choice, parallel_tool_calls | 1000000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | claude-sonnet-4-5 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | claude-sonnet-4-6 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, citations, tool_choice, parallel_tool_calls | 1000000 | 128000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | claude-sonnet-5 | anthropic | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, citations, tool_choice, parallel_tool_calls | 1000000 | 128000 | In: $2.00, Out: $10.00, Cache Read: $0.20, Cache Write: $2.50 | | au.anthropic.claude-opus-4-6-v1 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 128000 | In: $16.50, Out: $82.50, Cache Read: $1.65, Cache Write: $20.62 | | au.anthropic.claude-sonnet-4-6 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 128000 | In: $3.30, Out: $16.50, Cache Read: $0.33, Cache Write: $4.12 | | anthropic.claude-fable-5 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $10.00, Out: $50.00, Cache Read: $1.00, Cache Write: $12.50 | | eu.anthropic.claude-fable-5 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $11.00, Out: $55.00, Cache Read: $1.10, Cache Write: $13.75 | | global.anthropic.claude-fable-5 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $10.00, Out: $50.00, Cache Read: $1.00, Cache Write: $12.50 | | us.anthropic.claude-fable-5 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 1000000 | 128000 | In: $10.00, Out: $50.00, Cache Read: $1.00, Cache Write: $12.50 | | anthropic.claude-haiku-4-5-20251001-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $1.00, Out: $5.00, Cache Read: $0.10, Cache Write: $1.25 | | au.anthropic.claude-haiku-4-5-20251001-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $1.00, Out: $5.00, Cache Read: $0.10, Cache Write: $1.25 | | eu.anthropic.claude-haiku-4-5-20251001-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $1.10, Out: $5.50, Cache Read: $0.11, Cache Write: $1.38 | | global.anthropic.claude-haiku-4-5-20251001-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $1.00, Out: $5.00, Cache Read: $0.10, Cache Write: $1.25 | | jp.anthropic.claude-haiku-4-5-20251001-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $1.00, Out: $5.00, Cache Read: $0.10, Cache Write: $1.25 | | us.anthropic.claude-haiku-4-5-20251001-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 64000 | In: $1.00, Out: $5.00, Cache Read: $0.10, Cache Write: $1.25 | | anthropic.claude-opus-4-1-20250805-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 200000 | 32000 | In: $15.00, Out: $75.00, Cache Read: $1.50, Cache Write: $18.75 | | us.anthropic.claude-opus-4-1-20250805-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 200000 | 32000 | In: $15.00, Out: $75.00, Cache Read: $1.50, Cache Write: $18.75 | | anthropic.claude-opus-4-5-20251101-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | eu.anthropic.claude-opus-4-5-20251101-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $5.50, Out: $27.50, Cache Read: $0.55, Cache Write: $6.88 | | global.anthropic.claude-opus-4-5-20251101-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | us.anthropic.claude-opus-4-5-20251101-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 64000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | anthropic.claude-opus-4-6-v1 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | eu.anthropic.claude-opus-4-6-v1 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 128000 | In: $5.50, Out: $27.50, Cache Read: $0.55, Cache Write: $6.88 | | global.anthropic.claude-opus-4-6-v1 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | us.anthropic.claude-opus-4-6-v1 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | anthropic.claude-opus-4-7 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | eu.anthropic.claude-opus-4-7 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $5.50, Out: $27.50, Cache Read: $0.55, Cache Write: $6.88 | | global.anthropic.claude-opus-4-7 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | jp.anthropic.claude-opus-4-7 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | us.anthropic.claude-opus-4-7 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | anthropic.claude-opus-4-8 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | au.anthropic.claude-opus-4-8 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | eu.anthropic.claude-opus-4-8 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $5.50, Out: $27.50, Cache Read: $0.55, Cache Write: $6.88 | | global.anthropic.claude-opus-4-8 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | jp.anthropic.claude-opus-4-8 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | us.anthropic.claude-opus-4-8 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | anthropic.claude-opus-5 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | au.anthropic.claude-opus-5 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | eu.anthropic.claude-opus-5 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $5.50, Out: $27.50, Cache Read: $0.55, Cache Write: $6.88 | | global.anthropic.claude-opus-5 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | jp.anthropic.claude-opus-5 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | us.anthropic.claude-opus-5 | bedrock | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | anthropic.claude-sonnet-4-5-20250929-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | au.anthropic.claude-sonnet-4-5-20250929-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | eu.anthropic.claude-sonnet-4-5-20250929-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $3.30, Out: $16.50, Cache Read: $0.33, Cache Write: $4.12 | | global.anthropic.claude-sonnet-4-5-20250929-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | jp.anthropic.claude-sonnet-4-5-20250929-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | us.anthropic.claude-sonnet-4-5-20250929-v1:0 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | anthropic.claude-sonnet-4-6 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | eu.anthropic.claude-sonnet-4-6 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 64000 | In: $3.30, Out: $16.50, Cache Read: $0.33, Cache Write: $4.12 | | global.anthropic.claude-sonnet-4-6 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | jp.anthropic.claude-sonnet-4-6 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | us.anthropic.claude-sonnet-4-6 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | anthropic.claude-sonnet-5 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 128000 | In: $2.00, Out: $10.00, Cache Read: $0.20, Cache Write: $2.50 | | au.anthropic.claude-sonnet-5 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 128000 | In: $2.00, Out: $10.00, Cache Read: $0.20, Cache Write: $2.50 | | eu.anthropic.claude-sonnet-5 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 128000 | In: $2.20, Out: $11.00, Cache Read: $0.22, Cache Write: $2.75 | | global.anthropic.claude-sonnet-5 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 128000 | In: $2.00, Out: $10.00, Cache Read: $0.20, Cache Write: $2.50 | | jp.anthropic.claude-sonnet-5 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1000000 | 128000 | In: $2.00, Out: $10.00, Cache Read: $0.20, Cache Write: $2.50 | | us.anthropic.claude-sonnet-5 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $2.00, Out: $10.00, Cache Read: $0.20, Cache Write: $2.50 | | openai.gpt-5.4 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 272000 | 128000 | In: $2.75, Out: $16.50, Cache Read: $0.28 | | openai.gpt-5.5 | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 272000 | 128000 | In: $5.50, Out: $33.00, Cache Read: $0.55 | | openai.gpt-5.6-luna | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 272000 | 128000 | In: $0.22, Out: $1.32, Cache Read: $0.02, Cache Write: $0.28 | | openai.gpt-5.6-sol | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 272000 | 128000 | In: $5.50, Out: $33.00, Cache Read: $0.55, Cache Write: $6.88 | | openai.gpt-5.6-terra | bedrock | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 272000 | 128000 | In: $2.20, Out: $13.20, Cache Read: $0.22, Cache Write: $2.75 | | deep-research-max-preview-04-2026 | gemini | In: text, image, video, audio, pdf; Out: text, image | function_calling, reasoning, vision, video | 131072 | 65536 | In: $2.00, Out: $12.00, Cache Read: $0.20 | | deep-research-preview-04-2026 | gemini | In: text, image, video, audio, pdf; Out: text, image | function_calling, reasoning, vision, video | 131072 | 65536 | In: $2.00, Out: $12.00, Cache Read: $0.20 | | gemini-2.0-flash | gemini | In: text, image, audio, video, pdf; Out: text | function_calling, structured_output, vision, video, tool_choice | 1048576 | 8192 | In: $0.10, Out: $0.40, Cache Read: $0.02 | | gemini-2.0-flash-lite | gemini | In: text, image, audio, video, pdf; Out: text | function_calling, structured_output, vision, video | 1048576 | 8192 | In: $0.08, Out: $0.30 | | gemini-2.5-flash | gemini | In: text, image, audio, video, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, tool_choice | 1048576 | 65536 | In: $0.30, Out: $2.50, Cache Read: $0.03 | | gemini-2.5-flash-lite | gemini | In: text, image, audio, video, pdf; Out: text | function_calling, structured_output, reasoning, vision, video | 1048576 | 65536 | In: $0.10, Out: $0.40, Cache Read: $0.01 | | gemini-2.5-pro | gemini | In: text, image, audio, video, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, tool_choice | 1048576 | 65536 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gemini-3-flash-preview | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, tool_choice | 1048576 | 65536 | In: $0.50, Out: $3.00, Cache Read: $0.05 | | gemini-3-pro-preview | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, tool_choice | 1048576 | 65536 | In: $2.00, Out: $12.00, Cache Read: $0.20 | | gemini-3.1-flash-lite | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video | 1048576 | 65536 | In: $0.25, Out: $1.50, Cache Read: $0.02 | | gemini-3.1-flash-lite-preview | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video | 1048576 | 65536 | In: $0.25, Out: $1.50, Cache Read: $0.02 | | gemini-3.1-pro-preview | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, tool_choice | 1048576 | 65536 | In: $2.00, Out: $12.00, Cache Read: $0.20 | | gemini-3.1-pro-preview-customtools | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, tool_choice | 1048576 | 65536 | In: $2.00, Out: $12.00, Cache Read: $0.20 | | gemini-3.5-flash | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, tool_choice | 1048576 | 65536 | In: $1.50, Out: $9.00, Cache Read: $0.15 | | gemini-3.5-flash-lite | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video | 1048576 | 65536 | In: $0.30, Out: $2.50, Cache Read: $0.03 | | gemini-3.6-flash | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, tool_choice | 1048576 | 65536 | In: $1.50, Out: $7.50, Cache Read: $0.15 | | gemini-embedding-2 | gemini | In: text, image, audio, video, pdf; Out: embeddings | vision, video, tool_choice | 8192 | 1 | In: $0.20, Out: $0.00 | | gemini-flash-latest | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, tool_choice | 1048576 | 65536 | In: $1.50, Out: $9.00, Cache Read: $0.15 | | gemini-flash-lite-latest | gemini | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video | 1048576 | 65536 | In: $0.25, Out: $1.50, Cache Read: $0.02 | | gemini-3.1-flash-image | gemini | In: text, image, video, pdf; Out: text, image | reasoning, vision, video, tool_choice | 65536 | 65536 | In: $0.50, Out: $60.00 | | gemini-3.1-flash-image-preview | gemini | In: text, image, pdf; Out: text, image | reasoning, vision, tool_choice | 65536 | 65536 | In: $0.50, Out: $60.00 | | gpt-4.1 | openai | In: text, image, pdf; Out: text | function_calling, structured_output, vision, tool_choice, parallel_tool_calls | 1047576 | 32768 | In: $2.00, Out: $8.00, Cache Read: $0.50 | | gpt-4.1-mini | openai | In: text, image, pdf; Out: text | function_calling, structured_output, vision, tool_choice, parallel_tool_calls | 1047576 | 32768 | In: $0.40, Out: $1.60, Cache Read: $0.10 | | gpt-4o | openai | In: text, image, pdf; Out: text | function_calling, structured_output, vision, tool_choice, parallel_tool_calls | 128000 | 16384 | In: $2.50, Out: $10.00, Cache Read: $1.25 | | gpt-4o-mini | openai | In: text, image, pdf; Out: text | function_calling, structured_output, vision, tool_choice, parallel_tool_calls | 128000 | 16384 | In: $0.15, Out: $0.60, Cache Read: $0.08 | | gpt-5.3-codex | openai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 400000 | 128000 | In: $1.75, Out: $14.00, Cache Read: $0.18 | | gpt-5.3-codex-spark | openai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 128000 | 32000 | In: $1.75, Out: $14.00, Cache Read: $0.18 | | gpt-5.4 | openai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 1050000 | 128000 | In: $2.50, Out: $15.00, Cache Read: $0.25 | | gpt-5.5 | openai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 1050000 | 128000 | In: $5.00, Out: $30.00, Cache Read: $0.50 | | gpt-5.5-pro | openai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 1050000 | 128000 | In: $30.00, Out: $180.00 | | gpt-5.6 | openai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 1050000 | 128000 | In: $5.00, Out: $30.00, Cache Read: $0.50, Cache Write: $6.25 | | gpt-5.6-luna | openai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 1050000 | 128000 | In: $0.20, Out: $1.20, Cache Read: $0.02, Cache Write: $0.25 | | gpt-5.6-sol | openai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 1050000 | 128000 | In: $5.00, Out: $30.00, Cache Read: $0.50, Cache Write: $6.25 | | gpt-5.6-terra | openai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 1050000 | 128000 | In: $2.00, Out: $12.00, Cache Read: $0.20, Cache Write: $2.50 | | o1 | openai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, tool_choice, parallel_tool_calls | 200000 | 100000 | In: $15.00, Out: $60.00, Cache Read: $7.50 | | o3 | openai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 100000 | In: $2.00, Out: $8.00, Cache Read: $0.50 | | ~anthropic/claude-haiku-latest | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 64000 | In: $1.00, Out: $5.00, Cache Read: $0.10, Cache Write: $1.25 | | ~anthropic/claude-sonnet-latest | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $2.00, Out: $10.00, Cache Read: $0.20, Cache Write: $2.50 | | openrouter/auto | openrouter | In: text, image, audio, pdf, video; Out: text, image | function_calling, structured_output, reasoning, vision, video, streaming, predicted_outputs | 2000000 | 2000000 | - | | anthropic/claude-fable-5 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $10.00, Out: $50.00, Cache Read: $1.00, Cache Write: $12.50 | | ~anthropic/claude-fable-latest | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $10.00, Out: $50.00, Cache Read: $1.00, Cache Write: $12.50 | | anthropic/claude-haiku-4.5 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 64000 | In: $1.00, Out: $5.00, Cache Read: $0.10, Cache Write: $1.25 | | anthropic/claude-opus-4 | openrouter | In: image, text, pdf; Out: text | function_calling, reasoning, vision, streaming | 200000 | 32000 | In: $15.00, Out: $75.00, Cache Read: $1.50, Cache Write: $18.75 | | anthropic/claude-opus-4.1 | openrouter | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 200000 | 32000 | In: $15.00, Out: $75.00, Cache Read: $1.50, Cache Write: $18.75 | | anthropic/claude-opus-4.5 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 64000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | anthropic/claude-opus-4.6 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | anthropic/claude-opus-4.7 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | anthropic/claude-opus-4.7-fast | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $30.00, Out: $150.00, Cache Read: $3.00, Cache Write: $37.50 | | anthropic/claude-opus-4.8 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | anthropic/claude-opus-4.8-fast | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $10.00, Out: $50.00, Cache Read: $1.00, Cache Write: $12.50 | | anthropic/claude-opus-5 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | anthropic/claude-opus-5-fast | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $10.00, Out: $50.00, Cache Read: $1.00, Cache Write: $12.50 | | ~anthropic/claude-opus-latest | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | anthropic/claude-sonnet-4 | openrouter | In: image, text, pdf; Out: text | function_calling, reasoning, vision, streaming | 1000000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | anthropic/claude-sonnet-4.5 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | anthropic/claude-sonnet-4.6 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | anthropic/claude-sonnet-5 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 128000 | In: $2.00, Out: $10.00, Cache Read: $0.20, Cache Write: $2.50 | | mistralai/codestral-2508 | openrouter | In: text, pdf; Out: text | function_calling, structured_output, vision, streaming | 256000 | 256000 | In: $0.30, Out: $0.90, Cache Read: $0.03 | | openai/gpt-chat-latest | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 400000 | 128000 | In: $5.00, Out: $30.00, Cache Read: $0.50 | | openai/gpt-4.1 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 1047576 | 32768 | In: $2.00, Out: $8.00, Cache Read: $0.50 | | openai/gpt-4.1-mini | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 1047576 | 32768 | In: $0.40, Out: $1.60, Cache Read: $0.10 | | openai/gpt-4.1-nano | openrouter | In: image, text, pdf; Out: text | function_calling, structured_output, vision, streaming | 1047576 | 32768 | In: $0.10, Out: $0.40, Cache Read: $0.02 | | openai/gpt-4o | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 128000 | 16384 | In: $2.50, Out: $10.00, Cache Read: $1.25 | | openai/gpt-4o-2024-05-13 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 128000 | 4096 | In: $5.00, Out: $15.00 | | openai/gpt-4o-2024-08-06 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 128000 | 16384 | In: $2.50, Out: $10.00, Cache Read: $1.25 | | openai/gpt-4o-2024-11-20 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 128000 | 16384 | In: $2.50, Out: $10.00, Cache Read: $1.25 | | openai/gpt-4o-mini | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 128000 | 16384 | In: $0.15, Out: $0.60, Cache Read: $0.08 | | openai/gpt-4o-mini-2024-07-18 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 128000 | 16384 | In: $0.15, Out: $0.60, Cache Read: $0.08 | | openai/gpt-5 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | openai/gpt-5-image | openrouter | In: image, text, pdf; Out: image, text | structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $10.00, Out: $10.00, Cache Read: $1.25 | | openai/gpt-5-image-mini | openrouter | In: pdf, image, text; Out: image, text | structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $2.50, Out: $2.00, Cache Read: $0.25 | | openai/gpt-5-mini | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $0.25, Out: $2.00, Cache Read: $0.02 | | openai/gpt-5-nano | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $0.05, Out: $0.40, Cache Read: $0.01 | | openai/gpt-5-pro | openrouter | In: image, text, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $15.00, Out: $120.00 | | openai/gpt-5.1 | openrouter | In: image, text, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | openai/gpt-5.2 | openrouter | In: pdf, image, text; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $1.75, Out: $14.00, Cache Read: $0.18 | | openai/gpt-5.2-chat | openrouter | In: pdf, image, text; Out: text | function_calling, structured_output, vision, streaming | 128000 | 16384 | In: $1.75, Out: $14.00, Cache Read: $0.18 | | openai/gpt-5.2-pro | openrouter | In: image, text, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $21.00, Out: $168.00 | | openai/gpt-5.3-chat | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 128000 | 16384 | In: $1.75, Out: $14.00, Cache Read: $0.18 | | openai/gpt-5.3-codex | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $1.75, Out: $14.00, Cache Read: $0.18 | | openai/gpt-5.4 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $2.50, Out: $15.00, Cache Read: $0.25 | | openai/gpt-5.4-image-2 | openrouter | In: image, text, pdf; Out: image, text | structured_output, reasoning, vision, streaming | 272000 | 128000 | In: $8.00, Out: $15.00, Cache Read: $2.00 | | openai/gpt-5.4-pro | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $30.00, Out: $180.00 | | openai/gpt-5.4-mini | openrouter | In: pdf, image, text; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $0.75, Out: $4.50, Cache Read: $0.08 | | openai/gpt-5.4-nano | openrouter | In: pdf, image, text; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $0.20, Out: $1.25, Cache Read: $0.02 | | openai/gpt-5.5 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $5.00, Out: $30.00, Cache Read: $0.50 | | openai/gpt-5.5-pro | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $30.00, Out: $180.00 | | openai/gpt-5.6-luna | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $0.10, Out: $0.60, Cache Read: $0.01, Cache Write: $0.12 | | openai/gpt-5.6-luna-pro | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $0.10, Out: $0.60, Cache Read: $0.01, Cache Write: $0.12 | | openai/gpt-5.6-sol | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $5.00, Out: $30.00, Cache Read: $0.50, Cache Write: $6.25 | | openai/gpt-5.6-sol-pro | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $5.00, Out: $30.00, Cache Read: $0.50, Cache Write: $6.25 | | openai/gpt-5.6-terra | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $1.00, Out: $6.00, Cache Read: $0.10, Cache Write: $1.25 | | openai/gpt-5.6-terra-pro | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $1.00, Out: $6.00, Cache Read: $0.10, Cache Write: $1.25 | | google/gemini-2.5-flash | openrouter | In: text, image, audio, video, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65535 | In: $0.30, Out: $2.50, Cache Read: $0.03, Cache Write: $0.08 | | google/gemini-2.5-flash-lite | openrouter | In: text, image, audio, video, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65535 | In: $0.10, Out: $0.40, Cache Read: $0.01, Cache Write: $0.08 | | google/gemini-2.5-pro | openrouter | In: text, image, audio, video, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $1.25, Out: $10.00, Cache Read: $0.12, Cache Write: $0.38 | | google/gemini-2.5-pro-preview-05-06 | openrouter | In: text, image, pdf, audio, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65535 | In: $1.25, Out: $10.00, Cache Read: $0.12, Cache Write: $0.38 | | google/gemini-2.5-pro-preview | openrouter | In: pdf, image, text, audio; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1048576 | 65536 | In: $1.25, Out: $10.00, Cache Read: $0.12, Cache Write: $0.38 | | google/gemini-3-flash-preview | openrouter | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $0.50, Out: $3.00, Cache Read: $0.05, Cache Write: $0.08 | | google/gemini-3.1-flash-lite | openrouter | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $0.25, Out: $1.50, Cache Read: $0.02, Cache Write: $0.08 | | google/gemini-3.1-flash-lite-preview | openrouter | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $0.25, Out: $1.50, Cache Read: $0.02, Cache Write: $0.08 | | google/gemini-3.1-pro-preview | openrouter | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $2.00, Out: $12.00, Cache Read: $0.20, Cache Write: $0.38 | | google/gemini-3.1-pro-preview-customtools | openrouter | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $2.00, Out: $12.00, Cache Read: $0.20, Cache Write: $0.38 | | google/gemini-3.5-flash | openrouter | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $1.50, Out: $9.00, Cache Read: $0.15, Cache Write: $0.08 | | google/gemini-3.5-flash-lite | openrouter | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $0.30, Out: $2.50, Cache Read: $0.03, Cache Write: $0.08 | | google/gemini-3.6-flash | openrouter | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $1.50, Out: $7.50, Cache Read: $0.15, Cache Write: $0.08 | | ~google/gemini-flash-latest | openrouter | In: text, image, video, pdf, audio; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $1.50, Out: $7.50, Cache Read: $0.15, Cache Write: $0.08 | | ~google/gemini-pro-latest | openrouter | In: audio, pdf, image, text, video; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $2.00, Out: $12.00, Cache Read: $0.20, Cache Write: $0.38 | | x-ai/grok-4.20 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 2000000 | 2000000 | In: $1.25, Out: $2.50, Cache Read: $0.20 | | x-ai/grok-4.20-multi-agent | openrouter | In: text, image, pdf; Out: text | structured_output, reasoning, vision, streaming | 2000000 | 2000000 | In: $1.25, Out: $2.50, Cache Read: $0.20 | | x-ai/grok-4.3 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 1000000 | In: $1.25, Out: $2.50, Cache Read: $0.20 | | x-ai/grok-4.5 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 500000 | 500000 | In: $2.00, Out: $6.00, Cache Read: $0.30 | | x-ai/grok-build-0.1 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 256000 | 256000 | In: $1.00, Out: $2.00, Cache Read: $0.20 | | ~x-ai/grok-latest | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 500000 | 1000000 | In: $2.00, Out: $6.00, Cache Read: $0.30 | | mistralai/mistral-large | openrouter | In: text, pdf; Out: text | function_calling, structured_output, vision, streaming | 128000 | 128000 | In: $2.00, Out: $6.00, Cache Read: $0.20 | | mistralai/mistral-large-2407 | openrouter | In: text, pdf; Out: text | function_calling, structured_output, vision, streaming | 131072 | 131072 | In: $2.00, Out: $6.00, Cache Read: $0.20 | | mistralai/mistral-large-2512 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 262144 | 262144 | In: $0.50, Out: $1.50, Cache Read: $0.05 | | mistralai/mistral-medium-3 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 131072 | 131072 | In: $0.40, Out: $2.00, Cache Read: $0.04 | | mistralai/mistral-medium-3.1 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 131072 | 262144 | In: $0.40, Out: $2.00, Cache Read: $0.04 | | mistralai/mistral-medium-3-5 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 262144 | 262144 | In: $1.50, Out: $7.50 | | mistralai/mixtral-8x22b-instruct | openrouter | In: text, pdf; Out: text | function_calling, structured_output, vision, streaming | 65536 | 65536 | In: $2.00, Out: $6.00, Cache Read: $0.20 | | meta/muse-spark-1.1 | openrouter | In: text, image, video, pdf, audio; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 1048576 | In: $1.25, Out: $4.25, Cache Read: $0.15 | | meta/muse-spark-1.2 | openrouter | In: text, image, video, pdf, audio; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 1048576 | In: $1.25, Out: $4.25, Cache Read: $0.15 | | amazon/nova-2-lite-v1 | openrouter | In: text, image, video, pdf; Out: text | function_calling, reasoning, vision, video, streaming | 1000000 | 65535 | In: $0.30, Out: $2.50 | | ~openai/gpt-latest | openrouter | In: pdf, image, text; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1050000 | 128000 | In: $5.00, Out: $30.00, Cache Read: $0.50, Cache Write: $6.25 | | ~openai/gpt-mini-latest | openrouter | In: pdf, image, text; Out: text | function_calling, structured_output, reasoning, vision, streaming | 400000 | 128000 | In: $0.75, Out: $4.50, Cache Read: $0.08 | | mistralai/mistral-saba | openrouter | In: text, pdf; Out: text | function_calling, structured_output, vision, streaming | 32768 | 32768 | In: $0.20, Out: $0.60, Cache Read: $0.02 | | mistralai/voxtral-small-24b-2507 | openrouter | In: text, audio, pdf; Out: text | function_calling, structured_output, vision, streaming | 32000 | 32000 | In: $0.10, Out: $0.30, Cache Read: $0.01 | | openai/o1 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 100000 | In: $15.00, Out: $60.00, Cache Read: $7.50 | | openai/o1-pro | openrouter | In: text, image, pdf; Out: text | structured_output, reasoning, vision, streaming | 200000 | 100000 | In: $150.00, Out: $600.00 | | openai/o3 | openrouter | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 100000 | In: $2.00, Out: $8.00, Cache Read: $0.50 | | openai/o3-mini-high | openrouter | In: text, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 100000 | In: $1.10, Out: $4.40, Cache Read: $0.55 | | openai/o3-mini | openrouter | In: text, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 100000 | In: $1.10, Out: $4.40, Cache Read: $0.55 | | openai/o3-pro | openrouter | In: text, pdf, image; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 100000 | In: $20.00, Out: $80.00 | | openai/o4-mini-high | openrouter | In: image, text, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 100000 | In: $1.10, Out: $4.40, Cache Read: $0.28 | | openai/o4-mini | openrouter | In: image, text, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 200000 | 100000 | In: $1.10, Out: $4.40, Cache Read: $0.28 | | claude-3-5-haiku | vertexai | In: text, image, pdf; Out: text | function_calling, vision | 200000 | 8192 | In: $0.80, Out: $4.00, Cache Read: $0.08, Cache Write: $1.00 | | claude-haiku-4-5 | vertexai | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 200000 | 64000 | In: $1.00, Out: $5.00, Cache Read: $0.10, Cache Write: $1.25 | | claude-opus-4 | vertexai | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 200000 | 32000 | In: $15.00, Out: $75.00, Cache Read: $1.50, Cache Write: $18.75 | | claude-opus-4-1 | vertexai | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 200000 | 32000 | In: $15.00, Out: $75.00, Cache Read: $1.50, Cache Write: $18.75 | | claude-opus-4-5 | vertexai | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 200000 | 64000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | claude-opus-4-6 | vertexai | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | claude-opus-4-7 | vertexai | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | claude-opus-4-8 | vertexai | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | claude-opus-5 | vertexai | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 1000000 | 128000 | In: $5.00, Out: $25.00, Cache Read: $0.50, Cache Write: $6.25 | | claude-sonnet-4 | vertexai | In: text, image, pdf; Out: text | function_calling, reasoning, vision | 200000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | claude-sonnet-4-5 | vertexai | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 200000 | 64000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | claude-sonnet-4-6 | vertexai | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 1000000 | 128000 | In: $3.00, Out: $15.00, Cache Read: $0.30, Cache Write: $3.75 | | claude-sonnet-5 | vertexai | In: text, image, pdf; Out: text | function_calling, reasoning, vision, streaming | 1000000 | 128000 | In: $2.00, Out: $10.00, Cache Read: $0.20, Cache Write: $2.50 | | deepseek-ai/deepseek-v3.1-maas | vertexai | In: text, pdf; Out: text | function_calling, structured_output, reasoning, vision | 163840 | 32768 | In: $0.60, Out: $1.70 | | deepseek-ai/deepseek-v3.2-maas | vertexai | In: text, pdf; Out: text | function_calling, structured_output, reasoning, vision | 163840 | 65536 | In: $0.56, Out: $1.68, Cache Read: $0.06 | | zai-org/glm-4.7-maas | vertexai | In: text, pdf; Out: text | function_calling, structured_output, reasoning, vision | 200000 | 128000 | In: $0.60, Out: $2.20 | | gemini-2.0-flash | vertexai | In: text, image, audio, video, pdf; Out: text | function_calling, structured_output, vision, video, streaming | 1048576 | 8192 | In: $0.10, Out: $0.40, Cache Read: $0.02 | | gemini-2.5-flash | vertexai | In: text, image, audio, video, pdf; Out: text | function_calling, reasoning, vision, video, streaming | 1048576 | 65536 | In: $0.30, Out: $2.50, Cache Read: $0.08, Cache Write: $0.38 | | gemini-2.5-flash-lite | vertexai | In: text, image, audio, video, pdf; Out: text | function_calling, reasoning, vision, video, streaming | 1048576 | 65536 | In: $0.10, Out: $0.40, Cache Read: $0.01 | | gemini-2.5-pro | vertexai | In: text, image, audio, video, pdf; Out: text | function_calling, reasoning, vision, video, streaming | 1048576 | 65536 | In: $1.25, Out: $10.00, Cache Read: $0.12 | | gemini-3-flash-preview | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $0.50, Out: $3.00, Cache Read: $0.05 | | gemini-3.1-flash-lite | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $0.25, Out: $1.50, Cache Read: $0.02 | | gemini-3.1-flash-lite-preview | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $0.25, Out: $1.50, Cache Read: $0.02 | | gemini-3.1-pro-preview | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $2.00, Out: $12.00, Cache Read: $0.20 | | gemini-3.1-pro-preview-customtools | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video | 1048576 | 65536 | In: $2.00, Out: $12.00, Cache Read: $0.20 | | gemini-3.5-flash | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video, streaming | 1048576 | 65536 | In: $1.50, Out: $9.00, Cache Read: $0.15 | | gemini-3.5-flash-lite | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video | 1048576 | 65536 | In: $0.30, Out: $2.50, Cache Read: $0.03 | | gemini-3.6-flash | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video | 1048576 | 65536 | In: $1.50, Out: $7.50, Cache Read: $0.15 | | gemini-embedding-2 | vertexai | In: text, image, audio, video, pdf; Out: embeddings | vision, video, streaming | 8192 | 1 | In: $0.20, Out: $0.00 | | gemini-flash-latest | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, structured_output, reasoning, vision, video | 1048576 | 65536 | In: $1.50, Out: $9.00, Cache Read: $0.15 | | gemini-flash-lite-latest | vertexai | In: text, image, video, audio, pdf; Out: text | function_calling, reasoning, vision, video | 1048576 | 65536 | In: $0.25, Out: $1.50, Cache Read: $0.02 | | gemini-3.1-flash-image | vertexai | In: text, image, video, pdf; Out: text, image | reasoning, vision, video, streaming | 131072 | 32768 | In: $0.50, Out: $60.00 | | gemini-3.1-flash-image-preview | vertexai | In: text, image, pdf; Out: text, image | reasoning, vision, streaming | 65536 | 65536 | In: $0.50, Out: $60.00 | | grok-4.20-0309-non-reasoning | xai | In: text, image, pdf; Out: text | function_calling, structured_output, vision, streaming | 1000000 | 30000 | In: $1.25, Out: $2.50, Cache Read: $0.20 | | grok-4.20-0309-reasoning | xai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 30000 | In: $1.25, Out: $2.50, Cache Read: $0.20 | | grok-4.20-multi-agent-0309 | xai | In: text, image, pdf; Out: text | structured_output, reasoning, vision, streaming | 1000000 | 30000 | In: $1.25, Out: $2.50, Cache Read: $0.20 | | grok-4.3 | xai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 1000000 | 30000 | In: $1.25, Out: $2.50, Cache Read: $0.20 | | grok-4.5 | xai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 500000 | 500000 | In: $2.00, Out: $6.00, Cache Read: $0.30 | | grok-build-0.1 | xai | In: text, image, pdf; Out: text | function_calling, structured_output, reasoning, vision, streaming | 256000 | 256000 | In: $1.00, Out: $2.00, Cache Read: $0.20 | | grok-imagine-image | xai | In: text, image, pdf; Out: image | vision | 8000 | 0 | - | | grok-imagine-image-quality | xai | In: text, image, pdf; Out: image | vision | 8000 | 0 | - | | grok-imagine-video | xai | In: text, image, video, pdf; Out: video | vision, video | 1024 | 0 | - | | grok-imagine-video-1.5 | xai | In: text, image, audio, pdf; Out: video | vision | 1024 | 0 | - | ### Embedding Models (21) Models that generate embeddings: | Model | Provider | I/O | Capabilities | Context | Max Output | Standard Pricing (per 1M tokens) | | :-- | :-- | :-- | :-- | --: | --: | :-- | | cohere.embed-english-v3 | bedrock | In: text; Out: embeddings | function_calling | - | - | - | | cohere.embed-english-v3:0:512 | bedrock | In: text; Out: embeddings | function_calling | - | - | - | | cohere.embed-multilingual-v3 | bedrock | In: text; Out: embeddings | function_calling | - | - | - | | cohere.embed-multilingual-v3:0:512 | bedrock | In: text; Out: embeddings | function_calling | - | - | - | | us.cohere.embed-v4:0 | bedrock | In: text, image; Out: embeddings | function_calling | 128000 | - | - | | amazon.titan-embed-text-v1 | bedrock | In: text; Out: embeddings | function_calling | - | - | - | | amazon.titan-embed-text-v1:2:8k | bedrock | In: text; Out: embeddings | function_calling | - | - | - | | amazon.titan-embed-image-v1 | bedrock | In: text, image; Out: embeddings | function_calling | - | - | - | | amazon.titan-embed-image-v1:0 | bedrock | In: text, image; Out: embeddings | function_calling | - | - | - | | amazon.titan-embed-text-v2:0 | bedrock | In: text; Out: embeddings | function_calling | - | - | - | | amazon.titan-embed-g1-text-02 | bedrock | In: text; Out: embeddings | function_calling | - | - | - | | gemini-embedding-001 | gemini | In: text; Out: embeddings | - | 2048 | 1 | In: $0.15, Out: $0.00 | | gemini-embedding-2 | gemini | In: text, image, audio, video, pdf; Out: embeddings | vision, video, tool_choice | 8192 | 1 | In: $0.20, Out: $0.00 | | codestral-embed | mistral | In: text; Out: embeddings | predicted_outputs | 32768 | 8192 | - | | codestral-embed-2505 | mistral | In: text; Out: embeddings | predicted_outputs | 32768 | 8192 | - | | mistral-embed-2312 | mistral | In: text; Out: embeddings | - | 32768 | 8192 | - | | text-embedding-3-large | openai | In: text; Out: embeddings | - | 8191 | 3072 | In: $0.13, Out: $0.00 | | text-embedding-3-small | openai | In: text; Out: embeddings | - | 8191 | 1536 | In: $0.02, Out: $0.00 | | text-embedding-ada-002 | openai | In: text; Out: embeddings | - | 8192 | 1536 | In: $0.10, Out: $0.00 | | gemini-embedding-001 | vertexai | In: text; Out: embeddings | streaming | 2048 | 1 | In: $0.15, Out: $0.00 | | gemini-embedding-2 | vertexai | In: text, image, audio, video, pdf; Out: embeddings | vision, video, streaming | 8192 | 1 | In: $0.20, Out: $0.00 | --- _Provider availability can vary by account and region. Model information is enriched by [models.dev](https://models.dev) and RubyLLM's provider integrations._ --- ### RubyLLM Ecosystem URL: https://rubyllm.com/ecosystem/ Date: 2026-08-08 # RubyLLM Ecosystem {: .no_toc } Extend RubyLLM with MCP servers, structured schemas, instrumentation, monitoring and community-built tools for production AI apps. {: .fs-6 .fw-300 } > Ecosystem projects are maintained by their respective authors. We list projects for discoverability, but we cannot guarantee the quality, security, maintenance status, or fitness of every listed project. {: .note } ## Table of contents {: .no_toc .text-delta } 1. TOC {:toc} --- After reading this guide, you will know: * How `RubyLLM::Schema` simplifies structured data definition for AI applications * What the Model Context Protocol (MCP) is and how `RubyLLM::MCP` brings it to Ruby * How `RubyLLM::Instrumentation` exposes RubyLLM events through ActiveSupport notifications * How `RubyLLM::Monitoring` provides dashboards and alerts for RubyLLM activity * How `RubyLLM::RedCandle` enables local model execution from Ruby * How OpenTelemetry instrumentation for RubyLLM provides observability into your LLM applications * How to test application code by stubbing responses with `RubyLLM::Test` * Where to find community projects and how to contribute your own ## RubyLLM::Schema **Ruby DSL for JSON Schema Creation** [`RubyLLM::Schema`](https://github.com/danielfriis/ruby_llm-schema) provides a clean, Rails-inspired DSL for creating JSON schemas. It's designed specifically for defining structured data schemas for LLM function calling and structured outputs. ### Why Use RubyLLM::Schema? When working with LLMs, you often need to define precise data structures for: - Structured output formats - Function parameter schemas - Data validation schemas - API response formats `RubyLLM::Schema` makes this easy with a familiar Ruby syntax. ### Key Features - Rails-inspired DSL for intuitive schema creation - Full JSON Schema compatibility - Support for primitive types, objects, and arrays - Union types with `any_of` - Schema definitions and references for reusability ### Installation ```bash gem install ruby_llm-schema ``` For detailed documentation and examples, visit the [RubyLLM::Schema repository](https://github.com/danielfriis/ruby_llm-schema). --- ## RubyLLM::MCP **Model Context Protocol Support for Ruby** [`RubyLLM::MCP`](https://github.com/patvice/ruby_llm-mcp) brings the [Model Context Protocol](https://modelcontextprotocol.io/) to Ruby, enabling your applications to connect to MCP servers and use their tools, resources, and prompts as part of LLM conversations. ### What is MCP? The Model Context Protocol is an open standard that allows AI applications to integrate with external data sources and tools. MCP servers can expose: - **Tools**: Functions that LLMs can call to perform actions - **Resources**: Structured data that can be included in conversations - **Prompts**: Predefined prompt templates with parameters ### Key Features - Multiple transport types (HTTP streaming, STDIO, SSE) - Automatic tool integration with RubyLLM - Resource management for files and data - Prompt templates with arguments - Support for multiple simultaneous MCP connections ### Installation ```bash gem install ruby_llm-mcp ``` For detailed documentation, examples, and usage guides, visit the [RubyLLM::MCP documentation](https://rubyllm-mcp.com/). --- ## RubyLLM::Instrumentation **ActiveSupport::Notifications instrumentation for RubyLLM** [`RubyLLM::Instrumentation`](https://github.com/sinaptia/ruby_llm-instrumentation) is a Rails plugin that instruments RubyLLM events with the built-in [ActiveSupport::Notifications](https://api.rubyonrails.org/classes/ActiveSupport/Notifications.html) API. ### Why Use RubyLLM::Instrumentation? When building LLM applications, you may need custom monitoring, analytics, or logging pipelines based on your RubyLLM activity. ### Key Features - Event instrumentation for key RubyLLM operations - Native integration with `ActiveSupport::Notifications` - Event hooks for chat completion, tools, embeddings, images, moderation, and transcription - Easy integration with existing Rails observability stacks ### Supported Events - `complete_chat.ruby_llm` when `RubyLLM::Chat#ask` is called - `execute_tool.ruby_llm` when a tool call is executed - `embed_text.ruby_llm` when `RubyLLM::Embedding.embed` is called - `paint_image.ruby_llm` when `RubyLLM::Image.paint` is called - `moderate_text.ruby_llm` when `RubyLLM::Moderation.moderate` is called - `transcribe_audio.ruby_llm` when `RubyLLM::Transcription.transcribe` is called ### Installation ```bash gem install ruby_llm-instrumentation ``` For detailed documentation and examples, visit the [RubyLLM::Instrumentation repository](https://github.com/sinaptia/ruby_llm-instrumentation). --- ## RubyLLM::Monitoring **RubyLLM monitoring within your Rails application** [`RubyLLM::Monitoring`](https://github.com/sinaptia/ruby_llm-monitoring) is a Rails engine that provides a dashboard for cost, throughput, response time, and error aggregations. It also supports configurable alerts through channels such as email or Slack. ### Why Use RubyLLM::Monitoring? When running RubyLLM-powered features in production, you need ongoing visibility into performance, cost, and failure patterns. ### Key Features - Captures events from `RubyLLM::Instrumentation` - Dashboard metrics for cost, throughput, latency, and error rates - Rule-based alerting for operational thresholds and regressions ### Installation ```bash gem install ruby_llm-monitoring ``` For detailed documentation and examples, visit the [RubyLLM::Monitoring repository](https://github.com/sinaptia/ruby_llm-monitoring). --- ## RubyLLM::RedCandle **Local LLM Execution with Quantized Models** [`RubyLLM::RedCandle`](https://github.com/scientist-labs/ruby_llm-red_candle) enables local LLM execution using quantized GGUF models through the [Red Candle](https://github.com/scientist-labs/red-candle) gem. Unlike other RubyLLM providers that communicate via HTTP APIs, `RubyLLM::RedCandle` runs models directly in your Ruby process using Rust's Candle library. ### Why Run Models Locally? Running LLMs locally offers several advantages: - **Zero latency**: No network round-trips to external APIs - **No API costs**: Run unlimited inferences without usage fees - **Complete privacy**: Your data never leaves your machine - **Offline capable**: Works without an internet connection ### Key Features - Local inference with hardware acceleration (Metal on macOS, CUDA for NVIDIA GPUs, or CPU fallback) - Automatic model downloading from HuggingFace - Streaming support for token-by-token output - Structured JSON output with grammar-constrained generation - Multi-turn conversation support with automatic history management ### Installation ```bash gem install ruby_llm-red_candle ``` **Note**: The underlying red-candle gem requires a Rust toolchain for compiling native extensions. ### Supported Models `RubyLLM::RedCandle` supports various quantized models including TinyLlama, Qwen2.5, Gemma-3, Phi-3, and Mistral-7B. Models are automatically downloaded from HuggingFace on first use. For detailed documentation and examples, visit the [RubyLLM::RedCandle repository](https://github.com/scientist-labs/ruby_llm-red_candle). --- ## OpenTelemetry RubyLLM Instrumentation **Observability for RubyLLM Applications** [opentelemetry-instrumentation-ruby_llm](https://github.com/thoughtbot/opentelemetry-instrumentation-ruby_llm) adds OpenTelemetry tracing to RubyLLM, enabling you to send traces to any compatible backend (Langfuse, Datadog, Honeycomb, Jaeger, Arize Phoenix and more). ### Why Use OpenTelemetry Instrumentation? When running LLM applications in production, you need visibility into: - Which models are being called and how they perform - The flow of conversations and tool calls - How long each step takes and where time is spent - Token usage for cost tracking and optimization - Tool call selection, execution, and results - Error rates and failure modes This gem provides all of this automatically, with minimal setup and without having to manually add tracing code to your application. ### Key Features - Automatic tracing for chat completions and tool calls - Token usage tracking (input and output) - Tool call spans with arguments and results - Error recording with exception details - Works with any OpenTelemetry-compatible backend - Follows the [OpenTelemetry GenAI Semantic Conventions](https://opentelemetry.io/docs/specs/semconv/gen-ai/gen-ai-spans/) ### Installation ```bash gem install opentelemetry-instrumentation-ruby_llm ``` ### Usage ```ruby OpenTelemetry::SDK.configure do |c| c.use 'OpenTelemetry::Instrumentation::RubyLLM' end ``` For detailed documentation, setup instructions, and examples, visit the [OpenTelemetry RubyLLM Instrumentation repository](https://github.com/thoughtbot/opentelemetry-instrumentation-ruby_llm). --- ## RubyLLM::Tribunal **LLM Evaluation and Testing for Ruby** [`RubyLLM::Tribunal`](https://github.com/Alqemist-labs/ruby_llm-tribunal) helps you evaluate and test LLM outputs in Ruby applications. It combines deterministic assertions for fast checks with model-based evaluations for quality, faithfulness, and safety. ### Why Use RubyLLM::Tribunal? When building LLM features, you often need to verify that responses are: - Grounded in retrieved context - Relevant to the user's request - Free from hallucinations or unsafe content - Resistant to jailbreak or prompt injection attempts `RubyLLM::Tribunal` brings these checks into your RSpec or Minitest suite. ### Key Features - Deterministic assertions for exact matches, regexes, JSON validation, and other fast checks - LLM-as-judge assertions for faithfulness, relevance, correctness, and refusal behavior - Assertions for hallucinations, toxicity, harmful content, bias, jailbreaks, and PII exposure - Red team attacks to generate adversarial prompts and test defenses - Multiple reporters including Console, JSON, HTML, JUnit, and GitHub Actions - Test helpers for RSpec and Minitest ### Installation ```bash gem install ruby_llm-tribunal ``` For detailed documentation and examples, visit the [RubyLLM::Tribunal repository](https://github.com/Alqemist-labs/ruby_llm-tribunal). --- ## RubyLLM::TopSecret **Automatically filter sensitive information from RubyLLM conversations using Top Secret.** [`RubyLLM::TopSecret`](https://github.com/thoughtbot/ruby_llm-top_secret) automatically filters sensitive information from your conversations using [`Top Secret`](https://github.com/thoughtbot/top_secret). ### Why Use RubyLLM::TopSecret? If you're working in a regulated industry, or have general privacy concerns, you should be cautious about what data you send to an LLM. `RubyLLM::TopSecret` not only filters sensitive information before sending it to a provider, but it also restores the filtered response server-side. ### Key Features - Supports in-memory and Active Record backed chats - Opt-in first architecture ### Installation ```bash gem install ruby_llm-top_secret ``` ## Usage ```ruby RubyLLM::TopSecret.with_filtering do chat = RubyLLM.chat response = chat.ask("My name is Ralph and my email is ralph@thoughtbot.com") # The provider receives: "My name is [PERSON_1] and my email is [EMAIL_1]" # The response comes back with placeholders restored: puts response.content # => "Nice to meet you, Ralph!" end ``` For detailed documentation and examples, visit the [RubyLLM::TopSecret repository](https://github.com/thoughtbot/ruby_llm-top_secret?tab=readme-ov-file). --- ## RubyLLM::Test **Test Application Code by Stubbing LLM Responses** [`RubyLLM::Test`](https://github.com/RockSolt/ruby_llm-test) allows you to stub LLM responses in your tests, making it easier to test application logic without relying on calls to external systems. ### Why Use RubyLLM::Test? When writing tests for code that interacts with LLMs, you may want to: - Ensure your application logic behaves correctly without making real API calls - Test edge cases and error handling - Control the responses from the LLM for deterministic tests ### Key Features - Clear syntax for defining stubs and expected responses - Support for multiple stubs in a single test - Validate arguments, such as model or tool calls, passed to the LLM - Works with RSpec and Minitest ### Usage ```ruby RubyLLM::Test.stub_response("Outlook good") chat = RubyLLM.chat response = chat.ask "What are the odds this works?" assert_equal "Outlook good", response.content ``` ### Installation Add the gem to the test group in your Gemfile, or install it directly: ```bash gem install ruby_llm-test ``` --- ## Community Projects The RubyLLM ecosystem is growing! If you've built a library or tool that extends RubyLLM, we'd love to hear about it. Consider: - Opening a PR to add your project to this page - Sharing it in our GitHub Discussions - Using the `ruby-llm` topic on your GitHub repository Together, we're building a comprehensive ecosystem for LLM-powered Ruby applications. --- ## Links - About: https://rubyllm.com/about/ - GitHub: https://github.com/crmne/ruby_llm - Rubygems: https://rubygems.org/gems/ruby_llm - GitHub: https://github.com/sponsors/crmne