Skip to main content
Glama

Expansion

calculator_expand
Read-only

Expand products/powers, e.g. (x+2)(x+3) → x² + 5x + 6.

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": {
      "expression": "<expression>"
    },
    "name": "calculator_expand"
  }
}

Input Schema

NameRequiredDescriptionDefault
expressionYesExpression to expand.

Output Schema

NameRequiredDescriptionDefault
resultYes
expandedNo
expressionYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

B3.3/5.0
Behavior2/5

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

Annotations already declare readOnlyHint=true, destructiveHint=false and openWorldHint=false, so the safety profile is covered. The description adds essentially nothing behavioral beyond that — no statement about supported operators/variables, whether symbolic constants are allowed, or how the expanded result is returned, despite an output schema existing to complement.

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?

One short sentence with the operation front-loaded and the example doing the disambiguating work — nothing wasted. It is efficient, though the example is the only thing carrying precision.

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 single-parameter, read-only, output-schema-backed computation tool, the definition is sufficient to call correctly. The remaining gap — which expression forms are in scope (single vs. multiple variables, supported operators) — is minor but real.

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 carries two concrete examples including the '**' power syntax, so the parameter is already documented. The description's inline example ('(x+2)(x+3)') marginally reinforces accepted input syntax but adds no rules the schema lacks. Baseline 3 applies.

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?

Names a specific operation (expand products/powers) and anchors it with a concrete input→output example, so an agent knows exactly what it produces. It doesn't explicitly distinguish itself from near siblings like calculator_simplify, calculator_factor, or calculator_polynomial, 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 Guidelines3/5

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

Usage is only implied by the worked example: 'use this when you have a product of binomials or a power.' There is no explicit when-to-use statement, no mention of when to prefer calculator_simplify or calculator_factor instead, and no prerequisites.

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.