W3C home > Mailing lists > Public > www-rdf-interest@w3.org > August 2003

interoperability between plain literals and typed literals: typed tidy literals

From: Francesco CannistrÓ <fracan@inwind.it>
Date: Thu, 7 Aug 2003 15:27:21 +0200
Message-ID: <00b101c35ce7$a38e2b30$29971d97@Matrix>
To: <www-rdf-interest@w3.org>

Hi All.

I have some perplexities about the interoperability between plain and typed
literals, and I would need some clarifications.

At the current status of specs, RDF does make a clear distinction between
plain literals and typed literals.
In this way, the possibility to leverage tidy literals as literals
representing specific datatype instances indicated as plain literals seems
to be disallowed since it seems at least recommended that plain literals are
to be intended like self-denoting values to be used preferably for
human-understanding purposes only, whereas the literal values properly
suitable for machine-understanding and processing are the typed literals. .
Indeed, I think that if that separation was not issued so strongly, then
major advantages could be achieved. In particular, as far as schema aware
application contexts are concerned, it would be possible to express a typed
literal value as a plain literal and then to recognize such a value as a
typed literal by means of the schema that defines the property for which the
literal value has been indicated.
Consider the following schema example:

(1)  <rdf:Property rdf:ID="ppp">
         <rdfs:domain rdf:resource="#DomainOf_ppp"/>
         <rdfs:range>
            <rdfs:Datatype
rdf:about="http://www.w3.org/2001/XMLSchema#integer"/>
         </rdfs:range>
      </rdf;Property>

In cases like this, a schema aware processor could read a statement like the
following:

(2)   <voc:DomainOf_ppp rdf:about="#theSubject">
          <voc:ppp>5</voc:ppp>
       </voc:DomainOf_ppp>

and then, provided with the knowledge base of the vocabulary schema, could
recognize the plain literal value "5" as an instance of a specific datatype.
Furthermore, for applications requiring that an RDF description is validated
vs. the schema it instances, it would be possible to assert within the
schema all the constraints that an RDF document must respect.
In fact, if, on the one hand, the schema was written as follows:

(3)  <rdf:Property rdf:ID="ppp">
         <rdfs:domain rdf:resource="#DomainOf_ppp"/>
         <rdfs:range rdf:resource="&rdfs-ns;Literal">
      </rdf;Property>

then the processor would not have enough information to process a ppp
statement since the object value of such a property could be both a plain or
a typed literal (and in this latter case the processor would not know
whether the literal should be an instance of a specific datatype).
On the other hand, if the schema was written like in (1), then indication of
the value of a ppp property as an explicit typed literal would not be
required and would cause an unnecessary overhead:

(4)   <voc:DomainOf_ppp rdf:about="#theSubject">
          <voc:ppp
rdf:datatype="http://www.w3.org/2001/XMLSchema#integer">5</voc:ppp>
       </voc:DomainOf_ppp>

In conclusion, could somebody explain to me the needs for the RDF clear-cut
separation between plain and typed literals since I don't succeed in finding
any good reason for that strong separation???

Thanks in advance.

Regards,
Francesco
Received on Thursday, 7 August 2003 09:28:00 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Monday, 7 December 2009 10:52:01 GMT