Skip to main content
Glama

Select a sample

select_sample

Draws a reproducible sample from a population via seeded random, systematic, haphazard, or targeted methods, recording the method, seed, and references for auditability.

Instructions

Select a reproducible sample from a population. Seeded (deterministic) for random/systematic/haphazard; targeted takes explicit references. Records the method, seed and references.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "engagementId": "<engagementId>",
      "populationId": "<populationId>",
      "method": "<method>"
    },
    "name": "select_sample"
  }
}

Input Schema

NameRequiredDescriptionDefault
seedNo
methodYes
controlIdNo
rationaleNo
sampleSizeNo
engagementIdYes
populationIdYes
targetedReferencesNo

Output Schema

NameRequiredDescriptionDefault
sampleYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.2

TDQS

B3.1/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 behavioral burden. It usefully discloses determinism/seeding and that method, seed and references are persisted (a side effect), but says nothing about permissions, validation failures, or what happens if required inputs for a given method are missing.

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?

Three short sentences with no filler, front-loading the core action before the method-specific notes. Efficient, though it sacrifices detail for brevity.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

An 8-parameter, no-annotation mutation tool with 0% schema coverage needs far more: conditional rules (seed for seeded methods, targetedReferences for targeted) are not stated, and the relationship to compute_sample_size is absent. An output schema exists, so return values need not be explained.

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

Parameters2/5

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

Schema description coverage is 0% across 8 parameters, so the description must compensate and largely does not. It hints at seed and targetedReferences semantics but leaves sampleSize, rationale, controlId, engagementId and populationId entirely unexplained.

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 (select) and resource (reproducible sample from a population), and clarifies the tailoring by method. However, it never distinguishes itself from the sibling compute_sample_size, leaving the agent to infer the workflow ordering between them.

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?

The description implicitly guides method choice (seeded for random/systematic/haphazard, explicit references for targeted) and notes reproducibility. But it gives no explicit when-to-use vs alternatives, no prerequisites, and no mention of when select_sample should be called relative to compute_sample_size.

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