Copyright © 2003 W3C® (MIT, ERCIM,Keio), All Rights Reserved. W3C liability,trademark,document use and software licensing rules apply.
The Resource Description Framework (RDF) is a framework for representing information in the Web.
RDF Concepts and Abstract Syntax defines an abstract syntax on which RDF is based, and which serves to link its concrete syntax to its formal semantics. It also includes discussion of design goals, key concepts, datatyping, character normalization and handling of URI references.
This document is an unofficial editors' working copy, which is being used to make proposed changes available for discussion by the RDFcore working group. It has no official status, and has not been approved for publication by the working group. A version of this document that is available for public discussion of issues can be found in the RDFcore shadow documents area, http://www.w3.org/2001/sw/RDFCore/TR/. Versions of this document that may be available at any other location may be subject to change at any time, and should not be used as a basis for public discussion.
[[[Last-call document status commented out below]]]
[an error occurred while processing this directive]
The ideas on meaning and inference in RDF are underpinned by the formal concept of entailment, as discussed in the RDF semantics document [RDF-SEMANTICS]. In brief, an RDF expression A is said to entail another RDF expression B if every possible arrangement of things in the world that makes A true also makes B true. On this basis, if the truth of A is presumed or demonstrated then the truth of B can be inferred .
RDF uses URI references to identify resources and properties. Certain URI references are reserved for use by RDF, and should not be used in ways not supported by the RDF specifications. Specifically, URI references with the following leading substrings are reserved for definition by the RDF specifications:
Used with the RDF/XML serialization, these URI prefix strings correspond to XML namespace names [XML-NS] associated with the RDF core vocabulary terms.
Note: these namespace names are the same as those used in earlier RDF documents [RDF-MS] [RDF-SCHEMA].
[[[NOTE FOR REVIEWERS: Some terms in these namespaces have been deprecated, some have been added, and some RDF schema terms have had their meaning changed. We invite community feedback regarding the relative costs of adopting these changes under the old namespace URIs vs creating new URIs for this revision of RDF.]]]
Vocabulary terms in the rdf: namespace are listed in section 5.1 of the RDF syntax specification [RDF-SYNTAX]. Some of these terms are defined by the RDF specifications to denote specific concepts. Others have purely syntactic purpose (e.g. rdf:ID is part of the RDF/XML syntax) and should not be used in RDF to denote any kind of resource.
Vocabulary terms defined in the rdfs: namespace are defined in the RDF schema vocabulary specification [RDF-VOCABULARY].
Any information about URI references in the RDF and RDFS vocabularies (i.e. those that start with the RDF or RDFS namespace name) that is not supported by the RDF specifications (including possible future revisions and extensions) should not be taken to be correct in all uses of RDF.
RDF provides for XML content as a possible literal value. This typically originates from the use of rdf:parseType="Literal" in the RDF/XML Syntax [RDF-SYNTAX].
Such content is indicated in an RDF graph using a typed literal whose datatype is a special built-in datatype, rdf:XMLLiteral.
As part of the definition of this datatype, an ancillary definition is used.
The XML document corresponding to a pair ( str, lang ) is formed as follows:
Concatenate the five strings:
Encode the resulting Unicode string in UTF-8 to form the corresponding XML document.
No escaping is applied. The choice of rdf-wrapper is fixed but arbitrary.
The XML document corresponding to a string str is formed as the XML document corresponding to the pair (str, "").
Using this, the datatype rdf:XMLLiteral is defined as follows.
Reminder: All other datatypes have a lexical space being a set of strings, and a mapping which maps strings to values.
Note: Not all values of this datatype are compliant with XML 1.1 [XML 1.1]. If compliance with XML 1.1 is desired, then only those values that are fully normalized according to XML 1.1 should be used.
This section defines the RDF abstract syntax. The RDF abstract syntax is a set of triples, called the RDF graph.
This section also defines equality between RDF graphs. A definition of equality is needed to support the RDF Test Cases [RDF-TESTS] specification.
An RDF triple contains three components:
An RDF triple is conventionally written in the order subject, predicate, object.
The predicate is also known as the property of the triple.
An RDF graph is a set of RDF triples.
The nodes of an RDF graph is the set of subjects and objects of triples in the graph.
Two RDF graphs G and G' are equal if there is a bijection M between the nodes of the two graphs, such that:
With this definition, there are the same number of blank nodes in the two graphs, and M shows how each blank node in G can be replaced with a new blank node to give G'.
A URI reference within an RDF graph (an RDF URI reference) is a Unicode string [UNICODE] that:
The encoding consists of:
The disallowed octets that must be %-escaped include all those that do not correspond to US-ASCII characters, and the excluded characters listed in Section 2.4 of [URI], except for the number sign (#), percent sign (%), and the square bracket characters re-allowed in [RFC-2732].
Disallowed octets must be escaped with the URI escaping mechanism (that is, converted to %HH, where HH is the 2-digit hexadecimal numeral corresponding to the octet value).
Two RDF URI references are equal if and only if they compare as equal, character by character, as Unicode strings.
Editors' Note: This section is in the scope of the TAG issue IRIEverywhere-27. The editors are expecting a resolution of this issue during the last call period. This may result in updates to this section.
Note: RDF URI references are compatible with the anyURI datatype as defined by XML schema datatypes [XML-SCHEMA2], constrained to be an absolute rather than a relative URI reference, and constrained to be in Unicode Normal Form C [NFC] (for compatibility with [CHARMOD]).
Note: RDF URI references are compatible with International Resource Identifiers as defined by [XML Namespaces 1.1].
Note: The restriction to absolute URI references is found in this abstract syntax. When there is a well-defined base URI, concrete syntaxes, such as RDF/XML, may permit relative URIs as a shorthand for such absolute URI references.
A literal in an RDF graph contains three components called:
The lexical form is present in all RDF literals; the language identifier and the datatype URI may be absent from an RDF literal.
A plain literal is one in which the datatype URI is absent.
A typed literal is one in which the datatype URI is present.
Note: Literals in which the lexical form begins with a composing character (as defined by [CHARMOD]) are allowed however they may cause interoperability problems, particularly with XML version 1.1 [XML 1.1].
Note: When using the language identifier, care must be taken not to confuse language with locale. The language identifier only relates to human language text. Presentational issues, how to best represent typed data to the end-user, should be addressed in end-user applications.
Two literals are equal if and only if all of the following hold:
Note: RDF Literals are distinct and distinguishable from RDF URI references; e.g. http://example.org as an RDF Literal (untyped, without a language identifier) is not equal to http://example.org as an RDF URI reference.
The datatype URI refers to a datatype. For XML Schema built-in datatypes, URIs such as http://www.w3.org/2001/XMLSchema#int are used. The URI of the datatype rdf:XMLLiteral may be used. There may be other, implementation dependent, mechanisms by which URIs refer to datatypes.
The value associated with a typed literal is found by applying the datatype mapping associated with the datatype URI to the lexical form. Exceptionally, if the datatype is rdf:XMLLiteral and the literal has a language identifier, then the datatype mapping is applied to the pair form by the lexical form and the language identifier.
If the lexical form is not in the lexical space of the datatype associated with the datatype URI, then no literal value can be associated with the typed literal. Such a case, while in error, is not syntacticly ill-formed.
A typed literal for which the datatype does not map the lexical form to a value is not syntacticly ill-formed.
Note: In application contexts, comparing the values of typed literals (see section 6.5.2) is usually more helpful than comparing their syntactic forms (see section 6.5.1). Similarly, for comparing RDF Graphs, semantic notions of entailment (see [RDF-SEMANTICS]) are usually more helpful than syntactic equality (see section 6.3).
The blank nodes in an RDF graph are drawn from an infinite set. This set of blank nodes, the set of all RDF URI references and the set of all literals are pairwise disjoint.
Otherwise, this set is arbitrary.
RDF makes no reference to any internal structure of blank nodes.
RDF uses an RDF URI Reference, which may include a fragment identifier, as a context free identifier for a resource. RFC 2396 [URI] states that the meaning of a fragment identifier depends on the MIME content-type of a document, i.e. is context dependent.
These apparently conflicting views are reconciled by considering that a URI reference in an RDF graph is treated with respect to the MIME type application/rdf+xml [RDF-MIME-TYPE]. Given an RDF URI reference consisting of an absolute URI and a fragment identifier, the fragment identifer identifies the same thing that it does in an application/rdf+xml representation of the resource identified by the absolute URI component. Thus:
This provides a handling of URI references and their denotation that is consistent with the RDF model theory and usage, and also with conventional Web behavior. Note that nothing here requires that an RDF application be able to retrieve any representation of resources identified by the URIs in an RDF graph.
This document contains a significant contribution from Pat Hayes, Sergey Melnik and Patrick Stickler, under whose leadership was developed the framework described in the RDF family of specifications for representing datatyped values, such as integers and dates.
The editors acknowledge valuable contributions from the following: Frank Manola, Pat Hayes, Dan Brickley, Jos de Roo, Dave Beckett, Patrick Stickler, Peter F. Patel-Schneider, Jerome Euzenat, Massimo Marchiori, Tim Berners-Lee, Dave Reynolds and Dan Connolly.
Jeremy Carroll thanks Oreste Signore, his host at the W3C Office in Italy and Istituto di Scienza e Tecnologie dell'Informazione "Alessandro Faedo", part of the Consiglio Nazionale delle Ricerche, where Jeremy is a visiting researcher.
This document is a product of extended deliberations by the RDFcore Working Group, whose members have included: Art Barstow (W3C), Dave Beckett (ILRT), Dan Brickley (ILRT), Dan Connolly (W3C), Jeremy Carroll (Hewlett Packard), Ron Daniel (Interwoven Inc), Bill dehOra (InterX), Jos De Roo (AGFA), Jan Grant (ILRT), Graham Klyne (Nine by Nine), Frank Manola (MITRE Corporation), Brian McBride (Hewlett Packard), Eric Miller (W3C), Stephen Petschulat (IBM), Patrick Stickler (Nokia), Aaron Swartz (HWG), Mike Dean (BBN Technologies / Verizon), R. V. Guha (Alpiri Inc), Pat Hayes (IHMC), Sergey Melnik (Stanford University) and Martyn Horner (Profium Ltd).
This specification also draws upon an earlier RDF Model and Syntax document edited by Ora Lassilla and Ralph Swick, and RDF Schema edited by Dan Brickley and R. V. Guha. RDF and RDF Schema Working Group members who contributed to this earlier work are: Nick Arnett (Verity), Tim Berners-Lee (W3C), Tim Bray (Textuality), Dan Brickley (ILRT / University of Bristol), Walter Chang (Adobe), Sailesh Chutani (Oracle), Dan Connolly (W3C), Ron Daniel (DATAFUSION), Charles Frankston (Microsoft), Patrick Gannon (CommerceNet), R. V. Guha (Epinions, previously of Netscape Communications), Tom Hill (Apple Computer), Arthur van Hoff (Marimba), Renato Iannella (DSTC), Sandeep Jain (Oracle), Kevin Jones, (InterMind), Emiko Kezuka (Digital Vision Laboratories), Joe Lapp (webMethods Inc.), Ora Lassila (Nokia Research Center), Andrew Layman (Microsoft), Ralph LeVan (OCLC), John McCarthy (Lawrence Berkeley National Laboratory), Chris McConnell (Microsoft), Murray Maloney (Grif), Michael Mealling (Network Solutions), Norbert Mikula (DataChannel), Eric Miller (OCLC), Jim Miller (W3C, emeritus), Frank Olken (Lawrence Berkeley National Laboratory), Jean Paoli (Microsoft), Sri Raghavan (Digital/Compaq), Lisa Rein (webMethods Inc.), Paul Resnick (University of Michigan), Bill Roberts (KnowledgeCite), Tsuyoshi Sakata (Digital Vision Laboratories), Bob Schloss (IBM), Leon Shklar (Pencom Web Works), David Singer (IBM), Wei (William) Song (SISU), Neel Sundaresan (IBM), Ralph Swick (W3C), Naohiko Uramoto (IBM), Charles Wicksteed (Reuters Ltd.), Misha Wolf (Reuters Ltd.) and Lauren Wood (SoftQuad).
$Log: Overview.html,v $ Revision 1.21 2003/04/11 14:00:21 graham Update revision history. Edit version to be proposed to 2003-04-11 telecon. Revision 1.20 2003/04/11 13:25:46 graham Changed use of "property" to prefer "predicate". Edit version to be proposed to 2003-04-11 telecon. Revision 1.19 2003/04/11 12:55:48 graham Worked in revisions based on RDFcore list discussions. Edit versions to be proposed to 2003-04-11 telecon. Revision 1.18 2003/04/04 15:05:08 graham Revise wording of sections 3.1, 3.2 to fix some problems noted. Revision 1.17 2003/04/04 13:29:12 graham Clarified text (URI fregmants) in section 7. Revision 1.16 2003/04/03 18:18:38 graham Update revision summary. Revision 1.15 2003/04/03 18:17:29 graham Incorporated some of Pat's suggested text into section 3.1, further clarifying the role of URIs in RDF graphs. Revision 1.14 2003/04/03 17:57:47 graham Fix section 3.1 heading in ToC Revision 1.13 2003/04/03 17:53:50 graham Reworked text in 3.1, 3.2 to address williams-01, clarifying role of URIs and literals in an RDF graph. Revision 1.12 2003/04/03 16:55:49 graham Rework of revised section 4 text. Revision 1.11 2003/04/03 16:46:43 graham Revise/add text in section 4 to describe role of RDF(s) vocabularies. Revision 1.10 2003/04/02 20:48:38 graham Further revision to text in section 2.2.6. Revision 1.9 2003/04/02 20:42:29 graham Fix problem with revised text in section 2.2.6. Revision 1.8 2003/04/02 20:34:45 graham Removed two paragraphs added to section 3.5 (cf. rev 1.2) Revision 1.7 2003/04/01 18:40:32 graham More wording changes in section 2.2.6, and ToC fix Revision 1.6 2003/04/01 18:34:45 graham Fix up section 2.2.6 heading in ToC Revision 1.5 2003/04/01 18:26:29 graham Deleted section 2.2.7 from ToC Revision 1.4 2003/04/01 18:24:26 graham Deleted section 2.2.7 and revised wording in 2.2.6 Revision 1.3 2003/04/01 17:32:38 graham Add extra paragraph at start of section 3.5 to capture sense of "Shelley's Words of Wisdom" noted by Pat Hayes. Revision 1.2 2003/04/01 16:30:24 graham Remove section on social meaning Renumber section about namespace URIs and vocabularies Replace part of section 3.5 with a reference to the primer, and add two short paragraphs clarifying non-support for propositional attitudes and distinction between asserted and non-asserted statements. ***