Two-layer retrieval augmented generation framework for low-resource medical question-answering: proof of concept using Reddit data

Sudeshna Das, Yao Ge, Yuting Guo, Swati Rajwal, JaMor Hairston, Jeanne M. Powell, Drew Walker, Snigdha Peddireddy, Sahithi Lakamana, Selen Bozkurt, Matthew A. Reyna, Reza Sameni, Yunyu Xiao, Sangmi Kim, Rasheeta Chandler, Natalie Hernandez, Danielle Mowery, Rachel Wightman, Jennifer Love, Anthony Spadaro, Jeanmarie Perrone, Abeed SarkerarXiv 2024 · DOI

TL;DR

This paper introduces a novel two-layer Retrieval-Augmented Generation (RAG) framework designed for medical question answering (MQA) using user-generated data from social media. The framework effectively synthesizes accurate and contextually relevant answers, even when using smaller, quantized, open-source Large Language Models (LLMs), making it suitable for low-resource settings.

What Problem Does This Paper Address?

The increasing volume of user-generated content on social media, particularly regarding emerging health topics and substances, presents a rich source of information. However, extracting meaningful insights for medical professionals is challenging due to the sheer scale and unstructured nature of this data. Traditional LLMs, while powerful, often require significant computational resources and can "hallucinate" (generate plausible but incorrect information). This paper aims to bridge this gap by developing a RAG architecture that can efficiently process this social media data to answer complex medical questions, specifically addressing the need for tools that are both accurate and accessible in resource-constrained environments.

Methods

The core innovation is a two-layer RAG framework.

  • Layer 1: This layer focuses on initial summarization. When a query is submitted, a retrieval engine fetches relevant documents (in this case, Reddit posts). The top 'n' documents are then fed to an LLM along with the query and a prompt instructing it to generate a short, query-focused summary. To handle LLM context window limitations, the retrieved text is segmented. This layer aims to distill key information from individual posts relevant to the query.
  • Layer 2: This layer synthesizes the information. It takes the original query and the individual summaries generated in Layer 1 as input. The LLM then generates a final, aggregated summary that answers the original medical question.

The framework is designed to be modular, allowing for the use of different retrieval engines and LLMs. For their proof-of-concept, they used a smaller, 8-bit quantized LLM (Nous-Hermes-2-7B-DPO) for low-resource deployment and compared its performance against GPT-4.

Datasets

The study utilized user-generated data from Reddit. Specifically, they collected posts mentioning "xylazine" (n=177,684) and "ketamine" (n=7699) up to December 31, 2023. This data was used to train the retrieval engine and evaluate the RAG framework. No new benchmarks were introduced; instead, the framework was evaluated on its ability to answer 20 clinician-driven queries related to these substances.

Key Insights and Ideas

  • Democratizing MQA: The framework's ability to function effectively with smaller, quantized LLMs is a significant step towards making advanced MQA tools accessible in low-resource settings, reducing reliance on expensive, high-performance hardware.
  • Modular Design for Flexibility: The two-layer RAG architecture is inherently modular, allowing for easy swapping of retrieval engines or LLMs. This adaptability is crucial for evolving research landscapes and diverse application needs.
  • Leveraging Social Media for Emerging Trends: The study highlights the immense potential of social media platforms like Reddit for real-time monitoring of emerging drug trends, side effects, and public perception, which can inform public health initiatives.
  • Addressing Nuanced Queries: The framework demonstrated its capability to handle complex, nuanced queries (e.g., "What are k cramps like?"), which often require extensive manual curation and are difficult to answer with traditional search methods.

Key Results

The framework achieved comparable performance to GPT-4 across several evaluation metrics, including relevance, length, hallucination, and coherence.

  • Coverage and Coherence: Median scores for both GPT-4 and Nous-Hermes-2-7B-DPO were high (5/5), with no statistically significant difference between them.
  • Relevance and Length: Median scores were also good (3/3 for relevance, 3/3 for length), again with no significant differences.
  • Hallucination: Both models performed well, with median hallucination scores of 0 (meaning no information not present in the original text).
  • Readability: A statistically significant difference was observed in the Coleman-Liau Index (CLI), with GPT-4 producing text that required a higher US grade level for comprehension (16.635) compared to Nous-Hermes-2-7B-DPO (12.125). This suggests the smaller model generates more accessible text.
  • Efficiency: The Nous-Hermes-2-7B-DPO model generated significantly shorter final summaries (median 61 tokens) compared to GPT-4 (median 141.5 tokens), indicating greater efficiency.

Limitations and Future Work

  • Data Dependency: The framework's output is inherently dependent on the accuracy and representativeness of the Reddit data it ingests. Biases, inaccuracies, or misinformation present in the posts can influence the generated answers.
  • Scope of Evaluation: The current proof-of-concept focused on a specific domain (substance use) and a limited set of queries. Further validation is needed to assess its performance across a broader range of medical topics.
  • Future Directions: The authors suggest that future work should focus on expanding the evaluation to diverse medical domains and exploring different retrieval engines and LLMs to further optimize performance and applicability. They also note the value of faithfully summarizing misinformation for transparency, while emphasizing the need for users to exercise caution in interpreting the results.

Summary updated

BibTeX
@misc{das2024two,
  author = {Sudeshna Das and Yao Ge and Yuting Guo and Swati Rajwal and JaMor Hairston and Jeanne M. Powell and Drew Walker and Snigdha Peddireddy and Sahithi Lakamana and Selen Bozkurt and Matthew A. Reyna and Reza Sameni and Yunyu Xiao and Sangmi Kim and Rasheeta Chandler and Natalie Hernandez and Danielle Mowery and Rachel Wightman and Jennifer Love and Anthony Spadaro and Jeanmarie Perrone and Abeed Sarker},
  title = {{Two-layer retrieval augmented generation framework for low-resource medical question-answering: proof of concept using Reddit data}},
  year = {2024},
  eprint = {2405.19519},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2405.19519},
}
Figure