Skip to main content
Glama

correlate_ai_trace

Explain why an AI trace behaved as it did by correlating its cache/memory spans with live Valkey state—key existence, TTL, thresholds, and index status—to diagnose unexpected cache misses or stale recalls.

Instructions

Explain WHY a trace behaved the way it did by joining its cache/memory spans with live Valkey state: does the key still exist, what is its TTL, what threshold was active, what is the index state. The strongest tool for diagnosing unexpected cache misses or stale memory recalls. Requires a selected instance (the one the AI components run on).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
traceIdYesTrace ID from list_ai_traces
instanceIdNoOptional instance ID override
Behavior3/5

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

The description explains what the tool does (join trace with live state) and lists the specific diagnostics performed. However, it does not explicitly state that the tool is read-only or disclose any side effects. Since there are no annotations to supplement this, the description carries the full burden but falls short of being fully transparent about behavioral traits.

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 extremely concise: two sentences with no wasted words. It front-loads the core action and then provides diagnostic details and use-case. Every sentence adds value, and the structure is clean and easy to parse.

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 (joining trace with live state), the description covers the key diagnostic elements (key existence, TTL, threshold, index state). It lacks an explicit statement about the output format or return value, but the list of checks gives a reasonable expectation. Overall, it is nearly complete for an agent to decide when to use it.

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?

Both parameters (traceId, instanceId) have schema descriptions, and the description adds meaningful context: traceId is from list_ai_traces, and instanceId is an optional override. It also mentions that a selected instance is required by default, which adds value beyond the schema. This justifies a score above the baseline of 3.

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 states the tool's purpose: to explain why a trace behaved as it did by joining cache/memory spans with live Valkey state. This distinguishes it from sibling tools like get_ai_trace (which just retrieves a trace) or cache_list (which lists cache keys). The verb 'Explain' with specific diagnostic capabilities (key existence, TTL, threshold, index state) makes the purpose highly specific.

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

Usage Guidelines4/5

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

The description explicitly states when to use this tool: 'The strongest tool for diagnosing unexpected cache misses or stale memory recalls.' It also mentions a prerequisite: requires a selected instance. However, it does not explicitly state when not to use it or provide alternatives for other scenarios, which would elevate it to a 5.

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/BetterDB-inc/monitor'

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