PEACE: Cross-Platform Hate Speech Detection - A Causality-Guided Framework

Paaras Sheth, Tharindu Kumarage, Raha Moraffah, Aman Chadha, Huan Liu

TL;DR

This paper introduces PEACE, a novel framework for hate speech detection that leverages "causal cues" – specifically, overall sentiment and aggression – to improve generalization across different social media platforms. By focusing on these inherent linguistic signals, PEACE aims to overcome the limitations of traditional methods that rely on platform-specific features or auxiliary information, leading to more robust hate speech detection.

What Problem Does This Paper Address?

The proliferation of hate speech on social media poses a significant challenge for online platforms. Detecting and moderating this harmful content is crucial, but building effective hate speech detection models is difficult due to several factors:

  • Platform Diversity: Different social media platforms have varying policies and user communities, leading to diverse ways hate speech is expressed. This "distribution shift" makes models trained on one platform perform poorly on another.
  • Data Scarcity: Obtaining large, labeled datasets for hate speech detection is labor-intensive and emotionally taxing, especially for less common platforms or specific types of hate speech.
  • Limitations of Existing Methods: Current cross-platform generalization approaches often rely on linguistic cues (like specific words or POS tags) or auxiliary information (like user profiles or post implications). These methods can be brittle, as they might overfit to platform-specific language patterns or require information that isn't universally available.

The core problem is developing hate speech detection models that can generalize well across different platforms and contexts, even when faced with subtle or implicit forms of hate speech.

Methods

The proposed framework, PEACE (Platform-independent causal Cues for generalizable hatE speech detection), tackles this problem by employing a causality-guided approach. Instead of relying on superficial linguistic features, PEACE focuses on two intrinsic "causal cues" believed to be fundamental to hateful content:

  1. Sentiment Module: This module uses a pre-trained transformer-based language model (RoBERTa-base) fine-tuned for sentiment analysis. It learns to predict the overall sentiment (positive, neutral, negative) of a given text.
  2. Aggression Module: Similar to the sentiment module, this component also uses a fine-tuned RoBERTa-base model to classify text as aggressive or non-aggressive.

These two modules act as "cue extractors." The key innovation lies in how these cues are integrated:

  • Attention Extraction: The framework extracts attention vectors from the final encoder blocks of both the sentiment and aggression modules. These vectors highlight which tokens in the input text are most important for determining sentiment and aggression.
  • Cue Integration: The extracted attention vectors from both modules are concatenated and then fed into an "attention selector head." This is a fully connected neural network that learns to weigh the importance of sentiment and aggression cues dynamically, depending on the context. This weighted combination forms a final causal cue vector.
  • Hate Detector: A separate transformer encoder stack acts as the hate detector. It takes the original input text and the integrated causal cue vector as auxiliary input. The model learns to adjust its representations to incorporate these causal signals, aiming to produce a more generalizable representation for hate speech detection.

Crucially, the weights of the sentiment and aggression cue extractor modules are frozen during the end-to-end training of the hate detector, preventing them from overfitting to the specific hate speech data.

Datasets

The paper evaluates PEACE on several widely used benchmark datasets for hate speech detection, focusing on cross-platform generalization. The datasets include:

  • GAB: Posts from the GAB social media platform.
  • Reddit: Conversation threads from the Reddit platform.
  • Wikipedia: Comments from the Wikipedia website.
  • Twi-Red-You: Social media comments from Twitter, Reddit, and YouTube.
  • FRENK: Facebook comments targeting LGBTQ and Migrants (English subset).

These datasets represent different platforms and distributions, allowing for robust evaluation of cross-platform generalization.

Key Insights and Ideas

  • Causality as a Generalization Tool: The core idea is that inherent causal cues like sentiment and aggression are less susceptible to distribution shifts than superficial linguistic features, making them powerful for cross-platform generalization.
  • Sentiment and Aggression are Key: The research strongly suggests that these two cues, often overlooked in favor of direct hate speech lexicons, are fundamental indicators of hateful content.
  • Dynamic Weighting of Cues: The attention selector head is crucial, allowing the model to learn when sentiment is a stronger indicator of hate than aggression, and vice-versa, for a given piece of text.
  • Implicit Hate Detection: The case studies highlight PEACE's ability to identify implicit hate speech, where direct hateful terms are absent, by attending to subtle sentiment and aggression cues.
  • Limitations of Lexical Approaches: The paper demonstrates that relying solely on specific words or phrases can be insufficient, especially when hate speech is expressed indirectly or with grammatical inconsistencies.

Key Results

  • State-of-the-Art Cross-Platform Performance: PEACE consistently achieves the best or second-best performance across various cross-platform evaluation settings, outperforming strong baselines like HateBERT and HateXplain.
  • Significant Improvements: PEACE shows improvements of 3-6% in macro F1 score for cross-platform generalization compared to baselines on datasets like GAB, Reddit, and Wikipedia.
  • Importance of Causal Cues: Ablation studies reveal that removing either the sentiment or aggression cue can lead to a performance drop of 5-13%, underscoring their importance.
  • Aggression as a Stronger Cue: For some datasets, the aggression cue appears to be a slightly stronger predictor of hate speech than sentiment, aligning with psychological theories linking aggression to hatred.
  • Case Study Success: Visualizations show PEACE effectively attending to key phrases and words indicative of hate, even in implicit cases, where other models struggle.

Limitations and Future Work

  • Manual Identification of Cues: The current PEACE framework relies on manually identified causal cues (sentiment and aggression). Future work could explore automating the identification of these cues for a fully end-to-end system.
  • Contextual Information: While PEACE focuses on individual posts, incorporating conversational context could further enhance generalization capabilities.
  • Implicit Hate Challenges: The paper notes that detecting implicit hate speech remains challenging, and further research is needed to improve performance in such scenarios.
  • Ethical Considerations: The authors emphasize that while their system aims to mitigate harmful content, false positives could lead to censoring legitimate speech. They recommend human oversight for any real-world automated moderation system.

Summary updated

BibTeX
@inproceedings{sheth2023peace,
  author = {Paaras Sheth and Tharindu Kumarage and Raha Moraffah and Aman Chadha and Huan Liu},
  title = {{PEACE: Cross-Platform Hate Speech Detection - A Causality-Guided Framework}},
  booktitle = {Ecml/pkdd},
  year = {2023},
  url = {https://openreview.net/forum?id=ITSncchXfJ},
}
Figure