garvitsachdeva Claude Sonnet 4.6 commited on
Commit
9988949
Β·
1 Parent(s): 7e20750

feat: add Training Space link to Training tab; fix Space URL in app.py

Browse files
Files changed (2) hide show
  1. app.py +1 -1
  2. demo/streamlit_app.py +19 -0
app.py CHANGED
@@ -605,7 +605,7 @@ with gr.Blocks(title="SpindleFlow RL Training", css=CSS) as demo:
605
  gr.Markdown(
606
  "This Space runs the **RecurrentPPO (LSTM PPO)** training for SpindleFlow RL. "
607
  "The trained model is pushed to HF Hub when training completes and is loaded "
608
- "automatically by the [SpindleFlow Demo Space](https://huggingface.co/spaces/garvitsachdeva/spindleflow-demo)."
609
  )
610
 
611
  # ── Warning banner ────────────────────────────────────────
 
605
  gr.Markdown(
606
  "This Space runs the **RecurrentPPO (LSTM PPO)** training for SpindleFlow RL. "
607
  "The trained model is pushed to HF Hub when training completes and is loaded "
608
+ "automatically by the [SpindleFlow-RL Demo Space](https://huggingface.co/spaces/garvitsachdeva/SpindleFlow-RL)."
609
  )
610
 
611
  # ── Warning banner ────────────────────────────────────────
demo/streamlit_app.py CHANGED
@@ -1432,6 +1432,25 @@ def tab_specialists():
1432
  def tab_training():
1433
  sec("Training Progress β€” Mean Reward per Episode")
1434
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1435
  c_fetch, _ = st.columns([2, 5])
1436
  if c_fetch.button("πŸ“₯ Fetch latest curve from HF Hub", key="fetch_curve"):
1437
  try:
 
1432
  def tab_training():
1433
  sec("Training Progress β€” Mean Reward per Episode")
1434
 
1435
+ st.markdown(
1436
+ '<div style="background:rgba(0,212,255,0.06);border:1px solid rgba(0,212,255,0.20);'
1437
+ 'border-radius:12px;padding:16px 20px;margin-bottom:18px;">'
1438
+ '<div style="font-size:13px;font-weight:700;color:#00d4ff;margin-bottom:6px;">'
1439
+ 'πŸ” Want to run a fresh training run?</div>'
1440
+ '<div style="font-size:12px;color:#94a3b8;margin-bottom:10px;">'
1441
+ 'Open the <strong style="color:#e2e8f0;">Training Space</strong> below, then click '
1442
+ '<strong style="color:#e2e8f0;">β–Ά Start Training</strong>. '
1443
+ 'When the run completes the new model is pushed to HF Hub and this demo loads it automatically.<br>'
1444
+ '<span style="color:#fb923c;font-size:11px;">⚠️ Starting a new run will overwrite the current A100-trained policy.</span>'
1445
+ '</div>'
1446
+ '<a href="https://huggingface.co/spaces/garvitsachdeva/finalRLEnv" target="_blank" '
1447
+ 'style="display:inline-block;background:rgba(0,212,255,0.12);border:1px solid rgba(0,212,255,0.35);'
1448
+ 'color:#00d4ff;padding:7px 18px;border-radius:8px;text-decoration:none;font-size:13px;font-weight:600;">'
1449
+ 'πŸš€ Open Training Space β†’</a>'
1450
+ '</div>',
1451
+ unsafe_allow_html=True,
1452
+ )
1453
+
1454
  c_fetch, _ = st.columns([2, 5])
1455
  if c_fetch.button("πŸ“₯ Fetch latest curve from HF Hub", key="fetch_curve"):
1456
  try: