LoRA 专题(02):选参:r、target_modules、alpha、lr 与 QLoRA / DoRA / PiSSA 各让模型变成什么
LoRA 02: Choosing r, target_modules, alpha and lr — and What QLoRA, DoRA and PiSSA Each Change
更新 @2026-09-30:实验用 peft 0.21.1、trl 1.14.1、transformers 5.17.0、bitsandbytes 0.50.2、PyTorch 2.14(CPU,8 线程),模型 Qwen2.5-0.5B(base),数据 HuggingFaceH4/no_robots。配套脚本 ai-learning-labs/lora/02_knobs.py,--list 列出全部配置名;正文给出每种配置的数字。
LoraConfig(r=16, lora_alpha=32, target_modules="all-linear", lora_dropout=0.05) 加 learning_rate=2e-4——这一行出现在几乎每...