1 / 32

Resource Description Framework ( RDF )

Resource Description Framework ( RDF ). Xinxia An. Resource Description Framework ( RDF ). Introduction RDF Syntax Dublin Core. Introduction. What is RDF ?. RDF: Resource Description Framework Is a language designed to describe resources which has its own formal grammar

Download Presentation

Resource Description Framework ( RDF )

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Resource Description Framework( RDF ) Xinxia An

  2. Resource Description Framework( RDF ) • Introduction • RDF Syntax • Dublin Core

  3. Introduction What is RDF ? • RDF: Resource Description Framework • Is a language designed to describe resources which has its own formal grammar • Is a framework: • tells us how to organize metadata • does not say what metadata we should have • Is an XML application • Is a W3C recommendation

  4. Introduction What is Dublin Core ? • Is a metadata standard • Tells us what aspects of a resource we should describe and what names to use

  5. Introduction Why need RDF and Dublin Core ? • Provides a foundation for metadata processing • Supports metadata interchanging • better precision in resource discovery

  6. RDF Syntax (Root Element) • A RDF document must start with <?xml?> declaration • It also must have a root element with a fixed name which is <RDF> • It must use the RDF namespace, which is http://www.w3.org/1999/02/22-rdf-syntax-ns# • The prefix for this namespace is usually rdf

  7. RDF Syntax Root Element <?xml version=“1.0”?> <rdf:RDF xmlns:rdf=“http://www.w3.org/ 1999/02/22-rdf-syntax-ns#”> . . ( Description Elements ) . . </rdf:RDF>

  8. RDF Syntax Description Element • Each resource you want to describe in RDF document gets its own <rdf:Description> element • We use about attribute to specify the resource to be described

  9. RDF Syntax Description Element <?xml version=“1.0”?> <rdf:RDF xmlns:rdf=“http://www.w3.org/ 1999/02/22-rdf-syntax-ns#”> <rdf:Description about=“http://www.nmsu.edu/jobs.html”> …… ( Property Elements ) …… </rdf:Description> </rdf:RDF>

  10. RDF Syntax Description Element • attributes of <rdf:Description> element • about • aboutEach • aboutEachPrefix • bagID • ID • type

  11. RDF Syntax Property Element • Each property element describes one property or one aspect of the resource • It is up to you to decide how to name the properties • But it is strongly suggested to use agreed-upon sets of terms • The most widely used standard is Dublin Core whose namespace is usually given a prefix dc http://www.purl.org/DC/

  12. RDF Syntax Property Element • Some forms of property elements 1. <PropertyName> Value </PropertyName> Value = string | Description | Container e.g.1<dc:Creator> John Smith </dc:Creator> e.g.2 <dc:Creator> <rdf:Description about=“Jsmith.html”> <dc:Language> en </dc:Language> <dc:Date> Feb.18,2002 </dc:Date> </rdf:Description> </dc:Creator>

  13. RDF Syntax Property Element • Some forms of property elements 2. <PropertyName parseType=“Literal”> any well-formed XML (not interpreted by RDF-aware browers) </PropertyName> e.g. <dc:Creator parseType=“Literal”> <js:Name> John Smith </js:Name> <js:Birth> Jan 01,1900</js:Birth> </dc:Creator>

  14. RDF Syntax Property Element • Some forms of property elements 3. <PropertyName parseType=“Resource”> property elements </PropertyName> e.g. <dc:Creator parseType=“Resource”> <js:Name> John Smith</js:Name> <js:Birth> Jan 01,1900</js:Birth> </dc:Creator>

  15. RDF Syntax Property Element • Some forms of property elements 4. <PropertyName rdf:resource=URI /> URI = Uniform Resource Identifier e.g. <rdf:Description about=“http://nmsu.edu/jobs.html”> <dc:Creator rdf:Resource=“smith.html”/> </rdf:Description>

  16. RDF Syntax RDF Document - Example <?xml version=“1.0”?> <rdf:RDF xmlns:rdf=“http://www.w3.org/ 1999/02/22-rdf-syntax-ns#” xmlns:dc=“http://purl.org/DC/”> <rdf:Description about=“http://www.nmsu.edu/jobs.html”> <dc:Creator> John Smith </dc:Creator> <dc:Date> Feb.18,2002 </dc:Date> </rdf:Description> </rdf:RDF>

  17. RDF Syntax Abbreviated RDF Syntax • Up to now, we place all the property elements inside the description elements • W3C also provides another way to organize the property elements, which is called abbreviated RDF syntax • Abbreviated RDF syntax allows us convert property elements into attributes of the <rdf:Description> element

  18. RDF Syntax Abbreviated RDF Syntax <rdf:/Description about=“jobs.html”> <dc:Creator> John Smith </dc:Creator> <dc:Date> Feb 18, 2002 </dc:Date> <rdf:/Description> is converted into <rdf:/Description about=“jobs.html” dc:Creator=“ John Smith “ dc:Date=“ Feb 18, 2002 ”> <rdf:/Description>

  19. RDF Syntax Abbreviated RDF Syntax • Abbreviate RDF syntax results in empty description elements • The biggest advantage of this is that browsers that do not understand RDF, will not mishandle the content of the property elements, if we embed some RDF descriptions in an HTML document

  20. RDF Syntax RDF Containers • A RDF container is a group of properties of a resource • With RDF containers, we could describe a resource more conveniently and efficiently

  21. RDF Syntax RDF Containers • Without RDF container, we have to repeat the property tags like <rdf:Description about=“planets.html”> <dc:Subject> Mercury </dc:Subject> <dc:Subject> Venus </dc:Subject> <dc:Subject> Earth </dc:Subject> <dc:Subject> Mars </dc:Subject> </rdf:Description> if Mercury, Venus, Earth and Mars are all subjects of the resource planets.html

  22. RDF Syntax RDF Containers There are three types of RDF containers • <rdf:Bag> a group of multiple,unordered properties • <rdf:Seq> a group of multiple,ordered properties • <rdf:Alt> a list of properties giving alternative choices, only one of all these choices is actually chosen

  23. RDF Syntax RDF Containers - Bag <rdf:Description about=“planets.html”> <dc:Creator> John Smith </dc:Creator> <dc:Subject> <rdf:Bag> <rdf:li> Mercury </rdf:li> <rdf:li> Venus </rdf:li> <rdf:li> Earth </rdf:li> <rdf:li> Mars </rdf:li> </rdf:Bag> </dc:Subject> </rdf:Description>

  24. RDF Syntax RDF Containers - Seq <rdf:Description about=“planets.html”> <dc:Creator> John Smith </dc:Creator> <dc:Subject> <rdf:Seq> <rdf:li> Mercury </rdf:li> <rdf:li> Venus </rdf:li> <rdf:li> Earth </rdf:li> <rdf:li> Mars </rdf:li> </rdf:Seq> </dc:Subject> </rdf:Description>

  25. Dublin Core Why Dublin Core ? • RDF is just a framework under which we organize our metadata about resources • It does not say anything about what properties or aspects of a resource we should describe • We need some standard property names or agreed-upon terms to describe resources, otherwise, the metadata is not easy to share or exchange • Dublin Core comes for this reason

  26. Dublin Core What is Dublin Core ? • Is a metadata standard • Is a set of named properties • Is a description model • Tells us what aspects of a resource should be described • Is the most popular and supported by most search engines

  27. Dublin Core Dublin Core Properties The Dublin Core standard has 15 properties of 3 categories • Content • Intellectual Property • Instantiation

  28. Dublin Core Content Properties • Coverage • Description • Type • Relation • Source • Subject • Title

  29. Dublin Core Type Property • text • image • sound • software • . . .

  30. Dublin Core Intellectual Properties • Contributor • Creator • Publisher • Rights

  31. Dublin Core Instantiation Properties • Date • Format • Identifier • Language

  32. Summary • RDF is a language about how to write RDF documents • RDF does not specify what properties or aspects of a resource we should describe • Dublin Core provides a standard way to describe resources by giving a set of agreed-upon terms

More Related