Skip to main content
QUICK REVIEW

[Paper Review] Typhoon: Thai Large Language Models

Kunat Pipatanakul, Phatrasek Jirabovonvisut|arXiv (Cornell University)|Dec 21, 2023
Natural Language Processing TechniquesComputer Science6 citations
TL;DR

Typhoon is a 7-billion-parameter Thai large language model fine-tuned from Mistral-7B using targeted Thai pretraining and instruction tuning, achieving state-of-the-art performance on open-source Thai benchmarks and matching GPT-3.5's performance in Thai while being 2.62x more efficient in tokenization. The model is evaluated via ThaiExam, a custom benchmark based on national exams, and outperforms existing open-source models on instruction-following, translation, summarization, and question-answering tasks.

ABSTRACT

Typhoon is a series of Thai large language models (LLMs) developed specifically for the Thai language. This technical report presents challenges and insights in developing Thai LLMs, including data preparation, pretraining, instruction-tuning, and evaluation. As one of the challenges of low-resource languages is the amount of pretraining data, we apply continual training to transfer existing world knowledge from a strong LLM. To evaluate the Thai knowledge encapsulated in each model from the pretraining stage, we develop ThaiExam, a benchmark based on examinations for high-school students and investment professionals in Thailand. In addition, we fine-tune Typhoon to follow Thai instructions, and we evaluate instruction-tuned models on Thai instruction datasets as well as translation, summarization, and question-answering tasks. Experimental results on a suite of Thai benchmarks show that Typhoon outperforms all open-source Thai language models, and its performance is on par with GPT-3.5 in Thai while having only 7 billion parameters and being 2.62 times more efficient in tokenizing Thai text.

Motivation & Objective

  • To develop a high-performing, open-source large language model specifically for the Thai language, addressing the underrepresentation of Thai in existing multilingual and English-centric LLMs.
  • To overcome data scarcity in Thai NLP by applying continual pretraining on a curated Thai corpus to transfer world knowledge from a strong base model.
  • To evaluate Thai language understanding and instruction-following capabilities using domain-specific benchmarks such as ThaiExam, based on real national examinations.
  • To improve alignment and zero-shot generalization through instruction tuning on both native Thai and translated instruction datasets.
  • To release Typhoon under the Apache-2.0 license to promote further research and development in Thai NLP.

Proposed method

  • Continual pretraining of Mistral-7B on a curated, moderately sized Thai text corpus to enhance domain-specific knowledge and linguistic understanding.
  • Development of ThaiExam, a benchmark based on high-school and investment professional examinations, to evaluate factual and cultural knowledge in Thai LLMs.
  • Instruction tuning of Typhoon using both native Thai and translated instruction-following datasets to improve zero-shot and few-shot alignment.
  • Evaluation using LLM-judge frameworks (AlpacaEval, OASST, MT-Bench, Sea-bench) with GPT-4 as the judge to measure instruction-following performance.
  • Zero-shot evaluation on standard NLP tasks: machine translation (FLORES-200), abstractive summarization (XLSum, CrossSum), and question-answering (XQuAD) using standard metrics.
  • Use of the newmm tokenizer to improve Thai tokenization efficiency, achieving 2.62x faster tokenization compared to base models.
Figure 1 : Performance of Typhoon and other open-source Thai large language models on Thai Examinations (left) and Thai instruction-following (right). Details about ThaiExam and Thai instruction-following evaluation are provided in Section 3.4 , and Section 4.2 , respectively.
Figure 1 : Performance of Typhoon and other open-source Thai large language models on Thai Examinations (left) and Thai instruction-following (right). Details about ThaiExam and Thai instruction-following evaluation are provided in Section 3.4 , and Section 4.2 , respectively.

Experimental results

Research questions

  • RQ1Can a strong English-centric LLM be effectively adapted to the Thai language through targeted pretraining on a moderate-sized Thai corpus?
  • RQ2How well does Typhoon perform on domain-specific knowledge evaluation compared to existing open-source Thai LLMs, particularly on exam-based benchmarks like ThaiExam?
  • RQ3To what extent does instruction tuning on native Thai and translated datasets improve zero-shot generalization on translation, summarization, and question-answering tasks?
  • RQ4How does Typhoon’s performance compare to GPT-3.5 in Thai, particularly in terms of instruction-following and factual reasoning?
  • RQ5What is the impact of improved tokenization efficiency on inference speed and model deployment in Thai NLP applications?

Key findings

  • Typhoon-7B-Instruct achieved a 49.05% win rate on Thai AlpacaEval, outperforming all other open-source Thai LLMs and matching GPT-3.5’s performance on this benchmark.
  • On the translated MT-Bench, Typhoon-7B-Instruct achieved a 55.52% win rate, again outperforming all other open-source models and matching GPT-3.5’s performance.
  • In zero-shot NLP tasks, Typhoon-7B-Instruct achieved the highest BLEU score of 46.62 on FLORES-200 English-to-Thai translation and the highest ROUGE-L score of 14.51 on XLSum (Thai-to-Thai summarization).
  • On XQuAD, Typhoon-7B-Instruct achieved a 34.46% F1 score in the 0-shot setting, outperforming OpenThaiGPT and SeaLLM-7B-Chat.
  • Typhoon demonstrated 2.62x higher tokenization efficiency for Thai text compared to the base Llama2 model, significantly improving inference speed and efficiency.
  • Typhoon-7B-Instruct showed strong zero-shot capabilities on summarization and question-answering, with ROUGE-L scores of 21.60 and 17.32, respectively, surpassing all other open-source models.

Read this paper

Open the full text in the Nubint reader and ask about any passage as you read.

Read this paper on Nubint

This review was generated by AI from the original paper. Please check the paper before citing it.