Skip to content

馃悵 Filter non-heading PDF bookmarks from section navigation - #208

Open
JFWooten4 wants to merge 1 commit into
mainfrom
quiet-quill
Open

JFWooten4 wants to merge 1 commit into
mainfrom
quiet-quill

Conversation

@JFWooten4

Copy link
Copy Markdown
Member

Problem

The 1,315-page SEC/FCIC follow-up exhibits PDF embeds 545 native bookmarks, not all of which represent document headings. Its outline includes spreadsheet sheet names (Stock_Chart, C_chart_rate, Top15_bearish), data names (aurelius, rankdat), and table cells (Variable, Mean, Median, percentage values). The viewer currently presents them indiscriminately under Sections.

Changes

  • Filter entries only in sibling groups that have strong evidence of machine-generated bookmarks (at least 12 entries, including at least six data-like labels).
  • Preserve genuine numbered sections, table/figure identifiers, first-page document titles, and ordinary human-authored bookmark lists.
  • Provide Show all bookmarks (N hidden) / Show sections within the sidebar, so every original PDF destination remains accessible.
  • Preserve source sibling positions for fallback copy references even when some entries are hidden. Keep the unmodified bookmark list available for printed-contents resolution.

Verification

  • Added four focused regression tests based on bookmarks observed in the linked PDF, including spreadsheet artifacts, numeric table cells, unchanged ordinary outlines, and viewer toggle wiring.
  • Executed the filter unit checks locally: 4 passed, 0 failed.
  • Verified the commit is one ahead of main, its tree differs from its parent, and the five intended files are present.
  • Not performed: full extension build, browser-side manual reproduction, full test suite. This addresses the viewer's presentation of existing PDF outline entries, not any separate heading-tagging decisions made by the OCR enhancer.

Scope

This does not rewrite or erase bookmarks in the PDF. The original outline remains accessible through the toggle and is still available for other navigation features.

Hide spreadsheet sheet names, chart labels, and table-cell values in conspicuously noisy PDF bookmark groups, while preserving genuine section labels and an opt-in view of every original bookmark.

Co-authored-by: Codex Web <noreply@openai.com>
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