:- use_module(library(readability_parser)). ?- build_agent("f861ea4...", Agent), parse(Agent, 'http://foo.com/article.html', Response). Response = _{ author: "John Doe" , content: "A long time ago ..." , title: "A Fairy Tale" , word_count: 372 ... }.
Access Readability's parser API for extracting article content from an HTML page.
Using SWI-Prolog 7.1.5 or later:
?- pack_install(readability_parser).
This module uses semantic versioning.
Source code available and pull requests accepted at http://github.com/mndrix/readability_parser
readability_parser.pl | ||
---|---|---|
build_agent/2 | Construct an agent for making API requests using your Readability Parser Token. | |
parse/3 | Like parse/4 but without extra options. | |
parse/4 | Parse an article with Readability's Parser API. |