Skip to main content
Glama

Remove Outliers

remove_outliers

Detect and remove rows with outliers in selected numerical columns using IQR trimming; missing values are preserved and zero-IQR columns are skipped.

Instructions

Remove rows that have an outlier in any of the checked numerical columns (IQR trimming). Rows with missing values are kept. Columns where IQR is 0 (flags, one-hot columns) are skipped. Args: dataset_id (str): ID of the dataset. columns (list[str], optional): Numerical columns to check. Default is all numerical columns (consider excluding the target column). Returns: dict: rows before and after, rows removed, the bounds used and the skipped columns.

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_id": "<dataset_id>"
    },
    "name": "remove_outliers"
  }
}

Input Schema

NameRequiredDescriptionDefault
columnsNo
dataset_idYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4/5.0
Behavior4/5

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

With no annotations supplied, the description carries the full burden and does reasonably well: it discloses edge-case behavior (rows with missing values kept, zero-IQR columns skipped) and what the return payload contains (rows before/after, rows removed, bounds, skipped columns). The main undisclosed trait is whether the dataset is mutated in place or a new dataset is produced, which matters for a filtering operation.

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?

Front-loaded with the core action and method, followed by compact edge-case notes and an Args/Returns block with no filler. Slightly verbose in the Returns enumeration, but every line conveys distinct information.

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 two-parameter transformation tool with no output schema and no annotations, the definition covers method, defaults, edge cases, and return shape, which is close to sufficient. The remaining gap is persistence semantics (in-place vs new dataset) and any note on how the IQR bounds are computed (multiplier used).

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

Parameters5/5

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

Schema description coverage is 0%, so the description must explain both parameters, and it does: dataset_id is the dataset ID, and columns is scoped to numerical columns checked with a default of all numerical columns plus a caution about the target column. This is the meaningful compensation the low-coverage schema requires.

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 ('Remove'), resource ('rows'), and method ('outlier in any of the checked numerical columns (IQR trimming)'), which implicitly separates it from cap_outliers (capping vs removal) and drop_missing (missing vs outlier). It does not explicitly name a sibling alternative, so it stops short of 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 Guidelines3/5

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

Usage is only implied: the parenthetical '(consider excluding the target column)' is the single piece of actionable advice about when/how to call it. There is no explicit guidance to prefer this over cap_outliers or detect_outliers first, nor any stated precondition beyond the parameter default.

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

Deploy Server

Other Tools