Special property "Has preferred property label"

From semantic-mediawiki.org
Has preferred property label
Adds localizable labels to a property
Further Information
Provided by: extension "Semantic MediaWiki "Allows to store and query data annotated to pages
Added: 2.5.0
Removed: still in use
Alias: Preferred property label
Optional: no
Visible: yes
Annotable: yes
Declarative: yes
Setting: not specified
Focus: language information
In this wiki: Property:Has preferred property label
Table of Contents

The Has preferred property label property is a special property in Semantic MediaWiki with a built-in meaning: it adds the possibility to localize the label of a property. It was introduced starting with Semantic MediaWiki

With the introduction of the "Monolingual text" datatype, Semantic MediaWiki is able to provide a method to denote a text element of arbitrary length with a language tag thus allowing it to distinguish such text by the same attribute.

Adding preferred labels to a property specification is aimed at increasing the likelihood for a user to understand the concept of a particular property by defining a label in a language (as side from the canonical label) a user is most familiar with.

Features and limitations[edit]

  • Borrowing on the "skos:prefLabel"2 definition, the preferred label is understood as to only have one label per given language (while "skos:altLabel"3 can have many alternative labels but this is not part this issue)
  • To separate a canonical label from a preferred label during the output, a small p hint will be shown along with the label
  • The preferred label feature is aimed for the output and not for the annotation process, meaning that a reverse matching during an annotation process is not supported ([[Has population::123]] vs [[人口@ja::123]], annotations are expected to use the canonical identifier or label)
  • The user language is being used as selective attribute that will trigger a change of labels, if available
  • Can easily be combined with the property link feature4 ([[SomeProperty::@@@]] or [[SomeProperty::@@@en]]) to create local-specific infoboxes.


On the "Has population" property page in namespace "Property" one would add the following to define preferred property labels for the the languages specified language French (fr), German (de), Japanese (ja) and Spanisch (es):

* [[Has preferred property label::population@fr]]
* [[Has preferred property label::Bevölkerung@de]]
* [[Has preferred property label::人口@ja]]
* [[Has preferred property label::población@es]]
Other examples

See also[edit]


  1. ^  Semantic MediaWiki: GitHub issue gh:smw:1865
  2. ^  skos:prefLabel is described as "preferred lexical label for a resource, in a given language" and skos-primer notes further that "... it is recommended that no two concepts in the same KOS be given the same preferred lexical label for any given language tag ...", Retrieved from: https://www.w3.org/TR/skos-primer/#secpref
  3. ^  At the time of this writing, skos:altLabel or alternative labels (different labels for the same language) are not supported.
  4. ^  Semantic MediaWiki: GitHub issue gh:smw:1855