Fine-tune LLMs from one YAML. Layer streaming trains an 8B model on a 4 GB laptop GPU.
Python cliconsumer-gpudpofine-tuningggufhuggingfacellmllmopslocal-ailocal-llmloralow-vrammachine-learningollamapeftpythonpytorchqlorasfttransformers
- PRM and RAFT divide each accumulated micro-batch mean by
gradient_accumulation_steps(#1444 by @Momoyeyu in #1771). Both trainers return a per-micro-batch mean and cannot honour HF's label-countnum_items_in_batch; they now decline loss kwargs soTrainer.training_stepapplies its standard1 / gradient_accumulation_stepsnormalisation. Loggedloss,train_lossandgrad_normmatch agradient_accumulation_steps: 1run instead of reading G times too large, andmax_grad_normclips the gradient for the stated loss. RAFT'sloss_weightsweighted mean, including citation boosts, is unchanged.