lablup / lablup/backend.ai-webui
Live training metrics chart in the session detail drawer (log-tail parsing MVP)
- Dominant language
- TypeScript
- Stars
- 133
- Forks
- 81
- Avg merge
- 1d 12h
- Merged PRs (30d)
- 355
Description
## Problem
Users running training sessions have no way to see whether training is progressing without launching TensorBoard or tailing logs manually. The loss/accuracy values are right there in the container logs — we just never visualize them.
## Proposal (Phase 1 of the training-metrics series)
Add a **Metrics tab** to the session detail drawer (`SessionDetailDrawer` / `SessionDetailContent`) that charts training metrics parsed from the session's container logs.
- Poll the existing container log fetch path (the one `ContainerLogModal` uses) for RUNNING sessions at a 10–30s interval, tail-window only.
- Parse step / loss / accuracy via regex adapters for the common trainer output formats: HuggingFace Trainer, PyTorch Lightning, Keras, tqdm-style progress lines. Adapters are pluggable so formats can be added incrementally.
- Render line charts with **recharts** (already a dependency). Live-update while the session is RUNNING; freeze on termination.
- Sessions whose logs match no adapter simply don't show the tab (or show an empty state with a doc link).
Frontend-only: no backend change, no user-code change required.
## Acceptance criteria
- A RUNNING session printing HF Trainer or Lightning logs shows a live-updating loss chart in the detail drawer.
- Polling happens only while the drawer's Metrics tab is open and the session is RUNNING.
- Non-training sessions are unaffected (no tab / clean empty state).
- No extra chart library added; recharts only.
## Follow-ups
- Phase 2: structured metrics file convention (robust parsing, opt-in).
- Phase 3: sparkline column on the session list.
JIRA Issue: FR-3648
Contributor guide
No contributing guide indexed for this repository
Research direction
Start by tracing the existing container log fetch path used by ContainerLogModal, then inspect SessionDetailDrawer and SessionDetailContent to understand how a Metrics tab would fit. Confirm the existing recharts dependency and determine how the requested log formats can be covered by pluggable adapters. Done means running sessions show live HF Trainer or Lightning loss data only while the open tab is active, with no tab or a clean empty state for unmatched logs.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- react, typescript
- Domain
- data-visualization, frontend
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Active
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100