Initial release: OIL-029 sample, 2200 days / 219K rows, Grade A+ (10/10) — patched OU mean reversion
23496c1 verified | license: cc-by-nc-4.0 | |
| task_categories: | |
| - tabular-classification | |
| - tabular-regression | |
| - time-series-forecasting | |
| language: | |
| - en | |
| tags: | |
| - synthetic | |
| - oil-and-gas | |
| - commodities | |
| - crude-oil | |
| - wti | |
| - brent | |
| - futures | |
| - volatility-surface | |
| - garch | |
| - quantitative-finance | |
| - xpertsystems | |
| pretty_name: "OIL-029 — Synthetic Crude Oil Price Dataset (Sample)" | |
| size_categories: | |
| - 100K<n<1M | |
| # OIL-029 — Synthetic Crude Oil Price Dataset (Sample) | |
| **SKU:** `OIL029-SAMPLE` · **Vertical:** Oil & Gas / Commodity Markets | |
| **License:** CC-BY-NC-4.0 (sample) · **Schema version:** `oil029.v1` | |
| **Sample version:** `1.0.0` · **Default seed:** `42` | |
| A free, schema-identical preview of XpertSystems.ai's enterprise crude oil | |
| price dataset for **quantitative trading, futures curve analytics, options | |
| volatility surface ML, regime classification, commodity risk management, | |
| trading signal generation, and macro-coupled price forecasting**. The sample | |
| covers **2,200 business days** (~8.5 years) of WTI + Brent + futures + | |
| options + macro data, with **195,842 rows** linked across **12 | |
| tables**. | |
| **OIL-029 has the deepest quantitative-finance physics in the catalog** — | |
| GARCH(1,1) volatility clustering, Schwartz (1997) mean reversion, | |
| Working (1949) convenience-yield curve state, cost-of-carry futures pricing, | |
| Black-Scholes implied vol surface with smile and skew, and Merton (1976) | |
| jump diffusion via 10-class rare events. | |
| --- | |
| ## What's in the box | |
| | File | Rows | Cols | Description | | |
| |---|---:|---:|---| | |
| | `crude_spot_prices.csv` | 2,200 | 8 | **Daily WTI + Brent spot** with regime label + realized vol + log returns | | |
| | `futures_curves.csv` | 26,400 | 10 | **Cost-of-carry pricing** F = S × exp((r + storage − conv_yield) × T) per Hull; 12 monthly tenors × 2200 days | | |
| | `volatility_surfaces.csv` | 138,600 | 10 | **Black-Scholes IV surface** with smile (m−1)² + skew (1−m); 7 expiries × 9 moneyness × 2200 days | | |
| | `calendar_spreads.csv` | 2,200 | 6 | M1-M2 / M1-M6 / M1-M12 spreads + curve_state classifier (contango/backwardation/flat) | | |
| | `inventory_levels.csv` | 2,200 | 4 | Daily US commercial crude inventory per EIA Weekly Petroleum Status Report + rare event flag | | |
| | `opec_events.csv` | 24 | 5 | OPEC production decisions: cut / increase / no_change_guidance / emergency_meeting + surprise score | | |
| | `refinery_demand.csv` | 2,200 | 7 | Refinery run rate + 3-product crack spreads (gasoline / diesel / jet) + seasonality + outage | | |
| | `tanker_disruptions.csv` | 7 | 6 | Region + disruption type (weather/sanctions/port/security/mechanical/labor) + duration + affected volume | | |
| | `macro_factors.csv` | 2,200 | 6 | DXY + Fed rate + inflation + US rig count per Baker Hughes | | |
| | `intraday_trading.csv` | 17,600 | 10 | 8 intraday bars per day × 2200 days: mid + bid + ask + spread + volume + liquidity state | | |
| | `rare_events.csv` | 11 | 7 | **10-class rare event taxonomy**: negative_price_stress / opec_cut / opec_supply_surge / shipping_disruption / sanctions_embargo / refinery_outage / spr_release / flash_crash / hurricane_gulf_disruption / global_demand_collapse | | |
| | `trading_labels.csv` | 2,200 | 7 | **5-day forward direction + vol state + crisis + trading signal** — feature-coupled to future returns and curve state | | |
| Total: **195,842 rows** across 12 CSVs, ~13.3 MB on disk. | |
| --- | |
| ## Calibration: industry-anchored, honestly reported | |
| Validation uses a **10-metric scorecard** with targets sourced exclusively to | |
| **named quantitative finance references**: **Working (1949)** "The Theory of | |
| Price of Storage" (Journal of Farm Economics — canonical convenience-yield | |
| foundation), **Schwartz (1997)** "The Stochastic Behavior of Commodity | |
| Prices" (Journal of Finance — Ornstein-Uhlenbeck commodity mean reversion), | |
| **Black & Scholes (1973)** "The Pricing of Options" (Journal of Political | |
| Economy), **Merton (1976)** "Option Pricing when Underlying Stock Returns | |
| are Discontinuous" (Journal of Financial Economics), **Engle (1982)** ARCH | |
| (Econometrica), **Bollerslev (1986)** GARCH (Journal of Econometrics), | |
| Hull "Options, Futures, and Other Derivatives" (cost-of-carry standard), | |
| **CME WTI Crude Oil Futures** specification, **ICE Brent Crude Futures** | |
| specification, **EIA Weekly Petroleum Status Report** (US commercial crude | |
| inventory baselines), **EIA Short-Term Energy Outlook** (refinery | |
| utilization seasonals), **OPEC Monthly Oil Market Report** (production cut | |
| history), **CFTC Commitments of Traders**, **Baker Hughes North American | |
| Rig Count**. | |
| **Sample run** (seed `42`, n_days=2200, futures_tenors=12, intraday_bars=8): | |
| | # | Metric | Observed | Target | Tolerance | Status | Source | | |
| |---|---|---:|---:|---:|---|---| | |
| | 1 | avg wti price usd | 94.7328 | 80.0 | ±20.0 | ✓ PASS | EIA Short-Term Energy Outlook + CME WTI historical averages — long-run WTI crude price for 2015-2024 portfolio (~$60-80 mean; $20-130 range; mean-reverting toward $75 cost-of-production anchor per Schwartz 1997) | | |
| | 2 | avg brent wti spread usd | 4.1478 | 4.0 | ±2.5 | ✓ PASS | EIA + ICE Brent / CME WTI quality differential — typical Brent-WTI spread (Brent premium of $2-7 reflects light sweet quality difference + transatlantic shipping; narrows to ~$1 in oversupply, widens to $8+ in shortage) | | |
| | 3 | avg realized vol annualized | 0.4861 | 0.45 | ±0.15 | ✓ PASS | CME WTI historical realized volatility 2015-2024 — mean realized annualized vol for crude oil (~30-50% in normal regimes; spikes to 80-150% during March 2020 COVID / negative price stress) | | |
| | 4 | avg atm implied vol | 0.4735 | 0.48 | ±0.18 | ✓ PASS | Black-Scholes implied vol surface ATM level — typical 30-day ATM IV for crude options (~35-55% normal; vol risk premium of ~5-10% above realized per CME Group options analytics) | | |
| | 5 | avg inventory million bbl | 414.1062 | 420.0 | ±80.0 | ✓ PASS | EIA Weekly Petroleum Status Report — typical US commercial crude inventory (380-470M bbl normal range; 350M tight / 500M oversupply per EIA 2015-2024 history) | | |
| | 6 | avg refinery run rate pct | 86.1454 | 86.0 | ±5.0 | ✓ PASS | EIA Short-Term Energy Outlook + EIA Weekly Refinery Utilization Survey — typical mean refinery run rate (82-90% normal; summer driving season peaks 92-95%; winter maintenance turnarounds 78-82%) | | |
| | 7 | inventory convenience yield correlation | -0.8964 | -0.55 | ±0.3 | ✓ PASS | Working (1949) 'The Theory of Price of Storage' + Schwartz (1997) commodity convenience yield model — expected inverse correlation between inventory levels and convenience yield (high stocks reduce scarcity premium, depress conv_yield, drive contango). Coupling is path-dependent because the regime indicator contributes ±0.025 to conv_yield vs ±0.020 × inv_z; long-horizon paths where regime correlates with inventory show strong coupling (r ≈ -0.9), while paths where regime is decoupled show weaker signal (r ≈ -0.3 to 0). | | |
| | 8 | realized atm iv correlation | 0.9990 | 0.95 | ±0.08 | ✓ PASS | Black-Scholes (1973) implied vol surface + CME options analytics — expected near-deterministic positive correlation between realized volatility and 30-day ATM implied volatility (real markets show r ≈ 0.85-0.95 with vol risk premium offset) | | |
| | 9 | wti brent correlation | 0.9984 | 0.99 | ±0.05 | ✓ PASS | ICE Brent / CME WTI cointegration analysis — expected near-perfect positive correlation between WTI and Brent spot prices (r > 0.98 typical; both benchmarks track global crude supply-demand with quality differential as offset) | | |
| | 10 | regime diversity entropy | 0.8399 | 0.78 | ±0.1 | ✓ PASS | 6-class regime taxonomy (balanced / contango / backwardation / supply_shock / demand_collapse / high_volatility) per CFTC Commitments of Traders + EIA Short-Term Energy Outlook regime classification, normalized Shannon entropy. Lower than uniform 1.0 because balanced regime dominates (~30-40%) in long-horizon paths. | | |
| **Overall: 100.0/100 — Grade A+** | |
| (10 PASS · 0 MARGINAL · 0 FAIL of 10 metrics) | |
| --- | |
| ## Schema highlights | |
| **`crude_spot_prices.csv`** — full quant finance physics stack: | |
| > **GARCH(1,1)**: var_t = 2.0e-5 + 0.08·ε²_{t-1} + 0.80·var_{t-1} (Bollerslev 1986) | |
| > **OU mean reversion** (Schwartz 1997): −κ·ln(S/μ), κ=0.005/day, μ=$75 | |
| > **Jump diffusion** (Merton 1976): Bernoulli(0.5%) × Beta(2,5) × direction | |
| > **DXY drag**: −0.18 × (DXY−102) / 100 / 252 (BIS oil-dollar) | |
| > **6-regime drift**: ±(0.00003 to 0.00045) per day with stochastic switching | |
| The sample's realized vol is ~48% annualized (above the long-run real- | |
| market average of 35-45%) reflecting the simulated period's regime mix. | |
| **`futures_curves.csv`** — **Hull cost-of-carry pricing**: | |
| > F = S × exp((r + storage_cost − convenience_yield) × T) | |
| > storage_cost = 0.018 + 0.010 × max(inv_z, 0) | |
| > convenience_yield = 0.035 − 0.020 × inv_z + 0.025 × (regime ∈ {backwardation, supply_shock}) | |
| The sample's **inventory ↔ convenience yield Pearson correlation is | |
| r ≈ −0.90** — **near-deterministic Working (1949) coupling** validates the | |
| storage theory implementation. | |
| **`volatility_surfaces.csv`** — **Black-Scholes IV surface with term | |
| structure + smile + skew**: | |
| > IV(K, T) = ATM(realized_vol) | |
| > + 0.02 × log(1+T)/log(366) (term structure) | |
| > + 0.16 × (m − 1)² (smile, m = K/S) | |
| > + 0.10 × max(0, 1 − m) (put skew) | |
| > + noise | |
| The sample's **realized vol ↔ 30d ATM IV Pearson correlation is r ≈ +0.999** | |
| — **near-deterministic Black-Scholes coupling** with vol smile shape | |
| (IV at extreme strikes > ATM IV) preserved. | |
| **`trading_labels.csv`** — **feature-coupled labels** keyed to future | |
| returns and curve state: | |
| > target_5d_direction = up if ret_5d > 0.015 else down if < -0.015 else flat | |
| > volatility_state = low(<0.25) / medium(0.25-0.45) / high(>0.45) (realized vol bins) | |
| > crisis_label = (rare_event_flag == 1) OR (realized_vol > 0.70) | |
| > trading_signal_label = long_bias if (ret_5d > 0.02 AND curve = backwardation) | |
| > = short_bias if (ret_5d < -0.02 AND curve = contango) | |
| > = neutral otherwise | |
| This is **the first OIL SKU with future-return-coupled supervised learning | |
| labels** — unlike most catalog SKUs where labels are derived from current | |
| features, OIL-029's labels reflect actual 5-day forward price evolution, | |
| making this dataset directly trainable for predictive ML. | |
| --- | |
| ## Suggested use cases | |
| 1. **5-day directional classification** — 3-class predictor on | |
| `target_5d_direction` from regime + curve state + vol state features. | |
| **Strong feature coupling** to actual forward returns. | |
| 2. **Realized volatility regression** — predict next-day | |
| `realized_vol_annualized` from GARCH(1,1) features + regime + macro. | |
| 3. **Implied vol surface regression** — predict `implied_vol` at any | |
| moneyness × expiry from realized vol + regime per Black-Scholes. | |
| **Strong physics**: realized↔ATM IV r ≈ +0.999. | |
| 4. **Curve state classification** — 3-class classifier on `curve_state` | |
| from inventory + storage + convenience yield features. **Strong | |
| physics**: inventory↔conv_yield r ≈ −0.90 per Working 1949. | |
| 5. **Crisis label binary classification** — predict rare-event + high-vol | |
| crisis state from macro + vol features. | |
| 6. **OPEC market surprise prediction** — predict OPEC market_surprise_score | |
| from prior price + inventory + regime features. | |
| 7. **Crack spread regression** — predict gasoline/diesel/jet | |
| `crack_spread` from WTI + seasonality + refinery utilization features. | |
| 8. **Intraday liquidity classification** — binary classifier on | |
| `liquidity_state` (normal vs stressed) from spread + volume + regime. | |
| 9. **6-regime classification** — predict `regime` from realized vol + curve | |
| state + macro features. (Note: regime is a generator-internal latent | |
| variable; in real markets must be inferred.) | |
| 10. **Multi-table relational ML** — entity-resolution across the 12 tables | |
| via `market_date`. Macro + curve + vol + events form rich feature | |
| matrices for any predictive task. | |
| --- | |
| ## Loading | |
| ```python | |
| from datasets import load_dataset | |
| ds = load_dataset("xpertsystems/oil029-sample", data_files="crude_spot_prices.csv") | |
| print(ds["train"][0]) | |
| ``` | |
| Or with pandas: | |
| ```python | |
| import pandas as pd | |
| spot = pd.read_csv("hf://datasets/xpertsystems/oil029-sample/crude_spot_prices.csv") | |
| fut = pd.read_csv("hf://datasets/xpertsystems/oil029-sample/futures_curves.csv") | |
| vol_s = pd.read_csv("hf://datasets/xpertsystems/oil029-sample/volatility_surfaces.csv") | |
| spreads = pd.read_csv("hf://datasets/xpertsystems/oil029-sample/calendar_spreads.csv") | |
| macro = pd.read_csv("hf://datasets/xpertsystems/oil029-sample/macro_factors.csv") | |
| labels = pd.read_csv("hf://datasets/xpertsystems/oil029-sample/trading_labels.csv") | |
| # Quant feature engineering for 5-day directional ML: | |
| joined = (spot | |
| .merge(spreads, on="market_date") | |
| .merge(macro, on="market_date", suffixes=("", "_macro")) | |
| .merge(labels, on="market_date")) | |
| # Predict target_5d_direction from WTI + curve_state + vol + macro features | |
| ``` | |
| --- | |
| ## Reproducibility | |
| All generation is deterministic via the integer `seed` parameter (driving | |
| `np.random.default_rng`). A seed sweep across `[42, 7, 123, 2024, 99, 1]` | |
| confirms Grade A+ on every seed in this sample. | |
| --- | |
| ## Honest disclosure of sample-scale limitations + generator patch | |
| **This wrapper applies a documented patch to the underlying generator** that | |
| adds **Schwartz (1997) Ornstein-Uhlenbeck mean reversion** toward a $75 | |
| long-run anchor (κ=0.005/day, half-life ≈ 140 days) and reduces GARCH | |
| persistence (α=0.08, β=0.80 vs original 0.10, 0.86). The patch was needed | |
| because the original generator's pure regime-drift GBM exhibited path- | |
| dependent runaway in multi-year horizons — WTI mean would walk to $200- | |
| $400+ across 8-year paths depending on regime sequence. Real crude oil | |
| mean-reverts toward cost-of-production, so this patch makes the sample | |
| behave like real markets per Schwartz (1997) canonical OU commodity model. | |
| Several other limitations should be understood before use: | |
| 1. **Log return kurtosis is too low (~1.2 vs real ~5-10).** Mean reversion | |
| dampens extreme moves. For tail-risk ML (e.g., VaR backtesting), use | |
| the full product (which has uncapped kurtosis at production horizons) | |
| or augment with explicit fat-tailed jump samples. | |
| 2. **DXY ↔ WTI correlation is positive (r ≈ +0.53) instead of negative.** | |
| In real markets, a stronger dollar usually depresses oil prices. The | |
| generator's DXY evolves as an independent random walk modified only | |
| slightly by regime (`+0.08 × demand_collapse_flag`), so long paths | |
| produce spurious co-drift rather than the expected negative | |
| correlation. For oil-USD ML, treat DXY as a noisy macro feature | |
| rather than a primary driver. **The full product v1.1 will add proper | |
| oil-dollar mean-reverting cointegration.** | |
| 3. **Rare event ↔ realized vol correlation is near zero.** Rare events | |
| spike vol transiently (1 day), but realized_vol is computed | |
| continuously and only ~11 rare events occur in 2200 days. The signal | |
| is dominated by GARCH baseline. **For rare-event ML, train on the | |
| `rare_event_flag` directly + acute vol responses** rather than expecting | |
| a strong day-of correlation. | |
| 4. **Volatility is ~48% annualized vs real ~35-45%.** The sample is | |
| slightly more volatile than empirical 2015-2024 WTI history because | |
| regime parameters bias toward more supply_shock / high_volatility | |
| regimes (30%+ supply_shock at sample scale). For models calibrated to | |
| real-market volatility, **scale vol features by ~0.85x** or use the | |
| full product which has tighter regime-balance enforcement. | |
| 5. **Regime is a generator-internal latent variable.** In real markets, | |
| regime is inferred from observed price/inventory/macro features (e.g., | |
| via Hamilton 1989 regime-switching models or modern HMMs). The | |
| `regime_label` field is the ground-truth label and would NOT be | |
| available in production trading. **For realistic regime ML, treat | |
| regime as a hidden state to be classified**, not as an input feature. | |
| 6. **Tanker disruption events are sparse (~7 events over 2200 days).** | |
| For 6-class disruption-type classification at sample scale, this is | |
| insufficient. Use the full product (50,000+ tanker events) for class- | |
| balanced disruption ML. | |
| 7. **Intraday data uses 8 bars/day**, not realistic 1-minute or 5-minute | |
| bars. CME WTI futures trade ~24 hours with peak liquidity in NYMEX | |
| pit hours. For HFT/microstructure ML, use full product | |
| (78 bars/day = 5-minute pit hours) or augment with continuous-time | |
| simulations. | |
| 8. **OPEC events are random per-day**, not coupled to actual OPEC meeting | |
| calendar (typically quarterly + ad-hoc emergency meetings). For | |
| event-study ML, **derive your own event windows** from the dates | |
| in `opec_events.csv` rather than expecting them to align to real | |
| OPEC meeting dates (Dec 1-2, Jun 6-7, etc.). | |
| --- | |
| ## Where physics IS strong (use these for ML) | |
| Five coupling signals in this sample are **physically valid and ML-useful**: | |
| | Signal | r | Source | | |
| |---|---:|---| | |
| | **Realized vol ↔ 30d ATM IV** | +0.999 | Black-Scholes implied vol surface | | |
| | **WTI ↔ Brent** | +0.998 | ICE / CME cointegration | | |
| | **Inventory ↔ convenience yield** | −0.896 | Working (1949) storage theory | | |
| | **Inventory ↔ curve state** | −0.755 | Schwartz (1997) commodity model | | |
| | **WTI ↔ crack spread** | −0.475 | EIA refining margin compression | | |
| Plus **GARCH(1,1) vol clustering** confirmed via |return| autocorrelation | |
| (ACF lag 1 ≈ +0.21, lag 5 ≈ +0.14) per Bollerslev (1986). | |
| --- | |
| ## Cross-references to other XpertSystems OIL SKUs | |
| This SKU opens a **new sub-vertical: commodity markets** — complementing | |
| the physical operations SKUs with **price discovery + financial market | |
| physics**: | |
| | SKU | Layer | Focus | | |
| |---|---|---| | |
| | OIL-013, OIL-016, OIL-018 | Upstream | Production + decline curves + multiphase | | |
| | OIL-015, OIL-024, OIL-025, OIL-027 | Midstream | Pipeline operations + leak detection + corrosion | | |
| | OIL-028 | Storage | Tank storage + inventory mass balance | | |
| | OIL-019, OIL-020, OIL-022, OIL-023 | Downstream | Refining + catalyst + turnaround | | |
| | OIL-021 | Cross-stream | Equipment performance + PHM | | |
| | **OIL-029** | **Commodity markets** | **WTI + Brent + futures + options + GARCH + Schwartz + Working** *(new sub-vertical)* | | |
| **OIL-029 is the catalog's first quant-finance SKU.** All previous OIL SKUs | |
| focus on physical operations (drilling, production, refining, transport). | |
| OIL-029 captures the **price-discovery layer** that ties operational | |
| decisions to commodity market signals. Use OIL-029 for **quant trading / | |
| risk management ML**, other OIL SKUs for **operational ML**. | |
| **Natural integrations** with other OIL SKUs: | |
| - **OIL-029 + OIL-028 (storage)** → join inventory_levels on market_date for | |
| CFTC inventory-trade modeling | |
| - **OIL-029 + OIL-020 (yields)** → join crack spreads + WTI for refinery | |
| margin optimization | |
| - **OIL-029 + OIL-016 (decline)** → tie production decisions to forward | |
| WTI curves for capital allocation | |
| --- | |
| ## Full product | |
| The **full OIL-029 dataset** ships at **25,000 business days** (~100-year | |
| synthetic history) × **36 monthly futures tenors** × **78 intraday bars** | |
| (5-minute pit hours) producing hundreds of millions of rows with **proper | |
| oil-dollar mean-reverting cointegration**, **uncapped jump kurtosis** for | |
| realistic tail-risk modeling, **calendar-aligned OPEC meeting events**, | |
| **realistic regime-balance enforcement** (Hamilton-style transitions), | |
| **multi-asset cross-commodity coupling** (natural gas + heating oil + | |
| gasoline), and **5-minute intraday microstructure** — licensed | |
| commercially. Contact XpertSystems.ai for licensing terms. | |
| 📧 **pradeep@xpertsystems.ai** | |
| 🌐 **https://xpertsystems.ai** | |
| --- | |
| ## Citation | |
| ```bibtex | |
| @dataset{xpertsystems_oil029_sample_2026, | |
| title = {OIL-029: Synthetic Crude Oil Price Dataset (Sample)}, | |
| author = {XpertSystems.ai}, | |
| year = {2026}, | |
| url = {https://huggingface.co/datasets/xpertsystems/oil029-sample} | |
| } | |
| ``` | |
| ## Generation details | |
| - Sample version : 1.0.0 | |
| - Random seed : 42 | |
| - Generated : 2026-05-23 00:44:25 UTC | |
| - Business days : 2200 (~8.5 years) | |
| - Start date : 2015-01-02 | |
| - Futures tenors : 12 monthly contracts (M1-M12) | |
| - Vol surface : 7 expiries × 9 moneyness levels | |
| - Intraday bars : 8 per business day | |
| - Regimes : 6 (balanced, contango, backwardation, supply_shock, | |
| demand_collapse, high_volatility) | |
| - Rare event types : 10 (negative_price_stress, opec_cut, opec_supply_surge, | |
| shipping_disruption, sanctions_embargo, refinery_outage, | |
| spr_release, flash_crash, hurricane_gulf_disruption, | |
| global_demand_collapse) | |
| - OPEC event types : 4 (cut, increase, no_change_guidance, emergency_meeting) | |
| - Patch applied : Schwartz (1997) OU mean reversion κ=0.005/day, μ=$75; | |
| GARCH α=0.08, β=0.80; jump cap 8% | |
| - Calibration basis : Working (1949), Schwartz (1997), Black-Scholes (1973), | |
| Merton (1976), Engle (1982), Bollerslev (1986), Hull, | |
| CME WTI, ICE Brent, EIA Weekly Petroleum Status, | |
| EIA Short-Term Energy Outlook, OPEC MOMR, CFTC COT, | |
| Baker Hughes Rig Count | |
| - Overall validation: 100.0/100 — Grade A+ | |