Skip to main content
Glama

Quant Arbitrage & Risk Calculator MCP

kelly_position_sizer

Calculate exact full Kelly %, fractional Kelly %, capped position stake, expected value (EV %), breakeven probability, and edge check for binary payoff trades.

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": {
      "p": "<p>",
      "bankroll": "<bankroll>"
    },
    "name": "kelly_position_sizer"
  }
}

Input Schema

NameRequiredDescriptionDefault
pYesEstimated win probability in [0, 1].
bankrollYesTotal bankroll in quote currency (e.g., USD).
fractionNoKelly multiplier (e.g., 0.25 for quarter-Kelly).
decimal_oddsNoDecimal odds (> 1, e.g., 2.0 for even money). Specify either decimal_odds or payoff_ratio.
payoff_ratioNoNet win/loss payoff ratio b (> 0, e.g., 1.5 means win 1.5x per 1x risked). Specify either decimal_odds or payoff_ratio.
max_position_pctNoHard cap on position size as percentage of bankroll (0..100, e.g., 10 for 10%).

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A3.7/5.0
Behavior3/5

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

No annotations exist, so the description carries the full burden. It usefully discloses the exact outputs computed (including an edge check, hinting at non-positive-Kelly handling), which substitutes for a missing output schema, but says nothing about error behavior when both decimal_odds and payoff_ratio are supplied, rounding/precision, or what a failed edge check returns.

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?

A single front-loaded sentence naming the verb first and the computed outputs after, with zero filler. Nothing in it is redundant or padded.

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?

Because there is no output schema, the description must explain return values, and it does enumerate them. However, it leaves the semantics of the "edge check" and "breakeven probability" unexplained and does not cover edge cases for a pure-computation tool, so it is adequate but not complete.

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 coverage is 100%, so every parameter is already documented in the input schema, including the decimal_odds vs payoff_ratio alternative and the fraction and max_position_pct ranges. The description adds no format or interaction detail beyond what the schema provides, so the baseline of 3 applies.

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?

Specific verb ("Calculate") plus an enumerated set of outputs: full Kelly %, fractional Kelly %, capped stake, EV %, breakeven probability, and edge check. Combined with the "binary payoff trades" scope, an agent can distinguish this from arbitrage-style siblings like arb_stake_allocator or funding_carry_breakeven.

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?

The description implicitly scopes usage to binary payoff trades and signals that fractional Kelly and capping are supported, but it never states when to prefer this over a sibling allocator or when a fractional multiplier is appropriate. Usage must be inferred from the output list rather than stated.

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