Skip to content

feat(report): add table output structure signals - #12

Merged
MMoney1988 merged 1 commit into
mainfrom
feat/table-output-structure-signals
May 20, 2026
Merged

feat(report): add table output structure signals#12
MMoney1988 merged 1 commit into
mainfrom
feat/table-output-structure-signals

Conversation

@MMoney1988

Copy link
Copy Markdown
Owner

Summary

Adds a warning-only quality-report check for visible table-output structure signals in normalized parser blocks.

Why

Table-labeled parser output can be hard to review when structure signals are missing or inconsistent. This check gives reviewers a conservative signal before using normalized output for Markdown export, chunk records, or manual review.

What

  • Add Table Output Structure Signals as a PASS/WARN check in the quality report.
  • Inspect table-labeled normalized blocks for visible structure signals such as data_grid, rows, optional cells / html, or delimiter-like content.text.
  • Add conservative interpretation text that avoids PDF ground-truth, parser-accuracy, and table-reconstruction claims.
  • Update README and regenerated page 006/page 012 example reports.
  • Add focused tests for PASS/WARN paths, CLI exit behavior, required-field separation, and interpretation wording.

Tests

  • .venv/bin/python -m pytest -p no:cacheprovider tests -> 92 passed
  • .venv/bin/python -m ruff check src tests -> passed
  • git diff --check -> passed
  • .venv/bin/python -m pdf_quality_report.report --help -> passed
  • .venv/bin/python -m pdf_quality_report.report --input examples/mdpi_pdf_elements/page_006/normalized_blocks.json --output /tmp/page_006_table_signals_report.md -> passed
  • .venv/bin/python -m pdf_quality_report.report --input examples/mdpi_pdf_elements/page_012/normalized_blocks.json --output /tmp/page_012_table_signals_report.md -> passed
  • Claim scan for table reconstruction accuracy / validated table / flattened table detected / table_structure_score / rag-ready / production-ready / OCR accuracy -> no matches

Risks

Low to medium. Reports now include one additional check, so consumers that assume exactly six checks may need to update. The check can move reports to REVIEW when table-output signals are weak, but it does not add hard failures or change CLI exit behavior.

Rollback

Revert this PR to remove the new check, interpretation text, README update, regenerated example report sections, and tests. Existing report checks and CLI behavior return to the previous shape.

@MMoney1988
MMoney1988 merged commit 1679413 into main May 20, 2026
1 check passed
@MMoney1988
MMoney1988 deleted the feat/table-output-structure-signals branch May 20, 2026 11:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant