class orangecontrib.text.wikipedia_api.WikipediaAPI(on_error=None)[source]

Wraps Wikipedia API.


>>> api = WikipediaAPI()
>>> corpus ='en', ['Barack Obama', 'Hillary Clinton'])
search(lang, queries, articles_per_query=10, should_break=None, on_progress=None)[source]

Searches for articles.

  • lang (str) – A language code in ISO 639-1 format.

  • queries (list of str) – A list of queries.

  • should_break (callback) – Callback for breaking the computation before the end. If it evaluates to True, downloading is stopped and document downloaded till now are returned in a Corpus.

  • on_progress (callable) – Callback for progress bar.