Skip to main content
Glama

finance_position_size

Read-only

Trade position size and Kelly — Risk-based position sizing for stocks, futures or crypto: units to buy or short so a stop-out loses a set percent of the account, with position value, actual risk, stop distance, max-position cap, and with target= the R multiple, profit at target and breakeven win rate; with win_rate= also expectancy and full/half Kelly with a verdict. Params: account, entry, stop; optional risk (% default 1), target, win_rate, max_position (%), lot, fee, multiplier (contract size). Offline. Price: $0.002 USDC (Base, via x402).

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": {
      "account": "<account>",
      "entry": "<entry>",
      "stop": "<stop>"
    },
    "name": "finance_position_size"
  }
}

Input Schema

NameRequiredDescriptionDefault
stopYes95
entryYes100
accountYes50000

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4.2/5.0
Behavior4/5

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

Annotations already declare readOnlyHint=true and destructiveHint=false, so safety is covered; the description adds genuinely new behavior — that the tool runs offline, computes locally, and costs $0.002 USDC via x402 on Base. That cost/payment disclosure is meaningful for an agent deciding whether to call it. It does not describe error handling for invalid stops or missing data.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness3/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The purpose is front-loaded and the 'Params:' list is an efficient way to enumerate inputs, but the core is one long semicolon-chained sentence that is hard to parse. The density earns its place, yet the sentence structure could be broken into shorter units without losing content.

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?

There is no output schema, and the description compensates by enumerating what comes back — position value, actual risk, stop distance, max-position cap, R multiple, profit at target, breakeven win rate, expectancy, and Kelly verdict. Combined with the offline and pricing notes, an agent has enough to call it correctly; only the optional-parameter mismatch and error behavior are gaps.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Nominal schema coverage is 100%, but the schema's property descriptions are only bare examples ('95', '100', '50000'), so the description carries real semantic weight: risk as a percent with default 1, max_position as a percent, multiplier as contract size, plus lot and fee. However, it lists optional parameters (risk, target, win_rate, max_position, lot, fee, multiplier) that do not appear in the supplied input schema, which is a mismatch an agent could trip over.

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 names a specific computation — risk-based position sizing in units for stocks/futures/crypto such that a stop-out loses a set percent of the account — plus the Kelly extension. The topic is distinct enough from the surrounding finance calculators (tax, DCF, break-even) that an agent can route to it without inspecting siblings.

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?

It gives conditional guidance for the optional inputs: 'with target= the R multiple...' and 'with win_rate= also expectancy and full/half Kelly with a verdict,' which tells the agent which outputs each optional parameter unlocks. It does not state when to prefer this tool over a sibling calculator or when it is inappropriate, so it stops short of full routing 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.

Resources