TLDR: Optimal Corpus Aware Training (OCAT) is a novel fine-tuning method for Neural Machine Translation models that have been pre-trained with Corpus Aware Training (CAT). OCAT addresses the challenge of selecting the best inference mode by freezing most model parameters and only tuning a small set of corpus-related parameters. This approach makes OCAT lightweight, resistant to overfitting, and highly effective in significantly improving model accuracy, outperforming or matching other state-of-the-art fine-tuning techniques on WMT’23 English to Chinese and English to German translation tasks.
In the realm of Machine Learning (ML), particularly in tasks like Neural Machine Translation (NMT), practitioners often combine various datasets—acquired, licensed, crawled, and manually annotated—to create a large training corpus. However, these datasets can differ significantly in domain, quality, and quantity. Blindly mixing them can lead to a loss of valuable corpus-specific information, resulting in sub-optimal model performance.
To address this, a generic approach known as Corpus Aware Training (CAT) has emerged. CAT enhances models by injecting corpus information, often as ‘tags,’ into each training example. This allows the model to inherently learn the quality, domain, and nuances between different corpora directly from the data. Consequently, CAT models gain the ability to switch between different prediction modes during inference, depending on the specific corpus tag used. While effective, a key challenge with CAT is determining the optimal inference mode for deployment, especially when aiming for the best generalization across various testing domains.
Introducing Optimal Corpus Aware Training (OCAT)
A new method, Optimal Corpus Aware Training (OCAT), has been proposed to tackle the inference mode selection problem inherent in CAT models. OCAT fine-tunes a pre-trained CAT model by strategically freezing most of its parameters and only adjusting a small set of corpus-related parameters, specifically the tag embeddings. This approach is inspired by techniques that fine-tune limited parameters from large pre-trained models.
The benefits of OCAT are manifold. Firstly, it is remarkably lightweight, requiring minimal computational resources. For instance, a transformer base model can converge in less than a single A100 GPU-hour. Secondly, OCAT demonstrates strong resilience to overfitting. Because only a very limited number of parameters (e.g., 512 out of 69 million in a transformer base model) are fine-tuned, the model is less prone to overfitting, even when trained on small datasets. Thirdly, despite its minimal parameter tuning, OCAT is highly effective in boosting model accuracy. This is because CAT models are sensitive to the choice of inference tag, and tuning the tag embedding steers the model’s behavior towards the desired direction.
Experimental Validation and Performance
Experiments conducted on the WMT’23 English to Chinese and English to German translation tasks showcased OCAT’s effectiveness. The results indicated significant improvements in chrF scores: +3.6 for English to Chinese and +1.8 for English to German, compared to models trained without CAT. The research also highlighted how sensitive CAT model predictions are to the chosen inference tag, with differences of up to 8.6 chrF points observed when decoding with different tags.
When compared against other popular fine-tuning techniques like full-weight fine-tuning, adapter, and LoRA, OCAT proved to be on par or even slightly superior, particularly in generalizing to out-of-domain test sets. Full-weight fine-tuning, for example, often overfits to the tuning dataset, leading to degraded performance on unseen data. Adapter and LoRA showed better generalization but still lagged behind OCAT on out-of-domain tests. Furthermore, OCAT exhibited greater robustness to hyperparameter settings, remaining stable across a wide range of learning rates and training steps, unlike other methods that are more susceptible to overfitting with aggressive settings.
Also Read:
- MoKA: Enhancing LLM Adaptation with Gated Kronecker Mixtures
- Unlocking Vision-Language Models: A Deep Dive into Label-Free Adaptation
Data Efficiency and Future Directions
A surprising finding was OCAT’s efficiency with small datasets. Improvements were observed with as few as 100 sentences for in-domain test sets, and around 400 sentences were sufficient to prevent degradation and show minor improvements on out-of-domain test sets. This suggests that OCAT is not data-hungry and can effectively leverage even small quantities of high-quality data.
The concept of CAT can also be extended to more fine-grained information, such as tagging training data by annotator ID or specific web domains. This allows for a deeper understanding of data quality and domain matching, potentially enabling automated selection of high-quality datasets or filtering out low-quality corpora for fine-tuning. This aspect is considered a promising area for future work.
In conclusion, OCAT provides an easy, efficient, and effective method to fine-tune CAT pre-trained models. It successfully leverages small, high-quality fine-tune data to significantly boost model prediction in machine translation setups and effectively mitigates the inference tag selection problem of CAT. For more details, you can refer to the full research paper here.


