Skip to content

Commit

Permalink
added queries from caseologue for testing in the control room
Browse files Browse the repository at this point in the history
  • Loading branch information
Claire Rioualen committed May 24, 2024
1 parent caf4de2 commit f5e0e87
Show file tree
Hide file tree
Showing 9 changed files with 203 additions and 0 deletions.
21 changes: 21 additions & 0 deletions src/webapp/queries/end_dot_def_missing.rq
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
PREFIX obo: <http://purl.obolibrary.org/obo/>
PREFIX owl: <http://www.w3.org/2002/07/owl#>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
PREFIX oboInOwl: <http://www.geneontology.org/formats/oboInOwl#>
PREFIX edam:<http://edamontology.org/>
PREFIX xsd: <http://www.w3.org/2001/XMLSchema#>

SELECT DISTINCT ?entity ?property ?def ?label WHERE {
VALUES ?property {oboInOwl:hasDefinition}
?entity ?property ?def .
?entity rdfs:label ?label .

FILTER NOT EXISTS {
FILTER REGEX(str(?def), "['.']+$")
}
FILTER (!isBlank(?def))

}
ORDER BY ?entity

19 changes: 19 additions & 0 deletions src/webapp/queries/end_dot_label.rq
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
PREFIX obo: <http://purl.obolibrary.org/obo/>
PREFIX owl: <http://www.w3.org/2002/07/owl#>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
PREFIX oboInOwl: <http://www.geneontology.org/formats/oboInOwl#>
PREFIX edam:<http://edamontology.org/>
PREFIX xsd: <http://www.w3.org/2001/XMLSchema#>

SELECT DISTINCT ?entity ?property ?value ?label WHERE {
VALUES ?property {rdfs:label}
?entity ?property ?value .
?entity rdfs:label ?label .

FILTER REGEX(str(?value), "['.']+$")
FILTER (!isBlank(?entity))

}
ORDER BY ?entity

18 changes: 18 additions & 0 deletions src/webapp/queries/end_space_annotation.rq
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
PREFIX obo: <http://purl.obolibrary.org/obo/>
PREFIX owl: <http://www.w3.org/2002/07/owl#>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
PREFIX oboInOwl: <http://www.geneontology.org/formats/oboInOwl#>
PREFIX edam:<http://edamontology.org/>
PREFIX xsd: <http://www.w3.org/2001/XMLSchema#>

SELECT DISTINCT ?entity ?property ?value ?label WHERE {
?entity ?property ?value .
?entity rdfs:label ?label .

FILTER REGEX(str(?value), "[\\s\r\n]+$")
FILTER (!isBlank(?entity))

}
ORDER BY ?entity

17 changes: 17 additions & 0 deletions src/webapp/queries/eol_in_annotation.rq
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
PREFIX obo: <http://purl.obolibrary.org/obo/>
PREFIX owl: <http://www.w3.org/2002/07/owl#>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
PREFIX oboInOwl: <http://www.geneontology.org/formats/oboInOwl#>
PREFIX edam:<http://edamontology.org/>
PREFIX xsd: <http://www.w3.org/2001/XMLSchema#>

SELECT DISTINCT ?entity ?property ?value ?label WHERE {
?entity ?property ?value .
?entity rdfs:label ?label .
FILTER regex(?value, "\n")
FILTER (!isBlank(?entity))

}
ORDER BY ?entity

15 changes: 15 additions & 0 deletions src/webapp/queries/get_uri.rq
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
PREFIX obo: <http://purl.obolibrary.org/obo/>
PREFIX owl: <http://www.w3.org/2002/07/owl#>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
PREFIX oboInOwl: <http://www.geneontology.org/formats/oboInOwl#>
PREFIX edam:<http://edamontology.org/>
PREFIX xsd: <http://www.w3.org/2001/XMLSchema#>

SELECT DISTINCT ?entity ?label WHERE {

?entity a owl:Class .
OPTIONAL {?entity rdfs:label ?label .}

}
ORDER BY ?entity
38 changes: 38 additions & 0 deletions src/webapp/queries/literal_links.rq
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
PREFIX obo: <http://purl.obolibrary.org/obo/>
PREFIX owl: <http://www.w3.org/2002/07/owl#>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
PREFIX oboInOwl: <http://www.geneontology.org/formats/oboInOwl#>
PREFIX edam:<http://edamontology.org/>
PREFIX xsd: <http://www.w3.org/2001/XMLSchema#>

SELECT DISTINCT ?entity ?property ?label ?value WHERE {
VALUES ?property {
<http://edamontology.org/citation>
<http://edamontology.org/documentation>
<http://edamontology.org/information_standard>
<http://edamontology.org/oldParent>
<http://edamontology.org/ontology_used>
<http://edamontology.org/organisation>
<http://www.geneontology.org/formats/oboInOwl#consider>
<http://www.geneontology.org/formats/oboInOwl#inSubset>
<http://www.geneontology.org/formats/oboInOwl#replacedBy>
<http://www.w3.org/2000/01/rdf-schema#seeAlso>
<http://www.w3.org/2000/01/rdf-schema#subClassOf>
<http://www.w3.org/2000/01/rdf-schema#subPropertyOf>
<http://www.w3.org/2002/07/owl#annotatedProperty>
<http://www.w3.org/2002/07/owl#inverseOf>
<http://www.w3.org/2002/07/owl#disjointWith>
<http://www.w3.org/2000/01/rdf-schema#domain>
<http://www.w3.org/2000/01/rdf-schema#range>


}

?entity ?property ?value .

FILTER isLiteral(?value)
?entity rdfs:label ?label .

}
ORDER BY ?entity
37 changes: 37 additions & 0 deletions src/webapp/queries/mandatory_property_missing.rq
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
PREFIX obo: <http://purl.obolibrary.org/obo/>
PREFIX owl: <http://www.w3.org/2002/07/owl#>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
PREFIX oboInOwl: <http://www.geneontology.org/formats/oboInOwl#>
PREFIX edam:<http://edamontology.org/>
PREFIX xsd: <http://www.w3.org/2001/XMLSchema#>

SELECT DISTINCT ?entity ?property ?label ?property_subs_edam WHERE {

VALUES ?property {oboInOwl:hasDefinition
edam:created_in
#oboInOwl:inSubset
rdfs:label
rdfs:subClassOf }
?entity a owl:Class .

FILTER NOT EXISTS {?entity owl:deprecated true .}
OPTIONAL {?entity rdfs:label ?label .}
FILTER ( ?entity != <http://edamontology.org/data_0006>)
FILTER ( ?entity != <http://edamontology.org/topic_0003>)
FILTER ( ?entity != <http://www.w3.org/2002/07/owl#DeprecatedClass>)
FILTER ( ?entity != <http://edamontology.org/operation_0004>)
FILTER ( ?entity != <http://edamontology.org/format_1915>)

FILTER NOT EXISTS {?entity ?property ?value .
MINUS { ?value rdf:type owl:Restriction .} #to prevent concept with rdfs:subClassOf property being only restriction (e.g. has_topic)
}
FILTER (!isBlank(?entity))
# UNION
# {
# VALUES ?property { oboInOwl:inSubset
# }
# FILTER NOT EXISTS {?entity ?property <http://purl.obolibrary.org/obo/edam#edam> .}
# }
}
ORDER BY ?entity
18 changes: 18 additions & 0 deletions src/webapp/queries/start_space_annotation.rq
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
PREFIX obo: <http://purl.obolibrary.org/obo/>
PREFIX owl: <http://www.w3.org/2002/07/owl#>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
PREFIX oboInOwl: <http://www.geneontology.org/formats/oboInOwl#>
PREFIX edam:<http://edamontology.org/>
PREFIX xsd: <http://www.w3.org/2001/XMLSchema#>

SELECT DISTINCT ?entity ?property ?value ?label WHERE {
?entity ?property ?value .
?entity rdfs:label ?label .
FILTER REGEX(str(?value), "^[\\s\r\n]+")
FILTER (!isBlank(?entity))

}
ORDER BY ?entity


20 changes: 20 additions & 0 deletions src/webapp/queries/tab_in_annotation.rq
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
PREFIX obo: <http://purl.obolibrary.org/obo/>
PREFIX owl: <http://www.w3.org/2002/07/owl#>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
PREFIX oboInOwl: <http://www.geneontology.org/formats/oboInOwl#>
PREFIX edam:<http://edamontology.org/>
PREFIX xsd: <http://www.w3.org/2001/XMLSchema#>

SELECT DISTINCT ?entity ?property ?value ?label WHERE {
?entity ?property ?value .
?entity rdfs:label ?label .

FILTER regex(?value, "\t")
FILTER (!isBlank(?entity))

}
ORDER BY ?entity



0 comments on commit f5e0e87

Please sign in to comment.