The Easy Way to Extract Useful Text from Arbitrary HTML
1–10 of 13 posts
Re: The Easy Way to Extract Useful Text from Arbitrary HTML
#2Re: The Easy Way to Extract Useful Text from Arbitrary HTML
#3Anyone else getting an error page about this site being reported to be an "attack website"?
Re: The Easy Way to Extract Useful Text from Arbitrary HTML
#4Anyone else getting an error page about this site being reported to be an "attack website"?
Re: The Easy Way to Extract Useful Text from Arbitrary HTML
#5Anyone else getting an error page about this site being reported to be an "attack website"?
I think it's blacklisted by google but it appears to be perfectly safe
For anyone who wants to read the article, this works. (I put in URL_HERE as a placeholder because HN truncates the URL):
lynx --dump URL_HERE > output.txt
Ironic that to read the article, I used a technique that solves the problem the article is talking about solving. In a much easier way, I might add!
Re: The Easy Way to Extract Useful Text from Arbitrary HTML
#6Anyone else getting an error page about this site being reported to be an "attack website"?
Opera 9.5 and IE 7 (both w/ phishing detection as well) don't flag it. Google's malware detection engine has been known to be off plenty of times before - lost a startup I know a month's income because some bad sites were linking to them, before they apologized and undid their blacklisting.
Re: The Easy Way to Extract Useful Text from Arbitrary HTML
#7 1. Parse the HTML code and keep track of the number of bytes processed.
2. Store the text output on a per-line, or per-paragraph basis.
3. Associate with each text line the number of bytes of HTML required to describe it.
4. Compute the text density of each line by calculating the ratio of text to bytes.
5. Then decide if the line is part of the content by using a neural network.
You can get pretty good results just by checking if the line’s density is above a fixed threshold (or the average), but the system makes fewer mistakes if you use machine learning — not to mention that it’s easier to implement!for whose who too scared to follow link...
Re: The Easy Way to Extract Useful Text from Arbitrary HTML
#8Not that this approach is any easier, its just perhaps more robust for applying to other problem sets.
Nothing new of course, according to their website, Autonomy (Europe's 2nd largest software company) uses these techniques as the basis for their core technology to analyze text, audio, video, etc.
Re: The Easy Way to Extract Useful Text from Arbitrary HTML
#9Earlier quoted context omitted.
I think it's blacklisted by google but it appears to be perfectly safe
Most attack sites do. Appear to be perfectly safe, that is. For anyone who wants to read the article, this works. (I put in URL_HERE as a placeholder because HN truncates the URL): lynx --dump URL_HERE > output.txt Ironic that to read the article, I used a technique that solves the problem the article is talking about solving. In a much easier way, I might add!