Skip to main content
Glama

Average Calculator

average_calculator
Read-onlyIdempotent

Compute mean, median, modes, range, sum, count, population and sample standard deviation, plus an optional separately weighted average.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
valuesYes1–1000 finite values in a common unit.
weightsNoOptional one weight per value; at least one positive weight. Weights affect only weightedAverage.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A3.5/5.0
Behavior3/5

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

Annotations already declare readOnlyHint, idempotentHint, destructiveHint=false, and openWorldHint=false, so the safety profile is fully covered. The description adds the useful fact that weighting applies only to a separately reported average (the other statistics stay unweighted), but says nothing about error behavior for mismatched weight/value lengths or invalid input. That is acceptable given annotation coverage, but not rich.

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?

A single sentence that front-loads the verb and resource, then lists outputs compactly. No filler or repetition of the title. The trailing 'plus an optional separately weighted average' clause is slightly awkwardly appended but still 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?

An output schema exists, so return values need not be explained, and both parameters are fully documented in the schema. The description covers what is computed and the weighted variant; the only gap is edge-case behavior (empty/oversized arrays, weight mismatch) which the schema bounds partially address.

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 documents units, bounds (±10^12), item limits (1–1000), and that weights must have at least one positive entry. The description's only parameter-level contribution is reinforcing that weights are optional and scoped to weightedAverage. Baseline 3 is appropriate when the schema does the heavy lifting.

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 uses a specific verb (compute) and enumerates exactly which statistics are produced: mean, median, modes, range, sum, count, population/sample standard deviation, plus an optional weighted average. This clearly separates it from numeric siblings like z_score, logarithm, or percentage_calculator, which compute different things from the same kind of input.

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?

There is no when-to-use / when-not-to-use guidance and no mention of alternate tools for related statistics. The only routing hint is the phrase 'optional separately weighted average', which signals a variant of the same operation rather than pointing at a sibling. For a self-evident calculator the omission is tolerable, but no explicit guidance is given.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources