NeurIPS 2026Coming to NeurIPS?Explore papers, orals & directions

Facilitating Fine-grained Detection of Chinese Toxic Language: Hierarchical Taxonomy, Resources, and Benchmarks

Junyu Lu, Bo Xu, Xiaokun Zhang, Changrong Min, Liang Yang, Hongfei Lin

Introduction: The Challenge of Implicit Toxicity

While toxic language detection has seen significant progress in English, research in Chinese has historically faced three major hurdles: a lack of granularity, the difficulty of detecting implicit toxicity, and a shortage of comprehensive insult lexicons. Standard models often fail to distinguish between general offensive language and targeted hate speech. Furthermore, they struggle with indirect toxicity—such as irony, metaphors, or "reporting" (quoting others' hate speech)—which is prevalent in Chinese social media. For instance, the term "fairy" (小仙女), typically positive, is frequently used ironically to attack women.

The MONITOR TOXIC FRAME Taxonomy

To address the lack of granularity, the researchers developed the MONITOR TOXIC FRAME, a hierarchical taxonomy designed to guide fine-grained annotation across four distinct levels. This framework moves beyond binary classification to capture the nuance of intent and expression.

The MONITOR TOXIC FRAME hierarchical taxonomy for annotating toxic content.

The taxonomy asks four key questions to determine the nature of the content:

  1. Is it toxic? (Binary Label)
  2. Is it general offense or hate speech? (Toxic Type Label)
  3. Who is the targeted group? (Group Label: Sexism, Racism, Regional Bias, LGBTQ)
  4. What is the expression type? (Category Label: Explicit, Implicit, or Reporting)

The ToxiCN Dataset

The authors introduced ToxiCN, a dataset of 12,011 comments sourced from Zhihu and Tieba. Unlike previous datasets, ToxiCN is relatively balanced (53.8% toxic) and includes detailed labels for toxic types and expression categories. It specifically targets high-conflict areas such as gender, race, and regional bias.

Examples of toxic content from the ToxiCN dataset, illustrating different toxic types and expression categories.

As shown in the examples above, "reporting" cases (Exp 4) and implicit insults (Exp 3) present significant challenges for automated systems, as they require contextual understanding beyond simple keyword matching. The research highlights that data from Zhihu tended to be more subtle and implicit, whereas Tieba users were often more direct.

Toxic Knowledge Enhancement (TKE)

To improve detection, the researchers proposed Toxic Knowledge Enhancement (TKE). This method utilizes a custom insult lexicon of 1,032 terms to identify potential toxic tokens via n-gram matching. It then injects a "toxic embedding"—a vector representing the category of the insult—into the standard word embeddings of a sequence encoder like BERT or RoBERTa. This process effectively "flags" suspicious terms for the model, providing it with external lexical knowledge to better decode irony and metaphors.

Key Results and Insights

The TKE method was benchmarked against several baselines, including BiLSTM and RoBERTa.

  • Performance Gains: TKE improved performance across almost all subtasks, with the most significant gains (2.7% on average) in "Expression Category" detection.
  • Top Performer: The RoBERTa model enhanced with TKE (RoBERTa*) achieved the best results, with an F1-score of 80.6% for toxic identification and 73.0% for targeted group detection.
  • Implicit vs. Explicit: Accuracy for implicit expressions remains roughly 10% lower than for explicit ones, highlighting the ongoing difficulty of decoding irony without deep background knowledge.
  • Commercial Comparison: These models significantly outperformed commercial tools like the Baidu Text Censor API, which relies heavily on keyword dictionaries and struggles with indirect expressions.

Conclusion

The introduction of the MONITOR TOXIC FRAME and the ToxiCN dataset provides a robust foundation for more nuanced Chinese toxic language detection. By integrating lexical knowledge through TKE, the researchers have demonstrated a viable path toward capturing the subtle, implicit forms of hate speech that currently evade standard moderation tools. Future work will look toward integrating multimodal data and deeper commonsense knowledge to further refine these detection capabilities.

Summary updated

BibTeX
@inproceedings{lu2023facilitating,
  author = {Junyu Lu and Bo Xu and Xiaokun Zhang and Changrong Min and Liang Yang and Hongfei Lin},
  title = {{Facilitating Fine-grained Detection of Chinese Toxic Language: Hierarchical Taxonomy, Resources, and Benchmarks}},
  booktitle = {Annual Meeting of the Association for Computational Linguistics},
  year = {2023},
  doi = {10.18653/v1/2023.acl-long.898},
}
Figure