mirror of
https://github.com/AgentSeal/codeburn.git
synced 2026-08-21 22:44:31 +00:00
models: distinguish grok-4.5-build from grok-4.5 in reports
Reports bucket rows by model id and label them afterwards, so the two ids collapsing onto one display name printed what looked like the same row twice with different numbers. Give the variant its own SHORT_NAMES entry, which the longest-first match picks over the grok-4.5 prefix. Display only: ids are untouched, so nothing re-parses and no cost moves. Fixed in the shared table rather than the grok provider so the menubar and model-breakdown, which call getShortModelName directly, get it too. Fixes #1029.
This commit is contained in:
parent
39075edd50
commit
37796a568e
3 changed files with 12 additions and 0 deletions
|
|
@ -33,6 +33,7 @@
|
|||
- **The resident `codeburn serve` child.** The first real panel request is also the cache warm-up, so startup never runs an artificial warm-up query beside a duplicate one-shot child; each served command carries its own read-only option allowlist, and anything outside it falls back to a normal spawn; the child exits when its stdin closes, so it can never outlive the app. Requests whose response exceeds the 16 MiB frame limit still replace the child, but that deliberate kill no longer spends the resident's unexpected-death budget. (#972)
|
||||
|
||||
### Fixed
|
||||
- **`models` and `audit` no longer show two identical `Grok 4.5` rows.** `grok-4.5-build` — the Grok Build harness's variant id — fell into the `grok-4.5` display entry by prefix, and since rows bucket by model id, not display name, the two came out as visually identical rows with different numbers. The variant now shows as `Grok 4.5 (build)`. Display only: no id is rewritten and no cost moves. (#1029)
|
||||
- **The session chart legend now leads with a visible session disambiguator and title instead of the project path.** Every series in a monorepo shared the same project prefix, so the only thing separating them was a truncated hex fragment — and per-application cost attribution is the main reason to open that chart. `SessionSummary.title` is already parsed and already rendered in the Context tab; the legend now puts the short session id first, prefers the title, and falls back to the previous project-based label when a session never produced one. Titles come from transcripts, so they are stripped of ANSI and control characters and capped before they reach either the legend or the tooltip. (#997)
|
||||
- **Context-bloat detection now counts reasoning tokens as generated output.** `detectContextBloat` divided context by `totalOutputTokens` alone, but reasoning is stored beside output rather than inside it, so for every reasoning-bearing provider the detector saw a fraction of the tokens actually generated and invented findings - a session whose real ratio was 20:1, under the 25:1 threshold, was reported as 133:1 and "high impact". It now uses the same `output + reasoning` sum the reports use, which corrects grok, codex, kiro, hermes, qwen and cursor-agent alike.
|
||||
- **The unpriced-models warning in the dashboard is now readable at every terminal width.** It lived in a fixed-width panel with an inline model list and a fix command, so it clipped mid-name at 80 columns and clipped *earlier* at 200, where the three-column layout narrows each panel - neither the affected models nor a runnable command survived. The panel line is now a pointer, `! N unpriced: codeburn models --unpriced` (shortened to `! N: codeburn models --unpriced` below 45 columns of panel), and the model list moves to that command's plain output, which is full width, copyable, and lists every model rather than the first two. The command's hint no longer reads as an unconditional instruction to alias: a subscription or flat-rate model is correctly $0, and mapping it onto another model's per-token rate would invent spend that was never billed. Provider-supplied model IDs are now stripped of terminal control characters in every human-readable report rather than only on the unpriced path, and `--unpriced` shows raw IDs instead of friendly names because `model-alias` keys on the raw ID. (#969)
|
||||
|
|
|
|||
|
|
@ -947,6 +947,10 @@ const SHORT_NAMES: Record<string, string> = {
|
|||
// The Grok Build harness reports the model it runs (`grok-4.5`), so this is
|
||||
// the model's own name; `grok-build*` ids still resolve to "Grok Build".
|
||||
'grok-4.5': 'Grok 4.5',
|
||||
// The harness also reports a `-build` variant of that model. It is a distinct
|
||||
// id and reports bucket by id, so without its own entry the prefix match gave
|
||||
// it the same name as `grok-4.5` and the report showed two identical rows.
|
||||
'grok-4.5-build': 'Grok 4.5 (build)',
|
||||
// ClinePass routes models as `cline-pass/<slug>`; getShortModelName's path
|
||||
// fallback strips the prefix and re-resolves the bare slug through this
|
||||
// table, the same way it handles `accounts/fireworks/models/<slug>`.
|
||||
|
|
|
|||
|
|
@ -490,6 +490,13 @@ describe('grok provider - display names', () => {
|
|||
expect(provider.modelDisplayName('grok-build')).toBe('Grok Build')
|
||||
})
|
||||
|
||||
// Two distinct ids, so two rows; identical names made them look like one row
|
||||
// printed twice (#1029).
|
||||
it('distinguishes the build variant of a model from the model itself', () => {
|
||||
expect(provider.modelDisplayName('grok-4.5')).toBe('Grok 4.5')
|
||||
expect(provider.modelDisplayName('grok-4.5-build')).toBe('Grok 4.5 (build)')
|
||||
})
|
||||
|
||||
it('normalizes tool names', () => {
|
||||
expect(provider.toolDisplayName('run_terminal_command')).toBe('Bash')
|
||||
expect(provider.toolDisplayName('mystery_tool')).toBe('mystery_tool')
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue