Skip to main content
Glama

Binomial coefficient

bpj_discrete_binomial
Read-onlyIdempotent

Count unordered selections of k distinct elements from n without replacement.

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>",
      "k": "<k>"
    },
    "name": "bpj_discrete_binomial"
  }
}

Input Schema

NameRequiredDescriptionDefault
kYes
nYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

B3.2/5.0
Behavior3/5

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

Annotations already declare readOnlyHint, idempotentHint, openWorldHint=false and destructiveHint=false, so the safety profile is covered without the description. The description adds the mathematical contract (unordered, without replacement), but with no output schema it never states that an integer count is returned, nor what happens when k > n or when the maximum of 150 is exceeded.

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 front-loaded sentence with no filler or repetition. It is efficient, though so terse that no space is allocated to the constraint or return-value information an agent would need.

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 two-parameter pure-computation tool with no output schema, the definition covers the core operation but omits the return value (the count) and the k <= n domain constraint. Given the tool's simplicity these are modest gaps, but they are the ones an agent is most likely to trip over.

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 0%, so the description must carry parameter meaning, and it does partially: it identifies k as the selection size and n as the pool size, plus the unordered/without-replacement semantics. It stops short of the critical constraint that k must not exceed n, and never names the parameters explicitly, leaving some inference to the agent.

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 gives a specific verb ("count") and a precisely defined mathematical object ("unordered selections of k distinct elements from n without replacement"), which unambiguously identifies this as the binomial coefficient. It does not mention any sibling (e.g. permutations, Catalan, multiset variations), but the mathematical phrasing is distinctive enough to separate it from the listed discrete siblings.

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 use this versus alternatives; an agent must infer that counting ordered arrangements belongs to a permutation tool and that repetition-allowed counting is a different function. No preconditions such as k <= n are stated, and no exclusions are 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.