smalot / smalot/pdfparser

Parsing big pdfs

Open
#75 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
PHP
Stars
2.7k
Forks
579
Avg merge
2m
Merged PRs (30d)
1

Description

Hi,
First of all, good job on this tool. It really suits for what i'm trying to do.
I am trying to upload and parse pdfs for data processing. To do so, I upload and search for key-words in the text retrieved with PdfParser in order to move them in the right folder (1st step of processing). I have no trouble using this for small files (approximately < 15Mo). However, when files are bigger than that, the text generated by $pdf -> $getText() is somehow bugged. Occurences of characters like "!"#$"%&!"!''$(%&#$)%&!")'$*+(%!,-$" appear and it doesn't seem to display the text in the right order.
I can't figure out the reason. Do you have any ideas ?

Thanks you in advance,
Best regards,
Thibaut

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Reproduce the report by parsing PDFs below and above approximately 15 MB with PdfParser and comparing the text returned by getText(). Inspect the extraction path for the malformed character occurrences and ordering differences; done means large PDFs produce readable text in the expected order without the reported artifacts.

Written by the indexing model from the issue text.

Assessment

Tech stack
php
Domain
backend
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.