EMNLP Findings2023
Beyond Layout Embedding: Layout Attention with Gaussian Biases for Structured Document Understanding
Xi Zhu, Xue Han, Shuyuan Peng, Shuo Lei, Chao Deng, Junlan Feng
Abstract
Effectively encoding layout information is a central problem in structured document understanding. Most existing methods rely heavily on millions of trainable parameters to learn the layout features of each word from Cartesian coordinates. However, two unresolved questions remain: (1) Is the Cartesian coordinate system the optimal choice for layout modeling? (2) Are massive learnable parameters truly necessary for layout representation? In this paper, we address these questions by proposing Layout Attention with Gaussian Biases (LAGaBi): Firstly, we find that polar coordinates provide a superior choice over Cartesian coordinates as they offer a measurement of both distance and angle between word pairs, capturing relative positions more effectively. Furthermore, by feeding the distances and angles into 2-D Gaussian kernels, we model intuitive inductive layout biases, i.e., the words closer within a document should receive more attention, which will act as the attention biases to revise the textual attention distribution. LAGaBi is modelagnostic and language-independent, which can be applied to a range of transformer-based models, such as the text pre-training models from the BERT series and the LayoutLM series that incorporate visual features. Experimental results on three widely used benchmarks demonstrate that, despite reducing the number of layout parameters from millions to 48, LAGaBi achieves competitive or even superior performance. Our code is available on GitHub 1 .
Ask Lune
Know this paper in minutes, not an afternoon.
Lune can read every page of it and the top-tier papers that cite it, and gives you its claims, its evidence and its limits, each one cited to the paper it comes from. No skimming, no AI slop.
1 top-tier paper has cited it since. Know what they found before your reviewers do.
Lune can draw on
the full paper · the top-tier papers that cite it · related work
Free to start. No credit card required.
Lineage
- Train Short, Test Long: Attention with Linear Biases Enables Input Length Extrapolation cites Unsupervised Cross-lingual Representation Learning at Scale
- LayoutLMv3: Pre-training for Document AI with Unified Text and Image Masking cites LayoutLM: Pre-training of Text and Layout for Document Image Understanding
- LayoutLMv3: Pre-training for Document AI with Unified Text and Image Masking cites Unsupervised Cross-lingual Representation Learning at Scale
- LayoutLMv3: Pre-training for Document AI with Unified Text and Image Masking cites DocFormer: End-to-End Transformer for Document Understanding
- DocFormer: End-to-End Transformer for Document Understanding cites LayoutLM: Pre-training of Text and Layout for Document Image Understanding
- Modeling Layout Reading Order as Ordering Relations for Visually-rich Document Understanding cites LayoutLMv3: Pre-training for Document AI with Unified Text and Image Masking
- Modeling Layout Reading Order as Ordering Relations for Visually-rich Document Understanding cites DocFormer: End-to-End Transformer for Document Understanding
Cited by top-tier papers1
Builds on11
- Train Short, Test Long: Attention with Linear Biases Enables Input Length ExtrapolationOfir Press, Noah A. Smith, Mike LewisICLR 2022 · 1,168 citations
- LayoutLMv3: Pre-training for Document AI with Unified Text and Image MaskingYupan Huang, Tengchao Lv, Lei Cui, Yutong Lu et al.ACM MM 2022 · 606 citations
- LayoutLM: Pre-training of Text and Layout for Document Image UnderstandingYiheng Xu, Minghao Li, Lei Cui, Shaohan Huang et al.KDD 2020 · 575 citations
- Unsupervised Cross-lingual Representation Learning at ScaleAlexis Conneau, Kartikay Khandelwal, Naman Goyal, Vishrav Chaudhary et al.ACL 2020 · 539 citations
- DocFormer: End-to-End Transformer for Document UnderstandingSrikar Appalaraju, Bhavan Jasani, Bhargava Urala Kota, Yusheng Xie et al.ICCV 2021 · 392 citations
Related papers
- A Simple yet Effective Layout Token in Large Language Models for Document UnderstandingZhaoqing Zhu, Chuwei Luo, Zirui Shao, Feiyu Gao et al.CVPR 2025
- StructMAR: Structure-Aware Masked Autoregression for Explicit Layout Alignment in Text-to-Image GenerationGang Cao, Junying ZhangICML 2026
- Position IDs Matter: An Enhanced Position Layout for Efficient Context Compression in Large Language ModelsRunsong Zhao, Xin Liu, Xinyu Liu, Pengcheng Huang et al.EMNLP Findings 2025 · 1 citation
- Enhancing Document Understanding with Group Position Embedding: A Novel Approach to Incorporate Layout InformationYuke Zhu, Yue Zhang, Dongdong Liu, Chi Xie et al.ICLR 2025
- LayoutLLM: Layout Instruction Tuning with Large Language Models for Document UnderstandingChuwei Luo, Yufan Shen, Zhaoqing Zhu, Qi Zheng et al.CVPR 2024 · 39 citations
