Abstract
Despite advances in Large Language Models (LLMs) and Multimodal LLMs (MLLMs) for visual document understanding (VDU), visual information extraction (VIE) from relation-rich documents remains challenging due to the layout diversity and limited training data. While existing synthetic document generators attempt to address data scarcity, they either rely on manually designed layouts and templates, or adopt rule-based approaches that limit layout diversity. Besides, current layout generation methods focus solely on topological patterns without considering textual content, making them impractical for generating documents with complex associations between the contents and layouts. In this paper, we propose a Relation-rIch visual Document GEnerator (RIDGE) that addresses these limitations through a two-stage approach: (1) Content Generation, which leverages LLMs to generate document content using a carefully designed Hierarchical Structure Text format which captures entity categories and relationships, and (2) Content-driven Layout Generation, which learns to create diverse, plausible document layouts solely from easily available Optical Character Recognition (OCR) results, requiring no human labeling or annotations efforts. Experimental results have demonstrated that our method significantly enhances the performance of document understanding models on various VIE benchmarks.
Introduction
Visual Information Extraction (VIE)—the process of turning an image of a document into structured data—is notoriously difficult due to two main hurdles: extreme layout diversity and severe data scarcity. Training models to understand these layouts requires massive amounts of labeled data. Specifically, labeling "Entity Linking" (e.g., connecting the text "Date" to the actual value "2023-10-01") is an $O(n^2)$ problem that is incredibly time-consuming for humans.
Existing synthetic data generators often rely on rigid templates or ignore the actual meaning of the text when placing boxes, leading to "unnatural" documents that don't help models learn real-world relationships. RIDGE (Relation-rIch visual Document GEnerator) addresses this by generating structured text first and then predicting plausible layouts based on that content.
Methodology
The RIDGE framework consists of a two-stage pipeline designed to create high-quality, annotated synthetic documents without manual intervention.
1. Content Generation
Instead of random text, RIDGE uses an LLM to generate document content in a custom Hierarchical Structure Text (HST) format. This format uses simple markers (like <h1> tags and hyphens) to explicitly define which pieces of text are "keys," which are "values," and how they are linked. Representing a document as a tree is much more effective for LLMs than a flat list, as it captures the complex, nested relationships common in professional forms.
2. Content-driven Layout Generation (CLGM)
In the second stage, a layout model (such as LLaMA-3.1-8B) is trained to predict bounding boxes based on the generated text. Crucially, this model is trained via self-supervision on 100,000 real-world documents. By taking raw OCR results and training the model to "fill in the blanks" for coordinates, RIDGE bypasses the need for human-annotated layout templates.
Hierarchical Structure Learning (HSL)
To further boost performance, the authors introduce HSL, a training strategy for downstream extraction models (like Qwen2-VL). It encourages the model to "think" about the document's hierarchy—parsing the structure before extracting the final answer—similar to how Chain-of-Thought prompting works for logic problems.
Experimental Results
The researchers generated approximately 6,000 high-quality synthetic documents to augment training across various benchmarks, including FUNSD, XFUND, and CORD.
- Significant Gains: Adding RIDGE-generated data to Qwen2-VL-7B improved its F1 score on the FUNSD benchmark by 5.83% and on XFUND-ZH by 7.76%.
- State-of-the-Art: On the CORD benchmark, the RIDGE-enhanced model achieved a new state-of-the-art ANLS score of 85.53%.
- Domain Adaptation: RIDGE proved highly effective at specializing models for specific domains, such as receipts or exam papers, seeing accuracy jumps of up to 4% on tasks like EPHOIE.
Conclusion
RIDGE demonstrates that a text-first approach to layout generation, combined with hierarchical structure modeling, can significantly overcome data scarcity in document understanding. While currently optimized for form-like documents (invoices, registrations, etc.), future work will focus on expanding the generator's range to cover more diverse visual styles like posters or complex maps.
Summary updated