JeroenDeDauw / QueryrAPI

🖹 REST API for Wikibase data
https://wikibase.consulting
7 stars 0 forks source link

Is there a sensible way to order properties? #41

Open JeroenDeDauw opened 8 years ago

JeroenDeDauw commented 8 years ago

The data at http://queryr.wmflabs.org/api/items/Q64/data is grouped and indexed by property. Right now no ordering is applied. Does some kind of order make sense?

JeroenDeDauw commented 8 years ago

Ping @addshore

jane023 commented 8 years ago

The lowest property id would get my vote, as this just means "oldest property created on Wikidata" and those tend to be the most important one. So e.g. for most items, P31 ( means "instance of" something ) is the lowest property and also the most useful.

On Sun, Dec 6, 2015 at 6:23 AM, Jeroen De Dauw notifications@github.com wrote:

The data at http://queryr.wmflabs.org/api/items/Q64/data is grouped and indexed by property. Right now no ordering is applied. Does some kind of order make sense?

  • lowest property id first
  • alphabetic sorting based on property name
  • something the Wikidata API or perhaps the Wikidata UI does
  • ???

— Reply to this email directly or view it on GitHub https://github.com/JeroenDeDauw/QueryrAPI/issues/41.

addshore commented 8 years ago

lowest property id first alphabetic sorting based on property name

Both of these would make sense. Personally I would go with ordered by PID as a default?

something the Wikidata API or perhaps the Wikidata UI does

Not reallly

adrianheine commented 8 years ago

@jane023 Although properties tend to get replaced from time to time.

Currently we don't have an automatic ordering done in Wikibase/Wikidata, but @frimelle's working on that for the article placeholders.

JeroenDeDauw commented 8 years ago

Ordering is now done by property id ec3b76c8038396e43f9c41b9382dd8b7beb0e63f. Keeping this question open though.

jane023 commented 8 years ago

The same is true of Q numbers btw. So lowest numbers probably are the most important and have Wikipedia articles in the most languages, though Q numbers get replaced from time to time.

JeroenDeDauw commented 8 years ago

Items and properties on their respective collection endpoints are already ordered by ID: http://queryr.wmflabs.org/api/items

frimelle commented 8 years ago

Well, we have this mediawiki page discussing the topic; https://www.mediawiki.org/wiki/Requests_for_comment/Statement_group_ordering (on phabricator: https://phabricator.wikimedia.org/T117681 ) That was mainly for the Article Placheolder but also for the Article Placeholder in particular, there is this ticket: https://phabricator.wikimedia.org/T117680 I'll work on that over the next days probably.