Skip to main content
Glama

route_agent_step

Route AI agent workflow steps across local, balanced, and frontier reasoning models with cost/latency optimization, semantic caching, failover, and confidence-gated escalation.

Instructions

Route an AI agent workflow step across FAST_LOCAL, BALANCED, and FRONTIER_REASONING models using Pareto cost/latency optimization, SimHash semantic caching, circuit-breaker failover, and confidence-gated cascade escalation.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "prompt": "<prompt>"
    },
    "name": "route_agent_step"
  }
}

Input Schema

NameRequiredDescriptionDefault
promptYesUser or agent step instruction.
step_idNostep-0
tenant_idNodefault-tenant
workflow_idNodefault-workflow
bypass_cacheNo
max_cost_usdNo
tools_schemaNo
system_promptNo
latency_sla_msNo
min_confidenceNo
require_json_schemaNo
estimated_output_tokensNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.1.0

TDQS

C2.8/5.0
Behavior2/5

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

No annotations are supplied, so the description carries the full disclosure burden. It does name meaningful behaviors — semantic caching, circuit-breaker failover, confidence-gated escalation — but it never says that a cache hit may return a semantically similar prior response, that escalation can raise cost, what the failover boundary is, or anything about side effects or return shape.

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?

It is a single front-loaded sentence with the verb and resource first and no filler. The dense technical vocabulary is efficient, though stacking five capability phrases into one clause puts the operation's actual behavior on equal footing with implementation details.

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

Completeness3/5

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

For a 12-parameter orchestration tool with no annotations and no output schema, one sentence is thin. The agent learns the routing objective but not the call contract — what comes back, how failures surface, or how the eleven optional parameters interact — so the definition is under-specified relative to the tool's complexity.

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

Parameters2/5

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

Schema coverage is 8%: only 'prompt' is documented, and ten of the twelve parameters have no description anywhere. The prose obliquely touches a few of them (cost/latency optimization hints at max_cost_usd and latency_sla_ms, 'confidence-gated' hints at min_confidence), but edge-case parameters like tools_schema, require_json_schema, and estimated_output_tokens remain entirely unexplained.

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?

The description gives a specific verb ('Route') and resource ('an AI agent workflow step') and names the concrete model tiers it chooses among. It is clear what the tool does, though it never distinguishes itself from siblings such as classify_task_complexity or check_budget_status, which an agent could plausibly reach for in the same workflow.

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

Usage Guidelines2/5

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

There is no statement of when to call this versus the sibling tools, no preconditions, and no exclusions. The agent is left to infer that routing follows classification and budget checks, and nothing tells it when to set bypass_cache or choose not to route at all.

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