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: Anyone else tired of brands discontinuing your favorite everyday items?

29•GreenPencil7•4h ago•21 comments

Belkin killed my smart switch. I got it working again without their app

3•gaborme•22m ago•0 comments

Ask HN: Crazy as a Service – does it exist?

3•Towaway69•3h ago•1 comments

Fund Momentum MCP: Live VC Fund Data for AI Agents

2•darius88•3h ago•0 comments

Robotics development made dead simple (open source)

19•Ekami•3d ago•7 comments

Ask HN: Is paying for a BIMI certificate useful?

4•gojkoa•4h ago•0 comments

Im 14 and I want to create AI for students

5•grgnend•6h ago•3 comments

Ask HN: Crooked Timber showed showed me a virus captcha, What now?

43•Jgoauh•1d ago•47 comments

Tell HN: Our paid Claude AI subscription unavailable >1 week and no support

45•KellyCriterion•1d ago•21 comments

Protecting My Server and Knowing What It Does with Tailscale and Beszel

5•SyedFazil•11h ago•2 comments

Why I prefer Opus 5 to Fable 5

22•novlrdotcom•1d ago•11 comments

Ask HN: What agentic AI ad optimization tool do you use?

3•smb06•13h ago•1 comments

Ask HN: How many AI agents do you actively use?

4•rjpruitt16•13h ago•16 comments

Ask HN: Semi lucrative careers after tech?

14•hnthrow10282910•19h ago•6 comments

Ask HN: Sectors that are inherently resistant to AI-ification?

4•player_piano•20h ago•7 comments

BMWs shows in-car ads for Spiderman

38•bigmattystyles•1d ago•17 comments

Ask HN: Can't we think out of the box to kill the tumor?

7•kinj28•21h ago•6 comments

Apple please cache my music

2•zirkuswurstikus•16h ago•0 comments

AI the Singularity and where we are

3•nathanyz•17h ago•3 comments

Point AI at a "Proven" Microkernel?

4•RantyDave•18h ago•1 comments

Ask HN: How do you use Copilot in the CLI, App, and IDE?

4•EspressoGPT•1d ago•1 comments

Ask HN: How to rewrite `Claude.md` and install the skill for Opus5 and Fable5

5•hyhmrright•1d ago•6 comments

Repurpose Video Content in Text

2•cristyg0101•19h ago•1 comments

Competitors have more analysts. They should not know more than you

2•Shmungus•20h ago•0 comments

Ask HN: I lost any interest in technology. What do I do?

10•fnoef•20h ago•17 comments

You've reached the end!