Skip to main content
Glama
AIops-tools

observability-aiops

label_values

Read-only

List distinct values for any Prometheus label, defaulting to all metric names. Scope results with a PromQL selector to avoid truncated, partial data.

Instructions

[READ] Distinct values of a label (default name = all metric names).

Args: label: Label name to enumerate (default name). match: Optional PromQL selector to scope the values (e.g. '{job="api"}'). target: Prometheus target name from config; omit for the default.

Returns an envelope with returned/limit/truncated. If truncated is true the result is partial — narrow the selector or raise the limit rather than treating it as complete.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
labelNo__name__
matchNo
targetNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.7.0

TDQS

A3.9/5.0
Behavior4/5

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

Annotations only declare readOnlyHint=true, so the description adds real value by disclosing the return envelope (returned/limit/truncated) and warning that truncated=true means partial results, plus what to do about it. It still omits any auth/permission or rate-limit context.

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?

Front-loaded with the [READ] marker and a one-line purpose, then Args and Returns in scannable order. Every sentence carries information; nothing is filler.

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 read-only tool with no output schema, the description covers the parameters, the return envelope, and truncation handling, which is enough to call and interpret it. Missing only environmental context such as auth requirements or per-target scope.

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%, but the description compensates for all three parameters: label (with default __name__), match as an optional PromQL selector with an example, and target as the Prometheus config target with omit-for-default semantics. A syntax example for match would make this fully self-sufficient.

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: enumerate the distinct values of a label, with the clarifying default that __name__ yields all metric names. The mention of a PromQL selector and a Prometheus target implicitly separates it from the Loki siblings, but that differentiation is never made explicit.

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?

Usage is implied rather than spelled out — the agent can infer this is for enumerating label values, and the truncation note gives remediation guidance. There is no explicit when-to-use/when-not statement or named alternative (e.g. vs loki_label_values or series_metadata).

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