Table of Contents
Fetching ...

Confronting LLMs with Traditional ML: Rethinking the Fairness of Large Language Models in Tabular Classifications

Yanchen Liu, Srishti Gautam, Jiaqi Ma, Himabindu Lakkaraju

TL;DR

The paper investigates the fairness of large language models when applied to tabular classification tasks, addressing whether LLMs inherit and propagate social biases from pretraining. Using GPT-3.5-turbo, it evaluates zero-shot, few-shot, finetuning, and resampling strategies across Adult, German Credit, and COMPAS datasets, comparing to Random Forest and a shallow neural network. Key findings show that biases persist in LLM predictions, with few-shot learning and label flipping able to mitigate bias but at the cost of accuracy, and finetuning offering varied gains while resampling often fails to help. The work argues for developing targeted fairness strategies for LLMs in high-stakes tabular applications and outlines future work across more models and prompting methods.

Abstract

Recent literature has suggested the potential of using large language models (LLMs) to make classifications for tabular tasks. However, LLMs have been shown to exhibit harmful social biases that reflect the stereotypes and inequalities present in society. To this end, as well as the widespread use of tabular data in many high-stake applications, it is important to explore the following questions: what sources of information do LLMs draw upon when making classifications for tabular tasks; whether and to what extent are LLM classifications for tabular data influenced by social biases and stereotypes; and what are the consequential implications for fairness? Through a series of experiments, we delve into these questions and show that LLMs tend to inherit social biases from their training data which significantly impact their fairness in tabular classification tasks. Furthermore, our investigations show that in the context of bias mitigation, though in-context learning and finetuning have a moderate effect, the fairness metric gap between different subgroups is still larger than that in traditional machine learning models, such as Random Forest and shallow Neural Networks. This observation emphasizes that the social biases are inherent within the LLMs themselves and inherited from their pretraining corpus, not only from the downstream task datasets. Besides, we demonstrate that label-flipping of in-context examples can significantly reduce biases, further highlighting the presence of inherent bias within LLMs.

Confronting LLMs with Traditional ML: Rethinking the Fairness of Large Language Models in Tabular Classifications

TL;DR

The paper investigates the fairness of large language models when applied to tabular classification tasks, addressing whether LLMs inherit and propagate social biases from pretraining. Using GPT-3.5-turbo, it evaluates zero-shot, few-shot, finetuning, and resampling strategies across Adult, German Credit, and COMPAS datasets, comparing to Random Forest and a shallow neural network. Key findings show that biases persist in LLM predictions, with few-shot learning and label flipping able to mitigate bias but at the cost of accuracy, and finetuning offering varied gains while resampling often fails to help. The work argues for developing targeted fairness strategies for LLMs in high-stakes tabular applications and outlines future work across more models and prompting methods.

Abstract

Recent literature has suggested the potential of using large language models (LLMs) to make classifications for tabular tasks. However, LLMs have been shown to exhibit harmful social biases that reflect the stereotypes and inequalities present in society. To this end, as well as the widespread use of tabular data in many high-stake applications, it is important to explore the following questions: what sources of information do LLMs draw upon when making classifications for tabular tasks; whether and to what extent are LLM classifications for tabular data influenced by social biases and stereotypes; and what are the consequential implications for fairness? Through a series of experiments, we delve into these questions and show that LLMs tend to inherit social biases from their training data which significantly impact their fairness in tabular classification tasks. Furthermore, our investigations show that in the context of bias mitigation, though in-context learning and finetuning have a moderate effect, the fairness metric gap between different subgroups is still larger than that in traditional machine learning models, such as Random Forest and shallow Neural Networks. This observation emphasizes that the social biases are inherent within the LLMs themselves and inherited from their pretraining corpus, not only from the downstream task datasets. Besides, we demonstrate that label-flipping of in-context examples can significantly reduce biases, further highlighting the presence of inherent bias within LLMs.
Paper Structure (35 sections, 3 equations, 3 figures, 8 tables)

This paper contains 35 sections, 3 equations, 3 figures, 8 tables.

Figures (3)

  • Figure 1: Fairness Comparison of GPT-3.5 Zero-Shot Prompting with RF and NN. We present the absolute differences in ACC, F1, SP, and EoO between subgroups of protected attributes across three datasets: "sex" for Adult and German Credit, and "race" for COMPAS. Notable fairness gaps between protected and non-protected subgroups are observed for GPT-3.5 in a zero-shot prompting manner (GPT-3.5 Zero-Shot), which are significantly larger compared to those observed with RF and NN, except for the German Credit dataset.
  • Figure 2: Fairness Comparison of GPT-3.5 Few-Shot Prompting. We compare the absolute differences in ACC, F1, SP, and EoO between subgroups of protected attributes across the Adult, COMPAS and and German Credit datasets for GPT-3.5 in three settings: zero-shot prompting (GPT-3.5 Zero-Shot), few-shot prompting (GPT-3.5 Few-Shot), and few-shot prompting with flipped labels (GPT-3.5 Few-Shot LF). Incorporating few-shot examples (GPT-3.5 Few-Shot) can partially reduce the inherent biases in GPT-3.5, but it cannot completely eliminate them. The fairness gap persists and is greater than that observed in RF and NN. Furthermore, label-flipped few-shot examples (GPT-3.5 Few-Shot LF) can effectively reverse the bias effects, further narrowing the fairness gaps.
  • Figure 3: Fairness Comparison of GPT-3.5 Finetuning with RF and NN Finetuning. We compare the absolute differences in fairness metrics - ACC, F1, SP, and EoO - between subgroups of protected attributes across the Adult, COMPAS and German Credit datasets for the finetuned GPT-3.5 models using three different approaches: finetuning on the entire training data (GPT-3.5 FT), oversampled data (GPT-3.5 FT OS), and undersampled data (GPT-3.5 FT US). While finetuning GPT-3.5 on task datasets (GPT-3.5 FT) can mitigate inherent social biases to some extent, the application of data resampling techniques (GPT-3.5 FT OS and GPT-3.5 FT US) during the finetuning process does not consistently yield similar results for LLMs compared to the typical mitigation observed in traditional machine learning models.