Semantic-Data-for-Humanities / SDHSS-modelling-best-practices

This repository is dedicated to sharing modelling issues, discussions, solutions and the definition of best practices
Creative Commons Attribution Share Alike 4.0 International
2 stars 0 forks source link

Importing owl:Restrictions into OntoME (RiC-O 1.0) #14

Closed MPica closed 8 months ago

MPica commented 9 months ago

49 Classes in RiC-O 1.0 have owl:Restrictions attached to their rdfs:subClassOf or owl:equivalentClass. This kind of information is completely absent from the script as of yet. We need to decide whether to import this information, and in what shape. @valamercery @stephenhart8, I believe you are the best informed.

One example

Here is the same example in the original XML and a TTL conversion for convenience.

<owl:Class rdf:about="https://www.ica.org/standards/RiC/ontology#CreationRelation">
        <owl:equivalentClass>
            <owl:Restriction>
                <owl:onProperty rdf:resource="https://www.ica.org/standards/RiC/ontology#creationRelation_role"/>
                <owl:hasSelf rdf:datatype="http://www.w3.org/2001/XMLSchema#boolean">true</owl:hasSelf>
            </owl:Restriction>
        </owl:equivalentClass>
        <rdfs:subClassOf rdf:resource="https://www.ica.org/standards/RiC/ontology#OrganicProvenanceRelation"/>
        <rdfs:subClassOf>
            <owl:Restriction>
                <owl:onProperty rdf:resource="https://www.ica.org/standards/RiC/ontology#relationHasSource"/>
                <owl:minQualifiedCardinality rdf:datatype="http://www.w3.org/2001/XMLSchema#nonNegativeInteger">1</owl:minQualifiedCardinality>
                <owl:onClass>
                    <owl:Class>
                        <owl:unionOf rdf:parseType="Collection">
                            <rdf:Description rdf:about="https://www.ica.org/standards/RiC/ontology#Instantiation"/>
                            <rdf:Description rdf:about="https://www.ica.org/standards/RiC/ontology#RecordResource"/>
                        </owl:unionOf>
                    </owl:Class>
                </owl:onClass>
            </owl:Restriction>
        </rdfs:subClassOf>
        <rdfs:subClassOf>
            <owl:Restriction>
                <owl:onProperty rdf:resource="https://www.ica.org/standards/RiC/ontology#relationHasTarget"/>
                <owl:minQualifiedCardinality rdf:datatype="http://www.w3.org/2001/XMLSchema#nonNegativeInteger">1</owl:minQualifiedCardinality>
                <owl:onClass rdf:resource="https://www.ica.org/standards/RiC/ontology#Agent"/>
            </owl:Restriction>
        </rdfs:subClassOf>
        <rdfs:comment xml:lang="en">Connects at least one Record Resource or Instantiation to at
            least one Agent, when the Agent is either responsible for all or some of the content of
            the Record Resource, or is a contributor to the genesis or production of the
            Instantiation.</rdfs:comment>
        <rdfs:isDefinedBy rdf:resource="https://www.ica.org/standards/RiC/ontology"/>
        <rdfs:label xml:lang="en">Creation Relation</rdfs:label>
        <rdfs:label xml:lang="fr">Relation de création</rdfs:label>
        <rdfs:label xml:lang="es">Relación de creación</rdfs:label>
        <skos:scopeNote xml:lang="en">Covers the definition of "author" in diplomatics, and any
            agent that makes a contribution to the intellectual content of a record resource. Can
            also be used for any agent that was involved in the genesis (e.g. with the role of
            witness, representative of the author etc.) or in the production (e.g. with the role of
            scribe, secretary, notary, printer etc.) of the record resource or
            instantiation.</skos:scopeNote>
        <RiCCMCorrespondingComponent xml:lang="en">Class implementation of RiC-R027 and RiC-R027i relations</RiCCMCorrespondingComponent>
    </owl:Class>
:CreationRelation a owl:Class ;
    rdfs:label "Creation Relation"@en,
        "Relación de creación"@es,
        "Relation de création"@fr ;
    rdfs:comment """Connects at least one Record Resource or Instantiation to at
            least one Agent, when the Agent is either responsible for all or some of the content of
            the Record Resource, or is a contributor to the genesis or production of the
            Instantiation."""@en ;
    rdfs:isDefinedBy <https://www.ica.org/standards/RiC/ontology> ;
    rdfs:subClassOf [ a owl:Restriction ;
            owl:minQualifiedCardinality "1"^^xsd:nonNegativeInteger ;
            owl:onClass :Agent ;
            owl:onProperty :relationHasTarget ],
        [ a owl:Restriction ;
            owl:minQualifiedCardinality "1"^^xsd:nonNegativeInteger ;
            owl:onClass [ a owl:Class ;
                    owl:unionOf ( :Instantiation :RecordResource ) ] ;
            owl:onProperty :relationHasSource ],
        :OrganicProvenanceRelation ;
    owl:equivalentClass [ a owl:Restriction ;
            owl:hasSelf true ;
            owl:onProperty :creationRelation_role ] ;
    skos:changeNote [ dc:date "2023-04-19" ;
            rdf:value "Removed a 0.2 existing unnecessary restriction."@en ],
        [ dc:date "2023-11-08" ;
            rdf:value """In order to get a system of rolified Relation classes:
                    added an equivalentClass object property; replaced the specific object
                    properties by the generic ones in the subClassOf declarations."""@en ],
        [ dc:date "2023-11-12" ;
            rdf:value """Aligned with RiC-CM 1.0: updated the
                    skos:scopeNote."""@en ],
        [ dc:date "2023-08-25" ;
            rdf:value "Added a new rdfs:label in French."@en ],
        [ dc:date "2023-11-02" ;
            rdf:value "Added a new rdfs:label in Spanish."@en ] ;
    skos:scopeNote """Covers the definition of "author" in diplomatics, and any
            agent that makes a contribution to the intellectual content of a record resource. Can
            also be used for any agent that was involved in the genesis (e.g. with the role of
            witness, representative of the author etc.) or in the production (e.g. with the role of
            scribe, secretary, notary, printer etc.) of the record resource or
            instantiation."""@en ;
    :RiCCMCorrespondingComponent """Class implementation of RiC-R027 and RiC-R027i
            relations"""@en .

The current possibilities

The import schema has the following possibilities (as of now):

For Classes:

For Properties:

valamercery commented 9 months ago

As expressed in its overview, OWL is a computational logic-based language such that knowledge expressed in OWL can be exploited by computer programs.

OntoME is not a GUI for OWL but a tool for designing ontologies. As a result, the constraints imposed by the owl:restrictions property must be explicitly modelled in the development of the model.

So I don't think it makes sense to import these restrictions into OntoME.