Qdex-1.5B
Taught to answer when asked
A 1.5B-parameter coding model, instruction-tuned with QLoRA to follow coding requests — small enough to run locally on a 16GB laptop with no GPU. Fine-tuning lifted instruction-mode HumanEval from 1.2% to 42.1% — a ~35× jump.
// tl;dr — the headline result
Fine-tuning took this model from 1.2% to 42.1% on HumanEval (pass@1) in instruction-following mode. In doing so it matched and slightly edged the base model’s raw coding ability (42.1% vs the base model’s 40.2% raw-completion score) — it learned to follow instructions and kept all of its coding skill, while making that ability actually usable through natural instructions. The fine-tune didn’t teach the model new programming knowledge — it taught it to answer when asked.
// what it is
The base model already knew how to code. It just couldn’t answer.
Qdex-1.5B is an instruction-tuned coding assistant built on Alibaba’s Qwen2.5-Coder-1.5B — the pre-trained baseversion (Apache-2.0). That base “knew” a lot of code, but only knew how to continue text; it couldn’t reliably respond to “write a function that…”.
I instruction-tuned it so it behaves like a proper coding assistant, then exported it to GGUF so it runs on an ordinary laptop — no GPU — via Ollama or llama.cpp.
same model · two ways of asking
// raw completion — “continue this”
def is_palindrome(s):
→works — 40.2%
// instruction — “write a function that…”
base: ✗ rambles · 1.2%
Qdex: ✓ answers · 42.1%
The ability was always there. The fine-tune unlocked the door to it.
Before & after — the honest numbers
The base model was measured two ways on purpose — raw completion and instruction — so the before/after is a fair, apples-to-apples comparison. Greedy decoding, one sample per problem. An honest, reproducible measurement, not a leaderboard-tuned number.
HumanEval pass@1
latent coding ability — matches the published paper
couldn't answer when actually asked
matched and slightly edged the base model's raw ability, now usable through instructions
The three measurements
Qwen2.5-Coder-1.5B (base)
raw completion
40.2%66/164
Qwen2.5-Coder-1.5B (base)
instruction
1.2%2/164
Qdex-1.5B (this model)
instruction
42.1%69/164
The base model could code (40.2% in completion mode — which also matches the published paper, confirming the harness is sound), but was nearly useless when actually asked (1.2%). After fine-tuning, Qdex answers coding requests at 42.1%— matching, and slightly edging, the model’s full latent ability, now reachable through instructions.
How it was built
QLoRA — Quantized Low-Rank Adaptation. Load the base model in 4-bit to shrink its memory ~4×, freeze all of it, and train only tiny adapter matrices on top. Cheap, fast, and it fits on a single free GPU.
Q — 4-bit quantization
The base model is loaded in 4-bit, cutting its memory footprint ~4× so it fits on a small, free GPU.
LoRA — adapters
The base is frozen; only low-rank adapter matrices train. That’s what makes the fine-tune cheap and fast.
18.5M of 1.56B params
The entire base model is frozen. Only tiny low-rank adapter matrices are trained — which is what makes the fine-tune cheap, fast and runnable on a single free GPU.
The pipeline
- 1Benchmark the base model (both modes)
- 2Instruction-tune with QLoRA
- 3Merge the adapter into the base
- 4Benchmark the fine-tuned model
- 5Export to GGUF for local use
Training loss · trajectory
Tooling: Unsloth (fast single-GPU QLoRA) · Hugging Face TRL (supervised fine-tuning) · llama.cpp (GGUF export).
Training details
Run it locally
Download merged.Q4_K_M.gguf(~1 GB — the 4-bit build recommended for a 16GB laptop; there’s also a slightly higher-quality merged.Q5_K_M.gguf, ~1.2 GB). Create a Modelfile, then run.
# Modelfile$ FROM ./merged.Q4_K_M.gguf# Qwen ChatML template (what it was trained on)$ TEMPLATE """{{ if .System }}<|im_start|>system$ {{ .System }}<|im_end|>$ {{ end }}<|im_start|>user$ {{ .Prompt }}<|im_end|>$ <|im_start|>assistant$ """$ PARAMETER stop "<|im_end|>"$ SYSTEM "You are a helpful coding assistant."# build the model from the Modelfile$ ollama create qdex-1.5b -f Modelfile# ask it something$ ollama run qdex-1.5b \$ "Write a Python function that checks$ if a string is a palindrome."The first two runs were lost
Training ran on a free, time-limited cloud GPU — and the first two runs were lost. Each time, training actually finished, but the session ended (a power cut at home) before the model was saved, and the platform’s default “No Persistence” setting wiped the working directory. So I rebuilt the pipeline to assume the session could die at any moment.
Checkpoint every 200 steps
A dropped session loses minutes, not hours.
Persistence: Files only
Saved files survive a session ending.
One-command resume
Restart from the latest checkpoint instantly.
Immediate off-platform backup
Push to Hugging Face the moment training finishes.
Stated honestly
Limitations
It's a small model
Genuinely useful on focused, well-specified coding tasks — but not a frontier model. It won't replace GPT/Claude on complex, multi-step problems.
Single-benchmark measurement
The reported score is HumanEval only, greedy decoding, one sample per problem. An honest, reproducible number — not a leaderboard-tuned one.
What’s next — Phase 2
WIP- 01
v2 — a data experiment
Retrain with an added, decontaminated slice of NVIDIA's OpenCodeInstruct (solutions ship with test cases + quality scores), then re-run the same HumanEval benchmark. A controlled, data-driven comparison — not guesswork.
- 02
Project 3 — the agent
Qdex-1.5B is the engine for a local CLI coding agent that runs entirely on a 16GB no-GPU laptop via Ollama. This model was built specifically to make that agent possible.
open weights · Apache-2.0
Small model. Runs on your laptop.
Download the ~1 GB GGUF, point Ollama at it, and ask your first coding question in under a minute — no GPU required. Weights and model card are open on Hugging Face.
→
42.1%
Qdex-1.5B · QLoRA fine-tune of Qwen2.5-Coder-1.5B · Apache-2.0 · built by Suman Debnath