Skip to main content
Glama

tokendiet_route_finops

Routes agent turns to cost-appropriate tiers (Local Flash, Balanced Coding, Frontier Reasoning) via Cascade Escalation Guard, balancing cost and quality by context size and task complexity.

Instructions

Route an agent turn across Local Flash, Balanced Coding, and Frontier Reasoning tiers with Cascade Escalation Guard.

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_summary": "<prompt_summary>",
      "context_tokens_raw": "<context_tokens_raw>",
      "context_tokens_compressed": "<context_tokens_compressed>"
    },
    "name": "tokendiet_route_finops"
  }
}

Input Schema

NameRequiredDescriptionDefault
retry_countNo
prompt_summaryYes
multi_file_countNo
context_tokens_rawYes
context_tokens_compressedYes
requires_formal_or_security_proofNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.0

TDQS

C2.2/5.0
Behavior2/5

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

With no annotations at all, the description carries the full behavioral burden and discloses essentially nothing: it does not say whether the call is a cheap read or triggers real model spend, how 'Cascade Escalation Guard' changes behavior, what causes escalation, or whether retry_count alters the chosen tier. Only the tier vocabulary hints at the cost trade-off, which is far short of what a 6-parameter routing tool needs.

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

Conciseness3/5

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

It is a single front-loaded sentence with no filler, which is structurally clean. But brevity here is under-specification rather than economy: the sentence is too thin for a six-parameter decision tool and spends its scarce words on capitalized branding instead of operational meaning.

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

Completeness2/5

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

Six parameters, three of them required, zero schema descriptions, no output schema and no annotations leave the agent with almost no basis for a correct call. The description should at minimum explain what the tool returns and how the required token counts and proof flag influence the routing outcome.

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

Parameters1/5

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

Schema description coverage is 0% across six parameters, so the description must compensate and it does not mention a single one. Names like context_tokens_raw, context_tokens_compressed, requires_formal_or_security_proof and multi_file_count are interpretable in isolation but their effect on routing decisions, expected formats, and whether compression ratio drives tier choice are left entirely unexplained.

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

Purpose3/5

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

The description gives a verb ('Route') and a resource ('an agent turn') and names three tiers, so the general intent is graspable. However, 'Cascade Escalation Guard', 'Local Flash', 'Balanced Coding' and 'Frontier Reasoning' are unexplained product jargon, and it never says whether the tool merely recommends a tier or actually dispatches the turn, which is the single most important fact about its purpose.

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 (compress_session, prune_tool_output, skeletonize_code) or versus just picking a model directly. No preconditions, no exclusions, no guidance on frequency of invocation per turn.

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