The sociopolitical dynamics following the 2024 Indonesian Presidential Election have significantly increased the intensity of public discourse on social media. Polarized opinions regarding various strategic policies are frequently expressed through Indonesian–English code-mixed text. Such texts are characterized by language switching, lexical variations, and semantic ambiguity, posing a major challenge for conventional Natural Language Processing (NLP) methods to accurately capture linguistic markers. This study evaluates Multilingual Bidirectional Encoder Representations from Transformers (mBERT) for opinion classification on Indonesian–English code-mixed text. mBERT was selected because it is a pre-trained model trained on monolingual corpora of 104 languages, granting it cross-lingual transfer capabilities without the need for explicit supervision or bilingual alignment. Additionally, to address the class imbalance issue in the dataset, this study applies the Synthetic Minority Over-sampling Technique (SMOTE). Experimental results demonstrate that mBERT achieved the best performance compared to other models, reaching an accuracy of 82.26% without SMOTE. Following the application of SMOTE, the accuracy increased to 83.00% (an increase of 0.74 percentage points). Although this overall numerical increase appears moderate, the value holds crucial significance: the model successfully mitigated the bias toward majority class predictions. This 0.74% increase represents a significant improvement in precisely recognizing minority classes, as evidenced by vastly more balanced class-wise evaluation metrics. In conclusion, mBERT is a highly promising approach for code-mixed opinion classification, while SMOTE plays an essential role in ensuring predictive fairness on imbalanced datasets.
No takes yet. Share an insight, caveat, or question.
Puspaningrum et al. (2026) studied this question.
Synapse has enriched 5 closely related papers on similar clinical questions. Consider them for comparative context: