Spaces:
				
			
			
	
			
			
		Runtime error
		
	
	
	
			
			
	
	
	
	
		
		
		Runtime error
		
	Commit 
							
							Β·
						
						33eb9c4
	
1
								Parent(s):
							
							662df7d
								
bug fix + update new model releases dates
Browse files- release_date_mapping.json +65 -0
- utils.py +8 -0
    	
        release_date_mapping.json
    CHANGED
    
    | @@ -573,5 +573,70 @@ | |
| 573 | 
             
                    "key": "phi-3-mini-4k-instruct-june-2024",
         | 
| 574 | 
             
                    "Model": "Phi-3-Mini-4k-Instruct-June-24",
         | 
| 575 | 
             
                    "Release Date": "2024-06-24"
         | 
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
|  | |
| 576 | 
             
                }
         | 
| 577 | 
             
            ]
         | 
|  | |
| 573 | 
             
                    "key": "phi-3-mini-4k-instruct-june-2024",
         | 
| 574 | 
             
                    "Model": "Phi-3-Mini-4k-Instruct-June-24",
         | 
| 575 | 
             
                    "Release Date": "2024-06-24"
         | 
| 576 | 
            +
                },
         | 
| 577 | 
            +
                {
         | 
| 578 | 
            +
                    "key": "athene-70b-0725",
         | 
| 579 | 
            +
                    "Model": "athene-70b-0725",
         | 
| 580 | 
            +
                    "Release Date": "2024-07-25"
         | 
| 581 | 
            +
                },
         | 
| 582 | 
            +
                {
         | 
| 583 | 
            +
                    "key": "athene-70b-0725",
         | 
| 584 | 
            +
                    "Model": "athene-70b-0725",
         | 
| 585 | 
            +
                    "Release Date": "2024-07-25"
         | 
| 586 | 
            +
                },
         | 
| 587 | 
            +
                {
         | 
| 588 | 
            +
                    "key": "deepseek-coder-v2-0724",
         | 
| 589 | 
            +
                    "Model": "Deepseek-Coder-v2-0724",
         | 
| 590 | 
            +
                    "Release Date": "2024-07-24"
         | 
| 591 | 
            +
                },
         | 
| 592 | 
            +
                {
         | 
| 593 | 
            +
                    "key": "deepseek-v2-api-0628",
         | 
| 594 | 
            +
                    "Model": "Deepseek-v2-API-0628",
         | 
| 595 | 
            +
                    "Release Date": "2024-06-28"
         | 
| 596 | 
            +
                },
         | 
| 597 | 
            +
                {
         | 
| 598 | 
            +
                    "key": "gemini-1.5-pro-exp-0801",
         | 
| 599 | 
            +
                    "Model": "Gemini-1.5-Pro-Exp-0801",
         | 
| 600 | 
            +
                    "Release Date": "2024-08-01"
         | 
| 601 | 
            +
                },
         | 
| 602 | 
            +
                {
         | 
| 603 | 
            +
                    "key": "gemma-2-2b-it",
         | 
| 604 | 
            +
                    "Model": "Gemma-2-2b-it",
         | 
| 605 | 
            +
                    "Release Date": "2024-07-31"
         | 
| 606 | 
            +
                },
         | 
| 607 | 
            +
                {
         | 
| 608 | 
            +
                    "key": "gpt-4o-mini-2024-07-18",
         | 
| 609 | 
            +
                    "Model": "GPT-4o-mini-2024-07-18",
         | 
| 610 | 
            +
                    "Release Date": "2024-07-18"
         | 
| 611 | 
            +
                },
         | 
| 612 | 
            +
                {
         | 
| 613 | 
            +
                    "key": "llama-3.1-405b-instruct",
         | 
| 614 | 
            +
                    "Model": "Meta-Llama-3.1-405b-Instruct",
         | 
| 615 | 
            +
                    "Release Date": "2024-07-23"
         | 
| 616 | 
            +
                },
         | 
| 617 | 
            +
                {
         | 
| 618 | 
            +
                    "key": "llama-3.1-70b-instruct",
         | 
| 619 | 
            +
                    "Model": "Meta-Llama-3.1-70b-Instruct",
         | 
| 620 | 
            +
                    "Release Date": "2024-07-23"
         | 
| 621 | 
            +
                },
         | 
| 622 | 
            +
                {
         | 
| 623 | 
            +
                    "key": "llama-3.1-8b-instruct",
         | 
| 624 | 
            +
                    "Model": "Meta-Llama-3.1-8b-Instruct",
         | 
| 625 | 
            +
                    "Release Date": "2024-07-23"
         | 
| 626 | 
            +
                },
         | 
| 627 | 
            +
                {
         | 
| 628 | 
            +
                    "key": "mistral-large-2407",
         | 
| 629 | 
            +
                    "Model": "Mistral-Large-2407",
         | 
| 630 | 
            +
                    "Release Date": "2024-07-24"
         | 
| 631 | 
            +
                },
         | 
| 632 | 
            +
                {
         | 
| 633 | 
            +
                    "key": "reka-core-20240722",
         | 
| 634 | 
            +
                    "Model": "Reka-Core-20240722",
         | 
| 635 | 
            +
                    "Release Date": "2024-07-22"
         | 
| 636 | 
            +
                },
         | 
| 637 | 
            +
                {
         | 
| 638 | 
            +
                    "key": "reka-flash-20240722",
         | 
| 639 | 
            +
                    "Model": "Reka-Flash-20240722",
         | 
| 640 | 
            +
                    "Release Date": "2024-07-22"
         | 
| 641 | 
             
                }
         | 
| 642 | 
             
            ]
         | 
    	
        utils.py
    CHANGED
    
    | @@ -11,6 +11,8 @@ from huggingface_hub import HfFileSystem, hf_hub_download | |
| 11 | 
             
            KEY_TO_CATEGORY_NAME = {
         | 
| 12 | 
             
                "full": "Overall",
         | 
| 13 | 
             
                "dedup": "De-duplicate Top Redundant Queries (soon to be default)",
         | 
|  | |
|  | |
| 14 | 
             
                "multiturn": "Multi-Turn",
         | 
| 15 | 
             
                "coding": "Coding",
         | 
| 16 | 
             
                "hard_6": "Hard Prompts (Overall)",
         | 
| @@ -34,6 +36,8 @@ KEY_TO_CATEGORY_NAME = { | |
| 34 | 
             
            CAT_NAME_TO_EXPLANATION = {
         | 
| 35 | 
             
                "Overall": "Overall Questions",
         | 
| 36 | 
             
                "De-duplicate Top Redundant Queries (soon to be default)": "De-duplicate top redundant queries (top 0.1%). See details in [blog post](https://lmsys.org/blog/2024-05-17-category-hard/#note-enhancing-quality-through-de-duplication).",
         | 
|  | |
|  | |
| 37 | 
             
                "Multi-Turn": "Multi-Turn Conversation (>= 2 turns)",
         | 
| 38 | 
             
                "Coding": "Coding: whether conversation contains code snippets",
         | 
| 39 | 
             
                "Hard Prompts (Overall)": "Hard Prompts (Overall): details in [blog post](https://lmsys.org/blog/2024-05-17-category-hard/)",
         | 
| @@ -77,6 +81,9 @@ def download_latest_data_from_space( | |
| 77 | 
             
                fs = HfFileSystem()
         | 
| 78 | 
             
                data_file_path = f"spaces/{repo_id}/*.{file_type}"
         | 
| 79 | 
             
                files = fs.glob(data_file_path)
         | 
|  | |
|  | |
|  | |
| 80 | 
             
                latest_file = sorted(files, key=extract_date, reverse=True)[0]
         | 
| 81 |  | 
| 82 | 
             
                latest_filepath_local = hf_hub_download(
         | 
| @@ -84,6 +91,7 @@ def download_latest_data_from_space( | |
| 84 | 
             
                    filename=latest_file.split("/")[-1],
         | 
| 85 | 
             
                    repo_type="space",
         | 
| 86 | 
             
                )
         | 
|  | |
| 87 | 
             
                return latest_filepath_local
         | 
| 88 |  | 
| 89 |  | 
|  | |
| 11 | 
             
            KEY_TO_CATEGORY_NAME = {
         | 
| 12 | 
             
                "full": "Overall",
         | 
| 13 | 
             
                "dedup": "De-duplicate Top Redundant Queries (soon to be default)",
         | 
| 14 | 
            +
                "math": "Math",
         | 
| 15 | 
            +
                "if": "Instruction Following",
         | 
| 16 | 
             
                "multiturn": "Multi-Turn",
         | 
| 17 | 
             
                "coding": "Coding",
         | 
| 18 | 
             
                "hard_6": "Hard Prompts (Overall)",
         | 
|  | |
| 36 | 
             
            CAT_NAME_TO_EXPLANATION = {
         | 
| 37 | 
             
                "Overall": "Overall Questions",
         | 
| 38 | 
             
                "De-duplicate Top Redundant Queries (soon to be default)": "De-duplicate top redundant queries (top 0.1%). See details in [blog post](https://lmsys.org/blog/2024-05-17-category-hard/#note-enhancing-quality-through-de-duplication).",
         | 
| 39 | 
            +
                "Math": "Math",
         | 
| 40 | 
            +
                "Instruction Following": "Instruction Following",
         | 
| 41 | 
             
                "Multi-Turn": "Multi-Turn Conversation (>= 2 turns)",
         | 
| 42 | 
             
                "Coding": "Coding: whether conversation contains code snippets",
         | 
| 43 | 
             
                "Hard Prompts (Overall)": "Hard Prompts (Overall): details in [blog post](https://lmsys.org/blog/2024-05-17-category-hard/)",
         | 
|  | |
| 81 | 
             
                fs = HfFileSystem()
         | 
| 82 | 
             
                data_file_path = f"spaces/{repo_id}/*.{file_type}"
         | 
| 83 | 
             
                files = fs.glob(data_file_path)
         | 
| 84 | 
            +
                files = [
         | 
| 85 | 
            +
                    file for file in files if "leaderboard_table" in file or "elo_results" in file
         | 
| 86 | 
            +
                ]
         | 
| 87 | 
             
                latest_file = sorted(files, key=extract_date, reverse=True)[0]
         | 
| 88 |  | 
| 89 | 
             
                latest_filepath_local = hf_hub_download(
         | 
|  | |
| 91 | 
             
                    filename=latest_file.split("/")[-1],
         | 
| 92 | 
             
                    repo_type="space",
         | 
| 93 | 
             
                )
         | 
| 94 | 
            +
                print(latest_file.split("/")[-1])
         | 
| 95 | 
             
                return latest_filepath_local
         | 
| 96 |  | 
| 97 |  | 
