This page summarizes basic aspects of classes in Wikidata. We will define a class-item is any item used as value in a instance of (P31) statement or with a subclass of (P279) statement (subclass) or used as value in a subclass of (P279) statement (superclass). Class-items are mostly used together with instance-items. By definition an instance-item in Wikidata is any item with a instance of (P31) statement.
For more information about classes and instances in Wikidata see:
- subclass of (P279) and its discussion page
- Help:Basic membership properties
- Wikidata:Item classification
this information should be consolidated and merged into one page
- 1 Aspects of classes in ontologies
- 2 Class restrictions
- 3 Class in Wikidata
- 4 References
Aspects of classes in ontologies
There are multiple aspects of classes in ontologies. Please refer to the corresponding Wikipedia articles for definition of class and related terms.
- class (Q5127848): philosophical term denoting a group of things derived from extensional or intensional definition
- class (Q16889133): group of items sharing common characteristics
- class (set theory) (Q217594): collection of sets in mathematics that can be defined based on a property of its members
A class is more general than another when every item that belongs to the second also belongs to the first, as in animal (Q729) is more general than dog (Q144). The more-general class is said to subsume the more-specific class. A class subsumed by another is called a subclass (or subtype) of the subsuming class (or supertype).
Because all items belonging to the superclass also belong to the subclass, any commonality of items belonging to the superclass is also a commonality of objects belonging to the subclass. This relationship is often called inheritance.
A class can be the direct subclass of several classes, permitting multiple inheritance.
Transitivity of Subsumption
Because of the definition of subclass, if B is a subclass of A and C is a subclass of B then C is a subclass of A.
A cycle is created if class A has a subclass B and B is a superclass of A.
Extensional vs. Intensional
Most classes in ontologies have an intentional aspect, i.e., there is an implicit or explicit definition of which items belong to the class. For example, human (Q5) is the class of humans. An item belongs to this class if and only if it is a member of the species homo sapiens. This is independent of whether all such items are explicitly stated to belong to the class or whether there is a formal definition in the ontology of the membership requirements.
A few classes in ontologies may be strictly extensional, i.e., items belong to the class solely by being listed as a member of it.
Disjointness of Classes
Classes may be disjoint from one another, i.e., they cannot have any instances in common, as in human (Q5) is disjoint from dog (Q144). Stating disjointness of classes in an ontology permits the flagging of questionable combinations of facts. For example, if disjointness of humans and dogs is stated in an ontology then items that belong to both classes could be flagged for investigation.
A collection of pairwise disjoint classes whose union has the same members as another class is said to be an exhaustive partition of that class.
Quantifier restriction can be divided into two groups:
- existential restriction: class with individuals having at least one property p with value a
- universal restriction: class with individuals having only property p with value a
- minimual cardinality restriction: restriction defined by a minimal number of relations
- maximal cardinality restriction: restriction defined by a maximal number of relations
- qualified cardinality restriction: restriction defined by a fixed number of relations
Class in Wikidata
Singular or plural ?
Wikidata labels for classes should be singular, at least in English. See also the guidelines in Help:Label.
- Ontology Development 101: A Guide to Creating Your First Ontology, Natalya F. Noy and Deborah L. McGuinness, 2001
- Taxonomy ontology, interesting structure for metaclass
- Two types of ontologies, comparison of two types of ontologies with consequences on their class structure
- visualization doc