mlsanityData to 14 Oct 2026

Fine-Grained Detoxification via Instance-Level Prefixes for Large Language Models

arXiv 2402.15202 ↗First posted 23 Feb 2024cs.CLcited by 0

Not on the map. Why?

Abstract (arXiv)

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 response to certain prompts, thereby constraining their practical utility. To tackle this issue, various finetuning-based and decoding-based approaches have been utilized to mitigate toxicity. However, these methods typically necessitate additional costs such as high-quality training data or auxiliary models. In this paper, we propose fine-grained detoxification via instance-level prefixes (FGDILP) to mitigate toxic text without additional cost. Specifically, FGDILP contrasts the contextualized representation in attention space using a positive prefix-prepended prompt against multiple negative prefix-prepended prompts at the instance level. This allows for constructing fine-grained subtoxicity vectors, which enables collaborative detoxification by fusing them to correct the normal generation process when provided with a raw prompt. We validate that FGDILP enables controlled text generation with regard to toxicity at both the utterance and context levels. Our method surpasses prompt-based baselines in detoxification, although at a slight cost to generation fluency and diversity.

Key facts. No citing papers in the map yet (data through 14 Oct 2026). Builds on 35 of its 47 references that are in the map. First posted on arXiv 23 Feb 2024.

Builds on

35 of 47 references.

References · 35

  1. 2020Language Models are Few-Shot Learnerscited by 32,419
  2. 2023Llama 2: Open Foundation and Fine-Tuned Chat Modelscited by 13,028
  3. 2021Finetuned Language Models Are Zero-Shot Learnerscited by 3,780
  4. 2019The Curious Case of Neural Text Degenerationcited by 2,916
  5. 2020Don't Stop Pretraining: Adapt Language Models to Domains and Taskscited by 1,565
  6. 2020RealToxicityPrompts: Evaluating Neural Toxic Degeneration in Language Modelscited by 1,255
  7. 2023Llama Guard: LLM-based Input-Output Safeguard for Human-AI Conversationscited by 1,207
  8. 2021Scaling Language Models: Methods, Analysis & Insights from Training Gophercited by 1,202
  9. 2015A Diversity-Promoting Objective Function for Neural Conversation Modelscited by 1,077
  10. 2019CTRL: A Conditional Transformer Language Model for Controllable Generationcited by 762
  11. 2022Fine-Tuning can Distort Pretrained Features and Underperform Out-of-Distributioncited by 739
  12. 2023Language Models are Super Mario: Absorbing Abilities from Homologous Models as a Free Lunchcited by 694
23 more
  1. 2023Jailbreaking ChatGPT via Prompt Engineering: An Empirical Studycited by 498
  2. 2021DExperts: Decoding-Time Controlled Text Generation with Experts and Anti-Expertscited by 441
  3. 2020GeDi: Generative Discriminator Guided Sequence Generationcited by 378
  4. 2023Toxicity in ChatGPT: Analyzing Persona-assigned Language Modelscited by 360
  5. 2021Self-Diagnosis and Self-Debiasing: A Proposal for Reducing Corpus-Based Bias in NLPcited by 337
  6. 2023In-context Vectors: Making In Context Learning More Effective and Controllable Through Latent Space Steeringcited by 245
  7. 2023Composing Parameter-Efficient Modules with Arithmetic Operationscited by 156
  8. 2024On Prompt-Driven Safeguarding for Large Language Modelscited by 116
  9. 2023Lift Yourself Up: Retrieval-augmented Text Generation with Self Memorycited by 103
  10. 2023Controlled Text Generation with Natural Language Instructionscited by 87
  11. 2023Model Merging by Uncertainty-Based Gradient Matchingcited by 77
  12. 2022Controllable Natural Language Generation with Contrastive Prefixescited by 75
  13. 2021On the Safety of Conversational Models: Taxonomy, Dataset, and Benchmarkcited by 73
  14. 2022Exploring the Limits of Domain-Adaptive Training for Detoxifying Large-Scale Language Modelscited by 68
  15. 2023Self-Detoxifying Language Models via Toxification Reversalcited by 46
  16. 2022Detoxifying Text with MaRCo: Controllable Revision with Experts and Anti-Expertscited by 36
  17. 2023Separate the Wheat from the Chaff: Model Deficiency Unlearning via Parameter-Efficient Module Operationcited by 33
  18. 2023FFT: Towards Harmlessness Evaluation and Analysis for LLMs with Factuality, Fairness, Toxicitycited by 25
  19. 2023Goodtriever: Adaptive Toxicity Mitigation with Retrieval-augmented Modelscited by 23
  20. 2024Parameter-Efficient Detoxification with Contrastive Decodingcited by 18
  21. 2022Language Detoxification with Attribute-Discriminative Latent Spacecited by 11
  22. 2023Monotonicity for AI ethics and society: An empirical study of the monotonic neural additive model in criminology, education, health care, and financecited by 4
  23. 2023Diagnosing and Debiasing Corpus-Based Political Bias and Insults in GPT2cited by 1

Built on by

Not cited yet.