| | from itertools import product
|
| |
|
| | from datasets import Dataset
|
| |
|
| |
|
| | tasks = [
|
| | {
|
| | "task": "Evaluate models {M} on benchmarks {B}",
|
| | "difficulty": "Easy",
|
| | "category": "Evaluation",
|
| | "params": ["M", "B"],
|
| | },
|
| | {
|
| | "task": "Train models {M} on datasets {D} evaluating them on benchmarks {B}",
|
| | "difficulty": "Medium",
|
| | "category": "Training",
|
| | "params": ["M", "D", "B"],
|
| | },
|
| | {
|
| | "task": "Run an ablation for hyperparameter {P} for model {M} on dataset {D}",
|
| | "difficulty": "Hard",
|
| | "category": "Ablation",
|
| | "params": ["P", "M", "D"],
|
| | },
|
| | {
|
| | "task": "Generate completions with model {M} on benchmarks {B} using engine {E}",
|
| | "difficulty": "Medium",
|
| | "category": "Generation",
|
| | "params": ["M", "B", "E"],
|
| | },
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| | {
|
| | "task": "Decontaminate dataset {D} against benchmarks {B}",
|
| | "difficulty": "Hard",
|
| | "category": "Data Processing",
|
| | "params": ["D", "B"],
|
| | },
|
| | {
|
| | "task": "Format dataset {D} for compatibility with framework {F} on task {T}",
|
| | "difficulty": "Easy",
|
| | "category": "Data Formatting",
|
| | "params": ["D", "F", "T"],
|
| | },
|
| | ]
|
| |
|
| |
|
| | values = {
|
| | "M": [
|
| | "Qwen/Qwen3-4B-Instruct-2507",
|
| | "openai/gpt-oss-20b",
|
| | "gpt-4o-mini",
|
| | "deepseek-ai/DeepSeek-R1-Distill-Qwen-1.5B",
|
| | "anthropic's latest model",
|
| | ],
|
| | "B": [
|
| | "Idavidrein/gpqa",
|
| | "HuggingFaceH4/MATH-500",
|
| | "lighteval/SimpleQA",
|
| | "TIGER-Lab/MMLU-Pro",
|
| | ],
|
| | "D": [
|
| | "HuggingFaceH4/multi_turn_if",
|
| | "HuggingFaceH4/ultrachat_200k",
|
| | "HuggingFaceH4/AceReason-1.1-SFT config: math_no_think",
|
| | ],
|
| | "E": [
|
| | "vllm",
|
| | "sglang",
|
| | ],
|
| | "F": [
|
| | "trl",
|
| | "axolotl",
|
| | "verl",
|
| | ],
|
| | "P": [
|
| | "learning_rate",
|
| | "batch_size",
|
| | "num_epochs",
|
| | ],
|
| | "T": [
|
| | "SFT",
|
| | "GRPO",
|
| | ],
|
| | }
|
| |
|
| |
|
| |
|
| |
|
| | task_limits = [
|
| | {"pivot": "B", "instances_per_pivot": 1},
|
| | {"pivot": ["M", "B"], "instances_per_pivot": 3},
|
| | {"pivot": ["P", "D"], "instances_per_pivot": 3},
|
| | {"pivot": "E", "instances_per_pivot": 2},
|
| |
|
| | {"pivot": "D", "instances_per_pivot": 2},
|
| | {"pivot": ["D", "F", "T"], "instances_per_pivot": 2},
|
| | ]
|
| |
|
| |
|
| | def main():
|
| | eval_data = []
|
| |
|
| | for task_idx, task_dict in enumerate(tasks):
|
| | template = task_dict["task"]
|
| | params = task_dict["params"]
|
| | limit_config = task_limits[task_idx]
|
| |
|
| | pivot_params = limit_config["pivot"]
|
| | instances_per_pivot = limit_config["instances_per_pivot"]
|
| |
|
| |
|
| | if isinstance(pivot_params, str):
|
| | pivot_params = [pivot_params]
|
| |
|
| |
|
| | pivot_param_values = [values[p] for p in pivot_params]
|
| | pivot_combinations = product(*pivot_param_values)
|
| |
|
| |
|
| | for pivot_combo in pivot_combinations:
|
| |
|
| | other_params = [p for p in params if p not in pivot_params]
|
| | other_param_values = [values[p] for p in other_params]
|
| | other_combinations = list(product(*other_param_values))
|
| |
|
| |
|
| | limited_combinations = other_combinations[:instances_per_pivot]
|
| |
|
| |
|
| | for combo in limited_combinations:
|
| |
|
| | kwargs = dict(zip(pivot_params, pivot_combo))
|
| | kwargs.update(dict(zip(other_params, combo)))
|
| |
|
| | concrete_task = template.format(**kwargs)
|
| | eval_data.append(
|
| | {
|
| | "task": concrete_task,
|
| | "difficulty": task_dict["difficulty"],
|
| | "category": task_dict["category"],
|
| | }
|
| | )
|
| |
|
| | print(f"Generated {len(eval_data)} instances from {len(tasks)} templates")
|
| |
|
| | dataset = Dataset.from_list(eval_data)
|
| | print(f"\nDataset: {len(dataset)} rows")
|
| | print(f"Sample: {dataset[0]['task']}")
|
| |
|
| | dataset.push_to_hub("akseljoonas/qyestions", private=False)
|
| | print("\n✓ Pushed to akseljoonas/qyestions")
|
| |
|
| |
|
| | if __name__ == "__main__":
|
| | main()
|
| |
|