Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -4,6 +4,7 @@ import os
|
|
4 |
import shutil
|
5 |
import json
|
6 |
from zipfile import ZipFile
|
|
|
7 |
|
8 |
# Function to load leaderboard data from a CSV file
|
9 |
def load_leaderboard_data(csv_file_path):
|
@@ -51,18 +52,19 @@ leaderboard2 = load_leaderboard_data("leaderboard_gaia.csv")
|
|
51 |
with gr.Blocks() as demo:
|
52 |
gr.Markdown("# 🏆 TRAIL: Trace Reasoning and Agentic Issue Localization Leaderboard")
|
53 |
|
54 |
-
with gr.
|
55 |
-
with gr.
|
56 |
-
gr.
|
57 |
-
|
58 |
-
|
59 |
-
gr.
|
60 |
-
|
|
|
61 |
|
62 |
-
with gr.
|
63 |
gr.Markdown("## Submit Your ZIP of JSONs")
|
64 |
|
65 |
-
with gr.Row():
|
66 |
with gr.Column():
|
67 |
file_input = gr.File(
|
68 |
label="Upload ZIP File",
|
@@ -85,5 +87,13 @@ with gr.Blocks() as demo:
|
|
85 |
outputs=output
|
86 |
)
|
87 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
88 |
if __name__ == "__main__":
|
89 |
demo.launch()
|
|
|
4 |
import shutil
|
5 |
import json
|
6 |
from zipfile import ZipFile
|
7 |
+
import re
|
8 |
|
9 |
# Function to load leaderboard data from a CSV file
|
10 |
def load_leaderboard_data(csv_file_path):
|
|
|
52 |
with gr.Blocks() as demo:
|
53 |
gr.Markdown("# 🏆 TRAIL: Trace Reasoning and Agentic Issue Localization Leaderboard")
|
54 |
|
55 |
+
with gr.Tab("LEADERBOARD"):
|
56 |
+
with gr.Row():
|
57 |
+
with gr.Column():
|
58 |
+
gr.Markdown("## TRAIL-SWE Leaderboard")
|
59 |
+
gr.Dataframe(leaderboard1)
|
60 |
+
with gr.Column():
|
61 |
+
gr.Markdown("## TRAIL-GAIA Leaderboard")
|
62 |
+
gr.Dataframe(leaderboard2)
|
63 |
|
64 |
+
with gr.Tab("SUBMIT ZIP"):
|
65 |
gr.Markdown("## Submit Your ZIP of JSONs")
|
66 |
|
67 |
+
#with gr.Row():
|
68 |
with gr.Column():
|
69 |
file_input = gr.File(
|
70 |
label="Upload ZIP File",
|
|
|
87 |
outputs=output
|
88 |
)
|
89 |
|
90 |
+
with open("README.md", "r", encoding="utf-8") as f:
|
91 |
+
README_CONTENT = f.read()
|
92 |
+
yaml_front_matter = re.compile(r"^---\s*.*?\s*---\s*", re.DOTALL)
|
93 |
+
readme_content_without_yaml = re.sub(yaml_front_matter, "", README_CONTENT).strip()
|
94 |
+
|
95 |
+
with gr.Tab("README"):
|
96 |
+
gr.Markdown(readme_content_without_yaml)
|
97 |
+
|
98 |
if __name__ == "__main__":
|
99 |
demo.launch()
|