Skip to main content
Glama

prediction.orderbook_imbalance_ratio

Read-only

A single Polymarket outcome's bid-side vs ask-side order-book depth ratio, summed within depth_band_pct (default 5.0%) of each side's own best quote. 0.5 = balanced, closer to 1.0 = bid-side depth dominant, closer to 0.0 = ask-side dominant. A descriptive statistic only - not a prediction of price direction. Accepts either a raw token_id or a market_slug (+ outcome) to resolve it automatically. Paid in USDC on Base.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
outcomeNo"yes" (default) or "no" - which side to resolve when using market_slug.
token_idNoThe outcome's CLOB token_id / asset_id, if already known.
market_slugNoExact Polymarket market slug, used to resolve token_id automatically.
depth_band_pctNoHow far into the book, as a percent of each side's own best quote, to sum depth. Defaults to 5.0.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
noticeNo
best_askNo
best_bidNo
token_idYes
data_sourceYes
market_slugNo
generated_atYes
depth_band_pctYes
imbalance_ratioNo
ask_depth_sharesYes
bid_depth_sharesYes
book_snapshot_timeNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4.1/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, and the description adds real value beyond them: the interpretive caveat that this is a descriptive statistic and not a price-direction signal, plus cost/payment context ('Paid in USDC on Base'). It stops short of stating actual pricing, rate limits, or refresh cadence.

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?

Three compact sentences, front-loaded with the metric definition and followed by scale interpretation, input modes, and cost. Each sentence carries information, though the opening sentence is dense enough that a reader has to parse it twice.

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 an output schema present, return values need no explanation, and annotations cover the safety profile. The description covers the metric, its interpretation, the input alternatives, and payment, leaving only minor gaps such as latency or freshness expectations.

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%, so the baseline is 3, but the description goes further by explaining the either/or resolution logic between token_id and market_slug+outcome and restating the 5.0% band default. It also anchors how to read the output value (0.5 balanced, toward 1.0 bid-dominant, toward 0.0 ask-dominant), which the schema cannot convey.

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 precise metric ('bid-side vs ask-side order-book depth ratio, summed within depth_band_pct of each side's own best quote') and defines its scale, which alone separates it from siblings like prediction.bid_ask_spread_pct and prediction.liquidity_depth_after_haircut. An agent can identify the operation and its exact computation without opening the schema.

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?

It explains the alternative input paths clearly ('raw token_id or a market_slug (+ outcome)'), which is genuine usage guidance for call construction, and it warns the result is descriptive not predictive. But it never says when to reach for this tool over the other prediction.* siblings, so the comparative guidance is only implied.

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.