frontpage.
newsnewestaskshowjobs

Open Source @Github

fp.

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

Ask HN: Who's still keeping a DOS machine up because the business depends on it?

278•mlaux•2d ago•293 comments

Ask HN: What are people doing with their OpenClaw set ups now?

12•will10pa•15h ago•5 comments

Management is forcing us to use AI

10•aksjfveoq•9h ago•14 comments

macOS 27: ifconfig command no longer prints hardware MAC address

3•luckman212•21h ago•4 comments

I was impressed by Jev, please explain why I shouldn't be

12•effisfor•21h ago•15 comments

Ask HN: Allow agents access to cloud files with least privilege?

3•beerglass•23h ago•2 comments

Ask HN: Any nerds out there who've read a lot of research papers?

29•shriy-singh•3d ago•28 comments

Ask HN: Hypothesis: Cellular providers are deprioritizing voice calls?

21•tkdb•3d ago•39 comments

Ask HN: IEEE expulsion of Fei-Yue Wang?

11•sathomasga•3d ago•1 comments

Ask HN: How are you getting inference for personal projects?

2•variety8675•1d ago•4 comments

Tell HN: OpenAI $500 ProMax plan listed in API

28•GustavHartz•3d ago•48 comments

Ask HN: Is Opus 5.5 another step change?

16•consumer451•2d ago•18 comments

Ask HN: Who is the inspiration for your thinking?

9•SMAAART•1d ago•15 comments

FYI: OpenAI "spend limits" aren't always limits

4•iambateman•2d ago•1 comments

Ask HN: How do you deal with cyber attacks once you scale?

6•cehgmaster•4d ago•4 comments

Ask HN: Which model do you use for work?

8•george_max•2d ago•15 comments

Ask HN: What vendor you'd switch out if a better option was available?

7•jviotti•2d ago•22 comments

How to Freelance Now?

18•Alexadar•2d ago•16 comments

Tell HN: Substack obfuscating text to break reading mode

19•xnx•5d ago•4 comments

Anyone using a Wispr Flow alternative that is non-cloud?

23•itsjeremiahs•5d ago•17 comments

What do you do now as a software engineer?

8•fawazali•1d ago•7 comments

Ask HN: How do you feel about the new $500 OpenAI subscription?

5•preommr•3d ago•12 comments

Ask HN: What job boards are good these days?

24•phendrenad2•5d ago•17 comments

Tell HN: Chrome 154 corrupt Fontconfig cache and crash KDE Plasma

6•vdfs•2d ago•0 comments

Ask HN: LM Studio Bionic with Python?

3•HoldOnAMinute•2d ago•1 comments

Ask HN: Does spec-driven development still pay off with frontier coding models?

6•sarangk90•3d ago•4 comments

Ask HN: Are .shop domains down?

6•esher•3d ago•8 comments

Ask HN: Has anyone built a leaderless multi-agent system?

4•har-ki•2d ago•2 comments

You've reached the end!