Skip to main content
Glama

check_keys

Read-only

Verify whether one or more dataset columns form a unique key by detecting missing values and duplicate combinations, then report affected row counts with example row numbers.

Instructions

Check whether a column (or set of columns) works as a unique key: no missing values and no repeats. Reports how many rows break it, with example row numbers.

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

Input Schema

NameRequiredDescriptionDefault
columnsNoCheck whether these columns together uniquely identify every row, such as ['id'] or ['order_id', 'line']. Omit to list candidate keys and check every id-like column.
datasetYesA dataset name returned by load_dataset.

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

B3.4/5.0
Behavior3/5

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

Annotations already declare this is a read-only, closed-world operation, so safety is covered. The description adds the useful semantic definition of what 'breaks' a key (missing value or repeat) and that counts plus example row numbers are reported. It says nothing about the cost of scanning all id-like columns when columns is omitted, which would have been valuable.

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 short sentences, zero filler, with the core definition front-loaded and the reporting behavior second. Every clause earns its place.

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?

For a simple read-only validation tool with full schema coverage and an output schema, this is nearly complete: purpose, criterion, and result shape are all conveyed. The only gap is any guidance on choosing this over adjacent check tools.

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 100%, and the schema already explains both the single-column and composite-key forms and the omit-to-scan behavior. The description only restates that one or many columns may be passed, adding little beyond the structured field.

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 and resource ('Check whether a column ... works as a unique key') and even defines the criterion: no missing values, no repeats. An agent can tell this is a key-validity check rather than a general profiling tool. It stops short of naming how it differs from siblings like find_duplicates or check_missing, which is the only thing keeping it from a 5.

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

Usage Guidelines2/5

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

The description gives no when-to-use or when-not-to-use guidance and does not point at any alternative tool for overlapping tasks such as duplicate detection or null checking. The only usage hint (omit columns to scan candidate keys) lives in the schema, not the description.

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