snikproject / ontology

Public SNIK Ontology. An ontology of information management in hospitals.
https://snikproject.github.io/ontology/
Other
10 stars 1 forks source link

Fix or delete axioms with broken subjects or objects #297

Open KonradHoeffner opened 5 years ago

KonradHoeffner commented 5 years ago
select *
{
 ?x owl:annotatedSource|owl:annotatedTarget ?o.
 MINUS {?o a ?something.}
}

There are 16 axioms where either the source or the target doesn't exist anymore, try to save them in case there was a renaming, otherwise delete them.

KonradHoeffner commented 4 years ago

brokenaxioms.ttl.txt brokenaxioms_bb.ttl.txt brokenaxioms_he.ttl.txt brokenaxioms_ob.ttl.txt

KonradHoeffner commented 4 years ago

I deleted them using the following query but there were 144 triples deleted from he which I didn't expect so I restored the backup and will investigate this first to be sure.

sparql
delete 
{
 ?x ?p ?o.
}
from <http://www.snik.eu/ontology/bb>
{
 ?x ?p ?o.
 filter(?p=owl:annotatedSource OR ?p=owl:annotatedTarget)
 MINUS {?o a ?something.}
}
KonradHoeffner commented 4 years ago

The problem with he comes from it being cut into two parts, he and he-unconsolidated.

KonradHoeffner commented 4 years ago

The following classes in he are not existing:

http://www.snik.eu/ontology/he/ITStrategie http://www.snik.eu/ontology/he/angebotsorientierterAnsatz http://www.snik.eu/ontology/he/QuantitativeMessgroesse http://www.snik.eu/ontology/he/StrategischerErfolgsfaktor http://www.snik.eu/ontology/he/Vogehensmodell http://www.snik.eu/ontology/he/CIO http://www.snik.eu/ontology/he/administrativeAufgabe http://www.snik.eu/ontology/he/SituationsanalyseVogehensweise

KonradHoeffner commented 4 years ago

I put he-unconsolidated back in the snik graph group so that it is shown in LodView.

KonradHoeffner commented 4 years ago

OK, let's investigate this more thoroughly:

Select triples that should be deleted if there isn't a way to correct the object:


select ?x ?y ?z
{
 ?x ?y ?z.
{select ?x
{
 ?x owl:annotatedSource|owl:annotatedTarget ?o.
 MINUS {?o a ?something.}
}}
} order by ?x

Create a backup.

Select just the objects, go through them and see if we can fix some of them:

select distinct ?o
{
 ?x owl:annotatedSource|owl:annotatedTarget ?o.
 MINUS {?o a ?something.}
}
KonradHoeffner commented 4 years ago

he:CIO

he:CIO exists as he:ChiefInformationOfficer, so correct this renaming as well:

SPARQL
with <http://www.snik.eu/ontology/he> # "with" specifies the graph that the query modifies
delete
{
?x ?p <http://www.snik.eu/ontology/he/CIO> . # delete our original triple
}
insert
{
?x ?p <http://www.snik.eu/ontology/he/ChiefInformationOfficer> . # insert the new triple
}
where
{
?x ?p <http://www.snik.eu/ontology/he/CIO> . # again our original triple
}
SPARQL
with <http://www.snik.eu/ontology/he-unconsolidated> # "with" specifies the graph that the query modifies
delete
{
?x ?p <http://www.snik.eu/ontology/he/CIO> . # delete our original triple
}
insert
{
?x ?p <http://www.snik.eu/ontology/he/ChiefInformationOfficer> . # insert the new triple
}
where
{
?x ?p <http://www.snik.eu/ontology/he/CIO> . # again our original triple
}

Also fixed a typo in the skos:definition.

KonradHoeffner commented 4 years ago

he: ITStrategie done

he:ITStrategie exists as he/ItStrategie, it was probably just renamed improperly, so fix this by renaming again in both he-graphs. This one was the one that actually changed things:

SPARQL
with <http://www.snik.eu/ontology/he> # "with" specifies the graph that the query modifies
delete
{
?x ?p <http://www.snik.eu/ontology/he/ITStrategie> . # delete our original triple
}
insert
{
?x ?p <http://www.snik.eu/ontology/he/ItStrategie> . # insert the new triple
}
where
{
?x ?p <http://www.snik.eu/ontology/he/ITStrategie> . # again our original triple
}
KonradHoeffner commented 4 years ago

ob:DelphiStudy done

ob:DelphiStudy wurde in https://github.com/IMISE/snik-ontology/issues/58 in ob:DelphiMethod gemerged, wobei die Objekte wohl vergessen wurden. Daher auch hier ein rename durchführen, aber auf beiden Seiten:

SPARQL
with <http://www.snik.eu/ontology/ob> # "with" specifies the graph that the query modifies
delete
{
?x ?y <http://www.snik.eu/ontology/ob/DelphiStudy>  . # delete our original triple
}
insert
{
?x ?y <http://www.snik.eu/ontology/ob/DelphiMethod> . # insert the new triple
}
where
{
?x ?y <http://www.snik.eu/ontology/ob/DelphiStudy> . # again our original triple
}
SPARQL
with <http://www.snik.eu/ontology/ob> # "with" specifies the graph that the query modifies
delete
{
<http://www.snik.eu/ontology/ob/DelphiStudy> ?p ?o . # delete our original triple
}
insert
{
<http://www.snik.eu/ontology/ob/DelphiMethod> ?p ?o . # insert the new triple
}
where
{
<http://www.snik.eu/ontology/ob/DelphiStudy> ?p ?o . # again our original triple
}
KonradHoeffner commented 4 years ago

bb:San done

http://www.snik.eu/ontology/bb/San existiert nicht in anderer Schreibweise im bb. Es wurde aber in der Issue https://github.com/IMISE/snik-ontology/issues/214 in bb:StorageAreaNetwork gemerged. Dabei wurde aber anscheinend die Objektquery vergessen. Habe dazu jetzt noch einen Hinweis hinzugefügt im Wiki unter https://wiki.imise.uni-leipzig.de/Projekte/SNIK/ontologie/sparul.

KonradHoeffner commented 4 years ago

bb:ISO25000 done

select *
{
graph ?g
{
{bb:ISO25000 ?p ?o.}
UNION
{?s ?p bb:ISO25000.}
}
}

It doesn't show up in any issue but there is https://www.snik.eu/ontology/bb/ISO25000SoftwareQuality. Is this the same concept? After some investigation I believe it is and will merge it.

SPARQL
with <http://www.snik.eu/ontology/bb> # "with" specifies the graph that the query modifies
delete
{
?x ?y <http://www.snik.eu/ontology/bb/ISO25000>  . # delete our original triple
}
insert
{
?x ?y <http://www.snik.eu/ontology/bb/ISO25000SoftwareQuality> . # insert the new triple
}
where
{
?x ?y <http://www.snik.eu/ontology/bb/ISO25000> . # again our original triple
}
SPARQL
with <http://www.snik.eu/ontology/bb> # "with" specifies the graph that the query modifies
delete
{
<http://www.snik.eu/ontology/bb/ISO25000> ?x ?y . # delete our original triple
}
insert
{
<http://www.snik.eu/ontology/bb/ISO25000SoftwareQuality> ?x ?y . # insert the new triple
}
where
{
<http://www.snik.eu/ontology/bb/ISO25000> ?x ?y . # again our original triple
}
KonradHoeffner commented 4 years ago

he:QuantitativeMessgroesse

select *
{
graph ?g
{
{he:QuantitativeMessgroesse ?p ?o.}
UNION
{?s ?p he:QuantitativeMessgroesse.}
}
}

It isn't mentioned in any other issue and I also don't see a similar one in the search. But we can't just delete it because it is the superclass of he:Leistungsdifferenz. I created a new issue at https://github.com/IMISE/snik-ontology/issues/328 for that one, maybe Birgit knows more about this.

KonradHoeffner commented 4 years ago

he:SituationsanalyseVogehensweise

@BirgitSNIK There is a typo in the URL but he:SituationsanalyseVorgehensweise does not exist. he:Situationsanalyse does exist however, is this the same concept?

select *
{
graph ?g
{
{he:SituationsanalyseVogehensweise ?p ?o.}
UNION
{?s ?p he:SituationsanalyseVogehensweise.}
}
}
g p o s
http://www.snik.eu/ontology/he http://www.w3.org/2000/01/rdf-schema#subClassOf   http://www.snik.eu/ontology/he/SchnittstellenOptimieren
http://www.snik.eu/ontology/he http://www.w3.org/2002/07/owl#annotatedTarget   http://www.snik.eu/ontology/he/axiomdc34b8c75da59a850f9106c8613c012c
KonradHoeffner commented 4 years ago

http://www.snik.eu/ontology/he/Vogehensmodell done

This one is just a typo of he:Vorgehensmodell in he, so I corrected it.

select *
{
graph ?g
{
{he:Vogehensmodell ?p ?o.}
UNION
{?s ?p he:Vogehensmodell.}
}
}
g p o s
http://www.snik.eu/ontology/he http://www.w3.org/2000/01/rdf-schema#subClassOf   http://www.snik.eu/ontology/he/TOGAFArchitectureDevolopmentMethod
http://www.snik.eu/ontology/he http://www.w3.org/2002/07/owl#annotatedTarget   http://www.snik.eu/ontology/he/axiom7de2381c81976ead4ee0ce86ee9e0696
KonradHoeffner commented 4 years ago

https://www.snik.eu/ontology/he/administrativeAufgabe

Looks like a typo but https://www.snik.eu/ontology/he/AdministrativeAufgabe does not exist. There is however http://www.snik.eu/ontology/he/AdministrativeFuehrungsaufgabe. Also, according to the unconsolidated part, he:administrativeAufgabe is a subclass of he:Technologiebeschaffung. So, @BirgitSNIK : What do we do?

KonradHoeffner commented 4 years ago

http://www.snik.eu/ontology/he/angebotsorientierterAnsatz done

Das ist wirklich nur ein Großschreibungsfehler. Korrigiere angebots... zu Angebots...

KonradHoeffner commented 4 years ago

http://www.snik.eu/ontology/he/StrategischerErfolgsfaktor

@BirgitSNIK: Ist das das gleiche wie Kritischer Wettbewerbsfaktor, soll ich das zusammenlegen? Oder fällt das einfach weg?

KonradHoeffner commented 4 years ago

@BirgitSNIK: Am besten, wir setzen uns da mal zusammen, um das zu besprechen.