Presentation is loading. Please wait.

Presentation is loading. Please wait.

E © 2002 Dario Aganovic Resource Description Framework Schema (RDFS) Dario Aganovic Industrial PhD-student NPI Production Kista, Ericsson AB and Production.

Similar presentations


Presentation on theme: "E © 2002 Dario Aganovic Resource Description Framework Schema (RDFS) Dario Aganovic Industrial PhD-student NPI Production Kista, Ericsson AB and Production."— Presentation transcript:

1 e © 2002 Dario Aganovic Resource Description Framework Schema (RDFS) Dario Aganovic Industrial PhD-student NPI Production Kista, Ericsson AB and Production Engineering Department Kungl Tekniska Högskolan Semantic Web PhD-Course Linköping, 2002-03-20

2 e © 2002 Dario Aganovic RDF Foundation for processing metadata on the www. A metadata model. Three object types: resource, property, and statement. RDF XML syntax Application domain independent ResourcePropertyProperty Value Statement SubjectPredicateObject

3 e © 2002 Dario Aganovic Why RDFS? Semantics of a certain application domain needs to be represented. Properties should be re-used globally. Their domain and range need therefore to be clearly specified. Classes of resources that properties connect need to be specified in class and subclass hierarchies. RDFS provides means to do that.

4 e © 2002 Dario Aganovic The Data Integrity Problem Austin Mitchell <epx:CandidateFor rdf:resource="http://www.pa.press.net/constituencies/281" /> Labour Party 19 September, 1934 How do we know that this resource actually represents a constituency?

5 e © 2002 Dario Aganovic The Data Integrity Problem Great Grimsby Fishing 19 September, 1934 Isn´t it obvious that a parlamentary constituency doesn´t have a DOB-property?

6 e © 2002 Dario Aganovic Validation of Statements Is the object suitable for the predicate? Is the predicate suitable for the subject? { epx:DOB, [http://www.pa.press.net/constituencies/281], "19 September, 1934" } { epx:CandidateFor, [http://www.epolitix.com/austin-mitchell], [http://www.microsoft.com/] }

7 e © 2002 Dario Aganovic Typing Resources How do we know that this is a consistuency? Great Grimsby Fishing We need to type this resource as a consistuency.

8 e © 2002 Dario Aganovic Resource Type: Consistuency <rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:epx="http://www.ePolitix.com/2001/03/rdf-schema#" > <rdf:type resource="http://www.ePolitix.com/2001/03/rdf-schema#Constituency" /> Great Grimsby Fishing

9 e © 2002 Dario Aganovic Specifying property values: linking a predicate to an apropriate object { epx:CandidateFor, [http://www.epolitix.com/austin-mitchell], [http://www.microsoft.com/] } Invalid: Not a consistuency

10 e © 2002 Dario Aganovic Specifying property values: linking a predicate to an apropriate object <rdf:Description rdf:about="http://www.ePolitix.com/2001/03/rdf-schema#CandidateFor" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" > <rdf:type resource="http://www.w3.org/1999/02/22-rdf-syntax-ns#Property" /> Create rdf:property CandidateFor

11 e © 2002 Dario Aganovic Specifying property values: linking a predicate to an apropriate object Constrain the property CandidateFor to only have a value that is a resource of type Constituency <rdf:Property rdf:about="http://www.ePolitix.com/2001/03/rdf-schema#CandidateFor" > <rdfs:range rdf:resource="http://www.ePolitix.com/2001/03/rdf-schema#Constituency" />

12 e © 2002 Dario Aganovic <rdf:Property rdf:about="http://www.ePolitix.com/2001/03/rdf-schema#CandidateFor" > <rdfs:range rdf:resource="http://www.ePolitix.com/2001/03/rdf-schema#Constituency" /> Prefix for RDF schema namespace. Namespace URI: http://www.w3.org/2000/01/rdf-schema# RDFS Namespace

13 e © 2002 Dario Aganovic <rdf:Property rdf:about="http://www.ePolitix.com/2001/03/rdf-schema#CandidateFor" > <rdfs:range rdf:resource="http://www.ePolitix.com/2001/03/rdf-schema#Constituency" /> An instance of ConstraintProperty that is used to indicate the class(es) that the values of a property must be members of. The value of a range property is always a Class. Range constraints are only applied to properties. A property can have at most one range property. It is possible for it to have no range, in which case the class of the property value is unconstrained. rdfs:range

14 e © 2002 Dario Aganovic Validation of Statements Is the object suitable for the predicate? Is the predicate suitable for the subject? { epx:DOB, [http://www.pa.press.net/constituencies/281], "19 September, 1934" } { epx:CandidateFor, [http://www.epolitix.com/austin-mitchell], [http://www.microsoft.com/] }

15 e © 2002 Dario Aganovic Specifying resource properties: linking predicates to apropriate subjects Constrain the property CandidateFor to only apply to resources of type Person rdf:Property rdf:about="http://www.ePolitix.com/2001/03/rdf-schema#CandidateFor"> <rdfs:domain rdf:resource="http://www.Schemas.org/2001/01/rdf-schema#Person" /> <rdfs:range rdf:resource="http://www.ePolitix.com/2001/03/rdf-schema#Constituency" />

16 e © 2002 Dario Aganovic rdfs:domain rdf:Property rdf:about="http://www.ePolitix.com/2001/03/rdf-schema#CandidateFor"> <rdfs:domain rdf:resource="http://www.Schemas.org/2001/01/rdf-schema#Person" /> <rdfs:range rdf:resource="http://www.ePolitix.com/2001/03/rdf-schema#Constituency" /> An instance of ConstraintProperty that is used to indicate the class(es) on whose members a property can be used. A property may have zero, one, or more than one class as its domain. If there is no domain property, it may be used with any resource. If there is exactly one domain property, it may only be used on instances of that class (which is the value of the domain property). If there is more than one domain property, the constrained property can be used with instances of any of the classes (that are values of those domain properties).

17 e © 2002 Dario Aganovic rdfs:ConstraintProperty This resource defines a subclass of rdf:Property, all of whose instances are properties used to specify constraints. This class is a subclass of rdfs:ConstraintResource and corresponds to the subset of that class representing properties. Both rdfs:domain and rdfs:range are instances of rdfs:ConstraintProperty. rdfs:ConstraintResource This resource defines a subclass of rdfs:Resource whose instances are RDF schema constructs involved in the expression of constraints. The purpose of this class is to provide a mechanism that allows RDF processors to assess their ability to use the constraint information associated with an RDF model.

18 e © 2002 Dario Aganovic Re-use of properties: Fake school elections (RDF-statements) Mark Birbeck <epx:CandidateFor rdf:resource="http://www.pa.press.net/constituencies/281" /> 28 September, 1964

19 e © 2002 Dario Aganovic Re-use of properties: Event web-site (a RDFS fragment) <rdfs:domain rdf:resource="http://www.WhatsOnWhere.com/2001/01/rdf-schema#Event" />

20 e © 2002 Dario Aganovic Multiple Types <rdf:Description rdf:about="http://www.epolitix.com/austin-mitchell" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:s="http://www.Schemas.org/2001/01/rdf-schema#" xmlns:epx="http://www.ePolitix.com/2001/03/rdf-schema#" > Austin Mitchell 19 September, 1934 <epx:CandidateFor rdf:resource="http://www.pa.press.net/constituencies/281" /> Labour Party

21 e © 2002 Dario Aganovic Multiple Types

22 e © 2002 Dario Aganovic Classes in RDFS No methods. Only properties Property-centric. In OOP a class is a set of methods and properties whilst in RDF a property is defined as being applicable to a class. A property exists independantly of relationship between two certain classes.

23 e © 2002 Dario Aganovic rdfs:Class <rdfs:Class rdf:about="http://www.Schemas.org/2001/01/rdf-schema#Person" xmlns:rdfs="http://www.w3.org/2000/01/rdf-schema#" /> This corresponds to the generic concept of a Type or Category, similar to the notion of a Class in object-oriented programming languages such as Java. When a schema defines a new class, the resource representing that class must have an rdf:type property whose value is the resource rdfs:Class. RDF classes can be defined to represent almost anything, such as Web pages, people, document types, databases or abstract concepts.

24 e © 2002 Dario Aganovic Creating Subclasses

25 e © 2002 Dario Aganovic Creating Subclasses: RDFS Class Definition <rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:rdfs="http://www.w3.org/2000/01/rdf-schema#" > <rdfs:Class rdf:about="http://www.ePolitix.com/2001/03/rdf-schema#Politician"> <rdfs:subClassOf rdf:resource="http://www.Schemas.org/2001/01/rdf-schema#Person" /> <rdfs:Class rdf:about="http://www.ePolitix.com/2001/03/rdf-schema#Candidate"> <rdfs:subClassOf rdf:resource="http://www.ePolitix.com/2001/03/rdf-schema#Politician" />

26 e © 2002 Dario Aganovic rdfs:subClassOf This property specifies a subset/superset relation between classes. The rdfs:subClassOf property is transitive. If class A is a subclass of some broader class B, and B is a subclass of C, then A is also implicitly a subclass of C. Consequently, resources that are instances of class A will also be instances of C, since A is a sub-set of both B and C. Only instances of rdfs:Class can have the rdfs:subClassOf property and the property value is always of rdf:type rdfs:Class. A class may be a subclass of more than one class.

27 e © 2002 Dario Aganovic Creating Subclasses

28 e © 2002 Dario Aganovic Using Subclasses: RDFS Property Definition <rdf:Property rdf:ID="CandidateFor"> <rdf:Property rdf:ID="MemberOf">

29 e © 2002 Dario Aganovic Using Subclasses: RDF-statements <rdf:Description rdf:about="http://www.epolitix.com/austin-mitchell" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:s="http://www.Schemas.org/2001/01/rdf-schema#" xmlns:epx="http://www.ePolitix.com/2001/03/rdf-schema#" > Austin Mitchell 19 September, 1934

30 e © 2002 Dario Aganovic Using Subclasses <rdf:Property rdf:ID="CandidateFor"> <rdf:Property rdf:ID="MemberOf"> <rdf:Description rdf:about="http://www.epolitix.com/austin-mitchell" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:s="http://www.Schemas.org/2001/01/rdf-schema#" xmlns:epx="http://www.ePolitix.com/2001/03/rdf-schema#" > Austin Mitchell 19 September, 1934

31 e © 2002 Dario Aganovic Multiple Inheritance <rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:rdfs="http://www.w3.org/2000/01/rdf-schema#" > <rdfs:Class ‘ rdf:about="http://www.ePolitix.com/2001/03/rdf-schema#DefendingCandidate"> <rdfs:subClassOf rdf:resource="http://www.ePolitix.com/2001/03/rdf-schema#Candidate"/> <rdfs:subClassOf rdf:resource=http://www.ePolitix.com/2001/03/rdf-schema#ElectedRepresentative />

32 e © 2002 Dario Aganovic Multiple Instantiation <rdf:Description rdf:about="http://www.epolitix.com/austin-mitchell"> <rdf:type resource="http://www.ePolitix.com/2001/03/rdf-schema#Candidate" /> Austin Mitchell Labour Party 19 September, 1934 <rdf:type resource="http://www.Schemas.org/2001/01/rdf-schema#Husband" />

33 e © 2002 Dario Aganovic Multiple Instantiation

34 e © 2002 Dario Aganovic Subproperties <rdfs:subPropertyOf rdf:resource= "#MemberOfOrganisation" />

35 e © 2002 Dario Aganovic rdfs:subPropertyOf The property rdfs:subPropertyOf is an instance of rdf:Property that is used to specify that one property is a specialization of another. A property may be a specialization of zero, one or more properties. If some property P2 is a subPropertyOf another more general property P1, and if a resource A has a P2 property with a value B, this implies that the resource A also has a P1 property with value B.

36 e © 2002 Dario Aganovic Other RDFS Elements rdf:Resource rdfs:label rdfs:comment rdfs:seeAlso rdfs:isDefinedBy rdf:Statement rdf:subject rdf:predicate rdf:object rdfs:container rdf:bag rdf:seq rdf:alt All Elements are Defined in: http://www.w3.org/TR/rdf-schema/

37 e © 2002 Dario Aganovic RDFS Class Hierarchy

38 e © 2002 Dario Aganovic RDFS Constraints

39 e © 2002 Dario Aganovic RDFS vs UML

40 e © 2002 Dario Aganovic RDFS Extension: DAML+OIL An ontology language built on top of RDFS Basic ontological primitives and mechanisms from RDFS. DAML+OIL is a set of RDF-statements. DAML+OIL adds expressive power and well- defined semantics. The purpose is to eliminate RDFSs expressive inadequacy in order to support inferencing on RDF-models.

41 e © 2002 Dario Aganovic And now, more about expressiveness in general, and KIF in particular… Marcus!


Download ppt "E © 2002 Dario Aganovic Resource Description Framework Schema (RDFS) Dario Aganovic Industrial PhD-student NPI Production Kista, Ericsson AB and Production."

Similar presentations


Ads by Google