Re: Different properties related to well-formedness

Olaf, all,

I have a problem with the way triple terms are sometimes defined in the 
different formalisations of RDF 1.2 (like the semantics proposed by 
Enrico and this well-formedness proposal).

Considering your definitions, a triple term *is* an RDF triple. Not just 
syntactically. It *is*, in every aspect. A triple term should not be 
defined like this, because the phrase "triple term" denotes a different 
thing than the phrase "RDF triple".

A triple term is a role an RDF triple plays within another RDF triple. 
Just like "predicate" is the role an IRI plays inside an RDF triple.

Compare your definitions with these:

Definition: An RDF 1.1 triple is a 3-tuple (s, p, o) where:
  - s in an IRI or a blank node;
  - p is a predicate;
  - o is an IRI, a blank node, or a literal.

Definition: A predicate is defined as:
  - a Unicode character string that conforms to the syntax defined in 
RFC 3987

Then one could say "let i be a predicate", which is very odd. Since i 
*is* a URI, I can then talk about the triple (i, p, o), and then there 
is a predicate in subject position!

It is not difficult to distinguish the notion of predicate and the 
notion of IRI. One is a role in a triple while the other is a class.

I claimed that it is not difficult to define triple terms in such a way 
that it is distinct from RDF triples, by making it a role that an RDF 
triple plays inside another RDF triple.

Therefore, I would propose:

Definition: An /RDF triple/ (or just /triple/ if context is clear) is a 
3-tuple that is defined recursively as follows:
  - If s is an IRI or a blank node, p is an IRI, and o is an IRI, a 
blank node, or a literal, then (s, p, o) is an RDF triple.
  - If s is an IRI or a blank node, p is an IRI, and o is an RDF triple, 
then (s, p, o) is an RDF triple.
  - If s is an RDF triple, p is an IRI, and o is an IRI, a blank node, a 
literal, or an RDF triple, then (s, p, o) is an RDF triple.

Definition: the first (resp. second, resp. third) element of an RDF 
triple t is called the /subject/ (resp. /predicate/, resp. /object/) of 
t and if the subject (resp. object) of t is an RDF triple then we say 
that it is a /triple term/ for t. Likewise, any RDF triple that is a 
triple term for a triple term of t is also a triple term of t.

Definition: the /triple terms of an RDF graph/ G are all the triple 
terms of the RDF triples that compose G.


Using these definitions, you would also avoid the redundancy in the 
definitions of /triple-term-placement well-formed/ and 
/reifies-predicate well-formed/, which look very much like unintended 
duplicates.


--AZ


Le 23/04/2024 à 16:50, Olaf Hartig a écrit :
> Hi all,
> 
> It occurs to me that the notion of well-formedness that the group
> strives for has more facets than just the decision of whether
> rdf:reifies is many-to-many or many-to-one, and I think it would be
> useful for us to be able to discuss and to decide about these facets
> independent of one another. Therefore, I have created the following
> document in which I define different syntactic properties that an RDF
> graph with triple terms may possess, where each of these properties
> corresponds to one of the facets that I see. The important point is
> that these properties are completely orthogonal, and we can decide
> which of them we include as the properties required for well-
> formedness.
> 
> https://github.com/w3c/rdf-star-wg/blob/main/docs/constraints.md
> 
> Best,
> Olaf
> 

-- 
Antoine Zimmermann
École des Mines de Saint-Étienne
158 cours Fauriel
CS 62362
42023 Saint-Étienne Cedex 2
France
Tél:+33(0)4 77 49 97 02
http://www.emse.fr/~zimmermann/

Received on Tuesday, 23 April 2024 15:59:35 UTC