Table of Contents
Fetching ...

LIBRA: Measuring Bias of Large Language Model from a Local Context

Bo Pang, Tingrui Qiao, Caroline Walker, Chris Cunningham, Yun Sing Koh

TL;DR

Bias evaluation for LLMs remains skewed toward US-centric contexts and knowledge boundaries; LIBRA addresses this by automatically constructing local-context bias datasets from regional corpora and introducing the Enhanced Idealized CAT Score ($EiCAT$) to jointly assess bias and vocabulary understanding. The framework computes $L(S)$ for MLMs and CLMs, builds distributions $\\\mathcal{D}_s$ and $\\\mathcal{D}_a$, and uses $JSD(\\\mathcal{D}_a||\\\mathcal{D}_s)$ along with a beyond-knowledge-boundary score $bbs$ to yield $EiCAT$, ensuring bias measurement reflects local linguistic realities. The NZ-based evaluation (367{,}384 articles; 167{,}712 sentences; ~160{,}000 test cases) shows Llama-3 achieves the best $EiCAT$ by handling local vocabulary, while BERT/RoBERTa exhibit higher bias and GPT-2 shows limited language proficiency, underscoring the value of localized data and knowledge-boundary considerations for fair, region-aware LLM use. Collectively, LIBRA offers a scalable, adaptable approach for global bias assessment in diverse cultural contexts and highlights practical implications for developing fair language technologies with regional relevance.

Abstract

Large Language Models (LLMs) have significantly advanced natural language processing applications, yet their widespread use raises concerns regarding inherent biases that may reduce utility or harm for particular social groups. Despite the advancement in addressing LLM bias, existing research has two major limitations. First, existing LLM bias evaluation focuses on the U.S. cultural context, making it challenging to reveal stereotypical biases of LLMs toward other cultures, leading to unfair development and use of LLMs. Second, current bias evaluation often assumes models are familiar with the target social groups. When LLMs encounter words beyond their knowledge boundaries that are unfamiliar in their training data, they produce irrelevant results in the local context due to hallucinations and overconfidence, which are not necessarily indicative of inherent bias. This research addresses these limitations with a Local Integrated Bias Recognition and Assessment Framework (LIBRA) for measuring bias using datasets sourced from local corpora without crowdsourcing. Implementing this framework, we develop a dataset comprising over 360,000 test cases in the New Zealand context. Furthermore, we propose the Enhanced Idealized CAT Score (EiCAT), integrating the iCAT score with a beyond knowledge boundary score (bbs) and a distribution divergence-based bias measurement to tackle the challenge of LLMs encountering words beyond knowledge boundaries. Our results show that the BERT family, GPT-2, and Llama-3 models seldom understand local words in different contexts. While Llama-3 exhibits larger bias, it responds better to different cultural contexts. The code and dataset are available at: https://github.com/ipangbo/LIBRA.

LIBRA: Measuring Bias of Large Language Model from a Local Context

TL;DR

Bias evaluation for LLMs remains skewed toward US-centric contexts and knowledge boundaries; LIBRA addresses this by automatically constructing local-context bias datasets from regional corpora and introducing the Enhanced Idealized CAT Score () to jointly assess bias and vocabulary understanding. The framework computes for MLMs and CLMs, builds distributions and , and uses along with a beyond-knowledge-boundary score to yield , ensuring bias measurement reflects local linguistic realities. The NZ-based evaluation (367{,}384 articles; 167{,}712 sentences; ~160{,}000 test cases) shows Llama-3 achieves the best by handling local vocabulary, while BERT/RoBERTa exhibit higher bias and GPT-2 shows limited language proficiency, underscoring the value of localized data and knowledge-boundary considerations for fair, region-aware LLM use. Collectively, LIBRA offers a scalable, adaptable approach for global bias assessment in diverse cultural contexts and highlights practical implications for developing fair language technologies with regional relevance.

Abstract

Large Language Models (LLMs) have significantly advanced natural language processing applications, yet their widespread use raises concerns regarding inherent biases that may reduce utility or harm for particular social groups. Despite the advancement in addressing LLM bias, existing research has two major limitations. First, existing LLM bias evaluation focuses on the U.S. cultural context, making it challenging to reveal stereotypical biases of LLMs toward other cultures, leading to unfair development and use of LLMs. Second, current bias evaluation often assumes models are familiar with the target social groups. When LLMs encounter words beyond their knowledge boundaries that are unfamiliar in their training data, they produce irrelevant results in the local context due to hallucinations and overconfidence, which are not necessarily indicative of inherent bias. This research addresses these limitations with a Local Integrated Bias Recognition and Assessment Framework (LIBRA) for measuring bias using datasets sourced from local corpora without crowdsourcing. Implementing this framework, we develop a dataset comprising over 360,000 test cases in the New Zealand context. Furthermore, we propose the Enhanced Idealized CAT Score (EiCAT), integrating the iCAT score with a beyond knowledge boundary score (bbs) and a distribution divergence-based bias measurement to tackle the challenge of LLMs encountering words beyond knowledge boundaries. Our results show that the BERT family, GPT-2, and Llama-3 models seldom understand local words in different contexts. While Llama-3 exhibits larger bias, it responds better to different cultural contexts. The code and dataset are available at: https://github.com/ipangbo/LIBRA.

Paper Structure

This paper contains 17 sections, 3 equations, 4 figures, 1 table.

Figures (4)

  • Figure 1: The comparative responses of different LLMs to prompts such as "My karani" or "My karani Tōpia", which is a transliteration between English and Māori "My granny Tōpia", illustrate the challenges faced in local contexts. In multiple generations, the Llama-3 model considers karani to be a model or a car; GPT-2 considers karani to be a cup of coffee. Words in the local context that are beyond the knowledge boundaries of the LLMs severely affect the predictive performance of the LLMs, thus interfering with the test for bias.
  • Figure 2: Build and use a dataset to test the bias of Large Language Models. A fair model should have similar chances of choosing between stereotyped and anti-stereotyped sentences while selecting less irrelevant sentences. However, if the content in the sentence is beyond the knowledge boundaries (shown in the figure as KB) of Large Language Models, it will produce meaningless distribution.
  • Figure 3: Visualisations of Contextual Diversity. Fig. (a) shows BERT embeddings clustering purely English, mixed English-Māori, and solely Māori sentences separately, indicating LLMs' distinct treatment of linguistic variations that could limit effective output across them. Fig. (b) reveals a heatmap of similarities among the top 50 topics from U.S. English and New Zealand-specific corpora, highlighting their significant contextual differences with minimal overlap.
  • Figure 4: Comparison of kernel density estimation (KDE) plots for the log-transformed density of logits across the largest size of tested LLMs in the New Zealand Context. Each subplot represents the distribution of logits, where the X-axis shows the range of logits values, and the Y-axis displays the log-scale density estimation of data points at each logit value. Stereotyped logits are depicted with solid lines, while anti-stereotyped logits are depicted with dashed lines, facilitating a visual comparison of the model’s behaviour towards stereotyped versus anti-stereotyped content. A larger divergence represents the model with a larger bias.