Slide 1Slide 2Slide 3Slide 4Slide 5Slide 6Slide 7Slide 8Slide 9Slide 10Slide 11Slide 12Slide 13Slide 14Slide 15Slide 16Slide 17Slide 18Slide 19Slide 20Slide 21Slide 22Slide 23Slide 24Slide 25Slide 26Slide 27Slide 28Slide 29Slide 30Slide 31Slide 32Slide 33Slide 34Slide 35Slide 36Slide 37Slide 38Slide 39Slide 40Slide 41Slide 42Slide 43Slide 44Slide 45Slide 46Slide 47Slide 48Slide 49Slide 50Slide 51Slide 52Slide 53Slide 54Slide 55Slide 56Slide 57Slide 58Slide 59Slide 60Slide 61Slide 62Slide 63RDF and RDF Schema - Part 1Grigoris AntoniouFrank van HarmelenEdited by Jeff PartykaLecture Outline1. Basic Ideas of RDF 2. RDF Serializations3. Basic Concepts of RDF Schema4. Τhe Language of RDF Schema5. Direct Semantics based on Inference RulesDrawbacks of XMLXML is a universal metalanguage for defining markupIt provides a uniform framework for interchange of data and metadata between applicationsHowever, XML does not provide any means of talking about the semantics (meaning) of datae.g., there is no intended meaning associated with the nesting of tags—it is up to each application to interpret the nestingNesting of Tags in XML David Billington is a lecturer of Discrete Maths<course name="Discrete Maths"><lecturer>David Billington</lecturer></course>...versus...<lecturer name="David Billington"><teaches>Discrete Maths</teaches></lecturer>Opposite nesting, same information!REVIEW: Basic Ideas of RDFBasic building block: object-attribute-value triple–It is called a statement or a triple–Sentence about Billington is such a statement RDF has been given a syntax in XML–RDF/XML is the official syntax for representing RDF–Other syntactic representations of RDF possibleREVIEW: Basic Ideas of RDF (2)The fundamental concepts of RDF are:–Resources–Properties–StatementsREVIEW: ResourcesWe can think of a resource as an object, a “thing” we want to talk about–e.g., authors, books, publishers, places, people, hotelsEvery resource has a URI, a Universal Resource Identifier A URI can be –a URL (Web address) or –some other kind of unique identifier –IRI: URI that supports UnicodeREVIEW: PropertiesProperties are a special kind of resourcesThey describe relations between resources–e.g., “written by”, “age”, “title”, etc. Properties are also identified by URIs Advantages of using URIs:–Α global, worldwide, unique naming scheme–Reduces the homonym problem of distributed data representationREVIEW: StatementsStatements assert the properties of resourcesA statement is an object-attribute-value triple–It consists of a resource, a property, and a valueValues can be resources or literals –Literals are atomic values (strings)REVIEW: Examples of RDF Triples( http://www.cit.gu.edu.au#DBillington,http://www.w3.org/1999/02/22-rdf-syntax-ns#type,http://www.cit.gu.edu.au #lecturer )( http://www.cit.gu.edu.au#DBillington,http://www.example.com/predicates#hasName,“David Billington” )REVIEW: Three Views of a StatementA tripleA part of a graphA piece of XML codeThus an RDF document can be viewed as:A set of triplesA graph An XML documentREVIEW: Statements as Triples( http://www.cit.gu.edu.au/~db,http://www.mydomain.org#site-owner,http://www.cit.gu.edu.au#DBillington )The triple (x,P,y) can be considered as a logical formula P(x,y)–Binary predicate P relates object x to object y –RDF offers only binary predicates (properties)–“The uncle problem”REVIEW: XML VocabulariesA directed graph with labeled nodes and arcs–from the resource (the subject of the statement) –to the value (the object of the statement)Known in AI as a semantic netThe value of a statement may be a resource–Ιt may be linked to other resourceshttp://www.cit.gu.edu.au #DBillingtonREVIEW: A Set of Triples as a Semantic Nethttp://www.cit.gu.edu.au #DBillington3975 507Sharing and Interchange with XMLWith XML, it was possible to represent the same semantics in multiple ways. It was not expressive enough on its own.A schema was necessary to structure the semantics embedded in the documentThe order of the tags is tied to the semantics of the documentHowever, many schema might be possible for a given XML documentXML documents have a tree structureSharing and Interchange with RDFWith RDF, a separate schema definition to describe structure is not necessaryThis is because RDF triples can be described as a graphAny order of triple specification will result in the same graphThis makes it possible to combine arbitrary RDF graphs without caring about the order of combinationStatements in XML SyntaxGraphs are a powerful tool for human understanding butThe Semantic Web vision requires machine-accessible and machine-processable representationsRDF can also be expressed as an XML document in RDF/XML formData TypesData types are used in programming languages to allow interpretationIn RDF, typed literals are used, if necessary( http://www.cit.gu.edu.au#DBillington,http://www.mydomain.org/age,“27”^^http://www.w3.org/2001/XMLSchema#integer )Data Types (2)^^ - notation indicates the type of a literal In practice, the most widely used data typing scheme will be XML Schema –But the use of any externally defined data typing scheme is allowed in RDF documentsXML Schema predefines a large range of data types–e.g., booleans, integers, floating-point numbers, times, dates, etc.Binary PredicatesRDF uses only binary properties–This is a restriction because, to the contrary, we often use predicates with more than 2 arguments(the “uncle problem” – to be discussed later)–But binary predicates can simulate theseExample: referee(X, Y, Z) –X is the referee in a chess game between players Y and ZBinary Predicates (2)We introduce:–a new auxiliary resource chessGame–the binary predicates referee, player1, and player2We can represent referee(X, Y, Z) as:Lecture Outline1. Basic Ideas of RDF 2. RDF Serializations3. Basic Concepts of RDF Schema4. Τhe Language of RDF Schema5. Direct Semantics based on Inference RulesWays to Serialize RDF as textRDF/XMLTurtle – Terse RDF Triple Language (subset of N3)N-TriplesJSON-LD – New(er)!●See: “JSON-LD and Why I Hate the Semantic Web” 2014RDF/XML SerializationRDF/XML is the W3C recommended serialization for RDF as of February 2004This MUST be supported by all well-behaved Semantic Web ApplicationsThere
View Full Document