- From: Eric Prud'hommeaux <eric@w3.org>
- Date: Mon, 29 Aug 2005 05:22:45 -0400
- To: Dan Connolly <connolly@w3.org>
- Cc: RDF Data Access Working Group <public-rdf-dawg@w3.org>
- Message-ID: <20050829092245.GA17622@w3.org>
On Wed, Aug 17, 2005 at 06:03:46PM -0500, Dan Connolly wrote: > > [this message isn't really finished, but maybe it's better > shared in its present state...] > > On Tue, 2005-08-16 at 09:59 -0400, Eric Prud'hommeaux wrote: > > On Mon, Aug 15, 2005 at 06:12:47PM -0500, Dan Connolly wrote: > > > 8. BASE IRI resolution comment > > > > > > ACTION: ericP to add "don't normalize" to rq23 (perhaps supplied in > > > 0096) > > > > [[ > > QNames are transformed into IRIs by appending the local name to the > > namespace name. Relative IRIs are combined with base IRIs as per > > Uniform Resource Identifier (URI): Generic Syntax [RFC3986] using only > > the basic algorithm in Section 5.2 . Neither Syntax-Based > > Normalization nor Scheme-Based Normalization (described in sections > > 6.2.2 and 6.2.3 of RFC3986) is performed. The resolution of relative > > IRIs in SPARQL queries with no BASE is not defined. > > ]] > > > > I defined QName resolution (not happy with it, but I think it's better > > than nothing). Text was stolen from RDF Syntax [SYNTAX]. > > > > Somewhat counter to the advice of the comment [COMMENT], I used RFC > > 3986 to define relative IRI resolution. > > > > This brought up the question of resolution if no BASE is present. I > > use this feature in Algae a lot. BASE defaults to the URL of the > > query, which means that, be it in a file or a web page, FILE and GRAPH > > and the like can get to relative documents. Defining this would get > > well into execution environment, prohibiting it would prohibit a lot > > of convenient use cases, so I went with don't ask/don't tell. > > That's one coherent approach, but I think it's messier than the > alternative, which is to say that there is always a base URI; i.e. > to figure out the abstract form of a SPARQL query string, you're > always given a base URI. > > That's the route that XML infoset went, and it works reasonably > well. I've thought about this a lot, including a conversation on IRC: 2005-08-25T17:28:35Z * ericP needs to write up "and there *is* a base, regardless of whether there is a BASE directive 2005-08-25T17:30:44Z <DanC> ah... good; that's my preference, ericp 2005-08-25T17:31:03Z <DanC> there should be language in XML infoset that you can borrow... let's see.. 2005-08-25T17:31:13Z * ericP gotta run to dinner 2005-08-25T17:31:36Z <DanC> "In some cases (such as a document read from a string or a pipe) the rules in [XML Base] may r esult in a base URI being application dependent. In these cases this specification does not define the value of the [base URI] or [declaration base URI] property." -- http://www.w3.org/TR/xml-infoset/ I can't see how to say there MUST be a base without talking about implementation and invoking the MAY/MUST RFC. It seems like we have to pick one constraint or the other, and I'd rather pick the not-talking- about-implementations constraint. The current text: [[ SPARQL provides an abbreviation mechanism for IRIs. Prefixes can be defined and a QName-like syntax [NAMESPACE] provides shorter forms. Prefixes may be used anywhere after they are declared; redefining a prefix causes the new definition to be used from that point in the query syntax. The base IRI for the resolution of relative IRIs may be explicitly declared with the BASE keyword. QNames are transformed into IRIs by appending the local name to the namespace name. Relative IRIs are combined with base IRIs as per Uniform Resource Identifier (URI): Generic Syntax [RFC3986] using only the basic algorithm in Section 5.2 . Neither Syntax-Based Normalization nor Scheme-Based Normalization (described in sections 6.2.2 and 6.2.3 of RFC3986) is performed. The resolution of relative IRIs in SPARQL queries with no BASE is not defined. ]] talks only about a base in terms of it's instantiation with the BASE keyword. Would you prefer I invent another term like BaseIRI and say it is set with BASE or some undefined means? This would move the "is not defined" to the upper paragraph: [[ SPARQL provides an abbreviation mechanism for IRIs. Prefixes can be defined and a QName-like syntax [NAMESPACE] provides shorter forms. Prefixes may be used anywhere after they are declared; redefining a prefix causes the new definition to be used from that point in the query syntax. The base IRI for the resolution of relative IRIs may be explicitly declared with the BASE keyword. This specification does not define the value of the base IRI for SPARQL queries with no BASE directive. QNames are transformed into IRIs by appending the local name to the namespace name. Relative IRIs are combined with base IRIs as per Uniform Resource Identifier (URI): Generic Syntax [RFC3986] using only the basic algorithm in Section 5.2 . Neither Syntax-Based Normalization nor Scheme-Based Normalization (described in sections 6.2.2 and 6.2.3 of RFC3986) is performed. ]] Andy, tx for putting the BASE directive earliest in the grammar -- avoided tricky words around lexically earlier PREFIX decls. DanC, everybody, are you happy wiht this text? Shall I drop it in? > > > > > > ACTION: EricP to add test in 0096 to rq23 tests. label "approved" and ref > > > http://www.w3.org/2005/07/26-dawg-minutes > > > ACTION: ericP to send [OK?] message to Bjoern > > > > waiting to see if this text is OK. > > > > [SYNTAX] <http://www.w3.org/TR/2004/REC-rdf-syntax-grammar-20040210/#section-Identifiers> > > [COMMENT] <http://lists.w3.org/Archives/Public/public-rdf-dawg-comments/2005Jul/0042> -- -eric office: +81.466.49.1170 W3C, Keio Research Institute at SFC, Shonan Fujisawa Campus, Keio University, 5322 Endo, Fujisawa, Kanagawa 252-8520 JAPAN +1.617.258.5741 NE43-344, MIT, Cambridge, MA 02144 USA cell: +81.90.6533.3882 (eric@w3.org) Feel free to forward this message to any list for any purpose other than email address distribution.
Received on Monday, 29 August 2005 09:22:48 UTC