Prototype on the stream
Use server-side filters to sample high-premium or short-dated flow without drowning notebooks in every print.
Develop flow features on WebSocket trades and validate them on historical RAW trades. Map derived fields and aggregation modes explicitly before comparing results.
For quant researchers who need both a live options tape (~10M/day) and a SQL warehouse (rolling 15-day window, ~100M trades) with consistent Greeks/IV/premium semantics.
Keep one definition of premium, delta bands, and DTE filters across stream and SQL.
Use server-side filters to sample high-premium or short-dated flow without drowning notebooks in every print.
Persist minute bars or event features (premium, |delta|, IV) with the same formulas you will run live.
Replay multi-week windows via historical SQL with row/timeout guardrails appropriate to research jobs.
Promote filters to production WebSocket params and monitor drift against the SQL baseline.
SELECT
toStartOfMinute(time) AS minute,
sumIf(toFloat64(price) * size * 100, put_call = 'CALL') AS call_premium,
sumIf(toFloat64(price) * size * 100, put_call = 'PUT') AS put_premium,
avg(abs(delta)) AS avg_abs_delta
FROM RawOptionTrades
WHERE date = (
SELECT max(date) FROM RawOptionTrades
WHERE symbol = 'AAPL' AND date >= today() - 7
)
AND symbol = 'SPY'
AND toFloat64(price) * size * 100 >= 50000
GROUP BY minute
ORDER BY minute
LIMIT 1000See also the quant hub and UOA-for-quant pages.
Yes. Many studies start in SQL. Map derived fields and RAW versus AGGREGATED semantics before deploying those features on WebSocket.
Yes. AGGREGATED merges same-contract same-instant prints; RAW keeps every exchange print. Pick one mode and keep it consistent from backtest to prod.
Paid Historical SQL covers the past 15 days of option trades (a rolling 360-hour window, on the order of 100M rows), queryable via ClickHouse SQL over REST.
Greeks and IV are analytics estimates under model assumptions. Use them as features, not as guaranteed P&L.