A Review of Standard Text Classification Practices for Multi-label Toxicity Identification of Online Content

Isuru Gunasekara, Isar NejadgholiEMNLP 2018

TL;DR

This paper reviews standard text classification techniques for identifying toxic content in online conversations, focusing on the trade-offs between model accuracy and inference complexity. They find that character-level representations and advanced neural network architectures, combined with semi-supervised learning, significantly improve toxicity detection performance.

What Problem Does This Paper Address?

The internet, particularly social media, is rife with toxic and abusive content, creating an unsafe online environment. While governments and platforms have incentives to combat this, accurately detecting and removing such content is challenging. Simply classifying content as "toxic" or "non-toxic" is insufficient, as it can lead to over-censorship and impact user freedom of speech. The authors argue for a more nuanced approach: classifying the type and level of toxicity. This multi-label classification task is complex due to the colloquial, inconsistent, and evolving nature of online language, requiring large annotated datasets. The paper aims to evaluate various standard text classification methods for this task, considering both performance and practical deployment considerations.

Methods

The authors explore several text classification approaches:

  • Text Representation: They compare traditional frequency-based methods like TF-IDF (term frequency-inverse document frequency) at both word and character levels. They also investigate word embeddings, including custom-trained fastText embeddings and pre-trained GloVe and fastText vectors.
  • Classification Models:
    • SVM (Support Vector Machine): A baseline one-vs-rest SVM classifier is used to evaluate different text representations.
  • Neural Networks: They employ recurrent neural networks (specifically bi-LSTM and bi-GRU) and attention mechanisms to capture sequential and contextual information in text.
  • Stacking Classifiers: A Light Gradient Boosting Machine (LGBM) is used to combine predictions from multiple classifiers, leveraging their diverse strengths.
  • Semi-Supervised Learning: Pseudo-labeling is used to augment the training data by using predictions from a strong classifier on unlabeled data.

Datasets

The primary dataset used is the Wikimedia Toxicity Data Set. This dataset, originally from a Kaggle competition, contains approximately 215,000 annotated examples from Wikipedia Talk Pages. The labels include seven categories: neutral, toxic, severe toxic, obscene, threat, insult, and identity hate. The dataset is noted for being highly unbalanced, with some toxic categories appearing much more frequently than others.

Key Insights and Ideas

  • Character-level representations are crucial for online text: For informal and conversational text, character-level TF-IDF significantly outperforms word-level TF-IDF, highlighting the importance of capturing sub-word patterns and misspellings common in online language.
  • Advanced neural networks offer marginal gains over strong baselines: While SVMs with character-level features perform well, neural network models (bi-LSTM, attention) provide a slight improvement in AUC.
  • Stacking classifiers can boost performance: Combining multiple classifiers, particularly with LGBM, offers a modest but consistent improvement in accuracy.
  • Semi-supervised learning is effective for improving performance: Pseudo-labeling, by leveraging unlabeled data, leads to notable improvements in AUC scores, especially when dealing with limited labeled data.
  • The trade-off between accuracy and complexity matters: The authors emphasize that the "best" model depends on the application's requirements, balancing predictive accuracy with the computational cost of inference.

Key Results

  • A conventional one-vs-rest SVM with character and word level TF-IDF achieved an ROC AUC score of 0.9763.
  • Leveraging advanced technologies like word embeddings, recurrent neural networks, attention mechanisms, stacking, and semi-supervised training improved the ROC AUC score to 0.9862.
  • Specifically, a bi-LSTM model achieved 0.9842 AUC, and a bi-LSTM with attention achieved 0.9844 AUC.
  • The LGBM stacking model reached 0.9847 AUC.
  • Semi-supervised training improved the AUC scores of the neural network classifiers to 0.9860 and 0.9862.

Limitations and Future Work

  • Dataset Imbalance: The dataset is highly unbalanced, which is a common challenge in toxicity detection and can bias model performance.
  • Inference Complexity: While advanced models show higher accuracy, their computational cost for inference might be prohibitive for real-time applications. The paper suggests considering this trade-off.
  • Subjectivity of Toxicity: The definition and perception of toxicity can be subjective, making annotation and model evaluation inherently challenging.
  • Future Work: The paper implicitly suggests further exploration into optimizing the balance between accuracy and inference speed, potentially through model compression or more efficient architectures. The authors also mention the development of a toxicity identification tool alongside this paper, indicating a practical application focus.

Summary updated

BibTeX
@inproceedings{gunasekara2018review,
  author = {Isuru Gunasekara and Isar Nejadgholi},
  title = {{A Review of Standard Text Classification Practices for Multi-label Toxicity Identification of Online Content}},
  booktitle = {Conference on Empirical Methods in Natural Language Processing},
  year = {2018},
}
Figure