Skip to main content
Glama

llm_auto

Routes AI tasks to the best model while tracking cumulative savings across sessions and hosts, even without client-side hooks.

Instructions

Auto-routing wrapper with persistent savings tracking — works from any host.

Equivalent to llm_route but additionally:

  • Flushes pending hook-written savings records into SQLite before routing.

  • Appends a compact savings envelope every 5 calls so you can see the cumulative value across all sessions and hosts without running llm_savings.

Use llm_auto instead of llm_route when you are in a host that lacks a UserPromptSubmit hook (Codex CLI, Claude Desktop, GitHub Copilot) — the savings are tracked server-side, so they accumulate correctly regardless of which client triggered the call.

Args: prompt: The task or question to route. task_type: Optional hint — "query", "research", "generate", "analyze", "code". profile_override: Force a routing profile — "budget", "balanced", or "premium". system_prompt: Optional system instructions. context: Optional conversation context.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
promptYes
task_typeNo
profile_overrideNo
system_promptNo
contextNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior4/5

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

Since no annotations are provided, the description must fully disclose behavioral traits. It clearly explains that the tool flushes pending hook-written savings records into SQLite before routing and appends a savings envelope every 5 calls, and that savings are tracked server-side. However, it doesn't mention potential side effects on the routing process itself (e.g., latency) or any error scenarios, but the core extra behavior is well communicated.

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

Conciseness5/5

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

The description is concise at about 160 words, with a logical structure: summary, differentiation from sibling, usage guidance, and parameter list. Every sentence adds value, and there is no redundant or extraneous information.

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?

Given the tool's complexity (routing with savings tracking, 5 params, no annotations), the description covers purpose, behavioral traits, usage guidelines, and all parameters. It does not describe the output schema, but since an output schema is provided separately, that is acceptable. It could mention error handling or response format, but the current completeness is sufficient for most use cases.

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

Parameters5/5

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

Schema description coverage is 0%, so the description must compensate, and it does thoroughly. The 'Args' section provides clear, meaningful descriptions for all 5 parameters, including allowed values for task_type and profile_override, which are not enumerated in the schema. Each parameter's purpose and optionality are explicitly stated.

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

Purpose5/5

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

The description clearly defines the tool as an auto-routing wrapper with persistent savings tracking, distinguishes it from the sibling llm_route by explaining the additional flushing and savings envelope behavior, and specifies it works from any host. The verb 'route' and resource 'prompt' are clear, and the scope is well-defined.

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

Usage Guidelines5/5

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

The description explicitly states when to use llm_auto over llm_route: 'Use llm_auto instead of llm_route when you are in a host that lacks a UserPromptSubmit hook (Codex CLI, Claude Desktop, GitHub Copilot).' It also provides context about server-side tracking, making the usage guidance extremely clear.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/ypollak2/llm-router'

If you have feedback or need assistance with the MCP directory API, please join our Discord server