Skip to main content
Glama

Running totals within groups

bpj_table_group_running_total
Read-onlyIdempotent

Accumulate a numeric measure in original row order separately for each category.

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": {
      "rows": "<rows>",
      "group": "<group>",
      "column": "<column>"
    },
    "name": "bpj_table_group_running_total"
  }
}

Input Schema

NameRequiredDescriptionDefault
rowsYes
groupYes
columnYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

B3.1/5.0
Behavior3/5

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

Annotations already declare readOnlyHint, idempotentHint, non-destructive and closed-world, so the safety profile is covered. The description contributes genuine extra context by specifying that accumulation follows original row order per category, which materially affects results. It does not say how results are returned (a new column appended? a parallel array? replaced values?), leaving a real behavioral gap.

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 tightly written sentence with the accumulation rule front-loaded and no filler. It is efficient, though its brevity borders on under-specification given the 0% schema coverage.

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

Completeness2/5

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

For a three-parameter transformation with no output schema and no documented parameter formats, the description omits the return shape (where the running total appears) and input encoding. An agent could guess the intent but not confidently construct a call or interpret the result from the definition alone.

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; it does map loosely onto all three ('numeric measure' → column, 'each category' → group, 'original row order' → rows). However it never states that rows is a JSON-encoded record array string, nor that group and column are column-name strings, which the bare titles only hint at.

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 names a specific verb and resource ('Accumulate a numeric measure') and states the scoping rule ('separately for each category', 'original row order'). This distinguishes it reasonably from siblings like bpj_table_group_total (a single total per group) and bpj_table_group_percent_of_total (share of group), though it never names those alternatives explicitly.

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 this over the many adjacent group-aggregation siblings, and no stated preconditions (e.g., that the measure column must be numeric or that rows must already be ordered as desired). The agent must infer selection criteria entirely from the one-line purpose statement.

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.