Skip to main content
Glama

get_llm_model_stats

Retrieve performance statistics for a specific LLM model to analyze request counts, latency percentiles, token usage, error rates, and finish reasons.

Instructions

Get detailed performance statistics for a specific LLM model.

Analyzes request count, latency percentiles (p50, p95, p99), token usage statistics, error rates, and finish reason distributions.

Args: model_name: Model name to analyze (e.g., "gpt-4", "claude-3-opus", "gpt-3.5-turbo") start_time: Start time in ISO 8601 format (e.g., 2024-01-01T00:00:00Z) end_time: End time in ISO 8601 format service_name: Filter by service name

Returns: JSON string with comprehensive model statistics including duration/token percentiles

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
end_timeNo
model_nameYes
start_timeNo
service_nameNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

B3.4/5.0
Behavior3/5

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

With no annotations, the description carries the full burden. It discloses the metrics computed and that a JSON string is returned, and the 'Get ... statistics' framing implies a read-only analysis. However it says nothing about cost of the query, permissions, or behavior when start_time/end_time are omitted, which matters for a query tool with no annotation coverage.

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?

Front-loaded with the purpose, then cleanly delimited Args/Returns blocks. The metric enumeration is slightly padded, but nothing is genuinely wasteful.

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?

An output schema exists, so the Returns line need not document the response shape, and the description correctly focuses on purpose and input formats. It misses default time-window semantics and any note about how the result is scoped, which is a modest gap for a 4-parameter analytics tool.

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

Parameters4/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: all four parameters are named with formats (ISO 8601 for the time bounds) and concrete model-name examples. The gap is that it never states what a null/default time bound means (e.g. all time).

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 ('Get detailed performance statistics for a specific LLM model') and enumerates the metrics covered (latency percentiles, token usage, error rates, finish reasons). It is clearly distinguishable from list_llm_models, but it does not explicitly contrast itself with the closest sibling get_llm_usage.

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 explicit when-to-use guidance, no mention of prerequisites, and no routing to alternatives such as get_llm_usage or get_llm_slow_traces. Usage is only implied by the phrase 'for a specific LLM model.'

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