Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/qc.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ jobs:
ontology_qc:
# The type of runner that the job will run on
runs-on: ubuntu-latest
container: obolibrary/odkfull:v1.6
container: obolibrary/odkfull:v1.6.1

# Steps represent a sequence of tasks that will be executed as part of the job
steps:
Expand Down
2 changes: 2 additions & 0 deletions docs/odk-workflows/RepositoryFileStructure.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,8 @@ These are the current imports in IDPO
| ro | http://purl.obolibrary.org/obo/ro.owl | slme |
| omo | http://purl.obolibrary.org/obo/omo.owl | slme |
| bfo | http://purl.obolibrary.org/obo/bfo.owl | slme |
| go | http://purl.obolibrary.org/obo/go.owl | slme |
| iao | http://purl.obolibrary.org/obo/iao.owl | slme |
## Components
Components, in contrast to imports, are considered full members of the ontology. This means that any axiom in a component is also included in the ontology base - which means it is considered _native_ to the ontology. While this sounds complicated, consider this: conceptually, no component should be part of more than one ontology. If that seems to be the case, we are most likely talking about an import. Components are often not needed for ontologies, but there are some use cases:

Expand Down
61 changes: 42 additions & 19 deletions src/ontology/Makefile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# ----------------------------------------
# Makefile for idpo
# Generated using ontology-development-kit
# ODK Version: v1.6
# ODK Version: v1.6.1
# ----------------------------------------
# IMPORTANT: DO NOT EDIT THIS FILE. To override default make goals, use idpo.Makefile instead

Expand All @@ -10,7 +10,7 @@
# More information: https://github.com/INCATools/ontology-development-kit/

# Fingerprint of the configuration file when this Makefile was last generated
CONFIG_HASH= 85e84f816ca42dc77e6261e6ed6f9b757a7fd91496e00b26a9312398d2e403b9
CONFIG_HASH= 98b52c17665ae96ff0faa9ab8d0db7ef77748df8fe2cf20122e9cab3604e090b


# ----------------------------------------
Expand Down Expand Up @@ -49,7 +49,7 @@ REPORT_PROFILE_OPTS = --profile $(ROBOT_PROFILE)
OBO_FORMAT_OPTIONS = --clean-obo "strict drop-untranslatable-axioms"
SPARQL_VALIDATION_CHECKS = owldef-self-reference iri-range label-with-iri multiple-replaced_by
SPARQL_EXPORTS = basic-report class-count-by-prefix edges xrefs obsoletes synonyms
ODK_VERSION_MAKEFILE = v1.6
ODK_VERSION_MAKEFILE = v1.6.1
RELAX_OPTIONS = --include-subclass-of true
REDUCE_OPTIONS = --include-subproperties true

Expand Down Expand Up @@ -188,9 +188,9 @@ all_main: $(MAIN_FILES)
# ----------------------------------------


IMPORTS = ro omo bfo
IMPORTS = ro omo bfo go iao

IMPORT_ROOTS = $(patsubst %, $(IMPORTDIR)/%_import, $(IMPORTS))
IMPORT_ROOTS = $(IMPORTDIR)/merged_import
IMPORT_OWL_FILES = $(foreach n,$(IMPORT_ROOTS), $(n).owl)
IMPORT_FILES = $(IMPORT_OWL_FILES)

Expand Down Expand Up @@ -274,10 +274,10 @@ endif
# ----------------------------------------

$(REPORTDIR)/$(SRC)-obo-report.tsv: $(SRCMERGED) | $(REPORTDIR)
$(ROBOT) report -i $< $(REPORT_LABEL) $(REPORT_PROFILE_OPTS) --fail-on $(REPORT_FAIL_ON) --print 5 -o $@
$(ROBOT) report -i $< $(REPORT_LABEL) $(REPORT_PROFILE_OPTS) --fail-on $(REPORT_FAIL_ON) --base-iri $(URIBASE)/IDPO_ --base-iri $(URIBASE)/idpo --print 5 -o $@

$(REPORTDIR)/%-obo-report.tsv: % | $(REPORTDIR)
$(ROBOT) report -i $< $(REPORT_LABEL) $(REPORT_PROFILE_OPTS) --fail-on $(REPORT_FAIL_ON) --print 5 -o $@
$(ROBOT) report -i $< $(REPORT_LABEL) $(REPORT_PROFILE_OPTS) --fail-on $(REPORT_FAIL_ON) --base-iri $(URIBASE)/IDPO_ --base-iri $(URIBASE)/idpo --print 5 -o $@

check_for_robot_updates:
@cut -f2 "/tools/templates/src/ontology/profile.txt" | sort > $(TMPDIR)/sorted_tsv2.txt
Expand Down Expand Up @@ -403,25 +403,23 @@ ANNOTATION_PROPERTIES=rdfs:label IAO:0000115 OMO:0002000

ifeq ($(IMP),true)

## Default module type (slme)
$(IMPORTDIR)/%_import.owl: $(MIRRORDIR)/%.owl $(IMPORTDIR)/%_terms.txt \
$(IMPORTSEED) | all_robot_plugins
$(ROBOT) annotate --input $< --remove-annotations \
odk:normalize --add-source true \
extract --term-file $(IMPORTDIR)/$*_terms.txt $(T_IMPORTSEED) \
--force true --copy-ontology-annotations true \
--individuals include \
ALL_TERMS = $(foreach imp, $(IMPORTS), $(IMPORTDIR)/$(imp)_terms.txt)

$(IMPORTDIR)/merged_import.owl: $(MIRRORDIR)/merged.owl $(ALL_TERMS) \
$(IMPORTSEED) | all_robot_plugins
$(ROBOT) merge --input $< \
extract $(foreach f, $(ALL_TERMS), --term-file $(f)) $(T_IMPORTSEED) \
--force true --copy-ontology-annotations false \
--individuals exclude \
--method BOT \
remove $(foreach p, $(ANNOTATION_PROPERTIES), --term $(p)) \
--term-file $(IMPORTDIR)/$*_terms.txt $(T_IMPORTSEED) \
$(foreach f, $(ALL_TERMS), --term-file $(f)) $(T_IMPORTSEED) \
--select complement --select annotation-properties \
odk:normalize --base-iri http://purl.obolibrary.org/obo \
--subset-decls true --synonym-decls true \
repair --merge-axiom-annotations true \
$(ANNOTATE_CONVERT_FILE)

.PRECIOUS: $(IMPORTDIR)/%_import.owl

endif # IMP=true

.PHONY: refresh-imports
Expand Down Expand Up @@ -459,7 +457,7 @@ ifeq ($(MIR),true)
.PHONY: mirror-ro
.PRECIOUS: $(MIRRORDIR)/ro.owl
mirror-ro: | $(TMPDIR)
curl -L $(OBOBASE)/ro.owl --create-dirs -o $(TMPDIR)/ro-download.owl --retry 4 --max-time 200 && \
curl -L $(OBOBASE)/ro/ro-base.owl --create-dirs -o $(TMPDIR)/ro-download.owl --retry 4 --max-time 200 && \
$(ROBOT) convert -i $(TMPDIR)/ro-download.owl -o $(TMPDIR)/$@.owl


Expand All @@ -479,6 +477,31 @@ mirror-bfo: | $(TMPDIR)
$(ROBOT) convert -i $(TMPDIR)/bfo-download.owl -o $(TMPDIR)/$@.owl


## ONTOLOGY: go
.PHONY: mirror-go
.PRECIOUS: $(MIRRORDIR)/go.owl
mirror-go: | $(TMPDIR)
curl -L $(OBOBASE)/go/go-base.owl --create-dirs -o $(TMPDIR)/go-download.owl --retry 4 --max-time 200 && \
$(ROBOT) convert -i $(TMPDIR)/go-download.owl -o $(TMPDIR)/$@.owl


## ONTOLOGY: iao
.PHONY: mirror-iao
.PRECIOUS: $(MIRRORDIR)/iao.owl
mirror-iao: | $(TMPDIR)
curl -L $(OBOBASE)/iao.owl --create-dirs -o $(TMPDIR)/iao-download.owl --retry 4 --max-time 200 && \
$(ROBOT) convert -i $(TMPDIR)/iao-download.owl -o $(TMPDIR)/$@.owl

ALL_MIRRORS = $(patsubst %, $(MIRRORDIR)/%.owl, $(IMPORTS))
MERGE_MIRRORS = true

ifeq ($(MERGE_MIRRORS),true)
$(MIRRORDIR)/merged.owl: $(ALL_MIRRORS)
$(ROBOT) merge $(patsubst %, -i %, $^) -o $@
.PRECIOUS: $(MIRRORDIR)/merged.owl
endif


$(MIRRORDIR)/%.owl: mirror-% | $(MIRRORDIR)
if [ -f $(TMPDIR)/mirror-$*.owl ]; then if cmp -s $(TMPDIR)/mirror-$*.owl $@ ; then echo "Mirror identical, ignoring."; else echo "Mirrors different, updating." &&\
cp $(TMPDIR)/mirror-$*.owl $@; fi; fi
Expand Down
4 changes: 1 addition & 3 deletions src/ontology/catalog-v001.xml
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
<?xml version='1.0' encoding='UTF-8'?>
<catalog xmlns="urn:oasis:names:tc:entity:xmlns:xml:catalog" prefer="public">
<group id="odk-managed-catalog" prefer="public">
<uri name="http://purl.obolibrary.org/obo/idpo/imports/ro_import.owl" uri="imports/ro_import.owl" />
<uri name="http://purl.obolibrary.org/obo/idpo/imports/omo_import.owl" uri="imports/omo_import.owl" />
<uri name="http://purl.obolibrary.org/obo/idpo/imports/bfo_import.owl" uri="imports/bfo_import.owl" />
<uri name="http://purl.obolibrary.org/obo/idpo/imports/merged_import.owl" uri="imports/merged_import.owl" />
</group>
</catalog>
4 changes: 1 addition & 3 deletions src/ontology/idpo-edit.owl
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,7 @@ Prefix(rdfs:=<http://www.w3.org/2000/01/rdf-schema#>)


Ontology(<http://purl.obolibrary.org/obo/idpo.owl>
Import(<http://purl.obolibrary.org/obo/idpo/imports/bfo_import.owl>)
Import(<http://purl.obolibrary.org/obo/idpo/imports/omo_import.owl>)
Import(<http://purl.obolibrary.org/obo/idpo/imports/ro_import.owl>)
Import(<http://purl.obolibrary.org/obo/idpo/imports/merged_import.owl>)
Annotation(<http://purl.obolibrary.org/obo/IAO_0000700> <http://purl.obolibrary.org/obo/IDPO_0000029>)
Annotation(<http://purl.obolibrary.org/obo/IAO_0000700> <http://purl.obolibrary.org/obo/IDPO_0000080>)
Annotation(<http://purl.obolibrary.org/obo/IAO_0000700> <http://purl.obolibrary.org/obo/IDPO_0000089>)
Expand Down
7 changes: 7 additions & 0 deletions src/ontology/idpo-odk.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,14 +13,21 @@ export_formats:
- obo
- json
import_group:
use_base_merging: TRUE
slme_individuals: exclude
products:
- id: ro
use_base: TRUE
- id: omo
- id: bfo
- id: go
use_base: TRUE
- id: iao
documentation:
documentation_system: mkdocs
robot_java_args: "-Xmx8G"
robot_report:
use_base_iris: TRUE
use_labels: TRUE
fail_on: ERROR
custom_profile: TRUE
Expand Down
5 changes: 5 additions & 0 deletions src/ontology/imports/go_terms.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
GO:0003674
GO:0016301
GO:0003824
GO:0016740
GO:0016772
1 change: 1 addition & 0 deletions src/ontology/imports/iao_terms.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
IAO:0000030
Loading
Loading