frontpage.
newsnewestaskshowjobs

Made with ♥ by @iamnishanth

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: Are Tech Meetups Dead?

23•mlinhares•3d ago•20 comments

Ask HN: Gen model to 1) design characters 2) make a consistent comic with them?

4•rvba•5h ago•2 comments

Do they know we can tell it's AI slop?

8•jwsteigerwalt•2h ago•4 comments

Ask HN: Is anyone working at least 4 hours daily on an Apple Vision Pro?

149•widenrun•1d ago•105 comments

Is Amp more or less expensive than Claude Code? Is it better?

3•markosn•8h ago•1 comments

Ask HN: How do you model temporarily invalid data structures

4•escot•1d ago•1 comments

Sqlit – A lazygit-style TUI for SQL databases

20•MaxTeabag•2d ago•2 comments

Tell HN: Android Chrome deletes your browsing history silently

4•grehbies•23h ago•0 comments

Did the Linux memory management maintainer "just quit"?

14•hliyan•2d ago•3 comments

Ask HN: Why didn't the C64 come with Simons' BASIC in the box from 1983 onward?

15•amichail•3d ago•13 comments

We built a B2B API infrastructure for resume parsing and tailoring

3•engspeedy•1d ago•0 comments

Ask HN: Did Messages get removed from Google Takeout?

22•MollyRealized•4d ago•1 comments

Amdahl's Law for LLM generated code

4•akiarie•1d ago•2 comments

S there room for a VPN with zero Five Eyes servers and RAM-only infrastructure?

5•yanbinette•2d ago•3 comments

Ask HN: How do you prepare to tech interview? Any tip and tricks?

16•DmitriyBuchilin•2d ago•19 comments

Ask HN: When and why did you start believing in God?

15•dvrp•1d ago•52 comments

Ask HN: Why do we snore? And what to do about it?

19•simonebrunozzi•2d ago•21 comments

Ask HN: Best worldwide / classic phone games?

7•bix6•3d ago•7 comments

Ask HN: Is $300/HR too low these days for custom full stack?

21•noduerme•4d ago•16 comments

Ask HN: How to get back into programming without AI?

9•coolcoder613•2d ago•20 comments

You've reached the end!