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
task: simpoon the transformers backend caps the prompt as DPO and ORPO do (#2112 by @dryn85-max in #2116). TRL 0.29.1's CPO tokenizer cuts only the answers, so a long prompt reached the model whole, beyonddata.max_length. After TRL tokenizes, the prompt is now cut todata.max_length // 2tokens, keeping its end, and the answers to the room left, so no sequence exceedsdata.max_length. A prompt longer thandata.max_length // 2tokens is cut even when the whole row would fit; a row whose prompt is at mostdata.max_length // 2tokens and which fits is unchanged.