Skip to content

KB / operations

Data Sources

Last verified

Seventeen external feeds drive the platform. Each is registered as a DataSource subclass in app/sources/ and pulled by engine.py:fetch_all_sources() on the cadence dictated by the active collection profile.

The full inventory

SourceWhat it providesCadenceRequired
market (yfinance + Schwab)SPY/QQQ/IWM/DIA closes, VIX, MOVE, GEX/ZGL/PCR, BTC, RSI, IVRPer profileYes (core)
fredFed liquidity, HY OAS, 2s10s, breakevens, yields, real yieldPer profileYes
creditHigh-yield credit spread series, NFCIPer profileYes
liquidityNet Fed liquidity (WALCL − TGA − RRP)Per profileYes
darkpoolSqueezMetrics DIX + GEX daily CSVDaily post-closeYes
newsFXStreet RSS + Iran International liveblog + Hormuz tanker monitorPer profileYes
sentimentAlpha Vantage news sentimentPer profileOptional (25 req/day budget)
seasonalityHistorical SPY seasonality lookupPer profileOptional
vol_structureVIX term structure (VIX9D/VIX/VIX3M/VIX6M ratios)Per profileYes
epsForward EPS revision deltasPer profileOptional
breadthS&P 500 % above 50/200 SMA, sector breadthPer profileYes
energyWTI, Brent, USO, XLE, crack spreadPer profileYes
inflationBreakeven inflation series (5Y, 10Y, 5Y5Y)Per profileYes
macro_indicatorsComposite macro health proxiesPer profileOptional
cotCFTC Commitments of Traders speculator net positioningWeekly (Fri ~15:30 ET)Optional
aaiiAAII bull-bear sentiment spreadWeekly (Thu)Optional
ebpFed Excess Bond Premium + GZ credit spread + model recession probabilityMonthly (FEDS Notes CSV)Optional

Three auxiliary fetches run alongside the registered sources and stash results under underscore-prefixed keys (_gamma_levels, _fed_watch, _correlations) so format_report can find them without colliding with per-source dicts:

Provider mix and fallback posture

Execution order

Fast HTTP sources run first (FRED, liquidity, darkpool, news, sentiment) so the heavy yfinance sources (market, eps, breadth) don’t gate the report on slow network paths. Breadth specifically downloads in batches of 50 tickers with 2-second delays to stay under yfinance’s rate limits.

Every fetch routes through DataSource.safe_fetch() in app/sources/base.py — uniform retry with exponential backoff, WARNING on transient failure, logger.exception() on fatal, returns a default on terminal failure. New sources must use it.

See also