Lably
Skip to content

Wikidata

Collaborative multilingual knowledge graph

  • 9 min read
  • 5 chapters

Related on Lably

Through Identifier, Arthur Conan Doyle and Linguistics

Concept

Wikidata is a document-oriented database, focusing on items, which represent any kind of topic, concept, or object. Each item is allocated a unique persistent identifier called its QID, a positive integer prefixed with the upper-case letter "Q". This makes it possible to provide translations of the basic information describing the topic each item covers without favoring any particular language.

Some examples of items and their QIDs are 1988 Summer Olympics (Q8470), love (Q316), Johnny Cash (Q42775), Elvis Presley (Q303), and Gorilla (Q36611).

Item labels do not need to be unique. For example, there are two items named "Elvis Presley": Elvis Presley (Q303), which represents the American singer and actor, and Elvis Presley (Q610926), which represents his self-titled album. However, the combination of a label and its description must be unique. To avoid ambiguity, an item's QID is hence linked to this combination.

Main parts

Fundamentally, an item consists of:

  • An identifier (the QID), related to a label and a description.
  • Optionally, multiple aliases and some number of statements (and their properties and values).

Statements

Statements are how any information known about an item is recorded in Wikidata. Formally, they consist of key–value pairs, which match a property (such as "author", or "publication date") with one or more entity values (such as "Sir Arthur Conan Doyle" or "1902"). For example, the informal English statement "milk is white" would be encoded by a statement pairing the property color (P462) with the value white (Q23444) under the item milk (Q8495).

Statements may map a property to more than one value. For example, the "occupation" property for Marie Curie could be linked with the values "physicist" and "chemist", to reflect the fact that she engaged in both occupations.

Values may take on many types, including other Wikidata items, strings, numbers, or media files. Properties prescribe what types of values they may be paired with. For example, the property official website (P856) may only be paired with values of type "URL".

Optionally, qualifiers can be used to refine the meaning of a statement by providing additional information. For example, a "population" statement could be modified with a qualifier such as "point in time (P585): 2011" (as its own key-value pair). Values in the statements may also be annotated with references, pointing to a source backing up the statement's content. As with statements, all qualifiers and references are property–value pairs.

Properties

Each property has a numeric identifier prefixed with a capital P and a page on Wikidata with an optional label, description, aliases, and statements. As such, there are properties with the sole purpose of describing other properties, such as subproperty of (P1647).

Properties may also define more complex rules about their intended usage, termed constraints. For example, the capital (P36) property includes a "single value constraint", reflecting the reality that (typically) territories have only one capital city. Constraints are treated as testing alerts and hints, rather than inviolable rules.

Before a new property is created, it needs to undergo a discussion process.

The most used property is cites work (P2860), which is used on more than 290,000,000 item pages as of November 2023.

Lexemes

In linguistics, a lexeme is a unit of lexical meaning representing a group of words that share the same core meaning and grammatical characteristics. Similarly, Wikidata's lexemes are items with a structure that makes them more suitable for storing lexicographical data. Since 2016, Wikidata has supported lexicographical entries in the form of lexemes.

In Wikidata, lexicographical entries have a different identifier from regular item entries. These entries are prefixed with the letter L, such as in the example entries for book (L16168) and cow (L3726). Lexicographical entries in Wikidata can contain statements, senses, and forms. The use of lexicographical entries in Wikidata allows for the documentation of word usage, the connection between words and items on Wikidata, word translations, and enables machine-readable lexicographical data.

In 2020, lexicographical entries on Wikidata exceeded 250,000. The language with the most lexicographical entries was Russian, with a total of 101,137 lexemes, followed by English with 38,122 lexemes. There are over 668 languages with lexicographical entries on Wikidata.

Entity schemas

In Wikidata, a schema is a data model that outlines the necessary attributes for a data item. For instance, a data item that uses the attribute "instance of" with the value "human" would typically include attributes such as "place of birth," "date of birth," "date of death," and "place of death." The entity schema in Wikidata utilizes Shape Expression (ShEx) to describe the data in Wikidata items in the form of a Resource Description Framework (RDF). The use of entity schemas in Wikidata helps address data inconsistencies and unchecked vandalism.

In January 2019, development started of a new extension for MediaWiki to enable storing ShEx in a separate namespace. Entity schemas are stored with different identifiers than those used for items, properties, and lexemes. Entity schemas are stored with an "E" identifier, such as E10 for the entity schema of human data instances and E270 for the entity schema of building data instances. This extension has since been installed on Wikidata and enables contributors to use ShEx for validating and describing Resource Description Framework data in items and lexemes. Any item or lexeme on Wikidata can be validated against an entity schema, and this makes it an important tool for quality assurance.

Sign in to keep reading

4 more chapters are free with a Lably account.

More in Human body