Skip to main content

Module pricing_catalog

Module pricing_catalog 

Expand description

Global pricing catalog: a last-resort fallback consulted by the cost engine when a model has no per-provider pricing entry in config.

Structs§

CatalogModelPrice
One model’s chargeback rates, mirroring the on-disk pricing.json shape written by the pricing feed.
GlobalPricingCatalog
The full catalog as loaded from pricing.json, plus a precomputed lowercase index for O(1) exact lookups on the hot path.

Functions§

global_pricing_catalog
Current process-global catalog snapshot.
global_pricing_rates
Exact per-1M-token rates for model from the global catalog, or None.
load_global_pricing_catalog
set_global_pricing_catalog
Replace the process-global catalog (used by startup load and config reload to hot-swap rates without a restart). The catalog file itself is refreshed out-of-band by the CLI + launchd, not by this daemon.