Skip to main content
Glama

Get Position Size

get_position_size
Read-only

Turn a signal + bankroll into a concrete position: fractional-Kelly size capped by orderbook liquidity, ATR-based stop, liquidation price at chosen leverage, funding carry cost, and % bankroll at risk. Warns when liquidation sits inside the stop. Ground win_rate_pct with get_signal_performance or get_signal_backtest first.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
assetYesAsset, e.g. "BTC"
leverageNoIntended leverage (default 3x)
directionYesTrade direction
payoff_ratioNoAvg win / avg loss ratio (default 1.5)
win_rate_pctNoEstimated win probability % (use get_signal_performance or get_signal_backtest to ground this)
bankroll_usdcYesTotal capital available in USDC
kelly_fractionNoFraction of full Kelly to use (default 0.25 — quarter Kelly)
max_slippage_pctNoMax acceptable slippage % — caps size by orderbook depth

TDQS

A4.4/5.0
Behavior4/5

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

The description discloses computation-only behavior, consistent with readOnlyHint=true. It warns about liquidation inside stop and mentions caps by orderbook liquidity, adding behavioral context beyond annotations.

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?

Three efficient sentences: first lists outputs, second warns about liquidation, third advises on parameter grounding. No redundant words, front-loaded with key action.

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 8 parameters and no output schema, the description adequately outlines the major outputs and purpose. It could include return format or more details on liquidity capping, but it's sufficient for an agent to understand tool scope.

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?

Schema coverage is 100%, and the description adds usage context (e.g., grounding win_rate, capping by liquidity). While individual parameter details are in schema, the description gives semantic meaning to the overall computation and parameter interplay.

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 clearly states the tool's purpose: turning a signal and bankroll into a concrete position, listing specific outputs like fractional-Kelly size, stop, liquidation price. It distinguishes from other get_* tools which focus on data retrieval, not position sizing.

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 advises grounding win_rate_pct with get_signal_performance or get_signal_backtest first, providing explicit prerequisite guidance. However, it does not explicitly state when not to use or give alternatives beyond that.

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.

TDQS

A3.7/5.0
Disambiguation3/5

Many tools are specialized, but several pairs have fuzzy boundaries: e.g., get_funding_rates vs get_top_funding_rates, get_basic_macro vs get_macro_context, get_simple_iv vs get_options_iv. An agent could easily select the wrong one.

Naming Consistency4/5

Most tools follow a 'get_X' pattern with descriptive noun phrases. There are a few exceptions like 'create_api_key' and 'search_markets', but overall the convention is consistent and readable.

Tool Count2/5

With 47 tools, the server is overloaded. While the domain is broad, this many tools makes discovery and selection difficult for an agent, reducing coherence.

Completeness5/5

The tool set covers an impressively wide range: macro data, funding, prediction markets, OI history, whale tracking, risk analytics, position sizing, backtesting, and signal generation. It leaves no obvious gaps for a crypto trading assistant.