---
name: polykalshi-edge-scanner
description: "Scan live Polymarket and Kalshi orderbooks for fee-adjusted cross-venue arbitrage spreads, single-venue Dutch-book baskets, and UMA vs CFTC settlement-rule resolution traps."
---

# PolyKalshi Edge & Resolution-Guard Skill

Flat callable prediction-market arbitrage and settlement-risk engine for AI assistants, coding agents, and quantitative trading scripts. Zero wallet custody, read-only Polymarket Gamma/CLOB and Kalshi Trade API v2 analytics, deterministic settlement-rule diffing, and zero prompt or trace resale.

## Core Capabilities

- **Cross-Venue Fee-Adjusted Arbitrage (`scan-arb`)**: Compares live Polymarket and Kalshi orderbooks after exact Kalshi quadratic taker fees (`ceil(0.07 * C * P * (1 - P) * 100) / 100`), Polymarket optional taker fees, and top-3 CLOB orderbook depth enrichment.
- **Deterministic Resolution-Guard (`resolution-diff`)**: Audits two venue rule texts and ISO close timestamps for `MAJOR_EXPIRY_DIVERGENCE`, `DATE_MISMATCH_GT_48H`, `COMPARATOR_DIRECTION_MISMATCH`, `STRIKE_VALUE_MISMATCH`, `TOUCH_VS_CLOSE_TRAP`, and `ORACLE_SOURCE_DIVERGENCE`, outputting a 0-100 score and verdict (`SAFE_MATCH`, `CAUTION_REVIEW_RULES`, `TRAP_DO_NOT_ARB`).
- **Single-Venue Dutch-Book Radar (`scan-dutch-book`)**: Scans mutually exclusive multi-outcome events (`enableNegRisk` / `mutually_exclusive: true`) for sum-of-asks below `$1.00` after per-leg fees plus liquid wide-spread books.
- **Exact Edge & Kelly Sizing (`calc-edge`)**: Computes net profit, ROI %, edge in bps, annualized APR, breakeven pair ask sum, and 25%-capped fractional Kelly allocation.

## Quick Invocation

### 1. Via `treg hub` (`$0.025`/verified hit, `$0.00` on empty or degraded venue)

```bash
treg call polykalshi-edge-scanner \
  --data '{"action":"scan-arb","q":"Fed","min_edge_bps":"25","limit":10,"contracts":100}'
```

### 2. Via Streamable MCP (`/mcp`)

```bash
curl -sS -X POST https://api.polykalshi.example.com/mcp \
  -H "Content-Type: application/json" \
  -H "X-API-Key: ${POLYKALSHI_API_KEY}" \
  -d '{"jsonrpc":"2.0","id":1,"method":"tools/call","params":{"name":"polykalshi_scan_arb","arguments":{"q":"BTC","min_edge_bps":20,"limit":10,"contracts":100}}}'
```

### 3. Via Causal Bazaar Public Card

- `card_id`: `polymarket_kalshi_arb_scanner_v1` (`is_public=1`, `price_micros=25000` / `$0.025`/call)
- Supported actions: `health`, `demo-preview`, `scan-arb`, `scan-dutch-book`, `resolution-diff`, `calc-edge`

## Prepaid Credit Packs (Creem.io Live Checkout)

- Starter ($19 / 500 scans): https://www.creem.io/product/prod_61bQkq1fbbpbLGRSf4T95w
- Trader Pro ($49 / 2,000 scans): https://www.creem.io/product/prod_mv7rBlDyctTusY33A1OCM
- Active Desk ($79 / 5,000 scans): https://www.creem.io/product/prod_56H2ryWEQsaSoOWzh1DyTd
- Quant Desk ($149 / 10,000 scans): https://www.creem.io/product/prod_6ALZXF6EncayzYGqkVvkfK
