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

I turned an ESP32-S3 into a Tailscale gateway with recovery functions

4•Mattboxx•1h ago•1 comments

Ask HN: What in the world is taking Ubuntu so long?

209•linsomniac•23h ago•132 comments

Tell HN: Gemini trains on chat history, even for subscribers (personal accounts)

727•jameslk•3d ago•200 comments

Ask HN: What's your current AI agentic setup?

548•eggbrain•2d ago•678 comments

Claude usage credits purchased after Dec 7 will expire 12 months after purchase

14•bbg2401•14h ago•6 comments

Ask HN: What cryptography book do you recommend for reading with 10 year olds?

89•mike_richards•4d ago•82 comments

OpenAI seems to be silently re-enabling model training on Codex chats

530•user052919•3d ago•163 comments

Tell HN: Be Careful with Stripe Connect

16•breue•16h ago•3 comments

Ask HN: What are forgotten topics in computing that deserve a new revisit?

42•draxen•1d ago•39 comments

Seeking advice: Wix stolen my .com domain

11•wixcom•1d ago•10 comments

Ask HN: What fun things to do with an iPhone 11?

8•wanderingpixel•22h ago•5 comments

Gitbook Breached

164•punchmesan•3d ago•45 comments

Slickdeals.net Is Compromised

20•intenex•18h ago•1 comments

Tell HN: Don't use Postman, they proxy your info without your permission

109•neya•3d ago•7 comments

A new protocol and software suite for AIs

2•homingpigeon•18h ago•0 comments

Looking for a CTO

3•alpbahadur•21h ago•6 comments

I tried to connect every GPU on the planet together (kinda)

4•lukefrisker•21h ago•2 comments

Ask HN: How are companies hiring developers nowadays?

4•Frazzlebilt•23h ago•2 comments

OpenClaw SaaS?

3•alexfthom•23h ago•10 comments

Ask HN: How to resist endless app directories listing your product?

2•gosen•23h ago•0 comments

Ask HN: Does anyone have a contact with Cleveland-area Ham club?

166•stockresearcher•4d ago•23 comments

WorkOS reports security breach

81•werrett•4d ago•11 comments

Verifying a satellite image with temporal evidence

2•avijeetsingh16•1d ago•1 comments

Executive (C-Level) Decision Making Under Uncertainty with Large Language Models

2•northlondoner•1d ago•0 comments

Ask HN: Is anyone running multi/always-on agents that don't cost a fortune?

5•abejora•1d ago•3 comments

Ask HN: How's your home-cooked software revolution going?

3•nihakue•1d ago•3 comments

Ask HN: What is the most secure OS for mobile phone?

5•Muralnick•1d ago•2 comments

Ask HN: How can I get informed in the static vs. dynamic typing debate?

2•zingar•1d ago•4 comments

Ask HN: Engineers Focus Using AI

3•elchuzade•1d ago•2 comments

Ask HN: Has anyone used LLMs to audit TrueCrypt for backdoors?

5•dlphii•1d ago•1 comments