abhinav-joshi commited on
Commit
d1ca5fe
1 Parent(s): 39bc9e0

fix L-MT on default page

Browse files
Files changed (3) hide show
  1. app.py +18 -5
  2. submissions/baseline/results.json +1 -1
  3. uploads.py +10 -0
app.py CHANGED
@@ -156,8 +156,17 @@ with demo:
156
  with gr.Row():
157
  tasks_checkbox = gr.CheckboxGroup(
158
  label="Select Tasks",
159
- choices=["L-NER", "RR", "CJPE", "BAIL", "LSI", "PCR", "SUMM"],
160
- value=["L-NER", "RR", "CJPE", "BAIL", "LSI", "PCR", "SUMM"],
 
 
 
 
 
 
 
 
 
161
  interactive=True,
162
  )
163
 
@@ -231,7 +240,7 @@ with demo:
231
  leaderboard_table = gr.components.Dataframe(
232
  value=load_data(
233
  # "baseline",
234
- ["L-NER", "RR", "CJPE", "BAIL", "LSI", "PCR", "SUMM"],
235
  task_metrics=task_metrics,
236
  ),
237
  interactive=True,
@@ -392,10 +401,13 @@ with demo:
392
  outputs=leaderboard_table,
393
  )
394
 
395
- with gr.Accordion("Submit the results of your Method"):
396
  with gr.Row():
397
  with gr.Column():
398
- method_name_textbox = gr.Textbox(label="Method")
 
 
 
399
  url_textbox = gr.Textbox(label="Github Link")
400
  organisation = gr.Textbox(label="Organisation")
401
  mail = gr.Textbox(label="Contact email")
@@ -407,6 +419,7 @@ with demo:
407
  add_new_eval,
408
  [
409
  method_name_textbox,
 
410
  url_textbox,
411
  file_output,
412
  organisation,
 
156
  with gr.Row():
157
  tasks_checkbox = gr.CheckboxGroup(
158
  label="Select Tasks",
159
+ choices=[
160
+ "L-NER",
161
+ "RR",
162
+ "CJPE",
163
+ "BAIL",
164
+ "LSI",
165
+ "PCR",
166
+ "SUMM",
167
+ "L-MT",
168
+ ],
169
+ value=["L-NER", "RR", "CJPE", "BAIL", "LSI", "PCR", "SUMM", "L-MT"],
170
  interactive=True,
171
  )
172
 
 
240
  leaderboard_table = gr.components.Dataframe(
241
  value=load_data(
242
  # "baseline",
243
+ ["L-NER", "RR", "CJPE", "BAIL", "LSI", "PCR", "SUMM", "L-MT"],
244
  task_metrics=task_metrics,
245
  ),
246
  interactive=True,
 
401
  outputs=leaderboard_table,
402
  )
403
 
404
+ with gr.Accordion("Submit the Results of your Method"):
405
  with gr.Row():
406
  with gr.Column():
407
+ method_name_textbox = gr.Textbox(
408
+ label="Method",
409
+ )
410
+ submitted_by_textbox = gr.Textbox(label="Submitted By (Team Name)")
411
  url_textbox = gr.Textbox(label="Github Link")
412
  organisation = gr.Textbox(label="Organisation")
413
  mail = gr.Textbox(label="Contact email")
 
419
  add_new_eval,
420
  [
421
  method_name_textbox,
422
+ submitted_by_textbox,
423
  url_textbox,
424
  file_output,
425
  organisation,
submissions/baseline/results.json CHANGED
@@ -1 +1 @@
1
- [{"Method": "SOTA", "Submitted By": "multiple", "Github Link": "exploration-lab.github.io/IL-TUR/", "L-NER": {"strict mF1": "48.58"}, "RR": {"mF1": "69.01"}, "CJPE": {"mF1": "81.31", "ROUGE-L": "56.00", "BLEU": "32.00"}, "BAIL": {"mF1": "81"}, "LSI": {"mF1": "28.08"}, "PCR": {"muF1@K": "39.15"}, "SUMM": {"ROUGE-L": "33.00", "BERTSCORE": "86.00"}, "L-MT": {"BLEU": "28.00", "GLEU": "32.00", "chrF++": "57.00"}}, {"Method": "BERT", "Submitted By": "multiple", "Github Link": "", "L-NER": {"strict mF1": "39.59"}, "RR": {"mF1": "58"}, "CJPE": {"mF1": "71.14", "ROUGE-L": "-", "BLEU": "-"}, "BAIL": {"mF1": "-"}, "LSI": {"mF1": "-"}, "PCR": {"muF1@K": "18.44"}, "SUMM": {"ROUGE-L": "9.24", "BERTSCORE": "-"}, "L-MT": {"BLEU": "-", "GLEU": "-", "chrF++": "-"}}, {"Method": "LegalBERT", "Submitted By": "multiple", "Github Link": "", "L-NER": {"strict mF1": "45.58"}, "RR": {"mF1": "54"}, "CJPE": {"mF1": "78.21", "ROUGE-L": "-", "BLEU": "-"}, "BAIL": {"mF1": "-"}, "LSI": {"mF1": "-"}, "PCR": {"muF1@K": "21.74"}, "SUMM": {"ROUGE-L": "8.67", "BERTSCORE": "-"}, "L-MT": {"BLEU": "-", "GLEU": "-", "chrF++": "-"}}, {"Method": "InLegalBERT", "Submitted By": "multiple", "Github Link": "", "L-NER": {"strict mF1": "48.58"}, "RR": {"mF1": "58"}, "CJPE": {"mF1": "81.31", "ROUGE-L": "-", "BLEU": "-"}, "BAIL": {"mF1": "-"}, "LSI": {"mF1": "-"}, "PCR": {"muF1@K": "26.23"}, "SUMM": {"ROUGE-L": "7.57", "BERTSCORE": "-"}, "L-MT": {"BLEU": "-", "GLEU": "-", "chrF++": "-"}}, {"Method": "GPT-3.5 (0-shot)", "Submitted By": "IL-TUR", "Github Link": "", "L-NER": {"strict mF1": "30.59"}, "RR": {"mF1": "30.95"}, "CJPE": {"mF1": "54.17", "ROUGE-L": "30.00", "BLEU": "8.00"}, "BAIL": {"mF1": "51.04"}, "LSI": {"mF1": "21.55"}, "PCR": {"muF1@K": "-"}, "SUMM": {"ROUGE-L": "21.00", "BERTSCORE": "85.00"}, "L-MT": {"BLEU": "23.00", "GLEU": "28.00", "chrF++": "42.00"}}, {"Method": "GPT-3.5 (1-shot)", "Submitted By": "IL-TUR", "Github Link": "", "L-NER": {"strict mF1": "23.68"}, "RR": {"mF1": "30.05"}, "CJPE": {"mF1": "51.46", "ROUGE-L": "29.00", "BLEU": "15.00"}, "BAIL": {"mF1": "46.35"}, "LSI": {"mF1": "22.61"}, "PCR": {"muF1@K": "-"}, "SUMM": {"ROUGE-L": "20.00", "BERTSCORE": "84.00"}, "L-MT": {"BLEU": "25.00", "GLEU": "28.00", "chrF++": "43.00"}}, {"Method": "GPT-3.5 (2-shot)", "Submitted By": "IL-TUR", "Github Link": "", "L-NER": {"strict mF1": "32.84"}, "RR": {"mF1": "30.31"}, "CJPE": {"mF1": "56.74", "ROUGE-L": "30.00", "BLEU": "11.00"}, "BAIL": {"mF1": "61"}, "LSI": {"mF1": "21.4"}, "PCR": {"muF1@K": "-"}, "SUMM": {"ROUGE-L": "22.00", "BERTSCORE": "84.00"}, "L-MT": {"BLEU": "26.00", "GLEU": "29.00", "chrF++": "43.00"}}, {"Method": "GPT-4 (0-shot)", "Submitted By": "IL-TUR", "Github Link": "", "L-NER": {"strict mF1": "13.65"}, "RR": {"mF1": "37.37"}, "CJPE": {"mF1": "68.29", "ROUGE-L": "40.00", "BLEU": "14.00"}, "BAIL": {"mF1": "51.46"}, "LSI": {"mF1": "23.99"}, "PCR": {"muF1@K": "-"}, "SUMM": {"ROUGE-L": "23.00", "BERTSCORE": "85.00"}, "L-MT": {"BLEU": "33.00", "GLEU": "36.00", "chrF++": "50.00"}}, {"Method": "GPT-4 (1-shot)", "Submitted By": "IL-TUR", "Github Link": "", "L-NER": {"strict mF1": "10.51"}, "RR": {"mF1": "37.43"}, "CJPE": {"mF1": "47.26", "ROUGE-L": "39.00", "BLEU": "16.00"}, "BAIL": {"mF1": "56.9"}, "LSI": {"mF1": "22.26"}, "PCR": {"muF1@K": "-"}, "SUMM": {"ROUGE-L": "16.00", "BERTSCORE": "81.00"}, "L-MT": {"BLEU": "35.00", "GLEU": "38.00", "chrF++": "52.00"}}, {"Method": "GPT-4 (2-shot)", "Submitted By": "IL-TUR", "Github Link": "", "L-NER": {"strict mF1": "24.03"}, "RR": {"mF1": "38.18"}, "CJPE": {"mF1": "60.44", "ROUGE-L": "43.00", "BLEU": "18.00"}, "BAIL": {"mF1": "66.67"}, "LSI": {"mF1": "20.53"}, "PCR": {"muF1@K": "-"}, "SUMM": {"ROUGE-L": "17.00", "BERTSCORE": "81.00"}, "L-MT": {"BLEU": "36.00", "GLEU": "39.00", "chrF++": "53.00"}}, {"Method": "GPT-5 (2-shot)", "Submitted By": "IL-TUR", "Github Link": "dummy submission", "L-NER": {"strict mF1": "24.03"}, "RR": {"mF1": "38.18"}, "CJPE": {"mF1": "60.44", "ROUGE-L": "43.00", "BLEU": "18.00"}, "BAIL": {"mF1": "66.67"}, "LSI": {"mF1": "20.53"}, "PCR": {"muF1@K": "-"}, "SUMM": {"ROUGE-L": "17.00", "BERTSCORE": "81.00"}, "L-MT": {"BLEU": "36.00", "GLEU": "39.00", "chrF++": "53.00"}}, {"Method": "GPT-5 (2-shot)", "Submitted By": "IL-TUR", "Github Link": "dummy submission", "L-NER": {"strict mF1": "24.03"}, "RR": {"mF1": "38.18"}, "CJPE": {"mF1": "60.44", "ROUGE-L": "43.00", "BLEU": "18.00"}, "BAIL": {"mF1": "66.67"}, "LSI": {"mF1": "20.53"}, "PCR": {"muF1@K": "-"}, "SUMM": {"ROUGE-L": "17.00", "BERTSCORE": "81.00"}, "L-MT": {"BLEU": "36.00", "GLEU": "39.00", "chrF++": "53.00"}}]
 
1
+ [{"Method": "SOTA", "Submitted By": "multiple", "Github Link": "exploration-lab.github.io/IL-TUR/", "L-NER": {"strict mF1": "48.58"}, "RR": {"mF1": "69.01"}, "CJPE": {"mF1": "81.31", "ROUGE-L": "56.00", "BLEU": "32.00"}, "BAIL": {"mF1": "81"}, "LSI": {"mF1": "28.08"}, "PCR": {"muF1@K": "39.15"}, "SUMM": {"ROUGE-L": "33.00", "BERTSCORE": "86.00"}, "L-MT": {"BLEU": "28.00", "GLEU": "32.00", "chrF++": "57.00"}}, {"Method": "BERT", "Submitted By": "multiple", "Github Link": "", "L-NER": {"strict mF1": "39.59"}, "RR": {"mF1": "58"}, "CJPE": {"mF1": "71.14", "ROUGE-L": "-", "BLEU": "-"}, "BAIL": {"mF1": "-"}, "LSI": {"mF1": "-"}, "PCR": {"muF1@K": "18.44"}, "SUMM": {"ROUGE-L": "9.24", "BERTSCORE": "-"}, "L-MT": {"BLEU": "-", "GLEU": "-", "chrF++": "-"}}, {"Method": "LegalBERT", "Submitted By": "multiple", "Github Link": "", "L-NER": {"strict mF1": "45.58"}, "RR": {"mF1": "54"}, "CJPE": {"mF1": "78.21", "ROUGE-L": "-", "BLEU": "-"}, "BAIL": {"mF1": "-"}, "LSI": {"mF1": "-"}, "PCR": {"muF1@K": "21.74"}, "SUMM": {"ROUGE-L": "8.67", "BERTSCORE": "-"}, "L-MT": {"BLEU": "-", "GLEU": "-", "chrF++": "-"}}, {"Method": "InLegalBERT", "Submitted By": "multiple", "Github Link": "", "L-NER": {"strict mF1": "48.58"}, "RR": {"mF1": "58"}, "CJPE": {"mF1": "81.31", "ROUGE-L": "-", "BLEU": "-"}, "BAIL": {"mF1": "-"}, "LSI": {"mF1": "-"}, "PCR": {"muF1@K": "26.23"}, "SUMM": {"ROUGE-L": "7.57", "BERTSCORE": "-"}, "L-MT": {"BLEU": "-", "GLEU": "-", "chrF++": "-"}}, {"Method": "GPT-3.5 (0-shot)", "Submitted By": "IL-TUR", "Github Link": "", "L-NER": {"strict mF1": "30.59"}, "RR": {"mF1": "30.95"}, "CJPE": {"mF1": "54.17", "ROUGE-L": "30.00", "BLEU": "8.00"}, "BAIL": {"mF1": "51.04"}, "LSI": {"mF1": "21.55"}, "PCR": {"muF1@K": "-"}, "SUMM": {"ROUGE-L": "21.00", "BERTSCORE": "85.00"}, "L-MT": {"BLEU": "23.00", "GLEU": "28.00", "chrF++": "42.00"}}, {"Method": "GPT-3.5 (1-shot)", "Submitted By": "IL-TUR", "Github Link": "", "L-NER": {"strict mF1": "23.68"}, "RR": {"mF1": "30.05"}, "CJPE": {"mF1": "51.46", "ROUGE-L": "29.00", "BLEU": "15.00"}, "BAIL": {"mF1": "46.35"}, "LSI": {"mF1": "22.61"}, "PCR": {"muF1@K": "-"}, "SUMM": {"ROUGE-L": "20.00", "BERTSCORE": "84.00"}, "L-MT": {"BLEU": "25.00", "GLEU": "28.00", "chrF++": "43.00"}}, {"Method": "GPT-3.5 (2-shot)", "Submitted By": "IL-TUR", "Github Link": "", "L-NER": {"strict mF1": "32.84"}, "RR": {"mF1": "30.31"}, "CJPE": {"mF1": "56.74", "ROUGE-L": "30.00", "BLEU": "11.00"}, "BAIL": {"mF1": "61"}, "LSI": {"mF1": "21.4"}, "PCR": {"muF1@K": "-"}, "SUMM": {"ROUGE-L": "22.00", "BERTSCORE": "84.00"}, "L-MT": {"BLEU": "26.00", "GLEU": "29.00", "chrF++": "43.00"}}, {"Method": "GPT-4 (0-shot)", "Submitted By": "IL-TUR", "Github Link": "", "L-NER": {"strict mF1": "13.65"}, "RR": {"mF1": "37.37"}, "CJPE": {"mF1": "68.29", "ROUGE-L": "40.00", "BLEU": "14.00"}, "BAIL": {"mF1": "51.46"}, "LSI": {"mF1": "23.99"}, "PCR": {"muF1@K": "-"}, "SUMM": {"ROUGE-L": "23.00", "BERTSCORE": "85.00"}, "L-MT": {"BLEU": "33.00", "GLEU": "36.00", "chrF++": "50.00"}}, {"Method": "GPT-4 (1-shot)", "Submitted By": "IL-TUR", "Github Link": "", "L-NER": {"strict mF1": "10.51"}, "RR": {"mF1": "37.43"}, "CJPE": {"mF1": "47.26", "ROUGE-L": "39.00", "BLEU": "16.00"}, "BAIL": {"mF1": "56.9"}, "LSI": {"mF1": "22.26"}, "PCR": {"muF1@K": "-"}, "SUMM": {"ROUGE-L": "16.00", "BERTSCORE": "81.00"}, "L-MT": {"BLEU": "35.00", "GLEU": "38.00", "chrF++": "52.00"}}, {"Method": "GPT-4 (2-shot)", "Submitted By": "IL-TUR", "Github Link": "", "L-NER": {"strict mF1": "24.03"}, "RR": {"mF1": "38.18"}, "CJPE": {"mF1": "60.44", "ROUGE-L": "43.00", "BLEU": "18.00"}, "BAIL": {"mF1": "66.67"}, "LSI": {"mF1": "20.53"}, "PCR": {"muF1@K": "-"}, "SUMM": {"ROUGE-L": "17.00", "BERTSCORE": "81.00"}, "L-MT": {"BLEU": "36.00", "GLEU": "39.00", "chrF++": "53.00"}}]
uploads.py CHANGED
@@ -4,6 +4,7 @@ import os
4
  import datetime
5
  import json
6
  import pandas as pd
 
7
 
8
  LEADERBOARD_PATH = "Exploration-Lab/IL-TUR-Leaderboard"
9
  # RESULTS_PATH = "Exploration-Lab/IL-TUR-Leaderboard-results"
@@ -42,11 +43,20 @@ def input_verification(method_name, url, path_to_file, organisation, mail):
42
  if path_to_file is None:
43
  return format_warning("Please attach a file.")
44
 
 
 
 
 
 
 
 
 
45
  return parsed_mail
46
 
47
 
48
  def add_new_eval(
49
  method_name: str,
 
50
  url: str,
51
  path_to_file: str,
52
  organisation: str,
 
4
  import datetime
5
  import json
6
  import pandas as pd
7
+ import gradio as gr
8
 
9
  LEADERBOARD_PATH = "Exploration-Lab/IL-TUR-Leaderboard"
10
  # RESULTS_PATH = "Exploration-Lab/IL-TUR-Leaderboard-results"
 
43
  if path_to_file is None:
44
  return format_warning("Please attach a file.")
45
 
46
+ # check the required fields
47
+ required_fields = ["Method", "Submitted By", "url", "organisation", "mail"]
48
+
49
+ # Check if the required_fields are not blank
50
+ for field in required_fields:
51
+ if field not in locals():
52
+ raise gr.Error(f"{field} cannot be blank")
53
+
54
  return parsed_mail
55
 
56
 
57
  def add_new_eval(
58
  method_name: str,
59
+ submitted_by: str,
60
  url: str,
61
  path_to_file: str,
62
  organisation: str,