Skip to main content
Glama

TradingCalc MCP — Crypto Futures Math

primitive.hedge_ratio

Calculate the short perpetual futures position size needed to hedge a spot holding. Use when user asks "how much should I short to hedge my BTC?" or "what margin do I need for a 100% hedge?". Returns: hedgeNotional, requiredMargin, estimatedFundingCost.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
leverageNoLeverage on the perp short. Default 1.
spotSizeYesSpot position value in USDT
hedgeRatioNoPercentage of spot to hedge, e.g. 100 for full hedge, 50 for half. Default 100.
fundingRatePctNoCurrent 8h funding rate as percentage, e.g. 0.01. Used for cost estimate.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4/5.0
Behavior3/5

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

No annotations provided, so description carries full burden. It discloses what the tool computes and returns (hedgeNotional, requiredMargin, estimatedFundingCost) and lists input parameters. However, it lacks details on behavioral traits like idempotency, computational constraints, or error handling, which are expected for a calculation tool.

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?

Extremely concise: two sentences front-loading the purpose and usage examples. Every word earns its place; no redundancy or irrelevant details.

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?

Given 4 parameters (1 required, no output schema), the description explains what the tool does, what it returns, and provides example queries. It adequately covers the core functionality but could mention potential limitations or assumptions for completeness.

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 100%, so the input schema already documents all parameters. The description adds minimal extra meaning beyond example usage (e.g., 'Default 1' for leverage is already in schema). Therefore, baseline score of 3 is appropriate.

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?

Clearly states the tool calculates the short perpetual futures position size for hedging a spot holding, with specific verb 'Calculate' and resource 'hedge ratio'. Examples like 'how much should I short to hedge my BTC?' directly convey the purpose, distinguishing it from sibling tools.

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

Usage Guidelines4/5

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

Provides explicit use cases via example queries (e.g., 'how much should I short to hedge my BTC?'). While it doesn't explicitly say when not to use or list alternatives, the examples give clear context for when this tool is appropriate.

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.