pminervini commited on
Commit
24eddae
β€’
1 Parent(s): 142beab
app.py CHANGED
@@ -26,30 +26,25 @@ from src.display.utils import (
26
  from src.envs import API, EVAL_REQUESTS_PATH, EVAL_RESULTS_PATH, H4_TOKEN, IS_PUBLIC, QUEUE_REPO, REPO_ID, RESULTS_REPO
27
  from src.populate import get_evaluation_queue_df, get_leaderboard_df
28
  from src.submission.submit import add_new_eval
29
- from src.submission.check_validity import already_submitted_models
30
- from src.tools.collections import update_collections
31
  from src.tools.plots import (
32
  create_metric_plot_obj,
33
  create_plot_df,
34
  create_scores_df,
35
  )
36
 
37
-
38
  def restart_space():
39
  API.restart_space(repo_id=REPO_ID, token=H4_TOKEN)
40
 
41
  try:
42
  print(EVAL_REQUESTS_PATH)
43
- snapshot_download(
44
- repo_id=QUEUE_REPO, local_dir=EVAL_REQUESTS_PATH, repo_type="dataset", tqdm_class=None, etag_timeout=30
45
- )
46
  except Exception:
47
  restart_space()
48
  try:
49
  print(EVAL_RESULTS_PATH)
50
- snapshot_download(
51
- repo_id=RESULTS_REPO, local_dir=EVAL_RESULTS_PATH, repo_type="dataset", tqdm_class=None, etag_timeout=30
52
- )
53
  except Exception:
54
  restart_space()
55
 
@@ -60,11 +55,7 @@ leaderboard_df = original_df.copy()
60
 
61
  plot_df = create_plot_df(create_scores_df(raw_data))
62
 
63
- (
64
- finished_eval_queue_df,
65
- running_eval_queue_df,
66
- pending_eval_queue_df,
67
- ) = get_evaluation_queue_df(EVAL_REQUESTS_PATH, EVAL_COLS)
68
 
69
 
70
  # Searching and filtering
 
26
  from src.envs import API, EVAL_REQUESTS_PATH, EVAL_RESULTS_PATH, H4_TOKEN, IS_PUBLIC, QUEUE_REPO, REPO_ID, RESULTS_REPO
27
  from src.populate import get_evaluation_queue_df, get_leaderboard_df
28
  from src.submission.submit import add_new_eval
29
+ # from src.submission.check_validity import already_submitted_models
30
+ # from src.tools.collections import update_collections
31
  from src.tools.plots import (
32
  create_metric_plot_obj,
33
  create_plot_df,
34
  create_scores_df,
35
  )
36
 
 
37
  def restart_space():
38
  API.restart_space(repo_id=REPO_ID, token=H4_TOKEN)
39
 
40
  try:
41
  print(EVAL_REQUESTS_PATH)
42
+ snapshot_download(repo_id=QUEUE_REPO, local_dir=EVAL_REQUESTS_PATH, repo_type="dataset", tqdm_class=None, etag_timeout=30)
 
 
43
  except Exception:
44
  restart_space()
45
  try:
46
  print(EVAL_RESULTS_PATH)
47
+ snapshot_download(repo_id=RESULTS_REPO, local_dir=EVAL_RESULTS_PATH, repo_type="dataset", tqdm_class=None, etag_timeout=30)
 
 
48
  except Exception:
49
  restart_space()
50
 
 
55
 
56
  plot_df = create_plot_df(create_scores_df(raw_data))
57
 
58
+ (finished_eval_queue_df, running_eval_queue_df, pending_eval_queue_df) = get_evaluation_queue_df(EVAL_REQUESTS_PATH, EVAL_COLS)
 
 
 
 
59
 
60
 
61
  # Searching and filtering
requirements.txt CHANGED
@@ -1,4 +1,5 @@
1
  torch
 
2
  APScheduler==3.10.1
3
  black==23.11.0
4
  click==8.1.3
 
1
  torch
2
+ colorama
3
  APScheduler==3.10.1
4
  black==23.11.0
5
  click==8.1.3
scripts/create_request_file.py CHANGED
@@ -9,7 +9,7 @@ from colorama import Fore
9
  from huggingface_hub import HfApi, snapshot_download
10
 
11
  EVAL_REQUESTS_PATH = "eval-queue"
12
- QUEUE_REPO = "open-llm-leaderboard/requests"
13
 
14
  precisions = ("float16", "bfloat16", "8bit (LLM.int8)", "4bit (QLoRA / FP4)", "GPTQ")
15
  model_types = ("pretrained", "fine-tuned", "RL-tuned", "instruction-tuned")
 
9
  from huggingface_hub import HfApi, snapshot_download
10
 
11
  EVAL_REQUESTS_PATH = "eval-queue"
12
+ QUEUE_REPO = "hallucinations-leaderboard/requests"
13
 
14
  precisions = ("float16", "bfloat16", "8bit (LLM.int8)", "4bit (QLoRA / FP4)", "GPTQ")
15
  model_types = ("pretrained", "fine-tuned", "RL-tuned", "instruction-tuned")
src/display/about.py CHANGED
@@ -1,9 +1,9 @@
1
  from src.display.utils import ModelType
2
 
3
- TITLE = """<h1 align="center" id="space-title">πŸ€— Open LLM Leaderboard</h1>"""
4
 
5
  INTRODUCTION_TEXT = """
6
- πŸ“ The πŸ€— Open LLM Leaderboard aims to track, rank and evaluate open LLMs and chatbots.
7
 
8
  πŸ€— Submit a model for automated evaluation on the πŸ€— GPU cluster on the "Submit" page!
9
  The leaderboard's backend runs the great [Eleuther AI Language Model Evaluation Harness](https://github.com/EleutherAI/lm-evaluation-harness) - read more details in the "About" page!
 
1
  from src.display.utils import ModelType
2
 
3
+ TITLE = """<h1 align="center" id="space-title">πŸ€— Open Hallucinations Leaderboard</h1>"""
4
 
5
  INTRODUCTION_TEXT = """
6
+ πŸ“ The πŸ€— Open Hallucinations Leaderboard aims to track, rank and evaluate hallucinations in LLMs and chatbots.
7
 
8
  πŸ€— Submit a model for automated evaluation on the πŸ€— GPU cluster on the "Submit" page!
9
  The leaderboard's backend runs the great [Eleuther AI Language Model Evaluation Harness](https://github.com/EleutherAI/lm-evaluation-harness) - read more details in the "About" page!
src/envs.py CHANGED
@@ -14,7 +14,7 @@ PRIVATE_RESULTS_REPO = "hallucinations-leaderboard/private-results"
14
 
15
  IS_PUBLIC = bool(os.environ.get("IS_PUBLIC", True))
16
 
17
- CACHE_PATH=os.getenv("HF_HOME", ".")
18
 
19
  EVAL_REQUESTS_PATH = os.path.join(CACHE_PATH, "eval-queue")
20
  EVAL_RESULTS_PATH = os.path.join(CACHE_PATH, "eval-results")
 
14
 
15
  IS_PUBLIC = bool(os.environ.get("IS_PUBLIC", True))
16
 
17
+ CACHE_PATH = os.getenv("HF_HOME", ".")
18
 
19
  EVAL_REQUESTS_PATH = os.path.join(CACHE_PATH, "eval-queue")
20
  EVAL_RESULTS_PATH = os.path.join(CACHE_PATH, "eval-results")
src/leaderboard/read_evals.py CHANGED
@@ -5,8 +5,8 @@ import os
5
  from dataclasses import dataclass
6
 
7
  import dateutil
8
- from datetime import datetime
9
- from transformers import AutoConfig
10
  import numpy as np
11
 
12
  from src.display.formatting import make_clickable_model
 
5
  from dataclasses import dataclass
6
 
7
  import dateutil
8
+ # from datetime import datetime
9
+ # from transformers import AutoConfig
10
  import numpy as np
11
 
12
  from src.display.formatting import make_clickable_model