Spaces:
Running
on
CPU Upgrade
Running
on
CPU Upgrade
Commit
Β·
f21842d
1
Parent(s):
1aa355c
Refactor app.py and utils.py to centralize dataset repository configuration
Browse files
app.py
CHANGED
@@ -1,16 +1,7 @@
|
|
1 |
-
import os
|
2 |
-
import json
|
3 |
-
import numpy as np
|
4 |
-
import pandas as pd
|
5 |
import gradio as gr
|
6 |
-
from huggingface_hub import HfApi, hf_hub_download
|
7 |
-
from pathlib import Path
|
8 |
from utils import submit_gradio_module, load_retrieval_results
|
9 |
|
10 |
|
11 |
-
OWNER = "Navid-AI"
|
12 |
-
DATASET_REPO_ID = f"{OWNER}/requests-dataset"
|
13 |
-
|
14 |
HEADER = """<div style="text-align: center; margin-bottom: 20px;">
|
15 |
<h1>The Arabic RAG Leaderboard</h1>
|
16 |
<p style="font-size: 14px; color: #888;">The only leaderboard you will require for your RAG needs π</p>
|
|
|
|
|
|
|
|
|
|
|
1 |
import gradio as gr
|
|
|
|
|
2 |
from utils import submit_gradio_module, load_retrieval_results
|
3 |
|
4 |
|
|
|
|
|
|
|
5 |
HEADER = """<div style="text-align: center; margin-bottom: 20px;">
|
6 |
<h1>The Arabic RAG Leaderboard</h1>
|
7 |
<p style="font-size: 14px; color: #888;">The only leaderboard you will require for your RAG needs π</p>
|
utils.py
CHANGED
@@ -3,10 +3,13 @@ import pandas as pd
|
|
3 |
import json
|
4 |
import os
|
5 |
from pathlib import Path
|
6 |
-
from huggingface_hub import HfApi
|
7 |
|
8 |
api = HfApi()
|
9 |
|
|
|
|
|
|
|
10 |
def load_retrieval_results():
|
11 |
base_path = Path(__file__).parent
|
12 |
results_dir = base_path / "assets" / "results"
|
|
|
3 |
import json
|
4 |
import os
|
5 |
from pathlib import Path
|
6 |
+
from huggingface_hub import HfApi, hf_hub_download
|
7 |
|
8 |
api = HfApi()
|
9 |
|
10 |
+
OWNER = "Navid-AI"
|
11 |
+
DATASET_REPO_ID = f"{OWNER}/requests-dataset"
|
12 |
+
|
13 |
def load_retrieval_results():
|
14 |
base_path = Path(__file__).parent
|
15 |
results_dir = base_path / "assets" / "results"
|