Jamforande Analys av BERT, FastText, och Perspective API for Effektiv Identifiering av Skadligt Innehall
This study presents a comparative analysis of three AI models: BERT, FastText, and Perspective API, for detecting harmful content in social media communications, focusing on the trade-offs between detection effectiveness and computational efficiency. The research addresses the growing need for scalable and accurate automated content moderation systems, given the limitations of manual review. Using two datasets (Davidson et al. and HateXplain), the study evaluates the models' performance through standard metrics such as F1-score, accuracy, precision, and recall, while also assessing computational metrics like latency and throughput.Surprisingly, FastText, a lightweight embedding-based model, outperformed the more complex BERT and Perspective API in most classification metrics, achieving the highest F1-scores and demonstrating superior computational efficiency. However, FastText showed a conservative classification pattern with higher true negatives and lower false positives, resulting in missing more harmful content compared to the other models. Perspective API, while offering ease of deployment and multilingual support, faced scalability challenges due to rate limits in its free tier. These findings challenge the assumption that advanced deep learning models consistently outperform simpler alternatives in harmful content detection. The study shows the importance of balancing model complexity, detection accuracy, and computational efficiency in practical moderation scenarios. Limitations include dataset biases, English-language focus, and simplified binary classification. Future work could explore hybrid approaches, multilingual datasets, and evolving linguistic trends to enhance moderation systems.
Publication Details
- Journal
- KTH Publication Database DiVA (KTH Royal Institute of Technology)
- Published
- 2025-01-01
- Primary Topic
- Laser-Plasma Interactions and Diagnostics
- Type
- article
- Field-Weighted Citation Impact
- 0.00