Skip to main content
Glama

MCD y MCM

int-gcd-lcm
Read-onlyIdempotent

Calcula el MCD y MCM exactos de una lista de enteros de hasta 100 dígitos (BigInt, algoritmo de Euclides); el resultado es texto para no perder dígitos. Útil para fracciones, turnos y tamaños de lote. Cuándo: un resultado numérico tiene que ser exacto o reproducible y no estimado. No para: simplificar una fracción a su mínima expresión, con forma mixta y decimal (fraction-simplify). Efectos secundarios: ninguno (solo lectura, sin red, sin estado guardado). Determinista: la misma entrada da la misma salida. Límites: entrada JSON de hasta 64 KB, 1 s por llamada, resultado de hasta 1 MB.

EN: Computes the exact GCD and LCM of a list of integers of up to 100 digits each, computed with BigInt and Euclid's algorithm; returned as text, keeping every digit. Useful for fractions, shift rotations and batch sizes. When: a numeric result has to be exact or reproducible instead of estimated. Not for: reducing a fraction (fraction-simplify). [EN completo / full EN: inputSchema.description]

Input Schema

NameRequiredDescriptionDefault
numbersYesIntegers (array of integer/string; required; at least 2 items; up to 1000 items).

Output Schema

NameRequiredDescriptionDefault
gcdNo
lcmNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • addedInput schema / properties / numbers / examples
      Added value: +[
      +  [
      +    12,
      +    18,
      +    30
      +  ]
      +]
  2. Changed1 schema field changed
    • addedInput schema / description
      Added value: +"EN: Computes the exact GCD and LCM of a list of integers of up to 100 digits each, computed with BigInt and Euclid's algorithm; returned as text, keeping every digit. Useful for fractions, shift rotations and batch sizes. When: a numeric result has to be exact or reproducible instead of estimated. Not for: reducing a fraction (fraction-simplify). Side effects: none (read-only, no network access, no stored state). Deterministic: the same input gives the same output. Limits: JSON input up to 64 KB, 1 s per call, result up to 1 MB."
  3. First observed

TDQS

A4.6/5.0
Behavior5/5

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

Annotations already declare read-only, idempotent, non-destructive, and closed-world behavior; the description adds side-effect disclosure (no network, no stored state), determinism, text output to preserve digits, and concrete limits (64 KB input, 1 s per call, 1 MB result). These details are consistent with the annotations.

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?

The description is front-loaded and organized into useful sections (purpose, when, not for, side effects, determinism, limits). It loses some conciseness by duplicating the full text in Spanish and English, which is redundant for an English-reading agent.

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

Completeness5/5

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

For a one-parameter math utility with full annotations and an output schema, the description covers purpose, alternatives, side effects, determinism, and operational limits. No critical information needed for correct invocation is missing.

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?

The single 'numbers' parameter has 100% schema description coverage with type, pattern, min/max items, and examples. The description reinforces the 100-digit/BigInt handling but adds little parameter-specific guidance beyond the schema, such as edge-case handling for zero or negative values.

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?

States a specific verb and resource ('Calcula el MCD y MCM exactos de una lista de enteros'), specifies BigInt/Euclid and text output, and explicitly separates it from fraction-simplify. An agent can identify this as the exact GCD/LCM tool without opening the schema.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

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

Provides an explicit 'Cuándo' condition (numeric result must be exact or reproducible, not estimated) and a 'No para' exclusion pointing to fraction-simplify. It also names concrete use cases such as fractions, shift rotations, and batch sizes.

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