AI Ethics and Bias Mitigation in Large Language Models: An Experimental Analysis of Detection Methods and Debiasing Techniques

26 PAGES (6472 WORDS) Computer Science Paper


Abstract

Large Language Models (LLMs) have demonstrated remarkable capabilities across various domains but have introduced substantial biases that can compromise their effectiveness and fairness in real-world applications [1] [2]. This experimental study investigates the prevalence and manifestation of bias in contemporary LLMs, evaluates existing detection methodologies, and assesses the effectiveness of mitigation strategies. We conducted a comprehensive analysis using multiple bias evaluation frameworks on seven prominent LLMs, including GPT-4, Claude 3.5, and LLaMA 3.1, across diverse demographic and socioeconomic dimensions. Our findings reveal that simulated physicians consistently demonstrated racial, gender, age, political affiliation, and sexual orientation bias in clinical decision-making, with most pairwise comparisons showing statistical significance [3] [4]. Through extensive experiments utilizing publicly available datasets such as BBQ, CrowS-Pairs, and Winogender, we demonstrate the advantages of Bayesian inference using Bayes factors for bias detection and quantification, particularly their capacity to quantify evidence for both competing hypotheses and their robustness to small sample sizes [5]. Our experimental evaluation of debiasing techniques shows that contrastive self-debiasing adapters can be widely applied to any pre-trained language model without changing the internal structure or parameters, preserving language modeling capabilities while effectively reducing social biases [6] [7]. The study concludes with recommendations for comprehensive bias evaluation frameworks and ethical deployment guidelines for LLMs in high-stakes applications.