Skip to main content
Glama

sample_case_ids

Retrieve a sample of case IDs from a log using strategies: first (original order), longest (most events), or shortest (fewest events) to select cases without exporting the log.

Instructions

Return a small sample of case IDs from a log.

Useful for picking a concrete case_id to pass to abstract_case without having to export the log to disk first.

Strategies:

  • "first": IDs in original order (cheap; no sort).

  • "longest": the n cases with the most events.

  • "shortest": the n cases with the fewest events.

For longest / shortest, the response includes an event_counts dict so callers can see the sort key; first omits it.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
nNo
log_idYes
strategyNofirst

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

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 behavioral traits: for longest/shortest strategies, the response includes an event_counts dict; first omits it. This is sufficient for a read-only sampling tool.

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, using bullet points for strategies, and front-loads the purpose. Every sentence adds value without redundancy.

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?

The description covers core functionality, strategy differences, and output behavior (event_counts). It does not mention prerequisites or error handling, but the tool is simple and an output schema exists.

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

Parameters3/5

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

Schema description coverage is 0%, but the description adds meaning for the strategy parameter by listing enum values and their implications. It does not explicitly describe n (though the name is clear) or log_id, partially compensating for missing schema descriptions.

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 returns a sample of case IDs from a log, with explicit mention of its utility for feeding into abstract_case. This distinguishes it from abstract_* siblings by specifying the resource and verb.

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 explains when to use the tool (to pick a concrete case_id without exporting the log) and describes three strategies. It does not explicitly state when not to use or provide alternatives, but the context is 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/azizketata/pm4py-mcp'

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