Recipes
Trading questions, answered in code
Each recipe is a complete Python script that answers a real trading question. Copy it, run it with your API key, get the answer. No setup, no dependencies beyond requests and pandas.
Positioning & Structure
4 recipes“Which BTC strikes have the most open interest within 7 days of expiry?”
Ranks strikes by total OI in USD for near-expiry BTC options. Shows where the market has the heaviest positioning and where gamma pinning pressure is strongest.
“How is open interest distributed across expiries for BTC right now?”
Stacks total OI by expiration date, showing where the weight of the market sits. Reveals which expiries will generate the most rebalancing pressure as they approach.
“Which call and put are closest to spot for each active expiry?”
Finds the ATM pair for every live expiration. ATM options carry the highest gamma and vega, making them the fulcrum of the options surface.
“Which instruments were listed in the last 24 hours on any coin?”
Scans for freshly created options across all coins. New listings often precede new expiry cycles and can signal exchange expectations about upcoming volatility.
Volatility Surface
3 recipes“Is BTC vol in contango or backwardation right now?”
Plots the ATM IV term structure from 7-day to long-dated expiries. Contango (upward slope) is normal. Backwardation (inverted) signals fear or an imminent vol event.
“How steep is the BTC put skew and is it steepening?”
Measures the premium investors pay for downside protection vs upside exposure. Rising put skew = growing fear. Collapsing skew = complacency or bullish repositioning.
“Is implied vol cheap or expensive relative to what actually happened?”
Compares current ATM implied volatility against 7d, 30d, and 90d realized volatility. Positive VRP = options are "expensive." Negative = the market is underpricing risk.
GEX & Pinning
3 recipes“Where are the magnetic strikes pulling BTC price toward?”
Shows the top 3 GEX magnetic strikes for near-expiry options, the pinning zone boundaries, and whether price is currently inside the zone. When spot is in the pinning zone, expect mean reversion.
“Where does gamma flip from stabilizing to amplifying?”
Finds the interpolated price level where cumulative GEX crosses zero. Above the flip, dealers stabilize price (positive gamma). Below, they amplify moves (negative gamma).
“Is the market pricing flash crash risk in the deep tails?”
Shows the Tail Strike score: the divergence between deep OTM (10-delta) and moderate OTM (25-delta) vol, normalized by ATM. When deep tails get bid independently of moderate OTM, someone is buying crash protection.
Flow & Signals
2 recipes“Are whales sweeping BTC options right now?”
Checks ORIA activity signals for whale involvement (HIGH), sweep patterns (WHALE_CALL_SWEEP, WHALE_PUT_SWEEP), and smart money flows. When quality score is above 70 with whale involvement, the signal is institutional-grade.
“How much premium is bleeding across BTC expiries today?”
Shows total theta exposure per expiry with acceleration metrics. When theta acceleration turns sharply negative in the last 48 hours before expiry, gamma effects dominate and the theoretical "time decay" becomes unreliable.