Self-Supervised Position Debiasing for Large Language Models (2024)

Abstract: Fine-tuning has been demonstrated to be an effective method to improve the domain performance of large language models (LLMs). However, LLMs might fit the dataset bias and shortcuts for prediction, leading to poor generation performance. Previous works have proven that LLMs are prone to exhibit position bias, i.e., leveraging information positioned at the beginning or end, or specific positional cues within the input. Existing debiasing methods for LLMs require external bias knowledge or annotated non-biased samples, which is lacking for position debiasing and impractical in reality. In this work, we propose a self-supervised position debiasing (SOD) framework to mitigate position bias for LLMs. SOD leverages unsupervised responses from pre-trained LLMs for debiasing without relying on any external knowledge. To improve the quality of unsupervised responses, we propose an objective alignment (OAM) module to prune these responses. Experiments on eight datasets and five tasks show that SOD consistently outperforms existing methods in mitigating three types of position biases. Besides, SOD achieves this by sacrificing only a small performance on biased samples, which is general and effective. To facilitate the reproducibility of the results, we share the code of all methods and datasets on https://github.com/LZKSKY/SOD.

## introduction although large language models (llms) have demonstrated remarkable unsupervised ability in various tasks @xcite , fine-tuning still overtakes it under the task-specific setting @xcite . however, fine-tuned llms might rely on the dataset biases and artifacts as shortcuts for prediction, as the fine-tuning datasets are sometimes skewed due to budget constraints @xcite . this results in poor generalization performance when applying fine-tuned llms to unseen * corresponding authors. test data and these models are vulnerable to various types of adversarial attacks @xcite . position bias has been demonstrated to exist across various fine-tuned llms @xcite . specially, the well-known llms, e.g., gpt-3.5 foot_0 , longchat-13b foot_1 , are skilled when the relevant information occurs at the beginning or end of the input context, while the performance significantly degrades when llms need to find relevant information in the middle of the context. analysis of conversational question answering (cqa) on ca-nard @xcite dataset further confirms the existence of position bias. as shown in fig. 1 , 80% of the performance improvement after fine-tuning is attributed to fitting bias on relative positions 0-2. this encourages researchers to engage in position debiasing @xcite . early works mainly focus on mitigating position bias on extractive tasks before the emergence of llms @xcite . a prominent debiasing method is productof-expert (poe), which discourages the extractive model from learning position bias picked up by the fixed biased model @xcite . recently, more and more works focus on debiasing for generative models, e.g., llms @xcite . they adopt either incontext learning (icl) to guide the generation of llm @xcite or prompt tuning (pt) to fine-tune prompts for llms @xcite . however, these works mostly focus on mitigating social bias @xcite , e.g., gender bias and racial bias, leaving position debiasing unexplored. besides, these works cannot be transferred to mitigate position bias, as they require manually annotated non-biased samples for icl or external bias knowledge for pt, which are lacking for position debiasing. to deal with this challenge, we propose to leverage the low position bias characteristics of pre-trained llms. previous studies have shown that pre-trained llms are more robust to position bias @xcite . this is due to the randomness of knowledge utilization in generation during pre-training. as shown in fig. 1 , the rouge-l score of pre-trained t5 fluctuates within the range of 0.2 to 0.4 across almost all relative positions, demonstrating its robustness against position bias. in this paper, we propose a self-supervised position debiasing (sod) framework to mitigate position bias for llms. first, we use a low-bias inference module to collect unsupervised responses with low position bias by applying various prompting strategies. then, we propose an objective alignment (oam) module to prune the unsupervised responses, as low-quality responses will undermine model performance on non-biased samples. finally, we use a multi-objective optimization module to leverage these unsupervised responses for fine-tuning. the whole process does not require any external bias knowledge or non-biased samples, which is self-supervised and general. to verify the effectiveness of sod, we conduct experiments on eight datasets covering five tasks. experimental results show that the sod achieves superior performance in mitigating three types of position bias significantly, including lead bias, relative position bias, and lexical bias. the main contributions of this work are as follows. ## results the overall performances of all methods on language understanding tasks, language creation tasks and language compression tasks are listed in second, sod can mitigate position bias significantly on almost all datasets for three types of tasks. as shown in note that some baselines achieve poor perfor-mance, sometimes lower than base. first, in ## conclusion in this paper, we have proposed a self-supervised debiasing framework sod for llms. it adopts a multi-objective optimization module to mitigate position bias for llms, where unsupervised responses for the debiasing objective are of low position bias. these responses are pruned by a proposed oam module for aligning the task and debiasing objectives. extensive experiments on five tasks and eight benchmark datasets show that sod outperforms existing baselines on non-biased samples while retaining performance or sacrificing little performance on biased samples. it demonstrates that leveraging unsupervised responses is a practicable solution to mitigate position bias for generative llms.