Skip to content

Model defaults to only FP4, when only 1 curve #470

Closed

Description

@Oseltamivir

Activity

  1. Oseltamivir commented on Jun 18, 2026

    @Oseltamivir
    ContributorAuthor
  2. github-actions commented on Jun 18, 2026

    @github-actions
    Contributor

    Claude finished @Oseltamivir's task in 19m 23s —— View job • claude/issue-470-20260618-0436 • Create PR ➔


    Fixing MiniMax M3 default precision

    Reproduced on the live site: selecting MiniMax M3 from the model dropdown left precisions at the global [FP4] default. M3's day-zero rollout shipped 23 FP8 datapoints per sequence vs 1 FP4 row, so the chart was almost empty until users manually checked FP8.

    Fix

    • Added a per-model defaultPrecisions field on ModelConfig (packages/app/src/lib/data-mappings.ts) and seeded Model.MiniMax_M3 with ['fp4', 'fp8']. Other models inherit the existing [fp4] fallback.
    • Wrapped the public setSelectedModel in GlobalFilterContext to re-seed precisions to the new model's defaults. URL i_prec=… and InferenceContext.applyPreset write to precision state immediately after the model setter, so they still win the React batch — URL hydration, preset application, and the unofficial-run auto-switch all behave as before.
    • Updated initial selectedPrecisions state to honor the initial model's defaults.

    Verification (Playwright, local dev server)

    Path Model Precision
    /inference → switch to MiniMax M3 MiniMax M3 428B FP4 + FP8
    Switch back to DSv4 DeepSeek V4 Pro 1.6T FP4 (default)
    /inference?g_model=MiniMax-M3&i_prec=fp8 MiniMax M3 428B FP8 (URL wins)
    /inference?preset=minimax-m3-launch MiniMax M3 428B FP4 + FP8

    Chart renders 647 SVG elements, no "No data available" message.

    • Find where MiniMax M3 default precision is configured
    • Add defaultPrecisions to ModelConfig; set MiniMax M3 = ['fp4', 'fp8']
    • Reset precisions on model change in GlobalFilterContext (URL i_prec still overrides)
    • Add unit tests (getModelDefaultPrecisions)
    • Typecheck ✅, lint ✅, fmt ✅, 2107 unit tests pass ✅
    • Commit and push (cbb849e)

    · branch: claude/issue-470-20260618-0436

  3. changed the title [-]MiniMax M3 default only FP4, should be FP4 and FP8[/-] [+]Model defaults to only FP4, when only 1 curve[/+] on Jun 18, 2026
  4. github-actions commented on Jun 28, 2026

    @github-actions
    Contributor

    Claude finished @Oseltamivir's task in 11m 56s —— View job • claude/issue-470-20260628-1043 • Create PR ➔


    Duplicate graph labels — root cause & fix

    Why there were multiple labels. With a single precision selected, the inference chart de-duplicates line labels to one per hardware type. For Qwen-3.5 on Jun 25 there are three b300_sglang curves (fp4, fp8, bf16) that all share the label text "B300 (SGLang)" — the render keeps one (visible: true) and hides the other two (visible: false).

    The hidden duplicates were getting re-shown because three separate visibility-sync code paths in ScatterGraph.tsx (legend hover, hover-end reset, and the filter-change effect) re-set line-label opacity from hardware membership alone — they never consulted the render's visible flag. Since every duplicate carries the same data-hw-key="b300_sglang", all three "B300 (SGLang)" labels lit up and stacked on the curve (exactly your screenshot). It's a render race the live build loses (a fast dev machine happens to correct it with a follow-up render).

    Fix. Persist the render's per-label decision as a data-visible attribute and respect it in all three sync paths. Extracted the opacity logic into pure, unit-tested helpers (line-label-visibility.ts) so the de-dup invariant can't silently regress.

    • Reproduce + confirm the 3× b300_sglang labels share one data-hw-key
    • Identify the 3 sync paths that ignored the visible flag
    • Fix via data-visible + pure helpers, wired into all 3 paths
    • Verify in browser — now exactly one label per active hardware, no duplicates (steady state + legend-hover path)
    • Add regression tests (10 cases) · typecheck ✅ lint ✅ fmt ✅ · app unit tests ✅
    • Commit & push (aff62bb)

    Before → After

    Labels on the B300 curve
    Before B300 (SGLang) ×3 (stacked)
    After B300 (SGLang) ×1

    Note: this is a separate issue from the original #470 title (FP4 default). It only addresses the duplicate-labels question from your screenshot. The fix applies to both official and ?unofficialrun= overlay paths (overlay labels use the same .line-label join + data-visible attribute).

    • branch claude/issue-470-20260628-1043

  5. Oseltamivir commented on Jun 28, 2026

    @Oseltamivir
    ContributorAuthor

    @claude combine both the above branches into 1 updated one and PR against master

  6. github-actions commented on Jun 28, 2026

    @github-actions
    Contributor

    Claude finished @Oseltamivir's task in 6m 30s —— View job • claude/issue-470-20260628-1158


    Combined both #470 branches into one PR ✅

    When I went to combine the two branches, I found they're not in the same state anymore:

    Branch Fix Status
    …1043 (aff62bb) Stop stacking duplicate line labels per hardware New — not in master. ✅ Carried into this branch.
    …0436 (cbb849e) Seed MiniMax M3 default precisions to FP4+FP8 Already superseded by master. ⛔ Not re-applied (would regress).

    Why the FP4 fix was dropped: Since branch …0436 was cut, master (8f612d6) added a more general, data-driven mechanism in GlobalFilterContext — resolveEffectivePrecisions auto-picks the densest precision per model/sequence until the user explicitly chooses one (tracked via precisionExplicit). For MiniMax M3 (23 FP8 curves vs 1 FP4 row) it auto-selects FP8, which is the original "defaults to only FP4" fix — and better than the stale branch's static defaultPrecisions: ['fp4','fp8']. Cherry-picking cbb849e on top conflicted and would have hard-reset precisions on every model switch, fighting precisionExplicit. So the combined PR = duplicate-labels fix on top of master, which already contains the FP4 fix's intent.

    Verification (Playwright, local dev)

    1. Duplicate labels — fixed (exact URL from your screenshot, Qwen-3.5 Jun 25, single FP4 precision):

    • Two chart panels on the page, each now shows exactly one B300 (SGLang) and one GB300 NVL72 (Dynamo SGLang) label (was 3× stacked). 0 console errors, real data.

    2. Original #470 (M3 → FP4) — already fixed by master:

    • /inference?g_model=MiniMax-M3 opens with precision FP8 auto-selected, chart renders 2294 points, no "No data available".

    Checks

    • Cherry-pick duplicate-labels fix; drop stale FP4 fix (already in master, via a better mechanism)
    • pnpm typecheck ✅ · pnpm lint ✅ · pnpm fmt ✅
    • Unit tests ✅ (2177 pass, incl. the 10 line-label-visibility cases)
    • Browser-verified both behaviors
    • Pushed claude/issue-470-20260628-1158

    Overlay note: the dup-labels fix lives in the shared ScatterGraph .line-label D3 join (now keyed by data-visible), so it applies to both official runs and ?unofficialrun= overlays — same code path.

    Create a PR ➔
    • branch claude/issue-470-20260628-1158

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions