Abstract
Parsing tables from PDF documents is a challenging task, particularly when cells span multiple rows or columns. This paper presents GraphTSR, a novel Graph Neural Network (GNN) framework designed to recognize complex table structures by predicting relational links between cells. To address the lack of high-quality training data for this task, the authors introduce SciTSR, a large-scale dataset containing 15,000 tables with accurate ground-truth labels derived from LaTeX source code. Experimental results demonstrate that GraphTSR significantly outperforms existing rule-based and image-segmentation methods, particularly on tables with complicated spanning structures.
Introduction
While humans can intuitively interpret tabular data, machines often perceive PDFs as a disorganized collection of characters and lines. Table Structure Recognition (TSR) is the process of converting this unstructured visual information into machine-readable formats like HTML or Excel. The primary difficulty in TSR lies in "complicated tables"—those featuring cells that span multiple rows or columns.
Traditional approaches often rely on rigid, rule-based heuristics or simple grid assumptions, which fail when layouts deviate from standard patterns. Recent deep learning attempts have treated TSR as an image segmentation problem; however, these methods frequently struggle to capture the underlying relational logic and structural dependencies inherent in complex tables.
Methodology: The GraphTSR Framework
The authors propose a four-stage pipeline to transform raw PDF data into structured tables, centered on a specialized Graph Neural Network called GraphTSR.
- Pre-processing: Cell contents and their corresponding bounding boxes are extracted from the PDF document.
- Graph Construction: To avoid the computational overhead of a fully connected graph, a K-Nearest Neighbors (KNN) approach ($K=20$) is employed to build an undirected graph where each cell serves as a node.
- GraphTSR Core: The model treats the table as a bipartite graph of nodes (cells) and edges (potential relations). It utilizes a stack of Graph Attention Blocks that perform dual operations: Edge-to-Vertex Attention, which updates cell representations based on neighbors, and Vertex-to-Edge Attention, which updates edge representations based on the cells they connect. This allows the model to integrate spatial features (e.g., Euclidean distance, alignment) with semantic content.
- Post-processing: The model classifies each edge as "horizontal," "vertical," or "no relation." These predictions are then used to reconstruct the final table structure.
The SciTSR Dataset
A significant contribution of this work is the creation of SciTSR, a comprehensive dataset designed to push the boundaries of table recognition research.
- SciTSR: Comprises 15,000 tables extracted from scientific papers on arXiv. By using LaTeX source code to generate labels, the authors ensure 100% accuracy for spanning cell ground truth.
- SciTSR-COMP: A subset of 716 "complicated" tables specifically curated to evaluate performance on complex spanning structures.
- ICDAR-2013: A standard benchmark used to compare the proposed method against historical baselines.
Analysis and Key Insights
The paper offers several critical insights into the nature of table recognition:
- Relational Modeling: By framing TSR as a graph edge-prediction task rather than a grid-fitting task, the model gains the flexibility to recognize relations between cells that are not perfectly aligned.
- Bipartite Attention: Explicitly modeling edges as nodes in a bipartite structure allows GraphTSR to better incorporate edge-specific features like precise spatial offsets and overlaps.
- Receptive Field: Increasing the number of attention blocks ($N$) improves recall by allowing cells to "see" further across the table, providing the necessary context to understand their role within the global layout.
Experimental Results
GraphTSR consistently outperforms state-of-the-art baselines, including the Adobe Acrobat SDK, Tabby, and DeepDeSRT. On the SciTSR-COMP dataset, GraphTSR achieved a Macro-F1 score of 0.934, a substantial improvement over the rule-based Tabby (0.855) and image-based DeepDeSRT (0.812). Furthermore, GraphTSR demonstrates superior generalization capabilities across different fonts and styles compared to purely image-based models.
Conclusion and Future Work
While GraphTSR represents a significant advancement, it remains dependent on the accuracy of initial cell detection. Errors in pre-processing, such as missed or incorrectly merged cells, cannot be rectified by the GNN. Future research directions include developing end-to-end models that integrate cell detection and structure recognition into a single trainable framework, as well as expanding the dataset to include diverse document domains such as financial and historical records.
Summary updated