Spaces:
Sleeping
Sleeping
joshua400 commited on
Commit Β·
b8afba2
1
Parent(s): 2521148
π FINAL POLISH: Fixed image visibility in UI and added captioned plots to README
Browse files- README.md +14 -2
- server/app.py +12 -4
README.md
CHANGED
|
@@ -152,13 +152,25 @@ LLM Agent (GRPO trained)
|
|
| 152 |
|
| 153 |

|
| 154 |
|
| 155 |
-
*
|
| 156 |
|
| 157 |
### Reward Curve Over Training
|
| 158 |
|
| 159 |

|
| 160 |
|
| 161 |
-
*4-episode moving average.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 162 |
|
| 163 |
### Key Numbers
|
| 164 |
|
|
|
|
| 152 |
|
| 153 |

|
| 154 |
|
| 155 |
+
*Figure 2: Heatmap showing per-episode rewards. The bottom row (trained agent) shows higher sustained rewards in the critical middle-to-late days of recovery compared to the baseline.*
|
| 156 |
|
| 157 |
### Reward Curve Over Training
|
| 158 |
|
| 159 |

|
| 160 |
|
| 161 |
+
*Figure 3: 4-episode moving average. The Sarvam-105B agent steadily learns to capture both service restoration and fairness bonuses, outperforming the heuristic greedy baseline after ~20 iterations.*
|
| 162 |
+
|
| 163 |
+
### Utility vs Fairness Trade-off
|
| 164 |
+
|
| 165 |
+

|
| 166 |
+
|
| 167 |
+
*Figure 4: Intersectional analysis showing the agent's progress. Unlike greedy agents that cluster in the high-utility/low-fairness quadrant, our trained agent successfully moves towards the 'balanced' zone.*
|
| 168 |
+
|
| 169 |
+
### Fairness Progress
|
| 170 |
+
|
| 171 |
+

|
| 172 |
+
|
| 173 |
+
*Figure 5: Total Fairness Score across episodes. The training successfully pushed the agent to consider vulnerable zones, resulting in a consistent upward trend in equity achievement.*
|
| 174 |
|
| 175 |
### Key Numbers
|
| 176 |
|
server/app.py
CHANGED
|
@@ -105,12 +105,20 @@ def _build_app():
|
|
| 105 |
|
| 106 |
with gr.Tab("Analysis & Fairness"):
|
| 107 |
gr.Markdown("## π Training Results & Fairness Trends")
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 108 |
with gr.Row():
|
| 109 |
-
gr.Image(
|
| 110 |
-
gr.Image(
|
| 111 |
with gr.Row():
|
| 112 |
-
gr.Image(
|
| 113 |
-
gr.Image(
|
| 114 |
|
| 115 |
with gr.Tab("README"):
|
| 116 |
readme_path = os.path.join(os.path.dirname(os.path.dirname(__file__)), "README.md")
|
|
|
|
| 105 |
|
| 106 |
with gr.Tab("Analysis & Fairness"):
|
| 107 |
gr.Markdown("## π Training Results & Fairness Trends")
|
| 108 |
+
|
| 109 |
+
# Use absolute filesystem paths for gr.Image
|
| 110 |
+
base_dir = os.path.dirname(os.path.dirname(__file__))
|
| 111 |
+
results_img = os.path.join(base_dir, "assets", "training_results.png")
|
| 112 |
+
heatmap_img = os.path.join(base_dir, "assets", "score_heatmap.png")
|
| 113 |
+
loss_img = os.path.join(base_dir, "assets", "training_loss.png")
|
| 114 |
+
fair_img = os.path.join(base_dir, "assets", "fairness_vs_episode.png")
|
| 115 |
+
|
| 116 |
with gr.Row():
|
| 117 |
+
gr.Image(results_img if os.path.exists(results_img) else None, label="Trained vs Baseline")
|
| 118 |
+
gr.Image(heatmap_img if os.path.exists(heatmap_img) else None, label="Episode Rewards")
|
| 119 |
with gr.Row():
|
| 120 |
+
gr.Image(loss_img if os.path.exists(loss_img) else None, label="Reward Convergence")
|
| 121 |
+
gr.Image(fair_img if os.path.exists(fair_img) else None, label="Fairness Improvement")
|
| 122 |
|
| 123 |
with gr.Tab("README"):
|
| 124 |
readme_path = os.path.join(os.path.dirname(os.path.dirname(__file__)), "README.md")
|