Skip to content

armgit / Soup

Public Imported from GitHub
0

Fine-tune LLMs from one YAML. Layer streaming trains an 8B model on a 4 GB laptop GPU.

1.2 KB
Raw Blame
  • A dpo or ipo term in a preference_loss_weights blend now also trains when the largest weight is simpo or orpo. Those primaries build trl's CPO and ORPO trainers, which run no frozen reference, so a blend such as {simpo: 0.6, dpo: 0.4} stopped at the first step. The blend now makes the reference itself: the trainer's own forward once more per step, without gradients and with the LoRA adapter switched off, which is the base model the adapter started from. A blend that names neither dpo nor ipo runs no extra forward. With init_strategy: pissa / olora / loftq or relora_steps the adapter-off model is not the starting model, so that combination is refused before the model is loaded, with the reason. The terms are computed on the primary trainer's batch, and the CPO / ORPO batches start with the BOS token where the DPOTrainer's need not, so the same dpo term differs a little between a simpo and a dpo primary; docs/training.md says which reference and which tokens each primary uses. Try: soup train --config soup.yaml with task: preference and training.preference_loss_weights: {simpo: 0.6, dpo: 0.4}. (#1425 by @ybai08 in #1828)