AAL Discrepancy Detection API · v3.1 · 6 Asset Classes · MarkitWire · Batch

Confirmation discrepancy detection for capital markets operations.

Send a raw confirmation — IRS, equity option, corporate bond, cap/floor, TRS, or CDS — and your internal trade economics. Receive a structured discrepancy report in under two seconds.

The architecture is deliberate: Claude extracts fields from unstructured text; deterministic code handles all arithmetic. No language model touches a number. Detection accuracy exceeds 99% and the false positive rate is zero — validated against 500 benchmark cases across two datasets. Coverage spans six asset classes, margin call disputes, and MarkitWire FIXML ingestion.

99%+
Confirmation detection accuracy — AAL-D-001
0.0%
False positive rate on clean confirmations
500
Benchmark cases across AAL-D-001 + AAL-D-002
500
Max batch size — confirm 500 pairs in one call
Example

One call. Two exceptions caught.

A confirmation arrives with a counterparty legal entity mismatch and a 0.5bp fixed rate break on $50M notional. Both are caught, classified, and exposure-estimated in a single API call.

The counterparty break drives severity to high and triggers escalation. The rate break is quantified at $2,500 exposure. No human reads the confirmation first.

Endpoint
POST https://aal-discrepancy-api-production.up.railway.app/v1/confirmations/validate
Structured JSON input
POST https://aal-discrepancy-api-production.up.railway.app/v1/confirmations/validate-raw
Raw FIXML or PDF text
POST https://aal-discrepancy-api-production.up.railway.app/v1/confirmations/batch
Up to 500 pairs, concurrent
POST https://aal-discrepancy-api-production.up.railway.app/v1/disputes/analyze
Margin call dispute detection
200 OK — response
{
  "match_id": "681ac165-0110-4abd-8e5b-ed23351c646b",
  "overall_status": "discrepant",
  "discrepancies": [
    {
      "field": "counterparty",
      "category": "EXC-CPTY",
      "expected": "Global Bank Capital Markets Inc",
      "extracted": "Global Bank Securities LLC",
      "severity": "high",
      "exposure_estimate_usd": null
    },
    {
      "field": "fixed_rate",
      "category": "EXC-PRICE",
      "expected": 4.125,
      "extracted": 4.130,
      "difference": 0.005,
      "severity": "low",
      "exposure_estimate_usd": 2500.00
    }
  ],
  "overall_severity": "high",
  "escalation_required": true,
  "recommended_action": "SOFR confirmation break. EXC-CPTY on counterparty | EXC-PRICE on fixed_rate (~$2,500) — Escalate; do not affirm.",
  "extraction_confidence": 0.95,
  "processing_ms": 1169
}
Quickstart

Four endpoints. Copy, paste, run.

Authentication

All requests require an API key in the Authorization header. Request a key via email — we onboard same day.

Authorization: Bearer sk-aal-xxxxxxxxxxxxxxxxxxxxxxxx
POST /v1/confirmations/validate

Structured JSON — single confirmation pair

curl -X POST https://aal-discrepancy-api-production.up.railway.app/v1/confirmations/validate \  -H "Authorization: Bearer $AAL_API_KEY" \  -H "Content-Type: application/json" \  -d '{
    "expected": {
      "counterparty": "Global Bank Capital Markets Inc",
      "notional_usd": 50000000,
      "fixed_rate_pct": 4.125,
      "effective_date": "2026-06-16",
      "maturity_date": "2029-06-16",
      "floating_index": "SOFR",
      "floating_spread_bps": 12.5
    },
    "confirmation_text": "...raw confirmation text..."
  }'
POST /v1/confirmations/validate-raw

Raw text — no structured input required

curl -X POST https://aal-discrepancy-api-production.up.railway.app/v1/confirmations/validate-raw \  -H "Authorization: Bearer $AAL_API_KEY" \  -H "Content-Type: application/json" \  -d '{
    "expected": { ... },
    "confirmation_text": "...raw PDF or email text..."
  }'
POST /v1/confirmations/batch

Up to 500 pairs — concurrent, ~6ms per pair

curl -X POST https://aal-discrepancy-api-production.up.railway.app/v1/confirmations/batch \  -H "Authorization: Bearer $AAL_API_KEY" \  -H "Content-Type: application/json" \  -d '{
    "pairs": [
      { "expected": {...}, "confirmation_text": "..." },
      { "expected": {...}, "confirmation_text": "..." }
    ]
  }'
POST /v1/disputes/analyze

Margin call dispute detection — 17 categories

curl -X POST https://aal-discrepancy-api-production.up.railway.app/v1/disputes/analyze \  -H "Authorization: Bearer $AAL_API_KEY" \  -H "Content-Type: application/json" \  -d '{
    "counterparty_notice": "...margin call notice text...",
    "internal_calculation": { ... },
    "csa_terms": { ... }
  }'
Response codes
200

Success — discrepancy report returned

400

Malformed request — check JSON schema

401

Invalid or missing API key

429

Rate limit exceeded — retry after header provided

500

Internal error — deterministic engine failure logged

Rate limits
/validate

100 req/min · 10 concurrent

/validate-raw

60 req/min · 5 concurrent

/batch

10 req/min · 1 concurrent — 500 pairs max

/disputes/analyze

30 req/min · 3 concurrent

Coverage

Six asset classes. One endpoint.

189 regression assertions · all passing
IRS

Interest Rate Swaps

Fixed/float, SOFR, LIBOR, cross-currency

EQUITY_OPTION

Equity Index Options

FIA/RILA call spreads, caps, SPX/RTY/NDX

FIXED_INCOME

Fixed Income

Corporate bonds, munis, agencies, structured

CAP_FLOOR

Caps & Floors

SOFR/LIBOR caps, floors, collars

TRS

Total Return Swaps

Rates TRS, cross-currency sovereign TRS

CDS

Credit Default Swaps

Single-name corporate and sovereign CDS

Exception taxonomy
EXC-CPTY

Counterparty

Legal entity mismatch — all asset classes

EXC-PRICE

Rate / Spread

Fixed rate, CDS spread, strike, forward rate

EXC-QTY

Notional / Size

Par value, notional, number of contracts

EXC-SDATE

Settlement date

Effective, maturity, termination date

EXC-PROD

Product terms

Day count, payment frequency, credit events, index

EXC-CCY

Currency

Settlement or notional currency mismatch

EXC-CUSIP

Security ID

CUSIP, ISIN, reference obligation identifier

EXC-DIR

Direction

Buy/sell, protection buyer/seller, TRS receiver/payer

EXC-TYPE

Instrument type

Call vs put, cap vs floor

EXC-COUP

Coupon

Reference obligation or bond coupon rate

EXC-MAT

Maturity

Reference obligation or bond maturity date

EXC-FX

FX rate

Initial spot rate on cross-currency structures

Architecture

LLMs classify. Code calculates.

01

LLM extraction

Claude Haiku parses raw confirmation text into structured fields — counterparty, notional, rates, dates, payment terms. Classification and extraction only. No arithmetic.

02

Deterministic reconciliation

Pure Python compares extracted fields against your expected economics field by field. All exposure math runs in code. No language model touches a number. Unit-tested against 250 ground-truth IRS cases.

03

Severity classification

Rule table maps exception category and dollar exposure to low / medium / high. Escalation flag set by category. Deterministic, auditable, zero hallucination risk on the number that matters.

AAL-D-001

Regression tested

The reconciliation engine is unit-tested against AAL-D-001 and AAL-D-002 — 189 assertions across six asset classes. The disputes engine is validated against AAL-D-002 (250 margin call cases, 17 dispute categories). Read the benchmarks →

Our benchmark data shows frontier models exceed 99% on discrepancy detection and plateau at 76–80% on financial arithmetic. The hybrid pipeline enforces the boundary in code — that is why the accuracy holds.

Design principle
The model detects. The code calculates.

No language model touches a dollar figure. Exposure arithmetic runs in deterministic Python, unit-tested against a public benchmark. That is why the false positive rate is zero.

Pricing

No contracts. No procurement cycle.

Pay-as-you-go
$0.35per confirmation
No monthly minimum
Card on file
Full API access
Same-day onboarding
Get API key
Growth
$250/ month
1,000 confirmations included
$0.20 per confirmation after
Priority support
Usage dashboard
Get API key
Enterprise
Custom
Volume pricing
SLA guarantee
On-prem / VPC option
Dedicated onboarding
Contact us

Ready to start? Email us to request an API key. We onboard same day. No sales call required.

Validate your deployment →joe@aialphalabs.ai