55 cards · AI & LLM Engineering · answer each one, then read the explanation. Your score tallies below. Looking for GRPO vs PPO: a worked example comparing the advantage calculation? Read the explainer.
0 / 55 answered · 0 correct
Link copied — send it to a friend!
AI & LLM Engineering · Fine-tuning & Model Customisation · Card 001/055easy
A team wants to adapt a large pretrained language model to a new domain without updating billions of parameters or storing a full second copy of the model's weights. They choose LoRA (Low-Rank Adaptation) to do this. Under Hu et al.'s original LoRA method, how does the technique actually reduce the number of trainable parameters during fine-tuning?
AIt fine-tunes every parameter in the pretrained model as usual, but uses a much smaller learning rate so the resulting weight changes stay numerically small enough to store efficiently
BIt freezes all of the pretrained weight matrices and, for selected layers, injects a pair of much smaller trainable matrices whose low-rank product approximates the update those weights would otherwise need, so only that pair is trained
CIt deletes the attention layers of the pretrained model and replaces them with a smaller, randomly initialized transformer block that is trained from scratch on the new domain data
DIt converts the entire pretrained model to 8-bit integer weights and performs ordinary full-parameter backpropagation directly on those compressed integer weights
Correct answer: .
LoRA leaves the pretrained weight matrices frozen and, for the layers it targets, adds a new pair of much smaller matrices -- one that projects down to a low intermediate rank and one that projects back up -- whose product forms a low-rank approximation of whatever weight update the task would otherwise require; only the two small matrices are trained, which is why the trainable parameter count drops so sharply while the frozen base weights carry over unchanged. The option describing an ordinary full fine-tune with a smaller learning rate is wrong because a smaller learning rate does not shrink the number of parameters being updated, only the size of each update, so it does nothing to reduce the underlying memory and compute cost. The option describing deleting and retraining the attention layers from scratch is wrong because LoRA never removes or replaces any pretrained component; it augments the existing frozen weights alongside a small addition rather than discarding learned structure. The option describing full-parameter backpropagation on 8-bit integer weights is wrong because that describes a form of quantized full fine-tuning, not LoRA's low-rank decomposition, and still requires updating every original parameter rather than a small injected pair.
Source: Hu et al., 'LoRA: Low-Rank Adaptation of Large Language Models' (arXiv:2106.09685, 2021)
AI & LLM Engineering · Fine-tuning & Model Customisation · Card 002/055medium
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?
AIt keeps the entire base model and its trainable adapters in 4-bit precision throughout both forward and backward passes, including all gradient computation
BIt 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
CIt 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
DIt 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
Correct answer: .
QLoRA's actual recipe is to store the frozen base model's weights in a 4-bit NormalFloat (NF4) format -- an information-theoretically tuned datatype for normally distributed weights -- while dequantizing on the fly to a higher-precision compute type for the actual forward and backward math, then training ordinary LoRA adapters on top of those frozen quantized weights; it further saves memory by quantizing the quantization constants themselves (double quantization) and uses paged optimizers built on unified GPU memory to absorb the memory spikes that occur when processing long sequences. The option describing full 4-bit computation throughout both passes is wrong because QLoRA's 4-bit format is used only for storing the frozen base weights, not for the arithmetic itself, which is why it can match 16-bit fine-tuning quality. The option describing permanently zeroing small-magnitude weights describes a pruning technique, not quantization, and QLoRA does not delete any of the base model's weights. The option describing training a smaller distilled student from scratch describes knowledge distillation, an entirely different technique that discards the original model's exact parameters rather than adapting them.
AI & LLM Engineering · Fine-tuning & Model Customisation · Card 003/055medium
A team wants to align a supervised-fine-tuned language model to human preference data (pairs of a preferred and a dispreferred response to the same prompt) without the engineering overhead of training a separate reward model and then running an online reinforcement-learning loop like PPO against it. They adopt Direct Preference Optimization (DPO). What does DPO actually do differently from that standard RLHF pipeline?
AIt uses the closed-form relationship between an optimal KL-regularized policy and its implied reward under the Bradley-Terry preference model to rewrite the reward directly in terms of the policy itself, so the policy can be trained straight from the preference pairs with a single supervised-style loss, with no separate reward model and no online RL sampling loop
BIt still trains a full separate reward model on the same preference pairs exactly as standard RLHF does, but then applies that reward model's scores using a closed-form policy update instead of running PPO
CIt discards the human preference-pair data entirely and instead generates all of its training signal by having the model critique its own sampled outputs against a written set of principles
DIt keeps the standard RLHF pipeline completely intact, including the separate reward model and the full PPO optimization loop, and only changes the architecture of the reward model from a scalar head to a pairwise classifier
Correct answer: .
DPO's key mathematical move is to observe that, under the Bradley-Terry model of preferences, the reward implied by the optimal KL-regularized policy can be expressed purely in terms of that policy's own probabilities relative to a reference model; substituting this expression back into the standard preference loss produces a single supervised classification-style loss on the preference pairs themselves, which means the policy is trained directly, with no separate reward model ever fit and no online rollout-and-update RL loop like PPO required at all. The option describing still fitting a full reward model and then applying a closed-form update is wrong because DPO's entire point is to avoid fitting any separate reward model; the reward is never estimated as its own object. The option describing discarding human preference pairs in favor of self-critique against written principles describes a Constitutional-AI-style approach, not DPO, which is built specifically to consume labeled preference pairs. The option describing keeping the full RLHF pipeline intact and only swapping the reward model's architecture is wrong because it retains exactly the separate-reward-model-plus-RL-loop structure that DPO was designed to eliminate.
Source: Rafailov, Sharma, Mitchell, Ermon, Manning & Finn, 'Direct Preference Optimization: Your Language Model is Secretly a Reward Model' (arXiv:2305.18290, 2023)
AI & LLM Engineering · Fine-tuning & Model Customisation · Card 004/055easy
A general-purpose language model that previously solved multi-step arithmetic and logic problems reliably is fine-tuned exclusively on a narrow customer-support ticket dataset for several epochs. Afterward, the model handles support tickets well but its arithmetic and logic performance has dropped sharply, even though none of the fine-tuning data was arithmetic-related. What phenomenon does this describe, and what tends to make it worse?
AThis is overfitting to noise in the customer-support dataset, meaning the model has memorized incorrect labels in that specific dataset; it has nothing to do with the model's previously learned capabilities, which fine-tuning cannot affect
BThis is a tokenizer mismatch, meaning the fine-tuning process silently changed the model's vocabulary so that arithmetic expressions are now encoded into different tokens than during pretraining
CThis is catastrophic forgetting: fine-tuning updates the model's weights to optimize performance on the new, narrow task distribution, and in doing so can overwrite representations the model relied on for previously learned capabilities; this effect tends to become more pronounced the further the fine-tuning data diverges from the pretraining distribution and can worsen with more fine-tuning steps or a higher learning rate
DThis is a known evaluation artifact where the arithmetic benchmark itself becomes unreliable after any fine-tuning run, regardless of what the fine-tuning data contained, so the drop is not a real change in the model's underlying ability
Correct answer: .
Catastrophic forgetting occurs because gradient updates during fine-tuning reshape the same shared weights the model uses for every capability; optimizing those weights hard toward a new, narrow task distribution can overwrite or distort the representations the model was previously relying on for unrelated skills like arithmetic, even though no arithmetic examples appeared in the new training data. This effect is documented to become more severe as the fine-tuning distribution diverges further from the original pretraining distribution, and can be worsened by training for more steps or with a higher learning rate, both of which push the weights further from their pretrained configuration. The option attributing this to memorized label noise is wrong because forgetting is a structural side effect of weight updates, not a symptom of bad labels in the fine-tuning set. The option attributing this to a tokenizer mismatch is wrong because fine-tuning as described does not alter the model's vocabulary or tokenization scheme. The option calling it a benchmark artifact is wrong because the described capability loss is a real, well-studied consequence of how fine-tuning updates shared parameters, not a measurement error.
Source: Luo et al., 'An Empirical Study of Catastrophic Forgetting in Large Language Models During Continual Fine-tuning' (arXiv:2308.08747, 2023)
AI & LLM Engineering · Fine-tuning & Model Customisation · Card 005/055easy
Researchers take a large pretrained language model and fine-tune it on a diverse collection of more than 60 different NLP tasks, each phrased as a natural-language instruction, then evaluate it on entirely new tasks it never saw during this fine-tuning, with zero examples given at test time. What did Wei et al.'s FLAN study find about this kind of instruction tuning?
AInstruction tuning only improved performance when the model was still given several worked examples of the new task at test time; with zero examples given, it performed no better than the original untuned model
BInstruction tuning substantially improved zero-shot performance on the held-out, unseen tasks, in some cases surpassing a much larger model's zero-shot performance and even beating that larger model's few-shot performance on several benchmarks; the gains depended on tuning across a large number of diverse task types, not just scaling up the amount of data for a single task
CInstruction tuning had no measurable effect on unseen tasks at all, and only helped on the exact same 60-plus tasks it was fine-tuned on, meaning the benefit was pure memorization rather than any generalization
DInstruction tuning worked only because the model's parameter count was increased at fine-tuning time; the improvement disappeared entirely once the study controlled for holding the model's size fixed
Correct answer: .
FLAN fine-tuned a 137-billion-parameter pretrained model on over 60 NLP tasks verbalized as natural-language instructions and then tested it, with no examples given, on tasks held out from that tuning set entirely; the tuned model's zero-shot performance improved substantially, surpassing a much larger untuned model's zero-shot results on most evaluated tasks and even beating that larger model's few-shot performance on several benchmarks, with ablations showing the number of distinct task types used in tuning -- not just raw data volume -- was central to the gain. The option claiming the benefit required examples at test time is wrong because the whole point of the finding is that the gains showed up under a strictly zero-shot evaluation. The option claiming the model only improved on the exact tasks it was tuned on is wrong because the evaluated tasks were specifically held out and unseen during tuning. The option attributing the gain purely to increased parameter count is wrong because the ablations isolate task diversity, not model scale, as the key driver.
Source: Wei et al., 'Finetuned Language Models Are Zero-Shot Learners' (arXiv:2109.01652, 2021)
AI & LLM Engineering · Fine-tuning & Model Customisation · Card 006/055hard
Both bottleneck adapter modules (Houlsby et al.) and LoRA are parameter-efficient fine-tuning methods that add a small number of new trainable parameters to a frozen pretrained model, but they differ in how those new parameters interact with the model's forward pass at inference time. Which statement correctly distinguishes them on this specific point?
ABottleneck adapters add their new parameters as a parallel low-rank update to existing weight matrices that can be merged back into those weights after training, while LoRA inserts new down-projection and up-projection feed-forward layers with a nonlinearity directly into the forward pass
BBoth methods add their new parameters in mathematically identical ways, differing only in what random distribution is used to initialize the new weights before training begins
CBoth methods modify the exact same weight matrices inside the attention mechanism in an identical fashion, differing only in the name each paper's authors chose to give the technique
DBottleneck adapters insert new down-projection and up-projection feed-forward layers with a nonlinearity directly into the forward pass, adding extra sequential computation and inference latency, while LoRA's trainable matrices form a parallel low-rank update to an existing weight matrix that can be merged back into that weight after training, adding no extra inference latency
Correct answer: .
Houlsby et al.'s bottleneck adapters are new modules -- a down-projection, a nonlinearity, and an up-projection -- spliced directly into the transformer's forward pass, so every inference call must sequentially compute through that extra module, adding a small but real amount of latency and depth that cannot be removed without retraining. LoRA instead represents its trainable low-rank matrices as an additive update running in parallel to an existing weight matrix rather than as a new sequential layer, and because the update and the original weight are simply added together, the low-rank product can be folded back into the original weight matrix once training is finished, leaving a model that runs at the original architecture's inference speed with no separate module left in the forward path. The option reversing which method merges and which inserts a sequential layer states the opposite of both papers' actual designs. The option claiming the two methods are mathematically identical aside from initialization ignores that one changes the network's computational graph with a new sequential module and the other only changes an existing weight matrix's value. The option claiming both modify the same attention weight matrices identically ignores that adapters are typically inserted as standalone modules after the attention and feed-forward sublayers rather than modifying attention's own weight matrices at all.
Source: Houlsby et al., 'Parameter-Efficient Transfer Learning for NLP' (arXiv:1902.00751, 2019); Hu et al., 'LoRA: Low-Rank Adaptation of Large Language Models' (arXiv:2106.09685, 2021)
AI & LLM Engineering · Fine-tuning & Model Customisation · Card 007/055easy
Anthropic developed a technique for training a model to be more harmless that does not depend on humans labeling which of two harmful responses is worse, since asking human labelers to compare harmful outputs to each other raises its own problems. Instead, the model is trained against a written list of principles (a 'constitution'). How does Bai et al.'s Constitutional AI method actually use that constitution across its two training phases?
AIn a first, supervised phase, the model critiques and revises its own sampled responses against the constitution's principles and is fine-tuned on the revised outputs; in a second, reinforcement-learning phase, the model itself judges which of two sampled responses better satisfies the constitution to build an AI-generated preference dataset, which trains a preference model used as the reward signal
BThe model is fine-tuned once, in a single supervised phase, purely on human-labeled comparisons between harmful responses, and the written constitution is used only as documentation describing the labeling instructions given to the human annotators
CThe constitution is applied only as a static output filter at inference time, blocking any response that matches a principle in the list, with no fine-tuning of the underlying model's weights involved at any stage
DThe constitution's principles are converted into a fixed set of rules and injected directly into the model's weights through a rule-based, gradient-free editing procedure, bypassing both supervised fine-tuning and reinforcement learning entirely
Correct answer: .
Constitutional AI runs in two stages: a supervised-learning stage where the model generates a response, then critiques and revises that response against a written set of principles, and is fine-tuned directly on those self-revised outputs; followed by a reinforcement-learning stage where the model -- rather than a human -- compares pairs of sampled responses against the same constitution to build a dataset of AI-generated preference judgments, which is used to train a preference model that then supplies the reward signal for reinforcement learning, a process the paper calls reinforcement learning from AI feedback (RLAIF). The option describing a single supervised phase trained purely on human-labeled harmful-response comparisons is wrong because it omits the entire point of the method, which is to replace human labeling of harmful comparisons with the model's own judgments. The option describing a static inference-time filter is wrong because both phases involve actually updating the model's weights through training, not filtering outputs after the fact. The option describing a gradient-free rule-injection procedure is wrong because both phases described in the paper use ordinary gradient-based supervised fine-tuning and reinforcement learning, not direct weight editing.
Source: Bai et al., 'Constitutional AI: Harmlessness from AI Feedback' (arXiv:2212.08073, 2022)
AI & LLM Engineering · Fine-tuning & Model Customisation · Card 008/055medium
Gathering large volumes of high-quality human preference labels for RLHF is expensive, so Lee et al. studied replacing the human-labeled preference data used to train a reward model with preference labels generated by an off-the-shelf large language model instead (RLAIF), then compared the resulting policies across summarization and dialogue tasks using human evaluators. What did the study actually find?
ARLAIF only matched human-evaluated RLHF performance when the LLM generating the preference labels was substantially larger and more capable than the policy model being trained, and performed far worse whenever the labeler was the same size as the policy
BRLAIF consistently and substantially underperformed both RLHF and a plain supervised-fine-tuned baseline across every task tested, showing that AI-generated preference labels cannot substitute for human-labeled ones
CRLAIF achieved performance comparable to RLHF as judged by human evaluators across the tasks tested, including cases where the labeling model was the same size as the policy being trained or even the exact same checkpoint, and RLAIF outperformed the supervised-fine-tuned baseline in these comparisons
DRLAIF eliminated the need for a reward model and the reinforcement-learning optimization step entirely in every configuration tested, since the AI-generated labels were used to edit the policy's weights directly without any RL algorithm
Correct answer: .
Lee et al. found that a reward model trained on preference labels generated by an off-the-shelf LLM, rather than by human annotators, produced policies that human evaluators rated comparably to policies trained with standard human-labeled RLHF across the summarization and dialogue tasks tested, and this held even in the more demanding case where the model generating the labels was the same size as the policy being trained, or the identical checkpoint as the policy's own starting point; RLAIF also beat a supervised-fine-tuned baseline in these comparisons. The option requiring the labeler to be strictly larger and more capable is wrong because the study specifically highlights comparable performance even at equal size or an identical checkpoint. The option claiming RLAIF substantially underperformed both RLHF and the supervised baseline is the opposite of the paper's finding. The option claiming the reward model and the RL step were eliminated entirely in every tested configuration describes a separate variant the paper calls direct-RLAIF, not the core RLAIF setup evaluated in most of the study's main comparisons, which still trains a reward model and runs RL against it, just with AI-generated rather than human-generated preference labels.
Source: Lee et al., 'RLAIF vs. RLHF: Scaling Reinforcement Learning from Human Feedback with AI Feedback' (arXiv:2309.00267, 2023)
AI & LLM Engineering · Fine-tuning & Model Customisation · Card 009/055hard
A team fine-tunes a policy by optimizing it, via reinforcement learning, as hard as possible against a fixed, already-trained proxy reward model rather than against real human judgment. Gao, Schulman & Hilton studied this setup by using a much larger 'gold-standard' reward model to stand in for real human judgment, so they could measure the gap between the two as optimization pressure against the proxy increased. What did they find happens to gold-standard, true-preference performance as optimization against the fixed proxy reward model continues further and further?
AGold-standard performance rises without limit for as long as optimization against the proxy reward model continues, with no observed ceiling or decline in any of the tested configurations
BGold-standard performance initially rises alongside the proxy reward model's score but eventually plateaus and then declines even as the proxy score keeps climbing, an instance of Goodhart's law where the imperfect proxy is increasingly over-exploited; the relationship follows scaling patterns that shift with the reward model's size and with whether optimization is done via reinforcement learning or best-of-n sampling
CThis decline in gold-standard performance was observed only when optimizing via best-of-n sampling and never appeared at all when optimizing via reinforcement learning, showing the two optimization methods behave in completely unrelated ways
DThe paper found that simply increasing the proxy reward model's parameter count to be large enough eliminates the decline in gold-standard performance entirely, regardless of how much further optimization pressure is then applied
Correct answer: .
Gao, Schulman & Hilton's synthetic setup used a large gold-standard reward model as a stand-in for true human judgment while a smaller proxy reward model, trained on the gold model's own labels, supplied the actual optimization signal; as they pushed optimization against that fixed proxy further, the policy's true quality, measured against the gold model, rose initially but then plateaued and eventually fell even while the proxy's own score kept climbing, which is the paper's central demonstration of Goodhart's law: an imperfect proxy stops being a reliable stand-in once it is exploited hard enough, and this pattern's exact shape shifted predictably with the reward model's size and with whether the optimization method was reinforcement learning or best-of-n sampling. The option claiming gold-standard performance rises without any ceiling is wrong because the decline after a peak is exactly what the paper documents and calls overoptimization. The option restricting the effect to best-of-n only is wrong because the paper studied and found the same qualitative overoptimization pattern under RL optimization as well, just following a different functional form. The option claiming a sufficiently large proxy reward model eliminates the decline entirely is wrong because the paper found scale shifts where the decline sets in, not that it disappears.
Source: Gao, Schulman & Hilton, 'Scaling Laws for Reward Model Overoptimization' (arXiv:2210.10760, 2022)
AI & LLM Engineering · Fine-tuning & Model Customisation · Card 010/055easy
DeepSeekMath's training pipeline (Shao et al.) uses a reinforcement-learning algorithm called Group Relative Policy Optimization (GRPO) instead of standard PPO to reduce the memory cost of the RL stage. What specific change does GRPO make to how the advantage used in the policy update is computed, compared to standard PPO?
AGRPO still trains a separate learned value/critic network exactly as PPO does, and its only change from PPO is removing the separate reward model used to score outputs
BGRPO uses a single fixed baseline value, chosen once by hand before training begins and never recomputed, in place of PPO's learned value function for every prompt across the entire training run
CGRPO requires a human-labeled preference judgment for every one of the sampled outputs before it can compute any output's advantage, replacing PPO's learned value function with direct human scoring
DGRPO removes PPO's separate learned value/critic network entirely; for a given prompt it samples a group of outputs from the current policy, uses that group's own average reward as a baseline, and computes each output's advantage as how far its reward deviates from that group's baseline, normalized by the group's reward variability
Correct answer: .
GRPO's defining change from standard PPO is eliminating the separately learned value or critic network that PPO normally trains to estimate a baseline for computing advantages; instead, for each prompt, GRPO samples a whole group of candidate outputs from the current policy, treats that group's own average reward as the baseline, and computes each individual output's advantage as the deviation of its reward from that group average, normalized using the group's own reward standard deviation, which removes the memory and compute cost of maintaining a separate critic model. The option claiming GRPO still trains a critic network and only removes the reward model is backwards; GRPO keeps a reward signal but removes the critic. The option describing a single fixed, hand-chosen baseline is wrong because GRPO's baseline is computed dynamically per prompt from the sampled group's own rewards, not set once in advance. The option requiring a human preference judgment for every sampled output is wrong because GRPO's advantage computation works with whatever reward signal the setup provides (which in DeepSeekMath is often an automatic correctness check), not a per-output human label.
Source: Shao et al., 'DeepSeekMath: Pushing the Limits of Mathematical Reasoning in Open Language Models' (arXiv:2402.03300, 2024)
AI & LLM Engineering · Fine-tuning & Model Customisation · Card 011/055medium
A team wants a parameter-efficient way to condition a frozen pretrained language model using continuous trainable vectors rather than discrete text prompts, and is comparing prefix-tuning (Li & Liang) with prompt tuning (Lester et al.). What is the key architectural difference between the two methods?
APrefix-tuning prepends trainable continuous vectors to the key and value inputs of the self-attention mechanism at every transformer layer, while prompt tuning only prepends trainable vectors at the input embedding layer
BPrompt tuning inserts trainable vectors into the keys and values of every transformer layer's attention, while prefix-tuning is restricted to modifying only the input embedding layer
CBoth methods insert an identical number of trainable vectors at every transformer layer; prefix-tuning differs only in using a larger vector dimensionality
DBoth methods work by inserting trainable vectors only into the final output layer immediately before the softmax, differing solely in how many vectors are used
Correct answer: .
Prefix-tuning learns a continuous vector, prepended to the keys and values of the self-attention computation, at every transformer layer, so subsequent tokens attend to these vectors as if they were additional 'virtual tokens' at each layer of the network; prompt tuning, described by its own authors as a simplification of prefix-tuning, instead learns vectors only at the input embedding layer and lets the frozen transformer stack propagate their influence forward from there. The option describing prompt tuning as reaching into every layer's attention and prefix-tuning as embedding-only is wrong because it swaps which method does which -- it is prefix-tuning, not prompt tuning, that touches every layer. The option describing both methods as inserting an identical number of vectors at every layer is wrong because prompt tuning's defining simplification is confining its trainable vectors to the embedding layer alone, not matching prefix-tuning's per-layer insertion. The option describing insertion only at the final output layer before the softmax is wrong because neither method works this way; both condition the model's processing from near the start of the network rather than only adjusting its final logits.
Source: Li & Liang, 'Prefix-Tuning: Optimizing Continuous Prompts for Generation' (arXiv:2101.00190, 2021); Lester, Al-Rfou & Constant, 'The Power of Scale for Parameter-Efficient Prompt Tuning' (arXiv:2104.08691, 2021)
AI & LLM Engineering · Fine-tuning & Model Customisation · Card 012/055medium
A team fine-tunes a large language model with LoRA at a fixed low rank and finds it still falls short of full fine-tuning's performance on a demanding reasoning benchmark. They switch to DoRA (Weight-Decomposed Low-Rank Adaptation, Liu et al.) at the same rank and see the gap close further. What does DoRA actually change compared to plain LoRA?
ADoRA automatically increases the LoRA rank partway through training whenever the loss plateaus, rather than keeping the rank fixed
BDoRA quantizes the frozen pretrained weights to 4-bit precision before applying the low-rank update, freeing memory for a higher rank
CDoRA decomposes each pretrained weight matrix into a magnitude component and a directional component, applies LoRA's low-rank update only to the directional component, and trains the magnitude component separately, more closely resembling how full fine-tuning updates both magnitude and direction together
DDoRA replaces LoRA's pair of low-rank matrices with a single full-rank matrix applied only to the value projection
Correct answer: .
DoRA decomposes each target pretrained weight matrix into a magnitude vector and a directional matrix, then applies a LoRA-style low-rank update only to the direction while the magnitude is fine-tuned as its own separate, small set of parameters; because full fine-tuning is free to adjust both magnitude and direction independently while plain LoRA's single low-rank update conflates the two, this decomposition lets DoRA's learning pattern resemble full fine-tuning's more closely at the same parameter budget, without adding any inference-time latency once the adapter is merged back into the base weights. The option describing an automatically growing rank is wrong because DoRA does not change the rank dynamically during training; its rank is fixed like LoRA's, and the improvement comes from the magnitude/direction decomposition, not from using more rank. The option describing 4-bit quantization of the frozen weights is wrong because that combination of quantization with low-rank adaptation describes QLoRA, a different, memory-focused technique, not DoRA's magnitude-direction decomposition. The option describing a single full-rank matrix applied only to the value projection is wrong because DoRA still uses LoRA's low-rank matrix pair; it does not replace them with a full-rank matrix, and it is not restricted to only the value projection.
Source: Liu et al., 'DoRA: Weight-Decomposed Low-Rank Adaptation' (arXiv:2402.09353, ICML 2024)
AI & LLM Engineering · Fine-tuning & Model Customisation · Card 013/055hard
A team notices that fine-tuning their model exclusively on a new, narrow dataset degrades its performance on tasks it previously handled well -- catastrophic forgetting. They compare two mitigation strategies: mixing a sample of the original task's data into the new fine-tuning batches (rehearsal/replay), and Elastic Weight Consolidation (EWC, Kirkpatrick et al.). How do these two strategies actually differ in mechanism?
AEWC works by re-exposing the model to a sample of the original task's data during the new training run, while rehearsal instead adds a Fisher-information-weighted penalty term to the loss
BRehearsal re-exposes the model to a sample of the original task's data during the new training run so the ordinary loss keeps rewarding good performance on it, while EWC does not replay any old data and instead adds a quadratic penalty term -- weighted by each parameter's estimated Fisher information, i.e. its importance to the original task -- that discourages large changes to the parameters that mattered most for that task
CBoth strategies are mathematically identical; they differ only in which optimizer implementation is used to apply the resulting gradient updates
DRehearsal and EWC both require discarding the new fine-tuning dataset entirely and training only on the original task's data
Correct answer: .
Rehearsal mitigates forgetting empirically, by literally mixing a sample of the original task's examples back into the fine-tuning batches so the ordinary training loss continues to reward good performance on that earlier task alongside the new one; EWC instead mitigates forgetting analytically, without replaying any original data during the new training run, by adding a quadratic penalty to the loss that is weighted by each parameter's Fisher information -- an estimate of how important that parameter was to the earlier task -- so parameters that mattered most for the earlier task are constrained to change less while less-important parameters remain free to adapt. The option that swaps these mechanisms, crediting EWC with replaying data and rehearsal with a Fisher-information penalty, is wrong because it reverses which technique does which. The option claiming the two are mathematically identical and differ only by optimizer is wrong because they modify entirely different parts of the training process -- one changes the training data mixture, the other changes the loss function's penalty term -- regardless of which optimizer applies the resulting gradients. The option claiming both require discarding the new dataset and training only on old data is wrong because both strategies are designed to let the model continue learning the new task while protecting the old one, not to abandon the new task altogether.
Source: Kirkpatrick et al., 'Overcoming catastrophic forgetting in neural networks' (PNAS, 2017)
AI & LLM Engineering · Fine-tuning & Model Customisation · Card 014/055easy
A team wants to compress a large, expensive-to-serve model into a much smaller model that mimics its behavior, rather than training the small model directly on the original hard labels from scratch. They use knowledge distillation (Hinton et al.). What signal does the smaller 'student' model actually learn from that a model trained only on hard labels would not have access to?
AThe student receives the teacher's raw gradient updates from pretraining and copies them directly into its own parameters
BThe student is trained on a much larger set of hard-labeled examples that the teacher itself never saw during its own training
CThe student directly copies the teacher's attention weight matrices into its own, smaller set of layers
DThe student is trained to match the teacher's softened output probability distribution across all classes or tokens, produced by raising the softmax temperature, which reveals the relative similarities the teacher perceives between the incorrect options -- information Hinton called 'dark knowledge' that a single correct hard label does not carry
Correct answer: .
Knowledge distillation trains the student against the teacher's softened output distribution -- the full probability the teacher assigns to every class or token, not just its single top pick -- obtained by raising the softmax temperature so the smaller probabilities on the wrong classes become visible instead of being rounded to near zero; those relative probabilities across the 'wrong' classes still encode real information about which mistakes the teacher considers more or less plausible, which Hinton termed 'dark knowledge,' and a hard, one-correct-label target simply cannot carry. The option describing the student copying the teacher's raw pretraining gradients is wrong because distillation trains the student on the teacher's output distribution for the actual training examples, not on a historical record of the teacher's own gradient updates. The option describing extra hard-labeled data the teacher never saw is wrong because distillation's value comes from the soft probability signal itself, not from giving the student more hard-labeled examples. The option describing the student copying the teacher's attention weight matrices is wrong because distillation transfers behavior through the training signal (the output distribution), not by directly copying internal weight matrices between differently sized architectures.
Source: Hinton, Vinyals & Dean, 'Distilling the Knowledge in a Neural Network' (arXiv:1503.02531, 2015)
AI & LLM Engineering · Fine-tuning & Model Customisation · Card 015/055hard
Wei et al.'s FLAN study found that instruction-tuning a model on a large, diverse collection of tasks improved its zero-shot performance on entirely unseen tasks. Zhou et al.'s LIMA study later fine-tuned a 65B model on only 1,000 carefully curated prompt-response pairs, with no reinforcement learning or preference modeling, and still produced strong, competitive instruction-following output. What does the LIMA finding actually support, per the paper's own framing?
AThe 'Superficial Alignment Hypothesis' -- that almost all of a model's knowledge and capability is acquired during pretraining, so fine-tuning mainly needs to teach the narrower, learnable subtask of which output style and format to use, meaning a small but carefully curated example set can suffice
BThat instruction tuning is the primary mechanism by which a model acquires new factual knowledge it lacked after pretraining
CThat fine-tuning dataset size is irrelevant in general, and larger instruction-tuning datasets actively hurt performance in every case
DThat FLAN's finding about zero-shot generalization to genuinely unseen task categories was mistaken, since LIMA shows diverse task coverage is never necessary for any instruction-tuning goal
Correct answer: .
LIMA's result -- strong, competitive output from only 1,000 carefully curated examples and no reinforcement learning or preference modeling -- is offered by its authors in support of what they call the Superficial Alignment Hypothesis: that a model's knowledge and capabilities are learned almost entirely during pretraining, and fine-tuning's job is mainly the comparatively narrow, learnable task of teaching the model which format and style to use when responding, which is why a small but carefully curated set of examples can be enough. The option claiming instruction tuning is how a model acquires new factual knowledge is wrong because it inverts LIMA's own claim, which is that knowledge comes from pretraining and fine-tuning contributes format and style rather than new facts. The option claiming dataset size is irrelevant and larger datasets always hurt is wrong because LIMA does not make a universal claim against scale; it demonstrates that a small, carefully curated set can suffice for its specific alignment goal, not that scale is actively harmful in every setting. The option claiming LIMA overturns FLAN's zero-shot generalization finding is wrong because the two studies test different properties -- FLAN's finding concerns zero-shot transfer to task categories never seen during instruction tuning, which LIMA's single-style curated dataset was not designed to test at all, so LIMA's result does not contradict it.
Source: Zhou et al., 'LIMA: Less Is More for Alignment' (arXiv:2305.11206, 2023); Wei et al., 'Finetuned Language Models Are Zero-Shot Learners' (arXiv:2109.01652, 2022)
AI & LLM Engineering · Fine-tuning & Model Customisation · Card 016/055medium
A team fine-tunes one shared model jointly on several dissimilar tasks at once, hoping this multi-task fine-tuning will be more efficient than training a separate model per task. Instead, performance on some individual tasks drops below what single-task fine-tuning on that task alone achieved. Yu et al.'s 'Gradient Surgery for Multi-Task Learning' paper studied this and identified what as a key optimization-level cause?
AThe drop is identical to catastrophic forgetting, which specifically occurs when tasks are trained one after another in sequence rather than jointly
BThe drop happens only because the learning rate used across all tasks was set too high, and lowering it always eliminates the effect
CGradients computed for different tasks can point in genuinely conflicting directions at parameters the tasks share, meaning they have negative cosine similarity, so combining them naively lets progress on one task come directly at the expense of another; the paper's proposed fix projects away each gradient's conflicting component before it is applied
DJoint multi-task training always improves every individual task's performance simultaneously, so no genuine drop in any task's performance is actually possible
Correct answer: .
Yu et al. identify conflicting gradients -- task gradients at shared parameters that point away from each other, i.e. have negative cosine similarity -- as a key optimization-level cause of multi-task interference, and propose 'gradient surgery' (PCGrad), which projects a task's gradient onto the normal plane of a conflicting gradient before applying it, so the update no longer directly fights the other task at that step. The option equating this with catastrophic forgetting is wrong because catastrophic forgetting is specifically a sequential-training phenomenon -- losing an earlier task's performance while training on a later one -- whereas this interference happens with tasks trained jointly, at the same time, which is a distinct optimization dynamic. The option blaming only an overly high learning rate is wrong because the paper attributes the effect to the geometric relationship between task gradients, not simply to step size, and shows the conflict persists as a structural property even with careful tuning. The option claiming joint training always helps every task is wrong because it directly contradicts the premise the paper investigates -- individual task performance genuinely can, and does, drop under naive joint optimization.
Source: Yu et al., 'Gradient Surgery for Multi-Task Learning' (arXiv:2001.06782, NeurIPS 2020)
AI & LLM Engineering · Fine-tuning & Model Customisation · Card 017/055hard
A team has plenty of past model outputs individually labeled 'good' or 'bad' by users, but very few outputs that were ever compared head-to-head as a preferred-versus-dispreferred pair for the same prompt. They want a preference-alignment method that can train directly on this binary-labeled data without first constructing new paired comparisons. Which method fits, and why?
ARLAIF fits best, because it removes the need for any human-provided labels entirely by having a separate LLM generate paired preference comparisons instead of relying on the binary labels already collected
BKTO (Kahneman-Tversky Optimization) fits, because its loss is grounded in prospect theory and requires only a single binary desirable/undesirable label per output, not a comparison against another output for the same prompt -- unlike DPO, whose loss is defined over a pair of preferred and dispreferred completions sharing a prompt
CConstitutional AI fits best, because its entire training pipeline is defined purely on binary labels and never involves any paired comparisons at any stage
DStandard RLHF's reward-model training step already works directly on binary desirable/undesirable labels without any modification, so no different method is needed
Correct answer: .
KTO trains directly on a single binary desirable/undesirable label per output, without needing that output compared against an alternative for the same prompt, because its loss function is built on a Kahneman-Tversky-style utility model from prospect theory rather than on a pairwise comparison objective; DPO, by contrast, needs an actual preferred/dispreferred pair sharing a prompt, which is exactly the paired data this team lacks. The option pointing to RLAIF is wrong because RLAIF still produces paired preference comparisons, just generated by an LLM judge instead of human labelers, so it does not remove the need to construct pairs -- it only changes who constructs them. The option describing Constitutional AI as purely binary-label-based throughout is wrong because its second, reinforcement-learning phase still trains against AI-generated pairwise preference comparisons, not solely independent binary labels. The option claiming standard RLHF's reward model already works directly on binary labels is wrong because that reward model is conventionally trained with a pairwise (Bradley-Terry-style) comparison loss, not a per-output binary label.
Source: Ethayarajh et al., 'KTO: Model Alignment as Prospect Theoretic Optimization' (arXiv:2402.01306, 2024)
AI & LLM Engineering · Fine-tuning & Model Customisation · Card 018/055easy
A company wants to offer thousands of customers their own fine-tuned 'personal' version of the same base model, without hosting thousands of separate full model copies on GPUs. What approach, as demonstrated by serving systems like S-LoRA, makes this feasible?
AMerge every customer's LoRA adapter weights permanently into one single shared base model in advance, so every customization is active for every request regardless of who is asking
BQuantize the base model to 4-bit precision for every customer so that thousands of full model copies can fit into GPU memory at once
CFine-tune one shared model on the concatenation of every customer's data, so a single identical model serves all customers and no per-customer weights are needed at all
DKeep one shared frozen base model resident on the GPU, store each customer's lightweight LoRA adapter weights separately, and dynamically load and batch just the small adapter matrices an incoming request needs against that shared base model, instead of duplicating the entire base model per customer
Correct answer: .
S-LoRA-style serving keeps a single frozen base model loaded on the GPU and stores each customer's much smaller LoRA adapter weights separately, loading and batching only the specific adapters needed for the requests currently being served against that one shared base model -- since an individual adapter is a tiny fraction of the base model's size, this lets one GPU deployment support thousands of distinct customizations instead of one full model copy per customer. The option describing merging every adapter into one shared model in advance is wrong because that would make every customization active for every request, defeating the purpose of per-customer personalization. The option describing quantizing the base model so thousands of full copies fit in memory is wrong because it still requires a full model copy per customer; quantization shrinks each copy but doesn't eliminate the fundamental one-copy-per-customer duplication. The option describing training one shared model on all customers' concatenated data is wrong because that produces a single generic model with no per-customer distinction at all, which is the opposite of what per-customer personalization requires.
Source: Sheng et al., 'S-LoRA: Serving Thousands of Concurrent LoRA Adapters' (arXiv:2311.03285, 2023)
AI & LLM Engineering · Fine-tuning & Model Customisation · Card 019/055easy
A developer wants to run supervised fine-tuning on one of OpenAI's models through OpenAI's API. Per OpenAI's current documentation, which statement correctly describes how this process works?
AThe developer uploads a JSONL file where each line is a training example formatted as a list of chat messages with roles such as system, user, and assistant; hyperparameters like the number of epochs, batch size, and learning-rate multiplier can each be set to 'auto' or overridden explicitly, and once the job completes, the fine-tuned model is called through its own distinct fine-tuned model identifier rather than replacing the original base model
BThe developer must submit raw, unstructured plain-text files for training, since the chat-message format with roles is only accepted for ordinary inference calls, never for fine-tuning jobs
CEvery fine-tuning hyperparameter, including epochs, batch size, and learning-rate multiplier, must be manually specified by the developer; OpenAI provides no option to select them automatically
DOnce fine-tuning completes, the resulting model silently replaces the original base model account-wide, so the base model's own name begins returning the fine-tuned outputs for every user of that base model
Correct answer: .
OpenAI's supervised fine-tuning takes a JSONL training file in which each line is one training example formatted as a list of chat messages carrying roles like system, user, and assistant, mirroring the same structure used at inference time; hyperparameters such as the number of epochs, batch size, and learning-rate multiplier can be left as 'auto' for OpenAI to select or set explicitly by the developer, and the finished fine-tuned model is accessed through its own separate fine-tuned model identifier, used alongside, not instead of, the original base model. The option requiring raw plain-text files is wrong because the same chat-message format used for ordinary API calls is exactly what the training file uses, not a different plain-text format. The option claiming every hyperparameter must be manually specified is wrong because OpenAI explicitly offers an automatic 'auto' setting for these hyperparameters as an alternative to manual specification. The option claiming the base model itself gets silently overwritten account-wide is wrong because the fine-tuned result is exposed under its own distinct model identifier, leaving the original base model and its behavior for other users completely unaffected.
Source: OpenAI API documentation, fine-tuning / model optimization guide (developers.openai.com/api/docs/guides/model-optimization)
AI & LLM Engineering · Fine-tuning & Model Customisation · Card 020/055easy
A team must choose between full-parameter fine-tuning and a parameter-efficient method such as LoRA to adapt a large pretrained model to a substantially different domain, one requiring the model to learn many genuinely new patterns poorly represented in its pretraining data. Which statement correctly compares the two approaches' tradeoffs for this scenario?
AParameter-efficient methods always match or exceed full fine-tuning's capacity to absorb any size of distribution shift, so full fine-tuning is never worth its extra cost
BFull fine-tuning trains strictly fewer parameters than any parameter-efficient method, because it can reuse the pretrained weights completely unchanged
CFull fine-tuning updates every model parameter, generally giving it the highest capacity to absorb a large distribution shift or a genuinely new capability, but at the cost of a full new model copy per task, the largest compute and memory bill, and the greatest risk of catastrophic forgetting of prior abilities; parameter-efficient methods constrain learning to a much smaller set of new parameters, which is cheaper to train, store, and swap between tasks, but can hit a lower capacity ceiling when the required change is very large
DThe two approaches are mathematically identical operations on the model's weights, differing only in which optimizer library happens to implement them
Correct answer: .
Full fine-tuning's access to every parameter generally gives it the greatest raw capacity to absorb a large distribution shift or a genuinely new capability, but that comes with the largest compute and memory bill, a full new model copy to store per task, and the greatest exposure to catastrophic forgetting of prior abilities; parameter-efficient methods restrict learning to a much smaller set of newly introduced parameters, which is far cheaper to train, store, and swap between tasks, but that same restriction can become a real capacity ceiling when the target domain requires learning a very large amount of genuinely new material. The option claiming parameter-efficient methods always match or exceed full fine-tuning's capacity for any shift size is wrong because a much smaller set of trainable parameters is a real constraint that can bind precisely in the large-distribution-shift scenario described. The option claiming full fine-tuning trains strictly fewer parameters is wrong because full fine-tuning updates every one of the model's parameters, which is categorically more than the small added parameter set any parameter-efficient method trains. The option describing the two approaches as mathematically identical, differing only by optimizer library, is wrong because they update fundamentally different sets of parameters -- the entire model versus a small added subset -- not merely different software implementations of the same operation.
Source: Hu et al., 'LoRA: Low-Rank Adaptation of Large Language Models' (arXiv:2106.09685, 2021)
AI & LLM Engineering · Fine-tuning & Model Customisation · Card 021/055medium
A team wants a parameter-efficient fine-tuning method for a few-shot setting with even fewer trainable parameters than LoRA, and one that can still be folded into the frozen base weights at inference with no added latency. They adopt IA3 (Infused Adapter by Inhibiting and Amplifying Inner Activations), the method behind Liu et al.'s T-Few recipe. What does IA3 actually do differently from LoRA's low-rank weight update?
AIt appends a small trainable classification head after the model's final hidden layer and trains only that head, leaving every transformer block's attention and feedforward weights completely untouched
BIt inserts a small number of brand-new transformer layers between the existing frozen layers and trains only those newly inserted layers end to end
CIt learns a handful of trainable vectors that rescale the key, value, and feedforward activations inside each transformer block by elementwise multiplication, rather than adding a low-rank matrix update to any weight matrix
DIt duplicates each frozen weight matrix into two half-precision copies and trains only the numerical difference between the two copies, effectively performing full fine-tuning at half the memory cost
Correct answer: .
IA3 does not touch any pretrained weight matrix at all. Instead, for each targeted transformer block it introduces a small set of new trainable vectors that elementwise-rescale the key, value, and feedforward-hidden activations as they flow through the frozen network, amplifying or inhibiting specific dimensions of those activations rather than approximating a weight update with a low-rank matrix product the way LoRA does. Because these are just extra multiplicative vectors rather than a full additional weight matrix, IA3 introduces even fewer trainable parameters than LoRA, and because the rescaling is a simple elementwise operation, it can also be absorbed back into the adjacent frozen weights before inference so no extra latency remains, similar in spirit to a merged LoRA adapter. The option describing a trainable classification head is wrong because that only adapts the model's output layer and leaves the transformer's internal representations exactly as pretrained, which is a much weaker and different kind of adaptation than reshaping activations throughout the network. The option describing newly inserted transformer layers is wrong because that describes an adapter-style architecture change that adds depth to the network, not IA3's activation-rescaling mechanism, and would also add real inference latency that cannot be merged away. The option describing training the difference between two half-precision copies of each weight matrix is wrong because that is simply full fine-tuning restated with a memory trick, still updating every original parameter, which is the opposite of IA3's small, fixed set of rescaling vectors.
Source: Liu et al., 'Few-Shot Parameter-Efficient Fine-Tuning is Better and Cheaper than In-Context Learning' (NeurIPS 2022, arXiv:2205.05638)
AI & LLM Engineering · Fine-tuning & Model Customisation · Card 022/055easy
A team has only a small labeled dataset for a new classification task and wants to adapt a pretrained BERT-style model while touching as few parameters as possible. Following Ben Zaken et al.'s BitFit method, they fine-tune only the model's bias terms, leaving every weight matrix frozen. What did the BitFit paper actually find about this approach on small-to-medium training sets?
ABias-only fine-tuning was competitive with, and on some tasks better than, fine-tuning the entire model, despite updating roughly 0.1% of the parameters
BBias-only fine-tuning failed to learn the new task at all, since bias terms alone cannot shift a model's output distribution in any meaningful way
CBias-only fine-tuning matched full fine-tuning only when combined with a newly added low-rank adapter matrix inserted into every attention layer
DBias-only fine-tuning required training for far more epochs than full fine-tuning before reaching comparable accuracy, making it slower overall despite touching fewer parameters
Correct answer: .
Ben Zaken et al. found that on small-to-medium training data, fine-tuning only the bias terms of a pretrained transformer such as BERT is competitive with full fine-tuning, and sometimes even outperforms it, while updating only about 0.1% of the model's total parameters. The paper frames this as evidence that most of the task-relevant capability already exists in the pretrained weights, and that fine-tuning is largely about exposing and steering that existing knowledge rather than learning substantial new computation, which is why nudging just the additive bias terms in each layer can redirect the model's behavior effectively. The option claiming bias-only fine-tuning fails to learn the task is wrong because the paper's central empirical result is the opposite: it works surprisingly well, not that it fails outright. The option requiring a newly added low-rank adapter matrix is wrong because that describes combining BitFit with a LoRA-style addition, which is not what the original BitFit method does; BitFit's whole point is that touching only pre-existing bias parameters, with no new matrices added anywhere, is already sufficient. The option claiming bias-only fine-tuning needs far more training epochs is wrong because the paper does not report a slower convergence tradeoff of this kind; its headline finding is about matching full fine-tuning's accuracy with drastically fewer trainable parameters, not about needing more training time to get there.
Source: Ben Zaken, Goldberg & Ravfogel, 'BitFit: Simple Parameter-efficient Fine-tuning for Transformer-based Masked Language-models' (ACL 2022, arXiv:2106.10199)
AI & LLM Engineering · Fine-tuning & Model Customisation · Card 023/055easy
A team wants to instruction-tune a language model but has only a small, narrow set of human-written instruction examples and no budget for large-scale human annotation. Following Wang et al.'s Self-Instruct method, they use the pretrained model itself, starting from that small seed set, to expand their instruction-tuning data. What does Self-Instruct actually do?
AIt trains a separate, smaller model exclusively on the seed examples, then uses that smaller model's weights directly as the fine-tuned model without any further data generation
BIt scrapes exam questions and solutions from publicly available question banks and question-answer forums, then relabels them as instruction-response pairs without any model generation involved
CIt uses the language model to iteratively generate new instructions and matching input-output examples from the seed set, filters out invalid or overly similar ones, then fine-tunes the same model on the resulting synthetic dataset
DIt replaces the fine-tuning stage entirely with a longer pretraining run on a larger, unlabeled general-purpose text corpus unrelated to the seed instructions
Correct answer: .
Self-Instruct is an iterative bootstrapping pipeline: starting from a small, manually written seed set of instructions, the language model itself is prompted to generate new instructions along with plausible inputs and outputs for them, invalid or excessively similar generations are filtered out, and the surviving synthetic examples are added to the pool used to fine-tune that same model, letting a small seed set expand into a much larger instruction-tuning dataset without further human annotation. Wang et al. reported that applying this to GPT-3 closed most of the gap to InstructGPT despite using only model-generated data grown from a small seed. The option describing training a separate smaller model solely on the seed examples is wrong because Self-Instruct's value comes precisely from generating large amounts of new synthetic data beyond the seed set, not from training directly on the small seed alone. The option describing scraping and relabeling existing question banks is wrong because that would reuse text authored by third parties rather than having the model generate genuinely new instructions and responses, which is the defining bootstrapping step Self-Instruct performs. The option describing a longer unrelated pretraining run is wrong because Self-Instruct is specifically about generating instruction-following fine-tuning data, not about extending unsupervised pretraining on unrelated general text.
Source: Wang et al., 'Self-Instruct: Aligning Language Models with Self-Generated Instructions' (ACL 2023, arXiv:2212.10560)
AI & LLM Engineering · Fine-tuning & Model Customisation · Card 024/055medium
Meta's Llama 2 chat models were aligned using several rounds of RLHF, and for the earlier rounds (through RLHF-V4) the paper describes relying only on rejection sampling fine-tuning rather than PPO. Under this rejection sampling fine-tuning approach, what actually happens to the model in each round?
AThe current policy generates a fixed number of candidate responses per prompt, the reward model scores each candidate, and the model is then supervised-fine-tuned on the highest-scoring candidates, with no policy-gradient update performed
BThe current policy generates a single response per prompt, and that response is accepted unconditionally as training data regardless of what the reward model scores it, since no rejection ever actually happens
CThe reward model itself is fine-tuned on the current policy's outputs each round, while the policy's own weights are left completely frozen throughout every round
DThe policy is updated using the PPO clipped surrogate objective against the reward model's scores, exactly as in standard RLHF, and 'rejection sampling' only refers to discarding malformed API responses
Correct answer: .
In rejection sampling fine-tuning, the current policy samples K candidate responses for each prompt, the reward model scores every candidate, and the highest-scoring candidate (or candidates) becomes new supervised training data that the model is fine-tuned on directly, functioning like a best-of-N selection step folded into supervised learning rather than a policy-gradient reinforcement learning update. Meta's Llama 2 paper describes using exactly this approach alone through RLHF-V4 before layering PPO on top from RLHF-V5 onward, treating the reward-selected best sample as the new gold-standard target for the next round of supervised fine-tuning. The option describing unconditional acceptance of a single generated response regardless of reward score is wrong because the entire point of the method is selective: multiple candidates are generated and scored, and only the reward model's top pick is kept, which is what makes it 'rejection' sampling rather than plain self-training. The option describing the reward model being fine-tuned while the policy stays frozen is backwards; the reward model is the fixed scorer used to select data, while it is the policy that gets updated via supervised fine-tuning on the selected samples. The option describing a PPO clipped surrogate update is wrong because rejection sampling fine-tuning is explicitly the alternative to PPO used in the earlier rounds; PPO and rejection sampling fine-tuning are two distinct mechanisms in the paper, and 'rejection sampling' here refers to discarding lower-reward generated candidates, not malformed API responses.
Source: Touvron et al., 'Llama 2: Open Foundation and Fine-Tuned Chat Models' (arXiv:2307.09288), Section 3.2
AI & LLM Engineering · Fine-tuning & Model Customisation · Card 025/055hard
A team wants to align a pretrained language model to preference data but wants to skip having a separate supervised fine-tuning warm-up stage and avoid maintaining any frozen reference model during training, unlike DPO. They adopt ORPO (Odds Ratio Preference Optimization, Hong et al.). How does ORPO actually achieve preference alignment without a reference model?
AIt trains a full reward model on the preference pairs first, then performs standard PPO reinforcement learning against that reward model without ever fine-tuning on the preferred responses directly
BIt requires two separately trained frozen copies of the base model, one for the chosen response and one for the rejected response, and computes their KL divergence as the sole training signal
CIt discards the preference labels entirely and instead fine-tunes only on the chosen responses using ordinary supervised fine-tuning, treating the rejected responses as irrelevant noise to be ignored
DIt appends a log odds-ratio penalty term, comparing the odds of generating the chosen versus the rejected response, directly onto the ordinary supervised fine-tuning negative log-likelihood loss, in a single combined training stage
Correct answer: .
ORPO folds preference alignment into the ordinary supervised fine-tuning objective by adding a log odds-ratio term that contrasts the model's odds of generating the chosen response against its odds of generating the rejected response for the same prompt, combined with the standard negative log-likelihood loss on the chosen response, all in one monolithic training stage. Because the odds ratio is computed from the same policy being trained rather than compared against a separately maintained frozen copy, ORPO needs neither a preceding supervised fine-tuning warm-up phase nor a frozen reference model during training, which is exactly the overhead DPO still carries and PPO carries even more of via its explicit reward model and KL penalty. The option describing training a reward model and then running standard PPO is wrong because that is the very RLHF pipeline ORPO is designed to avoid, complete with the reward model and the reinforcement-learning loop ORPO has no need for. The option describing two frozen model copies and a KL divergence signal is wrong because that describes something closer to DPO's or PPO's reliance on a fixed reference policy, whereas ORPO's defining feature is that it uses no reference model at all, frozen or otherwise. The option describing discarding the preference labels and fine-tuning only on chosen responses is wrong because ORPO's odds-ratio term specifically depends on the rejected response too, actively penalizing it, rather than ignoring it as the option suggests.
Source: Hong, Lee & Thorne, 'ORPO: Monolithic Preference Optimization without Reference Model' (EMNLP 2024, arXiv:2403.07691)
AI & LLM Engineering · Fine-tuning & Model Customisation · Card 026/055easy
A team fine-tunes a model with LoRA for a single production task and, before deploying it, merges the LoRA adapter's low-rank matrices directly into the base model's frozen weight matrices to produce one combined checkpoint. Compared to serving the same task with the LoRA adapter kept separate from the base weights at inference time, what is the effect of merging?
AThe merged checkpoint runs inference with essentially zero added latency compared to the base model alone, since the forward pass is now identical in shape and computation to the original unmodified model
BThe merged checkpoint runs noticeably slower than keeping the adapter separate, because merging forces every layer to be recomputed twice, once with and once without the adapter's contribution
CMerging has no effect on inference speed either way, because LoRA adapters already add zero computational overhead even when kept separate from the base weights
DMerging prevents the model from being fine-tuned again in the future, since a merged checkpoint permanently loses the ability to have any new LoRA adapter trained against it
Correct answer: .
Once a LoRA adapter's low-rank matrices are merged into the base weight matrices, the resulting checkpoint has exactly the same tensor shapes and layer structure as the original base model; the forward pass no longer computes a separate adapter contribution and adds it on top, it simply runs the base model's ordinary computation with different numerical weight values. That means merged inference carries essentially zero added latency compared to the unmodified base model, which is why merging is the preferred choice for single-task, latency-sensitive deployment. Keeping the adapter separate, by contrast, requires computing and adding the extra low-rank term at every targeted layer during each forward pass, which is a real (if often small) computational overhead compared to a merged checkpoint, and is the tradeoff systems that serve many different LoRA adapters on one base model, such as S-LoRA, deliberately accept in order to avoid maintaining many separate merged copies. The option claiming merging forces double computation is wrong because merging eliminates the separate adapter computation entirely rather than duplicating it. The option claiming adapters already add zero overhead when kept separate is wrong because computing an extra matrix product at every targeted layer is not free, even though it is typically small relative to the model's overall compute. The option claiming merging permanently blocks future fine-tuning is wrong because a merged checkpoint is just an ordinary set of weights and remains fully fine-tunable, including by attaching a brand-new LoRA adapter on top of it.
Source: Hu et al., 'LoRA: Low-Rank Adaptation of Large Language Models' (arXiv:2106.09685), Section 4.2 (merging and zero inference latency)
AI & LLM Engineering · Fine-tuning & Model Customisation · Card 027/055easy
In Ouyang et al.'s InstructGPT pipeline, the second stage trains a reward model on human rankings of multiple candidate responses to the same prompt, before that reward model is used to guide PPO in the third stage. Whose outputs are actually ranked by human labelers to produce the training data for this reward model?
AOutputs sampled directly from the original pretrained GPT-3 model before any supervised fine-tuning has been applied to it at all
BOutputs sampled from a separate, independently trained reward model that has no relationship to the supervised fine-tuned model at any stage of the pipeline
COutputs written entirely by the human labelers themselves, with no model-generated text involved anywhere in the reward-model training data
DOutputs sampled from the supervised fine-tuned model produced in the pipeline's first stage, since the reward model needs to distinguish quality among responses similar in style to what the policy being aligned will actually generate
Correct answer: .
InstructGPT's three-stage pipeline first produces a supervised fine-tuned (SFT) model trained on human demonstrations, and it is that SFT model, not the raw pretrained base model, that is used to sample multiple candidate responses per prompt for labelers to rank in the second stage. This matters because the reward model needs to learn to discriminate quality among responses that resemble what the policy actually being aligned will generate once RLHF begins; ranking outputs from a very different distribution, such as the raw pretrained model's often incoherent or off-task completions, would teach the reward model to distinguish differences that are far less relevant to the fine-tuned policy's actual output space. The option describing sampling from the original pretrained GPT-3 model before any supervised fine-tuning is wrong because that base model's outputs are not yet representative of the aligned policy's behavior, and the paper's pipeline explicitly inserts the supervised fine-tuning stage first for this reason. The option describing outputs from a separate, unrelated reward model is backwards: the reward model is the thing being trained from these rankings, not the source generating the candidates being ranked. The option describing outputs written entirely by human labelers is wrong because the reward-model stage specifically compares and ranks model-generated candidate responses; the labelers' human-written demonstrations belong to the earlier supervised fine-tuning stage, not to this ranking stage.
Source: Ouyang et al., 'Training language models to follow instructions with human feedback' (NeurIPS 2022, arXiv:2203.02155), Section 3
AI & LLM Engineering · Fine-tuning & Model Customisation · Card 028/055medium
During the PPO stage of a standard RLHF pipeline, the training objective adds a per-token penalty based on the KL divergence between the policy currently being trained and a frozen copy of the supervised fine-tuned model kept unchanged throughout training. What problem does this KL penalty against the frozen reference policy actually address?
AIt compresses the policy's vocabulary distribution so that only the single highest-probability token can ever be sampled at each generation step, eliminating randomness in the output entirely
BIt restrains the policy from drifting into regions of output space that exploit inaccuracies in the reward model to score highly while producing degenerate, incoherent, or off-distribution text
CIt reduces the total number of parameters the policy needs to store by sharing all weights between the policy and the frozen reference model at inference time
DIt replaces the reward model's score entirely once training begins, so that after the first few PPO updates the reward model's output is no longer used at all
Correct answer: .
A reward model is only an imperfect proxy for true human judgment, and a policy optimized hard enough against it, with no other constraint, can drift into regions of output space that score highly under the reward model's specific quirks and blind spots while actually producing repetitive, incoherent, or otherwise degenerate text a human would rate poorly -- a form of reward hacking. Adding a per-token KL divergence penalty between the current policy and a frozen copy of the supervised fine-tuned model anchors the policy near its well-behaved starting distribution, so large reward gains that require straying far from realistic, fluent language are penalized even if the reward model itself would have scored them favorably. The option describing collapsing generation to always pick the single highest-probability token is wrong because the KL penalty constrains how far the whole output distribution can drift from the frozen reference, it does not force greedy, zero-randomness decoding. The option describing weight sharing between the policy and the frozen reference to save parameters is wrong because the reference model is kept as a separate frozen copy specifically so its distribution stays fixed for comparison; sharing weights would make the reference model change along with the policy, defeating the entire purpose of the penalty. The option describing the reward model being discarded after the first few updates is wrong because the reward model's score remains the primary training signal throughout PPO; the KL term is an additional regularizer alongside it, not a replacement for it.
Source: Ouyang et al., 'Training language models to follow instructions with human feedback' (arXiv:2203.02155), Section 3.3; Schulman et al., 'Proximal Policy Optimization Algorithms' (arXiv:1707.06347)
AI & LLM Engineering · Fine-tuning & Model Customisation · Card 029/055easy
Gururangan et al. studied continuing a language model's original pretraining objective on a large volume of unlabeled text drawn from a specific target domain (such as biomedical or computer science publications), before any task-specific fine-tuning happens, calling this domain-adaptive pretraining (DAPT). What does DAPT actually involve, and what did the study find?
AIt replaces the pretraining objective with a supervised classification loss trained on labeled examples from the target domain, and the study found this always outperforms fine-tuning on labeled task data alone
BIt continues the same unsupervised pretraining objective (such as masked or autoregressive language modeling) on unlabeled in-domain text before task fine-tuning, and the study found this second pretraining phase generally improved downstream task performance across the domains and tasks tested
CIt fine-tunes only the model's final classification layer on a small number of labeled in-domain examples while freezing every other layer, and the study found this matched full fine-tuning in every domain tested
DIt discards the original pretrained weights entirely and pretrains a new, smaller model from scratch on only the in-domain corpus, and the study found this always outperformed continuing from the original pretrained model
Correct answer: .
Domain-adaptive pretraining, as studied by Gururangan et al., does not introduce a new training objective or labels at all; it simply continues the model's original unsupervised pretraining objective, such as masked language modeling, on a large corpus of unlabeled text drawn from the target domain, before the usual task-specific fine-tuning stage begins. Across four domains (biomedical and computer science publications, news, and reviews) and eight classification tasks, the study found that this extra in-domain pretraining phase generally improved downstream performance in both high-resource and low-resource task settings, essentially shifting the model's learned representations toward the statistics of the target domain before it is specialized further for any specific labeled task. The option describing a supervised classification loss on labeled in-domain data is wrong because DAPT is explicitly unsupervised, using unlabeled domain text and the model's existing pretraining objective, not new labels. The option describing freezing every layer except the final classification head is wrong because that describes a linear-probing style adaptation, not the full continued-pretraining approach DAPT uses, and the study did not find that partial freezing matched full fine-tuning. The option describing discarding the original pretrained weights and training a new smaller model from scratch is wrong because DAPT explicitly continues from the existing pretrained checkpoint to retain its general-purpose knowledge, rather than throwing that knowledge away and starting over.
Source: Gururangan et al., 'Don't Stop Pretraining: Adapt Language Models to Domains and Tasks' (ACL 2020, arXiv:2004.10964)
AI & LLM Engineering · Fine-tuning & Model Customisation · Card 030/055hard
In Hu et al.'s original LoRA formulation, the weight update injected at a targeted layer is scaled by a factor of alpha divided by rank (alpha/r) before being added to the frozen weight matrix, rather than being added at its raw magnitude. A team is deciding how to adjust rank r while keeping the update's overall magnitude roughly the same. What is this alpha/r scaling factor actually for?
AIt converts the trainable low-rank matrices from floating-point to integer precision before they are added to the frozen weight matrix, reducing memory usage during training
BIt determines how many transformer layers LoRA is applied to, with a higher alpha/r value applying the adapter to progressively more layers of the frozen model
CIt sets the learning rate used specifically for the frozen base weights, independently of the learning rate used for the trainable low-rank matrices themselves
DIt normalizes the magnitude of the injected update so that increasing or decreasing the rank alone does not automatically make the update's overall size grow or shrink, letting rank be adjusted somewhat independently of how strongly the update perturbs the frozen weights
Correct answer: .
LoRA's injected update is the product of two low-rank matrices, and without any correction, increasing the rank r adds more terms to that product and roughly increases the raw magnitude of the resulting update, meaning a change to rank alone would also change how strongly the frozen weights are perturbed and would typically force retuning the learning rate every time rank is adjusted. Scaling the raw update by alpha divided by r counteracts this: with alpha held fixed, sweeping r keeps the update's overall magnitude approximately constant, which is what lets a practitioner treat rank largely as a separate, independent knob for capacity rather than one that is entangled with how large a perturbation the adapter applies. The option describing conversion to integer precision is wrong because alpha/r is a floating-point scalar multiplier applied to the update's magnitude, not a numerical-precision or quantization mechanism at all. The option describing controlling how many layers LoRA is applied to is wrong because layer selection is a separate configuration choice (which weight matrices to target) made independently of the alpha/r scalar, which only affects the magnitude of updates at whichever layers are already selected. The option describing a separate learning rate for the frozen base weights is wrong because the base weights are frozen and never updated by gradient descent at all during LoRA fine-tuning, so no learning rate applies to them; alpha/r instead rescales the trainable adapter's own contribution to the forward pass.
Source: Hu et al., 'LoRA: Low-Rank Adaptation of Large Language Models' (arXiv:2106.09685), Section 4.1
AI & LLM Engineering · Fine-tuning & Model Customisation · Card 031/055medium
LoRA (Low-Rank Adaptation) is a parameter-efficient fine-tuning method. Instead of updating all weights in a pre-trained model, what does LoRA do differently, and why does this save memory and compute?
ALoRA freezes the original model weights and injects small trainable low-rank matrices into each transformer layer — because these matrices have far fewer parameters than the full weight matrices, the training requires much less GPU memory and compute while still adapting the model's behavior to the target task
BLoRA removes half of the model's layers before fine-tuning, cutting the parameter count in half and therefore halving the memory and compute requirements
CLoRA trains all parameters but uses a lower learning rate, which reduces compute by requiring fewer gradient update steps to converge
DLoRA converts the model from 32-bit to 4-bit precision before training, which is why it uses less memory — the low-rank aspect refers to the reduced numerical precision, not the matrix decomposition
Correct answer: .
LoRA, introduced by Hu et al. (2021), decomposes each weight update into a product of two small matrices with a low rank (e.g., rank 4 or 16). The original pre-trained weights are frozen and unchanged; only the small adapter matrices are trained. For a weight matrix of size d×d, a rank-r LoRA adapter has only 2×d×r parameters — dramatically fewer than d×d. This means gradients, optimizer states, and the trainable parameters themselves consume a fraction of the memory required for full fine-tuning. The option about removing layers describes model pruning, not LoRA. The option about lower learning rates conflates a hyperparameter choice with an architectural technique. The option about quantisation describes QLoRA (which combines LoRA with 4-bit quantisation) but confuses 'low-rank' (a linear algebra concept about matrix decomposition) with 'low precision' (a numerical representation concept).
Source: Hu et al. (2021), 'LoRA: Low-Rank Adaptation of Large Language Models', arXiv:2106.09685
AI & LLM Engineering · Fine-tuning & Model Customisation · Card 032/055medium
A team is fine-tuning a large model with LoRA at a single fixed rank applied uniformly to every weight matrix in every layer, and notices that some layers clearly matter more to the target task than others, so a uniform rank wastes parameter budget on unimportant layers while under-provisioning important ones. They switch to AdaLoRA (Zhang et al.). What does AdaLoRA actually do differently from plain fixed-rank LoRA?
AAdaLoRA replaces the low-rank matrices with full-rank dense updates at every layer, then prunes entire layers after training completes, rather than pruning individual parameters during training
BAdaLoRA keeps the same fixed rank at every layer but instead reduces the number of layers that receive any adapter at all, concentrating the full parameter budget onto a smaller subset of layers chosen at random
CAdaLoRA parameterizes each layer's update in singular-value-decomposition form and prunes the singular values, and their corresponding vectors, with the lowest importance scores over the course of training, dynamically shifting the rank budget toward the layers whose triplets prove most important, without needing to run an expensive exact SVD
DAdaLoRA removes the low-rank decomposition entirely and instead selects a random subset of the full weight matrix's individual entries to unfreeze and train directly, guaranteeing an identical parameter budget at every layer
Correct answer: .
AdaLoRA parameterizes each targeted weight matrix's update in the form of a singular value decomposition, splitting it into triplets of a singular value and its corresponding left and right singular vectors. As training proceeds, it computes an importance score for every triplet based on its contribution to the model's performance and prunes, meaning zeroes out, the singular values of the lowest-scoring triplets, which shrinks their effective rank contribution toward zero while leaving high-importance triplets at full strength. Because the update is already parameterized in this near-SVD form rather than as an arbitrary low-rank product, the method can approximate the effect of an exact SVD's pruning without repeatedly computing one, and the rank budget saved from unimportant layers is effectively redirected toward layers whose triplets keep proving important. The option describing full-rank dense updates with whole-layer pruning after training is wrong because AdaLoRA prunes at the fine-grained triplet level continuously during training, not whole layers after the fact, and never abandons the low-rank formulation for a dense one. The option describing a fixed rank with fewer adapted layers chosen at random is wrong because AdaLoRA still touches every targeted layer; what varies is each layer's effective rank, not whether the layer is adapted at all, and the reallocation is driven by importance scores rather than randomness. The option describing unfreezing random individual weight-matrix entries is wrong because AdaLoRA never abandons the low-rank, SVD-form update for direct entry-level training; that describes a different family of sparse fine-tuning methods entirely.
Source: Zhang et al., 'AdaLoRA: Adaptive Budget Allocation for Parameter-Efficient Fine-Tuning' (ICLR 2023, arXiv:2303.10512)
AI & LLM Engineering · Fine-tuning & Model Customisation · Card 033/055medium
A team wants to deploy a large pretrained language model at 4-bit precision for inference on limited-memory hardware, without doing any additional gradient-based training of the model, and needs the quantized model's outputs to stay close to the original full-precision model's outputs on held-out data. They use GPTQ (Frantar et al.). How does GPTQ actually decide how to quantize the model's weights?
AGPTQ quantizes each layer's weight matrix one column, or block of columns, at a time in sequence, using second-order Hessian-based information to choose the update order and to adjust the remaining unquantized weights so that the layer's output error, measured on a small calibration dataset, is minimized, with no gradient-based training of the model's weights themselves
BGPTQ trains a small set of new low-rank adapter matrices on top of the frozen full-precision weights, then quantizes only those adapter matrices to 4-bit while leaving the original weights at full precision
CGPTQ uniformly rounds every weight in the model to the nearest representable 4-bit value using a single global scale factor computed from the full weight distribution, without considering any layer's output error or using any calibration data
DGPTQ retrains the entire model from scratch at 4-bit precision using quantization-aware training, backpropagating gradients through simulated quantization operations across many epochs on the full pretraining corpus
Correct answer: .
GPTQ is a one-shot, post-training quantization method: it processes each layer's weight matrix column by column (or in small blocks), and for each step it uses second-order information, an approach adapted from the Optimal Brain Quantization solver, to decide which weights to quantize next and to update the still-unquantized weights so that the layer's output error on a small calibration dataset is minimized, since that error is quadratic and second-order information is the natural tool for minimizing it. No gradients are backpropagated through the model and no weights are retrained; the whole process runs once, using only a modest calibration set, and pushes accurate quantization down to the 4-bit range and below with far less accuracy loss than naive rounding. The option describing training new low-rank adapters and quantizing only those is wrong because GPTQ quantizes the model's existing weights directly; it does not introduce any new adapter matrices, which is instead the general idea behind LoRA-style methods, not GPTQ. The option describing a single global rounding rule with one scale factor and no calibration data is wrong because that describes naive round-to-nearest quantization, exactly the crude baseline GPTQ's per-layer, error-minimizing reconstruction was built to outperform. The option describing full retraining from scratch with quantization-aware training is wrong because GPTQ is specifically a one-shot post-training method that avoids any full retraining pass over the pretraining corpus, which is the far more expensive alternative it was designed to replace.
Source: Frantar et al., 'GPTQ: Accurate Post-Training Quantization for Generative Pre-trained Transformers' (arXiv:2210.17323)
AI & LLM Engineering · Fine-tuning & Model Customisation · Card 034/055easy
A team has one pretrained base model plus several independently fine-tuned versions of it, one for each of several different downstream tasks, and wants to combine or remove specific task capabilities in the base model without collecting any new training data or running any additional gradient-based training. They use task arithmetic (Ilharco et al.). What is a 'task vector' in this method, and what can be done with it?
AA task vector is the fine-tuned model's full set of weights saved separately from the base model; task vectors are combined by loading whichever fine-tuned checkpoint is needed for each task at inference time, one at a time
BA task vector is a text embedding of the task's name and description generated by the base model itself; combining task vectors means concatenating these embeddings into the model's prompt at inference time
CA task vector is the gradient computed during a single training step on the target task's data; task vectors are combined by summing gradients across tasks and applying one combined gradient update to the base model
DA task vector is the element-wise difference between a fine-tuned model's weights and the base model's weights before fine-tuning; task vectors from different tasks can be added together, or negated, directly in weight space to improve performance on multiple tasks at once or to reduce performance on an unwanted task, without any further training
Correct answer: .
A task vector is defined simply as the difference obtained by subtracting the pretrained base model's weights from the same model's weights after it has been fine-tuned on a particular task, giving a direction in weight space that points toward better performance on that task. Because this difference lives in the same weight space as the model itself, task vectors from different tasks can be added directly to the base model's weights to improve performance on multiple tasks at once, or negated and added to reduce performance on a task the fine-tuning targeted, all without touching any training data or running further gradient updates; the method's experiments also show that when four tasks are related by an analogy of the form 'A is to B as C is to D,' combining task vectors from three of them can improve performance on the fourth even though no data from that fourth task was used. The option describing separately stored full checkpoints loaded one at a time is wrong because that is simply keeping several ordinary fine-tuned models, with no arithmetic operation combining them in weight space at all. The option describing a text embedding of the task's description is wrong because a task vector is a weight-space quantity derived from actual fine-tuning, not a language embedding used inside a prompt. The option describing a single training-step gradient is wrong because a task vector is computed from the full difference after fine-tuning has completed, not from one intermediate gradient during training.
Source: Ilharco et al., 'Editing Models with Task Arithmetic' (ICLR 2023, arXiv:2212.04089)
AI & LLM Engineering · Fine-tuning & Model Customisation · Card 035/055easy
A team is training a reward model to grade a language model's multi-step solutions to math problems, and must decide whether to give the reward model feedback only on whether the final numeric answer is correct, or feedback on the correctness of each individual reasoning step along the way. Lightman et al. ('Let's Verify Step by Step') directly compared these two approaches, which they call outcome supervision and process supervision. What did they actually find?
AOutcome supervision, which only checks the final answer, significantly outperformed process supervision on their target math benchmark, because grading every intermediate step introduced too much noisy, low-value feedback for the reward model to learn from effectively
BProcess supervision, which grades every step for correctness, significantly outperformed outcome supervision on their target math benchmark, because it gives more precise feedback about exactly where an error occurs and more directly rewards the model for following a step-by-step chain of reasoning a human would endorse
CThe two approaches performed statistically indistinguishably on their target math benchmark, since a wrong final answer almost always comes from an identifiable single wrong step, so outcome supervision already captures nearly all the same signal
DProcess supervision could not be evaluated at all on their target math benchmark, because no human labelers were willing to grade individual reasoning steps, forcing the study to rely entirely on outcome supervision instead
Correct answer: .
Lightman et al. trained and compared an outcome-supervised reward model, which learns only from whether a solution's final answer was correct, against a process-supervised reward model, which learns from step-level human feedback labeling each individual step in a solution as correct, incorrect, or ambiguous, using their released PRM800K dataset of roughly 800,000 step-level labels. They found process supervision significantly outperformed outcome supervision on their representative subset of the MATH benchmark, with their best process-supervised model solving about 78% of problems in that test set, because process supervision pinpoints exactly where a reasoning chain goes wrong rather than only judging the destination, and it more directly rewards a model for producing a chain of reasoning a human would actually endorse step by step. The option claiming outcome supervision won because step-level feedback is too noisy is wrong because it states the opposite of the paper's central empirical result. The option claiming the two performed indistinguishably because a wrong answer implies a single identifiable wrong step is wrong because solutions can reach a wrong final answer through multiple compounding errors, or reach a correct final answer despite a flawed step, so outcome supervision does not capture the same signal as fine-grained step labels. The option claiming process supervision could not be evaluated because no labelers would grade individual steps is wrong because the study specifically collected and released hundreds of thousands of step-level human labels to make this exact comparison possible.
Source: Lightman et al., 'Let's Verify Step by Step' (arXiv:2305.20050)
AI & LLM Engineering · Fine-tuning & Model Customisation · Card 036/055hard
During the RL fine-tuning stage of a standard RLHF pipeline, PPO (Schulman et al.) is used to update the policy against the reward model's scores. A single batch of sampled responses can sometimes produce a very large estimated advantage for some responses, which naively would push the policy's probability ratio for those responses far from 1 in one update. What does PPO's clipped surrogate objective specifically do to prevent this?
AIt discards any training batch containing a response whose estimated advantage exceeds a fixed threshold, training only on batches where every response's advantage is small enough to be considered safe
BIt adds a KL-divergence penalty term, scaled by a tunable coefficient, to the reward itself before the advantage is computed, discouraging the policy from moving far from a frozen reference policy at every single token
CIt clips the probability ratio between the new and old policy for each sampled action to a fixed range around 1 before multiplying it by the estimated advantage, then takes the minimum of the clipped and unclipped versions of that product, so a ratio that has moved far enough in the direction that would exploit the advantage stops contributing extra objective value beyond that range
DIt performs a full second-order, trust-region-constrained optimization at every update, exactly as TRPO does, solving a constrained quadratic program at each step to guarantee the KL divergence between the old and new policy stays under a fixed bound
Correct answer: .
PPO's clipped surrogate objective computes the probability ratio between the current policy and the policy that generated the sampled data, multiplies that ratio by the estimated advantage as an ordinary policy-gradient surrogate would, but also computes a second version of that product using the ratio clipped to a fixed range around 1, and then takes the minimum of the unclipped and clipped versions as the actual objective term. The effect is that once the ratio moves far enough in the direction that would increase the objective by exploiting a large advantage, the clipped term caps how much further objective value can be gained from continuing to push in that direction, removing the incentive for a single update to move the policy too far, which approximates the stabilizing effect of a trust region without requiring one to be solved explicitly. The option describing discarding whole batches based on a fixed advantage threshold is wrong because clipping is applied per sampled action directly inside the objective's math, not as a batch-level filtering rule applied before training. The option describing a KL-divergence term added to the reward is wrong because that is a separate mechanism, a per-token penalty against a frozen reference policy applied to the reward signal itself, which is distinct from the ratio-clipping operation that PPO applies directly to its policy-gradient surrogate objective. The option describing a full second-order constrained optimization exactly like TRPO is wrong because PPO's entire motivation, per Schulman et al., is replacing TRPO's expensive constrained quadratic program with this much simpler first-order clipping trick that only requires ordinary gradient-based optimization.
Source: Schulman et al., 'Proximal Policy Optimization Algorithms' (arXiv:1707.06347)
AI & LLM Engineering · Fine-tuning & Model Customisation · Card 037/055easy
A team is investigating why a language model fine-tuned via RLHF consistently scores higher on its reward model, and consequently gets judged as more 'helpful,' than a purely supervised-fine-tuned baseline. Singhal et al. ('A Long Way to Go: Investigating Length Correlations in RLHF') investigated this specifically for response length across several open-domain tasks. What did they find primarily drives this reward improvement?
AResponse length itself was the single largest driver: reward scores were strongly correlated with output length, RLHF consistently produced longer outputs than the supervised-fine-tuned baseline, and a reward function based on length alone reproduced most of the downstream improvement standard RLHF achieved, tracing the root cause to reward models that are non-robust and easily swayed by length-related patterns in their preference training data
BThe improvement was found to be entirely unrelated to length; instead, it was driven by the RL fine-tuning stage specifically improving factual accuracy, which longer responses only happened to correlate with by coincidence
CThe improvement came from RLHF making responses shorter and more concise on average, since human preference-data labelers in their study consistently rated shorter responses as more helpful across every one of the settings tested
DThe study found the reward improvement varied unpredictably across settings with no identifiable common cause, and explicitly ruled out length as a contributing factor in every one of the settings they tested
Correct answer: .
Singhal et al. ran both observational and interventional analyses across several open-domain RLHF settings, including dialogue and web question answering, and found that response length was the single largest driver of the reward gains RLHF produces: reward scores correlated strongly with length, RLHF consistently pushed output length up relative to the supervised-fine-tuned starting point, and even a reward signal based purely on length, with no other quality signal at all, reproduced most of the downstream improvement that standard RLHF achieved. They traced this to the reward models themselves being non-robust and easily swayed by length-related patterns present in the human preference data used to train them, rather than to any genuine, length-independent improvement in response quality. The option attributing the gain to improved factual accuracy that merely happens to correlate with length is wrong because the paper's interventional experiments, including a length-only reward, isolate length itself as the driver rather than treating it as an incidental correlate of some other improvement. The option claiming RLHF made responses shorter is wrong because the study found the opposite: RLHF increased length relative to the supervised-fine-tuned baseline. The option claiming no identifiable common cause was found and that length was explicitly ruled out is wrong because the paper's central, repeated finding across settings was precisely that length was a major, identifiable common driver.
Source: Singhal et al., 'A Long Way to Go: Investigating Length Correlations in RLHF' (arXiv:2310.03716)
AI & LLM Engineering · Fine-tuning & Model Customisation · Card 038/055medium
A team wants to improve a language model's instruction-following ability through iterative preference training, without depending on a separately trained external reward model or ongoing human preference labeling for each new round. They adopt Self-Rewarding Language Models (Yuan et al.). How does this method actually generate its own training signal in each iteration?
AThe current model is frozen entirely; a separate large external model, unrelated to the model being trained, is used purely as a judge to score responses, and DPO is applied using only that external judge's scores
BThe same model being trained generates candidate responses to self-created instructions, then uses LLM-as-a-judge prompting on itself to score and rank those candidates into preference pairs, which are used to train the model via DPO; the resulting improved model is then used to generate the next iteration's data, so instruction-following ability and self-judging ability both improve together across iterations
CThe model's weights are duplicated into two frozen, never-updated copies that debate a response's quality with each other in natural language over several rounds, and a fixed majority-vote rule between the two copies determines the preference label with no model updates at any point
DPreference labels come entirely from a static, pre-existing human preference dataset collected once before training begins, with each iteration re-training on that exact same fixed dataset without generating any new data or new judgments
Correct answer: .
Self-Rewarding Language Models use the same model being trained for two roles at once: it generates candidate responses to instructions, including instructions it creates for itself, and it also acts as its own judge through LLM-as-a-judge prompting, scoring and ranking its own candidate responses to build preference pairs. Those self-generated preference pairs are then used to train the model further via DPO, and the resulting, improved model is used to generate the next iteration's instructions, responses, and judgments, so that across iterations both the model's instruction-following ability and the quality of its own self-judgments improve together, without ever depending on a separately trained external reward model or fresh human labels after the first iteration. The option describing a frozen model judged purely by an unrelated external model is wrong because the defining feature of this method is that the same evolving model supplies its own rewards; introducing an external, unrelated judge model would defeat the point of self-rewarding entirely. The option describing two frozen copies debating with a fixed majority-vote rule is wrong because nothing in that setup involves any model being updated or improving across iterations, whereas Self-Rewarding Language Models specifically retrain the model each round and observe its self-judging ability improve as a result. The option describing training only on a static pre-existing human dataset is wrong because the entire mechanism depends on generating new self-created instructions, responses, and self-judgments at every iteration rather than reusing one fixed dataset.
Source: Yuan et al., 'Self-Rewarding Language Models' (arXiv:2401.10020)
AI & LLM Engineering · Fine-tuning & Model Customisation · Card 039/055easy
A team has already spent significant compute pretraining a large dense transformer model and wants to scale up its capacity further by converting to a sparse mixture-of-experts model, without wasting that sunk pretraining cost by starting the mixture-of-experts model from a random initialization. They use sparse upcycling (Komatsuzaki et al.). What does this method actually do to the existing dense checkpoint?
AIt discards the dense checkpoint's feed-forward layers entirely, replacing them with newly and randomly initialized mixture-of-experts layers, while keeping only the attention layers from the original dense checkpoint
BIt trains a brand-new sparsely-gated mixture-of-experts model completely from scratch on the same pretraining data the dense model originally used, using the dense model's final validation loss only as a stopping-point benchmark to compare against
CIt converts the dense model into a mixture-of-experts model by pruning away most of its feed-forward parameters, keeping only a single most-important sparse subset of weights and permanently discarding the rest, without adding any new components
DIt clones the dense checkpoint's existing feed-forward layer multiple times to create the initial set of experts for each mixture-of-experts layer, adds a newly and randomly initialized routing network in front of each such layer, and then continues pretraining so the cloned experts gradually specialize while the router learns to route tokens between them
Correct answer: .
Sparse upcycling reuses an already-pretrained dense checkpoint's sunk training cost by cloning its existing feed-forward layer several times to form the starting set of experts inside each new mixture-of-experts layer, and adding a freshly, randomly initialized routing network in front of each such layer to decide which tokens go to which expert. Pretraining then continues from this initialization, during which the identically-cloned experts gradually diverge and specialize on different kinds of inputs while the router learns sensible routing decisions, and the paper reports that upcycled models trained this way, using roughly half the compute of the original dense pretraining run, outperform their dense counterparts on benchmarks such as SuperGLUE and ImageNet. The option describing discarding the feed-forward layers and randomly reinitializing the mixture-of-experts layers is wrong because the entire point of upcycling is reusing, not discarding, the dense checkpoint's already-trained feed-forward weights as the experts' starting point. The option describing training a brand-new model from scratch, using the dense model only as a comparison benchmark, is wrong because that describes exactly the sunk-cost waste sparse upcycling was designed to avoid; the dense weights are directly reused as initialization, not merely referenced afterward. The option describing pruning down to a single sparse subset of weights with nothing added is wrong because upcycling creates multiple full expert copies plus a new router, the opposite of discarding weights down to one surviving subset.
Source: Komatsuzaki et al., 'Sparse Upcycling: Training Mixture-of-Experts from Dense Checkpoints' (ICLR 2023, arXiv:2212.05055)
AI & LLM Engineering · Fine-tuning & Model Customisation · Card 040/055hard
A team has already trained several separate bottleneck adapter modules, each one specialized for a different individual task, on top of a shared frozen pretrained model, and now wants to combine the useful task-specific knowledge from all of them for a new target task, without damaging or retraining any of the original individual adapters. They use AdapterFusion (Pfeiffer et al.). How does this method actually combine the existing task adapters?
AIt averages all of the existing task adapters' weights together into a single new adapter with the same size as any one original adapter, then fine-tunes that averaged adapter further on the target task's data
BIt picks exactly one of the existing task adapters, chosen by whichever one achieves the highest validation accuracy on a small sample of the target task's data, and discards the rest before proceeding
CIn a separate composition stage, it keeps every existing task adapter's parameters completely frozen and trains a new attention-based fusion module on top of them, which learns to dynamically weight and combine each frozen adapter's contribution differently at each layer, as a function of the target task's own input, without modifying any original adapter
DIt merges the several task adapters by concatenating their weight matrices end-to-end into one much larger adapter, whose size grows linearly with the number of task adapters combined, and trains that entire concatenated block jointly from scratch
Correct answer: .
AdapterFusion works in two separate stages: a knowledge-extraction stage where individual task adapters are trained as usual, one per task, and a later knowledge-composition stage where all of those existing task adapters are kept completely frozen while a new attention-based fusion module is trained on top of them for the target task. That fusion module learns to dynamically weight each frozen adapter's contribution differently at different layers, as a function of the target task's own input at each point, so the composition can draw different amounts of knowledge from different adapters depending on the layer and the input, all without ever modifying the original adapters' already-learned parameters, which is why the paper describes the composition as non-destructive. The option describing averaging all the adapters' weights into one new adapter and fine-tuning that average is wrong because averaging would blend and dilute each adapter's distinct specialized knowledge into one static combination rather than dynamically weighting each one's contribution per layer and per input. The option describing selecting a single best-performing adapter and discarding the rest is wrong because the entire purpose of AdapterFusion is combining knowledge from multiple adapters together, not choosing a single winner and throwing away the others. The option describing concatenating the adapters' weight matrices into one much larger block trained jointly from scratch is wrong because that would abandon each adapter's already-learned frozen knowledge and let parameter count grow with the number of adapters, contrary to AdapterFusion's frozen, non-destructive composition approach.
Source: Pfeiffer et al., 'AdapterFusion: Non-Destructive Task Composition for Transfer Learning' (EACL 2021, arXiv:2005.00247)
AI & LLM Engineering · Fine-tuning & Model Customisation · Card 041/055easy
A team wants to fine-tune all of a large model's parameters, not with a parameter-efficient method like LoRA, across multiple GPUs, but plain data parallelism would require every single GPU to separately hold a full redundant copy of the model's parameters, gradients, and optimizer states, which quickly exceeds available memory as model size grows. They use ZeRO, the Zero Redundancy Optimizer (Rajbhandari et al.). What does ZeRO actually do to address this?
AZeRO partitions the optimizer states, gradients, and, in its most aggressive stage, the model parameters themselves across the participating GPUs, so each GPU only stores and updates its own partition rather than a full redundant copy of everything, eliminating the memory redundancy of standard data parallelism while still functioning as data-parallel training
BZeRO converts the entire model to a parameter-efficient method by inserting small trainable low-rank adapter matrices into every layer and freezing the original weights, reducing the number of trainable parameters that need to be stored on any single GPU
CZeRO reduces memory use by quantizing every parameter, gradient, and optimizer state to 4-bit precision throughout training, trading numerical precision for memory savings while still keeping a full redundant copy of everything on each GPU
DZeRO eliminates the need for any GPU to store gradients or optimizer states at all by recomputing them from scratch on demand at every single training step, entirely from the forward-pass activations
Correct answer: .
ZeRO addresses the memory redundancy of standard data-parallel training by partitioning the model's state across the participating GPUs instead of replicating all of it on every GPU: its first stage partitions only the optimizer states, its second stage additionally partitions the gradients, and its third and most aggressive stage additionally partitions the model parameters themselves, so each GPU holds and updates only its own shard of whichever categories are partitioned rather than a full redundant copy of everything. This lets memory use scale down as more GPUs are added while the training still behaves as ordinary data-parallel training overall, which is what allowed models with hundreds of billions to trillions of parameters to be trained on hardware that could never hold a full redundant copy of everything on every device. The option describing inserting low-rank adapter matrices and freezing the original weights is wrong because that describes a parameter-efficient fine-tuning method like LoRA, which the scenario explicitly rules out since the team wants to fine-tune all of the model's parameters, and ZeRO itself does not touch the model's architecture at all. The option describing 4-bit quantization while still keeping a full redundant copy on every GPU is wrong on both counts: ZeRO does not quantize anything, and its defining feature is specifically eliminating the full redundant copy on every GPU, not preserving it. The option describing recomputing gradients and optimizer states from activations at every step is wrong because ZeRO stores each GPU's own partitioned shard of that state rather than discarding and recomputing it; recomputing activations to save memory is a different, unrelated technique called activation checkpointing.
Source: Rajbhandari et al., 'ZeRO: Memory Optimizations Toward Training Trillion Parameter Models' (arXiv:1910.02054, SC20)
AI & LLM Engineering · Fine-tuning & Model Customisation · Card 042/055medium
A team has three independently fine-tuned versions of the same base model, one per task, and wants to merge them into a single multi-task model by combining their task vectors in weight space. Plain task arithmetic (simple addition of the task vectors) gives disappointing results because many individual weight entries received updates of opposite sign across the three tasks, and many other entries only changed by a tiny, likely-noisy amount in any given task. They switch to TIES-Merging (Yadav et al.) instead. What does TIES-Merging actually do differently before averaging the task vectors together?
AIt trains a new, larger adapter module on top of the three frozen task vectors and learns a continuous attention-based mixing weight for each one, re-optimized separately for every new input at inference time
BFor each task vector it first trims away entries that changed only a small amount in magnitude, then elects a single sign (positive or negative) per parameter by a magnitude-weighted vote across the task vectors, and finally averages together only the entries from task vectors whose sign agrees with that elected sign
CIt converts each task vector into a short natural-language description of what the task changed, then re-derives a new combined task vector purely by prompting the base model with all three descriptions at once
DIt discards two of the three task vectors entirely, keeping only the one whose fine-tuned model scored highest on a held-out validation set, and applies that single task vector unmodified
Correct answer: .
TIES-Merging addresses two specific sources of interference that plain task arithmetic ignores: redundant, small-magnitude parameter changes, and disagreement in sign across task vectors on the same parameter. Its three-step pipeline first trims each task vector by keeping only the top fraction of entries by absolute magnitude and zeroing the rest, treating small changes as likely noise; it then elects a single dominant sign per parameter by a magnitude-weighted vote across all the task vectors being merged; and finally it performs a disjoint merge, averaging together only the entries whose sign matches the elected sign for that parameter while discarding conflicting entries entirely. This trim-elect-merge sequence is what lets TIES-Merging recover much more of joint multi-task performance than naively summing task vectors. The option describing a trained attention-based mixing module re-optimized per input is wrong because that describes AdapterFusion-style composition of adapter modules at inference time, not TIES-Merging's one-time, gradient-free operation directly on task vectors in weight space before any deployment. The option describing converting task vectors into natural-language descriptions and re-prompting the base model is wrong because TIES-Merging never leaves weight space or touches the model's text interface at all; it operates purely on the numerical difference vectors. The option describing keeping only the single best-validated task vector and discarding the rest is wrong because that abandons the entire goal of combining multiple tasks' capabilities into one model, which is exactly what TIES-Merging's sign-election and disjoint-merge steps are designed to preserve from all the inputs.
Source: Yadav, Tam, Choshen, Raffel & Bansal, 'TIES-Merging: Resolving Interference When Merging Models' (NeurIPS 2023, arXiv:2306.01708)
AI & LLM Engineering · Fine-tuning & Model Customisation · Card 043/055medium
A team wants a DPO-style preference-alignment method, trained directly on chosen/rejected response pairs with no separate reward model and no PPO loop, but that also avoids keeping a frozen reference-model copy loaded during training, unlike DPO itself, and defines its implicit reward purely from the policy model's own output probabilities rather than from any odds-ratio term added to a supervised fine-tuning loss. They adopt SimPO (Meng, Xia & Chen). What is SimPO's reward formulation and why does it specifically need to be length-normalized?
ASimPO defines the implicit reward for a response as its average per-token log-probability under the policy being trained, length-normalized so that longer responses are not automatically favored simply for having more tokens over which log-probabilities are summed
BSimPO defines the reward as the raw, un-normalized sum of per-token log-probabilities under the policy, and length-normalization refers only to truncating every training response to the same fixed token count before any training begins
CSimPO defines the reward using a frozen reference model's probability ratio exactly as DPO does, and length-normalization refers to rescaling that frozen reference model's own parameter count relative to the policy model being trained
DSimPO defines the reward as the number of human preference votes a response received during data collection, length-normalized by dividing that vote count by the number of words in the response
Correct answer: .
SimPO's implicit reward for a candidate response is the average log-probability per token that the policy being trained assigns to that response, rather than the raw summed log-probability over all of its tokens. This average, length-normalized form matters precisely because an un-normalized sum of per-token log-probabilities (which are negative numbers) tends to grow more negative as a response gets longer, meaning a policy could appear to prefer shorter responses or exploit length in ways unrelated to actual quality; normalizing by length keeps the reward comparable across responses of different lengths and keeps it aligned with the same per-token likelihood that the model actually uses to generate text, which is also what lets SimPO drop DPO's frozen reference model entirely, since the reward is computed purely from the policy's own probabilities with nothing to compare against. The option describing an un-normalized raw sum with length-normalization meaning fixed-length truncation is wrong because SimPO's normalization is a per-token averaging of the reward itself, not a preprocessing step that truncates training data to a fixed token count. The option describing a frozen reference model's probability ratio exactly as in DPO is wrong because SimPO's entire point is eliminating that reference model dependency, replacing it with a reward computed solely from the policy being trained. The option describing counting human preference votes divided by word count is wrong because SimPO's reward is a property of the model's own output probabilities computed during training, not a tally of raw human votes from data collection.
Source: Meng, Xia & Chen, 'SimPO: Simple Preference Optimization with a Reference-Free Reward' (NeurIPS 2024, arXiv:2405.14734)
AI & LLM Engineering · Fine-tuning & Model Customisation · Card 044/055easy
A team is distilling a large machine-translation model into a much smaller student model. Standard (word-level) knowledge distillation trains the student to match the teacher's softened probability distribution over the vocabulary at each individual token position in the reference translation. Kim & Rush instead propose sequence-level knowledge distillation. How does this approach differ in what the student is actually trained on?
AIt is identical to word-level distillation except that the softmax temperature used to soften the teacher's per-token probability distribution is lowered rather than raised
BIt trains the student only on the original human reference translations, with the teacher model's predictions not used anywhere in the training process
CIt has the teacher model produce a single averaged probability distribution across the entire training corpus in advance, and the student is trained to match that one corpus-wide distribution at every token position
DIt runs beam search with the teacher model over the training inputs to generate the teacher's own full output sequences, then trains the student with ordinary cross-entropy on those teacher-generated sequences in place of the original reference translations
Correct answer: .
Sequence-level knowledge distillation replaces the training targets themselves: the teacher model is run with beam search over the training inputs to generate its own complete output sequences, and the student is then trained with ordinary cross-entropy to reproduce those teacher-generated sequences rather than the original human reference translations. This shifts the distillation signal from matching the teacher's per-token soft probability distribution at each position (word-level distillation) to approximating the teacher's full-sequence behavior as a whole, which Kim & Rush found could be combined with weight pruning to shrink translation models by up to roughly 13x with only a small drop in quality. The option describing only a lowered softmax temperature is wrong because that is simply a variant of word-level distillation's existing soft-label mechanism, not the sequence-level approach, which changes the training data itself rather than how sharply a per-token distribution is softened. The option describing training only on human reference translations with no teacher involvement is wrong because the teacher's beam-search output sequences are exactly what the student is trained on; the original references are not used in this scheme. The option describing a single averaged corpus-wide distribution applied at every position is wrong because sequence-level distillation generates a distinct output sequence from the teacher for each individual training input, not one global distribution reused everywhere.
Source: Kim & Rush, 'Sequence-Level Knowledge Distillation' (EMNLP 2016, arXiv:1606.07947)
AI & LLM Engineering · Fine-tuning & Model Customisation · Card 045/055hard
A team wants to extend a pretrained model's usable context window from 4k to a much larger size, such as 100k tokens, by further fine-tuning it, but standard full self-attention fine-tuning at that context length is far too expensive in compute and memory. They adopt LongLoRA (Chen et al.) and its shifted sparse attention (S2-Attn) mechanism during training. How does S2-Attn actually reduce the cost of attention during this fine-tuning, and what keeps information flowing between the separate pieces it creates?
AIt replaces self-attention entirely with a fixed sliding window of a few hundred nearby tokens for every head, permanently discarding any ability to attend across the full extended context even after fine-tuning finishes
BIt splits the long context into several smaller groups and computes full attention only within each group independently, while shifting the tokens by half a group's size for half of the attention heads, so that information still flows across the boundaries between neighboring groups
CIt keeps full dense attention across the entire long context unchanged during fine-tuning, and achieves its speedup purely by quantizing the attention score matrix to 8-bit integers
DIt discards the attention mechanism during fine-tuning altogether and instead trains a separate recurrent module to summarize the long context into a single fixed-size vector passed to the transformer
Correct answer: .
LongLoRA's shifted sparse attention splits the long input context into several smaller groups and computes ordinary full attention only within each group independently, which is far cheaper than attending across the entire long context at once; to prevent this from isolating each group entirely, half of the attention heads have their tokens shifted by half a group's size before grouping, so those heads' group boundaries land in different places than the unshifted heads' boundaries, letting information flow across what would otherwise be a hard cutoff between neighboring groups. This mechanism is used only to make the fine-tuning phase itself cheap (it can be switched off at inference, where normal full attention is used), and combined with making LoRA's embedding and normalization layers trainable, it let the authors extend Llama 2 7B from a 4k to a 100k context on a single 8-GPU machine. The option describing a permanently fixed sliding window with no cross-window attention ever is wrong because S2-Attn's shifting mechanism specifically exists to preserve cross-group information flow, and it is optional at inference rather than a permanent restriction. The option describing unchanged dense attention sped up purely through 8-bit quantization is wrong because S2-Attn's saving comes from restricting attention to within smaller groups, not from quantizing the attention computation itself. The option describing replacing attention with a recurrent summarization module is wrong because LongLoRA keeps the transformer's attention mechanism throughout, only changing which tokens attend to which others during the fine-tuning phase.
Source: Chen et al., 'LongLoRA: Efficient Fine-tuning of Long-Context Large Language Models' (ICLR 2024, arXiv:2309.12307)
AI & LLM Engineering · Fine-tuning & Model Customisation · Card 046/055easy
A team wants a model to more consistently exhibit a specific behavior, such as a more honest or less sycophantic response style, and considers two options: fine-tuning the model's weights on examples of the desired behavior, or activation steering, a representation-engineering technique that computes a 'steering vector' from the difference in internal activations between contrasting prompts and adds it into the model's residual stream at a chosen layer during generation. What is the key practical difference between activation steering and fine-tuning for this purpose?
AActivation steering requires collecting a labeled preference dataset of thousands of chosen/rejected response pairs and running a full reinforcement-learning loop, exactly like RLHF, whereas fine-tuning requires none of that
BActivation steering permanently overwrites the model's weight matrices with the steering vector added in, so once applied it cannot be turned off without re-downloading the original weights
CActivation steering changes no model weights at all; it modifies only the activations flowing through the network at inference time, so the behavioral shift can be adjusted or switched off per request simply by changing or omitting the added vector, without any training run
DActivation steering is mathematically identical to LoRA, since both add a learned low-rank update to specific weight matrices before the model is deployed
Correct answer: .
Activation steering is a representation-engineering technique that never touches the model's weights at all: a steering vector is typically computed in advance as the average difference in residual-stream activations between pairs of contrasting prompts (for example, prompts eliciting honest versus dishonest responses), and that fixed vector is then added into the residual stream at a chosen layer during generation. Because the base weights are untouched, the behavioral shift is entirely a property of inference-time computation, which means it can be scaled up or down, swapped for a different steering vector, or dropped entirely on a per-request basis with no retraining, unlike a fine-tuned model where the behavior change is baked permanently into the weights. The option describing a labeled preference dataset and a full RLHF-style reinforcement-learning loop is wrong because activation steering's vectors are typically derived from a small set of contrasting prompts and simple activation averaging, not from reward modeling or policy-gradient optimization. The option describing permanently overwriting weight matrices is wrong because it describes something closer to merging a fine-tuned update into the model, which is the opposite of activation steering's inference-time-only intervention. The option claiming activation steering is mathematically identical to LoRA is wrong because LoRA adds a learned low-rank update to weight matrices that persists in the deployed model, whereas activation steering adds a vector to intermediate activations at inference time without altering any weight matrix.
Source: Turner et al., 'Steering Language Models With Activation Engineering' (arXiv:2308.10248, 2023); Zou et al., 'Representation Engineering: A Top-Down Approach to AI Transparency' (arXiv:2310.01405, 2023)
AI & LLM Engineering · Fine-tuning & Model Customisation · Card 047/055medium
A team has a hub of many separately trained LoRA modules, each specialized for a different past task, and receives a brand-new task with only a handful of labeled examples and no budget for gradient-based training. They use LoraHub (Huang et al.) to dynamically combine existing LoRA modules for this new task. How does LoraHub decide how much weight to give each existing LoRA module in the combination?
AIt runs standard gradient-descent fine-tuning of a new combination layer on the few available examples, backpropagating through all of the existing LoRA modules simultaneously to learn each module's weight
BIt always combines every LoRA module in the hub with exactly equal, fixed weight, regardless of which new task is being solved or how many examples are available
CIt discards the few available examples and instead asks a separate large language model to read each LoRA module's original task description and assign a weight based purely on that text, with no evaluation on the new task's own examples
DIt searches for the per-module combination coefficients using a gradient-free black-box optimization procedure, evaluating candidate combinations directly against the few available examples and refining the coefficients over a handful of inference steps without computing gradients through the LoRA modules
Correct answer: .
LoraHub combines existing LoRA modules by searching for a set of per-module combination coefficients using a gradient-free black-box optimization procedure, specifically Covariance Matrix Adaptation Evolution Strategy (CMA-ES), which proposes candidate coefficient settings, evaluates how well the resulting combined LoRA performs directly on the handful of available examples from the new task, and iteratively refines the coefficients over a small number of inference steps, all without ever computing gradients through the LoRA modules themselves or requiring any additional model parameters. This is what makes LoraHub usable in genuinely low-resource, few-shot settings where a full gradient-based training run is not an option. The option describing standard gradient-descent fine-tuning of a new combination layer, backpropagating through all the LoRA modules, is wrong because that is exactly the gradient-based training LoraHub is designed to avoid needing for the new task. The option describing always using equal, fixed weights regardless of task is wrong because LoraHub's coefficients are searched and adapted specifically for each new task's own few examples, not held fixed. The option describing weighting modules purely from a language model reading their text descriptions, without ever evaluating on the new task's examples, is wrong because LoraHub's coefficient search is driven by actual performance on the few available labeled examples, not by a purely textual judgment of module descriptions.
Source: Huang, Liu, Lin, Pang, Du & Lin, 'LoraHub: Efficient Cross-Task Generalization via Dynamic LoRA Composition' (COLM 2024, arXiv:2307.13269)
AI & LLM Engineering · Fine-tuning & Model Customisation · Card 048/055easy
A team is fine-tuning a large model and wants a parameter-efficient method that trains dramatically fewer parameters than standard LoRA, since even LoRA's trainable matrices become a meaningful storage cost when the team needs a separate adapter for thousands of customers. They adopt VeRA (Vector-based Random Matrix Adaptation, Kopiczko et al.). How does VeRA reduce trainable parameters so much further than ordinary LoRA, which already trains a distinct pair of low-rank matrices per layer?
AIt removes the low-rank adaptation idea entirely and instead fine-tunes only a single scalar learning-rate multiplier per layer, applied to the base model's existing frozen weights
BIt shares one single pair of frozen, randomly initialized low-rank matrices across every layer being adapted, and trains only small per-layer scaling vectors that rescale those shared frozen matrices differently at each layer
CIt trains a separate full-rank weight update for every layer, which is actually more parameters than LoRA, but compresses the result afterward with 4-bit quantization before saving it to disk
DIt eliminates adaptation at inference time altogether by having every layer reuse the exact same trained low-rank matrices from LoRA with no scaling or modification whatsoever
Correct answer: .
VeRA's core idea is to stop training a distinct pair of low-rank matrices for every layer the way ordinary LoRA does, and instead share a single pair of frozen, randomly initialized low-rank matrices across all of the layers being adapted. The only parameters actually trained per layer are small scaling vectors that rescale those shared, frozen random matrices differently at each layer, which lets VeRA reach roughly an order of magnitude or more fewer trainable parameters than LoRA while reporting comparable downstream performance on benchmarks like GLUE and instruction-tuned language models, which matters directly for a team needing to store a separate lightweight adaptation per customer. The option describing a single scalar learning-rate multiplier per layer applied to frozen base weights is wrong because that would not add any task-specific directional update at all, just a uniform rescaling of the base model's existing weights, which is not what VeRA's trainable scaling vectors do. The option describing training a separate full-rank update per layer and compressing it afterward with quantization is wrong because that increases rather than decreases trainable parameters before any compression, the opposite of VeRA's design. The option describing every layer reusing LoRA's own trained matrices with no scaling is wrong because VeRA's matrices are randomly initialized and kept entirely frozen, never trained, with only the per-layer scaling vectors actually learned.
AI & LLM Engineering · Fine-tuning & Model Customisation · Card 049/055hard
A team wants a parameter-efficient fine-tuning method that, unlike LoRA's structured low-rank weight update, instead learns an arbitrary, sparse set of individual weight changes scattered anywhere across the pretrained model, so that per-task storage only needs to record the small number of modified weight positions and their values. They adopt diff pruning (Guo, Rush & Kim). How does diff pruning actually produce this sparse per-task update, and what does the paper report about how sparse it can be while matching full fine-tuning?
AIt restricts weight changes to a small number of hand-picked layers chosen in advance by the practitioner, applying full dense fine-tuning only within those chosen layers and none elsewhere
BIt first fine-tunes the entire model fully and only afterward prunes away weight changes below a fixed hand-set magnitude threshold, with no learned penalty guiding which positions are pruned during training
CIt learns a per-task 'diff' vector added to the frozen pretrained weights, adaptively pruning it toward sparsity during training using a differentiable approximation to the L0-norm penalty, and reports matching finetuned performance on GLUE while modifying only about 0.5% of the pretrained model's parameters per task
DIt replaces the pretrained model's weights entirely with a newly initialized sparse network trained from scratch on the target task, discarding the original pretrained values at every modified position
Correct answer: .
Diff pruning learns a task-specific 'diff' vector that is added on top of the frozen pretrained weights, and during training this diff vector is pushed toward sparsity using a differentiable approximation to the L0-norm penalty, which directly encourages most of its entries to become exactly zero rather than relying on any separately applied threshold after the fact. Because only the nonzero positions and their values need to be stored per task, while the shared pretrained weights are amortized across every task, diff pruning can match fully fine-tuned baselines on the GLUE benchmark while modifying only about 0.5% of the pretrained model's parameters for each task. The option describing hand-picked layers chosen in advance for dense fine-tuning is wrong because diff pruning's sparsity pattern is learned automatically by the L0 penalty during training, scattered across the model rather than confined to a small number of preselected layers. The option describing full fine-tuning followed by threshold-based pruning afterward is wrong because diff pruning's sparsity is shaped during training itself by the differentiable L0 penalty, not discovered by pruning a fully fine-tuned model post hoc with a fixed threshold. The option describing a newly initialized sparse network trained from scratch, discarding pretrained values, is wrong because diff pruning adds its sparse diff vector on top of the existing frozen pretrained weights, which remain intact and are never replaced.
Source: Guo, Rush & Kim, 'Parameter-Efficient Transfer Learning with Diff Pruning' (ACL 2021, arXiv:2012.07463)
AI & LLM Engineering · Fine-tuning & Model Customisation · Card 050/055easy
A team has a long, carefully engineered system prompt that reliably improves a model's behavior on a task, but it eats into the context window and must be re-sent with every request. They want to 'bake' the prompt's effect into the model's weights so it behaves the same way even without the prompt present. Following Snell et al.'s context distillation, how is this actually done?
AThe system prompt's exact text is appended as a hidden prefix to the model's vocabulary embedding table, so the model always implicitly reads it even when it is not included in the visible input
BThe same model, run once with the system prompt included (acting as the teacher) and once without it (acting as the student), is distilled by training the student, unprompted version to match the teacher, prompted version's output distribution on matching inputs, so the prompt's effect gets internalized into the student's weights
CThe system prompt is converted into a set of additional attention heads inserted permanently into every transformer layer, with the prompt's text never used again after this one-time architectural change
DThe model is fine-tuned using ordinary supervised fine-tuning directly on the system prompt's own text as the training target, with no teacher-student distillation or comparison between prompted and unprompted outputs involved at all
Correct answer: .
Context distillation treats the same base model as both teacher and student: run with the system prompt included, it acts as the teacher, producing an output distribution already shaped by the prompt's instructions; run without the prompt, the same model acts as the student. Training the student version to match the teacher version's output distribution on matching inputs transfers the prompt's behavioral effect directly into the student's weights, so the resulting model behaves as though the prompt were still present even when it is no longer included in the input, freeing up context window space and avoiding repeated prompt tokens on every request. The option describing appending the prompt's text as a hidden prefix in the embedding table is wrong because that still keeps the prompt's content present and consuming resources in some form, rather than removing it and relying on a distilled weight change. The option describing inserting new permanent attention heads derived from the prompt is wrong because context distillation changes the model's existing weights through an ordinary training signal, not by architecturally adding new heads. The option describing supervised fine-tuning directly on the prompt's own text with no teacher-student comparison is wrong because context distillation's defining mechanism is matching the prompted (teacher) and unprompted (student) versions of the same model's output distributions, not training on the prompt text itself as a target.
Source: Snell, Klein & Zhong, 'Learning by Distilling Context' (arXiv:2209.15189, 2022)
AI & LLM Engineering · Fine-tuning & Model Customisation · Card 051/055easy
A team has already fine-tuned a 7B model with full-parameter fine-tuning on a large programming dataset to boost coding ability, but notices this badly degrades the model's general conversational quality and performance on unrelated instruction-following benchmarks. They are considering switching to LoRA fine-tuning on the same coding dataset instead. Based on Biderman et al.'s 'LoRA Learns Less and Forgets Less,' what tradeoff should they expect from making that switch?
ALoRA will match full fine-tuning's gain in coding ability while also matching its degree of forgetting on unrelated tasks, since both methods update the same underlying attention and feed-forward matrices
BLoRA will outperform full fine-tuning on the coding benchmark itself, because restricting the update to a low-rank subspace acts as an implicit curriculum that concentrates learning capacity on the new domain
CLoRA will typically learn the new coding domain less well than full fine-tuning did, but will retain more of the model's prior general-domain performance, a tradeoff the paper partly attributes to the much lower rank of LoRA's weight updates compared to full fine-tuning's
DLoRA will forget the unrelated general-domain tasks just as much as full fine-tuning does, but will take substantially longer to converge on the coding benchmark, since its optimizer must simultaneously track both the frozen and trainable matrices
Correct answer: .
LoRA, Biderman et al. found, substantially underperforms full fine-tuning at learning a new target domain such as programming or math, in both instruction-tuning and continued-pretraining settings, yet it preserves more of the base model's performance on tasks outside that target domain and keeps more diverse generations than full fine-tuning does, even outperforming common explicit regularizers such as weight decay and dropout at limiting this forgetting. The paper attributes part of this tradeoff to rank: full fine-tuning's learned weight perturbations sit at a rank typically ten to a hundred times higher than a typical LoRA configuration's, which the authors suggest helps explain why LoRA's more constrained update learns less of the new domain while disturbing less of what the model already knew. The option claiming LoRA matches full fine-tuning on both learning and forgetting is wrong because the paper's central finding is exactly that the two methods diverge on those two axes. The option claiming LoRA outperforms full fine-tuning on the coding benchmark itself is wrong because the paper reports the opposite: LoRA substantially underperforms full fine-tuning at learning the target domain. The option about convergence speed is wrong because the paper's comparison concerns what capability each method ultimately learns and forgets, not which one takes longer to train.
Source: Biderman et al., 'LoRA Learns Less and Forgets Less' (arXiv:2405.09673, 2024)
AI & LLM Engineering · Fine-tuning & Model Customisation · Card 052/055medium
A team has fine-tuned the same pretrained model five separate times on the same target task and dataset, varying only the learning rate, data augmentation, and random seed for each run, and now must pick which single checkpoint to ship based on validation accuracy. Based on Wortsman et al.'s 'model soups' approach, what alternative to picking the single best-validation-accuracy checkpoint does the paper propose, and what does it claim about the result?
ATrain one additional, larger model from scratch using the five existing runs' predictions as soft labels, a form of knowledge distillation that produces a single model at double the parameter count
BKeep all five fine-tuned checkpoints loaded simultaneously and average their output logits at inference time, trading extra inference-time compute and memory for a modest accuracy gain over the single best checkpoint
CDiscard four of the five checkpoints and fine-tune the remaining one for additional epochs at a lower learning rate, since combining weights from independently fine-tuned runs is numerically unstable for models of this size
DAverage the weights of multiple (or all) of the fine-tuned checkpoints directly into a single set of weights, producing a 'soup' that the paper reports can exceed the accuracy of the best individual checkpoint, including on out-of-distribution and downstream transfer evaluations, without any additional inference or memory cost over a single model
Correct answer: .
Wortsman et al. found that instead of running a hyperparameter sweep and keeping only the checkpoint with the best validation accuracy, the weights of several (or even all) of the independently fine-tuned checkpoints, which emerge from the same pretrained initialization and sit in a shared low-error basin, can simply be averaged together into one set of weights, a 'soup.' Because the result is still a single model with the original architecture, it costs nothing extra at inference or in memory compared to shipping one checkpoint, unlike an ensemble. The paper reports this soup can exceed the single best individual checkpoint's accuracy, including on out-of-distribution robustness and downstream transfer tasks, and even produced a new state-of-the-art ImageNet top-1 result with a souped ViT-G model. Unlike task arithmetic or TIES-merging, which combine task vectors from models fine-tuned on different tasks to grant one model several capabilities, model soups average checkpoints fine-tuned on the same task and dataset with different hyperparameters, aiming for a better single-task model rather than a multi-task one. The option describing logit averaging at inference is wrong because that is ordinary ensembling, which does cost extra inference compute and memory per model kept loaded, exactly what the paper's weight-averaging approach avoids. The option describing distillation into a larger model is wrong because the paper never trains a new model from the others' outputs; it directly averages existing weights. The option claiming weight averaging is numerically unstable at this scale is wrong because the paper's central empirical claim, demonstrated across CLIP, ALIGN, and ViT-G scale models, is exactly the opposite: averaging works and helps.
Source: Wortsman et al., 'Model soups: averaging weights of multiple fine-tuned models improves accuracy without increasing inference time' (arXiv:2203.05482, ICML 2022)
AI & LLM Engineering · Fine-tuning & Model Customisation · Card 053/055easy
A team is running standard supervised instruction fine-tuning on a 7B model using the Alpaca dataset and wants a change that costs no extra training data, no extra compute per step, and requires modifying only a few lines of the training loop. Following Jain et al.'s NEFTune, what do they do, and on what basis does the paper claim it helps?
ADuring each training step's forward pass, add random uniform noise to the token embedding vectors (scaled down by a factor depending on sequence length and embedding dimension) before the rest of the model processes them, leaving the loss computation, optimizer, and data otherwise unchanged; the paper reports large gains on instruction-following benchmarks such as AlpacaEval
BReplace the cross-entropy loss with a label-smoothing loss that softens the target distribution over the vocabulary at every token position, which the paper claims reduces overconfidence without touching the embedding layer at all
CInsert an additional trainable adapter layer after the embedding layer whose output is added to the embeddings, trained jointly with the rest of the model via ordinary backpropagation, which the paper reports approximates full fine-tuning at a fraction of the parameter cost
DDuplicate each training example in the batch with its words randomly shuffled, a lightweight data augmentation step that the paper claims is equivalent in effect to a much larger training set
Correct answer: .
NEFTune adds independently sampled uniform noise, each entry drawn from the range [-1, 1], to the token embedding vectors on every forward pass during training, scaling the raw noise vector by a tunable base noise scale alpha divided by the square root of sequence length times embedding dimension; everything else in the training loop, the loss, the optimizer, and the data, is left completely unchanged, so the method adds no extra data and no extra compute. The paper reports that this single change took LLaMA-2-7B fine-tuned on Alpaca from roughly 30% to roughly 65% on AlpacaEval, with further gains of around 8-10 percentage points on other instruction datasets, and that even models already refined with RLHF benefited from additional NEFTune training. The option describing label smoothing is wrong because that changes the loss function's target distribution, not the embeddings, and is a different, unrelated regularization technique. The option describing a trainable adapter after the embedding layer is wrong because NEFTune adds no new trainable parameters at all; the noise is sampled fresh each step rather than learned. The option describing duplicating shuffled-word examples is wrong because NEFTune never touches the training data itself, only the embedding vectors computed from it during the forward pass.
AI & LLM Engineering · Fine-tuning & Model Customisation · Card 054/055hard
A team wants a parameter-efficient alternative to LoRA that trains even fewer parameters, and considers Wu et al.'s ReFT (specifically LoReFT, Low-rank Linear Subspace ReFT). Unlike LoRA, which injects trainable low-rank matrices into the weight computation and can later be merged into the frozen base weights, what does LoReFT actually train and intervene on?
ALoReFT trains a new set of low-rank weight matrices at every layer of the network, identical in form to LoRA's own low-rank matrices, but initializes them from the base model's existing weights rather than from random noise, which the paper reports is the sole source of its added parameter efficiency
BLoReFT keeps every pretrained weight completely frozen and instead learns a low-rank linear subspace intervention that edits the hidden representation at a fixed, small set of token positions and chosen layers, pushing the representation's component within that subspace toward a learned target value while leaving the rest of the representation untouched
CLoReFT removes the final few transformer layers entirely and replaces them with a small randomly initialized feed-forward network trained from scratch on the target task, discarding the pretrained layers' original representations altogether
DLoReFT trains a full copy of the attention mechanism's query and key projection matrices while freezing the value and output projections, reducing trainable parameters roughly in proportion to how many of the four projection matrices are skipped
Correct answer: .
LoReFT leaves every one of the base model's pretrained weights frozen and instead learns an intervention, parameterized by a low-rank projection matrix with orthonormal rows plus a small learned linear map, that edits a hidden representation only within that low-rank subspace: it computes a target value for the subspace from the current representation, then moves the representation's component inside that subspace toward that target while leaving everything outside the subspace completely untouched. This intervention is applied only at a fixed, small number of prefix and suffix token positions at a chosen set of layers, which is why its added inference cost does not grow with prompt length and why the paper reports it trains roughly 15 to 65 times fewer parameters than LoRA, around 0.031% of the base model's parameters for LLaMA-7B, while matching or exceeding other parameter-efficient methods across several benchmarks. The option describing new low-rank weight matrices initialized from existing weights is wrong because LoReFT never adds trainable weight matrices into the forward computation at all; it edits the representation that comes out of a layer, not the weights that produce it. The option describing replacing the final layers with a retrained feed-forward network is wrong because LoReFT keeps the entire pretrained architecture and its representations intact everywhere outside the small intervened subspace. The option describing training a subset of attention projection matrices is wrong because LoReFT does not touch any attention projection matrix; its only trainable parameters are the intervention's own projection matrix and linear map, applied to the representation after it leaves a layer.
Source: Wu et al., 'ReFT: Representation Finetuning for Language Models' (arXiv:2404.03592, 2024)
AI & LLM Engineering · Fine-tuning & Model Customisation · Card 055/055medium
A team wants to pretrain a 7B model from scratch on a single consumer GPU with 24GB of memory, nowhere near enough to hold full-parameter Adam optimizer states in standard precision for a model that size. They want every one of the model's original parameters to actually get updated during training, ruling out a LoRA-style approach that freezes the base weights. Based on Zhao et al.'s GaLore, how does the method make this feasible?
AGaLore freezes the base model's weights entirely, exactly like LoRA, and only trains a small pair of low-rank matrices injected at each layer, but claims extra memory savings over LoRA by storing those matrices in 8-bit integer precision
BGaLore shards the full set of model weights, gradients, and optimizer states evenly across multiple GPUs so that no single GPU ever holds a complete copy, the same partitioning strategy used by ZeRO
CGaLore reduces memory by training on a smaller random subset of the pretraining tokens each step, skipping full-batch gradient computation entirely and relying on the resulting noisier gradient estimate to approximate the full-data gradient
DGaLore keeps all of the model's original parameters trainable and updated every step, but projects the gradient computed for each weight matrix into a low-rank subspace before it reaches the optimizer, so the optimizer's state (such as Adam's moment estimates) is stored and updated at that lower rank instead of at the full weight matrix's size
Correct answer: .
GaLore is explicitly a full-parameter training method: unlike LoRA, which freezes the pretrained weights and adds a trainable low-rank matrix pair alongside them, GaLore lets every original weight get updated, but before the gradient computed for a weight matrix reaches the optimizer, it is projected into a low-rank subspace, so memory-hungry optimizer state such as Adam's first and second moment estimates is stored and updated at that lower rank rather than at the full matrix's size. The paper reports this cuts optimizer-state memory by up to 65.5% (82.5% for an 8-bit variant), enough to let a 7B model be pretrained on a single 24GB consumer GPU with no model parallelism, checkpointing, or offloading, while matching full-rank training's performance on pretraining and fine-tuning benchmarks. The option describing frozen weights with 8-bit low-rank matrices is wrong because that describes a LoRA/QLoRA-style parameter-efficient approach, the opposite of GaLore's full-parameter updates. The option describing sharding weights, gradients, and optimizer states across multiple GPUs is wrong because that describes ZeRO's partitioning strategy across devices, not GaLore's single-GPU, low-rank gradient-projection approach. The option describing training on a random subset of tokens each step is wrong because GaLore's memory savings come from how the gradient is projected before reaching the optimizer, not from using less training data per step.
Source: Zhao et al., 'GaLore: Memory-Efficient LLM Training by Gradient Low-Rank Projection' (arXiv:2403.03507, ICML 2024)
About Fine-tuning & Model Customisation
This topic covers adapting a pretrained language model to a new task, domain, or behaviour after pretraining, and the toolkit has grown well beyond retraining every weight. Full fine-tuning updates all of a model's parameters and can be worth it for a large domain shift, but it requires a full optimiser state alongside the model and a separate full copy per task. Parameter-efficient methods trade some of that flexibility for dramatically lower cost: LoRA (Hu et al., 2021) freezes the pretrained weights entirely and trains only a small pair of low-rank matrices injected alongside each targeted weight matrix, reporting a 10,000-fold reduction in trainable parameters on GPT-3 with no added inference latency once the adapter is merged back in. QLoRA extends this to a single GPU by additionally quantising the frozen base model to 4-bit precision during training.
Beyond supervised fine-tuning, a further stage aligns a model to human preferences rather than just imitating examples: RLHF trains a reward model on pairs of human-ranked responses, then optimises the policy against it with reinforcement learning, commonly PPO. Direct Preference Optimization (DPO) and newer variants such as ORPO and SimPO achieve a similar alignment effect by optimising directly on preference pairs, without training a separate reward model or running a full RL loop. A persistent risk across all of these methods is catastrophic forgetting: fine-tuning hard on a narrow new dataset can quietly degrade capabilities the base model already had, which is why evaluating against the original task distribution matters as much as evaluating the new one.
Looking for GRPO vs PPO, with the advantage calculation worked by hand? Read the explainer.