Table of Contents
Fetching ...

Detecting Bias in Large Language Models: Fine-tuned KcBERT

J. K. Lee, T. M. Chung

TL;DR

It is demonstrated that societal bias exists in Korean language models due to language-dependent characteristics, and two methods to mitigate societal bias are proposed.

Abstract

The rapid advancement of large language models (LLMs) has enabled natural language processing capabilities similar to those of humans, and LLMs are being widely utilized across various societal domains such as education and healthcare. While the versatility of these models has increased, they have the potential to generate subjective and normative language, leading to discriminatory treatment or outcomes among social groups, especially due to online offensive language. In this paper, we define such harm as societal bias and assess ethnic, gender, and racial biases in a model fine-tuned with Korean comments using Bidirectional Encoder Representations from Transformers (KcBERT) and KOLD data through template-based Masked Language Modeling (MLM). To quantitatively evaluate biases, we employ LPBS and CBS metrics. Compared to KcBERT, the fine-tuned model shows a reduction in ethnic bias but demonstrates significant changes in gender and racial biases. Based on these results, we propose two methods to mitigate societal bias. Firstly, a data balancing approach during the pre-training phase adjusts the uniformity of data by aligning the distribution of the occurrences of specific words and converting surrounding harmful words into non-harmful words. Secondly, during the in-training phase, we apply Debiasing Regularization by adjusting dropout and regularization, confirming a decrease in training loss. Our contribution lies in demonstrating that societal bias exists in Korean language models due to language-dependent characteristics.

Detecting Bias in Large Language Models: Fine-tuned KcBERT

TL;DR

It is demonstrated that societal bias exists in Korean language models due to language-dependent characteristics, and two methods to mitigate societal bias are proposed.

Abstract

The rapid advancement of large language models (LLMs) has enabled natural language processing capabilities similar to those of humans, and LLMs are being widely utilized across various societal domains such as education and healthcare. While the versatility of these models has increased, they have the potential to generate subjective and normative language, leading to discriminatory treatment or outcomes among social groups, especially due to online offensive language. In this paper, we define such harm as societal bias and assess ethnic, gender, and racial biases in a model fine-tuned with Korean comments using Bidirectional Encoder Representations from Transformers (KcBERT) and KOLD data through template-based Masked Language Modeling (MLM). To quantitatively evaluate biases, we employ LPBS and CBS metrics. Compared to KcBERT, the fine-tuned model shows a reduction in ethnic bias but demonstrates significant changes in gender and racial biases. Based on these results, we propose two methods to mitigate societal bias. Firstly, a data balancing approach during the pre-training phase adjusts the uniformity of data by aligning the distribution of the occurrences of specific words and converting surrounding harmful words into non-harmful words. Secondly, during the in-training phase, we apply Debiasing Regularization by adjusting dropout and regularization, confirming a decrease in training loss. Our contribution lies in demonstrating that societal bias exists in Korean language models due to language-dependent characteristics.
Paper Structure (18 sections, 5 equations, 5 figures, 2 tables)

This paper contains 18 sections, 5 equations, 5 figures, 2 tables.

Figures (5)

  • Figure 1: Various societal biases, including those related to nationality, gender, and race, are evident in KcBERT. In the case of ethnic bias, the top three countries with the highest probability of being predicted in the MASK for 31 countries are represented. This reveals that English and Korean exhibit different predictions for the same question.
  • Figure 2: $LPBS$ performs comparisons between two groups, while $CBS$ extends this analysis to multiple groups.
  • Figure 3: These templates and attribute sets (MASK) represent the measurements for ethnic, gender, and racial biases, along with the target sets (ATTRIBUTE). For ethnicity, we employed three templates, 31 attribute sets, and 55 target sets. For gender and race, one template, two attribute sets, and 55 target sets were used in the experiment.
  • Figure 4: Results of applying debiasing regularization. 4.(a) represents the base model. 4.(b) and 4.(c) depict the results with the application of dropout and L2 regularization individually, while 4.(d) shows the results with both dropout and L2 regularization.
  • Figure 5: Results illustrating the bias in KcBERT and the fine-tuned model. Subfigures 5.(a) and 5.(b) represent ethnic bias, 5.(c) and 5.(d) depict gender bias, and 5.(e) and 5.(f) showcase racial bias.