W3C home > Mailing lists > Public > www-rdf-logic@w3.org > May 2001

RE: Surface vs. Abstract Syntax, was: RE: What do the ontologists want

From: Jonathan Borden <jborden@mediaone.net>
Date: Fri, 18 May 2001 21:47:17 -0400
To: "pat hayes" <phayes@ai.uwf.edu>
Cc: <www-rdf-logic@w3.org>
Message-ID: <001001c0e005$a2abcbc0$0201a8c0@ne.mediaone.net>
pat, earlier you wrote:

>
> >2.  RDF is not necessarily verbose: the RDF syntax in the current W3C
> >    spec is verbose, but other RDF syntaxes are much less so (eg n3,
> >    as Jos de Roo pointed out).
>
> I agree: the verbosity arises chiefly from XML rather than RDF
> itself. Has anyone suggested Lexical_XML?
> <capletter>I</capletter><letter>t</letter><space>
> </space><letter>l</letter><double-letter>oo</double-letter><letter>k</
> letter><letter>s</letter> like that. Its a really neat universal
> notation: you can describe it in itself!  (The proof is too long to
> fit in this message, however.)
>

compaining about XML's verbosity is directly along the lines of complaining
that LISP uses too many paren's.

perhaps the greatest benefit of XML is that its surface syntax directly
represents its abstract syntax, and for someone familiar with XML, this
means that one can look at a document, even in the absense of a schema, and
get a pretty good idea of its structure.


> >Another would
> be to bite
> >the bullet and make containment and ordering a natural feature of the RDF
> >abstract syntax. The current container mechanism _is_ painful.
>
> But this goes beyond just adding containers. LISP lists are used to
> implement everything: expressions, in particular, are encoded as
> lists. That is why I prefer to say "S-expressions", to emphasise that
> this is a general-purpose datastructuring technique, not merely one
> kind of datatype among many. (It may be that I have misunderstood
> you, and that you mean 'containment' in a much more comprehensive
> sense than simply an additional datatype; in which case I would agree
> with you, I think.)

A couple of points. First the RDF XML syntax does not make full use of XML's
abilities to represent structured data. Every XML element node already _has_
a list of child nodes (e.g. the DOM NodeList). However the RDF abstract
syntax does not naturally maintain order so the syntactic hack is introduced
converting <rdf:li> into <rdf:_1> <rdf:_2> etc. This is _painful_ to my XML
accustomed eye.

Second: When I did alot of LISP programming, I recall it often took a bit of
work to create complex datatypes out of LISP. If you recall of Dan Corkill
and John Lowrance's GRASPER language (UMass c. 1981), one can indeed
represent nodes, arcs, spaces etc in LISP - on the other hand adding trees
and maps as native datatypes _tremendously_ increases the speed of such a
language. XML naturally represents trees and somewhat naturally handles
maps.

> This proposal for thinking about RDF would make
> the RDF into an implementation language in which to write expressions
> in some other language (which would have a semantics), rather than
> just adding a handy datatype to RDF, in the way that DAML adds lists
> as a shorthand for nested-triple structures of a certain kind (which
> would be too painful to spell out in detail).
>

again, the data structures naturally represented in an RDF abstract syntax
are orthogonal to what semantics are assigned to the expressions. put
another way, whether we code these using s-expressions or XML is not
relevent. but _having_ XML already provides an entirely natural way to
represent lists. what i am suggesting is that this concept could be
reflected in the RDF abstract syntax -- a trivial way to do this might be s
:= <p,s,o,i> where i is the index of the statement as reflected by document
order.

Jonathan Borden
The Open Healthcare Group
http://www.openhealth.org
Received on Friday, 18 May 2001 21:48:07 UTC

This archive was generated by hypermail 2.4.0 : Friday, 17 January 2020 22:45:38 UTC