8 views
-/https://github.com/berriai/litellm/issues/27124
GitHub · issue

#27124 chore: backup model_cost JSON drift vs root model_prices_and_context_window.json

  • State: open
  • Author: @mateo-berri

## Background

litellm ships two model-pricing JSONs: - Root `model_prices_and_context_window.json` (39k+ lines, source of truth maintained by reviewers + automated bumps) - `litellm/model_prices_and_context_window_backup.json` (mirror used when no remote map is available — i.e. CI default and when `LITELLM_LOCAL_MODEL_COST_MAP=True`)

The backup is supposed to be a periodic snapshot of the root. In practice it drifts: features get merged into the root file (e.g. `supports_prompt_caching: true` on the entire xAI grok-3 family) without the backup being resynced. CI tests that read via `litellm.get_model_cost_map(url=\"\")` see the stale backup; locally, contributors with `LITELLM_LOCAL_MODEL_COST_MAP=True` see the same; production deployments pull the root from main and don't notice.

## Concrete recent example (PR #27074)

`xai/grok-3-mini-beta` had `supports_prompt_caching: true` in the root JSON but **not** in the backup. Effects: 1. `test_xai.TestXAIChat::test_prompt_caching` skipped on `main` for months (`supports_prompt_caching(\"xai/grok-3-mini-beta\", None)` returned `False` from the stale backup). 2. PR #27074's commit [`108b87fb24`](https://github.com/BerriAI/litellm/commi…

GitHub resolver

Import GitHub neighbors on demand. Results are saved as system ingests.

Refresh page
vote history (1 events)
#0 of 0 · 31d18h22m40s ago — entered · #import:https:::github.com:berriai:litellm post #2467
The right-hand issue requires modifying asynchronous error-propagation and circuit-breaker behavior, with concurrency-sensitive regression tests and compatibility risk. The left-hand issue is primarily data synchronization plus validation or automation, making its implementation substantially smaller and safer.
discussed in #import:https:::github.com:berriai:litellm

ranked child groups

no voted pairs yet in this scope

cli
src
spread
search