Skip to main content
Glama

check_constraint_live

Read-only

Fetch live quotes and fee schedules for related markets to test whether prices violate a no-arbitrage relation after fees. Returns violation status, profitable basket, and net edge.

Instructions

Fetch live quotes and fee schedules for related markets, then check whether their prices violate a no-arbitrage relation after fees.

This is the main research call: find related contracts with search_markets,
confirm with get_market that their resolution rules really satisfy the
relation, then pass them here. Read-only: it calls the venues' public APIs
and places no orders. Returns the check_constraint result (violated,
profitable_after_fees, best basket with net edge) plus the quotes it used;
to simulate the trade, call paper_order for each leg of the best basket.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
makerNoPrice fees as resting maker orders instead of taker orders (default false). Maker fees are lower or zero, but a resting order may not fill.
marketsYesMarkets to check, each {venue, market_id}, in the order the relation expects: two for implication (A then B), complement and same_event; every outcome for exclusivity and event_sum. Venues may be mixed.
relationYesBound to test: implication (A implies B, so P(A) <= P(B)), exclusivity (at most one outcome happens), complement (exactly one of two), same_event (one event quoted on two venues) or event_sum (exactly one of n). See list_relation_types.
contractsNoContracts bought on every leg (default 1). Fees scale with size.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed7 schema fields changedv1.2.2
    • addedInput schema / $defs / MarketRef / description
      Added value: +"A live market to check, identified by venue and market id."
    • addedInput schema / $defs / MarketRef / properties / market_id / description
      Added value: +"Kalshi ticker or Polymarket market id, as returned by search_markets."
    • addedInput schema / $defs / MarketRef / properties / venue / description
      Added value: +"'kalshi' or 'polymarket'."
    • addedInput schema / properties / contracts / description
      Added value: +"Contracts bought on every leg (default 1). Fees scale with size."
    • addedInput schema / properties / maker / description
      Added value: +"Price fees as resting maker orders instead of taker orders (default false). Maker fees are lower or zero, but a resting order may not fill."
    • addedInput schema / properties / markets / description
      Added value: +"Markets to check, each {venue, market_id}, in the order the relation expects: two for implication (A then B), complement and same_event; every outcome for exclusivity and event_sum. Venues may be mixed."
    • addedInput schema / properties / relation / description
      Added value: +"Bound to test: implication (A implies B, so P(A) <= P(B)), exclusivity (at most one outcome happens), complement (exactly one of two), same_event (one event quoted on two venues) or event_sum (exactly one of n). See list_relation_types."
  2. First observedv1.2.1

TDQS

A4.4/5.0
Behavior4/5

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

Annotations declare readOnlyHint and openWorldHint; the description reinforces this by stating it calls public APIs and places no orders, and it discloses the return payload (violated, profitable_after_fees, best basket, quotes used). It does not discuss rate limits or failure modes, but it adds solid behavioral context.

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?

Front-loads the action, then the workflow, then the return/simulation note. Slightly verbose, but every sentence carries routing or behavioral information rather than filler.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

With annotations covering safety and an output schema covering returns, the description still adds the call-order workflow and simulation next step. Nothing an agent needs to invoke it correctly is missing.

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% and the enums/field descriptions are thorough; the description reinforces the ordering requirement (two for implication, every outcome for exclusivity) which the schema also states. Baseline 3 is appropriate since the schema carries the parameter detail.

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?

States specific verbs and resources: fetches live quotes/fee schedules and checks a no-arbitrage relation after fees. It is clearly distinguished from the sibling check_constraint (static) by the 'live' framing and by naming the surrounding workflow tools.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Explicitly routes the agent: find related contracts with search_markets, confirm with get_market, then call this, and use paper_order to simulate each leg of the best basket. This covers when to use it and the prerequisites/alternatives.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.