frontpage.
newsnewestaskshowjobs

Open Source @Github

fp.

Ask HN: Which TV do you recommend for privacy?

548•LecroJS•19h ago•660 comments

Ask HN: Isn't anyone worried about this flood of HackerTube-but-for apps?

5•jslakro•1h ago•4 comments

Pepperwind, a fictional company dataset with 223 tables and 79M rows

11•rasinmuhammed•10h ago•0 comments

Tell HN: Scribd Breached

357•x______________•2d ago•123 comments

Ask HN: What is your backup plan when AI companies rug pull their prices?

4•an0malous•2h ago•9 comments

Swedish grocery chain refrigerators and freezers hacked overnight

8•u1hcw9nx•7h ago•3 comments

Heretic 2.0 Released: Training-free language model modification

20•razster•20h ago•3 comments

In LLM era, can software startup survive?

34•sjia•15h ago•42 comments

Tell HN: X is opening any tweet link in a webview whether you press it or not

40•stillatit•2d ago•3 comments

I indexed 37h of my YouTube library using an RTX 4090 and local ML models in 24h

5•iliashad•18h ago•3 comments

Ask HN: What's it like working at Google nowadays? Core teams like Search, Ads?

47•karakoram•2d ago•28 comments

Ask HN: Anyone here still writing code for reasons other than fun or learning?

12•czhu12•1d ago•21 comments

Ask HN: Is applying to Y Combinator worth it if you aren't an insider?

22•all2•2d ago•11 comments

Ask HN: Opus 5.5 suddenly dumb as rocks?

34•jahala•3d ago•32 comments

Which hobby do you think is most diverting and pleasurable?

20•ikelos•1d ago•35 comments

Ask HN: I'd like to request Microsoft open source Windows XP

8•fosco•1d ago•9 comments

Ask HN: Do you have side-projects that generate >$500 revenue/month?

41•learner_yearner•3d ago•24 comments

Ask HN: Old experimental website that made photos sing?

3•jesuisdieu•1d ago•1 comments

Ask HN: Are most of you using HN Replies? Or what else do you use?

8•Gooblebrai•2d ago•9 comments

Tell HN: Claude Code adds your email to the prompt, the LLM sends it to websites

35•TekMol•4d ago•5 comments

"Wrong" Email

26•rbmm•2d ago•5 comments

Ask HN: Hack

10•throwaway3309•3d ago•3 comments

Ask HN: Are Knuth's Stanford Pages Down?

9•weinzierl•3d ago•4 comments

Ask HN: Are you using a custom harness?

11•japhyr•3d ago•8 comments

Ask HN: Is the Microsoft buyout just a long overdue correction?

6•sky2224•2d ago•28 comments

Ask HN: What's the future like? For normies, will it still be apps and websites?

4•talmr•2d ago•5 comments

GEMM Tutorial and UlmBLAS

5•michael-lehn•2d ago•2 comments

Ask HN: Is your leadership pushing you to skip dev review?

10•arm32•3d ago•7 comments

Ask HN: Are you putting off hardware upgrades because of AI coding tools?

5•winrid•2d ago•4 comments

Ask HN: What back end and database are you choosing for new projects in 2026?

5•ibbie•2d ago•2 comments
Open in hackernews

Ask HN: Best on device LLM tooling for PDFs?

4•martinald•1y 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•1y 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•1y ago
give https://pg.llmwhisperer.unstract.com/ a try