Not All Languages Are Created Equal in LLM s: Improving Multilingual Capability by Cross-Lingual-Thought Prompting (2023)

Abstract: Large language models (LLMs) demonstrate impressive multilingual capability, but their performance varies substantially across different languages. In this work, we introduce a simple yet effective method, called cross-lingual-thought prompting (XLT), to systematically improve the multilingual capability of LLMs. Specifically, XLT is a generic template prompt that stimulates cross-lingual and logical reasoning skills to enhance task performance across languages. We conduct comprehensive evaluations on 7 typical benchmarks related to reasoning, understanding, and generation tasks, covering both high-resource and low-resource languages. Experimental results show that XLT not only remarkably enhances the performance of various multilingual tasks but also significantly reduces the gap between the average performance and the best performance of each task in different languages. Notably, XLT brings over 10 points of average improvement in arithmetic reasoning and open-domain question-answering tasks.

## introduction large language models (llms) demonstrate impressive multilingual capability in a wide range of natural language processing tasks, including language generation, knowledge utilization, and complex reasoning @xcite . their performance in downstream tasks has been shown to reach or even surpass human-level performance @xcite @xcite . the capabilities of llms stem from the extensive volume of training data they leveraged @xcite . the training data for current models is primarily dominated by the english language corpus, but it also encompasses data from other languages, as described in gpt-3 @xcite , palm @xcite , and bloom @xcite , etc. there are over 7,000 languages worldwide, with the vast majority being low-resource or extremely low-resource languages @xcite . despite the latest gpt-4 model (openai, 2023) demonstrating some generalization capabilities in llm input request: 詹姆斯决定每 周跑 3 次 3 段冲刺，每 段冲刺跑 60 米。他每 周一共跑多少米? request: james decides to run 3 sets of 60-meter sprints three times a week. how many meters does he run in total each week? output 1. james runs 3 sets of 60-meter sprints, which means he runs 60 x 3 = 180 meters per sprint. 2. james runs 3 sets of 180 meters per week, which means he runs 180 x 3 = 540 meters per week. answer: james runs a total of meters per @xcite step-by-step answer: given a request, its associated meta information is filled into the placeholders of the xlt template to form the language-independent prompt, which is fed to the llm to enhance the generation of responses in the desired format. intuitively, llms can improve multilingual capability by augmenting data @xcite or fine-tuning models @xcite , but both are computationally expensive. alternatively, in-context learning with prompts can also boost performance @xcite @xcite but is limited to monolingual tasks @xcite . this work explores a universal in-context learning approach to enhance the multilingual capability of llms. we introduce a simple yet effective method, called cross-lingual-thought prompting (xlt), to enable models to handle various natu-ral language processing tasks across different target languages. our method employs a generic and language-independent prompt, which eliminates the need to update model parameters. depending on the task input type, cross-lingual-thought prompting guides the large language model to assume the role of an expert in a specific language for a particular task. given its predefined meta information, xlt directs llms to respond logically through a process involving problem understanding, cross-lingual thinking, task analysis, task execution, and output formatting. during this process, our method is designed to stimulate models' cross-lingual and logical reasoning skills, enabling them to respond to input requests regardless of the language. for enhanced performance, few-shot learning can also be employed with our method by providing an llm-generated response output as a demonstration using cross-lingual-thought prompting zero-shot learning. we conduct a comprehensive evaluation to verify the effectiveness of xlt across seven representative multilingual benchmarks of natural language reasoning, understanding, and generation tasks. each benchmark includes multilingual data covering both high-resource and low-resource languages. the experimental results demonstrate that our method can significantly improve the perfor- i want you to act as a task_name expert for task_language . task_input you should retell/repeat the input_tag in english. you should task_goal . you should step-by-step answer the request. you should tell me the output_type ( output_constraint ) in this format ' output_type :'. mance of all benchmarks across languages under both zero-shot and few-shot learning settings. notably, xlt achieves an average gain of over 10 points on the mgsm and mkqa benchmarks. furthermore, we observe that our prompting method significantly reduces the gap between the average performance and the best performance of each task in different languages, indicating its potential to democratize language intelligence. ## cross-lingual-thought prompting although llms are capable of accepting any input and generating responses, users typically structure their requests in the form of prompts to elicit the desired output. the design of these prompts is crucial for achieving optimal performance on downstream tasks, as llms are sensitive to the format of the prompts chosen @xcite . through a process called instruction tuning @xcite , models can develop the ability to follow natural language instructions @xcite , which can reduce their sensitivity to prompt engineering @xcite . in accordance with the guidelines of the openai cookbook 1 , we propose a cross-lingual thought prompting template, denoted as the xlt template. this generic template allows llms to respond to requests with cross-lingual thought and supports a wide range of multilingual tasks. figure 3 displays the xlt template, with the colored sections representing placeholders. figure 2 showcases an example of instantiated prompt for the chinese request. the following section will explain the details of constructing xlt. ## experiments to comprehensively verify the effectiveness of our method on language-independent generality, we evaluate our xlt template on different llms covering various natural language processing tasks in multiple languages. ## conclusion this work investigates the language processing capabilities of large language models in multilingual settings and expects to develop a universal framework for handling diverse multilingual tasks. to accomplish this goal, we propose a generic prompt, referred to as xlt, to enhance the multilingual capability and reduce the performance gaps among languages in tasks related to language understanding, reasoning, and generation in non-english and low-resource languages. although our method is generally applicable across tasks and languages, we discovered that prompting design factors such as instruction logic and word choice have explicit impacts on its effectiveness. cross-language thinking in xlt is particularly effective. finally, we hope this work can inspire further research to prioritize the development of generic prompting. by doing so, large language models can encompass a wider range of modalities and languages.