Abstract
Xiangru Tang, Chunyuan Deng, Hanmin Wang, Haoran Wang, Yilun Zhao, Wenqi Shi, May Fung, Wangchunshu Zhou, Jiannan Cao, Heng Ji, Arman Cohan, Mark Gerstein. Proceedings of the 2024 Conference on Empirical Methods in Natural Language Processing: System Demonstrations.
2024.
Introduction
While large language models (LLMs) like GPT-4 exhibit impressive reasoning and tool-use capabilities, they remain "black boxes" that pose significant privacy risks, particularly when handling sensitive scientific data such as Electronic Health Records (EHR) or proprietary research. Open-source models like LLaMA2 provide a private alternative but often lack "agentic" capabilities—the ability to plan, utilize external tools, and engage in complex, multi-step reasoning. This deficiency stems from a lack of high-quality "agent-tuning" data, which focuses on multi-turn interactions and tool use rather than simple question-answering.
MIMIR addresses this gap as an end-to-end platform designed to transform open-source LLMs into specialized scientific agents. By leveraging role-playing simulations and integrated search tools, MIMIR generates high-quality, multi-turn instruction data, allowing researchers to fine-tune smaller models that rival proprietary giants while maintaining data sovereignty.
Methodology
MIMIR introduces a comprehensive workflow that transitions from raw data to a deployed agent through several key stages:
- Multi-role Simulation: The platform employs a role-playing methodology where larger LLMs simulate interactions between diverse personas (e.g., doctor, patient, medical student). This creates realistic, multi-turn dialogue trajectories.
- Tool & Reasoning Integration: Unlike standard instruction-tuning datasets, MIMIR incorporates a "Tool Pool" (including Google Search, Tavily, and Wikipedia APIs) and "Reasoning Frameworks" (such as ReAct, Chain-of-Thought, and Reflexion). This ensures training data includes explicit "thinking" and "acting" steps.
- Knowledge Verification: To mitigate hallucinations, a fine-grained verification module extracts and validates key facts within the generated datasets.
- One-Click Fine-Tuning: The platform features a user-friendly interface for parameter-efficient fine-tuning using Low-Rank Adaptation (LoRA), lowering the barrier for scientific researchers.
Datasets and Domain Focus
The authors integrated a library of 520 scientific datasets from Hugging Face. For biomedical evaluation, the platform utilized benchmarks including MedQA (USMLE questions), MedMCQA, PubMedQA, and MMLU Clinical Topics.
Comparison with Existing Frameworks
MIMIR distinguishes itself from existing instruction-tuning methods by focusing specifically on the requirements of scientific agents. As shown in the comparison below, MIMIR is the only resource among its peers to simultaneously support multi-step reasoning, API retrieval, and role-playing for generation.
Key Results
The researchers evaluated MIMIR-tuned LLaMA2 models against several established baselines, yielding significant findings:
- Human Preference: In blind tests, medical students preferred MIMIR-generated data over original datasets and popular methods like Self-Instruct or Baize, with "win or equal" rates between 75% and 87%.
- Benchmark Performance: On medical benchmarks, the MIMIR-tuned model achieved an average score of 59.5%, significantly outperforming LLaMA2 zero-shot (39.3%) and retrieval-augmented generation (RAG) setups (40.7%).
- Competitive with Proprietary Models: The MIMIR-tuned LLaMA2 outperformed GPT-3.5's zero-shot performance (57.2%) across the tested medical benchmarks, demonstrating that specialized agent tuning can bridge the gap between open-source and proprietary models.
Discussion and Limitations
While MIMIR represents a significant step forward, several challenges remain. The efficiency of the generated data is heavily dependent on the performance of external tools; poor search results can degrade training quality. Additionally, the "hallucination ratio" tends to increase in longer dialogues, peaking at approximately 24% by the fifth turn.
Currently, the system relies on GPT-4 for knowledge verification, which reintroduces a dependency on proprietary models during the data preparation phase. Future work will focus on moving toward fully open-source verification models and validating the platform's generalizability across other scientific fields such as physics and chemistry.
Summary updated