To minimally support creating a prototype for the apps Edit Actions Queue we need a simple endpoint which provide a title (or list of titles?) of articles which need a Wikidata description.
IOW, if the wiki allows Wikidata description find articles that don't have descriptions.
A few ideas:
* Wikidata SPARQL query
* A variant of the random/title endpoint that actually favors the ones without a description (better: discards any articles with a description during the scoring process).he first stage of the App Editor Tasks feature requires two API endpoints which return the following:
- A random entity in Wikidata with a Wikipedia article but not a description in the requested language
* Build or add to a module in the MediaWiki API to support this (and maybe wrap in a RESTBase endpoint for client convenience)- A random entity in Wikidata with a description in language A but not language B (where Wikipedia articles corresponding to the entity exist in both languages)
The DB queries required to derive candidates meeting these criteria are far too heavy to run on end-user demand, so we'll need to pre-generate and cache results somewhere.
=== Proposed solution
Add a new Redis-backed PageSuggester implementation to #mediawiki-extensions-gettingstarted to return Wikidata entities from pregenerated sets that meet the specified criteria. See proposed implementation details below in T206504#4859812.
Note: This endpoint should be performant enough so that this can be invoked per end user request (and is not cached) to avoid running into issues where multiple users get the same list of pages that need descriptions, which would lead to multiple users starting adding descriptions for the same article, which could be frustratingWe'll also need to decide on a strategy for keeping pregenerated suggestion sets up-to-date to avoid providing invalid results.
[] **Android team:** Please comment here with exactly what data you need in the API responses.