Skip to content

Conversation

@nonprofittechy
Copy link
Member

This just merges the smaller changes into main that have already been reviewed.

The purpose of this PR is to remove all of the clunky older ML libraries that this package used to rely on, both to improve performance and to reduce costs (since those functions were being hosted on an always-on server).

Fix #135
Fix #145
Fix #133
Fix #131
Fix #128
Fix #79
Fix #37
Fix #39
Fix #41
Fix #42

BryceStevenWilley and others added 30 commits June 16, 2024 22:04
Harder than anticipated, for a few reasons:

* can't get things in order. I guess that's the point of PDFminer, but...
* PDF miner doesn't give you AcroForms at all. It has a completley hardcoded
  way of getting them, outside the context of the page.
* We can do these two things:
    * kinda put all of the fields back in the original text (see replace_original_text).
      Doesn't work too well though, lots of duplicate pieces of text that put many of the fields
      in the same place, when they should be in a different place.
        * could gather fields with the same adjacent text, and get all parts of that text in the PDF.
          Not guaranteed to be in order tho.
    * for each field, get all of the surrounding context. Is okay! But consistently gets too much text for GPT4.
      Even if we make it smaller, sometimes the surrounding context isn't the full sentence, or gets too much from other
      fields (will have too much shared / confusing the two fields).

TBH next goal is to try the PDFPageAndFieldInterpreter approach, notes in there.
Replace passivepy with a call to an LLM
…n-available

Allow working without .env; pull creds from docassemble config
@nonprofittechy nonprofittechy merged commit 1126236 into main Oct 30, 2025
3 checks passed
@nonprofittechy nonprofittechy deleted the migrate-from-spaCy-and-nltk branch October 30, 2025 19:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment