SuLab / WikidataIntegrator

A Wikidata Python module integrating the MediaWiki API and the Wikidata SPARQL endpoint
MIT License
244 stars 46 forks source link

Replace wdi_property_store.wd_properties with calls to the constraint check api #71

Closed stuppie closed 6 years ago

stuppie commented 6 years ago

The defaults in wdi_property_store.wd_properties are not very generic and cause issues with running a local wikibase (it must be cleared). Consider removing this and using the Constraint system instead.

stuppie commented 6 years ago

Proposal:

On wikidata, the default core IDs will be the properties with a distinct values constraint (select ?p where {?p wdt:P2302 wd:Q21502410} (run))

On a wikibase, we need some way of getting the property constraint qid and pids, so this will be empty by default. There was talk at the workshop of making a standard "config" file for a wikibase instance that would list things like these IDs. WDI could use this config file to retrieve these, as well as other things it may need like mapping relation type QIDs See: https://phabricator.wikimedia.org/T197588

stuppie commented 6 years ago

Done here: https://github.com/SuLab/WikidataIntegrator/commit/1c298a7a96ab68c0207cb7c23ebd77cc4defb3d9 Will merge once I fix some bots...