wheattoast11 commited on
Commit
322750b
·
verified ·
1 Parent(s): 027b87b

Upload eval_lfm_finetuned.py with huggingface_hub

Browse files
Files changed (1) hide show
  1. eval_lfm_finetuned.py +29 -0
eval_lfm_finetuned.py ADDED
@@ -0,0 +1,29 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # /// script
2
+ # requires-python = ">=3.10"
3
+ # dependencies = [
4
+ # "lighteval[accelerate]>=0.6.0",
5
+ # "torch>=2.0.0",
6
+ # "transformers>=4.40.0",
7
+ # "accelerate>=0.30.0",
8
+ # "peft>=0.7.0",
9
+ # ]
10
+ # ///
11
+
12
+ """Evaluate fine-tuned wheattoast11/agent-zero-lfm-1.2b-v1 on standard benchmarks."""
13
+
14
+ import subprocess
15
+ import sys
16
+
17
+ tasks = "leaderboard|mmlu|5,leaderboard|hellaswag|0,leaderboard|arc_challenge|25"
18
+
19
+ # PEFT adapter model — lighteval loads base + adapter automatically
20
+ cmd = [
21
+ sys.executable, "-m", "lighteval", "accelerate",
22
+ "--model_args", "pretrained=wheattoast11/agent-zero-lfm-1.2b-v1,trust_remote_code=True",
23
+ "--tasks", tasks,
24
+ "--output_dir", "./eval_results_finetuned",
25
+ ]
26
+
27
+ print(f"Running: {' '.join(cmd)}")
28
+ result = subprocess.run(cmd, capture_output=False)
29
+ sys.exit(result.returncode)