Skip to main content
Glama

Weather Markets Edge Desk

Kelly Position Size

kelly_size
Read-only

Compute the optimal Kelly position size for a prediction-market contract. Given your win probability, the market price (which sets the payout), your bankroll, and a Kelly fraction (full / half / quarter / eighth), returns the dollar stake and a risk rating. Use for "how much should I stake", "what is my position size", "Kelly sizing for this trade".

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
bankrollNoTotal bankroll in dollars (e.g. 1000). Optional — omit it and the result is the % of bankroll to stake, without a dollar figure. Accepts a number or a numeric string ("1000", "$1,000").
fractionNoKelly fraction to apply. Half-Kelly is the common sharp-money default.half
marketPriceYesContract price in cents (1–99). Sets the payout ratio. Accepts 55, "55%", "55¢", "$0.55", 0.55 or American odds (+120 / -150) — all read as 55%.
winProbabilityYesYour probability the contract resolves YES, in % (0–100). Accepts 55, "55%", "55¢", "$0.55", 0.55 or American odds (+120 / -150) — all read as 55%.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A3.9/5.0
Behavior3/5

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

The annotations declare readOnlyHint=true, so the safe, non-mutating nature is already covered. The description adds that the result is a dollar stake and a risk rating, but it does not disclose edge cases such as what happens when winProbability is below or equal to the market price, nor what the risk rating values actually mean. This leaves some behavioral ambiguity.

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 two sentences with no filler. It front-loads the core computation, then lists inputs and outputs, and ends with concrete query examples. Every sentence earns its place and the structure makes the tool easy to scan.

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 calculation tool with no output schema, the description does state the outputs ('dollar stake and a risk rating') and all inputs. However, it leaves the 'risk rating' undefined and does not explain behavior when no Kelly bet is warranted, which an agent would benefit from knowing before invoking the tool.

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%, and the schema already documents each parameter, including accepted formats, defaults, and optionality. The description restates the key parameters but does not add significant new semantic meaning beyond what the schema already provides, so the 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?

The description opens with a specific verb and resource: 'Compute the optimal Kelly position size for a prediction-market contract.' It clearly lists the inputs (win probability, market price, bankroll, Kelly fraction) and outputs (dollar stake and risk rating), making the tool's function unmistakable even among many 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?

The description explicitly provides user-intent triggers: 'Use for "how much should I stake", "what is my position size", "Kelly sizing for this trade".' This gives clear context on when to invoke the tool. However, it does not mention when not to use it or name any alternative tool, so it falls just short of full exclusion guidance.

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.