# Exploring ChatGPT for Toxicity Detection in GitHub

arXiv: https://arxiv.org/abs/2312.13105 · HTML: https://mlsanity.com/paper/2312.13105/

## Key facts

- Cited by 16 papers in the map (data through 14 Oct 2026).
- First posted on arXiv 20 Dec 2023.

## Built on by (most cited first, 16 of 16)

- ["They are uncultured": Unveiling Covert Harms and Social Threats in LLM Generated Conversations](https://mlsanity.com/paper/2405.05378/) (2024)
- [ValueScope: Unveiling Implicit Norms and Values via Return Potential Model of Social Interactions](https://mlsanity.com/paper/2407.02472/) (2024)
- [Reflections on the Reproducibility of Commercial LLM Performance in Empirical Software Engineering Studies](https://mlsanity.com/paper/2510.25506/) (2025)
- [DeMod: A Holistic Tool with Explainable Detection and Personalized Modification for Toxicity Censorship](https://mlsanity.com/paper/2411.01844/) (2024)
- [ABLEIST: Intersectional Disability Bias in LLM-Generated Hiring Scenarios](https://mlsanity.com/paper/2510.10998/) (2025)
- [MythTriage: Scalable Detection of Opioid Use Disorder Myths on a Video-Sharing Platform](https://mlsanity.com/paper/2506.00308/) (2025)
- [Leveraging Large Language Models and Topic Modeling for Toxicity Classification](https://mlsanity.com/paper/2411.17876/) (2024)
- [How Toxic Can You Get? Search-based Toxicity Testing for Large Language Models](https://mlsanity.com/paper/2501.01741/) (2025)
- [Combating Toxic Language: A Review of LLM-Based Strategies for Software Engineering](https://mlsanity.com/paper/2504.15439/) (2025)
- ["Harmless to You, Hurtful to Me!": Investigating the Detection of Toxic Languages Grounded in the Perspective of Youth](https://mlsanity.com/paper/2508.02094/) (2025)
- [Rethinking Code Review in the Age of AI: A Vision for Agentic Code Review](https://mlsanity.com/paper/2605.17548/) (2026)
- [Can AI Agents Synthesize Scientific Conclusions?](https://mlsanity.com/paper/2606.11337/) (2026)
- [Unveiling Social Media Comments with a Novel Named Entity Recognition System for Identity Groups](https://mlsanity.com/paper/2405.13011/) (2024)
- [Robust Persona-Aware Toxicity Detection with Prompt Optimization and Learned Ensembling](https://mlsanity.com/paper/2601.02337/) (2026)
- [Power Echoes: Investigating Moderation Biases in Online Power-Asymmetric Conflicts](https://mlsanity.com/paper/2603.01457/) (2026)
- [Machine Learning Models for the Early Detection of Burnout in Software Engineering: a Systematic Literature Review](https://mlsanity.com/paper/2603.23063/) (2026)

## Abstract (arXiv)

Fostering a collaborative and inclusive environment is crucial for the sustained progress of open source development. However, the prevalence of negative discourse, often manifested as toxic comments, poses significant challenges to developer well-being and productivity. To identify such negativity in project communications, especially within large projects, automated toxicity detection models are necessary. To train these models effectively, we need large software engineering-specific toxicity datasets. However, such datasets are limited in availability and often exhibit imbalance (e.g., only 6 in 1000 GitHub issues are toxic), posing challenges for training effective toxicity detection models. To address this problem, we explore a zero-shot LLM (ChatGPT) that is pre-trained on massive datasets but without being fine-tuned specifically for the task of detecting toxicity in software-related text. Our preliminary evaluation indicates that ChatGPT shows promise in detecting toxicity in GitHub, and warrants further investigation. We experimented with various prompts, including those designed for justifying model outputs, thereby enhancing model interpretability and paving the way for potential integration of ChatGPT-enabled toxicity detection into developer communication channels.
