Resolution

All pages

13 · Execution

The broker boundary is where a specification becomes money. It is engineered as carefully as the kernel, because the failure modes here — a duplicated order after a crash, an order the fund does not know it has, a fill that never reaches the ledger — are the ones that end funds.

13.1 The gateway

  • R-EXEC-001 (MUST) The execution gateway is the only process holding a broker credential, the only process that talks to a broker, and it originates nothing: it acts on a signed decision carrying a valid, unexpired kernel verdict, and on nothing else.
  • R-EXEC-002 (MUST) Write-ahead intents. Before any message leaves for the broker, the gateway writes an intent to durable storage containing the deterministic client order id derived from the decision, the instrument, the side, the quantity and the sequence. After a crash, recovery reads the intents, queries the broker by those ids, and reconciles: an order that exists is adopted, an order that does not is re-sent or abandoned by rule. Zero duplicate orders across injected crashes is a pass condition, not an aspiration.
  • R-EXEC-003 (MUST) The order state machine is one implementation — new, working, partially filled, filled, cancelled, rejected, expired, unknown — with unknown a first-class state that triggers reconciliation rather than a guess. Amendments and cancels are transitions, not new orders.
  • R-EXEC-004 (MUST) Execution requires entitled, current quotes for the instrument's venue. A stale or unentitled quote is a data halt for that universe, not a reason to send anyway.
  • R-EXEC-005 (MUST) Legs are a kernel unit. A multi-leg structure is authorised, sent, filled and risk-checked as one object; a partially filled structure has a defined completion or unwind policy set before it is sent.
  • R-EXEC-006 (SHOULD) Execution policy is a table, not a model's choice. Policy rows — limit at the touch, participation-rate schedules, closing auction, patient passive with a time limit, immediate — are selected by code from the order's size against ADV, the spread, the urgency implied by the view's horizon, and the venue's capability record. The Execution trader annotates the choice and comments on the outcome; its record is implementation shortfall against the code default.
  • R-EXEC-007 (MUST) The venue capability record per universe and venue: order types supported, hours and auctions, tick and lot rules, self-match rules, short-sale rules and flags, fee schedule, idempotency semantics of the broker API, the calendar, and the known failure modes. No live capital in a universe without it.
  • R-EXEC-008 (MUST) Nothing is sent at the open except pre-armed conditional orders that the kernel authorised in advance.
  • R-EXEC-009 (MUST) TCA on every fill: implementation shortfall against the arrival price, against the fund's own paper model's prediction, and against the interval benchmark; fees and financing separated; attributed to the policy row, the venue and the time of day. TCA is a scored record, and a persistent gap between paper and live costs is a ladder gate failure.
  • R-EXEC-010 (MUST) The paper fill model is the fund's own, not the broker's simulator: it models spread, depth, participation, market impact by liquidity tier, borrow cost and availability, financing, fees, and partial fills, and it is never optimistic — it is calibrated against the fund's own live fills and adjusted only in the conservative direction between calibrations. The paper-versus-live gap per liquidity tier is a published number.

13.2 Crypto and custody

  • R-EXEC-011 (MUST) Crypto is spot only, on venues that pass a custody rule recorded as a written fact: segregation, withdrawal controls, proof-of-reserve or equivalent, jurisdiction, and the counterparty exposure limit that applies. A venue that does not pass is not enabled, and crypto exposure is capped as a counterparty exposure, not only as a market exposure.

13.3 What execution may never do

  • Send anything without a kernel verdict and a signed decision, below the highest autonomy rung.
  • Re-send after an ambiguous response without querying by the deterministic id first.
  • Hold a position the ledger does not know about for longer than one reconciliation cycle.
  • Let a model choose a size, a price or a venue.
  • Report a paper fill on terms the live venue would not have given.