Copyright © 2007 W3C® (MIT, ERCIM, Keio), All Rights Reserved. W3C liability, trademark and document use rules apply.
This document underpins the Protocol for Web Description Resources (POWDER). It describes how the relatively simple operational format of a POWDER document can be transformed through two stages, first into a more tightly constrained XML format (POWDER-BASE), and then into an RDF/OWL encoding (POWDER-S) that may be processed by Semantic Web tools. Such processing is only possible, however, if tools implement the semantic extension defined within this document. The formal semantics of POWDER are best understood after the reader is acquainted with the Description Resources [DR] and Grouping of Resources [GROUP] documents.
This section describes the status of this document at the time of its publication. Other documents may supersede this document. A list of current W3C publications and the latest revision of this technical report can be found in the W3C technical reports index at http://www.w3.org/TR/.
This is a First Public Working Draft, designed to aid discussion and solicit feedback. This draft was developed by the POWDER Working Group which expects to advance this Working Draft to Recommendation Status alongside the other documents to which it refers. The Working Group expects to make very few changes before making a Last Call announcement.
Please send comments about this document to public-powderwg@w3.org (with public archive).
Publication as a Working Draft does not imply endorsement by the W3C Membership. This is a draft document and may be updated, replaced or obsoleted by other documents at any time. It is inappropriate to cite this document as other than work in progress.
This document was produced by a group operating under the 5 February 2004 W3C Patent Policy. W3C maintains a public list of any patent disclosures made in connection with the deliverables of the group; that page also includes instructions for disclosing a patent. An individual who has actual knowledge of a patent which the individual believes contains Essential Claim(s) must disclose the information in accordance with section 6 of the W3C Patent Policy.
The Protocol for Web Description Resources, POWDER, offers a simple method of associating RDF data with groups of resources. Its primary 'unit of information' is the Description Resource (DR). This comprises three elements:
To some extent, this approach is in tension with the core semantics of RDF and OWL. To resolve that tension, it is necessary to extend RDF semantics as described below. In order to minimize the required extension, while at the same time preserving the relatively simple encoding of POWDER in XML which is generally readable by humans, we define a multi-layered approach. The operational semantics, i.e. the encoding of POWDER in XML, is first transformed into a more restricted XML encoding that is less easily understood by humans and depends on matching IRIs against regular expressions to determine whether or not they are within the scope of the DR. This latter encoding is, in its own turn, transformed into the extended-RDF encoding.
The data model makes the attribution element mandatory for all POWDER documents. These may contain any number of Description Resources (DRs) that effectively inherit the attribution of the document as a whole. Descriptor sets may also be included independently of a specific DR and these too inherit the attribution. This model persists throughout the layers of the POWDER model which are as follows:
The operational encoding, a dialect of XML, that transports the RDF data. It is expected that POWDER will typically be published and processed in this form.
POWDER's resource grouping methods are mostly geared towards URLs and Information Resources as defined in the Architecture of the World Wide Web [WEBARCH].
This is a largely theoretical XML encoding of POWDER that reduces all means of grouping resources according to their IRI into a single grouping method, that of matching IRIs against arbitrary regular expressions.
POWDER-BASE is provided as a means of formally specifying the semantics of the various IRI grouping methods defined in POWDER. POWDER-BASE is generated automatically from POWDER by means of the GRDDL transform [GRDDL] that is associated with the POWDER namespace.
Elements not concerned with IRI set definition are identical in POWDER and POWDER-BASE.
The Semantic encoding uses a fragment of RDF/OWL that has been extended in a way that facilitates the matching of the string representation of a resource's identifier against a regular expression.
OWL classes are used to represent sets of resources, grouped according to their IRI and according to their properties (descriptors). Resources are described by asserting that a class that defines a set of IRIs is a sub class of a descriptor-defined classset. Attribution is provided by way of an RDF description of the RDF graph as a whole.
A small RDF vocabulary is needed to support POWDER-S. Although it is valid RDF/OWL, generic tools will only be able to process the semantics of POWDER-S if they implement the necessary extension defined in this document.
POWDER-S is generated from POWDER-BASE by means of the GRDDL transform [GRDDL] that is associated with the POWDER namespace. POWDER-S MAY be created directly but this is generally inadvisable since, whilst a POWDER Processor MUST understand and process POWDER-BASE and SHOULD understand POWDER, it MAY NOT understand and process POWDER-S. The aim of POWDER-S is to make the data available to the broader Semantic Web via GRDDL, not to create an alternative encoding.
The conformance criteria for a POWDER Processor are given in the Description Resource document [DR].
The GRDDL transform from POWDER to POWDER-BASE to POWDER-S is achieved using multiple passes of a POWDER document through an XSLT [XSLT] instance.
Description Resources are defined separately [DR] and a further document defines the creation of IRI sets [GROUP]. Readers should be familiar with those documents before proceeding with this one. The full set of POWDER documents also includes its Use Cases, Primer and Test Suite, together with the namespace documents [WDR, WDRS, WDRD] and GRDDL transform [PDR-GRDDL].
The POWDER vocabulary namespace is http://www.w3.org/2007/05/powder#
for which we use the prefix wdr
The POWDER-S vocabulary namespace is http://www.w3.org/2007/05/powder-s#
for which we use the prefix wdrs
All prefixes used in this document, together with their associated namespaces, are shown in the table below.
Prefix | Namespace |
---|---|
wdr | http://www.w3.org/2007/05/powder# |
wdrs | http://www.w3.org/2007/05/powder-s# |
rdf | http://www.w3.org/1999/02/22-rdf-syntax-ns# |
rdfs | http://www.w3.org/2000/01/rdf-schema#" |
owl | http://www.w3.org/2002/07/owl# |
ox | http://www.w3.org/ns/owl2-xml# |
foaf | http://xmlns.com/foaf/0.1/ |
dc | http://purl.org/dc/elements/1.1/ |
dcterms | http://purl.org/dc/terms/ |
xsd | http://www.w3.org/2001/XMLSchema-datatypes# |
xsl | http://www.w3.org/1999/XSL/Transform |
ex | An arbitrary prefix used to denote an 'example vocabulary' |
Unqualified elements in this document are from the wdr
namespace.
In this document, the words MUST, MUST NOT, SHOULD, SHOULD NOT and MAY are to be interpreted as described in RFC2119 [RFC2119].
For convenience and transparency, we have used the RDF/XML serialization for POWDER-S as we have throughout the document set. Other serializations, such as N3 [N3], are equally valid for POWDER-S. The GRDDL Transformation associated with the POWDER namespace, which uses XSLT to effect the transform, produces RDF/XML as its output.
Examples in this document show fragments of data and each is linked to an external file that mirrors the data in the text. However, in order to be valid documents, the external files include generic data not shown in the text that has been taken largely from examples 2-1 and 2-3 in the Description Resources document [DR].
The attribution
element, present in all POWDER documents, provides data about
the authorship, validity period, and other issues that a user or user agent can use
when deciding whether or not to confer their trust on a POWDER document.
Most attribution
elements are not involved in IRI grouping, and as such are untouched during the transformation from POWDER to
POWDER-BASE. The only exception is abouthosts
, which sets an outer limit on the resources described by the
DRs within the document. POWDER abouthosts
elements are translated into
POWDER-BASE aboutregex
elements, as discussed in Section 4.5 below.
Since the attribution
element provides data about the
document itself, it is transformed from POWDER (through POWDER-BASE) into POWDER-S as
an RDF Description for which the value of the rdf:about
attribute is null. Furthermore, this data does not receive OWL
semantics, but is only meaningful to POWDER tools when deciding
whether a POWDER document as a whole should be taken into
account or discarded.
Child elements of the attribution
element are RDF/XML statements about the document. With the explicit
exception of maker
, issued
, and aboutregex
, these are reproduced unchanged in the POWDER-S instance.
This general rule applies to validfrom
, validuntil
, certifiedby
and supportedby
where the only transformation necessary is to make their namespace explicit.
Where child elements of the attribution
element of a POWDER document contain an
external reference, denoted by the src
XML attribute, this is transformed into rdf:resource
.
Arbitrary RDF is copied verbatim.
Example 2-1 shows the generic semantics of the attribution
element.
POWDER [XML]
<attribution> <ex:property1>value</ex:property1> <ex:property2 src="http://example.org/foo.rdf#frag" /> <ex:property3> <ex:Class> <ex:property4>value_4</ex:property4> </ex:Class> </ex:property3> </attribution>
POWDER-S [RDF/XML]
<rdf:Description rdf:about=""> <ex:property1>value</ex:property1> <ex:property2 rdf:resource="http://example.org/foo.rdf#frag" /> <ex:property3> <ex:Class> <ex:property4>value_4</ex:property4> </ex:Class> </ex:property3> </rdf:Description>
As noted above, there are three elements within the POWDER and POWDER-BASE namespaces that are treated differently.
maker
element, required for all POWDER documents, takes its semantics from the FOAF namespace such that
<maker src="http://example.org/foaf.rdf#me" />
should be understood to mean
<foaf:maker rdf:resource="http://example.org/foaf.rdf#me" />
issued
element are defined in the dcterms
namespace such that
<issued>2008-03-25T00:00:00</issued>
should be understood to mean
<dcterms:issued>2008-03-25T00:00:00</dcterms:issued>
abouthosts
element is discussed in Section 4.5 below.The transformation of validfrom
, validuntil
, certifiedby
and supportedby
from POWDER to POWDER-S is straightforward such that, for example:
<validfrom>2008-01-01T00:00:00</validfrom>
<validuntil>2008-12-31T00:00:00</validuntil>
is transformed into
<wdrs:validfrom>2008-01-01T00:00:00</wdrs:validfrom>
<wdrs:validuntil>2008-12-31T00:00:00</wdrs:validuntil>
Example 2-2 below shows all the POWDER-specific attribution
elements. Note that there is no abouthosts
element in the
example, as it will be discussed in
Section 4.3 below.
POWDER [XML]
<attribution> <maker src="http://example.org/foaf.rdf#me" /> <issued>2007-12-23T00:00:00</issued> <validfrom>2008-01-01T00:00:00</validfrom> <validuntil>2008-12-31T00:00:00</validuntil> <certifiedby src="http://authority.example/powder.xml" /> <supportedby src="http://service.example.com?id=abc" /> </attribution>
POWDER-S [RDF/XML]
<rdf:Description rdf:about=""> <foaf:maker rdf:resource="http://example.org/foaf.rdf#me" /> <dcterms:issued>2008-12-23T00:00:00</dcterms:issued> <wdrs:validfrom>2008-01-01T00:00:00</wdrs:validfrom> <wdrs:validuntil>2008-12-31T00:00:00</wdrs:validuntil> <wdrs:certifiedby rdf:resource="http://authority.example/powder.xml" /> <wdrs:supportedby rdf:resource="http://service.example.com?id=abc" /> </rdf:Description>
Description Resources use vocabularies defined in RDF and/or plain string literals (tags) to describe resources de-referenced from instances of the IRI set. Since descriptor set elements are not involved in the specification of the IRI set itself, they are transferred verbatim from POWDER to POWDER-BASE. Example 3-1 below shows a generic example of a DR in which the IRI set has been elided for clarity (the semantics of the IRI set is discussed in Section 4 below).
<dr> <iriset>…</iriset> <descriptorset> <ex:colour rdf:resource="http://example.org/vocab#red"/> <ex:shape>square</ex:shape> </descriptorset> <tagset> <tag>red</tag> <tag>light</tag> </tagset> </dr>
The ex:colour
element specifies that the ex:colour
relation
holds between all resources in specified by iriset
and the
http://rgb.example.org/colours.rdf#red resource.
The content of ex:shape
is interpreted as a string literal. The
ex:shape
element specifies that all resources in iriset
has the value "square" for the ex:shape
dataproperty.
tag
is a string property defined by POWDER. Its content is a
single string literal, possibly including spaces.
The overall description of the resources in iriset
is the union of
the descriptions in the descriptorset
and the tagset
. In our example these are:
We formally interpret the above as follows: there is an OWL class
containing all resources that share all of these properties, and there
is an OWL class of all resources denoted by iriset
, and the latter
is a subset of the former. In POWDER-S we say:
<owl:Class rdf:ID="iriset_1"> all resources specified by <iriset>...</iriset> </owl:Class> <owl:Class rdf:nodeID="descriptorset_1"> <owl:intersectionOf rdf:parseType="Collection"> <owl:Restriction> <owl:onProperty rdf:resource="http://example.org/vocab#color"/> <owl:hasValue rdf:resource="http://example.org/vocab#red"/> </owl:Restriction> <owl:Restriction> <owl:onProperty rdf:resource="http://example.org/vocab#shape"/> <owl:hasValue>square</owl:hasValue> </owl:Restriction> </owl:intersectionOf> </owl:Class> <owl:Class rdf:nodeID="tagset_1"> <owl:intersectionOf rdf:parseType="Collection"> <owl:Restriction> <owl:onProperty rdf:resource="http://www.w3.org/2007/05/powder-s#tag"/> <owl:hasValue>red</owl:hasValue> </owl:Restriction> <owl:Restriction> <owl:onProperty rdf:resource="http://www.w3.org/2007/05/powder-s#tag"/> <owl:hasValue>light</owl:hasValue> </owl:Restriction> </owl:intersectionOf> </owl:Class> <owl:Class rdf:about="#iriset_1"> <rdfs:subClassOf rdf:resource="#descriptorset_1"/> <rdfs:subClassOf rdf:resource="#tagset_1"/> </owl:Class>
It is possible to have more than one iriset
element, in which case
a resource receives all of the descriptions by belonging to any
one of the corresponding IRI sets. For example:
<dr> <iriset>.1.</iriset> <iriset>.2.</iriset> <descriptorset xml:id="scarlet"> <ex:colour rdf:resource="http://example.org/vocab#red"/> </descriptorset> </dr>
receives the following semantics:
<owl:Class rdf:nodeID="iriset_1"> all resources specified by <iriset>.1.</iriset> </owl:Class> <owl:Class rdf:nodeID="iriset_2"> all resources specified by <iriset>.2.</iriset> </owl:Class> <owl:Class rdf:nodeID="scarlet"> <owl:intersectionOf rdf:parseType="Collection"> <owl:Restriction> <owl:onProperty rdf:resource="http://example.org/vocab#colour"/> <owl:hasValue rdf:resource="http://example.org/vocab#red"/> </owl:Restriction> </owl:intersectionOf> </owl:Class> <owl:Class rdf:about="#iriset_1"> <rdfs:subClassOf rdf:resource="#scarlet"/> </owl:Class> <owl:Class rdf:about="#iriset_2"> <rdfs:subClassOf rdf:resource="#scarlet"/> </owl:Class>
Examples 3-3 and 3-4 also show that if a descriptorset
element has an ID of its own, this is used in the POWDER-S document.
A POWDER processor is free to choose any traversal policy for treating multiple iriset
elements in
a DR: first match wins, last match wins, shortest iriset
first, and so on, as long as all iriset
elements are tried before deciding that DR does not apply to a candidate resource (candidate resource is defined in the Grouping of Resources document [GROUP]). However, DR authors may use the
order of the iriset
elements to suggest an efficient scope evaluation strategy, by putting the iriset
with the widest coverage first, so that a processor that chooses to follow the iriset
elements in document order
is more likely to terminate the evaluation after fewer checks.
A POWDER document may have any number of DRs, all of which are simultaneously asserted and ordering is not important. So, for example:
<powder> <dr> <iriset>.1.<code>iriset</code> <descriptorset> <ex:shape>square</ex:shape> </descriptorset> </dr> <dr> <iriset>.2.<code>iriset</code> <descriptorset> <ex:colour rdf:resource="http://example.org/vocab#red"/> </descriptorset> </dr> </powder>
receives the following semantics:
<owl:Class rdf:ID="iriset_1"> all resources specified by <iriset>.1.<code>iriset</code> </owl:Class> <owl:Class rdf:ID="descriptorset_1"> <owl:intersectionOf rdf:parseType="Collection"> <owl:Restriction> <owl:onProperty rdf:resource="http://example.org/vocab#shape"/> <owl:hasValue>square</owl:hasValue> </owl:Restriction> </owl:intersectionOf> </owl:Class> <owl:Class rdf:about="#iriset_1"> <rdfs:subClassOf rdf:resource="#descriptorset_1"/> </owl:Class> <owl:Class rdf:ID="iriset_2"> all resources specified by <iriset>.2.<code>iriset</code> </owl:Class> <owl:Class rdf:ID="descriptorset_2"> <owl:intersectionOf rdf:parseType="Collection"> <owl:Restriction> <owl:onProperty rdf:resource="http://example.org/vocab#color"/> <owl:hasValue rdf:resource="http://example.org/vocab#red"/> </owl:Restriction> </owl:intersectionOf> </owl:Class> <owl:Class rdf:about="#iriset_2"> <rdfs:subClassOf rdf:resource="#descriptorset_2"/> </owl:Class>
The owl:intersectionOf
of a singleton collection in both descriptor sets, although redundant, is a result of the GRDDL transformation.
Note that iriset_1
and iriset_2
are not necessarily disjoint — some resources may be both red AND square.
A POWDER document may have an ol
element which is an ordered list of DRs. Such a list receives a first-match semantics, that
is, when seeking the description of a candidate IRI, processors extract the descriptor set from the first DR in the ordered list in which it
is in scope. ol
elements allow the easy expression of exceptions to more general rules. So, for example:
<ol> <dr> <iriset>.1.<code>iriset</code> <descriptorset> <ex:shape>square</ex:shape> </descriptorset> </dr> <dr> <iriset>.2.<code>iriset</code> <descriptorset> <ex:shape>round</ex:shape> </descriptorset> </dr> <dr> <iriset>.3.<code>iriset</code> <descriptorset> <ex:shape>triangle</ex:shape> </descriptorset> </dr> </ol>
receives the following semantics, where belonging to description_1 automatically precludes belonging to description_2 and description_3; and belonging to description_2 automatically precludes belonging to description_3:
<owl:Class rdf:nodeID="iriset_1"> <owl:intersectionOf rdf:parseType="Collection"> <owl:Restriction> <owl:onProperty rdf:resource="http://www.w3.org/2007/05/powder-s#matchesregex" /> <owl:hasValue rdf:datatype="http://www.w3.org/2001/XMLSchema-datatypes#string">\:\/\/([^\:\/\?\#\@]+\.)?(example\.com)(:([0-9]+))?\/</owl:hasValue> </owl:Restriction> <owl:Restriction> <owl:onProperty rdf:resource="http://www.w3.org/2007/05/powder-s#matchesregex" /> <owl:hasValue rdf:datatype="http://www.w3.org/2001/XMLSchema-datatypes#string">\:\/\/([^\:\/\?\#\@]*)(\:([0-9]+))?\/foo</owl:hasValue> </owl:Restriction> </owl:intersectionOf> </owl:Class> <owl:Class rdf:nodeID="descriptorset_1"> <owl:intersectionOf rdf:parseType="Collection"> <owl:Restriction> <owl:onProperty rdf:resource="http://example.org/vocab#shape"/> <owl:hasValue>square</owl:hasValue> </owl:Restriction> </owl:intersectionOf> </owl:Class> <owl:Class rdf:about="#iriset_1"> <rdfs:subClassOf rdf:resource="#descriptorset_1"/> </owl:Class> <owl:Class rdf:nodeID="iriset_2"> <owl:intersectionOf rdf:parseType="Collection"> <owl:Restriction> <owl:onProperty rdf:resource="http://www.w3.org/2007/05/powder-s#matchesregex" /> <owl:hasValue rdf:datatype="http://www.w3.org/2001/XMLSchema-datatypes#string">\:\/\/([^\:\/\?\#\@]+\.)?(example\.com)(:([0-9]+))?\/</owl:hasValue> </owl:Restriction> <owl:Restriction> <owl:onProperty rdf:resource="http://www.w3.org/2007/05/powder-s#matchesregex" /> <owl:hasValue rdf:datatype="http://www.w3.org/2001/XMLSchema-datatypes#string">\:\/\/([^\:\/\?\#\@]*)(\:([0-9]+))?\/bar</owl:hasValue> </owl:Restriction> </owl:intersectionOf> </owl:Class> <owl:Class rdf:nodeID="descriptorset_2"> <owl:intersectionOf rdf:parseType="Collection"> <owl:Restriction> <owl:onProperty rdf:resource="http://example.org/vocab#shape"/> <owl:hasValue>round</owl:hasValue> </owl:Restriction> </owl:intersectionOf> </owl:Class> <owl:Class> <owl:intersectionOf rdf:parseType="Collection"> <owl:Class rdf:about="#iriset_2"/> <owl:Class> <owl:complementOf rdf:parseType="Collection"> <owl:Class rdf:about="#iriset_1"/> </owl:complementOf> </owl:Class> </owl:intersectionOf> <rdfs:subClassOf rdf:ID="#descriptorset_2"/> </owl:Class> <owl:Class rdf:nodeID="iriset_3"> <owl:intersectionOf rdf:parseType="Collection"> <owl:Restriction> <owl:onProperty rdf:resource="http://www.w3.org/2007/05/powder-s#matchesregex" /> <owl:hasValue rdf:datatype="http://www.w3.org/2001/XMLSchema-datatypes#string">\:\/\/([^\:\/\?\#\@]+\.)?(example\.com)(:([0-9]+))?\/</owl:hasValue> </owl:Restriction> </owl:intersectionOf> </owl:Class> <owl:Class rdf:nodeID="descriptorset_3"> <owl:intersectionOf rdf:parseType="Collection"> <owl:Restriction> <owl:onProperty rdf:resource="http://example.org/vocab#shape"/> <owl:hasValue>triangular</owl:hasValue> </owl:Restriction> </owl:intersectionOf> </owl:Class> <owl:Class> <owl:intersectionOf rdf:parseType="Collection"> <owl:Class rdf:about="#iriset_3"/> <owl:Class> <owl:complementOf rdf:parseType="Collection"> <owl:Class rdf:about="#iriset_2"/> <owl:Class rdf:about="#iriset_1"/> </owl:complementOf> </owl:Class> </owl:intersectionOf> <rdfs:subClassOf rdf:ID="#descriptorset_3"/> </owl:Class>
There are constraints on what the descriptor set element in a POWDER document may contain. Most importantly, although it
may contain RDF/XML, it MUST NOT contain any blank nodes. This is because creating a blank node implies semantics that
may not be true. The following examples show what attributes and child elements are allowed for a POWDER descriptorset
and how they are represented in POWDER-S.
POWDER [XML]
<descriptorset> <ex:colour>red</ex:colour> </descriptorset>
POWDER-S [RDF/XML]
<owl:Class rdf:nodeID="descriptorset_1"> <owl:intersectionOf rdf:parseType="Collection"> <owl:Restriction> <owl:onProperty rdf:resource="http://example.org/vocab#color"/> <owl:hasValue>red</owl:hasValue> </owl:Restriction> </owl:intersectionOf> </owl:Class>
A POWDER document may refer to a descriptor set in another POWDER document. However, this cannot express POWDER semantics since at the time of processing, the remote document may be unknown, unavailable or not a valid POWDER document. Therefore the formal semantics are limited as shown below.
POWDER [XML]
<descriptorset src="http://remote.example.org/powder2.xml#d1" />
POWDER-S [RDF/XML]
<owl:Class rdf:nodeID="descriptorset_1"> <rdfs:seeAlso rdf:resource="http://remote.example.org/powder2.xml#d1" /> </owl:Class>
Informally, a processor MAY apply full semantics to a descriptor set referred to in this way if it
is part of a valid POWDER document but only once it too has been transformed into POWDER-S.
A typical case might be where the referred to descriptor set represents compliance with an
established code or standard, see the Pre-Defined Descriptors section of the Description resources document [DR].
If these conditions are satisfied, then referring to an external descriptor set using src
can be equivalent
to the following example in which the rdf:resource
construct is used. Here, a processor
SHOULD assume that the referred to resource is an OWL class, even if it cannot access or process it.
This is exemplified below.
POWDER [XML]
<descriptorset rdf:resource="http://remote.example.org/powder2.rdfl#d1" />
POWDER-S [RDF/XML]
<owl:Class rdf:nodeID="descriptorset_1"> <owl:intersectionOf rdf:parseType="Collection"> <owl:Class rdf:about="http://remote.example.org/powder2.rdfl#d1" /> </owl:intersectionOf> </owl:Class>
If the value of a property is an RDF Class, (i.e. an OWL instance, not an OWL Class) then it is expressed as follows.
POWDER [XML]
<descriptorset> <ex:colour rdf:resource="http://example.org/vocab#red" /> </descriptorset>
POWDER-S [RDF/XML]
<owl:Class rdf:nodeID="descriptorset_1"> <owl:intersectionOf rdf:parseType="Collection"> <owl:Restriction> <owl:onProperty rdf:resource="http://example.org/vocab#colour"/> <owl:hasValue rdf:resource="http://example.org/vocab#red" /> </owl:Restriction> </owl:intersectionOf> </owl:Class>
Following on from the previous example, it is also permissible to have an RDF Class embedded in the descriptor set as long as there are no blank nodes. Typed nodes are allowed, as shown in Example 3-13.
POWDER [XML]
<descriptorset> <ex:colour> <ex:Red> <ex:hex>ff0000</ex:hex> </ex:Red> </ex:colour> </descriptorset>
POWDER-S [RDF/XML]
<owl:Class rdf:nodeID="descriptorset_1"> <owl:intersectionOf rdf:parseType="Collection"> <owl:Restriction> <owl:onProperty rdf:resource="http://example.org/vocab#colour"/> <owl:hasValue> <ex:Red> <ex:hex>ff0000</ex:hex> </ex:Red> </owl:hasValue> </owl:Restriction> </owl:intersectionOf> </owl:Class>
Finally, Example 3-11 showed how a single OWL Class could effectively take the place of the descriptor set. It is possible to include references to OWL Classes by their URI as shown below.
POWDER [XML]
<descriptorset> http://remote.example.org/powder2.rdfl#d1 http://remote.example.org/powder2.rdfl#d2 </descriptorset>
POWDER-S [RDF/XML]
<owl:Class rdf:nodeID="descriptorset_1"> <owl:intersectionOf rdf:parseType="Collection"> <owl:Class rdf:about="http://remote.example.org/powder2.rdfl#d1" /> <owl:Class rdf:about="http://remote.example.org/powder2.rdfl#d2" /> </owl:intersectionOf> </owl:Class>
Note that POWDER syntax does not allow an OWL Class to replace the descriptorset
directly.
There are two other POWDER elements that can be included as child elements of descriptorset
that
are mapped verbatim in POWDER-BASE and to RDF data properties in POWDER-S with the same names as follows:
sha1sum
certified
xsd:boolean
used when a DR certifies another resource.Two further (optional) child elements of descriptorset
are mapped verbatim in POWDER-BASE and transformed
into RDF data type properties in POWDER-S using other namespaces:
displaytext
dc:description
displayicon
src
attribute, the value of which is a URI (or IRI) u which, in POWDER-S, becomes foaf:depiction rdf:resource="u"
The semantics of the (free text) tags are straightforward. Each tag given in a tagset
element
in a POWDER document is a value for the RDF datatype property wdr:tag
as shown below. Note
also that resources referred to externally as an attribute of the tagset
are the target of
rdfs:seeAlso
properties.
POWDER [XML]
<tagset ref="http://encyclopaedia.example.com/gherkin.html http://photo.example.com/gherkin.jpg"> <tag>London</tag> <tag>Swiss Re</tag> <tag>gherkin</tag> </tagset>
POWDER-S [RDF/XML]
<owl:Class rdf:nodeID="tagset_1"> <owl:intersectionOf rdf:parseType="Collection"> <owl:Restriction> <owl:onProperty rdf:resource="http://www.w3.org/2007/05/powder#tag" /> <owl:hasValue>London</owl:hasValue> </owl:Restriction> <owl:Restriction> <owl:onProperty rdf:resource="http://www.w3.org/2007/05/powder#tag" /> <owl:hasValue>Swiss Re</owl:hasValue> </owl:Restriction> <owl:Restriction> <owl:onProperty rdf:resource="http://www.w3.org/2007/05/powder#tag" /> <owl:hasValue>gherkin</owl:hasValue> </owl:Restriction> </owl:intersectionOf> <rdfs:seeAlso rdf:resource="http://encyclopaedia.example.com/gherkin.html" /> <rdfs:seeAlso rdf:resource="http://photo.example.com/gherkin.jpg" /> </owl:Class>
The previous sections have shown that the semantics of several elements of a POWDER document can be obtained by applying the GRDDL transform associated with the namespace to generate native RDF/OWL as POWDER-S. This is not so for the IRI set element which, although transformed into valid RDF/OWL syntax, does not express the full semantics.
The IRI constraints defined in the POWDER Grouping of Resources document [GROUP] are given regular-expression semantics by the first part of the GRDDL transform from POWDER to POWDER-BASE. Regular-expression IRI groups are, in their turn, given semantics using datarange restrictions by the POWDER-BASE to POWDER-S transformation. It is noteworthy that the value space of POWDER's IRI constraints is, for the most part, a white space separated list of alternative values. This makes POWDER in its XML form relatively simple but the implications for the semantics are substantial.
Many elements of a POWDER IRI set definition have white space separated lists of strings as their value. White space is any of U+0009, U+000A, U+000D and U+0020. A space-separated list is a string of which the items are separated by one or more space characters (in any order). The string may also be prefixed or suffixed with zero or more of those characters. The GRDDL transform associated with the POWDER namespace converts these into components of a regular expression for use in POWDER-BASE and POWDER-S by following the steps set out below:
. \ ? * + { } ( ) [ ] ! " # % & ' , - / : ; = > @ [ ] _ ` ~
The resulting string is used in a template regular expression to give the element and list's desired semantics. For example
<includehosts>example.com example.org </includehosts>
becomes
<owl:Restriction>
<owl:onProperty rdf:resource="http://www.w3.org/2007/05/powder-s#matchesregex" />
<owl:hasValue rdf:datatype="http://www.w3.org/2001/XMLSchema-datatypes#string">\:\/\/([^\:\/\?\#\@]+\.)?(example\.com|example\.org)(\:([0-9]+))?\/</owl:hasValue>
</owl:Restriction>
POWDER's use cases involve information resources available on the Web, identified by IRIs containing host names, directory paths,
IP addresses, port numbers, and so on. To make it as easy as possible to create IRI sets we define a series of IRI constraints in
the Grouping of Resources document [GROUP]. These all receive semantics through being mapped to
includeregex
and excluderegex
elements in POWDER-BASE.
Re-visiting the example given in the previous section, the POWDER element
<iriset> <includehosts>example.com example.org</includehosts> </iriset>
is expressed in POWDER-BASE as:
<iriset> <includeregex>\:\/\/([^\:\/\?\#\@]+\.)?(example\.com|example\.org)(:([0-9]+))?\/<includeregex> </iriset>
IRIs are always interpreted as strings, even if they include numerical parts such as ports and IP numbers as shown in the following example:
POWDER: [XML]
<iriset> <includehosts>example.com example.org</includehosts> <includeports>80 8080 8081 8082</includeports> </iriset>
POWDER-BASE: [XML]
<iriset> <includeregex>\:\/\/([^\:\/\?\#\@]+\.)?(example\.com|example\.org)(\:([0-9]+))?\/</includeregex> <includeregex>\:\/\/([^\:\/\?\#\@]+\.)*[^\:\/\?\#\@]+\:(80|8080|8081|8082)\/</includeregex> </iriset>
This approach is applied to several of the POWDER IRI set elements. The following table shows these and their associated template regular expressions. In each case, var means the value of the POWDER element after processing as defined in Section 4.1.
POWDER IRI Constraint ( include/exclude... | POWDER-BASE Regular Expression (used in includeregex/excluderegex ) |
---|---|
schemes | ^var\:\/\/ |
hosts | \:\/\/([^\:\/\?\#\@]+\.)?var(\:([0-9]+))?\/ |
ports | \:\/\/([^\:\/\?\#\@]+\.)*[^\:\/\?\#\@]+\:var\/ |
exactpaths | \:\/\/([^\:\/\?\#\@]*)(\:([0-9]+))?var($|\?|\#) |
pathcontains | \:\/\/([^\:\/\?\#\@]*)(\:([0-9]+))?\/[^\?\#]*var[^\?\#]*[\?\#]? |
pathstartswith | \:\/\/([^\:\/\?\#\@]*)(\:([0-9]+))?var |
pathendswith | \:\/\/([^\:\/\?\#\@]*)(\:([0-9]+))?\/[^\?\#]*var($|\?|\#) |
resources | ^var$ |
Note that the Grouping of Resources document [GROUP] sets out a canonicalization process that must be followed. This has particular implications for the matching of ports: where the port number is constrained, default port numbers for the relevant scheme must be taken into account.
Two further pairs of IRI set constraints defined in the Grouping of Resources document undergo additional processing when transformed
from POWDER to POWDER-BASE: includequerycontains
and includeiripattern
(and their 'exclude' counterparts). Each of
these maps to multiple elements in the POWDER-BASE document.
includequerycontains
and excludequerycontains
take a single value, not a white space separated list of values.
Furthermore, an attribute delimiter
takes a single character that delimits the name/value pairs in the query string. If
no such attribute is set, the ampersand (&
) character is used as the default. To transform these elements from
POWDER to POWDER-BASE regular expressions the following steps are carried out:
includeregex
or excluderegex
as appropriate
using the following regular expression template:
\:\/\/([^\:\/\?\#\@]*)(\:([0-9]+))?\/[^\?\#]*\?([^\#]*d)?q(d|$)
This transformation is exemplified below.
POWDER: [XML]
<iriset> <includehosts>example.org</includehosts> <includequerycontains>id=123456&group=abcdefg</includequerycontains> </iriset>
POWDER-BASE: [XML]
<iriset> <includeregex>\:\/\/([^\:\/\?\#\@]+\.)?(example\.org)(\:([0-9]+))?\/</includeregex> <includeregex>\:\/\/([^\:\/\?\#\@]*)(\:([0-9]+))?\/[^\?\#]*\?([^\#]*\&)?id=123456(\&|$)</includeregex> <includeregex>\:\/\/([^\:\/\?\#\@]*)(\:([0-9]+))?\/[^\?\#]*\?([^\#]*\&)?group=abcdefg(\&|$)</includeregex> </iriset>
includeiripattern
and excludeiripattern
also take a single value, not a white space separated list of values,
and generate includeregex
and excluderegex
elements in POWDER-S as follows:
(([^\:\/\?\#\.]+)\:)?(\/\/)?([^\:\/\?\#\@]*)(\:([0-9]+))?
from which $2 is a constraint on the scheme, $4 is a constraint on the host and $6 is a constraint on the port (the host is always constrained, $2 and $6 may be empty).
[A-Za-z]+
.
(\:[0-9]+)?
,
else let p be \:
p
^\*\.(.*)
then let h be
([^\:\/\?\#\@]+\.)*$1
where $1 refers to ^\*\.(.*)
([^\:\/\?\#\@]+\.)*h
<includeregex>^s\:\/\/hp</includeregex>
The following example shows these steps.
POWDER: [XML]
<iriset> <includeiripattern>http://*.example.org:8080</includeiripattern> </iriset>
POWDER-BASE: [XML]
<iriset> <includeregex>^http\:\/\/([^\:\/\?\#\@]+\.)?example.org:8080</includeregex> </iriset>
Incidentally, the IRI set defined here is 'all resources on all subdomains of example.org (but not on example.org) accessed via HTTP through port 8080.'
Providing OWL/RDF semantics for iriset
elements is not directly
possible, since RDF does not provide any means for accessing or
manipulating the string representation of an IRI. We extend RDF
with a datatype property wdrs:matchesregex
as follows:
wdrs:matchesregex rdf:type owl:DatatypeProperty . wdrs:matchesregex rdf:type owl:Property . wdrs:matchesregex rdfs:domain rdfs:Resource . wdrs:matchesregex rdfs:range xsd:string .
and the further stipulation that for triples:
x wdrs:matchesregex reg .
<x, reg> is in IEXT(I(wdrs:matchesregex)) if and only if:
It is now possible to express includeregex
and excluderegex
as a
owl:hasValue
restriction [OWL] on this dataproperty and build up an
OWL Class to represent the IRI set in the POWDER-S encoding. Furthermore, the
sub class relationship between the IRI set and the descriptor set is asserted.
The following example takes a complete example POWDER document through to POWDER-BASE and then to POWDER-S. Note that the only change from POWDER to POWDER Base is the base namespace and the elements within the IRI set.
POWDER [XML]
<?xml version="1.0"?> <powder xmlns="http://www.w3.org/2007/05/powder#" xmlns:ex="http://example.org/vocab#"> <attribution> <maker src="http://authority.example.org/foaf.rdf#me" /> <issued>2007-12-14T00:00:00</issued> </attribution> <dr> <iriset> <includehosts>example.com example.org</includehosts> <includeports>80 8080 8081 8082</includeports> </iriset> <descriptorset> <ex:color>red</ex:color> <ex:shape>square</ex:shape> <displaytext>Everything on example.org and example.com is is red and square</displaytext> <displayicon src="http://example.org/icon.png" /> </descriptorset> </dr> </powder>
POWDER-BASE [XML]
<?xml version="1.0"?> <powder xmlns="http://www.w3.org/2007/05/powder#" xmlns:ex="http://example.org/vocab#"> <attribution> <maker src="http://authority.example.org/foaf.rdf#me" /> <issued>2007-12-14T00:00:00</issued> </attribution> <dr> <iriset> <includeregex>\:\/\/([^\:\/\?\#\@]+\.)?(example\.com|example\.org)(\:([0-9]+))?\/</includeregex> <includeregex>\:\/\/([^\:\/\?\#\@]+\.)*[^\:\/\?\#\@]+\:(80|8080|8081|8082)\/</includeregex> </iriset> <descriptorset> <ex:color>red</ex:color> <ex:shape>square</ex:shape> <displaytext>Everything on example.org and example.com is is red and square</displaytext> <displayicon src="http://example.org/icon.png" /> </descriptorset> </dr> </powder>
POWDER-S [RDF/XML]
<?xml version="1.0"?> <rdf:RDF xmlns:wdrs="http://www.w3.org/2007/05/powder-s#" xmlns:foaf="http://xmlns.com/foaf/0.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:rdfs="http://www.w3.org/2000/01/rdf-schema#" xmlns:owl="http://www.w3.org/2002/07/owl#" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:dcterms="http://purl.org/dc/terms/0.1/" xmlns:ex="http://example.org/vocab#"> <rdf:Description rdf:about=""> <foaf:maker rdf:resource="http://authority.example.org/foaf.rdf#me" /> <dcterms:issued>2007-12-14</dcterms:issued> </rdf:Description> <owl:Class rdf:nodeID="iriset_1"> <owl:intersectionOf rdf:parseType="Collection"> <owl:Restriction> <owl:onProperty rdf:resource="http://www.w3.org/2007/05/powder-s#matchesregex" /> <owl:hasValue rdf:datatype="http://www.w3.org/2001/XMLSchema-datatypes#string">\:\/\/([^\:\/\?\#\@]+\.)?(example\.com|example\.org)(\:([0-9]+))?\/</owl:hasValue> </owl:Restriction> <owl:Restriction> <owl:onProperty rdf:resource="http://www.w3.org/2007/05/powder-s#matchesregex" /> <owl:hasValue rdf:datatype="http://www.w3.org/2001/XMLSchema-datatypes#string">\:\/\/([^\:\/\?\#\@]+\.)*[^\:\/\?\#\@]+\:(80|8080|8081|8082)\/</owl:hasValue> </owl:Restriction> </owl:intersectionOf> </owl:Class> <owl:Class rdf:nodeID="descriptorset_1"> <owl:intersectionOf rdf:parseType="Collection"> <owl:Restriction> <owl:onProperty rdf:resource="http://example.org/vocab#color" /> <owl:hasValue>red</owl:hasValue> </owl:Restriction> <owl:Restriction> <owl:onProperty rdf:resource="http://example.org/vocab#shape" /> <owl:hasValue>square</owl:hasValue> </owl:Restriction> </owl:intersectionOf> <dc:description>Everything on example.org and example.com is is red and square</dc:description> <foaf:depiction rdf:resource="http://example.org/icon.png" /> </owl:Class> <owl:Class rdf:about="#iriset_1"> <rdfs:subClassOf rdf:resource="#descriptorset_1"/> </owl:Class> </rdf:RDF>
The formal encoding of an excluderegex
element uses
the owl:complementOf
property to link to the IRI set specified by the regular expression as exemplified below.
POWDER [XML]
<iriset> <incudehosts>example.org</includehosts> <excludeports>8080</excludeports> </iriset>
POWDER-BASE [XML]
<iriset> <includeregex>\:\/\/([^\:\/\?\#\@]+\.)?(example\.org)(\:([0-9]+))?\/</includeregex> <excluderegex>\:\/\/([^\:\/\?\#\@]+\.)*[^\:\/\?\#\@]+\:(8080)\/</excluderegex> </iriset>
POWDER-S [RDF/XML]
<owl:Class rdf:nodeID="iriset_1"> <owl:intersectionOf rdf:parseType="Collection"> <owl:Restriction> <owl:onProperty rdf:resource="http://www.w3.org/2007/05/powder-s#matchesregex" /> <owl:hasValue rdf:datatype="http://www.w3.org/2001/XMLSchema-datatypes#string">\:\/\/([^\:\/\?\#\@]+\.)?(example\.org)(\:([0-9]+))?\/</owl:hasValue> </owl:Restriction> <owl:Class> <owl:complementOf rdf:parseType="Collection"> <owl:Restriction> <owl:onProperty rdf:resource="http://www.w3.org/2007/05/powder-s#matchesregex" /> <owl:hasValue rdf:datatype="http://www.w3.org/2001/XMLSchema-datatypes#string">\:\/\/([^\:\/\?\#\@]+\.)*[^\:\/\?\#\@]+\:(80|8080|8081|8082)\/</owl:hasValue> </owl:Restriction> </owl:complementOf> </owl:Class> </owl:intersectionOf> </owl:Class>
POWDER and, consequently, POWDER-BASE documents might
include descriptorset
elements that are not
inside a dr
element but directly subsumed by the
document's root. Such descriptions are not meant to be implicitly
applied to any IRI groups, but are only made available by explicit
reference by resources, as explained in Section 2.5 of
the Description Resources document [DR].
In POWDER-S, such descriptions are translated into classes, but no subsumption of an IRI group is asserted, shown in Example 4-6:
POWDER [XML]
<descriptorset> <ex:colour rdf:resource="http://example.org/vocab#red"/> <ex:shape>square</ex:shape> </descriptorset> <descriptorset> <ex:colour rdf:resource="http://example.org/vocab#green"/> <ex:shape>round</ex:shape> </descriptorset> <descriptorset> <ex:colour rdf:resource="http://example.org/vocab#blue"/> <ex:shape>hexagonal</ex:shape> </descriptorset>
POWDER-S [RDF/XML]
<owl:Class rdf:nodeID="descriptorset_1"> <owl:intersectionOf rdf:parseType="Collection"> <owl:Restriction> <owl:onProperty rdf:resource="http://example.org/vocab#color"/> <owl:hasValue rdf:resource="http://example.org/vocab#red"/> </owl:Restriction> <owl:Restriction> <owl:onProperty rdf:resource="http://example.org/vocab#shape"/> <owl:hasValue>square</owl:hasValue> </owl:Restriction> </owl:intersectionOf> </owl:Class> <owl:Class rdf:nodeID="descriptorset_2"> <owl:intersectionOf rdf:parseType="Collection"> <owl:Restriction> <owl:onProperty rdf:resource="http://example.org/vocab#color"/> <owl:hasValue rdf:resource="http://example.org/vocab#green"/> </owl:Restriction> <owl:Restriction> <owl:onProperty rdf:resource="http://example.org/vocab#shape"/> <owl:hasValue>round</owl:hasValue> </owl:Restriction> </owl:intersectionOf> </owl:Class> <owl:Class rdf:nodeID="descriptorset_3"> <owl:intersectionOf rdf:parseType="Collection"> <owl:Restriction> <owl:onProperty rdf:resource="http://example.org/vocab#color"/> <owl:hasValue rdf:resource="http://example.org/vocab#blue"/> </owl:Restriction> <owl:Restriction> <owl:onProperty rdf:resource="http://example.org/vocab#shape"/> <owl:hasValue>hexagonal</owl:hasValue> </owl:Restriction> </owl:intersectionOf> </owl:Class>
abouthosts
and aboutregex
The value of abouthosts
is a whitespace-separated list
of hosts. This list receives identical semantics to the value of
the includehosts
grouping element. In consequence, the
transformation from POWDER to POWDER-BASE
transforms the abouthosts
elements into an
aboutregex
element using the same processing steps as for
transforming includehosts
into includeregex
,
as described in
Section 4.2 above.
The aboutregex
element of POWDER-BASE documents sets an
outer limit on the resources described by the DRs within the document.
That is to say, it restricts the resources that
may receive a description not only implicitly (via subsumption by an
IRI set) but also explicitly as described in Section 2.5 of
the Description Resources document [DR].
In order to capture this semantics, the POWDER-BASE to POWDER-S
transformation must
add an implicit restriction to all descriptor sets in the
document, effectively
subsuming all resource classes created by descriptorset
elements under the resource classe that is created by the
aboutregex
element. In this manner, the explicit
assignment of a description to a resource (cf. Section 2.5 of
the Description Resources document [DR]) will
create an inconsistency if the resource lies outside the
aboutregex
class.
This process is demonstrated by Example 4.7:
POWDER Document [XML]
<attribution> <maker src="http://authority.example.org/foaf.rdf#me" /> <abouthosts>example.org example.net</abouthosts> </attribution> <dr> <iriset> <includehosts>square.example.org</includehosts> </iriset> <descriptorset> <ex:shape>square</ex:shape> </descriptorset> </dr> <dr> <iriset> <includehosts>square.example.com</includehosts> </iriset> <descriptorset> <ex:shape>square</ex:shape> </descriptorset> </dr> <descriptorset> <ex:colour rdf:resource="http://example.org/vocab#red"/> <ex:shape>square</ex:shape> </descriptorset>
POWDER-BASE Document [XML]
<attribution> <maker ref="http://authority.example.org/foaf.rdf#me" /> <aboutregex> \:\/\/([^\:\/\?\#\@]+\.)?(example\.org|example\.net)(\:([0-9]+))?\/ </aboutregex> </attribution> <dr> <iriset> <includeregex> \:\/\/([^\:\/\?\#\@]+\.)?(square\.example\.org)(\:([0-9]+))?\/ </includeregex> </iriset> <descriptorset> <ex:shape>square</ex:shape> </descriptorset> </dr> <dr> <iriset> <includeregex> \:\/\/([^\:\/\?\#\@]+\.)?(square\.example\.com)(\:([0-9]+))?\/ </includeregex> </iriset> <descriptorset> <ex:shape>square</ex:shape> </descriptorset> </dr> <descriptorset> <ex:colour rdf:resource="http://example.org/vocab#red"/> <ex:shape>square</ex:shape> </descriptorset>
POWDER-S Document [RDF/XML] (This has been simplified for clarity, the transform would produce a more verbose RDF/XML document.)
<owl:Class rdf:nodeID="aboutset"> <!-- from the abouthosts element --> <owl:intersectionOf rdf:parseType="Collection"> <owl:Restriction> <owl:onProperty rdf:resource="http://www.w3.org/2007/05/powder-s#matchesregex" /> <owl:hasValue rdf:datatype="http://www.w3.org/2001/XMLSchema-datatypes#string"> \:\/\/([^\:\/\?\#\@]+\.)?(example\.org|example\.net)(\:([0-9]+))?\/ </owl:hasValue> </owl:Restriction> </owl:intersectionOf> </owl:Class> <owl:Class rdf:nodeID="descriptorset_1"> <owl:intersectionOf rdf:parseType="Collection"> <owl:Class rdf:about="#aboutset"/> <owl:Restriction> <owl:onProperty rdf:resource="http://example.org/vocab#shape"/> <owl:hasValue>square</owl:hasValue> </owl:Restriction> </owl:intersectionOf> </owl:Class> <owl:Class rdf:nodeID="descriptorset_2"> <owl:intersectionOf rdf:parseType="Collection"> <owl:Class rdf:about="#aboutset"/> <owl:Restriction> <owl:onProperty rdf:resource="http://example.org/vocab#color"/> <owl:hasValue rdf:resource="http://example.org/vocab#red"/> </owl:Restriction> <owl:Restriction> <owl:onProperty rdf:resource="http://example.org/vocab#shape"/> <owl:hasValue>square</owl:hasValue> </owl:Restriction> </owl:intersectionOf> </owl:Class> <owl:Class rdf:nodeID="iriset_1"> <owl:intersectionOf rdf:parseType="Collection"> <owl:Restriction> <owl:onProperty rdf:resource="http://www.w3.org/2007/05/powder-s#matchesregex" /> <owl:hasValue rdf:datatype="http://www.w3.org/2001/XMLSchema-datatypes#string"> \:\/\/([^\:\/\?\#\@]+\.)?(square\.example\.org|square\.example\.org)(\:([0-9]+))?\/ </owl:hasValue> </owl:Restriction> </owl:intersectionOf> </owl:Class> <owl:Class rdf:about="#iriset_1"> <rdfs:subClassOf rdf:resource="#descriptorset_1"/> </owl:Class>
As discussed in the Description Resources document [DR], a DR MAY refer to descriptorset
elements
in other POWDER documents. In such a situation, although it is not possible using XSLT (the technology used to effect the POWDER transforms) to
generate abouthosts
elements for POWDER-BASE as shown in the previous example, a conformant POWDER Processor
MUST take account of abouthosts
elements in both documents. The abouthosts
element is designed to place an
outer limit on the scope of any description in a POWDER document so that the publisher of those descriptions retains effective control
over the assertions attributed to them.
At the time of this writing, the OWL-2 [OWL2] working draft provides for user-defined datatypes, using the restriction facet mechanism in XSD 2 [XSD2]. As this includes regular expression patterns it possible to translate POWDER into OWL 2 requiring a simpler extension than the one in Section 4.4.
More specifically, we extend RDF semantics
[RDF-SEMANTICS]
with a datatype property hasIRI
, defined as:
hasIRI rdf:type owl:DatatypeProperty .
hasIRI rdf:type owl:Property .
hasIRI rdfs:domain owl:Thing .
hasIRI rdfs:range xsd:anyURI .
and the further stipulation that:
<x, uuu> is in IEXT(I(wdrs:hasIRI)) if and only if uuu is in the domain of I, with I(uuu)=x
Such an extension makes it possible to provide semantics to iriset
by
constructing an RDF datatype for each iriset
and restricting the values of
hasIRI
to this datatype's range.
In this manner, the POWDER-S translation of Example 4-1 becomes:
<?xml version="1.0"?> <rdf:RDF xmlns:wdrs="http://www.w3.org/2007/05/powder-s#" xmlns:foaf="http://xmlns.com/foaf/0.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:rdfs="http://www.w3.org/2000/01/rdf-schema#" xmlns:ox="http://www.w3.org/2006/12/owl2#" xmlns:ex="http://example.org/vocab#"> <rdf:Description rdf:about=""> <foaf:maker rdf:resource="http://authority.example.org/foaf.rdf#me" /> </rdf:Description> <ox:Declaration rdf:nodeID="iriset_1"> <ox:OWLClass ox:URI="#iriset_1"> <ox:ObjectIntersectionOf> <ox:DataAllValuesFrom> <ox:DataProperty>wdr:hasIRI</ox:DataProperty> <ox:DatatypeRestriction> <ox:Datatype>xsd:anyURI</ox:Datatype> <ox:Restriction facet="pattern" > \:\/\/([^\:\/\?\#\@]+\.)?(example\.com|example\.org)(\:([0-9]+))?\/ </ox:Restriction> </ox:DatatypeRestriction> </ox:DataAllValuesFrom> <ox:DataAllValuesFrom> <ox:DataProperty>wdr:hasIRI</ox:DataProperty> <ox:DatatypeRestriction> <ox:Datatype>xsd:anyURI</ox:Datatype> <ox:Restriction facet="pattern" > \:\/\/([^\:\/\?\#\@]+\.)*[^\:\/\?\#\@]+\:(80|8080|8081|8082)\/ </ox:Restriction> </ox:DatatypeRestriction> </ox:DataAllValuesFrom> </ox:ObjectIntersectionOf> </ox:OWLClass> </ox:Declaration> <ox:Declaration rdf:nodeID="descriptor_1"> <ox:OWLClass ox:URI="description_1"> <ox:ObjectIntersectionOf> <ox:ObjectHasValue> <ox:ObjectProperty>ex:shape</ox:ObjectProperty> <ox:Individual>ex:square</ox:Individual> </ox:ObjectHasValue> </ox:ObjectIntersectionOf> </ox:OWLClass> </ox:Declaration> <ox:SubClassOf> <ox:OWLClass ox:URI="#iriset_1" /> <ox:OWLClass ox:URI="#descriptorset_1" /> </ox:SubClassOf> </rdf:RDF>
which describes the intersection of the sets of all abstract resources, the concrete IRI string of which is a literal which is in the given datarange.
The Working Group would like to thank Jeremy Carroll for his substantial contribution to the development of the semantics of POWDER.