"""Shared look-and-feel: page config, CSS injection, header, GPU status, job badges.""" from __future__ import annotations import streamlit as st # Palette matching the hand-drawn diagrams. COLORS = { "data": "#27ae60", "proc": "#2c6fbb", "store": "#16a085", "model": "#d48806", "rl": "#e67e22", "loss": "#c0392b", "eval": "#8e44ad", "ckpt": "#888888", } _CSS = """ """ _BADGE = {"running": ("b-run", "running"), "finished": ("b-ok", "finished"), "failed": ("b-fail", "failed"), "stopped": ("b-idle", "stopped"), "none": ("b-idle", "idle")} def setup_page(title: str, icon: str = "🧠") -> None: st.set_page_config(page_title=f"{title} · Train LLM From Scratch", page_icon=icon, layout="wide") st.markdown(_CSS, unsafe_allow_html=True) def hero(title: str, subtitle: str) -> None: st.markdown(f'
{subtitle}