Abstract
Large Language Models (LLMs) often struggle with specialized domain knowledge, typically relying on either internal memorization via fine-tuning or external retrieval via Retrieval-Augmented Generation (RAG). However, both approaches have distinct failure modes, particularly in complex multi-hop reasoning tasks. We present DuetRAG, a collaborative framework that integrates domain-specific fine-tuning with RAG through a three-model architecture: a Reciter (internal knowledge), a Discoverer (external knowledge), and an Arbiter (referee). Our results on the HotpotQA dataset demonstrate that DuetRAG significantly outperforms standalone fine-tuning and RAG approaches, achieving a nearly three-fold improvement in accuracy over base LLaMA2-7B models.
Introduction
The application of Large Language Models (LLMs) to specialized domains is often hindered by a "knowledge gap." Current solutions generally fall into two categories: domain-specific fine-tuning and Retrieval-Augmented Generation (RAG). Fine-tuning allows a model to "memorize" facts within its weights but is data-intensive and risks "catastrophic forgetting" of general reasoning capabilities. Conversely, RAG provides external context at inference time but frequently fails on complex, multi-hop questions where retrievers may provide noisy or irrelevant documents, leading to hallucinations.
DuetRAG (Collaborative Retrieval-Augmented Generation) addresses these limitations by arguing that internal memorization and external retrieval are complementary. By running these processes in parallel and employing a "referee" model to adjudicate between them, the system can leverage the strengths of both approaches.
The DuetRAG Framework
The DuetRAG architecture is defined by the synergy of three distinct roles, as illustrated in the framework overview below:
1. The Reciter ($M_i$)
The Reciter serves as the internal knowledge-based model. It undergoes domain-specific fine-tuning using Low-Rank Adaptation (LoRA). This process enables the model to internalize domain facts and answer questions directly from its learned weights, acting as a reliable source when external retrieval fails.
2. The Discoverer ($M_e$)
The Discoverer is the external knowledge-based model. While also fine-tuned, its training focuses on improving the ability to extract and summarize answers from retrieved documents. This model is designed to remain robust even when the retrieved external knowledge contains significant noise.
3. The Arbiter ($M_j$)
The Arbiter, or "Referee" model, is the core of the collaborative inference process. During inference, both the Reciter and the Discoverer generate candidate answers. The Arbiter evaluates these outputs and selects the final answer based on calculated confidence levels.
Arbiter Implementation Strategies
The researchers explored two primary methods for implementing the Arbiter:
- Classification-based: Inspired by semantic alignment techniques like CLIP, this model calculates a score between the question and candidate answers to determine the best fit.
- Summarization-based: This approach utilizes the LLM’s inherent reasoning capabilities to weigh candidate answers against each other, guided by prompts that describe specific task preferences.
Experimental Results
The framework was evaluated using the HotpotQA dataset, which requires multi-hop reasoning across a Wikipedia-based external knowledge corpus. Performance was measured using GPT-4 as an automated evaluator for accuracy.
As shown in the results table, DuetRAG achieved an accuracy of 36.3%, representing a nearly 3x improvement over the base LLaMA2-7B model (12.7%). Notably, standard RAG without fine-tuning actually decreased performance to 9.2%, likely due to the introduction of noise in complex multi-hop queries. DuetRAG also significantly outperformed its individual components—the internal model (23.1%) and the external model (32.7%)—validating the collaborative "duet" approach.
Conclusion and Future Work
DuetRAG demonstrates that the integration of internal memorization and external retrieval, mediated by a referee model, provides a superior path for domain-specific LLM applications. The system effectively falls back on memorized knowledge when retrieval is noisy and utilizes retrieved evidence when internal weights are insufficient.
Future research will focus on scaling the framework to larger model architectures beyond LLaMA2-7B and expanding evaluation to diverse domains such as medical and legal question-answering. Additionally, the team aims to optimize the computational overhead associated with running multiple models during inference to make the framework more suitable for real-time production environments.
Summary updated