Skip to content

fix(logs): avoid giant provider pills for failed auto family requests - #8867

Merged
diegosouzapw merged 3 commits into
cheaper-inference:release/v3.8.49from
rafaeldrincon:fix/auto-family-failure-provider-logging
Jul 28, 2026
Merged

diegosouzapw merged 3 commits into
cheaper-inference:release/v3.8.49from
rafaeldrincon:fix/auto-family-failure-provider-logging

Conversation

@rafaeldrincon

Copy link
Copy Markdown
Contributor

Problem

Failed auto/<family> requests currently write the attempted model list into call_logs.provider:

  • cerebras/gemma-4-31b, nvidia/google/gemma-4-31b-it, ...
  • lmarena/gemini-3.1-flash-lite, ...

The logs page uses provider to build quick-filter pills, so one failed auto/gemma or auto/gemini request creates a giant provider chip that floods the filter row.

Root Cause

src/sse/handlers/chat.ts calls recordRejectedRequestUsage() on combo failures and passes:

provider: summarizeComboAttemptedModels(combo?.models)

That helper joins every attempted model with , .

Fix

For rejected combo requests, keep provider short and categorical:

  • auto for auto/* failures
  • combo.name for other combo failures
  • fallback combo

This preserves the logs UI provider filter semantics and avoids giant pills. The detailed failure info is still carried by the error/combo fields.

Verified

Locally verified against failing auto/gemini requests: new call_logs rows now store provider = "auto" instead of the comma-joined candidate list.

diegosouzapw and others added 2 commits July 28, 2026 14:47
The provider label was decided inline in handleChat, which has no test harness —
the change shipped untested and pushed chat.ts over its frozen size (1848 > 1845).

Moved to rejectedRequestUsage.ts next to summarizeComboAttemptedModels, the helper
it replaces on this path. chat.ts shrinks back under its baseline (no rebaseline
needed) and the logic gets three cases in the suite that already covers its sibling:
auto/* collapses to "auto", a named combo keeps its name, and bare "auto" (no
slash) is NOT collapsed — that one is a combo request, not a family request.

Also rebased on the current release tip and added the changelog fragment.

Co-authored-by: diegosouzapw <8016841+diegosouzapw@users.noreply.github.com>
@diegosouzapw
diegosouzapw merged commit 66997a6 into cheaper-inference:release/v3.8.49 Jul 28, 2026
5 checks passed
diegosouzapw added a commit that referenced this pull request Jul 28, 2026
[3.8.49]: 1178 -> 1179 bullets. [3.8.47] untouched at 234. 42 i18n mirrors synced.
@diegosouzapw diegosouzapw mentioned this pull request Jul 28, 2026
muhamadgalihsaputra pushed a commit to niyatna/NiyatnaRoute that referenced this pull request Sep 27, 2026
…cheaper-inference#8867)

* fix(logs): avoid giant provider pills for failed auto family requests

* refactor(logs): extract resolveRejectedComboProvider + cover it

The provider label was decided inline in handleChat, which has no test harness —
the change shipped untested and pushed chat.ts over its frozen size (1848 > 1845).

Moved to rejectedRequestUsage.ts next to summarizeComboAttemptedModels, the helper
it replaces on this path. chat.ts shrinks back under its baseline (no rebaseline
needed) and the logic gets three cases in the suite that already covers its sibling:
auto/* collapses to "auto", a named combo keeps its name, and bare "auto" (no
slash) is NOT collapsed — that one is a combo request, not a family request.

Also rebased on the current release tip and added the changelog fragment.

Co-authored-by: diegosouzapw <8016841+diegosouzapw@users.noreply.github.com>

---------

Co-authored-by: diegosouzapw <diegosouzapw@users.noreply.github.com>
Co-authored-by: rafaeldrincon <rafaeldrincon@users.noreply.github.com>
Co-authored-by: diegosouzapw <8016841+diegosouzapw@users.noreply.github.com>
muhamadgalihsaputra pushed a commit to niyatna/NiyatnaRoute that referenced this pull request Sep 27, 2026
…drincon

[3.8.49]: 1178 -> 1179 bullets. [3.8.47] untouched at 234. 42 i18n mirrors synced.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants