Papers › MMed-RAG: Versatile Multimodal RAG System for Medical Vision Language Models

MMed-RAG: Versatile Multimodal RAG System for Medical Vision Language Models

16 Oct 2024arXiv:2410.13085archive 2025-07-28

Peng Xia, Kangyu Zhu, Haoran Li, Tianze Wang, Weijia Shi, Sheng Wang, Linjun Zhang, James Zou, Huaxiu Yao

Artificial Intelligence (AI) has demonstrated significant potential in healthcare, particularly in disease diagnosis and treatment planning. Recent progress in Medical Large Vision-Language Models (Med-LVLMs) has opened up new possibilities for interactive diagnostic tools. However, these models often suffer from factual hallucination, which can lead to incorrect diagnoses. Fine-tuning and retrieval-augmented generation (RAG) have emerged as methods to address these issues. However, the amount of high-quality data and distribution shifts between training data and deployment data limit the application of fine-tuning methods. Although RAG is lightweight and effective, existing RAG-based approaches are not sufficiently general to different medical domains and can potentially cause misalignment issues, both between modalities and between the model and the ground truth. In this paper, we propose a versatile multimodal RAG system, MMed-RAG, designed to enhance the factuality of Med-LVLMs. Our approach introduces a domain-aware retrieval mechanism, an adaptive retrieved contexts selection method, and a provable RAG-based preference fine-tuning strategy. These innovations make the RAG process sufficiently general and reliable, significantly improving alignment when introducing retrieved contexts. Experimental results across five medical datasets (involving radiology, ophthalmology, pathology) on medical VQA and report generation demonstrate that MMed-RAG can achieve an average improvement of 43.8% in the factual accuracy of Med-LVLMs. Our data and code are available in https://github.com/richard-peng-xia/MMed-RAG.

PaperPDFCodeCode Syntology ran

In Syntology Open this paper in Syntology's Atlas, the map of the papers in Syntology's graph and their citations.

For agents, Syntology's MCP tool lists every function and class Syntology harvested from this paper and whether it ran (how to connect): get_harvested_code_for_paper(arxiv_id="2410.13085")

Code

Syntology Ran 7 of 10 code samples harvested from 1 repository linked to this paper; 3 have no recorded run. Of those that ran: 1 ran · honoured contract; 2 ran · our draft was wrong; 2 ran · fixture could not drive it; 2 ran with no contract checked.

By repository: official repository: 10 samples from 1 repository, 7 ran. The run record, sample by sample. “Ran” means executed on a synthesized input, not that the code is correct or reproduces the paper.

richard-peng-xia/mmed-rag officialmentioned in papermentioned on GitHubpytorchMIT report

Repository list and official/mentioned flags are the archive's, frozen 2025-07-28. Reachability, where shown, is from one Syntology probe window (2026-09-16 to 2026-09-18); repositories not probed show nothing. GitHub stars are not tracked.

Code Syntology ran Syntology

10 samples harvested; 7 ran; 1 honoured the contract we drafted; 3 have no recorded run. Read from Syntology's graph 2026-09-24; that is when this build read the record, not when the samples ran.

1ran · honoured contract
2ran · our draft was wrong
2ran · fixture could not drive it
2ran
3unverified

Licence: 0 of the 10 samples are pointer only, meaning Syntology does not serve that copy's text. This page shows no code text for any sample; each one links to its file in the repository.

Harvested from richard-peng-xia/MMed-RAG. “Ran” means the sample executed on a synthesized input. It does not mean the output is correct, and nothing here reproduces the paper's results. “Honoured” and “violated” refer to a contract Syntology drafted from the code itself; “our draft was wrong” and “fixture could not drive it” are failures of Syntology's instrument, not of the code.

Each sample ends with its code_sha256, Syntology's identity for that exact code. An agent fetches the stored sample with Syntology's MCP tool get_code(code_sha256="…") (how to connect); click an identity to copy that call.

Repository labels, per sample. official repository: The archive marks this repository official for the paper. named in the paper: The archive records that the paper mentions this repository; it is not marked official. community (archive-listed): In the archive's code links for this paper, not marked official and not recorded as mentioned in the paper. found in paper text by Syntology: Syntology found this repository in the paper's own text; whether it is the authors' implementation is not asserted. community: Not in the archive's code links for this paper; a community repository Syntology harvested. Samples from a repository marked official are listed first. Licence labels name the repository's licence as recorded at harvest. “Pointer only” means Syntology does not serve that copy's text, for one of four reasons: no licence file was found; the licence was not identified; the licence is recorded as permissive but that copy's record is not marked cleared; or the licence is outside the permissive list Syntology serves text under (MIT, Apache-2.0, BSD and similar). Some licences outside that list permit redistribution, such as WTFPL, and GPL-3.0 under its conditions; they are simply not on the list. Hover a licence label for the reason. File links open the file on GitHub at the default branch, which may have changed since the harvest.

clean_data_info richard-peng-xia/MMed-RAG/train/open_clip/src/retrieve_clip_VQA.py official repository ran MIT (permissive) · 3477a2c3e334616b · report
get_chunk richard-peng-xia/MMed-RAG/train/dpo/povid_infer.py official repository ran · our draft was wrong fingerprinted MIT (permissive) · 42a46570620cd9fa · report
get_logits richard-peng-xia/MMed-RAG/train/open_clip/src/retrieve_clip_VQA.py official repository ran MIT (permissive) · a8c80549ff61c7ea · report
load_image richard-peng-xia/MMed-RAG/train/dpo/predict.py official repository ran · honoured contract MIT (permissive) · 9b3c1cb391672ccb · report
retrieve_topk_per_image richard-peng-xia/MMed-RAG/train/open_clip/src/retrieve_clip_VQA.py official repository ran · fixture could not drive it MIT (permissive) · f89c524e425ca547 · report
split_list richard-peng-xia/MMed-RAG/train/dpo/povid_infer.py official repository ran · our draft was wrong fingerprinted MIT (permissive) · 076c252c52cbb161 · report
split_to_even_chunks richard-peng-xia/MMed-RAG/train/dpo/llava_trainer_2stages.py official repository ran · fixture could not drive it MIT (permissive) · 10893c4608c08075 · report
LlavaMetaForCausalLM richard-peng-xia/mmed-rag/train/dpo/llava/model/llava_arch.py official repository unverified MIT (permissive) · b9978345e2dba578 · report
get_mm_adapter_state_maybe_zero_3 richard-peng-xia/MMed-RAG/train/dpo/llava_trainer_2stages.py official repository unverified MIT (permissive) · bb35e3ac741bb2c9 · report
maybe_zero_3 richard-peng-xia/MMed-RAG/train/dpo/llava_trainer_2stages.py official repository unverified MIT (permissive) · 735025744c1ab0cf · report

Tasks

DiagnosticHallucinationRAGRetrievalRetrieval-augmented GenerationVisual Question Answering (VQA)

Results from the paper archive 2025-07-28

No leaderboard rows for this paper in the archive.

Methods

AdamAttentionAttention DropoutBARTBERTBPEDense ConnectionsDropoutLayer NormalizationLinear LayerLinear Warmup With Linear DecayMulti-Head AttentionRAGResidual ConnectionSoftmaxWeight DecayWordPiece

Report a problem or propose a change · a person checks every report against the paper or source before anything changes; decisions are listed on /corrections