- From: Nicola Carboni <nic.carboni@gmail.com>
- Date: Thu, 28 Nov 2019 11:15:29 +0100
- To: "Holger Knublauch" <holger@topquadrant.com>, phtyson@sbcglobal.net, "Antoine Zimmermann" <antoine.zimmermann@emse.fr>
- Cc: semantic-web@w3.org
- Message-ID: <76685C40-5942-45A6-A31E-9E8F2EFB4431@gmail.com>
Dear Holger, Paul and Antoine, I realised that my explanations were very far from clarity! Sorry for it! I will try to answer singularly to each of you in this mail. > Holger Knublauch: > In the scenario above, what is the relation between ex:book and :book, > and can you define some rule on how to create one from the other? Is > it "same-local-name-but-different-namespace"? My examples referred to 2 different ontologies which express statements about the same domain. > Holger Knublauch: > I am also unclear whether you want to use alignments to validate > constraints (e.g. "does pattern 2 exist for pattern 1"), or to > construct/infer one pattern out of the other. Just want to infer that the value expressed by the pattern is ontologically equivalent and while searching for one, you should be able to retrieve also the other. > If you want to validate constraints, you could use SHACL-SPARQL > constraints: https://www.w3.org/TR/shacl/#sparql-constraints > If you want to construct target triples, you could use SHACL-AF rules: > https://w3c.github.io/shacl/shacl-af/#rules I did not know you could do such thing! Thank you very much, this is quite useful! > Paul Tyson: > You can write the alignment rules in RIF, then translate them to > SPARQL > and use as needed, either as part of a runtime query, or to > materialize > your own "equivalence" triples (using SPARQL INSERT or CONSTRUCT). > Rules written in RIF are easier to analyze and document, for example > by > expressing them in the RIF XML notation and using XSLT. > I used this approach to align and validate part master and product > structure information in a large dataset derived from different PLM > systems. That's great. I will take a look at it and try to find a way to materialise the alignment rules in SPARQL CONSTRUCT. Do you know have any pointer to some documentation on how to do so? > Antoine Zimmermann: > I wrote these correspondences in an alignment file at: > https://www.emse.fr/~zimmermann/edoal-example.xml > > The alignment format from Inria's alignment API is meant to represent > correspondences in a way independent from how the correspondence may > be used. There are different ways of interpreting and using a > correspondence in an alignment: > > 1. as an ontological axiom > 2. as data transformations > 3. as schema constraints > 4. as "bridge rules" between descriptions of different contexts > > Additionally, ontology alignment correspondences may have a "measure" > assigned to them that can be interpreted as a degree of confidence, or > as a fuzzy value, or as a probability, or something else. They also > have additional metadata that makes it clear that they are relating > something from an ontology to something from another ontology. In > comparison, a logical axiom, even if it uses URIs from different > namespaces, does not make this clear. Thank you very much, that is great and exactly what I was searching for. I found some [tutorials](http://alignapi.gforge.inria.fr/tutorial/tutorial1/index.html) about it and I will try to to make it work. Just want to point out that the SPARQL querying with an alignment section [cannot](http://alignapi.gforge.inria.fr/tutorial/tutorial4/transf) [be](http://alignapi.gforge.inria.fr/tutorial/tutorial4/inst) [found](http://alignapi.gforge.inria.fr/tutorial/tutorial4/merged) ([404](http://alignapi.gforge.inria.fr/tutorial/tutorial4/construct)). Thank you all! Best, Nicola On 27 Nov 2019, at 1:46, Holger Knublauch wrote: > On 27/11/2019 02:55, Nicola Carboni wrote: > >> Dear all, >> >> I am searching for a way to create complex ontological alignments. >> I would like to state that two patterns of type 1-to-n are >> equivalent. >> >> The typical use case I have in mind is the declaration of equivalence >> between a flat statement and a property chain, as in the two patterns >> below: >> >> |@prefix:<http://example.org/>.@prefixex:<http://ontology.org/example>.ex:bookex:hasauthor"John".:book:hasbeencreated:creation_event.:creation_event:carried_out:person.:person:is_identified_by:appellation.:appellationrdfs:label"John".| > > In the scenario above, what is the relation between ex:book and :book, > and can you define some rule on how to create one from the other? Is > it "same-local-name-but-different-namespace"? > > If ex:book and :book are identical then a SHACL sh:equals constraint > can be used > > ex:BookShape > a sh:NodeShape ; > sh:property [ > sh:path ( :hasbeencreated :carried_out > :is_identified_by rdfs:label ) ; > sh:equals ex:hasauthor ; > ] . > > https://www.w3.org/TR/shacl/#EqualsConstraintComponent > > Note that SHACL includes a syntax for SPARQL-like property path > expressions, and the value of sh:path above is a property chain > (represented as a simple rdf:List). Other types of paths are supported > too: https://www.w3.org/TR/shacl/#property-paths > >> another important type of equivalence, but slightly different, which >> I would like to declare is the one between these two patterns: >> >> |@prefix:<http://example.org/>.@prefixex:<http://ontology.org/example>.ex:Architectrdfs:label"John".:Person:classifiedAs<http://vocab.getty.edu/aat/300024987>;rdfs:label"John".<http://vocab.getty.edu/aat/300024987>agvp:Concept;rdfs:label"architects"@en.| >> >> The first one declare an instance of the class Artist according to an >> ontology(x), the second classify as artist, using a controlled >> vocabulary term, an instance of a person declared using the ontology >> (y). >> >> Do you know how can I express such alignments? >> > I am also unclear whether you want to use alignments to validate > constraints (e.g. "does pattern 2 exist for pattern 1"), or to > construct/infer one pattern out of the other. > > The complexity of the scenario above indicates that you may want to > use SPARQL, because then you can more easily look up values through > matches, e.g. to match "architects"@en to ex:Architect using some > look-up table, and because SPARQL gives you a maximum of > expressiveness. > > - If you want to validate constraints, you could use SHACL-SPARQL > constraints: https://www.w3.org/TR/shacl/#sparql-constraints > > - If you want to construct target triples, you could use SHACL-AF > rules: https://w3c.github.io/shacl/shacl-af/#rules > > Hope this helps, a bit... > Holger
Received on Thursday, 28 November 2019 10:15:37 UTC