RE: RDF and RDFS Schemas?

Bill,

RDF instances don't have a definable syntax form, which is why there is no
XML schema / DTD. They are statements, and there are multiple equivalent
possibile XML representations of the same data.

(I have, somewhere, an explanation of this that I will try to publish for you
next week).

That said, If you have some RDF and you want to make instance files, you
could make an XML schema that covers the particular RDF you are trying to
generate, and use that for generating your RDF. You just can't expect to read
RDF according to a schema.

I have used this approach to make authoring tools for specific kinds of RDF
data in Xforms. My forms are buggy (they only work in X-smiles 0.81 as far as
I know because when I did it there was no xforms validator and I worked by
trial and error) but the rough idea was that I hand-wrote a particular
instance. Xforms let me use that as a template to generate new instances with
the same XML form, changing the element content to create new documents.

The stuff is at http://www.w3.org/2001/sw/Europe/200305/axforms - I don't
recall it being brilliantly documented but there might be enough there to go
on.

RDF Schema is now called RDF vocaulary definition language to try and fight
the confusion with XML schema. Whereas XML schema sets constraints on syntax,
RDF Schema allows you to add semantic interpretation to your RDF instances,
such as how to relate a term you use to a term in another RDF vocabulary.

(I really should dig out that stuff and publish it. Ping me if I don't...)

Cheers

Chaals

On Fri, 14 Jan 2005, Burkett, Bill wrote:

>
>Thanks, Sandro, Shawn, Dan for your responses.
>
>Okay - I think I understand why there is no schema for RDF.  Would it be
>reasonable to say that RDF is more-or-less a syntax/grammar of a "instance"
>document?  Which is why there is a need for RDFS?
>
>If this is a case, I'd still like to find an XML Schema (not a Relax NG
>schema) for RDFS so I can create an RDFS schema to govern an RDF instance
>document (no one mentioned this in their responses).  Does anyone have any
>idea where I could find one?  My goal is to create an RDFS Schema to govern
>the hand-creation of RDF instance files (in an RDF editor or a plain old XML
>Editor that I can load the RDFS schema into) that I would like to use as
>test cases.
>
>(What I find so challenging about this discussion what I percieve to be as a
>casual attitude with respect to the boundary between "schema" and
>"instance".  I find that if I don't respect this boundary I find the
>discussions quite confusing.)
>
>Thanks - Bill
>
>
>
>> -----Original Message-----
>> From: Shawn Bowers [mailto:sbowers@ucdavis.edu]
>> Sent: Wednesday, January 12, 2005 1:36 PM
>> To: Sandro Hawke
>> Cc: Burkett, Bill; www-rdf-interest@w3.org
>> Subject: Re: RDF and RDFS Schemas?
>>
>>
>>
>> Sandro Hawke wrote:
>> >>I'd like to hand-build some RDF/RDFS test cases using an
>> XML Editor =
>> >>(e.g., XMLSpy) but - much to my surprise - I haven't been
>> able to find =
>> >>an XML Schema (or even a DTD) for either of these.  (Or
>> nothing recent =
>> >>anyway - I found "attempts" at creating XML Schemas for RDF
>> but they're =
>> >>all over 5 years old.) =20
>> >>
>> >>My first question is: Does anybody have, or know where I
>> can locate, an =
>> >>XML Schema (or DTD) for RDF and RDFS (and perhaps OWL)?  My second =
>> >>question is more general: why is it so difficult to find
>> these things?  =
>> >>I would think they'd be available on W3.org smack-dab in
>> the middle of =
>> >>the RDF project material where they'd be easy to find.
>> >
>> >
>> > The short answer is that it's not possible to make an XML Schema or
>> > DTD for RDF in general.  I'm not sure how to explain why not, but it
>> > may be clear if you think about how RDF/XML doesn't constrain much;
>> > almost any XML inside an rdf:RDF element is valid RDF/XML.
>>  So a DTD
>> > wouldn't help much, even if one could be written.
>>
>> I believe one answer is that when you define a triple, you
>> can use the
>> property of the triple (like "editor") as a tag name in the RDF/XML
>> encoding.
>>
>> For example, (taken from the RDF syntax and grammar spec):
>>
>> <rdf:Description rdf:about="http://www.w3.org/TR/rdf-syntax-grammar">
>>    <ex:editor>
>>      <rdf:Description>
>>        <ex:homePage>
>>          <rdf:Description rdf:about="http://purl.org/net/dajobe/">
>>          </rdf:Description>
>>        </ex:homePage>
>>      </rdf:Description>
>>    </ex:editor>
>> </rdf:Description>
>>
>> Here, "editor" and "homePage" are application-specific properties
>> (perhaps defined in an RDF Schema), whereas "Description" is an RDF
>> construct (i.e., "Description" would be an element defined in an XML
>> Schema for the RDF/XML encoding).   You can basically use any
>> property
>> name you want in an RDF document (so long as it is a valid xml tag
>> name), thus making it difficult to specify an accurate XML
>> Schema and/or
>> DTD for the RDF/XML encoding.
>>
>> Shawn
>>
>>
>> >
>> > Try looking instead for "RDF Authoring Tools" and see if you have
>> > better luck.
>> >
>> >       -- sandro
>>
>>
>>
>>
>

Charles McCathieNevile             http://www.w3.org/People/Charles
tel: +61 409 134 136                 fax(france): +33 4 92 38 78 22
Post:    21 Mitchell street, FOOTSCRAY Vic 3011, Australia    or
 W3C, 2004 Route des Lucioles, 06902 Sophia Antipolis Cedex, France

Received on Friday, 14 January 2005 18:59:21 UTC