Commit graph

11 commits

Author SHA1 Message Date
LLLin000
3a18160249 chore: gitignore audit per-paper dirs, delete stale annotated_pages, update AGENTS.md
- .gitignore: audit/*/ (keep root summaries), .git-rewrite, .tmp, temp reports
- Delete tests/fixtures/ocr_real_papers/*/annotated_pages/ (stale)
- rm --cached 87 per-paper audit dirs (834 files), temp reports
- AGENTS.md: add role pipeline notes for this session's changes
2026-07-03 02:03:12 +08:00
LLLin000
e0260a8188 feat: recover 'Figure N' heading prefix from PDF text layer for OCR-missed captions
When PaddleOCR fails to detect a standalone 'Figure N' / 'FIGURE N'
heading (rendered in a bold/small-caps font that the OCR engine doesn't
read), the caption body is captured as figure_caption_candidate but
lacks the figure number prefix. The new _recover_figure_heading_prefix()
function checks the PDF text layer (via existing page_pdf_lines_by_page
infrastructure — no extra PDF open) and prepends the heading.

Key logic:
- Scans PDF text lines on the same page for 'Figure N' headings
- Confirms by checking if the NEXT PDF line (by y-order) shares ≥15
  chars of common prefix with the OCR caption candidate text
- Only runs when _extract_figure_number() returns None (no figure
  number in existing caption text)
- Integrated into build_figure_inventory() before _is_formal_legend()
  check, so recovered captions enter the legend matching pool

Fixes 'FIGURE 1' loss in 5S7UI34M and 'FIGURE 5' loss in HQAQBSBP.
372 figure tests pass.
2026-07-03 01:46:40 +08:00
LLLin000
8dba963394 fix: complete reference detection fixes — 5 problem families 2026-07-03 01:46:27 +08:00
LLLin000
01ba102605 fix: support Roman numeral and S-prefix table captions across roles/signatures/tables
- _TABLE_PREFIX_PATTERN in ocr_roles.py, ocr_signatures.py, ocr_tables.py
  now matches Table I/II/III and Table S1/S2
- _extract_table_number and _extract_marker_signature parse Roman numbers
- figure_title generic fallback checks table prefix before figure caption
- ocr_families.py adds early table-prefix guard before reference family
2026-07-02 00:47:18 +08:00
Research Assistant
172c3b2590 audit: vision audit of 2HEUD5P9 + 4AG67PBH (4 oracle agents)
2HEUD5P9 (10 findings):
  - Frontmatter P1: 17/17 correct (PASS)
  - Figures P4/P6/P9/P10/P15/P21: all correct (PASS)
  - Figure on P13: caption mislabeled as body_paragraph (BUG)
  - Boundary P23: clean body/ref transition (PASS)

4AG67PBH (11 findings):
  - Frontmatter P1: 3 footnote->affiliation mismatches (BUG)
  - Frontmatter P1: 2 frontmatter_noise->support mismatches (MINOR)
  - Figures P3: non_body_insert->figure_caption_candidate (BUG)
  - Figures P10: panel D over-segmented (MINOR)
  - Figures P25: author-bio page backmatter mislabel (BUG)
  - Boundary P21: Conflict of Interest heading/body wrong (BUG)
  - Figures P4/10/13/14/15: correctly grouped (PASS)

Cross-paper patterns identified:
  1. footnote_vs_affiliation (4AG67PBH)
  2. figure_caption_mislabel_as_body (both papers)
  3. backmatter_page_mislabel (4AG67PBH)
  4. zone_leak_frontmatter_to_body (both papers)
  5. reference_boundary_body_mix (both papers)
  6. title_repeat_on_page_2 (2HEUD5P9)
2026-06-28 23:40:08 +08:00
Research Assistant
a2bb91a42c audit: data-driven truth audit of 2HEUD5P9 + 4AG67PBH
Findings:
  - zone_leak_frontmatter_to_body: ORCID/copyright/DOI metadata in body_zone (2 papers)
  - reference_boundary_body_mix: body blocks intermixed with ref zone (2 papers)
  - title_repeat_on_page_2: section heading misclassified as paper_title (2HEUD5P9)
  - 12 empty unknown_structural ghost blocks (2HEUD5P9)
  - backmatter_body in body_zone vs tail zone (4AG67PBH)
2026-06-28 23:30:03 +08:00
Research Assistant
4cd0cf3d54 fix: heading detection, backmatter, table consumed, footnote reorder, figure crop + audit fixtures 2026-06-22 01:28:55 +08:00
Research Assistant
33a8028ffc docs: reconcile project truth files after blind audit
- Update PROJECT-MANAGEMENT.md header to 2026-06-19
- Update ocr-v2-closeout-priority.md baseline 945->975, fix typo
- Mark ocr-error-root-cause-fix-queue.md as SUPERSEDED
- Add .gitignore for .opencode/tmp/ and audit annotated_pages
- Add blind audit structured evidence (21 papers, JSON/CSV only)
2026-06-19 15:52:12 +08:00
Research Assistant
47557aa272 docs: update REVIEW and coverage ledger 2026-06-19 15:20:15 +08:00
Research Assistant
d574b191d7 test: formalize OCR layout coverage readiness classes 2026-06-18 22:20:12 +08:00
Research Assistant
eac49edcf2 test: lock OCR readiness baseline and restore coverage ledger 2026-06-18 22:10:52 +08:00