ACL2023

CFL: Causally Fair Language Models Through Token-level Attribute Controlled Generation

Rahul Madhavan, Rishabh Garg, Kahini Wadhawan, Sameep Mehta

摘要

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 detoxification, and propose the Causally Fair Language (CFL) architecture for detoxifying pre-trained LMs in a plug-and-play manner. Our architecture is based on a Structural Causal Model (SCM) that is mathematically transparent and computationally efficient as compared with many existing detoxification techniques. We also propose several new metrics that aim to better understand the behaviour of LMs in the context of toxic text generation. Further, we achieve state of the art performance for toxic degeneration, which are computed using REALTOXICITYPROMPTS (RTP) benchmark. Our experiments show that CFL achieves such a detoxification without much impact on the model perplexity. We also show that CFL mitigates the unintended bias problem through experiments on the BOLD dataset. Method Model Name Reference Data Based Approaches ATCON Gehman et al. (2020) DAPT Gururangan et al. (2020) CTRL Keskar et al. (2019) Fine-tuning Approaches GEDI Krause et al. (2020) DEXPERTS Liu et al. (2021) Decoding time Approaches VOCAB-SHIFT Gehman et al. (2020) WORD FILTER Gehman et al. (2020) PPLM Dathathri et al. (2019) Reward Modelling Reinforce-DeToxify Faal et al. (2022) Causal text classification C 2 L Choi et al. (2022) Causal ATE fine-tuning CFL Our Approach