Select optimal model
select_optimal_modelSelects the cheapest AI model for your task based on tier, capabilities, and budget, with full reasoning and fallback options.
Instructions
Pick the single cheapest model that meets the task tier, capabilities, and budget, with full reasoning and a fallbackChain. Offline.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| task | No | Free-text task; used for the tier heuristic when taskClass is absent. | |
| taskClass | No | Explicit task class; overrides the heuristic. | |
| requiredCapabilities | No | Capabilities the model must support. | |
| maxCostUsd | No | Budget ceiling for the predicted call cost. | |
| estimatedInputTokens | Yes | Estimated input tokens for the forecast. | |
| estimatedOutputTokens | Yes | Estimated output tokens for the forecast. | |
| providers | No | Axis 1: provider availability allowlist (spec 5.4). | |
| target | No | Axis 2: "self" (default) applies the client scope; "code" considers all providers. | |
| includeLocal | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| selected | Yes | ||
| runnerUp | No | ||
| rejected | Yes | ||
| reasoning | Yes | ||
| fallbackChain | Yes | ||
| budgetExceeded | No | ||
| shortfallUsd | No | ||
| providerScope | No | ||
| scopeSource | No | ||
| cheaperIfAvailable | No | ||
| catalogVersion | Yes | ||
| asOf | Yes |