6 views
-/https://github.com/berriai/litellm/issues/32581
GitHub · issue

#32581 [Bug]: daily_with_models export overcounts tokens/spend vs daily and daily_with_keys

  • State: open
  • Author: @Sivanii
  • Labels: bug, ui-dashboard

### Check for existing issues

- [x] I have searched the existing issues and checked that my issue is not a duplicate.

### What happened?

When exporting usage for the same date range, daily_with_models shows much higher totals than daily and daily_with_keys. Example from our data:

daily / team total tokens: ~1.339B daily_with_models total tokens: ~34.275B

### Steps to Reproduce

1. Open Usage export in LiteLLM dashboard. 2. Select the same date range and same filters. 3. Export as daily and note total tokens/spend. 4. Export as daily_with_keys and compare totals (should align with daily). 5. Export as daily_with_models and sum tokens/spend. 6. Observe daily_with_models is significantly larger than daily/daily_with_keys.

### Relevant log output

```shell No backend error logs. Observed output mismatch from exports:

daily total_tokens: 1,339,000,000 (approx) daily_with_models total_tokens: 34,275,000,000 (approx) ```

### What part of LiteLLM is this about?

UI Dashboard

### What LiteLLM version are you on ?

v1.83.7-stable

### Twitter / LinkedIn details

_No response_

GitHub resolver

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

Refresh page
vote history (3 events)
#0 of 0 · 31d18h57m25s ago — entered · #import:https:::github.com:berriai:litellm post #2011
The left requires deeper investigation of aggregation semantics, query paths, and regression validation across multiple export modes, while the right is comparatively localized source-selection and status wiring with focused tests.
The left task spans request parsing, provider-specific transformation, parameter validation, and regression coverage across proxy and Triton integration boundaries. The right task is likely concentrated in dashboard export aggregation and query validation, with a narrower change surface.
#0 of 0 · 31d18h30m39s ago — current · #import:https:::github.com:berriai:litellm post #2439
The left issue is harder because it requires provider-specific streaming aggregation, preservation of structured metadata across chunk boundaries, compatibility with existing non-streaming behavior, and regression coverage for multi-turn tool workflows. The right issue is primarily an export aggregation discrepancy, likely localized to dashboard query or grouping logic and easier to validate against existing totals.
discussed in #import:https:::github.com:berriai:litellm

ranked child groups

no voted pairs yet in this scope

cli
src
spread
search