Re: rdfs:isDefinedBy (Was Re: Representing DCMI semantics asRDFschemas versus Web pages)

On 2002-06-06 12:56, "ext Daniele Capursi" <capursi@sword.it> wrote:

> Dear Sirs,
> I'm using RDF to represent knowledge in a software project and I think that my
> problem might be part of this thread, beacuse it's about similar things.
> I'm trying to write and RDF schema for my RDF data, in order to validate them.
> I think that existing RDF parsers should have the capability to perform such
> validation in a manner similar to what XML parsers do with XML. So I wrote the
> schema, but I can't find anywhere how to attach my schema to a document of
> mine.
> In XML I would just use the "!DOCTYPE" node or the "xsi:schemaLocation"
> attribute in order to specify that my XML document can be validated using a
> DTD or an XLM Schema of my choice. Then all I have to do is to tell my XML
> parser to validate my document while parsing it and I have it validated. Is
> there a way to indicate that an RDF/XML document should be compliant to an RDF
> schema with something like the "!DOCTYPE" node or the "xsi:schemaLocation"
> attribute?

Firstly, there is no standardized way to specify which schema(s) a given
set of RDF statements must conform to.

Secondly, it is important to understand that XML Schema/DTDs have a
different scope than RDF Schemas.

An XML Schema or DTD has as its scope a single XML instance.

RDF on the other hand, simply uses XML to serialize statements that are
syndicated into a knowledge base, and that knowledge base may be the
result of combining hundreds of individual RDF/XML instances.

RDF Schemas apply to this combined knowledge base, not to a particular
RDF/XML instance, and therefore it doesn't really make sense to associate
an RDF Schema to a particular RDF/XML instance.

RDF Schema constraints are a quality of the knowledge base, not a
particular source of knowledge, and as such, should be specified as
part of the configuration of the knowledge base.

> I can't find a single example showing a schema and a case of its use on the
> whole Internet!
> In particular I'm trying to use the w3c online RDF validator, but I don't know
> how to tell it to get my schema, when parsing my RDF/XML document and to
> validate it against the schema.

Well, there are two kinds of or levels of RDF validation. The more
basic level of validation is the RDF syntax, and that is what the W3C
RDF Validator checks.

The higher level of RDF validation is RDF Schema validation, which tests
that range and domain constraints match the subjects and objects of
actual statements. The W3C RDF validator does not perform such checks.

> The only way I found to do this is to put my schema on the web (and make it
> reachable via an http: URI) and to use its URI as the name of the namespace
> for the objects I have in the RDF document, but it seemed like the validator
> just ignores the schema.

This doesn't work because (with the exception of some tools that do this
as a hack) the namespace need not (and IMO should not) resolve to anything,
and also, one can have many schemas which are relevant to a set of
RDF statements.

But the real reason why this didn't work is simply because the W3C
validator only validates the basic RDF syntax for one RDF/XML instance
at a time.

> Then then I tried to do this by putting both the RDF schema and the RDF model
> in a unique RDF/XML document. But I have some troubles to make sure a
> predicate refers to the same property I defined in the schema.

You're not the first ;-)

The relationship between qnames, IDs and URIs is very problemmatic.

C.f. a recent post of mine regarding this, with some advice:

http://lists.w3.org/Archives/Public/www-rdf-interest/2002Jun/0131.html

But again, even if you add the RDF Schema constraints in the same
RDF/XML instance, the W3C validator will not test them, only the
basic RDF syntax.

It would be reasonable to change the name of the W3C service to
"RDF Syntax Validator" to avoid this misconception of its abilities.

For RDF Schema constraint validation, have a look at

   http://infomesh.net/2001/cwm/
   (see schema-rules.n3 under Semantic Web Utilities)

   http://139.91.183.30:9090/RDF/VRP/index.html

Other folks will likely be able to provide additional pointers
and recommendations.

Regards,

Patrick

--
               
Patrick Stickler              Phone: +358 50 483 9453
Senior Research Scientist     Fax:   +358 7180 35409
Nokia Research Center         Email: patrick.stickler@nokia.com

Received on Friday, 7 June 2002 05:32:48 UTC