Skip to main content
QUICK REVIEW

[Paper Review] Why Is It Hate Speech? Masked Rationale Prediction for Explainable Hate Speech Detection

Jiyun Kim, Byounghan Lee|arXiv (Cornell University)|Nov 1, 2022
Hate Speech and Cyberbullying DetectionComputer Science11 citations
TL;DR

This paper proposes Masked Rationale Prediction (MRP), a two-stage fine-tuning method that improves hate speech detection by training BERT to predict masked human-annotated rationales—context-dependent justification snippets—using surrounding tokens and unmasked rationale embeddings. The approach achieves state-of-the-art performance in bias mitigation, explainability, and detection accuracy on the HateXplain benchmark, particularly excelling in identifying implicit hate speech.

ABSTRACT

In a hate speech detection model, we should consider two critical aspects in addition to detection performance-bias and explainability. Hate speech cannot be identified based solely on the presence of specific words: the model should be able to reason like humans and be explainable. To improve the performance concerning the two aspects, we propose Masked Rationale Prediction (MRP) as an intermediate task. MRP is a task to predict the masked human rationales-snippets of a sentence that are grounds for human judgment-by referring to surrounding tokens combined with their unmasked rationales. As the model learns its reasoning ability based on rationales by MRP, it performs hate speech detection robustly in terms of bias and explainability. The proposed method generally achieves state-of-the-art performance in various metrics, demonstrating its effectiveness for hate speech detection.

Motivation & Objective

  • To address bias and explainability in hate speech detection models, which often rely on specific offensive words rather than contextual reasoning.
  • To improve model robustness in detecting implicit hate speech, where offensive meaning arises from context rather than explicit slurs.
  • To develop a training framework that enables models to learn human-like reasoning by predicting masked rationale segments based on contextual cues.
  • To enhance model explainability by aligning model-generated rationales more closely with human-annotated justification snippets.
  • To achieve state-of-the-art performance across performance-based, bias-based, and explainability-based metrics on the HateXplain benchmark.

Proposed method

  • Transform human-annotated rationales into token-level rationale embeddings and inject them into BERT input embeddings during training.
  • Implement a masked rationale prediction task where a subset of rationale embeddings are replaced with zero vectors, forcing the model to predict the masked rationale tokens.
  • Train BERT in two stages: first on MRP to learn context-aware reasoning, then fine-tune on hate speech detection using the updated parameters.
  • Use the model’s attention weights (via LIME) to evaluate explainability, comparing predicted rationales against human-annotated ground truth.
  • Apply masking ratios (e.g., 50%) during MRP training to balance learning capacity and generalization, optimizing for downstream detection performance.
  • Utilize the HateXplain benchmark’s human-annotated rationales and hate speech labels to train and evaluate the model in a contextually grounded manner.

Experimental results

Research questions

  • RQ1Can a model trained to predict masked human rationales learn more contextually grounded and human-like reasoning for hate speech detection?
  • RQ2Does training on MRP improve both detection performance and robustness against biased predictions based on offensive keywords?
  • RQ3How does MRP compare to alternative methods like direct rationale supervision or masked language modeling in terms of explainability and bias mitigation?
  • RQ4Can MRP enhance detection of implicit hate speech, where offensive meaning is not signaled by explicit slurs?
  • RQ5What masking ratio during MRP yields optimal downstream hate speech detection performance?

Key findings

  • BERT-MRP achieved state-of-the-art performance across all 11 metrics on the HateXplain benchmark, including performance-based, bias-based, and explainability-based scores.
  • The 50% masking ratio in MRP yielded the best downstream hate speech detection performance, indicating optimal balance between supervision and generalization.
  • BERT-MRP outperformed BERT-RP and BERT-HateXplain in rationale alignment with human-annotated ground truth, especially in implicit hate speech cases.
  • The model’s rationale predictions were more consistent with human-annotated rationales than BERT-HateXplain, which suffered from uniform attention when rationales were spread across the sentence.
  • BERT-MRP demonstrated superior robustness in detecting implicit hate speech, where no single offensive word is present, due to its context-aware reasoning mechanism.
  • The method effectively mitigated bias by reducing over-reliance on specific offensive words, as evidenced by improved performance on bias-based metrics.

Read this paper

Open the full text in the Nubint reader and ask about any passage as you read.

Read this paper on Nubint

This review was generated by AI from the original paper. Please check the paper before citing it.