fix(studio): default chart view to full training history (#5007)

* fix(studio): default chart view to full training history instead of last 80 steps

Fixes #5003

* chore: windowsize as null code comment

---------

Co-authored-by: imagineer99 <samleejackson0@gmail.com>
Co-authored-by: Wasim Yousef Said <wasimysdev@gmail.com>
This commit is contained in:
Bharath Kumar Adinarayan 2026-04-14 12:29:27 +02:00 committed by GitHub
commit a50f61009b
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -3,12 +3,7 @@
import { create } from "zustand";
import type { OutlierMode, ScaleMode } from "./types";
import { DEFAULT_VISIBLE_POINTS, clamp } from "./utils";
const DEFAULT_WINDOW_SIZE = Math.max(
24,
Math.floor(DEFAULT_VISIBLE_POINTS / 2),
);
import { clamp } from "./utils";
type ChartPreferencesState = {
availableSteps: number;
@ -39,7 +34,7 @@ type ChartPreferencesState = {
};
const defaultPreferences = {
windowSize: DEFAULT_WINDOW_SIZE as number | null,
windowSize: null as number | null, // null = show full training history
smoothing: 0.6,
showRaw: true,
showSmoothed: true,