Introduction
Moderating social media content is a complex challenge, exacerbated by the linguistic diversity of user-generated text. In multilingual regions like South India, users frequently employ code-mixing (interweaving words from different languages) and script-mixing (writing native languages using the Latin alphabet). Traditional Natural Language Processing (NLP) tools often fail in these contexts due to "out-of-vocabulary" issues stemming from non-standard spellings and phonetic transliterations. This research addresses the critical need for automated offensive language detection in Dravidian languages, specifically Tamil and Malayalam, which remain under-resourced in the global NLP landscape.
Methodology
The researchers developed two ensemble-based architectures to handle the nuances of different datasets:
- Code-Mixed Ensemble (Tamil and Malayalam): This approach utilizes an ensemble of three classic classifiers: Support Vector Machine (SVM), Logistic Regression (LR), and Random Forest (RF). The core of this method lies in extracting character n-grams (1 to 6-grams) converted into TF-IDF features. By focusing on character sequences rather than whole words, the model effectively captures offensive roots despite misspellings or script variations. Final predictions are derived by averaging the probabilities from the three models.
- Script-Mixed Ensemble (Tamil): For the script-mixed Tamil dataset, an AdaBoost ensemble was employed. To ensure robustness, three AdaBoost models were trained on distinct validation splits and their outputs were averaged.
Feature selection played a pivotal role; the study found that utilizing the top 30,000 character n-gram features for code-mixed tasks and the top 50,000 for script-mixed Tamil yielded the best performance.
Datasets
The study utilized data from the HASOC-Dravidian-CodeMix-FIRE2021 challenge, covering three primary streams: Script-mixed Tamil (YouTube comments), Code-mixed Tamil (Tweets), and Code-mixed Malayalam (Tweets). These datasets reflect the inherent noise and class imbalance of real-world social media interactions.
Results and Analysis
Performance was evaluated using weighted $F_1$-scores to account for class imbalances. The models demonstrated significant efficacy, particularly in identifying non-offensive content.
- Tamil Script-mixed: Achieved a weighted $F_1$-score of 0.83.
- Malayalam Code-mixed: Achieved a weighted $F_1$-score of 0.77.
- Tamil Code-mixed: Achieved a weighted $F_1$-score of 0.67.
Analysis of the Tamil script-mixed model revealed a high recall of 0.95 for the "Not-offensive" class, though it struggled more with the "Offensive" class, which had a recall of 0.36. This indicates that while the model is excellent at filtering safe content, identifying the specific nuances of offensive language in script-mixed formats remains a challenge.
Conclusion
This study demonstrates that ensemble techniques combined with character-level features provide a robust baseline for offensive language detection in code-mixed and script-mixed Dravidian languages. While the current models excel at identifying non-offensive text, future work will focus on improving recall for offensive content. Potential avenues include the integration of larger datasets and the application of multilingual transformer models like mBERT or XLM-R, specifically fine-tuned for the unique linguistic patterns of South Indian social media users.
Summary updated