A Comparative Study of ParsBERT and mBERT in Emotion Recognition for Dari-Farsi Text with Explainable AI
Malika Muradi, Basit Hussain, Ehsanur Rahman Rhythm, Annajiat Alim Rasel · 2024
Even though emotion analysis is a popular research field, most of the studies have been conducted in English, and the number of those considering Dari is very constrained.Dari and Farsi are two different dialect of Persian language.It has limited resources for natural language processing (NLP), posing a major challenge for Dari NLP research.To overcome these challenges, this study explores the application of Bidirectional Encoder Representations from Transformers (BERT) models for emotion detection in the Dari text.Taking advantage of the power of the BERT model, we analyzed emotion classification in Dari.The study used two pre-trained BERT models: Multilingual BERT, a general-purpose model, and ParsBERT, a model specifically designed for the Dari language.In this study, we utilized the ArmanEmo dataset, and our analysis demonstrates Pars-BERT's superior performance across all evaluation metrics, achieving an accuracy of 86.3% compared to Multilingual BERT's 81.2%.This advantage is attributed to ParsBERT's deeper understanding of Dari intricacies and its domain-specific adaptation.Further analysis utilized two most renowned Explainable AI (XAI) methods: Local Interpretable Model-agnostic Explanations (LIME), and Shapley Additive exPlanations (SHAP).These methods reveal the specific words and phrases that ParsBERT relies on to classify emotions, highlighting its focus on key emotion-related terms and expanding relevant expressions.