27/31
Part 6 of 6 · What interviewers ask nextLearn and do

Merging makes serving cheap, but only for one adapter

Back to serving: merge the adapter, or keep it separate?

MergedUnmerged
Tasks per modelonemany, on one shared base
Extra work per adapted layernonetwo small matmuls

A merged model is a plain model: no extra matmuls, no extra kernel launches, nothing for the serving stack to know about. Unmerged, every adapted layer runs two more small matmuls on each forward pass. They're cheap in arithmetic, 0.13% of the layer at r=8r = 8 on GPT-3's projection, but they're extra steps on the path that sets latency.

Predict

You merged adapter 0 into the base. Can the same batch also serve a request for adapter 2?

Pick an answer above to see the rest
Predict

Biderman et al. (2024) trained on code and math, with about 100K instruction examples and 20B tokens of continued pretraining. How did LoRA do against full fine-tuning?

Pick an answer above to see the rest