Not every request needs your most expensive model. The Auto Router automatically routes each request to the optimal model based on your chosen profile, so you can reduce costs without sacrificing the quality that matters.
How It Works
The Auto Router sits between your application and two models you configure: a Strong Model for complex requests and an Economical Model for simpler ones. When a request comes in, it analyzes the task complexity and routes it to the appropriate model based on your profile.
Set Up the Auto Router
- Navigate to the AI Router section in AI Studio and open the Models page.
- Click Add Model.
- Select Auto Router from the dropdown.
- Fill in the configuration:
- Model ID: a unique identifier for this router (lowercase letters, numbers, and hyphens only).
- Strong Model: the more capable model, used for complex requests.
- Economical Model: the cheaper model, used for simpler requests.
- Profile: choose how aggressively to route between the two models.
- Click Add model.
Profiles
| Profile | Behavior |
|---|
| Quality | Prioritizes the Strong Model for more requests |
| Balanced | Balances cost and quality across simple and complex requests |
| Cost | Prefers the Economical Model more aggressively to save money |
Recommended model pairs
These pairs combine high routing accuracy with significant cost ratios (over 10x), making them effective starting points.
| Strong Model | Economical Model |
|---|
| Google Gemini 2.5 Pro | Google Gemini 2.5 Flash |
| OpenAI GPT-5.1 | OpenAI GPT-4o Mini |
| Anthropic Claude Opus 4 | Google Gemini 3 Flash |
| OpenAI GPT-4o | OpenAI GPT-4o Mini |
Models from the same family or tier work well together (e.g. Claude Sonnet and Gemini Flash). Very large capability gaps reduce the effectiveness of routing.
You can combine models from different providers in a single Auto Router configuration.
Use the Auto Router
Once created, the Auto Router appears in your AI Router and can be selected anywhere a model is accepted: Deployments, Agents, Playground, and Experiments.
Reference in code
When using an Auto Router through the SDKs, API, or Supported Libraries, reference it by the string <workspacename>@orq/<model-id>.
Example: acme@orq/my-auto-router