Source-linked AI summary
Structured Prediction for Scalable Spreadsheet Table Understanding: From Cell Types to Table Ranges (Extended Version)
Antoine Gauquier, Ioana Manolescu, Pierre Senellart
TL;DR
Spreadsheet understanding is difficult because heterogeneous layouts and inconsistent conventions complicate recovering machine-interpretable tables, while public benchmarks jointly supporting cell roles and table boundaries remain limited. This paper introduces StatSheets and an efficient pipeline combining structured cell-type prediction with deterministic table extraction, matching or outperforming deep-learning competitors across both tasks while using fewer resources.
Problem
Automated spreadsheet understanding remains difficult because heterogeneous layouts complicate table recovery, while public benchmarks jointly supporting cell-type classification and table detection remain limited.
Method
The paper builds StatSheets and combines non-linear structured cell-type prediction with a deterministic five-stage algorithm for extracting table ranges.
Results
Across CTC and TD, the pipeline matches or outperforms deep-learning competitors; CRF-LightGBM reaches M-FM-F1 0.937, only +0.6 pp below TUTA.
Takeaways & Limitations
The results support a strong-performing, resource-efficient, reproducible, and interpretable approach to spreadsheet understanding.
Takeaways & Limitations
The average-margin constraint can hide per-sheet violations, potentially leaving a small number of poorly labeled sheets uncorrected.
Abstract
from arXiv · showhide
Spreadsheets are a primary medium for publishing tabular data, yet automatically extracting structured content from them remains difficult due to heterogeneous layouts, diverse file formats, and inconsistent organizational conventions. We address two core tasks in spreadsheet understanding: Cell-Type Classification (CTC), which assigns roles to cells, and Table Detection (TD), which identifies table bounding boxes within sheets. We propose an efficient two-stage pipeline in which a learned CTC model feeds a deterministic TD algorithm. For CTC, we use a LightGBM classifier over 65 structured features together with a pairwise CRF enforcing spatial consistency across the cell grid. Our TD method extracts table ranges from predicted cell types by a deterministic five-stage procedure. For evaluation, we built and share StatSheets, a multilingual benchmark of 737 manually annotated sheets from 14 public data providers across multiple countries and file formats. Under 5-fold cross-validation, our CRF-LightGBM system achieves a Mean File-Macro F1 score of 0.937 on CTC, within 0.6 percentage points of the GPU-based TUTA Transformer, while requiring substantially fewer computational resources. For TD, our deterministic approach outperforms region-based baselines and remains competitive with recent LLM-based systems such as SpreadsheetLLM. These results demonstrate that combining non-linear structured prediction with deterministic range extraction provides a competitive, scalable, and computationally efficient approach to spreadsheet table understanding.
1 Introduction
Spreadsheet semantics are conveyed largely through layout and formatting, making heterogeneous real-world sheets difficult to extract and integrate automatically. This motivates robust spreadsheet understanding and a public benchmark supporting both cell-type classification and table detection under realistic conditions.
- Motivation: Spreadsheets encode semantics through layout, formatting, merged cells, and spatial proximity, with conventions varying across publishers, domains, languages, and software ecosystems.
- Challenges: Real-world sheets mix data regions with hierarchical headers, titles, footnotes, metadata, and auxiliary elements, while sparsity and merged cells create structural irregularities.
- Importance: Errors in table boundaries or cell roles can corrupt schemas, invalidate joins, and make downstream datasets unusable, making spreadsheet understanding foundational for scalable data management.
- Benchmark gap: Existing benchmarks lack realistic joint support for cell-type classification and table detection, with DECO based on the Enron archive and early-2000s practices.
- Contributions: 737 manually annotated sheets from 14 public organizations comprise StatSheets, covering both tasks across countries, languages, spreadsheet formats, large sheets, and heterogeneous layouts.
2 Related Work
Prior spreadsheet-understanding work spans feature-engineered and neural approaches to cell-type classification, region-based and table-specific table detection, and limited unified pipelines. Existing datasets and systems leave gaps in general-purpose classification, reproducibility, multilingual coverage, and scalability.
- Cell-Type Classification (CTC) in Spreadsheets: CTC methods evolved from spatial graphical models and independent Random Forest classifiers toward large pre-trained neural architectures.Early graphical-model work combined formatting and content cues but required human interaction and targeted relational extraction rather than general-purpose CTC.
- Cell-Type Classification (CTC) in Spreadsheets: Random Forest CTC uses formatting, content, and positional features to classify cells independently, with later active-learning extensions.The paper’s RF-Koci baseline follows the dedicated CTC framework’s similar feature design.
- Table Detection (TD) in Spreadsheets: Table-detection research divides into region-based methods that extract generic grid structures and table-specific methods that model table semantics and boundaries.Connected components and Mondrian exemplify region-based approaches, while RAC and SpreadsheetLLM exemplify table-specific systems.
- Table Detection (TD) in Spreadsheets: RAC couples cell-layout inference with graph construction and curated rules, while SpreadsheetLLM encodes spreadsheets into compact token sequences and fine-tunes LLMs for table detection.The authors include SpreadsheetLLM as a direct competitor using an implementation derived from its supplementary materials.
- End-to-end Spreadsheet Understanding: Few studies unify CTC and TD, and existing pipelines or tools commonly lack released code, trained models, or evaluation.Unified approaches include rule-based RAC extensions, the interactive XLIndy add-in, and a multi-task FCNN addressing TD, structural recognition, and CTC.
- Datasets for Spreadsheet Understanding: DECO is the only public dataset covering both CTC and TD, but excludes files larger than 5 MB and non-Western languages such as Arabic and Japanese.These exclusions create limitations for large public-portal tables and multilingual spreadsheet understanding.
3 Our Approach
The approach decomposes spreadsheet understanding into cell-type classification and table detection. CTC combines a nonlinear classifier with a pairwise CRF for spatially coherent labels, while TD deterministically recovers table extents from the resulting label grid.
- Table Detection: TD uses a deterministic five-stage pipeline that seeds, merges, filters, expands, and recovers table regions from predicted HEADER/DATA labels.The algorithm requires no learning and is designed to mirror human annotation heuristics for delineating tables on a grid.
- Cell-Type Classification: CTC predicts one of five cell-type classes for every node in a spreadsheet’s two-dimensional grid, using both local features and neighborhood consistency.The classes are EMPTY, HEADER, DATA, TITLE, and OTHER; grid edges connect horizontally and vertically adjacent cells.
- Cell-Type Classification: Each cell is represented by a 65-dimensional unary feature vector spanning content/position, formatting, and row-/column-aware structure.The groups contain 21, 29, and 15 features, respectively.
- Cell-Type Classification: The CTC pipeline feeds LightGBM class probabilities as unary potentials into an EdgeFeatureGraphCRF with label-specific pairwise interactions.LightGBM models nonlinear feature conjunctions, while the CRF enforces spatial coherence across neighboring cells.
- Cell-Type Classification: MAP inference uses α-expansion because exact inference in a general pairwise CRF is NP-hard.The move-making procedure jointly optimizes whether cells retain their labels or switch to a candidate label α.
4 Dataset
StatSheets is a released dataset of public-organization spreadsheets annotated for both cell-type classification and table detection. Its heterogeneous sources, languages, topics, sizes, and formats support evaluation under highly variable conditions, with 737 sheets containing 818 annotated tables.
- Dataset construction: StatSheets contains spreadsheets from statistical datasets published by public organizations and is annotated for both CTC and TD.The dataset was constructed to address limitations in existing datasets for both tasks.
- Dataset construction: Its heterogeneity spans data sources, sheet languages, covered topics, sheet sizes, and file formats.This variation enables evaluation of classifier and detector robustness in highly variable settings.
- Dataset construction: The collection draws on 14 geographically diverse sources, increasing language diversity and broadening topic coverage.Spreadsheets were retrieved from each source using a focused Web crawler before candidate-sheet processing.
- Annotation protocol: CTC annotations cover every cell in each sheet’s minimal non-empty bounding rectangle using EMPTY, HEADER, DATA, TITLE, and OTHER labels.HEADER includes column or row headers and sub-headers, including headers adjacent to higher-level headers or between DATA cells.
- Annotation protocol: TD annotations define each table as the rectangular bounding box of its HEADER and DATA cells, excluding TITLE and OTHER and disallowing overlapping tables.Each HEADER or DATA cell can belong to only one table.
- Dataset statistics: 737 sheets yield 818 annotated tables: 690 sheets contain one table, 29 contain two, and 18 contain three or more.The distribution indicates that single-table sheets predominate in the released collection.
5 Experiments
The experiments evaluate cell-type classification and table detection under shared 5-fold cross-validation, showing that structured CTC components improve difficult classes and support accurate, low-cost deterministic table-range extraction. The deterministic TD variants achieve precise boundaries while substantially reducing computational cost relative to region-based and LLM-based alternatives.
- Evaluation setup: All systems use 5-fold cross-validation with shuffled folds of approximately 147 sheets and shared test folds across CTC and TD.Each fold uses an 80/20 train/test split; training folds support training, fine-tuning, hyperparameter selection, or no training, depending on the system.
- CTC experiments: Adding full spatial features improves M-FM-F1 by +2.1 pp (0.899 →0.920), while adding CRF-based sequential modeling yields another +1.1 pp.The comparison progresses from RF-Koci to RF to CRF-RF, demonstrating the contributions of spatial awareness and sequential modeling.
- CTC experiments: CRF-LightGBM improves M-FM-F1 over RF-Koci by +3.8 pp, with the largest class gains for TITLE (+8.5 pp, 0.816 →0.901) and OTHER (+7.4 pp, 0.773 →0.847).DATA is already saturated at FM-F1 ≈0.976–0.981, whereas harder classes benefit more from structural context.
- TD experiments: TD is fully deterministic after CTC, with three variants applied to different CTC outputs alongside region-based baselines and an LLM-based detector.Only the LLM-based approach requires task-specific TD training; the deterministic methods rely indirectly on learning through CTC.
- Computational efficiency: TD(RF-Koci) and TD(CRF-LightGBM) cost $0.38/$0.49, compared with $51.29 for SpreadsheetLLM and a $279 lower-bound cost for Mondrian.The TD variant costs include CTC inference; SpreadsheetLLM’s cost is driven by GPU fine-tuning, while Mondrian’s estimate reflects a 7-day timeout.
- TD experiments: Replacing RF-Koci with CRF-LightGBM raises precision at IoU = 1 by +2.9 pp on macro (78.6 →81.5%) and +3.3 pp on micro (73.5 →76.8%).The gains mainly occur at high IoU thresholds, indicating more accurate boundary recovery rather than improved coarse localization.
6 Conclusion
The paper provides a comprehensive annotated dataset and a CTC-TD pipeline designed for strong performance, low resource needs, and full table-detection interpretability. Its methods match or outperform state-of-the-art deep-learning competitors while requiring a fraction of their resources.
- The work provides a comprehensive annotated dataset for spreadsheet information extraction.
- The proposed CTC-TD pipeline combines strong performance, low resource needs, and fully interpretable table detection.
- The CTC method combines spatial, sequential, and non-linear features, while the TD method is deterministic and learning-free.
- The methods match or outperform state-of-the-art deep-learning competitors, including TUTA for CTC and SpreadsheetLLM for TD.
GenAI Usage Disclosure
Claude Code, running Claude Sonnet 4.6, was used twice during development to reproduce SpreadsheetLLM and improve code usability, but not to write the paper.
- Usage scope: Claude Code, running Claude Sonnet 4.6, was used during development on two occasions.The disclosure identifies the tool and frequency of use.
- Reproduction support: The LLM helped reconstruct SpreadsheetLLM’s SheetCompressor from supplementary C# fragments, translate it into Python, and integrate the component.It also reimplemented SpreadsheetLLM’s overall pipeline from the paper’s methodological details.
- Code and documentation: The LLM cleaned and reorganized the codebase and refined CLI descriptions to improve reproducibility and usability.These changes were reviewed for behavioral equivalence and consistency with the experimental setup.
- Paper authorship: No generative AI system was used to write any part of the current paper.This is explicitly stated in the usage disclosure.