Skip to main content
Glama

get_slot_stats

Retrieve per-slot key counts and CPU usage for Valkey 8.0+ instances. Use 'key-count' to find most populated slots or 'cpu-usec' to identify hot slots.

Instructions

Get per-slot key counts and CPU usage (Valkey 8.0+ only). Use orderBy='cpu-usec' to find hot slots, or 'key-count' to find the most populated slots. Returns an error message if not supported.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
orderByNoSort order: 'key-count' or 'cpu-usec' (default 'key-count')
limitNoMax slots to return (default 20)
instanceIdNoOptional instance ID override
Behavior4/5

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

No annotations are provided, so the description carries the full burden. It discloses the version requirement (Valkey 8.0+), and states that an error message is returned on unsupported environments. However, it does not mention if the tool is read-only or any permission requirements, but for a stats tool this is less critical.

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?

Two sentences, both dense with information. The first sentence states purpose and version constraint; the second gives usage guidance and error behavior. No wasted words.

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?

No output schema exists, but the description infers the return likely includes slot IDs with counts and CPU usage. The version constraint and error behavior are covered. The description lacks explicit details on the response format, but for a stats retrieval tool used with context from sibling tools, it is largely complete.

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 coverage is 100%, so baseline is 3. The description adds value by explaining the purpose of the orderBy enum values ('cpu-usec' for hot slots, 'key-count' for populated slots) and confirms the default limit of 20. This extra semantic clarity justifies a score of 4.

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?

Description clearly identifies the tool's purpose: retrieving per-slot key counts and CPU usage for Valkey 8.0+. The verb 'get' and specific resource 'per-slot key counts and CPU usage' make it distinct from sibling tools like get_hot_keys or get_cluster_node_stats.

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?

Provides explicit guidance on using orderBy to find hot slots or populated slots. Also notes that an error is returned if the feature is not supported. While it doesn't explicitly list when not to use, the context is clear enough for an AI agent to decide.

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