Skip to content

Commit

Permalink
Add ontologies, update query expansion rules
Browse files Browse the repository at this point in the history
  • Loading branch information
amoeba committed Aug 12, 2022
1 parent fdb1a53 commit 28cbf91
Show file tree
Hide file tree
Showing 9 changed files with 164,524 additions and 28 deletions.
69 changes: 41 additions & 28 deletions src/main/resources/application-context-ontology-model-service.xml
Original file line number Diff line number Diff line change
@@ -1,7 +1,4 @@
<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:p="http://www.springframework.org/schema/p"
xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd">
<beans xmlns="http://www.springframework.org/schema/beans" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:p="http://www.springframework.org/schema/p" xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd">

<bean id="ontologyModelService" class="org.dataone.cn.indexer.annotation.OntologyModelService">
<property name="fieldList">
Expand All @@ -11,7 +8,7 @@
</list>
</property>

<property name="ontologyList">
<property name="ontologyList">
<list>
<value>http://purl.dataone.org/ontologies/observation/d1-ECSO.owl</value>
<value>http://purl.dataone.org/ontologies/provenance/ProvONE/v1/owl/provone.owl</value>
Expand All @@ -29,6 +26,13 @@
<value>http://ecoinformatics.org/oboe/oboe.1.2/oboe-chemistry.owl</value>
<value>http://ecoinformatics.org/oboe/oboe.1.2/oboe-anatomy.owl</value>
<value>http://ecoinformatics.org/oboe-ext/sbclter.1.0/oboe-sbclter.owl</value>
<value>https://purl.dataone.org/odo/MOSAIC_</value>
<value>http://purl.dataone.org/odo/ARCRC</value>
<value>https://purl.dataone.org/odo/ADCAD_</value>
<value>http://purl.dataone.org/odo/SENSO_</value>
<value>http://purl.dataone.org/odo/SALMON_</value>
<value>http://purl.dataone.org/odo/SALMON_alignment_</value>
<value>http://purl.dataone.org/odo/SASAP_</value>
</list>
</property>

Expand All @@ -37,24 +41,31 @@

<bean id="alt.entries" class="java.util.HashMap">
<constructor-arg>
<map key-type="java.lang.String" value-type="java.lang.String">
<entry key="http://purl.dataone.org/ontologies/observation/d1-ECSO.owl" value="file:src/main/resources/ontologies/ECSO.owl" />
<entry key="http://purl.dataone.org/ontologies/provenance/ProvONE/v1/owl/provone.owl" value="file:src/main/resources/ontologies/provone.owl" />
<entry key="http://purl.obolibrary.org/obo/envo.owl" value="file:src/main/resources/ontologies/envo.owl" />
<entry key="http://ecoinformatics.org/oboe/oboe.1.2/oboe-owl.owl" value="file:src/main/resources/ontologies/oboe.owl" />
<entry key="http://ecoinformatics.org/oboe/oboe.1.2/oboe-core.owl" value="file:src/main/resources/ontologies/oboe-core.owl" />
<entry key="http://ecoinformatics.org/oboe/oboe.1.2/oboe-characteristics.owl" value="file:src/main/resources/ontologies/oboe-characteristics.owl" />
<entry key="http://ecoinformatics.org/oboe/oboe.1.2/oboe-standards.owl" value="file:src/main/resources/ontologies/oboe-standards.owl" />
<entry key="http://ecoinformatics.org/oboe/oboe.1.2/oboe-spatial.owl" value="file:src/main/resources/ontologies/oboe-spatial.owl" />
<entry key="http://ecoinformatics.org/oboe/oboe.1.2/oboe-temporal.owl" value="file:src/main/resources/ontologies/oboe-temporal.owl" />
<entry key="http://ecoinformatics.org/oboe/oboe.1.2/oboe-taxa.owl" value="file:src/main/resources/ontologies/oboe-taxa.owl" />
<entry key="http://ecoinformatics.org/oboe/oboe.1.2/oboe-biology.owl" value="file:src/main/resources/ontologies/oboe-biology.owl" />
<entry key="http://ecoinformatics.org/oboe/oboe.1.2/oboe-ecology.owl" value="file:src/main/resources/ontologies/oboe-ecology.owl" />
<entry key="http://ecoinformatics.org/oboe/oboe.1.2/oboe-environment.owl" value="file:src/main/resources/ontologies/oboe-environment.owl" />
<entry key="http://ecoinformatics.org/oboe/oboe.1.2/oboe-chemistry.owl" value="file:src/main/resources/ontologies/oboe-chemistry.owl" />
<entry key="http://ecoinformatics.org/oboe/oboe.1.2/oboe-anatomy.owl" value="file:src/main/resources/ontologies/oboe-anatomy.owl" />
<entry key="http://ecoinformatics.org/oboe-ext/sbclter.1.0/oboe-sbclter.owl" value="file:src/main/resources/ontologies/oboe-sbclter.owl" />
</map>
<map key-type="java.lang.String" value-type="java.lang.String">
<entry key="http://purl.dataone.org/ontologies/observation/d1-ECSO.owl" value="file:src/main/resources/ontologies/ECSO.owl" />
<entry key="http://purl.dataone.org/ontologies/provenance/ProvONE/v1/owl/provone.owl" value="file:src/main/resources/ontologies/provone.owl" />
<entry key="http://purl.obolibrary.org/obo/envo.owl" value="file:src/main/resources/ontologies/envo.owl" />
<entry key="http://ecoinformatics.org/oboe/oboe.1.2/oboe-owl.owl" value="file:src/main/resources/ontologies/oboe.owl" />
<entry key="http://ecoinformatics.org/oboe/oboe.1.2/oboe-core.owl" value="file:src/main/resources/ontologies/oboe-core.owl" />
<entry key="http://ecoinformatics.org/oboe/oboe.1.2/oboe-characteristics.owl" value="file:src/main/resources/ontologies/oboe-characteristics.owl" />
<entry key="http://ecoinformatics.org/oboe/oboe.1.2/oboe-standards.owl" value="file:src/main/resources/ontologies/oboe-standards.owl" />
<entry key="http://ecoinformatics.org/oboe/oboe.1.2/oboe-spatial.owl" value="file:src/main/resources/ontologies/oboe-spatial.owl" />
<entry key="http://ecoinformatics.org/oboe/oboe.1.2/oboe-temporal.owl" value="file:src/main/resources/ontologies/oboe-temporal.owl" />
<entry key="http://ecoinformatics.org/oboe/oboe.1.2/oboe-taxa.owl" value="file:src/main/resources/ontologies/oboe-taxa.owl" />
<entry key="http://ecoinformatics.org/oboe/oboe.1.2/oboe-biology.owl" value="file:src/main/resources/ontologies/oboe-biology.owl" />
<entry key="http://ecoinformatics.org/oboe/oboe.1.2/oboe-ecology.owl" value="file:src/main/resources/ontologies/oboe-ecology.owl" />
<entry key="http://ecoinformatics.org/oboe/oboe.1.2/oboe-environment.owl" value="file:src/main/resources/ontologies/oboe-environment.owl" />
<entry key="http://ecoinformatics.org/oboe/oboe.1.2/oboe-chemistry.owl" value="file:src/main/resources/ontologies/oboe-chemistry.owl" />
<entry key="http://ecoinformatics.org/oboe/oboe.1.2/oboe-anatomy.owl" value="file:src/main/resources/ontologies/oboe-anatomy.owl" />
<entry key="http://ecoinformatics.org/oboe-ext/sbclter.1.0/oboe-sbclter.owl" value="file:src/main/resources/ontologies/oboe-sbclter.owl" />
<entry key="https://purl.dataone.org/odo/MOSAIC_" value="file:src/main/resources/ontologies/MOSAiC.owl" />
<entry key="http://purl.dataone.org/odo/ARCRC" value="file:src/main/resources/ontologies/ARCRC.owl" />
<entry key="https://purl.dataone.org/odo/ADCAD_" value="file:src/main/resources/ontologies/ADCAD.owl" />
<entry key="http://purl.dataone.org/odo/SENSO_" value="file:src/main/resources/ontologies/SENSO.owl" />
<entry key="http://purl.dataone.org/odo/SALMON_" value="file:src/main/resources/ontologies/SALMON.owl" />
<entry key="http://purl.dataone.org/odo/SALMON_alignment_" value="file:src/main/resources/ontologies/SALMON_alignment.owl" />
<entry key="http://purl.dataone.org/odo/SASAP_" value="file:src/main/resources/ontologies/SASAP.owl" />
</map>
</constructor-arg>
</bean>

Expand All @@ -69,7 +80,7 @@
SELECT ?annotation_property_uri
WHERE {
<$CONCEPT_URI> rdfs:subPropertyOf* ?annotation_property_uri .
<$CONCEPT_URI> (owl:equivalentProperty|^owl:equivalentProperty)*/rdfs:subPropertyOf* ?annotation_property_uri .
}
]]>
</value>
Expand All @@ -84,12 +95,14 @@
PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX owl: <http://www.w3.org/2002/07/owl#>
PREFIX skos: <http://www.w3.org/2004/02/skos/core#>
SELECT ?annotation_value_uri
WHERE {
<$CONCEPT_URI> rdfs:subClassOf* ?annotation_value_uri .
}
]]>
WHERE
{
<$CONCEPT_URI> (rdf:type|(owl:equivalentClass|^owl:equivalentClass)*|(owl:sameAs|^owl:sameAs)*|(skos:exactMatch|^skos:exactMatch)*)/rdfs:subClassOf* ?annotation_value_uri .
}
]]>
</value>
</constructor-arg>
</bean>
Expand Down
Loading

0 comments on commit 28cbf91

Please sign in to comment.