By Shelley Powers
Book Price: $39.95 USD
£28.50 GBP
PDF Price: $31.99
Cover | Table of Contents | Colophon
http://www.w3.org/RDF/. You can
access the
core working
group's efforts at http://www.w3.org/2001/sw/RDFCore/. In
addition, there's an
RDF Interest Group forum that you can
monitor or join at
http://www.w3.org/RDF/Interest/.
The Resource Description Framework (RDF) is a language designed to support the Semantic Web, in much the same way that HTML is the language that helped initiate the original Web. RDF is a framework for supporting resource description, or metadata (data about data), for the Web. RDF provides common structures that can be used for interoperable XML data exchange.
The Resource Description Framework (RDF) is a language designed to support the Semantic Web, in much the same way that HTML is the language that helped initiate the original Web. RDF is a framework for supporting resource description, or metadata (data about data), for the Web. RDF provides common structures that can be used for interoperable XML data exchange.
http://www.semaview.com/c/RDFvsXML.html).
Among those listed was one about the tree-structured nature of XML,
as compared to RDF's much flatter triple-based
pattern. XML is hierarchical, which means that all related elements
must be nested within the elements they're related
to. RDF does not require this nested structure.
<?xml version="1.0"?> <resource> <uri>http://burningbird.net/articles/monsters3.htm</uri> <history> <movement> <link>http://www.yasd.com/dynaearth/monsters3.htm</link> <reason>New Article</reason> </movement> </history> </resource>
dictionary.com, "An explicit
formal specification of how to represent the objects, concepts and
other entities that are assumed to exist in some area of interest and
the relationships that hold among them."
The Semantic Web will build on XML's ability to define customized tagging schemes and RDF's flexible approach to representing data. The next element required for the Semantic Web is a Web ontology language which can formally describe the semantics of classes and properties used in web documents. In order for machines to perform useful reasoning tasks on these documents, the language must go beyond the basic semantics of RDF Schema.
http://www.w3.org/TR/rdf-concepts/. The RDF
Semantics document can be found at http://www.w3.org/TR/rdf-mt/.
http://burningbird.net/articles/monsters1.htm.
meta tags
or directly from the page contents themselves.
rdf:nodeIDs, discussed in Chapter 3, provided some of the necessary syntactic
elements that allow RDF/XML to record all RDF graphs. However,
RDF/XML still can't encode graphs whose properties
(predicates) cannot be recorded as namespace-qualified XML names, or
QNames. For more on QNames, see XML
in a Nutshell, Second Edition
(O'Reilly).
http:// to
access a resource as a web page and ftp:// to
access another resource using FTP. However, one thing each approach
shares is the need to access a specific object given a unique name or
identifier. URIs provide a common syntax for naming a resource
regardless of the protocol used to access the resource. Best of all,
the syntax can be extended to meet new needs and include new
protocols.
#). In the following
example,
http://burningbird.net/articles/monsters3.htm is
the URI and introduction is the fragment:
http://burningbird.net/articles/monsters3.htm#introduction
http://
or ftp://, though you can if you like. Instead,
you could use something as different as a UUID
(Universally Unique Identifier) referencing a COM or other technology
component that exists locally on the same machine or within a network
of machines. In fact, a fundamental difference between a URL and a
URI is that a URL is a location of an object, while a URI can
function as a name or a location. URIs also differ from
URNs (Uniform Resource Name) because URIs
can refer to a location as well as a name, while URNs refer to
globally unique names.
subject
predicate
object ..). An actual example of N3 would be:
<http://weblog.burningbird.net/fires/000805.htm>
<http://purl.org/dc/elements/1.1/creator> Shelley .<http://burningbird.net/articles/monsters3.htm> <http://burningbird.net/postcon/ elements/1.0/title> "Architeuthis Dux"
<http://burningbird.net/articles/monsters3.htm> <http://burningbird.net/postcon/elements/1.0/author> "Shelley Powers"
http://www.w3.org/TR/REC-rdf-syntax/. The
updated RDF/XML Syntax Specification (revised) can be found at
http://www.w3.org/TR/rdf-syntax-grammar/.
http://www.w3.org/RDF/Validator/.
xml.com on what it means for an
XML document to be well formed and/or valid; it explains the two
concepts in more detail. See it at http://www.xml.com/pub/a/98/10/guide3.html.
The article on giant squids, titled "Architeuthis Dux," at http://burningbird.net/articles/monsters3.htm, written by Shelley Powers, explores the giant's squid's mythological representation as the legendary Kraken as well as describing current efforts to capture images of a live specimen. In addition, the article also provides descriptions of a giant squid's physical characteristics. It is part of a four-part series, described at http://burningbird.net/articles/monsters.htm and entitled "A Tale of Two Monsters."
bio attributes
are grouped within an enclosing PostCon bio resource. Since the
bio doesn't have its own URI, a
blank node represents it within the model.
<?xml version="1.0"?>
<rdf:RDF
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:pstcn="http://burningbird.net/postcon/elements/1.0/"
xml:base="http://burningbird.net/articles/">
<rdf:Description rdf:about="monsters1.htm">
<pstcn:bio>
<rdf:Description>
<pstcn:title>Tale of Two Monsters: Legends</pstcn:title>
<pstcn:description>
Part 1 of four-part series on cryptozoology, legends,
Nessie the Loch Ness Monster and the giant squid.
</pstcn:description>
<pstcn:created>1999-08-01T00:00:00-06:00</pstcn:created>
<pstcn:creator>Shelley Powers</pstcn:creator>
</rdf:Description>
</pstcn:bio>
</rdf:Description>
</rdf:RDF>rdf:about
attribute.
Instead of using the full URI, the example could be a relative URI
reference, which resolves to the base document
concatenated with the relative URI reference. In the following, the
relative URI reference "#somevalue.htm":
<rdf:Description rdf:about="#somevalue">
http://burningbird.net/articles/somedoc.htm#somevalue
if the containing document is
http://burningbird.net/articles/somedoc.htm. To
resolve correctly, the relative URI reference must be given with the
format of
pound sign
(#) followed by the reference
("#somevalue").
http://burningbird.net/somedoc.htm, the URI base
is considered to be this document, and changes of the document name
or URL change the URI for the resource.
xml:base, you can specify a base document
that's used to generate full URIs when given
relative URI references, regardless of the URL of the owning
document. This means that your URIs can be consistent regardless of
document renaming and movement.
xml:base attribute
is added to the RDF/XML document, usually in the same element tag
where you list your namespaces (though it can be placed anywhere).
Redefining Example 3-6 with
xml:base and using a relative URI reference would
give you the RDF/XML shown in Example 3-10.
<pstcn:lastEdited>18</pstcn:lastEdited>
18 means. Is it 18 days? Months?
Hours? Did a person identified by the number 18 edit it?
<pstcn:lastEdited>18 days</pstcn:lastEdit>
<pstcn:lastEdited>18</pstcn:lastEdited> <pstcn:lastEditedUnit>day</pstcn:lastEditedUnit>
rdf:value enters the
picture. When dealing with structured data, the
rdf:value predicate includes the actual value of
the structure—it provides a signal to the processor that the
data itself is included in this field, and all other members of the
structure are qualifiers and additional information about the
structure.
<pstcn:lastEdited rdf:parseType="Resource">
<rdf:value>18</rdf:value>
<pstcn:lastEditedUnit>day</pstcn:lastEditedUnit>
</pstcn:lastEdited>rdf:value. You
could use your own predicate, but rdf:value is
global in scope—it crosses all RDF vocabularies—making
its use much more attractive if you're concerned
about combining your vocabulary data with other data.
"Web Resource" to refer
to all of the resources, or could be explicitly set to
"article" for articles. All these would be
correct, depending on how generically you want to define the resource
and the other properties associated with the resource. To explicitly
define the resource type, you would use the RDF
rdf:type property.
rdf:type property is associated at the
same level of granularity as the other properties. As the resources
defined using RDF in this chapter all have properties associated more
specifically with an article than a web resource, the RDF type
property would be "article" or something similar.
rdf:type property is a URI
identifying an rdfs:Class-typed resource
(rdfs:Class is described in detail in Chapter 5). To demonstrate how to attach an explicit
type to a resource, Example 3-13 shows the resource
defined in the RDF/XML for Example 3-1, but this
time explicitly defining an RDF Schema element for the resource.
<?xml version="1.0"?>
<rdf:RDF
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:pstcn="http://burningbird.net/postcon/elements/1.0/">
<rdf:Description rdf:about="http://burningbird.net/articles/monsters3.htm">
<pstcn:Author>Shelley Powers</pstcn:Author>
<pstcn:Title>Architeuthis Dux</pstcn:Title>
<rdf:type rdf:resource="http://burningbird.net/postcon/elements/1.0/Article" /><?xml version="1.0"?> <rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:pstcn="http://burningbird.net/postcon/elements/1.0/"> <rdf:Description rdf:about="http://dynamicearth.com/articles/monsters3.htm"> <pstcn:author>Shelley Powers</pstcn:author> </rdf:Description> <rdf:Description rdf:about="http://burningbird.net/articles/monsters3.htm"> <pstcn:title>Architeuthis Dux</pstcn:title> </rdf:Description> </rdf:RDF>
xml:lang
attribute to specify a language for each RDF/XML element. In the
examples in this English-language book, the value would be
"en", and would be included within an element as
follows:
<pstcn:reason xml:lang="en">First in the series</pstcn:reason>
xml:lang at
http://www.w3.org/TR/REC-xml#sec-lang-tag.
rdf:parseType.
We've seen rdf:parseType of
"Resource", but you can also use
rdf:parseType of "Literal":
<pstcn:reason xml:lang="en" rdf:parseType="Literal"><h1>Reason</h1></pstcn:reason>
rdf:parseType="Literal", you are telling the
RDF/XML parser to treat the contents of a predicate as a literal
value rather than parse it out for new RDF/XML elements. This allows
you to embed XML into an element that is not parsed.
rdf:parseType="Literal" as a way of including
unparsed XML within a document, to bypass having to formalize the XML
into an RDF/XML valid syntax. This attribute was never intended to
bypass best practices. If the data contained in the attribute is
recurring, best practice would be to formalize the XML into RDF/XML
and incorporate it into the vocabulary or create a new vocabulary.
ex:index.html exterms:creation-date "1999-08-16"^^xsd:date .
1999-08-16), data type URI (^^
in this example), and XML Schema data type
(xsd:date).
<rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:dc="http://purl.org/dc/elements/1.1/">
<rdf:Description
about="http://burningbird.net/cgi-bin/mt-tb.cgi?tb_id=121"
dc:title="Good RSS"
dc:identifier="http://weblog.burningbird.net/archives/000619.php"
dc:subject="Technology"
dc:description="Mark Pilgrim and Sam Ruby created an RSS Validator for us to use
to validate our RSS feeds, and Bill Kearney was kind enough to host it. Many
appreciations, folks. I ran the Validator against my RSS feeds (both Userland..."
dc:creator="shelley"
dc:date="2002-10-2209:46:26-06:00" />
</rdf:RDF>http://moveabletype.org).
It's used for the tool's trackback
feature, which allows webloggers to notify each other when they
reference each other's posts in their own.
rdf:type. There was
also less than general approbation for the concept of reification,
which no one seemed to be quite happy with. However, the group kept
containers and reification, as well as adding in collections, but
with a caveat: no additional semantics are attached to these
constructs other than those that carefully delimited within the RDF
documentation. Any additional interpretation would then be between
the RDF toolmaker and the people who built the RDF vocabularies and
used the tools. However, even within this, there is common acceptance
of additional semantics, particularly as semantics relate to
containers; of that, one can almost be guaranteed.