Title: Defining RDF Vocabularies: RDF Schema
1Defining RDF Vocabularies RDF Schema
2Introduction
- RDF provides a way to express simple statements
about resources, using named properties and
values. - RDF user communities also need the ability to
define the vocabularies (terms) they intend to
use in those statements, specifically, to
indicate that they are describing specific kinds
or classes of resources, and will use specific
properties in describing those resources. - extermsTent extermsmodel, extermsweightInKg,
and extermspackedSize - ex2Book or ex2MagazineArticle ex2author,
ex2title, ex2subject - ex3Person and ex3Company ex3age,
ex3jobTitle, ex3stockSymbol, and
ex3numberOfEmployees.
3Introduction (Cont.)
- RDF itself provides no means for defining such
application-specific classes and properties. - Instead, such classes and properties are
described as an RDF vocabulary, using extensions
to RDF referred to as RDF Schema. - RDF Schema provides the facilities needed to
describe classes and properties, and to indicate
which classes and properties are expected to be
used together - In other words, RDF Schema provides a type system
for RDF
4Introduction (Cont.)
- Vocabulary descriptions (schemas) written in the
RDF Schema language are legal RDF graphs. - RDF software that is not written to also process
the additional RDF Schema vocabulary can still
interpret a schema as a legal RDF graph
consisting of various resources and properties,
but will not "understand" the additional built-in
meanings of the RDF Schema terms. - To understand these additional meanings, RDF
software must be written to process an extended
language that includes not only the rdf
vocabulary, but also the rdfs vocabulary,
together with their built-in meanings.
5Describe Class
- A class in RDF Schema corresponds to the generic
concept of a Type or Category - Classes are described using the RDF Schema
resources rdfsClass and rdfsResource, and the
properties rdftype and rdfssubClassOf - In RDF Schema, a class is any resource having an
rdftype property whose value is the resource
rdfsClass
exMotorVehicle rdftype
rdfsClass exVan rdftype rdfsClass exTruck
rdftype rdfsClass
exthingscompanyCar rdftype exMotorVehicle
6Describe Subclass
- The specialization relationship between two
classes is described using the predefined
rdfssubClassOf property to relate the two
classes - The rdfssubClassOf property is transitive
- A class may be a subclass of more than one class
- RDF Schema defines all classes as subclasses of
class rdfsResource
exVan rdfssubClassOf exMotorVehicle
exVan rdfssubClassOf exMotorVehicle
exMiniVan rdfssubClassOf exVan
7A Vehicle Class Hierarchy
8A Vehicle Class Hierarchy (Cont.)
exMotorVehicle rdftype rdfsClass .
exPassengerVehicle rdftype rdfsClass .
exVan rdftype rdfsClass . exTruck
rdftype rdfsClass . exMiniVan rdftype
rdfsClass . exPassengerVehicle
rdfssubClassOf exMotorVehicle . exVan
rdfssubClassOf exMotorVehicle . exTruck
rdfssubClassOf exMotorVehicle . exMiniVan
rdfssubClassOf exVan . exMiniVan
rdfssubClassOf exPassengerVehicle .
ex13.xml
ex14.xml (Type Node Abbreviation)
ex15.xml (Instance)
9Describe Properties
- User communities also need to be able to describe
specific properties that characterize those
classes of things. - In RDF Schema, properties are described using the
RDF class rdfProperty, and the RDF Schema
properties rdfsdomain, rdfsrange, and
rdfssubPropertyOf. - All properties in RDF are described as instances
of class rdfProperty
extermsweightInKg rdftype rdfProperty
10rdfsrange and rdfsdomain
- RDF Schema also provides vocabulary for
describing how properties and classes are
intended to be used together in RDF data. - The most important information of this kind is
supplied by using the RDF Schema properties
rdfsrange and rdfsdomain - rdfsrange indicate that the values of a
particular property are instances of a designated
class - rdfsdomain indicate that a particular property
applies to a designated class
11rdfsrange and rdfsdomain (Example)
exPerson rdftype rdfsClass . exauthor
rdftype rdfProperty . exauthor
rdfsrange exPerson .
exage rdftype rdfProperty . exage
rdfsrange xsdinteger .
exBook rdftype rdfsClass . exauthor
rdftype rdfProperty . exauthor rdfsdomain
exBook .
ex16.xml
ex17.xml (instance)
12Other Schema Information
- rdfscomment property a human-readable
description of a resource - rdfslabel property a more human-readable
version of a resource's name - rdfsseeAlso a resource that might provide
additional information about the subject
resource. - rdfsisDefinedBy property a subproperty of
rdfsseeAlso, and can be used to indicate a
resource that "defines" the subject resource.
13Richer Schema Languages
- Richer schema capabilities that have been
identified as useful (but that are not provided
by RDF Schema) include - Cardinality constraints on properties, e.g., that
a Person has exactly one biological father. - Specifying that a given property (such as
exhasAncestor) is transitive, e.g., that if A
exhasAncestor B, and B exhasAncestor C, then A
exhasAncestor C. - Specifying that a given property is a unique
identifier (or key) for instances of a particular
class. - Specifying that two different classes (having
different URIrefs) actually represent the same
class.
14Richer Schema Languages (Cont.)
- Richer schema capabilities (Cont.)
- Specifying that two different instances (having
different URIrefs) actually represent the same
individual. - Specifying constraints on the range or
cardinality of a property that depend on the
class of resource to which a property is applied,
e.g., being able to say that for a soccer team
the exhasPlayers property has 11 values, while
for a basketball team the same property should
have only 5 values. - The ability to describe new classes in terms of
combinations (e.g., unions and intersections) of
other classes, or to say that two classes are
disjoint (i.e., that no resource is an instance
of both classes). - DAMLOIL, OWL