W3C home > Mailing lists > Public > public-rdf-wg@w3.org > August 2011

Re: RDF-ISSUE-74: Prefixed names and slashes [RDF Turtle]

From: Richard Cyganiak <richard@cyganiak.de>
Date: Mon, 15 Aug 2011 18:54:57 +0100
Cc: Gavin Carothers <gavin@topquadrant.com>, RDF Working Group WG <public-rdf-wg@w3.org>
Message-Id: <B88416B3-F4E7-45BE-AD48-9D8A5B867E80@cyganiak.de>
To: Eric Prud'hommeaux <eric@w3.org>
Eric,

On 15 Aug 2011, at 13:11, Eric Prud'hommeaux wrote:
> Another argument for escaping is that identifier names (e.g. in
> biology) have things like ':' and '$' in them. Prefixes add a huge
> amount to the readability of SPARQL and Turtle. Forcing a query or
> data writer to abandon the logical prefix because there's an illegal
> localname character is an equally huge impediment to usability.

I don't think you can make a usability/readability argument for allowing this:

    ns0:id\u003D42

as an abbreviation for this:

    <http://example.com/foo/id=42>

These two things could hardly look more different. Anything that *discourages* the use of \u escape sequences is likely to *improve* readability.

> Disallowing escape sequences
> in SPARQL (and maintaining the status quo in Turtle) means we have to
> justify to the users why the escaping rules they can apply to strings
> and IRIs aren't applicable to prefixed names where they'd be most useful.

The justification is that prefixed names are syntactic sugar intended for use with vocabulary terms, which abbreviate just fine without escapes.

> We have a rare opportunity to make these languages more useful,

Useful? What *is* the use case for this? Being able to put more characters into prefixed names is not a use case.

> consistent

Consistent? Yes, but consistency can be sacrificed for other qualities.

> and intuitive.

Intuitive? Not at all.

Option A: A prefixed name can only contain letters, numbers and a few punctuation chars. For everything else you have to use <angle_bracket_IRIs>.

Option B: A prefixed name can only contain letters, numbers and a few punctuation chars. For everything else you have to use \uXXXX escapes. If you don't know/care to do that, then you have to use <angle_bracket_IRIs>.

Best,
Richard
Received on Monday, 15 August 2011 17:55:21 GMT

This archive was generated by hypermail 2.3.1 : Tuesday, 26 March 2013 16:25:44 GMT