Interactive DualChecker for Mitigating Hallucinations in Distilling Large Language Models

Meiyun Wang,Masahiro Suzuki,Hiroki Sakaji,Kiyoshi Izumi
2024-08-22
Abstract:Large Language Models (LLMs) have demonstrated exceptional capabilities across various machine learning (ML) tasks. Given the high costs of creating annotated datasets for supervised learning, LLMs offer a valuable alternative by enabling effective few-shot in-context learning. However, these models can produce hallucinations, particularly in domains with incomplete knowledge. Additionally, current methods for knowledge distillation using LLMs often struggle to enhance the effectiveness of both teacher and student models. To address these challenges, we introduce DualChecker, an innovative framework designed to mitigate hallucinations and improve the performance of both teacher and student models during knowledge distillation. DualChecker employs ContextAligner to ensure that the context provided by teacher models aligns with human labeling standards. It also features a dynamic checker system that enhances model interaction: one component re-prompts teacher models with more detailed content when they show low confidence, and another identifies borderline cases from student models to refine the teaching templates. This interactive process promotes continuous improvement and effective knowledge transfer between the models. We evaluate DualChecker using a green innovation textual dataset that includes binary, multiclass, and token classification tasks. The experimental results show that DualChecker significantly outperforms existing state-of-the-art methods, achieving up to a 17% improvement in F1 score for teacher models and 10% for student models. Notably, student models fine-tuned with LLM predictions perform comparably to those fine-tuned with actual data, even in a challenging domain. We make all datasets, models, and code from this research publicly available.
Computation and Language,Artificial Intelligence,Computational Engineering, Finance, and Science,Computers and Society
What problem does this paper attempt to address?
The paper primarily aims to address the hallucination problem that occurs during the knowledge distillation process of large language models (LLMs) and to improve the performance of both teacher and student models. Specifically, the paper addresses the following key issues: 1. **Hallucination Problem**: LLMs may produce hallucinations when handling tasks, manifesting as factual inaccuracies or inconsistent responses, which limits their reliability in practical applications. This issue is particularly severe in domains where the LLMs' knowledge is incomplete. 2. **Effectiveness of Knowledge Distillation**: Existing knowledge distillation methods often struggle to simultaneously improve the performance of both teacher and student models. Additionally, these methods typically require extra knowledge bases or pre-training or fine-tuning of the models to achieve high accuracy, which is both time-consuming and costly. To address the above issues, the paper proposes a new framework called DualChecker. DualChecker operates in the following ways: - **Hallucination Mitigation**: It employs ContextAligner to ensure that the model outputs are consistent with human annotation standards and enhances model interaction through a dynamic checking system, effectively reducing the occurrence of hallucinations. - **Improving Knowledge Distillation Performance**: Experimental results show that DualChecker significantly improves the performance of both teacher and student models during the knowledge distillation process, especially in the challenging domain of green innovation. - **Open Source Contribution**: To promote transparency and collaboration in the research field, the authors publicly release all datasets, models, and code. The paper also details the workflow of DualChecker, the definition of related tasks, as well as its experimental setup and result analysis. Experimental results indicate that DualChecker achieves significant performance improvements over other baseline methods across multiple tasks, particularly in few-shot settings. Additionally, the paper explores the impact of different numbers of examples (i.e., "shot" numbers) on DualChecker's performance and how it can enhance the student model's performance through the teacher model's predictions.