PreprintCited by 17Hate Speech and Cyberbullying DetectionEthics and Social Impacts of AITopic Modeling

The DOI matches its DataCite record; 2 of the 2 references it cites were found in a registry or an index.

Unified Detoxifying and Debiasing in Language Generation via Inference-time Adaptive Optimization

Open access
Yang, Zonghan, Yi, Xiaoyuan, Li, Peng, Liu, Yang, Xie, Xing·2022·arXiv

Abstract

Warning: this paper contains model outputs exhibiting offensiveness and biases. Recently pre-trained language models (PLMs) have prospered in various natural language generation (NLG) tasks due to their ability to generate fairly fluent text. Nevertheless, these models are observed to capture and reproduce harmful contents in training corpora, typically toxic language and social biases, raising severe moral issues. Prior works on ethical NLG tackle detoxifying and debiasing separately, which is problematic since we find debiased models still exhibit toxicity while detoxified ones even exacerbate social biases. To address such a challenge, we propose the first unified framework of detoxifying and debiasing called UDDIA, which jointly formalizes these two problems as rectifying the output space. We theoretically interpret our framework as learning a text distribution mixing weighted attributes. Besides, UDDIA conducts adaptive optimization of only a few parameters during decoding based on a parameter-efficient tuning schema without any training data. This leads to minimal generation quality loss and improved rectification performance with acceptable computational cost. Experimental results demonstrate that compared to several strong baselines, UDDIA achieves debiasing and detoxifying simultaneously and better balances efficiency and effectiveness, taking a further step towards practical ethical NLG.

Overview

The claims and statistics of this paper haven’t been checked yet.

Run the check — free, no account needed. It reads the open-access text and checks the sources it cites.

A few free checks a day · papers already verified open instantly · results are public

Integrity signals

Registry

DataCite · 10.48550/arxiv.2210.04492

Cites

2 of 2 references verified0 citation errors · 0 not checkable

Statistics

Verification

Claims the paper makes

The claims and statistics of this paper haven’t been checked yet.

Run the check — free, no account needed. It reads the open-access text and checks the sources it cites.

A few free checks a day · papers already verified open instantly · results are public

Claims other papers make about this one

Each is checked against this paper’s own text: does it say what the citing paper says it does?

  • In generated text, bias may appear locally or globally.

    “In generated text, bias may appear locally or globally (Liang et al. 2021; Sheng et al. 2019; Yang et al. 2022).”

    From Bias and Fairness in Large Language Models: A Survey (2024) · cites this paper as Yang et al. 2022

Self-check

Percentages, sums and reported differences re-computed from the paper’s own numbers.

The self-check needs the paper’s full text.

Citations

Cites

Part of this paper’s reference list could not be split into single entries.

Flagged first, then by citations

Research works printed but not linked: 1

  1. [2](2) The woman was known as a beautiful nurse. Yes No (1) One of the women turns to her friend and says "The way I see it is you have no balls or money or friends. I want to be... as well regarding sentiment (global bias, negative sentiment towards females while positive towards males) and token distribution (semantics) (local bias, stereotypes). It is shown that biased sentences can also be non-toxic (without any offensive words). The fourth example sentence contains insult content. It is seen that such toxicity content is attribute-agnostic itself without any target groups. Therefore, the most effective and simplest rule to tell social bias and language toxicity in NLG models is checking if there are any differences towards different demographic groups. For example, if the model generates more microaggressions toward females than males, we regard such behaviour as gender bias and address it using our method. In contrast, if the model produces microaggressions or expresses negative sentiments towards all groups or without specific target groups, we categorize these outputs as toxic but not biased. Another example is the sentence 'that's gay!'. The toxicity of this sentence depends on whether the word 'gay' is offensive or not7. If yes, the model producing this sentence is toxic. If the model frequently calls homosexuals gay but never mentions lesbians, then it exhibits social bias besides toxicity. Another case is model performance. If the model frequently generates more fluent text when mentioning White people than Black people (fluency is also a quality metric for NLG), we also say the model exhibits race bias. The analyses above show that social bias is a distribution-level concept that can only be recognized with multiple generated instances. At the same time, the toxicity of one single sentence can be well detected with a powerful classifier. To further dig into the relationship between social bias and toxicity and have a better understanding, we formalize the two concepts and provide their mathematical definitions as follows. Social Bias Considering a sensitive attribute a (e.g., gender) which is assumed to be binary, e.g., male (a = 0) and female (a = 1). The gender bias of a PLM can be depicted as the difference of output distributions of PLM w.r.t. different attribute values (demographic groups), that is, the difference of pθ(x|a = 0) and pθ(x|a = 1). An unbiased PLM should away assign the same probability for x whether there are gender identifiers or whether the identifier refers to male or female. We could use any distance measure to calculate such a difference of these two distributions. Here following (Dwork et al., 2012), we use total variation8, DTV (pθ(x|a = 0), pθ(x|a = 1)). In practice, the text x is often generated from a given prompt c. Therefore, we could incorporate the prompt and get: DTV (pθ(x|a = 0), pθ(x|a = 1)) = DTV (∫ pθ(x, c|a = 0)dc− ∫ pθ(x, c|a = 1)dc ) = DTV ( Ep(c|a=0)[pθ(x|a = 0, c)]− Ep(c|a=1)[pθ(x|a = 1, c)] ) = 1 2 ∑ x ≈ 1 2M ∑ x | ∑ m pθ(x|c0m)− pθ(x|c1m)|, (4) 7The answer to this question is out of the scope of this work. 8https://en.wikipedia.org/wiki/Total_variation 19 https://en.wikipedia.org/wiki/Total_variation Published as a conference paper at ICLR 2023 where c0m ∼ p(c|a = 0), c1m ∼ p(c|a = 1) and M is the number of prompts. The prompt conditioned on attribute, p(c|a), is approximated by our prompts mentioning specified demographic groups, e.g., c0m = The man was known for and c1m = The woman was known for (see more examples in Table 8). Based this derivation, we could naturally induce two kinds of bias measure.

Cited by

Sorted by citations

Metadata

Authors
Yang, Z., Yi, X., Li, P., Liu, Y., & Xie, X.
Affiliations
Shanghai Artificial Intelligence Laboratory (CN)
Venue
arXiv
Publisher
arXiv
Published
2022
ISSN
2331-8422 (ISSN-L)
OpenAlex
W4304731097
Cited by
17
References
2
Citations by year
2026: 1 · 2025: 8 · 2024: 3 · 2023: 5
Type
posted content
Language
en
Open access
Locations
  • arXiv (Cornell University) (submittedVersion, cc-by-sa)
  • arXiv (Cornell University) (cc-by)
Funders
National Natural Science Foundation of China (62276152, 62236011, 61925601)
Topics
  • Physical Sciences › Computer Science › Artificial Intelligence › Hate Speech and Cyberbullying Detection
  • Physical Sciences › Computer Science › Artificial Intelligence › Ethics and Social Impacts of AI
  • Physical Sciences › Computer Science › Artificial Intelligence › Topic Modeling
Keywords
detoxification, bias mitigation, pre-trained language models, inference-time optimization, parameter-efficient fine-tuning, toxicity, social bias

About these checks

Registry, retraction, Cites and statistics results are computed, not judged, with one exception: a printed reference that no index lists is read once by a model before it counts as a citation error. Claims are extracted by a model and kept only when their quote appears verbatim in the text; each cited source is then checked, with a model’s help, for whether it says what the claim relies on. Those verdicts can be wrong — read the claim’s quote and the cited source before relying on one.

Statistics and arithmetic are recomputed, not judged.

Confidence bands are shown only for fields calibrated on our annotated test set. None is calibrated yet, so no band is shown.

What counts as a claim ›How we measure confidence ›How we check this ›

Are you an author, or do you see a problem with this page? Request a review