Skip to main content
Glama

describe_by_group

Compute per-group descriptive statistics (mean, median, std, min, max) across all numeric columns in one call, avoiding multiple aggregate calls.

Instructions

Descriptive statistics per group: mean, median, std, min, max for each numeric column within each group. One call replaces many separate group_aggregate calls. If numeric_columns is empty, uses all numeric columns. Example: describe_by_group(group_column="CargoType", numeric_columns=["Revenue","ChargeableWeight"])

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
df_nameNo
group_columnYes
numeric_columnsNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior3/5

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

No annotations are provided, so the description carries the transparency burden. It discloses a useful default behavior (empty numeric_columns uses all numeric columns), but does not mention whether the operation is read-only, side effects, or requirements like column types. Moderate transparency for a simple stats 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?

Three sentences, front-loaded with the tool's purpose, followed by an efficiency note and an illustrative example. No redundancy or filler.

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?

Output schema exists, so return values are documented externally. The description covers key inputs and a default behavior, though it omits df_name semantics. Given the tool's simplicity, this is nearly complete for agent selection and invocation.

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 descriptions cover 0% of parameters, so the description must compensate. It explains the numeric_columns default behavior and provides an example for group_column and numeric_columns, but df_name is never explained. Partial compensation for parameter semantics.

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 computes descriptive statistics (mean, median, std, min, max) per group for numeric columns. It also distinguishes itself from sibling group_aggregate by noting it replaces many separate group_aggregate calls.

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 explicitly advises using this tool instead of many group_aggregate calls, providing clear usage context. It gives a concrete example, but it does not specify situations where group_aggregate might be preferred, so exclusions are absent.

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/AstyanM/mcp-data-science'

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