Downloads · 30 days
56
30% of all-time downloads
h0ney-badger/qwen2.5-coder-1.5b-python-distill
qwen2.5-coder-1.5b-python-distill is a text generation model from h0ney-badger. Use it when you need the model to write or continue text. It is set up for gguf. The card lists the license as apache-2.0.
A tiny, Python-focused QLoRA fine-tune of Qwen2.5-Coder-1.5B-Instruct, distilled from a Qwen2.5-Coder-14B-Instruct teacher on locally-generated, execution-verified Python data. Quantized to Q4KM — 941 MB — so it runs…
Downloads · 30 days
56
30% of all-time downloads
All-time downloads
186
Public
Repo size
2 GB
Likes
0
Public
Click a slice to open those files.
.gguf986 MB · 100%
From the Hugging Face model README
A tiny, Python-focused QLoRA fine-tune of Qwen2.5-Coder-1.5B-Instruct, distilled from a Qwen2.5-Coder-14B-Instruct teacher on locally-generated, execution-verified Python data. Quantized to Q4_K_M — 941 MB — so it runs comfortably on CPU on old / low-power hardware (built to run on a 2014 ThinkPad W541, no GPU needed).
TL;DR — 81.5% Python pass@1 in under 1 GB. That's +7.4 points over the stock 1.5B, and it beats a stock 7B at Python while being ~5× smaller — plus it now writes complete, interactive programs, not just bare functions.
Same 54-sample held-out Python eval, same Q4_K_M quant. Base = the exact weights this was fine-tuned from.
| Model | Python pass@1 |
|---|---|
| Qwen2.5-Coder-1.5B-Instruct (base) | 74.1% (40/54) |
| This model | 81.5% (44/54) |
For context, on the same eval the stock 7B scored 77.8% at Python — this 941 MB model edges it out for Python.
pass@1 = the model's code was executed against held-out tests and had to pass. Carries ±1–2 samples of sampling noise.
Teacher (Qwen2.5-Coder-14B) generates Python tasks + solutions + tests → each is executed, only passing samples kept → QLoRA SFT of the 1.5B student (Unsloth, r=16, 3 epochs) → merged 16-bit → GGUF Q4_K_M. Same pipeline as the 7B sibling, Python-only.
Training data mixes two styles (~566 samples): execution-verified functions
and complete, runnable programs from natural requests (calculators, CLIs,
games, file tools — teacher-generated + hand-authored gold, each run-verified). The
complete-program half is what makes it write whole interactive programs (using
input(), menus, etc.) rather than bare functions.
A 1.5B must be run with the chat template applied and low temperature, or
it rambles. Use llama-server (applies the template automatically) or llama-cli -cnv
with --temp 0.2. Do not use plain llama-cli -p "..." (raw completion, temp 0.8) —
that's the usual reason a small local model seems broken.
Execution-based pass@1 on a dedicated eval set disjoint from training (exact + fuzzy dedup). Deliberately not HumanEval/MBPP — the goal was an honest, contamination-controlled comparison against the base, not a leaderboard number.
Q4_K_M GGUF, 941 MB. On CPU (e.g. an old laptop):
# llama.cpp on CPU — no GPU offload
llama-cli -m qwen-coder-1.5b-py-Q4_K_M.gguf -p "Write a Python function to ..."
llama-server -m qwen-coder-1.5b-py-Q4_K_M.gguf -c 4096 # OpenAI-compatible API
# or load the .gguf in LM Studio
A companion to the 7B Python/C distill — see the repo for the reproducible pipeline.