Skip to main content
Glama

Agent Financial Advisor

Position sizing

position_size

Size a position the way a risk manager would: fixed-fractional risk to a stop, volatility targeting (ATR or annualized vol), or fractional Kelly from your edge statistics. Applies a max-position cap and round lots, and explains the binding constraint. Price: $0.005.

Input Schema

NameRequiredDescriptionDefault
atrNovolatility: average true range in price units.
sideNolong
equityYes
methodYes
avg_winNokelly: average win (any unit, same as avg_loss).
avg_lossNokelly: average loss as a positive number.
lot_sizeNoRound down to this multiple, default 1.
risk_pctNofixed_fractional: fraction of equity to risk, default 0.01.
win_rateNokelly: probability of a win (0-1).
annual_volNovolatility: annualized volatility of the asset (e.g. 0.35).
stop_priceNofixed_fractional: protective stop.
entry_priceYes
atr_multipleNovolatility: stop distance in ATRs, default 2.
kelly_fractionNokelly: fraction of full Kelly to use, default 0.25.
allow_fractionalNo
max_position_pctNoCap on position value / equity, default 0.2.
target_annual_vol_contributionNovolatility: target vol contribution as fraction of equity, default 0.02.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • addedInput schema / examples
      Added value: +[
      +  {
      +    "entry_price": 100,
      +    "equity": 50000,
      +    "method": "fixed_fractional",
      +    "risk_pct": 0.01,
      +    "stop_price": 95
      +  }
      +]
  2. First observed

TDQS

B3.4/5.0
Behavior3/5

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

With no annotations, the description carries the full burden: it does disclose that a max-position cap and round lots are applied and that the result explains the binding constraint, which is useful beyond the schema. It omits what the tool returns in concrete terms (shares vs notional), how invalid or conflicting inputs are handled, and any authentication requirements, though the stated $0.005 price gives partial cost context.

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 tight sentences, front-loaded with the core action and method list, followed by applied constraints and the price. Every clause is informative, though the trailing price mention is slightly promotional in placement.

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 17-parameter tool with no output schema and no annotations, the description is adequate but thin: it never states which parameters are conditional on which method, and allows an undocumented 'allow_fractional' plus unlabeled 'side'/'entry_price'. It does at least signal that the response includes a binding-constraint explanation.

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 71%, so the schema already explains most parameters including per-method fields. The description adds only the method vocabulary and the cap/round-lot behavior, leaving per-method required inputs (e.g. stop_price for fixed_fractional, win_rate/avg_win/avg_loss for Kelly) for the agent to infer from individual field descriptions.

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 uses a specific verb and resource ('size a position') and enumerates the three supported methods (fixed-fractional, volatility targeting, fractional Kelly), so an agent knows exactly what computation it performs. It does not explicitly contrast itself with siblings like pre_trade_check or options_risk_check, which keeps it off the top mark.

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

Usage Guidelines3/5

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

Method choice is implicitly signposted by naming the inputs each method relies on ('risk to a stop', 'ATR or annualized vol', 'fractional Kelly from your edge statistics'), which hints at when each applies. However, there is no explicit when-to-use/when-not-to-use guidance and no routing to sibling tools for pre-trade or suitability checks.

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.