Skip to main content
Glama

Mode Calculator

calculator_mode
Read-only

Most frequent value(s). Supports unimodal and multimodal datasets.

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

Input Schema

NameRequiredDescriptionDefault
dataYesNon-empty list of numbers.

Output Schema

NameRequiredDescriptionDefault
statusNo
expressionYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

B3.2/5.0
Behavior3/5

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

The annotations already declare this a safe, read-only, closed-world computation, so the safety burden is lifted. The description adds one genuinely useful behavioral fact — that multimodal datasets yield multiple values rather than a single answer — but says nothing about tie handling, ordering of returned modes, or behavior on datasets with no repeats, and the presence of an output schema covers the return-shape question.

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?

Two short sentences with the core operation front-loaded and no filler. It is efficient, though the second sentence does more work than the first and the whole thing is close to under-specified rather than maximally concise.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a trivial one-parameter statistical tool with full schema coverage, an output schema, and read-only annotations, little is required — what is present is adequate. However, edge-case semantics (multiple modes returned as a list, ordering, single-mode datasets) are only half-addressed by the phrase 'unimodal and multimodal'.

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?

With a single parameter at 100% schema description coverage (including examples and a 'Non-empty list of numbers' constraint), the schema fully documents the input and the description adds nothing about it. Baseline 3 applies when structured data carries all parameter meaning.

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 description states the computed resource precisely — the most frequent value(s) of a dataset — which maps unambiguously onto the tool name calculator_mode and separates it from statistical siblings like mean, median, and range. It never names a sibling explicitly, but the concept is distinctive enough that confusion is unlikely.

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 guidance on when to choose mode over calculator_mean, calculator_median, or calculator_range, and no stated preconditions beyond what the schema enforces. The agent must infer the selection rule purely from the tool name.

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.