Major economic events (FOMC decisions, CPI releases) cause sharp moves in prediction markets. Horizon’s calendar module provides a live event feed, bundled FOMC/CPI dates through 2026, and pipeline functions for time-decay sizing and pre-event risk reduction. The feed maps event data to standard FeedSnapshot fields for seamless pipeline integration.
Parses bundled or custom event data and tracks the nearest future event.
import horizon as hz# Uses bundled FOMC + CPI dates automaticallyfeed = hz.CalendarFeed()# Or with a custom APIfeed = hz.CalendarFeed(api_url="https://api.example.com/events")
Parameter
Type
Default
Description
events_json
str
bundled dates
JSON array of event objects
api_url
str
""
Optional REST API for event data
interval
float
300.0
Poll interval in seconds
Bundled events include FOMC meeting dates and CPI release dates from 2024 through 2026.FeedSnapshot mapping:
price = urgency score (0.0 to 1.0, higher as event approaches)
bid = seconds to next event
ask = event type code (FOMC=1.0, CPI=2.0, NFP=3.0, GDP=4.0, EARNINGS=5.0)