Zhongjing: Enhancing the Chinese Medical Capabilities of Large Language Model through Expert Feedback and Real-World Multi-Turn Dialogue

Songhua Yang, Hanjie Zhao, Senbin Zhu, Guangyu Zhou, Hongfei Xu, Yuxiang Jia, Hongying Zan

TL;DR

This paper introduces Zhongjing, a novel Chinese medical Large Language Model (LLM) that goes beyond standard fine-tuning by incorporating continuous pre-training, supervised fine-tuning, and Reinforcement Learning from Human Feedback (RLHF). It also presents CMtMedQA, a new multi-turn medical dialogue dataset, to address the limitations of existing models in understanding complex medical conversations and proactive doctor-like inquiry.

What Problem Does This Paper Address?

While general-purpose LLMs like ChatGPT have shown remarkable capabilities, their performance in specialized domains like Chinese medicine is often limited due to a lack of domain expertise. Existing approaches to adapt LLMs for Chinese medicine primarily rely on supervised fine-tuning (SFT) with single-turn or distilled dialogue data. This approach fails to capture the nuances of real-world medical consultations, which are inherently multi-turn, require proactive inquiry from the doctor to fully understand the patient's condition, and demand high accuracy and safety. The paper aims to bridge this gap by developing an LLM that can effectively handle complex medical dialogues, exhibit proactive inquiry, and align with expert medical intentions.

Methods

Zhongjing's development follows a three-stage pipeline:

  1. Continuous Pre-training: The authors start with the Ziya-LLaMA model and further pre-train it on a diverse and high-quality corpus of real medical texts. This stage aims to imbue the model with a strong foundation of medical knowledge.
  2. Supervised Fine-Tuning (SFT): This stage involves training the pre-trained model on four types of instruction datasets: single-turn medical dialogues, multi-turn medical dialogues (from their new dataset), natural language processing tasks, and general dialogues. This step enhances the model's generalization and understanding abilities.
  3. Reinforcement Learning from Human Feedback (RLHF): This is a crucial stage for aligning the model with expert intentions and ensuring safety. The authors developed a refined annotation rule for ranking model-generated dialogues across dimensions like safety, professionalism, and fluency. Six medical experts ranked 20,000 sentences, which were used to train a reward model. This reward model then guided the LLM's updates using the Proximal Policy Optimization (PPO) algorithm, further refining its responses to be more accurate, safe, and aligned with expert preferences.

Datasets

  • CMtMedQA: A newly introduced dataset comprising approximately 70,000 multi-turn Chinese medical dialogues and 400,000 conversations. It covers 14 medical departments and includes numerous proactive inquiry statements, designed to mimic real doctor-patient interactions. The dataset was constructed from real doctor-patient dialogues, with responses normalized for consistency and professionalism.
  • Medical Text Corpus: A diverse collection of real medical texts from various sources, including textbooks, electronic health records, clinical diagnosis records, and consultation dialogues, used for continuous pre-training.
  • Benchmark Test Datasets: The paper evaluates Zhongjing on the CMtMedQA test set and the huatuo26M-test dataset.

Key Insights and Ideas

  • Multi-turn Dialogue is Crucial: Real medical consultations are not single-turn exchanges. The ability to engage in extended, proactive dialogues is essential for accurate diagnosis and effective patient interaction.
  • RLHF is Key for Medical Alignment: Simply fine-tuning on medical data isn't enough. RLHF, guided by expert feedback, is vital for ensuring safety, professionalism, and adherence to medical ethics, which are paramount in this domain.
  • Data Diversity and Quality Matter: A broad and high-quality pre-training corpus, combined with a carefully curated multi-turn dialogue dataset, significantly enhances a model's medical capabilities.
  • Proactive Inquiry is a Differentiator: Existing models often struggle with proactive inquiry. Zhongjing's design, particularly with the CMtMedQA dataset, aims to equip it with this doctor-like ability.
  • Scaling Laws Still Hold: While Zhongjing shows significant improvements, it still falls behind larger models like ChatGPT in certain aspects, highlighting the continued importance of model scale.

Key Results

  • Zhongjing outperforms previous Chinese medical LLMs across all evaluated dimensions (safety, professionalism, fluency).
  • It matches ChatGPT's performance in some areas, despite having only 1% of its parameters.
  • Ablation studies show that continuous pre-training significantly improves "Professional" capabilities, while RLHF notably enhances safety and response length.
  • The CMtMedQA dataset demonstrably improves the model's ability to handle complex multi-turn dialogues and initiate proactive inquiries.

Limitations and Future Work

  • Accuracy Guarantee: Zhongjing cannot guarantee 100% accuracy in all responses. The authors strongly advise users to exercise caution and seek expert advice for medical information.
  • Hallucination Problem: Eliminating hallucinations in medical LLMs remains a significant challenge.
  • Future Directions: The authors plan to focus on improving safety, integrating more real-world data, and incorporating multimodal information for a more holistic medical service. They also aim to further explore how to eliminate hallucinations and better align LLMs with human experts. Zhongjing is currently positioned as a research tool rather than a replacement for professional medical consultation.

Summary updated

Abstract

Recent advances in Large Language Models (LLMs) have achieved remarkable breakthroughs in understanding and responding to user intents. However, their performance lag behind general use cases in some expertise domains, such as Chinese medicine. Existing efforts to incorporate Chinese medicine into LLMs rely on Supervised Fine-Tuning (SFT) with single-turn and distilled dialogue data. These models lack the ability for doctor-like proactive inquiry and multi-turn comprehension and cannot align responses with experts' intentions. In this work, we introduce Zhongjing, the first Chinese medical LLaMA-based LLM that implements an entire training pipeline from continuous pre-training, SFT, to Reinforcement Learning from Human Feedback (RLHF). Additionally, we construct a Chinese multi-turn medical dialogue dataset of 70,000 authentic doctor-patient dialogues, CMtMedQA, which significantly enhances the model's capability for complex dialogue and proactive inquiry initiation. We also define a refined annotation rule and evaluation criteria given the unique characteristics of the biomedical domain. Extensive experimental results show that Zhongjing outperforms baselines in various capacities and matches the performance of ChatGPT in some abilities, despite the 100x parameters. Ablation studies also demonstrate the contributions of each component: pre-training enhances medical knowledge, and RLHF further improves instruction-following ability and safety. Our code, datasets, and models are available at https://github.com/SupritYoung/Zhongjing.
BibTeX
@inproceedings{yang2024zhongjing,
  author = {Songhua Yang and Hanjie Zhao and Senbin Zhu and Guangyu Zhou and Hongfei Xu and Yuxiang Jia and Hongying Zan},
  title = {{Zhongjing: Enhancing the Chinese Medical Capabilities of Large Language Model through Expert Feedback and Real-World Multi-Turn Dialogue}},
  booktitle = {AAAI Conference on Artificial Intelligence},
  year = {2024},
  doi = {10.1609/aaai.v38i17.29907},
}
Figure