w3c / rdf-ucr

https://w3c.github.io/rdf-ucr/
Other
5 stars 1 forks source link

RDF-star for CIDOC-CRM events #14

Open pfps opened 1 year ago

pfps commented 1 year ago

See https://github.com/w3c/rdf-ucr/wiki/RDF-star-for-CIDOC-CRM-events for the current description of this use case. Taken from https://github.com/w3c/rdf-ucr/issues/12#issuecomment-1563856312

** Brief Description of your use case:

Quoted triples may be useful for representing events using a method similar to that used in labelled property graphs. For example, a marriage is an event that can be represented as a quoted triple (usually asserted as well) with added information, such as place, time, officiant, etc.

*** What you want to be able to do:

Represent the effect of an event along with other information about it, so that a marriage asserts the marriage between two people and the other information is attached to the quoted triple. This more closely couples the state information with the event information.

*** What is the role of RDF-star quoted triples in your use case:

The quoted triple is used as the subject of the information associated with the event.

*** Why it is hard or impossible to do what you want to do without quoted triples:

Without quoted triples events have to be represented using something like RDF reification, where there is a node (often a blank node) for the event that is linked to information about the event. The effect of the event is then a separate triple, and the connection between the event and its effect is not part of the RDF model.

*** How you want quoted triples to behave in your use case:

What matters in events is the objects involved, so using different names for the same object should not affect the event.

*** An example RDF graph that shows part of your use case:

Here is an example of how CIDOC-CRM is used to represent events without using quoted triples, here the birth and castration of an historical figure. In this example genders are classes, not values of a gender property.

@prefix ex: <http://example.org/tla/ontologies/2023/3/gender-assignment/> .
@prefix crm: <http://www.cidoc-crm.org/cidoc-crm/> .
@prefix owl: <http://www.w3.org/2002/07/owl#> .
@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .
@base <http://example.org/tla/ontologies/2023/3/gender-assignment> .

<ex:Gender_Eunuch> rdf:type <crm:E55_Type> ;
                   rdfs:label "Eunuch" .

<ex:Gender_Male> rdf:type crm:E55_Type ;
                 rdfs:label "Male" .

<ex:Ioannes_68> rdf:type crm:E21_Person ;
                rdfs:label "John the Orphanotrophos" .

<ex:Paphlagonian_family> rdf:type crm:E74_Group ;
                         rdfs:label "Family of John, Michael, & brothers" .

<ex:Ioannes_68_gender_birth> rdf:type crm:E17_Type_Assignment ;
                             crm:P14_carried_out_by <ex:Paphlagonian_family> ;
                             crm:P183_ends_before_the_start_of <ex:Ioannes_68_gender_castration> ;
                             crm:P41_classified <ex:Ioannes_68> ;
                             crm:P42_assigned <ex:Gender_Male> ;
                             rdfs:label "Birth gender assignment" .

<ex:Ioannes_68_gender_castration> rdf:type crm:E17_Type_Assignment ;
                                  crm:P14_carried_out_by <ex:Paphlagonian_family> ;
                                  crm:P41_classified <ex:Ioannes_68> ;
                                  crm:P42_assigned <ex:Gender_Eunuch> ;
                                  rdfs:label "Castration gender assignment" .

Here is the same information utilizing quoted triples.

@prefix ex: <http://example.org/tla/ontologies/2023/3/gender-assignment/> .
@prefix crm: <http://www.cidoc-crm.org/cidoc-crm/> .
@prefix owl: <http://www.w3.org/2002/07/owl#> .
@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .
@base <http://example.org/tla/ontologies/2023/3/gender-assignment> .

<ex:Gender_Eunuch> rdf:type <crm:E55_Type> ;
                   rdfs:label "Eunuch" .

<ex:Gender_Male> rdf:type crm:E55_Type ;
                 rdfs:label "Male" .

<ex:Ioannes_68> rdf:type crm:E21_Person ;
                rdfs:label "John the Orphanotrophos" .

<ex:Paphlagonian_family> rdf:type crm:E74_Group ;
                         rdfs:label "Family of John, Michael, & brothers" .

<< ex:Ioannes_68 rdf:type ex:Gender_Male >> crm:P14_carried_out_by <ex:Paphlagonian_family> ;
                             crm:P183_ends_before_the_start_of << ex:Ioannes_68 rdf:type ex:Gender_Eunuch >> ;
                             rdfs:label "Birth gender assignment" .

ex:Ioannes_68 rdf:type ex:Gender_Eunuch {| crm:P14_carried_out_by <ex:Paphlagonian_family> ;
                                  rdfs:label "Castration gender assignment" .
rat10 commented 1 year ago

*** Why it is hard or impossible to do what you want to do without quoted triples:

Without quoted triples events have to be represented using something like RDF reification, where there is a node (often a blank node) for the event that is linked to information about the event. The effect of the event is then a separate triple, and the connection between the event and its effect is not part of the RDF model.

Quoted triples don't solve this problem. Annotating a quoted triple annotates all instances/occurrences of that triple. Annotating a RDF standard reification quad annotates a specific instance/occurrence without being able to pinpoint that specific instance in a graph. Creating an identifier for an occurrence of a quoted triple as suggested by the CG report brings you to the exact same place as RDF standard reification.

To better understand the problem contrast that with singleton properties that create an instance and make it possible to annotate that specific instance, whereas the triple type is implicitly defined via the definition of the singleton property and can (or has to be, depending on view point) entailed in an extra step. The effect is that singleton properties always account for the more specific case - instances - at the cost of having to entail the more general case - the abstract type, whereas RDF-star favors the abstract case but demands extra steps to honor the more specific case. As this extra step in RDF-star is optional is incurs the risk of premature optimization and later need to re-model, plus the need to query for both forms. RDF standard reification at least doesn't have that last problem as it enforces the creation of an identifier for each instance/occurrence. It can't refer to the abstract type - if that is a bug or a feature is another discussion this WG needs to have.

Sorry for the long comment but I really think this issue needs to be discussed in depth.

pfps commented 1 year ago

https://github.com/w3c/rdf-ucr/wiki/RDF-star-for-CIDOC-CRM-events has two representations - a naive one where data is hung directly off the quoted triple and a better one where events link to quoted triples.

rat10 commented 1 year ago

Thanks, that's good. However, in the analysis it might also discuss the effects on navigation, updates, querying, reasoning, etc that those two different approaches to modelling have. Of course the examples could also add the TEP mechanism and the analysis could discuss how these examples get much more convoluted under real-world circumstances if the proposed semantics is taken serious. I don't know what the best way to discuss these problems is: they apply to every example. However, discussing them in every example is verbose and tiresome, but discussing them only once might give the impression that they are only peripheral issues

akuckartz commented 1 year ago

I suppose that @tla is interested in discussing this use case.