Views
No views yet
Reliable tool-calling for agentic coding — LoRA fine-tune of Qwen3.5-9B v1.1-DPO released — DPO alignment improves code correctness and self-verification. If you downloaded before March 28, 2026, please re-pull to get v1.1-DPO.
| Format | Link | Size |
|---|---|---|
| GGUF Q4_K_M (recommended) | HuggingFace | ~5.5 GB |
| GGUF Q5_K_M | HuggingFace | ~6.5 GB |
| GGUF BF16 | HuggingFace | ~17.9 GB |
| DPO LoRA adapter | HuggingFace | ~700 MB |
tool=edit, error=JSON Parse error: Property name must be a string literal
tool=bash, error=JSON Parse error: Expected '}'| Parameter | Value |
|---|---|
| Base model | Qwen3.5-9B (hybrid GDN architecture) |
| Method | LoRA (r=64, alpha=32) |
| Dataset | CoderForge-Preview filtered_reward1 (50K subset) |
| Sequence length | 4096 |
| Effective batch size | 16 |
| Learning rate | 1e-4 (cosine) |
| Epochs | 1 |
| Hardware | NVIDIA H200 140GB (Vast.ai) |
| Training time | ~10 hours |
| Final loss | ~0.94 |
| Parameter | Value |
|---|---|
| Method | DPO (Direct Preference Optimization) |
| Dataset | AceCode-V2-122K — 4,519 preference pairs |
| Pair generation | 10K problems × 8 samples, keep if ≥1 pass AND ≥1 fail (45% keep rate) |
| Beta | 0.1 |
| Loss type | sigmoid |
| Learning rate | 5e-6 (cosine) |
| Effective batch size | 16 |
| Hardware | NVIDIA H100 80GB (Vast.ai) |
| Training time | ~3.7 hours |
| Final loss | 0.538 |
| Rewards/margins (final) | ~1.0 |
| Rewards/accuracies (final) | ~80% |
q_proj, k_proj, v_proj, o_projin_proj_qkv, in_proj_z, in_proj_b, in_proj_a, out_projgate_proj, up_proj, down_projollama create deltacoder -f Modelfile./llama-server -m DeltaCoder-9B-v1.1-DPO-Q5_K_M.gguf -ngl 999 -c 131072 -ctk f16 -ctv q4_0 -fa 1 --jinja1from transformers import AutoModelForCausalLM, AutoTokenizer
2from peft import PeftModel
3import torch
4
5base = AutoModelForCausalLM.from_pretrained(
6 "Jackrong/Qwen3.5-9B-Claude-4.6-Opus-Reasoning-Distilled-v2",
7 torch_dtype=torch.bfloat16,
8 trust_remote_code=True,
9)
10model = PeftModel.from_pretrained(base, "danielcherubini/Qwen3.5-DeltaCoder-9B")
11tokenizer = AutoTokenizer.from_pretrained("danielcherubini/Qwen3.5-DeltaCoder-9B")| Model | HumanEval | HumanEval+ | Terminal-Bench Easy |
|---|---|---|---|
| Jackrong Qwen3.5-9B-v2 (base) | 53.7% | — | — |
| DeltaCoder-9B v1 (temp=0.6) | 50.6% | 49.4% | 2/4 (50%) |
| DeltaCoder-9B v1.1-DPO (temp=0.6) | TBD | TBD | 2/4 (50%)* |
| Parameter | Value |
|---|---|
| temperature | 0.6 |
| top_k | 20 |
| top_p | 0.95 |
| min_p | 0.0 |
| presence_penalty | 0.0 |
| repeat_penalty | 1.0 |
[!WARNING] Do not use temperature below 0.5 — low temperatures cause deterministic looping in multi-turn agentic use.
| Context Length | KV Cache | VRAM (Q4_K_M) | Generation Speed |
|---|---|---|---|
| 102,400 | f16/q4_0 | ~8.5 GB | ~111 tok/s |
| 131,072 | f16/q4_0 | ~9.1 GB | ~110 tok/s |
[!NOTE] Qwen3.5 is a VLM — Unsloth treats it as a vision model. For text-only DPO training, use standard HuggingFace + PEFT + TRL directly (no Unsloth DPOTrainer).
[!WARNING] Do not useflash_attention_2with sample packing on Qwen3.5 — training loss goes to 0. Useattn_implementation="eager"instead.
in_proj_qkv, in_proj_z, in_proj_b, in_proj_a, out_proj in LoRA target modules or 75% of attention layers are untrainedQwen/Qwen3.5-9B base with vLLM async inference (32 concurrent requests)scripts/
train_unsloth.py # v1 SFT training
train_dpo.py # v1.1 DPO training (HF + PEFT + TRL)
generate_dpo_pairs.py # Async on-policy pair generation
merge_and_export_dpo.py # Two-stage merge + GGUF export