Fusing Transformer-XL with bi-directional recurrent networks for cyberbullying detection
Open Access
- 17 June 2025
- journal article
- Published by PeerJ in PeerJ Computer Science
- Vol. 11, e2940
Abstract
Identifying cyberbullying in languages other than English presents distinct difficulties owing to linguistic subtleties and scarcity of annotated datasets. This article presents a new method for identifying cyberbullying in Bengali text data using the Kaggle dataset. This strategy combines Transformer-Extra Large (XL) with bi-directional recurrent neural networks (BiGRU-BiLSTM). Extensive data preparation was performed, including data cleaning, data analysis, and label encoding. Upsampling methods were used to handle imbalanced classes, and data augmentation enhanced the training dataset. We carried out tokenization of the text using a pre-trained tokenizer to capture semantic representations accurately. The model we presented, Transformer-XL-bidirectional gated recurrent units (BiGRU)-bidirectional long short-term memory (BiLSTM), which is called Fusion Transformer-XL, surpassed the performance of the baseline models, attaining an accuracy of 98.17% and an F1-score of 98.18%. Local interpretable model-agnostic explanation (LIME) text explanations were used to understand the reasoning behind the model’s choices and performed the cross-dataset evaluation of the model using the English dataset. This helped improve the clarity and reliability of the proposed method. Furthermore, implementing k-fold cross-validation ensures our model’s robustness and adaptability across diverse data categories. The results of our study demonstrate the effectiveness of combining Transformer-XL with bi-directional recurrent networks for detecting cyberbullying in Bengali. This emphasizes the significance of using hybrid architectures to address intricate natural language processing problems in languages with limited resources. This study enhances the development of methods for detecting cyberbullying and opens up opportunities for additional investigation into language diversity and social media analytics.Keywords
Funding Information
- Research Chair of Online Dialogue and Cultural Communication at King Saud University, Riyadh, Saudi Arabia
This publication has 29 references indexed in Scilit:
- Cyberbullying detection of resource constrained language from social media using transformer-based approachNatural Language Processing Journal, 2024
- Cyberbullying detection for low-resource languages and dialects: Review of the state of the artInformation Processing & Management, 2023
- An attention-based hybrid architecture with explainability for depressive social media text detection in BanglaExpert Systems with Applications, 2022
- Cyberbullying detection using deep transfer learningComplex & Intelligent Systems, 2022
- Cyberbullying detection: Utilizing social media featuresExpert Systems with Applications, 2021
- A Bi-GRU with attention and CapsNet hybrid model for cyberbullying detection on social mediaWorld Wide Web, 2021
- Correction to: Abusive language detection from social media comments using conventional machine learning and deep learning approachesMultimedia Systems, 2021
- Multimodal cyberbullying detection using capsule network with dynamic routing and deep convolutional neural networkMultimedia Systems, 2021
- Cyberbullying detection solutions based on deep learning architecturesMultimedia Systems, 2020
- Identification of cyberbullying: A deep learning based multimodal approachMultimedia Tools and Applications, 2020