Quick Reference Guide

From OWL
Revision as of 04:48, 2 May 2009 by Baojie (Talk | contribs)

Jump to: navigation, search

__NUMBEREDHEADINGS__

[Hide Review Comments]

Document title:
OWL 2 Web Ontology Language
Quick Reference Guide (Second Edition)


Authors
Jie Bao, Rensselaer Polytechnic Institute
Elisa F. Kendall, Sandpiper Software, Inc.
Deborah L. McGuinness, Rensselaer Polytechnic Institute
Contributors
Li Ding, Rensselaer Polytechnic Institute
Ankesh Khandelwal, Rensselaer Polytechnic Institute
Peter F. Patel-Schneider, Bell Labs Research, Alcatel-Lucent
Abstract
The OWL 2 Web Ontology Language, informally OWL 2, is an ontology language for the Semantic Web with formally defined meaning. OWL 2 ontologies provide classes, properties, individuals, and data values and are stored as Semantic Web documents. OWL 2 ontologies can be used along with information written in RDF, and OWL 2 ontologies themselves are primarily exchanged as RDF documents. The OWL 2 Document Overview describes the overall state of OWL 2, and should be read before other OWL 2 documents.
This document provides a quick reference guide to the OWL 2 language. It also provides links to other documents, including the OWL 2 Primer for language introduction and examples, the Syntax document for more details of the functional syntax, and the New Features and Rationale document for new feature descriptions.
This is an editors' draft. The intended final status of this document has not yet been determined; since it may become a Recommendation, it should be considered a Recommendation-Track document for now.
The OWL Working Group solicits feedback on how to improve and update this document.
Copyright © 2008-2009 W3C® (MIT, ERCIM, Keio), All Rights Reserved. W3C liability, trademark and document use rules apply.
Editor's Note: To do list:
  • Make a new pdf print version when the guide is finalized. (pdf) (wiki file)
Editor's Note: There are some links that are currently missing in Primer.
Editor's Note: Christine suggested to use the same naming convention as in Syntax, e.g., CE, DR, OPE, DPE, a and lt

1 Prefixes

The standard prefixes in OWL 2 are:

Prefix Name Prefix IRI
rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
rdfs: <http://www.w3.org/2000/01/rdf-schema#>
owl: <http://www.w3.org/2002/07/owl#>
xsd: <http://www.w3.org/2001/XMLSchema#>

2 OWL 2 constructs and axioms

We use the following notation conventions: 'C' is a class expression, 'D' is a data range, 'P' is an object property expression, 'R' is a data property, 'A' is an annotation property, 'a' is an individual, 'v' is a literal, 'n' is a non-negative integer (as a shorthand for "n"^^xsd:nonNegativeInteger), '_:x' is a blank node, 'O' is an ontology, and 'U' is an IRI. All of the previous can have subscripts. '(a1 … an)' in the RDF syntax is an RDF list.

For an OWL 2 DL ontology, there are some global restrictions on axioms.

In the following tables, the first column gives links to Primer and New Features and Rationale (if applicable), the 2nd column gives links to (Functional) Syntax.

2.1 Classes

Predefined and Named Classes

Language Feature Functional Syntax RDF Syntax
named class U U
universal class owl:Thing owl:Thing
empty class owl:Nothing owl:Nothing

Boolean Connectives and Enumeration of Individuals

Language Feature Functional Syntax RDF Syntax
intersection ObjectIntersectionOf(C1 … Cn) _:x rdf:type owl:Class.
_:x owl:intersectionOf ( C1 … Cn ).
union ObjectUnionOf(C1 … Cn) _:x rdf:type owl:Class.
_:x owl:unionOf ( C1 … Cn ).
complement ObjectComplementOf(C) _:x rdf:type owl:Class.
_:x owl:complementOf C.
enumeration ObjectOneOf(a1 … an) _:x rdf:type owl:Class.
_:x owl:oneOf ( a1 … an ).

Object Property Restrictions

Language Feature Functional Syntax RDF Syntax
universal ObjectAllValuesFrom(P C) _:x rdf:type owl:Restriction.
_:x owl:onProperty P.
_:x owl:allValuesFrom C
existential ObjectSomeValuesFrom(P C) _:x rdf:type owl:Restriction.
_:x owl:onProperty P.
_:x owl:someValuesFrom C
individual value ObjectHasValue(P a) _:x rdf:type owl:Restriction.
_:x owl:onProperty P.
_:x owl:hasValue a.
local reflexivity ObjectHasSelf(P) _:x rdf:type owl:Restriction.
_:x owl:onProperty P.
_:x owl:hasSelf "true"^^xsd:boolean.
exact cardinality ObjectExactCardinality(n P) _:x rdf:type owl:Restriction.
_:x owl:onProperty P.
_:x owl:cardinality n.
qualified exact cardinality ObjectExactCardinality(n P C) _:x rdf:type owl:Restriction.
_:x owl:onProperty P.
_:x owl:qualifiedCardinality n.
_:x owl:onClass C.
maximum cardinality ObjectMaxCardinality(n P) _:x rdf:type owl:Restriction.
_:x owl:onProperty P.
_:x owl:minCardinality n.
qualified maximum cardinality ObjectMaxCardinality(n P C) _:x rdf:type owl:Restriction.
_:x owl:onProperty P.
_:x owl:minQualifiedCardinality n.
_:x owl:onClass C.
minimum cardinality ObjectMinCardinality(n P) _:x rdf:type owl:Restriction.
_:x owl:onProperty P.
_:x owl:maxCardinality n.
qualified minimum cardinality ObjectMinCardinality(n P C) _:x rdf:type owl:Restriction.
_:x owl:onProperty P.
_:x owl:maxQualifiedCardinality n.
_:x owl:onClass C.

Data Property Restrictions

Language Feature Functional Syntax RDF Syntax
universal DataAllValuesFrom(R D) _:x rdf:type owl:Restriction.
_:x owl:onProperty R.
_:x owl:allValuesFrom D.
existential DataSomeValuesFrom(R D) _:x rdf:type owl:Restriction.
_:x owl:onProperty R.
_:x owl:someValuesFrom D.
individual value DataHasValue(R v) _:x rdf:type owl:Restriction.
_:x owl:onProperty R.
_:x owl:hasValue v.
exact cardinality DataExactCardinality(n R) _:x rdf:type owl:Restriction.
_:x owl:onProperty P.
_:x owl:cardinality n.
qualified exact cardinality DataExactCardinality(n R D) _:x rdf:type owl:Restriction.
_:x owl:onProperty P.
_:x owl:qualifiedCardinality n.
_:x owl:onDataRange D.
maximum cardinality DataMaxCardinality(n R) _:x rdf:type owl:Restriction.
_:x owl:onProperty P.
_:x owl:maxCardinality n.
qualified maximum cardinality DataMaxCardinality(n R D) _:x rdf:type owl:Restriction.
_:x owl:onProperty P.
_:x owl:maxQualifiedCardinality n.
_:x owl:onDataRange D.
minimum cardinality DataMinCardinality(n R) _:x rdf:type owl:Restriction.
_:x owl:onProperty P.
_:x owl:minCardinality n.
qualified minimum cardinality DataMinCardinality(n R D) _:x rdf:type owl:Restriction.
_:x owl:onProperty P.
_:x owl:minQualifiedCardinality n.
_:x owl:onDataRange D.

Restrictions Using n-ary Data Range

"Dn" is an n-ary data range.
Language Feature Functional Syntax RDF Syntax
n-ary universal DataAllValuesFrom(R1 … Rn Dn) _:x rdf:type owl:Restriction.
_:x owl:onProperties ( R1 … Rn ).
_:x owl:allValuesFrom Dn.
n-ary existential DataSomeValuesFrom(R1 … Rn Dn) _:x rdf:type owl:Restriction.
_:x owl:onProperties ( R1 … Rn).
_:x owl:someValuesFrom Dn.

Class Axioms

Language Feature Functional Syntax RDF Syntax
subclasses SubClassOf(C1 C2) C1 rdfs:subClassOf C2.
equivalent classes EquivalentClasses(C1 … Cn) Cj owl:equivalentClass Cj+1. j=1…n-1
disjoint classes DisjointClasses(C1 C2) C1 owl:disjointWith C2.
pairwise disjoint classes DisjointClasses(C1 … Cn) _:x rdf:type owl:AllDisjointClasses.
_:x owl:members ( C1 … Cn ).
disjoint union DisjointUnionOf(C C1 … Cn)
C is a named class
C owl:disjointUnionOf ( C1 … Cn ).

2.2 Properties

Object Property Expressions

Language Feature Functional Syntax RDF Syntax
named object property U U
universal object property owl:topObjectProperty owl:topObjectProperty
empty object property owl:bottomObjectProperty owl:bottomObjectProperty
inverse property ObjectInverseOf(P) _:x owl:inverseOf P

Datatype Property Expressions

Language Feature Functional Syntax RDF Syntax
named datatype property U U
universal datatype property owl:topDataProperty owl:topDataProperty
empty datatype property owl:bottomDataProperty owl:bottomDataProperty

Object Property Axioms

Language Feature Functional Syntax RDF Syntax
subproperty SubObjectPropertyOf(P1 P2) P1 rdfs:subPropertyOf P2.
property chain inclusion SubObjectPropertyOf(ObjectPropertyChain(P1 … Pn) P) P owl:propertyChainAxiom (P1 … Pn).
property domain ObjectPropertyDomain(P C) P rdfs:domain C.
property range ObjectPropertyRange(P C) P rdfs:range C.
equivalent properties EquivalentObjectProperties(P1 … Pn) Pj owl:equivalentProperty Pj+1. j=1…n-1
disjoint properties DisjointObjectProperties(P1 P2) P1 owl:propertyDisjointWith P2.
pairwise disjoint properties DisjointObjectProperties(P1 … Pn) _:x rdf:type owl:AllDisjointProperties.
_:x owl:members ( P1 … Pn ).
inverse properties InverseObjectProperties(P1 P2) P1 owl:inverseOf P2.
functional property FunctionalObjectProperty(P) P rdf:type owl:FunctionalProperty.
inverse functional property InverseFunctionalObjectProperty(P) P rdf:type owl:InverseFunctionalProperty.
reflexive property ReflexiveObjectProperty(P) P rdf:type owl:ReflexiveProperty.
irreflexive property IrreflexiveObjectProperty(P) P rdf:type owl:IrreflexiveProperty.
symmetric property SymmetricObjectProperty(P) P rdf:type owl:SymmetricProperty.
asymmetric property AsymmetricObjectProperty(P) P rdf:type owl:AsymmetricProperty.
transitive property TransitiveObjectProperty(P) P rdf:type owl:TransitiveProperty.

Datatype Property Axioms

Language Feature Functional Syntax RDF Syntax
subproperty SubDataPropertyOf(R1 R2) R1 rdfs:subPropertyOf R2.
domain DataPropertyDomain(R C) R rdfs:domain C.
property range DataPropertyRange(R D) R rdfs:range D.
equivalent properties EquivalentDataProperties(R1 … Rn) Rj owl:equivalentProperty Rj+1. j=1…n-1
disjoint properties DisjointDataProperties(R1 R2) R1 owl:propertyDisjointWith R2.
pairwise disjoint properties DisjointDataProperties(R1 … Rn) _:x rdf:type owl:AllDisjointProperties.
_:x owl:members ( R1 … Rn ).
functional property FunctionalDataProperty(R) R rdf:type owl:FunctionalProperty.

2.3 Individuals & Literals

Language Feature Functional Syntax RDF Syntax
named individual U U
anonymous individual :a
'a' is a local label name
_:a
literal (datatype value) "abc"^^datatypeIRI "abc"^^datatypeIRI

2.4 Data Ranges

Language Feature Functional Syntax RDF Syntax
named datatype U U
datatype definition DatatypeDefinition(DT DR)
DT a datatype, DR a data range
DT owl:equivalentClass DR.
data range complement DataComplementOf(D) _:x rdf:type rdfs:Datatype.
_:x owl:datatypeComplementOf D.
data range intersection DataIntersectionOf(D1…Dn) _:x rdf:type rdfs:Datatype.
_:x owl:intersectionOf (D1…Dn).
data range union DataUnionOf(D1…Dn) _:x rdf:type rdfs:Datatype.
_:x owl:unionOf (D1…Dn).
literal enumeration DataOneOf(v1 … vn) _:x rdf:type rdfs:Datatype.
_:x owl:oneOf ( v1 … vn ).
datatype restriction DatatypeRestriction(D f1 v1 … fn vn)
D a datatype, fj a facet, vj a literal
_:x rdf:type rdfs:Datatype.
_:x owl:onDatatype D.
_:x owl:withRestrictions (y1 ... yn).
    yj fj vj. j=1…n
Note: datatypes are data ranges of arity one.

2.5 Keys

Language Feature Functional Syntax RDF Syntax
Keys HasKey(C (P1 … Pm) (R1 … Rn) ) C owl:hasKey (P1 … Pm R1 … Rn).

2.6 Assertions

Language Feature Functional Syntax RDF Syntax
individual equality SameIndividual(a1 … an) aj owl:sameAs aj+1. j=1…n-1
individual inequality DifferentIndividuals(a1 a2) a1 owl:differentFrom a2.
pairwise individual inequality DifferentIndividuals(a1 … an) _:x rdf:type owl:AllDifferent.
_:x owl:members (a1 … an).
class assertion ClassAssertion(C a) a rdf:type C.
positive object property assertion ObjectPropertyAssertion( P a1 a2 )
P is a named object property
a1 P a2.
positive inverse object property assertion ObjectPropertyAssertion( ObjectInverseOf(P) a1 a2 ) a2 P a1.
positive data property assertion DataPropertyAssertion( P a v ) a P v.
negative object property assertion NegativeObjectPropertyAssertion(P a1 a2 ) _:x rdf:type owl:NegativePropertyAssertion.
_:x owl:sourceIndividual a1.
_:x owl:assertionProperty P.
_:x owl:targetIndividual a2
negative datatype property assertion NegativeDataPropertyAssertion(R a v ) _:x rdf:type owl:NegativePropertyAssertion.
_:x owl:sourceIndividual a.
_:x owl:assertionProperty R.
_:x owl:targetValue v

2.7 Declarations

'C', 'D', 'P', 'R', 'A' and 'a' are all named ontology entities.

Language Feature Functional Syntax RDF Syntax
class Declaration( Class( C ) ) C rdf:type owl:Class.
datatype Declaration( Datatype( D ) ) D rdf:type rdfs:Datatype.
object property Declaration( ObjectProperty( P ) ) P rdf:type owl:ObjectProperty.
datatype property Declaration( DataProperty( R ) ) R rdf:type owl:DatatypeProperty.
annotation property Declaration( AnnotationProperty( A ) ) A rdf:type owl:AnnotationProperty.
named individual Declaration( NamedIndividual( a ) ) a rdf:type owl:NamedIndividual.

2.8 Annotations

In this section, 's' is any IRI (e.g., a named ontology, class, datatype, property or individual) or an anonymous individual, 't' can be any IRI, an anonymous individual or a literal.

Annotation of an object

Language Feature Functional Syntax RDF Syntax
annotation assertions AnnotationAssertion( A s t)
s the annotated object, t a resource.
s A t.

or (if the assertion itself has annotation)
s A t.
_:x rdf:type owl:Annotation.
_:x owl:subject s.
_:x owl:predicate A.
_:x owl:object t.

Annotation of an axiom, an ontology or other annotations

Language Feature Functional Syntax RDF Syntax
annotations CONTAINER(Annotation( A t) ) s p o.
_:x rdf:type owl:Axiom.
_:x owl:subject s.
_:x owl:predicate p.
_:x owl:object o.
_:x A t.
If CONTAINER(...) becomes s p o.

_:x p o
_:x A t.
If CONTAINER(...) becomes _:x p o.
Note 1: a CONTAINER can be an axiom, an ontology, or another annotation.
Note 2: for n-ary axioms of the types EquivalentClasses, EquivalentProperties or SameIndividual, they will first be broken up into several RDF triples of their binary forms, then each triple is reified using the above rule.

Annotation Properties

Language Feature Functional Syntax RDF Syntax
named annotation property U U
human-readable name rdfs:label rdfs:label
human-readable comment rdfs:comment rdfs:comment
additional information rdfs:seeAlso rdfs:seeAlso
defining agent rdfs:isDefinedBy rdfs:isDefinedBy
version information owl:versionInfo owl:versionInfo
deprecation owl:deprecated owl:deprecated

Annotation Axioms

Language Feature Functional Syntax RDF Syntax
annotation subproperties SubAnnotationPropertyOf(A1 A2) A1 rdfs:subPropertyOf A2.
annotation property domain AnnotationPropertyDomain(A U) A rdfs:domain U.
annotation property range AnnotationPropertyRange(A U) A rdfs:range U.

Deprecation

C a named class, P a named object property, named datatype property or named annotation property;
Language Feature Functional Syntax RDF Syntax
deprecated class AnnotationAssertion(owl:deprecated C "true"^^xsd:boolean) C rdf:type owl:DeprecatedClass.
deprecated property AnnotationAssertion(owl:deprecated P "true"^^xsd:boolean) P rdf:type owl:DeprecatedProperty.
deprecated IRI AnnotationAssertion(owl:deprecated U "true"^^xsd:boolean) U owl:deprecated "true"^^xsd:boolean.

2.9 Ontologies

Ontologies

Language Feature Functional Syntax RDF Syntax
OWL ontology
(importing )

Ontology([O [U]]
Import(O1)...

Annotation(A v)...
)
O rdf:type owl:Ontology.
[O owl:versionIRI U.]
O owl:imports O1. ...
O A v.
...
prefix declaration Prefix(p=U)
p is a prefix name
@prefix p U.
Note: O1 an ontology IRI; if O is omitted, then in the RDF syntax O is replaced by _:x (an anonymous individual).

Annotation Properties for Ontologies

Language Feature Functional Syntax RDF Syntax
backwards compatibility O Anntation(owl:backwardCompatibleWith U) O owl:backwardCompatibleWith U.
incompatibility O Anntation(owl:incompatibleWith U) O owl:incompatibleWith U.
prior version O Anntation(owl:priorVersion U) O owl:priorVersion U.

3 Built-in Datatypes and Facets

3.1 Built-in Datatypes

universal datatype rdfs:Literal
Numbers owl:rational owl:real
xsd:double xsd:float xsd:decimal xsd:integer
xsd:long xsd:int xsd:short xsd:byte
xsd:nonNegativeInteger xsd:nonPositiveInteger
xsd:positiveInteger xsd:negativeInteger
xsd:unsignedLong xsd:unsignedInt
xsd:unsignedShort xsd:unsignedByte
Strings rdf:text (internationalized strings)
xsd:string xsd:NCName xsd:Name xsd:NMTOKEN
xsd:token xsd:language xsd:normalizedString
Boolean Values xsd:boolean (value space: true and false)
Binary Data xsd:base64Binary xsd:hexBinary
IRIs xsd:anyURI
Time Instants xsd:dateTime (with time zone offset)
xsd:dateTimeStamp (without time zone offset)
XML Literals rdf:XMLLiteral (Note: at Risk in OWL 2)

3.2 Facets

The facet space is a set of pairs of the form < f v >, where f is an IRI called a constraining facet, and v is a value. Each such pair is mapped to a subset of the value space of the datatype.

Notations: Numeric Datatype, String Datatype and Binary datatype refer to a set of datatypes based on the classification done in the prior section.

Facet f Datatype Value v Explanation
xsd:minInclusive,
xsd:maxInclusive,
xsd:minExclusive,
xsd:maxExclusive
Numeric Datatype,
Time instant Datatype
Literal in DT Restricts the value-space to greater than (equal to)
or lesser than (equal to) a value
xsd:minLength,
xsd:maxLength,
xsd:length
String Datatype,
Binary Datatype,
xsd:anyURI
Non-negative integer Restricts the value-space based on the
lengths of the literals
xsd:pattern String Datatype,
xsd:anyURI
xsd:string literal whose value is a regular expression Restricts the value space to literals that
match the regular expression
rdf:langRange rdf:text xsd:string literal whose value is a regular expression Restricts the value space to literals with
language tags that match the regular expression

4 Appendix

4.1 New Features in OWL 2

New features in OWL 2 are (with links to New Features and Rationale) are:

Class Expressions
Class Axioms
Property Expressions
Property Axioms
Data Ranges
Assertions
Annotation
Built-in Extra Datatypes
  • owl:rational, owl:real, xsd:dateTimeStamp, rdf:text
Facets
  • xsd:minInclusive, xsd:maxInclusive, xsd:minExclusive, xsd:maxExclusive
  • xsd:minLength, xsd:maxLength, xsd:length
  • xsd:pattern
  • rdf:langRange
Others

4.2 Deprecated Vocabularies in OWL 2

The following vocabularies are provided in OWL 1 but not encouraged in OWL 2.
OWL 1 Vocabulary Status in OWL 2
owl:DataRange replaced by rdfs:Datatype
owl:distinctMembers replaced by owl:members

5 Acknowledgments

The starting point for the development of OWL 2 was the OWL1.1 member submission, itself a result of user and developer feedback, and in particular of information gathered during the OWL Experiences and Directions (OWLED) Workshop series. The working group also considered postponed issues from the WebOnt Working Group.

This document has been produced by the OWL Working Group (see below), and its contents reflect extensive discussions within the Working Group as a whole. The editors extend special thanks to Bernardo Cuenca Grau (Oxford University), Christine Golbreich (Université de Versailles St-Quentin and LIRMM), Ivan Herman (W3C/ERCIM), Bijan Parsia (University of Manchester) and Peter F. Patel-Schneider (Bell Labs Research, Alcatel-Lucent) for their thorough reviews.

The regular attendees at meetings of the OWL Working Group at the time of publication of this document were: Jie Bao (RPI), Diego Calvanese (Free University of Bozen-Bolzano), Bernardo Cuenca Grau (Oxford University Computing Laboratory), Martin Dzbor (Open University), Achille Fokoue (IBM Corporation), Christine Golbreich (Université de Versailles St-Quentin and LIRMM), Sandro Hawke (W3C/MIT), Ivan Herman (W3C/ERCIM), Rinke Hoekstra (University of Amsterdam), Ian Horrocks (Oxford University Computing Laboratory), Elisa Kendall (Sandpiper Software), Markus Krötzsch (FZI), Carsten Lutz (Universität Bremen), Deborah L. McGuinness (RPI), Boris Motik (Oxford University Computing Laboratory), Jeff Pan (University of Aberdeen), Bijan Parsia (University of Manchester), Peter F. Patel-Schneider (Bell Labs Research, Alcatel-Lucent), Sebastian Rudolph (FZI), Alan Ruttenberg (Science Commons), Uli Sattler (University of Manchester), Michael Schneider (FZI), Mike Smith (Clark & Parsia), Evan Wallace (NIST), Zhe Wu (Oracle Corporation), and Antoine Zimmermann (DERI Galway). We would also like to thank past members of the working group: Jeremy Carroll, Jim Hendler, and Vipul Kashyap.

Retrieved from "http://www.w3.org/2007/OWL/wiki/index.php?title=Quick_Reference_Guide&oldid=23024"