Description
Implement built-in functions which, given a Wikidata entity ID for a lexeme or lexeme form, retrieve that entity from Wikidata as a JSON string and use the content to instantiate an instance of the corresponding Wikifunctions type.
The corresponding Wikifunctions types have been merged by this merge request.
Retrieval and instantiation of the following Wikidata types will be done within lexemes and lexeme forms, to the extent they are needed to instantiate lexemes and lexeme forms for initial NLG use cases: Item, Statement, Property, Lexeme sense. However, separate retrieval functions for those 4 types are out of scope for this ticket.
Some Wikidata API details and recommendations are given in T368654.
Desired behavior/Acceptance criteria (returned value, expected error, performance expectations, etc.)
- Performance should be reasonably optimized.
- Errors should be handled and returned appropriately.
Completion checklist
- Before closing this task, review one by one the checklist available here: https://www.mediawiki.org/wiki/Abstract_Wikipedia_team/Definition_of_Done#Back-end_Task/Bug_completion_checklist