Skip to main content
Glama

subset

Filter, select, or sample table rows and columns using query, regex, or variance criteria; preview results and optionally save the output as a new table.

Instructions

Filter / select / sample rows and columns of a table; preview a few rows; optionally store the result as new_name.

where: pandas query string, e.g. "iv > 0.3 and maturity_days <= 30" (backtick-quote odd column names). columns: list of names, "re:", or "top_variance:". top_variance keeps the k highest-variance numeric features. This is the only way to read raw rows; preview is capped (200 rows x 60 cols).

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": {
      "name": "<name>"
    },
    "name": "subset"
  }
}

Input Schema

NameRequiredDescriptionDefault
nameYes
seedNo
whereNo
sampleNo
columnsNo
previewNo
sort_byNo
new_nameNo
ascendingNo
top_varianceNo

Output Schema

NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.2.1

TDQS

A3.5/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 burden. It does disclose a real behavioral constraint — 'preview is capped (200 rows x 60 cols)' — which is valuable context an agent cannot get elsewhere. However, it never explains the side effect of new_name (does it register a new dataset, overwrite an existing one, appear in list_datasets?) or what happens when filtering yields zero rows, leaving the mutation semantics opaque.

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?

The definition is front-loaded with the core action, then drops into per-parameter notes only for where, columns and the preview cap. Each line earns its place and there is no filler. The formatting is slightly compressed (bare parameter labels with no separators), but the size is appropriate for a 10-parameter tool.

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?

An output schema exists, so return values need not be described, and the description covers the highest-risk unknowns: the hard cap on preview output and the expression languages for where and columns. The remaining gap is the persistence behavior of new_name in a 20-sibling dataset-management context, which matters but is a narrower omission given schema coverage of returns.

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 coverage is 0%, so the description must compensate, and it does well for the hardest parameters: 'where' gets a pandas query syntax with a concrete example and backtick-quoting tip, and 'columns' gets the list / re:<regex> / top_variance:<k> forms. But 6 of 10 parameters — sample, seed, sort_by, ascending, preview and the required 'name' — are never explained, and what 'name' refers to (the source table) is left ambiguous.

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?

The opening line names specific verbs and the resource: 'Filter / select / sample rows and columns of a table; preview a few rows; optionally store the result as new_name.' The clause 'This is the only way to read raw rows' distinguishes it from siblings such as describe or transform that return derived views. It stops short of naming a sibling directly, so it is clear but not maximally differentiated.

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 line 'This is the only way to read raw rows' implies when this tool is mandatory rather than, say, transform or describe, but there is no explicit when-not guidance and no named alternative. An agent must infer which of the 20 siblings to prefer for filtering vs. transforming. Adequate but clearly incomplete routing guidance.

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