Mapping Property URLs with human-readable text
Autocomplete queries made by humans use human language, while the schematree works with urls for the properties. We need a mapping system between the two.
Data that feeds the mapper
Most likely, the properties are also part of the big Wikidata database dump, just like the instances. References describing the dump say that properties are part of it, but I haven't actually downloaded the full dump.
Some people are also using Quarry to get this information. Quarry seems to be a replication of the wikidata database that can be queried. For example this query fetches all the property labels in english. That output there can be downloaded other simpler formats.
Lastly, there is a website that provides filtered dumps of the wikidata dump. There is one category where only the properties are filtered. However, the latest dump that is provided is already very old. This resource might still be valuable because it gives us a sample of what to expect of the original wikidata dump.
Overall, it's important to treat this data feeding as a repeatable process. Even if we hand-craft a good dataset of properties, that information can get quickly outdated. Therefore, using the original wikidata dumps seems like the most elegant version.
Issue steps:
-
Implement the builder for the mapping -
Store the mapping binary for later use. -
Implement the attacher, that receives a list of properties and adds labels and descriptions to each property -
Integrate this glossary with a request on the user (probably needs different request input)