[Paper Review] On the Complementarity of Data Selection and Fine Tuning for Domain Adaptation
This paper investigates the complementarity between data selection and fine-tuning in domain adaptation for neural language modeling and machine translation. It proposes using discriminative domain classifiers—particularly fine-tuned BERT—to select out-of-domain pretraining data that is similar but not overly specific to the target domain, showing that such selection significantly improves generalization and outperforms contrastive data selection methods, especially when combined with fine-tuning.
Domain adaptation of neural networks commonly relies on three training phases: pretraining, selected data training and then fine tuning. Data selection improves target domain generalization by training further on pretraining data identified by relying on a small sample of target domain data. This work examines the benefit of data selection for language modeling and machine translation. Our experiments assess the complementarity of selection with fine tuning and result in practical recommendations: (i) selected data must be similar to the fine-tuning domain but not so much as to erode the complementary effect of fine-tuning; (ii) there is a trade-off between selecting little data for fast but limited progress or much data for slow but long lasting progress; (iii) data selection can be applied early during pretraining, with performance gains comparable to long pretraining session; (iv) data selection from domain classifiers is often more effective than the popular contrastive data selection method.
Motivation & Objective
- To analyze the complementarity between data selection and fine-tuning in domain adaptation for neural models.
- To evaluate the effectiveness of different data selection methods—particularly contrastive scoring versus discriminative domain classifiers—on language modeling and machine translation.
- To identify optimal hyperparameters for data selection, including selection size, timing relative to pretraining, and training duration before fine-tuning.
- To provide practical recommendations for practitioners on when and how to apply data selection to maximize performance gains.
Proposed method
- The authors use a three-stage training pipeline: pretraining on generic out-of-domain data, data selection on a subset of this data, and fine-tuning on target-domain data.
- Data selection is performed using either contrastive scoring (e.g., based on sentence embeddings) or discriminative domain classifiers trained on small in-domain samples.
- Discriminative classifiers are fine-tuned BERT models that predict whether a pretraining example belongs to the target domain, with scores used to rank and select data.
- The study evaluates selection methods on both language modeling and neural machine translation (En-De and En-Fr) across varying pretraining steps and selection sizes.
- Generalization performance is measured via validation loss on target-domain data after fine-tuning, with ablation studies on selection size, timing, and model type.
- The authors compare selection methods using binary classification accuracy on held-out in-domain/out-of-domain data and average quantile of in-domain examples in the ranked selection list.
Experimental results
Research questions
- RQ1How does the similarity between selected data and fine-tuning data affect the complementarity of data selection and fine-tuning?
- RQ2What is the trade-off between selecting a small amount of high-quality data versus a larger, lower-quality set in terms of generalization and training speed?
- RQ3How does the choice of data selection method—contrastive scoring versus discriminative domain classifiers—affect downstream performance?
- RQ4Can data selection be applied early in pretraining to reduce total training time while maintaining performance?
- RQ5To what extent does data selection improve generalization compared to fine-tuning alone, and when does it harm performance?
Key findings
- Discriminative domain classifiers, especially fine-tuned BERT, consistently outperform contrastive data selection methods in both language modeling and machine translation, achieving 93.51% binary classification accuracy on the MT task.
- Data selection from domain classifiers leads to better generalization than contrastive selection, which suffers from overfitting to the target training set, as evidenced by higher validation loss despite strong training set performance.
- Selecting only the top 1M examples from pretraining data with contrastive scoring results in worse generalization than selecting more data with a less precise but more diverse method.
- Data selection can be applied early in pretraining—after just 200k steps—achieving performance comparable to models pre-trained for much longer durations.
- The combination of data selection and fine-tuning can outperform fine-tuning alone, but only when the selected data is sufficiently complementary; poor complementarity can degrade performance below fine-tuning-only baselines.
- Short diagnostics on selected data performance before fine-tuning are misleading, as small subsets converge quickly but overfit, while larger subsets generalize better but require more training steps.
Read this paper
Open the full text in the Nubint reader and ask about any passage as you read.
Read this paper on NubintThis review was generated by AI from the original paper. Please check the paper before citing it.