Abstract
Large Language Models (LLMs) frequently underperform in non-Latin scripts and low-resource languages due to English-centric optimization. This paper presents a dynamic runtime framework that selects the optimal combination of prompt strategy, embedding model, and LLM for each query. By treating configuration selection as a prediction task and introducing a more flexible evaluation metric, GPTAnnotator, the proposed system achieves a 10-15% performance boost over static baselines and significantly outperforms specialized fine-tuned models.
Introduction
While Large Language Models (LLMs) like GPT-4 and Gemini are revolutionary, they suffer from a significant "language gap." Their performance drops sharply when handling languages with non-Latin scripts or those with limited training data (low-resource languages). The researchers identify two main hurdles: the failure of "one-size-fits-all" prompting strategies and the rigidity of traditional evaluation metrics like F1 scores, which often penalize semantically correct answers that differ from limited ground-truth data.
Current solutions usually involve expensive fine-tuning, which often fails to generalize to new languages or tasks. This paper introduces a way to bridge this gap at runtime without retraining the underlying LLMs, using a dynamic selection mechanism.
Methods
The authors propose a Dynamic Learning Framework that treats configuration selection as a prediction problem. Instead of a static setup, the system evaluates the query context to determine the best tools for the job.
The Architecture
The system uses a LLaMA-2-70B backbone to generate embeddings for a "Task Description" (the query and context) and various "Configuration Options" (combinations of LLMs, embeddings, and prompts). A set of convolutional layers, referred to as the "Head," then predicts the expected F1 score for every possible combination. The system operates within a Retrieval-Augmented Generation (RAG) setup, dynamically choosing the best multilingual embedding model (e.g., Cohere v3 or XLMR) to pull relevant context.
Prompting and Evaluation
The framework chooses between five strategies, including Monolingual (source language), Translate-Test (translating to English), and Similar High-Resourced Language (routing through a linguistically related language). To address evaluation rigidity, the researchers developed GPTAnnotator, which uses GPT-4 to "enrich" ground-truth answers. If a model's answer is semantically correct but linguistically different from the gold standard, GPTAnnotator recognizes it, providing a more accurate reflection of true performance.
Datasets
The approach was evaluated across 18 diverse languages using two primary benchmarks:
- IndicQA: A curated dataset covering 11 Indic languages (e.g., Hindi, Kannada, Gujarati) sourced from Wikipedia, containing over 18,000 questions.
- TyDiQA: A gold-standard benchmark covering 9 typologically diverse languages (including Arabic, Russian, and Swahili).
Key Insights and Results
A primary finding is that the "best" strategy is highly volatile. For example, GPT-4 might prefer a monolingual prompt for Hindi but perform better with a translation strategy for Telugu. This volatility confirms that static configurations are insufficient for broad multilingual support.
Furthermore, the choice of evaluation metric (standard F1 vs. GPTAnnotator-F1) significantly alters which prompting strategy appears superior. This suggests that previous multilingual research findings might be artifacts of overly rigid evaluation tools.
Performance Gains
- Superiority over Fine-tuning: The dynamic approach achieved 4x gains in F1 scores compared to state-of-the-art fine-tuned, language-specific models like Ambari (for Kannada) or Navarasa (for Indian languages).
- Baseline Gains: It outperformed the "best single configuration" baseline by roughly 11% and random selection by 17%.
- Cross-Lingual Generalization: The framework showed strong "zero-shot" adaptation, outperforming baselines even on languages it never encountered during training (e.g., Kannada or Tamil).
Limitations and Future Work
While the results are promising, the authors note several areas for future research. The system currently focuses on Question Answering (QA), and its effectiveness in creative writing or coding remains to be tested. Additionally, while the prediction head is lightweight, the reliance on multiple LLMs and embedding models at runtime could increase computational overhead and latency in production environments. Future work will also aim to expand coverage to languages with even smaller digital footprints.
Summary updated