Skip to content

Add experiment comparison view — side-by-side loss curves and metrics #41

@SahilKumar75

Description

@SahilKumar75

Background

ExperimentState (added in app/state/experiment_state.py) now persists all fine-tuning runs in SQLite with full hyperparameters, final loss, perplexity, and loss_history (the full per-step loss array).

Feature request

Build an Experiment Comparison page or panel that lets users:

  1. Select two or more completed runs from a table or checklist (toggle_run_selection is already implemented).
  2. View overlaid loss curves on a shared axis — one line per run, color-coded.
  3. See a side-by-side metrics table showing final loss, perplexity, epochs, LR, LoRA rank, and dataset.

Design notes

  • Use app/components/loss_chart.py as the base — it already renders a Recharts LineChart.
  • Extend it to accept a list[list[float]] (one series per run) and a matching list[str] for labels.
  • The comparison view can live as a new tab on the Experiments page.
  • ExperimentState.selected_runs already returns the selected ExperimentRun objects.

Acceptance criteria

  • Can select ≥ 2 runs and see their loss curves overlaid on the same chart
  • Metrics table updates to show only selected runs
  • Works with runs that have different numbers of steps (pad or clip to shorter)
  • Empty state shown when fewer than 2 runs are selected

Metadata

Metadata

Assignees

No one assigned

    Labels

    area:analyticsModel analysis, visuals, charts, and explainabilityenhancementNew feature or request

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions