W3C home > Mailing lists > Public > public-html-data-tf@w3.org > November 2011

Link relations in RDFa (Was: Re: Guidance on publishing in multiple formats)

From: Jeni Tennison <jeni@jenitennison.com>
Date: Wed, 9 Nov 2011 21:59:25 +0000
Cc: Ivan Herman <ivan@w3.org>
Message-Id: <0DE75ADB-677D-4CBA-A66F-350A8FBF36EC@jenitennison.com>
To: HTML Data Task Force WG <public-html-data-tf@w3.org>
On 9 Nov 2011, at 09:36, Ivan Herman wrote:
> 2. As for the default context of HTML: indeed, there is the issue of the default prefixes. But there is another default set, namely the set of 'link relations' that are recognized as valid in a @rel or @property[1]. The decision of the RDFa WG is to rely on the IANA set of link relations in this respect[2]. It is worth referring to that, too (note that those terms are used only if there is no @vocab, meaning that in probably 99%, if not 100%, of the schema.org cases they would have no effect).


Thanks, Ivan, for pointing out the discrepancies in the use of link relations. We need to work through the implications of this...

If someone uses an unprefixed term within a @rel attribute and there is no in-scope @vocab then an RDFa processor will interpret the relationships based on the IANA link relations whereas an HTML processor will interpret them based on the HTML link relations. Has the RDFWAWG done an analysis on whether the semantics are comparable? (It seems to me that rel="alternate stylesheet" has particular issues.) If it hasn't, it would be a useful thing for this group to do.

If there *is* a @vocab in scope then the semantics of the relationship could be radically different between an HTML/microformats and RDFa processor. For example (ok, a bit of a reach), someone could define a vocabulary about graffiti artists in which the 'tag' property pointed to an imagine of their tag. We should warn publishers against using @vocab to expand properties that have the same short name as those in HTML, and warn vocabulary authors not to use properties with the same name as the HTML link relationships if they aim to have their vocabulary used by RDFa.

In fact, using properties that are named the same as HTML link relationship terms is problematic generally, as the *subject* of the relationship will almost certainly be different. The subject of the HTML link relationships is usually (but not always) the document, whereas the subject of a property in RDFa is determined through the @about, @typeof etc attributes. So again publishers are best advised not to use @vocab for such properties, and vocabulary authors to try to avoid those terms.

If publishers use normal HTML link relations within the scope of @vocab then they will be interpreted as being part of that vocabulary (which they almost certainly aren't). We should warn publishers to avoid using @vocab where there are normal HTML relations in scope (in particular not to use it on the html or head element where they are common place), or to use vocab="http://www.w3.org/1999/xhtml/vocab#" on links that have normal HTML relationships within that scope.

The microformats list of rel values [3] need to be considered as well. That's a much bigger list to beware of...

Have I missed anything?

Jeni

> [1] http://www.w3.org/2011/rdfa-context/html-rdfa-1.1.html
> [2] http://www.iana.org/assignments/link-relations/link-relations.xml
[3] http://microformats.org/wiki/existing-rel-values
-- 
Jeni Tennison
http://www.jenitennison.com
Received on Wednesday, 9 November 2011 21:59:50 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Wednesday, 9 November 2011 21:59:51 GMT