English
Related papers

Related papers: Self-Detoxifying Language Models via Toxification …

200 papers

Pre-trained language models (LMs) are shown to easily generate toxic language. In this work, we systematically explore domain-adaptive training to reduce the toxicity of language models. We conduct this study on three dimensions: training…

Computation and Language · Computer Science 2022-10-25 Boxin Wang , Wei Ping , Chaowei Xiao , Peng Xu , Mostofa Patwary , Mohammad Shoeybi , Bo Li , Anima Anandkumar , Bryan Catanzaro

Large language models (LLMs) are now ubiquitous in user-facing applications, yet they still generate undesirable toxic outputs, including profanity, vulgarity, and derogatory remarks. Although numerous detoxification methods exist, most…

Computation and Language · Computer Science 2025-10-24 Agam Goyal , Vedant Rathi , William Yeh , Yian Wang , Yuen Chen , Hari Sundaram

We propose a method to control the attributes of Language Models (LMs) for the text generation task using Causal Average Treatment Effect (ATE) scores and counterfactual augmentation. We explore this method, in the context of LM…

Computation and Language · Computer Science 2023-10-04 Rahul Madhavan , Rishabh Garg , Kahini Wadhawan , Sameep Mehta

This paper investigates the underlying mechanisms of toxicity generation in Large Language Models (LLMs) and proposes an effective detoxification approach. Prior work typically considers the Feed-Forward Network (FFN) as the main source of…

Computation and Language · Computer Science 2025-05-26 Zenghao Duan , Zhiyi Yin , Zhichao Shi , Liang Pang , Shaoling Jing , Jiayi Wu , Yu Yan , Huawei Shen , Xueqi Cheng

In recent years, the advent of the attention mechanism has significantly advanced the field of natural language processing (NLP), revolutionizing text processing and text generation. This has come about through transformer-based…

Computation and Language · Computer Science 2026-01-13 Zhiyao Zhang , Yazan Mash'Al , Yuhan Wu

This paper investigates using knowledge editing techniques to detoxify Large Language Models (LLMs). We construct a benchmark, SafeEdit, which covers nine unsafe categories with various powerful attack prompts and equips comprehensive…

Computation and Language · Computer Science 2024-05-29 Mengru Wang , Ningyu Zhang , Ziwen Xu , Zekun Xi , Shumin Deng , Yunzhi Yao , Qishen Zhang , Linyi Yang , Jindong Wang , Huajun Chen

Impressive results have been achieved in natural language processing (NLP) tasks through the training of large language models (LLMs). However, these models occasionally produce toxic content such as insults, threats, and profanity in…

Computation and Language · Computer Science 2024-02-27 Xin Yi , Linlin Wang , Xiaoling Wang , Liang He

When trained on large, unfiltered crawls from the internet, language models pick up and reproduce all kinds of undesirable biases that can be found in the data: they often generate racist, sexist, violent or otherwise toxic language. As…

Computation and Language · Computer Science 2021-09-10 Timo Schick , Sahana Udupa , Hinrich Schütze

Existing studies have investigated the tendency of autoregressive language models to generate contexts that exhibit undesired biases and toxicity. Various debiasing approaches have been proposed, which are primarily categorized into…

Computation and Language · Computer Science 2022-05-03 Yoon A Park , Frank Rudzicz

Language models, while capable of generating remarkably coherent and seemingly accurate text, can occasionally produce undesirable content, including harmful or toxic outputs. In this paper, we present a new two-stage approach to detect and…

Machine Learning · Computer Science 2025-11-11 Bao Nguyen , Binh Nguyen , Duy Nguyen , Viet Anh Nguyen

Large Language Models (LLMs) have demonstrated great potential as generalist assistants, showcasing powerful task understanding and problem-solving capabilities. To deploy LLMs as AI assistants, it is crucial that these models exhibit…

Artificial Intelligence · Computer Science 2025-02-12 Huanqian Wang , Yang Yue , Rui Lu , Jingxin Shi , Andrew Zhao , Shenzhi Wang , Shiji Song , Gao Huang

The widespread dissemination of toxic content on social media poses a serious threat to both online environments and public discourse, highlighting the urgent need for detoxification methods that effectively remove toxicity while preserving…

Machine Learning · Computer Science 2025-07-08 Jing Yu , Yibo Zhao , Jiapeng Zhu , Wenming Shao , Bo Pang , Zhao Zhang , Xiang Li

Large language models (LLMs) frequently generate toxic content, posing significant risks for safe deployment. Current mitigation strategies often degrade generation quality or require costly human annotation. We propose CAUSALDETOX, a…

Computation and Language · Computer Science 2026-04-17 Yian Wang , Yuen Chen , Agam Goyal , Hari Sundaram

Large language models can produce toxic or inappropriate text even for benign inputs, creating risks when deployed at scale. Detoxification is therefore important for safety and user trust, particularly when we want to reduce harmful…

Computation and Language · Computer Science 2026-02-04 Baturay Saglam , Dionysis Kalogerias

Large language models (LM) generate remarkably fluent text and can be efficiently adapted across NLP tasks. Measuring and guaranteeing the quality of generated text in terms of safety is imperative for deploying LMs in the real world; to…

Recent generative large language models (LLMs) show remarkable performance in non-English languages, but when prompted in those languages they tend to express higher harmful social biases and toxicity levels. Prior work has shown that…

Computation and Language · Computer Science 2025-06-03 Vera Neplenbroek , Arianna Bisazza , Raquel Fernández

Due to the subtleness, implicity, and different possible interpretations perceived by different people, detecting undesirable content from text is a nuanced difficulty. It is a long-known risk that language models (LMs), once trained on…

Computation and Language · Computer Science 2022-05-26 Yau-Shian Wang , Yingshan Chang

Pre-trained Language Models (PLMs) have shown impressive results in various Natural Language Generation (NLG) tasks, such as powering chatbots and generating stories. However, an ethical concern arises due to their potential to produce…

Computation and Language · Computer Science 2024-06-04 Kaixin Lan , Tao Fang , Derek F. Wong , Yabo Xu , Lidia S. Chao , Cecilia G. Zhao

The field of natural language generation has witnessed significant advancements in recent years, including the development of controllable text generation techniques. However, controlling the attributes of the generated text remains a…

Computation and Language · Computer Science 2024-01-17 Tong Niu , Caiming Xiong , Semih Yavuz , Yingbo Zhou

The spread of toxic content online is an important problem that has adverse effects on user experience online and in our society at large. Motivated by the importance and impact of the problem, research focuses on developing solutions to…

Computation and Language · Computer Science 2023-08-11 Xinlei He , Savvas Zannettou , Yun Shen , Yang Zhang