Qilin-Med: Multi-stage Knowledge Injection Advanced Medical Large Language Model

📄 arXiv: 2310.09089v2 📥 PDF

作者: Qichen Ye, Junling Liu, Dading Chong, Peilin Zhou, Yining Hua, Fenglin Liu, Meng Cao, Ziming Wang, Xuxin Cheng, Zhu Lei, Zhenhua Guo

分类: cs.CL

发布日期: 2023-10-13 (更新: 2024-04-17)


💡 一句话要点

提出多阶段知识注入方法以提升医疗大语言模型性能

🎯 匹配领域: 支柱二:RL算法与架构 (RL & Architecture) 支柱九:具身大模型 (Embodied Foundation Models)

关键词: 医疗大语言模型 多阶段训练 知识注入 领域特定预训练 监督微调 直接偏好优化 检索增强生成 医学数据集

📋 核心要点

  1. 现有方法在医疗领域的LLMs训练中面临资源消耗大和过度自信预测等挑战。
  2. 本文提出的多阶段训练方法结合了DCPT、SFT和DPO,以更有效地利用领域知识。
  3. Qilin-Med在CMExam测试集上取得了38.4%和40.0%的准确率,超越基线模型Baichuan-7B 7.5%。

📝 摘要(中文)

将大型语言模型(LLMs)应用于医疗领域具有巨大潜力,但面临诸多挑战。针对从零开始预训练医疗领域LLMs的资源消耗和单一依赖监督微调(SFT)导致的过度自信预测问题,本文提出了一种结合领域特定继续预训练(DCPT)、SFT和直接偏好优化(DPO)的多阶段训练方法。此外,我们发布了一个包含医疗问答、文本、知识图谱和对话的3Gb中文医学数据集(ChiMed),并将其分为三个训练阶段。经过该训练流程训练的医疗LLM Qilin-Med在CMExam测试集上取得了显著的性能提升。

🔬 方法详解

问题定义:本文旨在解决在医疗领域训练大型语言模型时的资源消耗和过度自信预测问题。现有方法往往依赖于从零开始的预训练或单一的监督微调,导致模型性能不足。

核心思路:论文提出了一种多阶段训练方法,结合领域特定继续预训练(DCPT)、监督微调(SFT)和直接偏好优化(DPO),以充分利用领域知识并提高模型的预测能力。

技术框架:整体架构分为三个主要阶段:首先进行DCPT以适应医学领域知识,其次进行SFT以优化模型性能,最后通过DPO进一步提升模型的生成质量。

关键创新:最重要的技术创新在于多阶段训练方法的设计,使得模型在不同阶段能够逐步吸收和优化领域知识,显著提升了模型的准确性和生成能力。

关键设计:在训练过程中,采用了特定的损失函数和参数设置,以确保模型在每个阶段都能有效学习和调整。此外,结合了检索增强生成(RAG)方法,进一步提升了模型的性能。

📊 实验亮点

实验结果显示,Qilin-Med在CMExam测试集上的准确率达到了42.8%,相比于SFT阶段的40.0%有了进一步提升。同时,在Huatuo-26M测试集上,Qilin-Med的BLEU-1和ROUGE-1得分分别为16.66和27.44,显示出显著的生成质量提升。这些结果证明了多阶段训练方法在医疗应用中的有效性。

🎯 应用场景

该研究的潜在应用领域包括医疗问答系统、智能诊断助手和医学知识管理等。通过提升医疗领域LLMs的性能,Qilin-Med有望在实际医疗场景中提供更准确的支持,改善患者的医疗体验,并推动医疗人工智能的发展。未来,该模型还可以扩展到其他专业领域的知识注入与应用。

📄 摘要(原文)

Integrating large language models (LLMs) into healthcare holds great potential but faces challenges. Pre-training LLMs from scratch for domains like medicine is resource-heavy and often unfeasible. On the other hand, sole reliance on Supervised Fine-tuning (SFT) can result in overconfident predictions and may not tap into domain-specific insights. In response, we present a multi-stage training method combining Domain-specific Continued Pre-training (DCPT), SFT, and Direct Preference Optimization (DPO). In addition, we publish a 3Gb Chinese Medicine (ChiMed) dataset, encompassing medical question answering, plain texts, knowledge graphs, and dialogues, segmented into three training stages. The medical LLM trained with our pipeline, Qilin-Med, shows substantial performance improvement. In the CPT and SFT phases, Qilin-Med achieved 38.4% and 40.0% accuracy on the CMExam test set, respectively. It outperformed the basemodel Baichuan-7B (accuracy: 33.5%), by 7.5%. In the DPO phase, it scored 16.66 in BLEU-1 and 27.44 in ROUGE-1 on the Huatuo-26M test set, bringing further improvement to the SFT phase (12.69 in BLEU-1 and 24.21 in ROUGE-1). Additionally, we have further enhanced the model's performance through the Retrieval Augmented Generation (RAG) approach. Experiments demonstrate that Qilin-Med-RAG achieves an accuracy rate of 42.8% on CMExam. These results highlight the contribution of our novel training approach in building LLMs for medical applications.