Page MenuHomePhabricator

Concept URIs of foreign entities should be based on URL of the repo entity belongs to, and not be including a prefixed entity ID
Closed, ResolvedPublic

Description

concepturi included in search results returned by API action wbsearchentities consists of the (configurable) URI base and the entity ID (serialized string).

For foreign entity ID foo:Q123 it would result in the concept URI looking like http://www.wikidata.org/entity/foo:Q123. This doesn't seem right. Concept URI of the entity from the foreign repository should be the same as it is when fetched from this "original" repository. Concept URI is meant to be an identifier of the concept, so it should be the same for a single concept, no matter what Wikibase repository provides it.

Repository settings could also include a concept base URI settings, used to build the correct concept URI for entities from this repo, similar to the existing conceptBaseUri setting for the "main" repository.
As hinted by @thiemowmde the URI base is also exposed through siteinfo API as wikibase-conceptbaseuri.

Event Timeline

WMDE-leszek triaged this task as Medium priority.Jan 4 2017, 4:37 PM
WMDE-leszek renamed this task from Concept URI of foreign entities should be based on URL of the repo entity belongs to, and not be including a prefixed entity ID to Concept URIs of foreign entities should be based on URL of the repo entity belongs to, and not be including a prefixed entity ID.Jan 27 2017, 8:56 AM

Change 343092 had a related patch set uploaded (by WMDE-leszek):
[mediawiki/extensions/Wikibase] Add base URI of concept URIs to RepositoryDefinitions

https://gerrit.wikimedia.org/r/343092

Change 343093 had a related patch set uploaded (by WMDE-leszek):
[mediawiki/extensions/Wikibase] Use repo-specific base concept URI to build concepturi in wbsearchentities results

https://gerrit.wikimedia.org/r/343093

Change 343092 merged by jenkins-bot:
[mediawiki/extensions/Wikibase@master] Add base URI of concept URIs to RepositoryDefinitions

https://gerrit.wikimedia.org/r/343092

Change 343093 merged by jenkins-bot:
[mediawiki/extensions/Wikibase@master] Use repo-specific base concept URI to build concepturi in wbsearchentities results

https://gerrit.wikimedia.org/r/343093

Do we already have a ticket tracking this issue for the RDF export?

thiemowmde removed a project: Patch-For-Review.

Nothing to review any more. Please close if you are sure this is done, or move back to proposed.

I don't know if this can be closed, since the scope of the ticket is unclear. From the title, it seems this includes the RDF mapping, which still needs doing. But the description only mentions the search API, which is done.

Daniel's right, it was not clear. Sorry for that.

Do we already have a ticket tracking this issue for the RDF export?

I am going to create one now. I wanted to have it opened before I was gone for few days but ran out of time. That said, I am closing this one.