mostlyright.markets
mostlyright.markets — prediction-market data (Kalshi, Polymarket).
The venue submodules own all venue knowledge and speak the domain grammar a quant
can guess from weather / economy.
Two tools, used in that order. Find fuzzily with
mostlyright.discover(query, live=True), a cross-venue market search; then fetch
precisely with the venue verbs below, using the identifier it returned or a link
pasted from the venue. mostlyright.discover() without live=True is
network-free and searches only the catalog vendored in this build.
mostlyright.markets.kalshi— the market-data grammar (kalshi.series/kalshi.events/kalshi.markets/kalshi.market/kalshi.candles/kalshi.trades/kalshi.orderbook), plus the settlement verbs:kalshi.training_table(the leakage-free supervised table over the Kalshi NHIGH/NLOW settlement target),kalshi.label(the.label.settlementregistration),kalshi.settlement_days(the who/when day grid, per-row originatingtickerretained),kalshi.parse_ticker.mostlyright.markets.polymarket— the same market-data grammar (polymarket.events/polymarket.markets/polymarket.market/polymarket.candles/polymarket.trades/polymarket.orderbook), wherepolymarket.seriesexists only to raiseVenueCapabilityError: this venue’s hierarchy is Event to Market and has no series tier. Plus the settlement verbs:polymarket.training_table(thedaily_extremestarget),polymarket.label,polymarket.settlement_days(per-row originatingentityretained),polymarket.discover/polymarket.settle.mostlyright.markets.economy_trades— Kalshi venue price-history (OHLC candlesticks) for settled economy markets.
markets.polymarket.discover() and mostlyright.discover() are different
verbs. The former scans Polymarket weather events for the settlement pipeline; the
latter is the cross-domain catalog search named above.
The venue catalog (settlement whitelists, city→station maps) lives under
mostlyright.markets.catalog. _kalshi_trades and _polymarket_trades
are private, superseded by the public venue verbs and kept only because two of
their frame contracts are pinned; new code uses the public verbs.
Further reading: docs/market-data.md is the user-facing guide to the verbs,
the venue asymmetries, and the unit rules; docs/market-data-browser-support.md
carries the per-verb browser verdict (Polymarket is browser-direct, Kalshi is Node
or server only).
Signature note: the venue-level training_table verbs take more named
parameters than the top-level domain verbs (weather.training_table /
economy.training_table, which stay at five or fewer).
markets.kalshi.training_table takes 6 and markets.polymarket.training_table
8; both are thin delegators to core research.dataset.
Modules
Section titled “Modules”| Module | Description |
|---|---|
catalog | mostlyright.markets.catalog — prediction market contract specs. |
economy_trades | Kalshi venue price-history for SETTLED economy markets. |
kalshi | Kalshi venue wrapper over the venue-free core composition body. |
polymarket | Polymarket discovery + settlement (US + international). |