Combating Toxic Language: A Review of LLM-Based Strategies for Software Engineering

Hao Zhuo, Yicheng Yang, Kewen Peng
4/21/2025
cs.LGcs.SE

No confident code implementation found for this paper.

Abstract

Large Language Models (LLMs) have become integral to Software Engineering (SE), increasingly used in development workflows. However, their widespread adoption raises concerns about the presence and propagation of toxic language - harmful or offensive content that can foster exclusionary environments. This paper provides a comprehensive review of recent research (2020-2024) on toxicity detection and mitigation, focusing on both SE-specific and general-purpose datasets. We examine annotation and pre-processing techniques, assess detection methodologies, and evaluate mitigation strategies, particularly those leveraging LLMs. Additionally, we conduct an ablation study demonstrating the effectiveness of LLM-based rewriting for reducing toxicity. This review is limited to studies published within the specified timeframe and within the domain of toxicity in LLMs and SE; therefore, certain emerging methods or datasets beyond this period may fall outside its purview. By synthesizing existing work and identifying open challenges, this review highlights key areas for future research to ensure the responsible deployment of LLMs in SE and beyond.

View on arXivView PDF

Code Implementations

No confident code match yet

We couldn't find an author-owned or strongly-evidenced community implementation for this paper. Any repos shown below are weak matches — verify before relying on them.

No code implementations found yet.

Know of an implementation? Let us know in the comments below!

Similar Papers

Cite this paper

@article{zhuo2025combating,
  title  = {Combating Toxic Language: A Review of LLM-Based Strategies for Software Engineering},
  author = {Hao Zhuo and Yicheng Yang and Kewen Peng},
  year   = {2025},
  eprint = {2504.15439},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2504.15439v2}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2504.15439.svg)](https://codeofpaper.com/paper/2504.15439)

Discussion