- From: Dave Reynolds <der@hplb.hpl.hp.com>
- Date: Fri, 13 Jul 2007 10:19:01 +0100
- To: Sandro Hawke <sandro@w3.org>
- CC: public-rif-wg@w3.org
Sandro Hawke wrote: > > This is an attempt to progress on ACTION-309 ("Work on unified > strawman proposal for asn->xml system"). Personally I'm happy with the approach and most of the details. I just have a couple of small comments ... (a) Text content and leaf labelling In an example like: <Const>book</Const> then that doesn't follow RDF striping (Const is a class node and there is no property relation to the string "book"). Possible solutions retaining RDF/XML serialization are: <Const rdf:value="book" /> or <Const><name>book</name></Const> the latter being equivalent in RDF/XML terms to: <Const rif:name="book" /> In most cases I hope Consts will be IRIs not strings in which case presumably they would be: <Const rdf:about="http://example.com/myrules#book" /> Adopting RDF/XML style does mean we can't use qname/curie notation for shortening IRIs. We can only use relative IRIs so the above could be: <Const rdf:about="#book" /> in a document with xml:base of "http://example.com/myrules". (b) Single serialization > Also, I'm constraining objects to be > serialized in one place in a document -- the value of rdf:about is not > allowed to occur twice in a file. (This makes de-serializing and other > kinds of XML processing easier and more efficient, I believe.) If that is really a goal then there is a problem with Const nodes. All IRI Const nodes are likely to be serialized multiple times. I don't understand why that might be a problem. If it really is a problem then there are a couple of solutions which preserve RDF/XML compatibility. (i) Serialize each Const once (e.g. at first occurrence) then all references to the same Const would use rdf:resource: ... <Const rdf:about="#book" /> ... <Uniterm> <op rdf:resource="#book"> <arg rdf:parsetype="Collection"> <Var rif:name="Author" /> <Const rif:name="LeRif" /> </arg> </Uniterm> (ii) Serialize Consts as blank nodes with a property giving their IRI <Const rif:iri="#book" /> From an XML processor's point of view I would have thought the repeated rdf:about would be fine. I guess the issue is whether we permit metadata annotations on Const nodes. (c) Metadata and schema validation A primary attraction to me of using the RDF data model at the top level of rulesets and rules is that it gives us extensible metadata for free. <Ruleset> <Forall rdf:about="#rule1"> <rdf:label>Rule1</rdf:label> <dc:description>This is a cool rule</dc:description> <dc:creator>Dave Reynolds</dc:creator> ... If that is indeed the way that we allow metadata annotation then the XML Schema will need to permit unbounded xs:any elements on the classes where we permit metadata annotation. Unexpected element data at that level will be treated as metadata and ignored. This seems OK to me and preferable to having a closed set of metadata terms. Dave -- Hewlett-Packard Limited Registered Office: Cain Road, Bracknell, Berks RG12 1HN Registered No: 690597 England
Received on Friday, 13 July 2007 14:06:23 UTC