Skip to main content
Glama

Validate Order

warden.validate_order
Read-onlyIdempotent

Validate proposed orders against house position and gross exposure floors before trade execution. Rejections cite the exact limit and report deviations for house or fund overrides.

Instructions

Validate a proposed order against the house floors (max position 25%, gross cap 60%).

order: {symbol, notional, side: buy|sell}; current_positions: {symbol: notional}. Per-fund overrides are allowed but the response always reports the deviation from the house floors. Rejections quote the exact floor — the same function gating live capital.

Input Schema

NameRequiredDescriptionDefault
orderYesProposed order: {symbol, notional, side: buy|sell}.
equityYesAccount equity (base currency) used for the exposure floors.
floor_overridesNoOptional per-fund overrides {max_position_pct, max_gross_exposure_pct}; the response always reports the deviation from the house floors.
current_positionsNoOptional {symbol: notional} map of current positions.

Output Schema

NameRequiredDescriptionDefault
howNo
toolNo
errorNo
accessNo
safetyNo
verdictNo
provenanceNo
violationsNo
house_floorsNo
fund_overridesNo
post_gross_pctNo
rejection_quoteNo
post_position_pctNo
request_access_atNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.4.1

TDQS

A3.7/5.0
Behavior4/5

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

Annotations already cover the safety profile (readOnly, idempotent, non-destructive, closed world), so the description earns credit for adding real behavior: per-fund overrides are permitted but the response always reports deviation from house floors, and rejections quote the exact floor. The 'same function gating live capital' note is meaningful operational context that the annotations cannot convey.

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-loaded with the core purpose and the actual floor thresholds, then input shapes, then override/rejection behavior. Dense and mostly waste-free, though the order/current_positions restatement duplicates the schema rather than adding information.

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?

An output schema exists, so return-value detail is unnecessary. The description covers the key behavioral edges an agent needs — overrides, deviation reporting, exact-floor rejection text, and live-capital gating — though it says nothing about units, edge cases such as missing symbols, or whether validation is purely advisory.

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%, so order, equity, floor_overrides, and current_positions are already documented in the schema. The description restates the order and current_positions shapes verbatim and repeats the floor_overrides deviation wording, adding essentially no semantics beyond the structured fields. Baseline 3 applies.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb+resource ('Validate a proposed order') and immediately grounds it in concrete domain semantics (house floors: max position 25%, gross cap 60%). It does not explicitly name a sibling to contrast with, but the pre-trade order-validation purpose is distinct from plan_rebalance, validate_genome, and explain_sizing.

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?

Usage is implied rather than stated: 'the same function gating live capital' signals this is the pre-trade check before capital is committed. There is no explicit when-to-use, when-not-to-use, or named alternative among the seven siblings.

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