Issue evidence · AI API · BerriAI/litellm
GitHub issue: https://github.com/BerriAI/litellm/issues/46403
Reproduced
LiteLLM keys spend-log rows on the provider's response id, so a provider that reuses ids silently loses the colliding rows.
Ran LiteLLM 1.104.2 with Postgres and two local mock OpenAI-style upstreams, one returning ids chatcmpl-<0..999> at random and one returning uuid ids, sending 300 requests to each, then counted LiteLLM_SpendLogs rows.
The mock reproduces Ollama's id behavior; a real Ollama was not routed through the proxy in this run. A unique id from the provider is the mitigation that held here; the fix in LiteLLM would be to key rows on litellm_call_id.
Checked 2026-10-14 in Badgr’s local development environment.
← All issue evidence