mostlyright.stations
mostlyright.stations
Section titled “mostlyright.stations”Venue-agnostic station catalog (Phase 22).
A station is a physical fact; the prediction-market venue that settles on it
is metadata. Before Phase 22 the US-city universe lived in
mostlyright.markets.catalog.kalshi_stations — coupling general-purpose
weather stations to a single venue even though the same cities trade on
Polymarket and are valid query targets with no market at all.
This module exposes the canonical registry (mostlyright._internal._stations)
as a venue-agnostic StationCatalog. Markets derives its settlement
universe by filtering on venue tags; bare-data users ignore venues entirely.
Station is an alias for the registry’s StationInfo record — there is
one source of station truth, not two.
Module Attributes
Section titled “Module Attributes”Station | Public name for the station record. |
|---|---|
CATALOG | Process-wide default catalog over the canonical registry. |
Classes
Section titled “Classes”StationCatalog([stations]) | Read-only view over the station registry with venue/country filters. |
|---|
mostlyright.stations.CATALOG = <mostlyright.stations.StationCatalog object>
Section titled “mostlyright.stations.CATALOG = <mostlyright.stations.StationCatalog object>”Process-wide default catalog over the canonical registry.
mostlyright.stations.Station
Section titled “mostlyright.stations.Station”Public name for the station record. The registry dataclass IS the public shape — re-exported (not duplicated) so there is a single source of truth.
class mostlyright.stations.StationCatalog(stations=None)
Section titled “class mostlyright.stations.StationCatalog(stations=None)”Bases: object
Read-only view over the station registry with venue/country filters.
Lookups accept either the registry key (3-letter NWS code for US
stations, ICAO for international) or the 4-letter ICAO directly, so
get("NYC"), get("KNYC"), and get("EGLL") all resolve.
filter_by_country(country)
Section titled “filter_by_country(country)”Return stations whose ISO 3166-1 alpha-2 country matches, sorted by ICAO.
filter_by_venue(venue)
Section titled “filter_by_venue(venue)”Return stations tagged with venue (e.g. "kalshi"), sorted by ICAO.
get(code)
Section titled “get(code)”Return the station for code (registry key or ICAO).
venues()
Section titled “venues()”Return the union of all venue tags present in the catalog.