Measured results (Spider dev, n=1034)
From scripts/eval.py on the overnight lean recipe (configs/lean_full_*.yaml in the GitHub repo):
Table with columns: Checkpoint, Exec accuracy, Exec success, Mean reward, Validity| Checkpoint | Exec accuracy | Exec success | Mean reward | Validity |
|---|
Base (Qwen2.5-3B-Instruct) | 60.83% | 88.78% | 0.770 | 99.81% |
| SFT | 61.70% | 81.33% | 0.752 | 99.71% |
| GRPO (this adapter) | 62.67% | 82.40% | 0.761 | 100% |
GRPO +1.8 pp exec accuracy vs base (+1.0 pp vs SFT). Base still leads exec success / mean reward on this harness.
Training recipe
Table with columns: Stage, Setting| Stage | Setting |
|---|
| Base | Qwen/Qwen2.5-3B-Instruct + QLoRA (r=16, α=32, 4-bit) |
| SFT | Full Spider train (8659 rows), 1 epoch, batch 1 / accum 16 / seq 1024 / grad checkpoint |
| GRPO | 3000 prompts × 4 generations, batch 4 / accum 4, completion 160, prompt 896 |
Links
How to use
from peft import PeftModelfrom transformers import AutoModelForCausalLM, AutoTokenizer base = "Qwen/Qwen2.5-3B-Instruct"tok = AutoTokenizer.from_pretrained(base, trust_remote_code=True)model = AutoModelForCausalLM.from_pretrained(base, device_map="auto", trust_remote_code=True)model = PeftModel.from_pretrained(model, "abhisheksutaria/qwen2.5-3b-grpo-text-to-sql")
Or set Space / app env: MODEL_ID=Qwen/Qwen2.5-3B-Instruct and ADAPTER_ID=abhisheksutaria/qwen2.5-3b-grpo-text-to-sql.
Intended use
Research / demo text-to-SQL on Spider-style schemas. Not a production database agent; always validate generated SQL before execution on real data.