passdrill
AI & LLM Engineering · Fine-tuning & Model Customisation · Card 002/010 medium

A researcher needs to fine-tune a 65-billion-parameter language model on a single GPU with 48GB of memory, far too little to hold the model in standard 16-bit precision alongside optimizer states for full fine-tuning. They use QLoRA (Dettmers et al.) to make this feasible. Which combination of techniques does QLoRA actually use to achieve this while matching full 16-bit fine-tuning performance?

  1. It keeps the entire base model and its trainable adapters in 4-bit precision throughout both forward and backward passes, including all gradient computation
  2. It permanently prunes the smallest-magnitude weights in the base model to zero until the model fits in the available memory, then fine-tunes the remaining nonzero weights
  3. It distills the full 65-billion-parameter model into a much smaller student model trained from scratch on the target task, then fine-tunes only that smaller student
  4. It quantizes the frozen base model's weights to a 4-bit NormalFloat data type for storage while computing in a higher-precision type, trains LoRA adapters on top of those frozen quantized weights, and adds double quantization of the quantization constants plus paged optimizers to absorb memory spikes
Next card → Shuffle