W3C home > Mailing lists > Public > public-rdf-in-xhtml-tf@w3.org > October 2008

Re: RDFa review ... too late, but maybe still helpful for the group

From: Ben Adida <ben@adida.net>
Date: Tue, 07 Oct 2008 17:23:22 -0700
Message-ID: <48EBFD7A.3030502@adida.net>
To: Axel Polleres <axel.polleres@deri.org>
CC: public-rdf-in-xhtml-tf@w3.org, alxandre.passant@deri.org, Benjamin Heitmann <benjamin.heitmann@deri.org>


Hey folks,

Thanks for your review!

A few comments below in response to your questions. Mark, Shane, and
Steven might chime in to enhance the response :)

We'll do our best to incorporate as much as we can here, though we are
on a tight deadline to publish. Comments below.


> The inconsistent specification of the CURIE syntax is the main critical
> question we have, which occurs in more than one section.  The main
> question is whether a CURIE must contain a colon, or need not.  The
> formal syntax definition in section 7 says
> 
>> curie       :=   [ [ prefix ] ':' ] reference
> 
> but the definition of the XML Schema datatype in appendix B.1 does not
> reflect the fact that the colon can be missing:
> 
>> <xs:simpleType name="CURIE">
>>     <xs:restriction base="xs:string">
>>       <xs:pattern value="[\i-[:]][\c-[:]]*:.+" />
>>     </xs:restriction>
>> </xs:simpleType>

Good point about the inconsistency, we'll be clearer about that. A valid
CURIE need not have a colon, but CURIEs in @rel/@rev *do* need a colon,
and that is indeed an intended design tidbit: we don't want rel="foobar"
to mean something by default, but we *do* want rel="next" to mean what
it has always meant.

> Generally: If the authoritative definition of CURIEs in RDFa is to be
> given in the RDFa spec, you could simplify this a bit and restrict it to
> those cases that are valid in RDFa.  If the definition of CURIEs in RDFa
> is to be taken from the CURIE specification
> (http://www.w3.org/TR/curie/), the RDFa specification could just refer
> to that, and concentrate on RDFa-specific differences, such as:

We cannot forward-reference a document that isn't a REC, thus the
separate explanation.

> . in section 7 suggest that ":next" is a valid CURIE (due to the 'default
> prefix' mapping), but "next" is not.  On the other hand, there is no
> reasonable example given that explains why ":next" should ever be used,

:next is there for consistency. next is there for backwards
compatibility (and not as a CURIE to prevent overinterpretation of
rel="foobar".)

> The fact that
> "next" is not a CURIE makes the parsing of link/@rel overly complicated.

Right... the reason is given above. That said, it shouldn't be *too*
complicated.

>> @rel and @rev support both XHTML link types and CURIEs
> 
> If XHTML link types like "next" turn out to be CURIEs, this will have to be
> rephrased.

We could say "prefixed CURIEs," but I'll let Mark and Shane explain further.

> Moreover, it is not clear how to use a default namespace introduced via
> @xmlns
> with CURIEs; consider the following sentence from section 7 and an example:
> 
>> However, RDFa does not define a 'no prefix' mapping, meaning that 
> this form
>> of CURIE is not supported.
> 
> BTW, what if we have e.g.
> 
> <xhtml:elem xmlns="http://purl.org/dc/elements/1.1/" about=":foobar">
> 
> (or maybe about="foobar"?)

xmlns="" is *not* used in XHTML to define the default CURIE mapping.

Also, note in your example above that @about is a SafeCURIE, which means
that you probably should have written about="[:foobar]". Regardless,
that still resolves to the xhtml#vocab default mapping.

> Would the only possibility to reference a resource in this namespace by a
> CURIE be to give this namespace a proper prefix, such as "dc"?

For now, yes. We are discussing other ways of having a default mapping,
but that will be for a future version of RDFa, not for now.

>  So if redefining the default namespace does not have any impact on the URI prefix
> mapping that is relevant for CURIEs, this should be explained by a
> dedicated example.

We might make it a dedicated test case, although I could have sworn we
had one (but I can't find it yet). I don't think we'll change language
at this point, as this has not been an issue so far. Mark, Shane, feel
free to correct me.

> Other sections affected by this issue are 5.4.2 and 5.4.3:
> 
>> 1. Split the CURIE at the colon to obtain the prefix and the resource.
> 
> How should the parser react if there is no colon? 

As per the spec, ignore the value (but don't ignore the presence of the
attribute.) I think that part is relatively well explained.

> "[Albert_Einstein]" is not a non-CURIE in the sense of the formal syntax
> defined in section 7, nor in the sense of the CURIE spec, but it is a CURIE
> that is not supported in RDFa, according to the absence of a 'non prefix'
> mapping.

Right, so again this is not an RDFa-supported CURIE.

> No examples are given for embedding invisible annotations into the document
> using @rev, @content, and @resource.  There should at least be an
> example for
> @content and @resource.

We're not trying to be complete with all examples in this document. That
would make the document *quite* long :) We're going to be collecting
examples on the RDFa wiki: http://rdfa.info/wiki

>> Note that it is generally considered a good idea not to use relative 
> paths
>> in namespace declarations, but since it is possible that an author may
>> ignore this guidance
> 
> The XML namespaces spec says it's deprecated.  So it should probably not be
> endorsed by the (newer) RDFa spec.

These are CURIEs, so I'm not sure that deprecation applies.

> == 5.3 Chaining ==
> 
>> Einstein has a birth place of Germany, which has a long name of
>> "Federal Republic of Germany".
> 
> This example is arguable; We'd suggest to completely replace it
> throughout the specification.  Einstein was born in Germany, but at that
> time the Federal Republic of Germany did not exist.  I think this
> example opens a can of worms, as it raises questions of temporal
> reasoning that RDF does not have an answer for.

Fair point, though at this point I don't recommend any widespread
changes of this kind (which could have repercussions on the readability
of the document.)

> == 5.4.5 Referencing Blank Nodes ==
> 
> Here it should be mentioned that you can also generate implicit bnodes
> using
> @typeof.  bnodes with an explicit ID are not the only way.

Right, but if you want to reference the bnode, you have to give it an
ID. For this section, that seems okay.

> 
> == 5.5 Sequence ==
> 
>> 9. . the actual literal value is obtained as follows:
>> * as a [typed literal] if:
>>   * @datatype is present, and does not have an empty value
> 
> Note that this condition covers the case @datatype=rdf:XMLLiteral, so it
> should be changed to: "does not have an empty value, nor the value
> XMLLiteral"

I think technically that's covered by the other condition matching, but
you're right that this would help clarify things and be more precise.

> ==== 6.1.1.3 Using @src ====
> 
>> The complete mark-up yields three triples:
>> ...
>> <photo1.jpg> xh:license <http://...> .
> 
> xhv is the correct prefix.

Good catch!

-Ben
Received on Wednesday, 8 October 2008 00:24:01 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Wednesday, 8 October 2008 00:24:04 GMT