frontpage.
newsnewestaskshowjobs

Open Source @Github

fp.

Ask HN: Anthropic is accusing my company of distilling. How can I prove I'm not?

430•weli•1d ago•326 comments

Ask HN: How to manage "crown jewel" files?

2•DLA•43m ago•1 comments

Ask HN: Best VPS Hosting in 2026?

4•CM30•1h ago•1 comments

Ask HN: If you had no limitations what would you build in AI?

8•NarcisMirandes•4h ago•14 comments

Ask HN: Are the trades a safe career transition?

82•Rd6n6•3d ago•121 comments

Ask HN: Am I the only one whose AI hype is cooling down a lot?

33•redleathercouch•1d ago•20 comments

Ask HN: I have been unemployed for 2y. 15 years of experience, US. What to do?

754•LetThingsBeDiff•4d ago•862 comments

Ask HN: Coworker rejects PR (a month in) because it does not meet his standards

18•LandOfMightDev•1d ago•41 comments

I'm Peter Roberts, immigration attorney who does work for YC and startups. AMA

134•proberts•5d ago•182 comments

The CIA is the latest federal agency hit by a cyber breach

3•ethanmercer•12h ago•3 comments

Why are so many services using email magic links for login?

18•bfbf•1d ago•18 comments

Ask HN: What Happened to Midjourney?

9•vmuhammadsaid20•1d ago•3 comments

Ask HN: Its 2026 and there is still not good Email client for macOS. Why?

8•orbanlevi•1d ago•16 comments

Does anyone gets hired with himalaya, well found or other remote hiring sites?

4•rohansrma•1d ago•3 comments

Ask HN: Will Claude be able to solve future maths problems?

3•olirex99•22h ago•10 comments

Ask HN: Everything will get breached. How do you limit the blast radius?

16•humbleferret•1d ago•10 comments

Ask HN: Is a college degree still necessary for a programmer?

7•vmuhammadsaid20•1d ago•18 comments

Tell HN: Claude Opus 4.5 turns one year old today

9•zkldi•1d ago•4 comments

Are you clinging to the TUI to feel like a developer?

7•TomEleff•3d ago•17 comments

Ask HN: How are tech recruiters assessed on their recruiting skills?

4•_override•2d ago•5 comments

Tell HN: OpenRouter prompts to Minimax may have been read

76•dannyw•4d ago•11 comments

What is the likelihood LLMs exploited the learn software to verify their Riemann

3•rsoto2•2d ago•2 comments

Ask HN: Did Amazon Get Hacked?

5•lacoolj•2d ago•1 comments

Ask HN: What Are You Learning?

8•deepakkoli93•2d ago•24 comments

Ask HN: Is Anthropic being public better or worse for your org?

8•ares623•3d ago•11 comments

Ask HN: How likely are we to see a major quantum attack on modern crypto?

5•ijustlovemath•2d ago•4 comments

Tell HN: Today marks the first anniversary of Opus 4.5's release

6•gokhan•1d ago•1 comments

Ask HN: Where the company's employees launch the tools that Claude created

6•vmuhammadsaid20•3d ago•7 comments

You've reached the end!

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