--- license: apache-2.0 dataset_info: features: - name: id dtype: string - name: split dtype: string - name: similarity_score dtype: float64 - name: ground_truth struct: - name: cells list: - name: content list: string - name: end_col dtype: int64 - name: end_row dtype: int64 - name: id dtype: int64 - name: start_col dtype: int64 - name: start_row dtype: int64 - name: tex dtype: string - name: generated struct: - name: cells list: - name: content list: string - name: end_col dtype: int64 - name: end_row dtype: int64 - name: id dtype: int64 - name: start_col dtype: int64 - name: start_row dtype: int64 - name: tex dtype: string splits: - name: train num_bytes: 173252161 num_examples: 36066 - name: test num_bytes: 15195072 num_examples: 3000 download_size: 48544622 dataset_size: 188447233 configs: - config_name: default data_files: - split: train path: data/train-* - split: test path: data/test-* --- # Table Extraction Evaluation Dataset A dataset for training and benchmarking **verifier models** that predict the quality of structured table extraction from documents — **without access to ground truth at inference time**. Modern LLMs and vision-language models extract tables from PDFs impressively but inconsistently: structural recognition is largely solved, yet semantic content accuracy remains unreliable (e.g., TATR reaches GriTS ≈ 0.985 on PubTables-1M while content accuracy stays around 0.82). In high-stakes workflows — legal, financial, medical — pipelines need an automated way to judge whether an extraction can be trusted. This dataset provides supervision for exactly that task: each example pairs a machine-generated table extraction with its ground truth and a computed quality score, so a model can learn to predict extraction quality directly from the extracted output. Built for the Stanford CS230 project **"A Neural Verifier for Structured Table Extraction"** (Ray Hu, Nofel Teldjoune, Hiva Zaad). ## Dataset Summary | | | |---|---| | Total examples | 39,066 | | Train split | 36,066 | | Test split | 3,000 | | Format | Parquet | | License | Apache 2.0 | ## How It Was Built 1. **Upstream source:** [SciTSR](https://github.com/Academic-Hammer/SciTSR) — tables from scientific journals with human-annotated ground-truth JSON structure. 2. **Extraction generation:** each table image was processed with [Table Transformer (TATR)](https://github.com/microsoft/table-transformer) for structure recognition and [EasyOCR](https://github.com/JaidedAI/EasyOCR) for cell content, producing a machine-generated JSON extraction of the same table. 3. **Quality labeling:** each (ground truth, generated) pair was scored with a composite structural-similarity metric: ``` similarity_score = 0.50 * cell_detection_F1 + 0.25 * row_accuracy + 0.25 * col_accuracy ``` The resulting scores span 0.04–1.0, reflecting the realistic range of extraction quality that production pipelines encounter. ## Data Fields | Field | Type | Description | |---|---|---| | `id` | string | Source table identifier (SciTSR document + table index) | | `split` | string | `train` or `test` | | `similarity_score` | float64 | Quality label in [0, 1] — the regression target | | `ground_truth` | dict | Human-annotated table structure: list of cells with `content`, `start_row`, `end_row`, `start_col`, `end_col`, `id`, `tex` | | `generated` | dict | Machine-generated extraction of the same table, same schema | ## Usage ```python from datasets import load_dataset ds = load_dataset("rayhu/table-extraction-evaluation") example = ds["train"][0] print(example["similarity_score"]) # e.g. 0.5315 print(example["ground_truth"]["cells"][0]) print(example["generated"]["cells"][0]) ``` A typical use: serialize `generated` (optionally with `ground_truth` during training), embed it, and train a regression model to predict `similarity_score`. At inference, the verifier scores new extractions with no ground truth available — enabling automated QA gates, model benchmarking, and extraction-pipeline monitoring. ## Baseline A 2-layer MLP over `sentence-transformers/all-mpnet-base-v2` embeddings trained on this dataset serves as the reference baseline. Training code, data-processing scripts, and the full report: [github.com/rayhu/cs230-evaluation-model](https://github.com/rayhu/cs230-evaluation-model). ## Limitations - Quality labels are computed from a single composite metric; other aspects of extraction quality (numerical consistency, header semantics) are not separately labeled. - Source tables come from scientific journals (SciTSR); domain shift should be expected when applying verifiers to financial, legal, or medical documents. - Generated extractions come from one pipeline (TATR + EasyOCR); scores reflect that pipeline's error distribution. ## Citation If you use this dataset, please cite: ```bibtex @misc{hu2025tableextractioneval, title = {Table Extraction Evaluation Dataset}, author = {Hu, Ray and Teldjoune, Nofel and Zaad, Hiva}, year = {2025}, note = {Stanford CS230 project: A Neural Verifier for Structured Table Extraction}, url = {https://huggingface.co/datasets/rayhu/table-extraction-evaluation} } ``` Upstream data derived from SciTSR: Chi et al., *Complicated Table Structure Recognition*, arXiv:1908.04729, 2019.