Skip to main content
Glama

Trustbase Lab · rCB & Chemical Recycling Data

Trade Flow Summary

get_trade_flow_summary
Read-onlyIdempotent

Purpose: aggregate the UN Comtrade carbon black (HS 280300) records for a period - per reporter totals forquantity and value, the weighted unit price, and the top-10 partner countries by quantity. Guidelines: passperiod (YYYY) or leave empty to aggregate all periods (2024-2025); weighted price equals total value divided bytotal quantity; pair with get_trade_partner_ranking to drill into a single reporter. Limits: customs-reportedtotals only - no commercial quote platform data; World aggregate rows are excluded from partner rankings; unitprices are not comparable across reporters where quantity reporting is incomplete. Ex:get_trade_flow_summary(period='2025'), get_trade_flow_summary(response_format='json').

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
periodNo期间 YYYY,如 2024;留空则汇总全部期间
response_formatNoOutput format: 'markdown' (default, human-readable) or 'json' (machine-readable).markdown

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
textYesHuman-readable result (markdown, or a JSON string when response_format=json).

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed2 schema fields changed
    • addedInput schema / properties / response_format / description
      Added value: +"Output format: 'markdown' (default, human-readable) or 'json' (machine-readable)."
    • changedOutput schema / (root)
      Previous value: -nullNew value: +{
      +  "additionalProperties": true,
      +  "properties": {
      +    "text": {
      +      "description": "Human-readable result (markdown, or a JSON string when response_format=json).",
      +      "type": "string"
      +    }
      +  },
      +  "required": [
      +    "text"
      +  ],
      +  "type": "object"
      +}
  2. Added

TDQS

A4.9/5.0
Behavior5/5

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

Annotations already mark the tool read-only and idempotent, and the description adds material behavioral caveats: World aggregate rows are excluded from partner rankings, unit prices are not comparable where quantity reporting is incomplete, and only customs-reported totals are included. This goes well beyond the structured annotations.

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?

The description is organized into Purpose, Guidelines, Limits, and Ex with the most important scoping information front-loaded. Every sentence adds value: output definition, input rule, calculation formula, sibling routing, data limitations, and examples.

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 read-only aggregation tool with zero required parameters, an output schema, and rich annotations, the description covers all the operational context an agent needs: input range, output scope, data caveats, and drilling into a single reporter. No significant gap remains.

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 coverage is 100%, so the baseline is 3, but the description adds usable parameter detail: the exact YYYY format, the empty-period behavior across 2024-2025, and concrete call examples for period and response_format. This is more than the schema alone supplies because it combines syntax with intended usage.

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?

The description opens with a precise verb and resource: aggregate UN Comtrade carbon black (HS 280300) records for a period, and lists exactly what is returned (per reporter totals, weighted unit price, top-10 partners). It also distinguishes itself from get_trade_partner_ranking by framing that sibling as the drill-down tool for a single reporter.

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?

Explicit Guidelines and Limits sections tell the agent how to form input (pass YYYY or leave empty to cover 2024-2025), how the weighted price is calculated, and when the data is not appropriate (customs-reported totals only, no commercial quote platform data). The pairing advice with get_trade_partner_ranking gives clear routing versus the nearest alternative.

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