Skip to content

Latest commit

 

History

History

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 
 
 

README.md

Extraction Helpers

Shared utility functions for extractor geometry and text operations.

Files

  • geometry.py
    • bbox center/bounds utilities
    • region selection helpers (top_region_spans, bottom_region_spans)
  • span_queries.py
    • anchor search and proximity queries:
      • find spans containing keyword
      • spans to right / below anchors
      • nearest joined text snippets
  • text_parsing.py
    • normalization and parsing helpers:
      • normalize_text
      • extract_money_from_text
      • extract_date_from_text
      • extract_name_like_text

Why This Exists

Without shared helper modules, extractor logic duplicates geometry and regex code across document types. These helpers keep extractor classes focused on document-specific heuristics.