RDF RESOURCE DESCRIPTION FRAMEWORK Scott Ainsworth & Louis Nguyen Old Dominion University, CS 791: Web Syndication Formats, February 20,
Presentation Overview What/Why/History WhatWhyHistory RDF By Example RDF By Example RDF Schema RDF Schema SPARQL SPARQL RDF and Dublin Core RDF and Dublin Core RDF In the Field RDF In the Field Summary Summary Questions Questions 2
What is RDF? RDF is a standard that enables the encoding, exchange, and reuse of structured metadata Provides framework for describing resources (webpage, documents, etc), and how these resources relate to each other Allows to state anything about anything Designed for computer to read and understand RDF is created as a standard on top of XML for encoding metadata
What is RDF? RDF is W3C recommendation and part of the W3C’s Semantic Web activity Semantic Web is about interpretation and manipulation of data to provide content that is meaningful to humans Semantic Web = Knowledge RDF = Encoding, exchange, and reuse of that knowledge
Why RDF? Provides common framework (vocabularies) for describing and publishing metadata about internet resources Improves discovery and access to information Imposes metadata standards which enables decentralized applications to discovery/ exchange information among themselves about Web resources (URIs) on the Internet Promotes meshup applications using shared data sources across decentralized system
RDF History Begin in 1995 with development of Meta Content Framework and the Platform for Internet Content Selection (PICS) projects MCF: Ramanathan Guha of Apple Computers, format specification for structuring metadata information about web sites and other data PICS: provides mechanism for creating rating systems for web pages (ie. does it contain nudity, violence, peer-reviewed articles, etc)
RDF History PICS was motivated by need to restrict internet content however it has limitation describing information with Internet resources RDF project was formed as a result of a collaborative design effort of metadata communities and technologies coming together to provide architecture for supporting metadata on the web. No one person or organization invented RDF. Dublin Core Initiative is a major contributor that influence the design and direction of RDF
RDF: Examples of Use Describing properties for shopping items, such as price and availability Describing time schedules for web events Describing information about web pages, such as content, author, created and modified date Describing content for search engines Describing electronic libraries
RDF By Example Syntax & Rules Quick Example RDF Graph Main Elements Containers Collections Prerequisites XML XML Namespaces 9
Syntax & Rules RDF represents knowledge as assertions in subject—predicate—object form. “Dr. Nelson is the instructor of CS791” Subject: Dr. Nelson Predicate: is the instructor of Object: CS791 Commonly referred to as triples. 10 RDF by Example
Syntax & Rules RDF terminology Resource is anything that can have a URI Property is a resource that has a name Property Value is the value of a property, which can also be a resource “Dr. Nelson is the instructor of CS791” Resource: Dr. Nelson(Subject) Property: instructor(Predicate) Property Value: CS791(Object) 11 RDF by Example
Syntax & Rules Basic Syntax Property Value “Dr. Nelson is the instructor of CS791” CS RDF by Example
A Simple Example NumberDaysTimeSiteInstructor CS 555M T W R14:30—16:10DRGS 1117Price CS 557T R16:00—19:20ECSB 2120Gupta Subject: Properties: 13 Course CourseNo, Days, Time, Site, Instructor RDF by Example
A Simple Example NumberDaysTimeSiteInstructor CS 555M T W R14:30—16:10DRGS 1117Price CS 557T R16:00—19:20ECSB 2120Gupta Example Assertions: Triples: 14 “CS 555 will be taught by Price” “CS 557 will meet from 16:00—19:20” CS 555teacherPrice CS 557time16:00—19:20 RDF by Example
A Simple Example NumberDaysTimeSiteInstructor CS 555M T W R14:30—16:10DRGS 1117Price CS 557T R16:00—19:20ECSB 2120Gupta M T W R 14:30—16:10 Price 15 RDF by Example
RDF Graphs NumberDaysTimeSiteInstructor CS 555M T W R14:30—16:10DRGS 1117Price CS 557T R16:00—19:20ECSB 2120Gupta 16 InstructorNameOffice Hill PriceHughes GuptaE&CS /course/CS555 /~price MTWR 14:30—16:10 /site/drgs1117 G. Hill Price /site/hughes1108 RDF by Example
Main Elements 17 M T W R 14:30—16:10 Price RDF by Example
Main Elements 18 M T W R 14:30—16:10 Price RDF by Example
Main Elements Properties and Property Values 19 M T W R 14:30—16:10 Price RDF by Example
Main Elements Properties as Resources 20 M T W R 14:30—16:10 Price RDF by Example
Containers 21 : Unordered list of elements : Ordered list of element : Select only 1 of N elements M T W R RDF by Example
Collections rdf:parseType=“Collection” XML attribute: Used to define a group containing only specified members 22 M T W R RDF by Example
RDF Schema Allows definition of application-specific Classes (resources) Properties Types. 23
Classes A class is a resource with an rdf:type property whose value is rdfs:Class. oducs:course rdf:type rdfs:Class A subclass is a resource with an rdfs:subClassOf property whose value is a class. oducs:gradcourse rdf:subClassOf oducs:course 24 RDF Schema
Classes course:Courserdf:typerdfs:Class course:GradCourserdf:subClassOfcourse:Course course:Instructorrdf:typerdfs:Class ]> <rdf:RDFxmlns:rdf=" xmlns:rdfs=" xml:base=" 25 RDF Schema
Properties course:daysrdf:typerdfs:Property course:timerdf:typerdfs:Property <rdfs:range rdf:resource=“#Instructor” 26 RDF Schema
A Simple Example w/Schema NumberDaysTimeSiteInstructor CS 555M T W R14:30—16:10DRGS 1117Price CS 557T R16:00—19:20ECSB 2120Gupta M T W R 14:30—16: RDF Schema
SPARQL An SQL-like query language for RDF Allows Simple Selection Unions Joins Sorting Queries the triples 28
Triples for Courses CS555daysM T W R CS555time14:30-16:10 CS555siteDRGS 1117 CS555instructorhttp:// CS557daysT R CS557time16:00-19:20 CS557siteECBS 2120 CS557instructorhttp:// 29 NumberDaysTimeSiteInstructor CS 555M T W R14:30—16:10DRGS 1117Price CS 557T R16:00—19:20ECSB 2120Gupta
Triples for Instructors Hill Price Gupta InstructorNameOffice Hill PriceHughes GuptaE&CS 3311
Simple SPARQL Query CS555daysM T W R CS555time14:30-16:10 CS555siteDRGS 1117 CS555instructorhttp://.../~price CS557daysT R CS557time16:00-19:20 CS557siteECBS 2120 CS557instructorhttp://.../~ajay PREFIX course: SELECT ?number FROM WHERE { ?course course:instructor ?instructor. } 31 CS555 CS557
Simple SPARQL Query #2 CS555daysM T W R CS555time14:30-16:10 CS555siteDRGS 1117 CS555instructor CS557daysT R CS557time16:00-19:20 CS557siteECBS 2120 CS557instructor PREFIX course: SELECT ?number ?site FROM WHERE { ?number course:instructor ?instructor. ?site course:site ?site. } 32 CS555DRGS 1117 CS557ECBS 2120
SPARQL Query with “Join” CS555daysM T W R CS555time14:30-16:10 CS555siteDRGS 1117 CS555instructor CS557daysT R CS557time16:00-19:20 CS557siteECBS 2120 CS557instructor PREFIX course: PREFIX instr: SELECT ?number ?name ?office FROM FROM NAMED WHERE { GRAPH { ?instructor instr:office ?office. ?instructor instr:office ?name. }. ?number course:instructor ?instructor. } 33 CS555http://.../~priceHughes 1108 CS557http://.../~ajayE&CS Hill Price Gupta
RDF Applications Some actual deployed RDF applications that supports various real world requirements to represent and manipulate information DC: Dublin Core Metadata Initiative PRISM: Publishing Requirements for Industry Standard Metadata Xpackage: XML Package specification RSS 1.0: RDF Site Summary (Really Simple Syndication) 34
RDF Application: Dublin Core RDF is metadata. Metadata is data about data. RDF is used to describe information resources. DC is a set of predefined properties for describing documents (recording metadata) Goal: provide a minimal set of properties that facilitate the description and automated indexing of documents 35
Predefined Dublin Core Vocabularies 36 PropertiesDefinitions TitleA name given to the resource CreatorAn entity primarily responsible for making the content of the resource. SubjectThe topic of the content of the resource DescriptionAn account of the content of the resource PublisherAn entity responsible for making the resource available ContributorAn entity responsible for making contributions to the content of the resource DataA date associated with an event in the life cycle of the resource TypeThe nature or genre of the content of the resource FormatThe physical or digital manifestation of the resource IdentifierAn unambiguous reference to the resource within a given context SourceA reference to a resource from which the present resource is derived LanguageA language of the intellectual content of the resource RelationA reference to a related resource CoverageThe extent or scope of the content of the resource RightsInformation about rights held in and over the resource
Examples Dublin Core Properties in RDF Document 37
Examples Dublin Core Properties in RDF Document 38
Examples Dublin Core Properties in RDF Document 39
RDF Application: RSS 1.0 RSS is Web content syndication format Provides timely dissemination of variety of information that changes day to day for large-scale distribution and reuse: news, schedule, search results, “what’s new”, etc Provides a feed that allows content to be access and merged into application or sites RSS feed can be requested by any app via HTTP Desktop Readers: subscribe to feeds and search RSS 1.0: most widely deployed RDF application on Web Note: RSS 0.9 and 1.0 uses RDF while 0.91,0.92,0.93, 0.94 and 2.0 does not. 40
RSS Example: W3C 41 W3C RSS Web feed
RSS Example: W3C 42
RSS Example: W3C Syndication 43 MeerkatMeerkat.com NewsIsFreeNewsIsFree.com
Summary This presentation is an introduction to RDF RDF in detail at: Additional Resources: RDF Validation Service 44
Questions and Discussion What are some of the benefits of RDF? What is a triple? Match Subject Property PredicateResource Object Property Value Describe important capabilities of RDF Schema. 45
References “Introducing SPARQL: Querying the Semantic Web.” XML.com. 6 November February 2008, Miller, Eric. “An Introduction to Resource Description Framework”. May “RDF: about.” RDFabout. January “RDF Primer.” W3C Consortium. 10 February February “RDF Schema.” W3C Consortium. 10 February February “RDF Tutorial.” W3Schools. 14 February “Resource Description Framework.” Wiki. 10 Feb, “SPARQL Query Language for RDF.” W3C Consortium. 15 January February 2008, 46