Skip to main content
Glama

Catalan number

bpj_discrete_catalan
Read-onlyIdempotent

Calculate the number of balanced bracket strings with n pairs.

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": {
      "n": "<n>"
    },
    "name": "bpj_discrete_catalan"
  }
}

Input Schema

NameRequiredDescriptionDefault
nYes

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 readOnly=true, idempotent=true, destructive=false, and openWorld=false, so the safety profile is fully covered. The description adds that the result is a count derived from a combinatorial interpretation, but says nothing about the n<=150 ceiling causing a failure, the return type, or behavior at the boundaries n=0 and n=150.

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?

One sentence, front-loaded with the verb and resource, with no filler or redundancy. Nothing could be removed without losing meaning.

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 pure single-parameter math function with full annotation coverage and no output schema needed (it returns an integer), the definition is essentially sufficient. The remaining gap is the 150 upper bound's consequence and the exact return shape, which are minor for this tool class.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, so the description must carry the semantics of the single parameter, and it does: 'n pairs' tells the caller that n is the number of bracket pairs, not an index or a count of characters. The 0-150 bounds and integer type are left entirely to the schema.

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 pairs a specific verb ('Calculate') with a precisely characterized quantity ('number of balanced bracket strings with n pairs'), which unambiguously identifies the Catalan number computation. It does not name Catalan explicitly (only the title does) nor distinguish itself from the many bpj_discrete_* siblings, so it falls short of 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 Guidelines2/5

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

There is no when-to-use or when-not-to-use guidance, no naming of an alternative sibling such as bpj_discrete_binomial, and no stated prerequisites. The agent must infer usage purely from the mathematical definition 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.