Skip to main content
Glama

position_size

Read-onlyIdempotent

Position sizing for linear USD shares/coins: prices in USD, account risk in percent, fees/slippage in basis points, quantity increment in units. Returns results, conditions, assumptions, an editable link, share page and PNG. No account access or order execution.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
feeNoFee per fill in basis points; negative maker fees are rebates in the spread model.
riskNoLoss budget as a percentage of the account.
stopNoStop price.
entryNoTrade entry price.
targetNoTrade target price, or target inventory percentage for inventory quotes.
balanceNoAccount balance in dollars.
slippageNoSlippage per side in basis points.
unitStepNoQuantity increment; 0 disables rounding.
directionNolong or short.long
maxLeverageNoMaximum notional exposure divided by equity.
include_imageNoAlso inline a PNG no wider than 1000 pixels. Image URL is always returned.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
metricsYes
resultsYes
edit_urlYes
image_urlYes
share_urlYes
calculatorYes
conditionsYes
disclaimerYes
assumptionsYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A3.5/5.0
Behavior4/5

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

Annotations already cover readOnly, idempotent, non-destructive, and closed-world behavior, so the bar is lower. The description still adds real value by naming the return artifacts ('results, conditions, assumptions, an editable link, share page and PNG') and explicitly disclaiming side effects ('No account access or order execution'), which reassures an agent this is a pure calculation.

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?

Two tightly packed sentences with the core purpose front-loaded and no filler. The unit enumeration in sentence one is dense but each clause maps to real parameters, so it earns its place. Minor cost: the unit list reads like a schema echo rather than new information.

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?

With an output schema present, the description needn't explain return values, yet it still summarizes them usefully. All 11 params are optional and fully described in the schema, and the safety profile is covered by annotations. The only missing element is sibling routing, which is a usage-guideline concern rather than a completeness gap.

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 schema already documents all 11 parameters with defaults, bounds, and units. The description's unit summary (USD prices, percent risk, basis-point fees, unit increments) largely restates what the schema provides and adds no syntax or edge-case semantics beyond it. Baseline 3 applies.

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 states a specific operation and resource: 'Position sizing for linear USD shares/coins', followed by the unit conventions it operates in. An agent can tell what it computes, but nothing distinguishes it from conceptually adjacent siblings like trade_expectancy or inventory_quotes (the latter only surfaces in the schema for the 'target' param, not the description).

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 guidance, no exclusions, and no routing to alternatives among the seven siblings. The unit conventions hint at legitimate inputs but never say under what conditions this tool should be chosen over trade_expectancy or inventory_quotes. The agent must infer usage entirely from the name.

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