Views
No views yet
intent, urgency, product, sentiment).| Metric | Base + optimized prompt | This adapter |
|---|---|---|
| Target task accuracy | 0.595 | 0.995 |
| General-knowledge regression score | 0.689 | 0.067 |
| JSON format validity | 1.000 | 1.000 |
{"intent": "hoi", "urgency": "trung_binh", ...} instead of
"Nguyễn Du". The model has effectively lost the ability to do anything except emit
this JSON schema. See the linked report §5–6 for the full regression-gate analysis
(verdict: FAILED) and the fix that was not applied here (1–5% general-purpose
replay data mixed into training, per LoRA-fine-tuning best practice).Qwen/Qwen3.5-2Br=16, alpha=32, target modules = all linear layers (text-linear
placement), 16,819,200 trainable params1e-4 (cosine schedule), 2 epochs, 58 optimizer stepsper_device_batch=1 × grad_accum=8)assistant-only (loss computed only on the JSON answer span,
supervised_fraction=0.394 — verified by decoding the supervised span, not
assumed)1from transformers import AutoModelForCausalLM, AutoTokenizer
2from peft import PeftModel
3
4base = AutoModelForCausalLM.from_pretrained("Qwen/Qwen3.5-2B", dtype="bfloat16")
5tok = AutoTokenizer.from_pretrained("Qwen/Qwen3.5-2B")
6model = PeftModel.from_pretrained(base, "TuanPham2308/lab21-qwen3.5-2b-cskh-triage-lora")