TL;DR
LFRAG advances multimodal Retrieval-Augmented Generation (RAG) by shifting from coarse page-level document retrieval to fine-grained, layout-aware block-level retrieval. By integrating layout segmentation with a semantic-layout fusion encoder, it improves answer accuracy by up to 7.20% while slashing token consumption in downstream Vision-Language Models (VLMs) by over 73%.
What Problem Does This Paper Address?
Multimodal RAG has become a powerful paradigm for grounding Large Language Models (LLMs) and Vision-Language Models (VLMs) with external knowledge from visually rich documents like PDFs, financial reports, and scientific papers. However, existing state-of-the-art multimodal retrievers (such as ColPali) operate at a coarse page level, treating an entire page as the minimal retrieval unit.
This page-level granularity introduces a major bottleneck: feeding entire high-resolution pages into a VLM injects massive amounts of irrelevant context. This not only drives up computational overhead and token costs but also introduces distracting information that elevates the risk of model hallucinations. Naively splitting pages into uniform grids or text chunks doesn't solve the problem either, as arbitrary cuts break up critical semantic structures—like separating a chart from its caption or splitting a single paragraph across chunks.
Methods
The authors propose LFRAG (Layout-oriented Fine-grained RAG), a framework that introduces layout analysis directly into the retrieval pipeline to extract semantically coherent document blocks. The method operates in two main stages:
- Stage 1: Offline Processing (Layout Segmentation & Aggregation)
- Segmentation: LFRAG uses a layout detection model (
DocLayout-YOLO) to identify structural regions (text, tables, figures) and assign bounding boxes and tags. - Semantic Block Aggregation: To prevent excessive fragmentation, a graph-based merging algorithm groups spatially adjacent and semantically compatible regions (e.g., combining a figure with its caption).
- Global Context Preservation: To ensure local blocks don't lose their broader context, LFRAG creates an auxiliary "masked page image" where all detected blocks are blanked out, leaving only the background layout.
- Semantic-Layout Fusion Encoding: A vision encoder extracts block features, which are then fused with global page layout context using a cross-attention mechanism. Structural awareness is further enhanced by appending layout tag embeddings (e.g.,
<Table>,<Figure>). - Stage 2: Online Processing (Late Interaction & Generation)
- Late Interaction Retrieval: LFRAG uses a ColBERT-style token-level late interaction mechanism (
MaxSim) to precisely align textual user queries with the multi-vector visual embeddings of the document blocks. - Augmented Generation: Instead of passing full pages, only the top-$k$ most relevant blocks are forwarded to the downstream VLM (
Qwen2-VL) for final answer generation.
Datasets
To train and evaluate LFRAG, the authors compiled a hybrid training corpus of over 120,000 samples from Docmatix and Visual-CoT.
Because existing RAG benchmarks only evaluate at the page level, the authors introduced LFDocQA, the first multimodal document benchmark featuring explicit block-level bounding box annotations. LFDocQA contains 1,000 high-quality QA pairs split across two subsets:
- LF-Docmatix: General documents (reports, forms, manuals) with diverse layouts.
- LF-PaperTab: Academic papers characterized by dense tables, complex multi-column text, and figures.
Key Insights and Ideas
- Structure Trumps Pure Granularity: Uniformly partitioning a page into fixed-size blocks consistently degrades retrieval performance. Preserving the document's intrinsic layout structure is far more important than simply making the retrieval chunks smaller.
- Local Blocks Need Global Context: Isolating a cropped image of a paragraph or table strips away its surrounding context. Fusing global page embeddings with local block embeddings via cross-attention is vital for accurate fine-grained matching.
- Higher Information Density: Providing a VLM with highly targeted visual blocks rather than downsampled full pages yields higher information density, allowing the generator to produce better answers with significantly fewer tokens.
Key Results
LFRAG was evaluated against strong OCR-based pipelines (BM25, BGE-M3, NV-Embed-V2) and VLM-based retrievers (SigLIP, VisRAG, ColPali, ColQwen2.5).
- Retrieval Performance: LFRAG achieved state-of-the-art results on both block-level and page-level retrieval. On LF-Docmatix, it achieved an nDCG@3 of 90.01 at the block level, outperforming the closest baseline by nearly 5 percentage points.
- Downstream Generation Accuracy: When evaluated by an LLM judge on answer correctness and faithfulness, LFRAG outperformed the best baseline by 7.20% in answer accuracy on the challenging LF-PaperTab dataset.
- Token and Time Efficiency: LFRAG reduced input token consumption by an average of 73.07% across generation tasks. This massive reduction in context length dropped generation times significantly (e.g., from 1.42 seconds down to 0.39 seconds in qualitative tests).
Limitations and Future Work
Despite its strong performance, the authors note a few areas for improvement:
- Ultra-Fine-Grained Structures: LFRAG treats tables as single semantic blocks. On highly structured, table-centric datasets (like
TabFQuad), it occasionally struggles because it lacks cell-level or row-column relational awareness. - Sparse Layouts: On sparse, condensed, and less structured documents like presentation slides (
SlideVQA), layout-based block decomposition is less effective. - Future Directions: The team plans to extend LFRAG to better handle internal table structures and explore adaptive retrieval strategies that dynamically adjust chunk granularity based on the specific document type.
Summary updated