Skip to main content
Glama

Recommend Optimal Model

rai_model_route
Read-onlyIdempotent

Routes AI tasks to suitable models by analyzing complexity and cost-quality tradeoffs, returning recommended model, alternatives, per-1K-token costs, and savings estimates.

Instructions

Recommend the optimal AI model for a task based on complexity analysis and cost-quality tradeoff. Returns recommended model, alternative, estimated cost per 1K tokens, and estimated savings vs GPT-4o. Used by LLMOps Engineers for intelligent model routing.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
tasksNoOptional: batch route multiple task descriptions
task_descriptionNoNatural language description of the task
quality_requirementNomaximum: best model always; balanced: cost-quality tradeoff; cheapest: minimize costbalanced

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.2.6

TDQS

A3.7/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already declare the safe read-only, idempotent, non-destructive profile, so the bar is lower. The description adds real value by disclosing the response payload (recommended model, alternative, cost per 1K tokens, savings vs GPT-4o), which is otherwise undocumented because there is no output schema.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Three sentences with no filler, and the core purpose is front-loaded ahead of the return details and the audience note. The trailing LLMOps sentence is the only mildly expendable element.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a 3-parameter tool with full schema coverage and no output schema, the description covers purpose, basis, and expected return contents. The one unresolved point is that all parameters are optional, so the description never clarifies what happens on an empty call or which of task_description vs tasks is expected.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, including an enum with its meanings, so the schema carries the parameter burden and baseline 3 applies. The description adds no syntax, format, or interaction detail beyond what the schema already states.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and resource ("Recommend the optimal AI model") with the basis for the recommendation (complexity analysis, cost-quality tradeoff) and enumerates the output. It is clear in isolation, but it never distinguishes itself from nearby siblings like rai_compare_models or rai_cost_estimate, so an agent must infer the boundary.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

"Used by LLMOps Engineers for intelligent model routing" implies the intended context but gives no explicit when-to-use conditions, no prerequisites, and no named alternative. An agent gets a rough sense of fit but nothing that resolves the choice against rai_compare_models or rai_cost_estimate.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.