frontpage.
newsnewestaskshowjobs

Made with ♥ by @iamnishanth

Open Source @Github

fp.

Ask HN: How far has "vibe coding" come?

4•pigon1002•2h ago•6 comments

Ask HN: Books to learn 6502 ASM and the Apple II

96•abkt•1d ago•67 comments

Ask HN: Who do you follow via RSS feed?

67•znpy•2d ago•51 comments

Designing programming languages beyond AI comprehension

4•mr_bob_sacamano•13h ago•6 comments

Ask HN: DDD was a great debugger – what would a modern equivalent look like?

55•manux81•3d ago•60 comments

Ask HN: Has Show HN become LLM-prompt-centric?

8•piratesAndSons•13h ago•3 comments

Ask HN: What recent UX changes make no sense to you?

29•superasn•1d ago•33 comments

Ask HN: Where to find cool companies to work for?

5•truetaurus•14h ago•4 comments

Ask HN: What's the Point Anymore?

60•fnoef•1d ago•73 comments

How much recurring income do you generate in 2026 and from what?

9•djshah•1d ago•4 comments

Ask HN: Gmail spam filtering suddenly marking everything as spam?

210•goopthink•4d ago•122 comments

Ask HN: Vibe Researching" with AI – Anyone Using It for Real?

8•spenceXu•1d ago•5 comments

Ask HN: What's the current best local/open speech-to-speech setup?

256•dsrtslnd23•5d ago•61 comments

Ask HN: Notification Overload

7•fractal618•2d ago•8 comments

Ask HN: European alternative to Vercel/Cloudflare for hosting

11•vldszn•1d ago•13 comments

Where can I find startups looking for fractional product leads?

6•stulogy•1d ago•3 comments

How to DeGoogle Myself?

12•neuralkoi•23h ago•1 comments

Ask HN: How to prevent Claude/GPT/Gemini from reinforcing your biases?

29•akshay326•2d ago•22 comments

I built a C++ runtime with immutable objects and no GIL

5•gamarino•1d ago•3 comments

Ask HN: How much emphasis to put on unit testing and when?

9•theturtlemoves•2d ago•18 comments

Tell HN: I cut Claude API costs from $70/month to pennies

40•ok_orco•3d ago•25 comments

Ask HN: If Everyone Can "Build" a SaaS, What Becomes Valuable?

10•spenceXu•1d ago•8 comments

Ask HN: Can a MMO be vibe coded?

3•radicalethics•19h ago•4 comments

Ask HN: What usually happens after a VC asks for a demo?

12•stijo•4d ago•7 comments

Tell HN: JumpCloud 2FA appears to be down

2•sgammon•1d ago•0 comments

Why did the developer go broke?

7•oxqbldpxo•1d ago•6 comments

Generative AI failed to replace SaaS

3•AIFairy•1d ago•2 comments

Ask HN: What's something interesting you learned from training your own GPT?

2•amadeuswoo•1d ago•3 comments

Ask HN: If OpenAI stops its free Web service (ChatGPT)

3•JPLeRouzic•1d ago•2 comments

Ask HN: Is there a good open-source alternative to Adobe Acrobat?

9•sebastian_z•2d ago•9 comments
Open in hackernews

Ask HN: Best on device LLM tooling for PDFs?

4•martinald•8mo ago
I've got very used to using the "big" LLMs for analysing PDFs

Now llama.cpp has vision support; I tried out PDFs with it locally (via LM Studio) but the results weren't as good as I hoped for. One time it insisted it couldn't do "OCR", but gave me an example of what the data _could_ look like - which was the data.

The other major problem is sometimes PDFs are actually made up of images; and it got super confused on those as well.

Given this is so new I'm struggling to find any tools which make this easier.

Comments

raymond_goo•8mo ago
Try something like this

  !pip install pytesseract pdf2image pillow
  !apt install poppler-utils
  #!apt install tesseract-ocr
  from pdf2image import convert_from_path
  import pytesseract

  pages = convert_from_path('k.pdf', dpi=300)

  all_text = ""
  for page_num, img in enumerate(pages, start=1):
      text = pytesseract.image_to_string(img)
      all_text += f"\n--- Page {page_num} ---\n{text}"

  print(all_text)
constantinum•8mo ago
give https://pg.llmwhisperer.unstract.com/ a try