in llm_perf/update_llm_perf_leaderboard.py [0:0]
def update_llm_df():
"""
Scrape the open-llm-leaderboard and update the leaderboard dataframe
"""
scrapping_script = """
git clone https://github.com/Weyaxi/scrape-open-llm-leaderboard.git
pip install -r scrape-open-llm-leaderboard/requirements.txt -q
python scrape-open-llm-leaderboard/main.py
rm -rf scrape-open-llm-leaderboard
"""
subprocess.run(scrapping_script, shell=True)
create_repo(repo_id=MAIN_REPO_ID, repo_type=REPO_TYPE, exist_ok=True, private=False)
upload_file(
repo_id=MAIN_REPO_ID,
repo_type=REPO_TYPE,
path_in_repo=LLM_DF,
path_or_fileobj="open-llm-leaderboard.csv",
)