Leveraging Domain Knowledge at Inference Time for LLM Translation: Retrieval versus Generation
By: Bryan Li , Jiaming Luo , Eleftheria Briakou and more
Potential Business Impact:
Helps computers translate tricky medical and legal words.
While large language models (LLMs) have been increasingly adopted for machine translation (MT), their performance for specialist domains such as medicine and law remains an open challenge. Prior work has shown that LLMs can be domain-adapted at test-time by retrieving targeted few-shot demonstrations or terminologies for inclusion in the prompt. Meanwhile, for general-purpose LLM MT, recent studies have found some success in generating similarly useful domain knowledge from an LLM itself, prior to translation. Our work studies domain-adapted MT with LLMs through a careful prompting setup, finding that demonstrations consistently outperform terminology, and retrieval consistently outperforms generation. We find that generating demonstrations with weaker models can close the gap with larger model's zero-shot performance. Given the effectiveness of demonstrations, we perform detailed analyses to understand their value. We find that domain-specificity is particularly important, and that the popular multi-domain benchmark is testing adaptation to a particular writing style more so than to a specific domain.
Similar Papers
Exploring How LLMs Capture and Represent Domain-Specific Knowledge
Machine Learning (CS)
Helps computers pick the best AI for each job.
Assessing the Capability of Large Language Models for Domain-Specific Ontology Generation
Artificial Intelligence
Builds smart knowledge maps for any topic.
Bridging the Linguistic Divide: A Survey on Leveraging Large Language Models for Machine Translation
Computation and Language
Helps computers translate rare languages better.