PDF Form Filler Skill (Round 2)
This skill addresses XFA/complex PDF form challenges by using FreeText annotations for field population.
Usage
When field-based filling (via update_page_form_field_values) fails due to XFA structure or non-standard forms, utilize annotation-based filling.
Steps
- Identify fields manually or via
get_fields(). - Map fields to visual page coordinates.
- Use a script to overlay text using
FreeTextannotations. - Execute via the
scripts/fill_pdf_form_with_annotations.pyutility.
Example
# Create a JSON configuration mapping pages, bounding boxes, and field values.
# Use the annotation script:
# python scripts/fill_pdf_form_with_annotations.py input.pdf fields.json output.pdf