A comparative study of cross-lingual sentiment analysis

Abstract

This paper presents a detailed comparative study of the zero-shot cross-lingual sentiment analysis. Namely, we use modern multilingual Transformer-based models and linear transformations combined with CNN and LSTM neural networks. We evaluate their performance in Czech, French, and English. We aim to compare and assess the models’ ability to transfer knowledge across languages and discuss the trade-off between their performance and training/inference speed. We build strong monolingual baselines comparable with the current SotA approaches, achieving state-of-the-art results in Czech (96.0% accuracy) and French (97.6% accuracy). Next, we compare our results with the latest large language models (LLMs), i.e., Llama 2 and ChatGPT. We show that the large multilingual Transformer-based XLM-R model consistently outperforms all other cross-lingual approaches in zero-shot cross-lingual sentiment classification, surpassing them by at least 3%. Next, we show that the smaller Transformer-based models are comparable in performance to older but much faster methods with linear transformations. The best-performing model with linear transformation achieved an accuracy of 92.1% on the French dataset, compared to 90.3% received by the smaller XLM-R model. Notably, this performance is achieved with just approximately 0.01 of the training time required for the XLM-R model. It underscores the potential of linear transformations as a pragmatic alternative to resource-intensive and slower Transformer-based models in real-world applications. The LLMs achieved impressive results that are on par or better, at least by 1%–3%, but with additional hardware requirements and limitations. Overall, this study contributes to understanding cross-lingual sentiment analysis and provides valuable insights into the strengths and limitations of cross-lingual approaches for sentiment analysis
Tento článek představuje podrobnou komparativní studii mezijazyčné analýzy sentimentu. Konkrétně, využíváme moderní vícejazyčné modely založené na architektuře Transformer a lineárních transformacích v kombinaci s CNN a LSTM neuronovými sítěmi. Jejich úspěšnost je vyhodnocena na češtině, francouzštině a angličtině. Naším cílem je porovnat schopnost modelů přenášet znalosti napříč jazyky a zhodnotit kompromis mezi jejich úspěšností a rychlostí trénování a predikce. Pro porovnání jsou vytvořeny základní modely, které dosahují současných state-of-the-art výsledků pro češtinu a francouzštinu. Dále jsou naše výsledky porovnány s výstupy nejnovějších velkých jazykových modelů, tj. modely Llama 2 a ChatGPT. Ukazujeme, že velký vícejazyčný model XLM-R založený na architektuře Transformer konzistentně překonává všechny ostatní mezijazyčné přístupy při tzv. zero-shot detekci polarity. Dále je ukázáno, že menší modely založené na architektuře Transformer jsou výkonnostně srovnatelné se staršími, ale mnohem rychlejšími metodami používající lineární transformace. Této úspěšnosti je dosaženo jen s přibližně 0,01 času potřebného pro natrénování velkého modelu XLM-R. Tyto výsledky podtrhují potenciál metod založených na lineárních transformacích jako pragmatické alternativy. A to zejména v reálných aplikacích používajících modely založených na architektuře Transformer, které jsou pomalejší a náročné na výpočetní zdroje. Velké jazykové modely (Llama 2 a ChatGPT) dosáhly působivých výsledků, které jsou srovnatelné nebo lepší minimálně o 1% - 3% , ale přinášejí další omezení požadavky. Celkově přispíváme k pochopení mezijazyčné analýzy sentimentu a poskytujeme cenné zkušenosti o silných stránkách a omezeních mezijazyčných přístupů.

Description

Subject(s)

sentiment analysis, zero-shot cross-lingual classification, linear transformation, ransformers, large language models, transfer learning, analýza sentimentu, mezijazyčná zero-shot klasifikace, lineární transformace, transformer, velké jazykové modely, transfer leraning

Citation

Collections