Back to Article

A Comparative Study of Attention-Based Transformer Networks and Traditional Machine Learning Methods for Toxic Comments Classification

Journal of Social Mathematical & Human Engineering Sciences | Vol 1, Issue 1

Table 1. Metrics Performance of Attention-Based Transformer andTraditional Machine Learning Methods

ModelAccuracyPrecisionRecallF1-Score
Logistic Regression85.25%82.19%88.34%85.15%
Naive Bayes78.42%75.61%82.39%78.05%
Support Vector Machines (SVM)87.62%84.28%89.46%86.14%
Decision Trees80.92%78.12%85.92%80.89%
Random Forests86.79%83.47%88.61%85.23%
Gradient Boosting88.45%85.92%90.11%87.38%
Attention-Based Transformer92.14%89.28%94.13%91.12%
Transformer90.68%87.83%92.04%89.19%