Introduction: The Language Gap in LLMs
While Large Language Models (LLMs) demonstrate remarkable capabilities, they suffer from a significant "language gap." Most state-of-the-art models are trained on datasets where English comprises over 90% of the tokens, leading to suboptimal performance in non-English languages. Traditionally, developers have relied on two primary strategies: Direct Inference (prompting in the source language) or Full Pre-translation (translating the entire prompt into English). This paper explores a modular middle ground: selective pre-translation.
Methodology: Modular Prompting and Selective Translation
The researchers decomposed standard prompts into four functional modules: Instruction (I) (task description), Context (X) (primary data), Examples (E) (few-shot learning), and Output (O) (response language). By exhaustively testing 24 different configurations across 35 languages and four diverse NLP tasks (QA, NER, NLI, and Summarization), the study identifies which specific components benefit most from translation into English.
Key Insights: The "Surgical" Advantage
The study reveals that selective pre-translation outperformed both full translation and direct inference in 92% of the tested languages. Key findings include:
- Instructions are better in English: Providing the task instruction in English leverages the model's robust reasoning capabilities developed during English-centric training.
- Extractive vs. Generative Divide: For extractive tasks like Question Answering (QA) and Named Entity Recognition (NER), keeping the Context in the source language is often superior. This prevents "translation artifacts" from corrupting the source data, which is particularly critical for low-resource languages.
- Low-Resource Gains: The performance boost was most dramatic for low-resource languages (e.g., Telugu, Malayalam), where selective strategies yielded improvements of over 200% compared to direct inference.
Quantitative Results and Model Generalization
Quantitative analysis shows that selective translation acts as a buffer against poor Machine Translation (MT). In low-resource settings, the average improvement from selective translation was 65% greater than in high-resource settings. These findings held true across various architectures, including GPT-3.5-turbo, Mistral-8x7B, and Gemini-1.0-pro, though multilingual-specific models like BLOOMZ showed a stronger preference for single-language prompts.
Limitations and Future Directions
While the study provides a robust framework, it notes limitations such as the reliance on specific MT engines (Google Translate) and the occasional failure of LLMs to adhere to language instructions. Future work should incorporate more linguistically aware metrics for morphologically rich languages and evaluate the latest flagship models like GPT-4. To assist developers, the authors have released a HuggingFace Space to generate optimal selective pre-translation prompts for various use cases.
Summary updated