> ## Documentation Index
> Fetch the complete documentation index at: https://docs.getelyra.xyz/llms.txt
> Use this file to discover all available pages before exploring further.

# ODDS

> Scan decentralized prediction markets for mispriced events, cross-book arbitrage, and structural edge — across Polymarket and DFlow in real time.

ODDS connects Elyra to decentralized prediction markets, scanning for mispriced events and structural arbitrage opportunities that manual browsing cannot surface at scale. Rather than scrolling through hundreds of open markets looking for edges, you query Elyra and receive a ranked list of opportunities ordered by edge size, with the reasoning behind each one.

## Supported platforms

<CardGroup cols={2}>
  <Card title="Polymarket" icon="target">
    The largest decentralized prediction market by volume. ODDS scans event lines, computes implied probabilities, and applies semantic clustering to identify related markets with divergent pricing.
  </Card>

  <Card title="DFlow" icon="zap">
    Solana-native prediction market with on-chain orderbooks. ODDS analyzes taker flow and available liquidity to surface opportunities where order flow and quoted odds are misaligned.
  </Card>
</CardGroup>

## What ODDS detects

<Steps>
  <Step title="Cross-book line shopping">
    ODDS queries both venues simultaneously and identifies where the best available odds on the same event differ between books. You get the optimal entry point without comparing venues manually.
  </Step>

  <Step title="Semantic clustering and mispricing">
    On Polymarket, ODDS groups semantically related markets (events that are logically correlated) and flags cases where the implied probabilities are inconsistent across the cluster. A cluster where the sum of implied probabilities deviates materially from 100% is a structural signal.
  </Step>

  <Step title="Structural arbitrage identification">
    When correlated markets are priced divergently — for example, two markets on the same underlying outcome trading at odds that imply a riskless spread — ODDS surfaces that pair ranked by profit potential percentage.
  </Step>

  <Step title="Ranked opportunity output">
    All identified opportunities are ranked by edge size. You control how many results to surface and how many markets to scan using natural language or explicit flags.
  </Step>
</Steps>

## Natural language examples

```text theme={null}
"Find the best Polymarket opportunities"
→ Scanning 600 markets...

   #1 — "Will BTC close above $100k in May?" · YES 0.38 / NO 0.64
        Implied total: 1.02 · Edge: 2% overround detected
        Liquidity: $84,000 · Volume: $210,000

   #2 — "Fed rate cut before July?" · YES 0.61 / NO 0.41
        Implied total: 1.02 · Related market divergence flagged
        Liquidity: $122,000 · Volume: $380,000
```

```text theme={null}
"Show me arbitrage on DFlow"
→ 2 structural pairs detected:

   [CORR-ARB] "SOL above $90 by June" cluster
   Total implied prob: 0.97 · Profit potential: 3.1%
   Action: YES on Market A, NO on Market B

"What's the implied probability on [event]?"
→ Current YES price: 0.54 → Implied probability: 54%
   NO price: 0.48 → Market overround: 2%
```

## Scanning parameters

You can control the scope of an ODDS scan through natural language or direct flags when running the trade research pipeline.

| Parameter       | Default | Description                                        |
| --------------- | ------- | -------------------------------------------------- |
| `--max-markets` | 600     | Maximum number of markets to fetch and analyze     |
| `--top`         | 5       | Number of top opportunities to surface per table   |
| `--json`        | off     | Return raw JSON output instead of formatted tables |

```text theme={null}
"Top 10 Polymarket opportunities, scan 800 markets"
→ [Runs scan with --top 10 --max-markets 800]
```

<Note>
  Polymarket semantic clustering uses sentence-transformers for embedding-based grouping. On first run, a Hugging Face model is downloaded to `.cache/huggingface/`. If the library is unavailable, ODDS falls back to TF-IDF clustering automatically — no configuration required.
</Note>

<Warning>
  Implied probability calculations reflect current market prices only. Liquidity depth varies significantly between markets. An apparent edge in a low-liquidity market may not be executable at the quoted size.
</Warning>

<Tip>
  Use the arbitrage table alongside the opportunities table. The arbitrage output surfaces correlated market pairs, while the opportunities table surfaces single-market mispricings. Both are generated in the same scan.
</Tip>
