Live data from Hacker News

Show HN: PDFLayoutTextStripper – Converts PDF to text while keeping the layout

github.com

11–20 of 95 posts

Re: Show HN: PDFLayoutTextStripper – Converts PDF to text while keeping the layout

#11
post #2

who would be interested by an online website doing the job?

if you really want to rake it in, serve, at static speeds (meaning instantly, I swear, boot a ramdrive (Tmpfs) and serve static html from nginx all from RAM), text versions of the top 10,000 web sites. there is so much crap on most sites. re-crawl hourly.

monetize via Google adwords.

EDIT: I'm not sure why I'm being downvoted. I am not suggesting serving PDF's. I am suggesting serving tiny text renders of top sites, that otherwise are much too bloated.

the hard part is getting the text and layout right. many people read many sites for the text IMO.

So I am suggesting you make an all-text version.

As an example, the front page of the New York Times right now, copied into Microsoft Word, is 2504 words. When I save from the word I copied into into .txt - I get a 16.4 KB file.

By comparison, when I put the site into a Page Size Checker -- http://smallseotools.com/website-page-size-checker/ -- I get 214.23 KB. That is impressively small, and it's a fast page.

If I try their competition, the Washington Post, I get 237 KB. If I try the Wall Street Journal, I get 938.15 KB -- nearly a full Megabyte. (This is actually more what I was expecting - I'm impressed by the Times.)

Suppose someone desperately wants to glance at the Wall Street Journal from a poor connection where they barely get data. The difference between 12 KB and nearly a megabyte is huge. Its the difference between 4 seconds and 312 seconds: 4 seconds as compared with 5 full minutes.

So there is a large need in my opinion for such a service in case someone desperately wants to see a text render. Preserving any formatting at all, helps hugely.

Re: Show HN: PDFLayoutTextStripper – Converts PDF to text while keeping the layout

#12
post #9
post #7

Curious if this works better than the pdftotext utility that comes in the Debian poppler-utils package. That has a --layout option that works really well sometimes and really terrible other times. Doesn't seem to be related to document complexity either.

It probably works reasonably well with the documents it has been tested with. It's a very hard problem to crack if you ask me. (edit: word choice)

[deleted]

Re: Show HN: PDFLayoutTextStripper – Converts PDF to text while keeping the layout

#13
post #2

who would be interested by an online website doing the job?

if you really want to rake it in, serve, at static speeds (meaning instantly, I swear, boot a ramdrive (Tmpfs) and serve static html from nginx all from RAM), text versions of the top 10,000 web sites. there is so much crap on most sites. re-crawl hourly. monetize via Google adwords. EDIT: I'm not sure why I'm being downvoted. I am not suggesting serving PDF's. I am suggesting serving tiny text renders of top sites,…

You can use the SHA-1 of the PDF's to avoid serving the same pdf twice.

Re: Show HN: PDFLayoutTextStripper – Converts PDF to text while keeping the layout

#15
post #10

This is important for (al)pine users ... when reading email in a terminal it is very useful to be able to open a PDF attachment as text and view it in the (terminal) mailtool ... Yes, (al)pine is my mailtool in 2017.

Also mutt, which I've switched back to recently. I've got a little Atom powered Chromebook converted to Linux that just does not like modern heavy webmail clients(even GMail when it was still running ChromeOS, and this is one still on the market, Acer CB3-131) so a combination of mutt, mbsync, and msmtp is a much nicer combo. Mutt is a terrific mail reader but its internal SMTP and IMAP handling can be a bit iffy, hence mbsync and msmtp.

Though I can generally open attachments just fine, this text rendering of PDFs would be useful for when I'm SSH'd into my home machine and reading stuff remotely(usually from work where I don't want to download my personal email).

Re: Show HN: PDFLayoutTextStripper – Converts PDF to text while keeping the layout

#17
post #8
post #6

Earlier quoted context omitted.

Privacy is the reason I'd prefer to do this in house.

Not to mention corporate privacy/IP.

Indeed. I might also show this to my wife(works in Nissan), might save her a bit of time.
Post reply on HN