KnowWhereGraph / KWG-SHACL

This is the repository of SHACL shapes development/research for KWG.
1 stars 1 forks source link

shape for inverse path #2

Open gengchenmai opened 2 years ago

gengchenmai commented 2 years ago

For sosa:ObservableProperty

I see that one restriction is the domain of sosa:observedProperty should be sosa:Observation : inverse Of sosa:observedProperty ONLY sosa:Observation

I am not sure how to express this inverse path in SHACL. I see a shLinversPath. But I think it has a different meaning.

zhurui0509 commented 2 years ago

I think this is included in the ObservationConstraint.

gengchenmai commented 2 years ago

I know what you mean. But I think they are different. We say if the subject is an instance of sosa:Observation, the predicate is sosa:observedProperty, then the object should be an instance of sosa:ObservableProperty.

This is different from we say - if the object is an instance of sosa:ObservableProperty, the predicate is sosa:observedProperty, then the subject should be an instance of sosa:Observation.

cogan-shimizu commented 2 years ago

my understanding is that the sh:inversePath is the correct term to use here.

inverse Of sosa:observedProperty ONLY sosa:Observation

would translate to

sh:property [
    sh:path [sh:inversePath sosa:observedProperty] ;
    rdfs:comment "";
    sh:class sosa:Observation ;
]