[Paper Review] Translation Transformers Rediscover Inherent Data Domains
This paper demonstrates that NMT Transformers inherently learn and preserve domain-specific information in their hidden representations, even without explicit domain labels. By leveraging these internal representations for unsupervised clustering—especially at the document level—it achieves superior domain clustering and domain adaptation performance compared to using external pre-trained language models like XLM-R, outperforming or matching performance when fine-tuning on original labels.
Many works proposed methods to improve the performance of Neural Machine Translation (NMT) models in a domain/multi-domain adaptation scenario. However, an understanding of how NMT baselines represent text domain information internally is still lacking. Here we analyze the sentence representations learned by NMT Transformers and show that these explicitly include the information on text domains, even after only seeing the input sentences without domains labels. Furthermore, we show that this internal information is enough to cluster sentences by their underlying domains without supervision. We show that NMT models produce clusters better aligned to the actual domains compared to pre-trained language models (LMs). Notably, when computed on document-level, NMT cluster-to-domain correspondence nears 100%. We use these findings together with an approach to NMT domain adaptation using automatically extracted domains. Whereas previous work relied on external LMs for text clustering, we propose re-using the NMT model as a source of unsupervised clusters. We perform an extensive experimental study comparing two approaches across two data scenarios, three language pairs, and both sentence-level and document-level clustering, showing equal or significantly superior performance compared to LMs.
Motivation & Objective
- To investigate whether NMT Transformers implicitly encode text domain information in their hidden representations without explicit supervision.
- To evaluate the quality of unsupervised domain clusters derived from NMT model representations compared to those from pre-trained language models.
- To improve NMT domain adaptation by reusing the NMT model’s own learned clusters instead of relying on external language models.
- To test the effectiveness of NMT-based clustering across multiple language pairs and data scenarios, including labeled mixed corpora and unlabeled heterogeneous corpora like ParaCrawl.
Proposed method
- Extract sentence and document-level representations from all layers of a pre-trained NMT Transformer encoder using mean-pooled contextual embeddings.
- Apply Principal Component Analysis (PCA) and k-means clustering to identify unsupervised domain clusters from these representations.
- Use the automatically discovered clusters to fine-tune the NMT model in a domain adaptation framework, replacing reliance on external models like XLM-R for clustering.
- Compare performance using NMT-derived clusters against clusters from XLM-R and original corpus labels across two data settings: labeled mixed corpora and unlabeled ParaCrawl data.
- Evaluate model performance using BLEU scores on multiple language pairs (e.g., EN-DE, EN-ET, EN-CS) and analyze results across different model sizes and cluster numbers.
- Perform ablation studies with smaller NMT models to assess robustness and scalability of the proposed clustering approach.
Experimental results
Research questions
- RQ1Can NMT Transformers learn and preserve domain-specific information in their hidden representations without any explicit domain supervision?
- RQ2How does the quality of unsupervised domain clustering from NMT representations compare to that from pre-trained language models like XLM-R?
- RQ3Can NMT-derived clusters be used effectively for domain adaptation, achieving performance comparable or superior to using original domain labels?
- RQ4Does the performance of NMT-based clustering depend on model size, language pair, or data heterogeneity (e.g., ParaCrawl)?
Key findings
- NMT models produce sentence and document representations that cluster closely with actual text domains, achieving near-perfect correspondence (nearly 100%) at the document level without any supervision.
- NMT-based clusters outperform XLM-R-based clusters in terms of cluster purity and translation quality, especially in document-level clustering.
- Fine-tuning NMT models on automatically extracted NMT clusters matches or exceeds performance when fine-tuning on original corpus labels, particularly for EN-ET and EN-CS translation.
- Even with a 5x smaller model, NMT-based clustering achieves performance comparable to XLM-R, demonstrating robustness and scalability.
- In the DE-EN ParaCrawl setting, NMT-based clustering shows significant improvements over XLM-R, especially when model capacity is sufficient for the language pair.
- The method reduces reliance on external pre-trained models, simplifying the domain adaptation pipeline while maintaining or improving translation quality.
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.