Skip to content

Commit 07e07c1

Browse files
authored
Merge pull request #459 from materialdigital/reorganization-of-SDCs
Reorganization of SDCs
2 parents 5b2cafb + c71f922 commit 07e07c1

41 files changed

Lines changed: 2214 additions & 16890 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
-6 KB
Binary file not shown.

.gitignore

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,10 @@ bin/
2424
/pmdco-simple.*
2525
/pmdco-simple-non-classified.*
2626
/mappings/
27+
/patterns/
2728
/reports/
2829
/subsets/
30+
/bridges/
2931

3032
src/ontology/mirror
3133
src/ontology/mirror/*
@@ -49,6 +51,7 @@ src/ontology/simple_seed.txt
4951
src/ontology/patterns
5052
src/ontology/merged-pmdco-edit.owl
5153
src/ontology/pmdco-edit.properties
54+
src/ontology/bridges
5255

5356
src/ontology/target/
5457
src/ontology/tmp/*
@@ -75,3 +78,7 @@ docs/odk-workflows/RepositoryFileStructure.md
7578
/docs/odk-workflows
7679
/.cache
7780
/patterns/tmp
81+
._.DS_Store
82+
**/.DS_Store
83+
**/._.DS_Store
84+
patterns/.DS_Store

docs/cite.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
# How to cite PMDCO

docs/contributing.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
# How to contribute to PMDCO

docs/odk-workflows/RepoManagement.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ Your ODK repositories configuration is managed in `src/ontology/pmdco-odk.yaml`.
66

77

88
```
9-
sh run.sh make update_repo
9+
sh run.sh update_repo
1010
```
1111

1212
There are a large number of options that can be set to configure your ODK, but we will only discuss a few of them here.
@@ -169,7 +169,7 @@ components:
169169
- filename: mycomp.owl
170170
```
171171
172-
When running `sh run.sh make update_repo`, a new file `src/ontology/components/mycomp.owl` will
172+
When running `sh run.sh update_repo`, a new file `src/ontology/components/mycomp.owl` will
173173
be created which you can edit as you see fit. Typical ways to edit:
174174
175175
1. Using a ROBOT template to generate the component (see below)

docs/odk-workflows/RepositoryFileStructure.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ These are the current imports in PMDCO
2525
| uo | http://purl.obolibrary.org/obo/uo.owl | slme |
2626
| cob | http://purl.obolibrary.org/obo/cob.owl | custom |
2727
| nfdicore | https://raw.githubusercontent.com/ISE-FIZKarlsruhe/nfdicore/refs/tags/v3.0.4/nfdicore-base.owl | slme |
28-
| time | https://raw.githubusercontent.com/w3c/sdw/gh-pages/time/rdf/time.ttl | slme |
28+
| time | https://github.com/w3c/sdw-time/raw/refs/heads/gh-pages/rdf/time.ttl | slme |
2929
## Components
3030
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:
3131

patterns/scalar value specification/shape.ttl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,4 +51,4 @@ shape:scalar_value_specification
5151
] ;
5252

5353
sh:closed true ;
54-
sh:ignoredProperties ( rdf:type owl:topDataProperty owl:topObjectProperty obo:IAO_0000418 obo:IAO_0000219 obo:IAO_0000136 obo:BFO_0000051 obo:OBI_0002135 ) .
54+
sh:ignoredProperties ( rdf:type owl:topDataProperty owl:topObjectProperty obo:IAO_0000418 obo:IAO_0000219 obo:IAO_0000136 obo:BFO_0000051 obo:OBI_0002135 rdfs:label <http://www.w3.org/2004/02/skos/core#definition>) .

scripts/test_pr_checks.sh

100755100644
File mode changed.

src/ontology/Makefile

Lines changed: 27 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# ----------------------------------------
22
# Makefile for pmdco
33
# Generated using ontology-development-kit
4-
# ODK Version: "Unknown"
4+
# ODK Version: v1.6
55
# ----------------------------------------
66
# IMPORTANT: DO NOT EDIT THIS FILE. To override default make goals, use pmdco.Makefile instead
77

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

1212
# Fingerprint of the configuration file when this Makefile was last generated
13-
CONFIG_HASH= 54072dc574a377048daa0be07494524ef16b0e62e4cbf5483bb9f4e1401d0586
13+
CONFIG_HASH= f21fb6466e311206258e4626acb95498d16097f5c7c583eab894021c196a1441
1414

1515

1616
# ----------------------------------------
@@ -42,15 +42,14 @@ UPDATEREPODIR= target
4242
SPARQLDIR = ../sparql
4343
EXTENDED_PREFIX_MAP= $(TMPDIR)/obo.epm.json
4444
COMPONENTSDIR = components
45-
ODK_RESOURCES_DIR ?= /tools/resources
4645
ROBOT_PROFILE = profile.txt
4746
REPORT_FAIL_ON = ERROR
4847
REPORT_LABEL = -l true
4948
REPORT_PROFILE_OPTS = --profile $(ROBOT_PROFILE)
5049
OBO_FORMAT_OPTIONS = --clean-obo "strict drop-untranslatable-axioms"
5150
SPARQL_VALIDATION_CHECKS = owldef-self-reference iri-range label-with-iri multiple-replaced_by
5251
SPARQL_EXPORTS = basic-report class-count-by-prefix edges xrefs obsoletes synonyms
53-
ODK_VERSION_MAKEFILE = "Unknown"
52+
ODK_VERSION_MAKEFILE = v1.6
5453
RELAX_OPTIONS = --include-subclass-of true
5554
REDUCE_OPTIONS = --include-subproperties true
5655

@@ -64,7 +63,6 @@ ONTOLOGYTERMS = $(TMPDIR)/ontologyterms.txt
6463
EDIT_PREPROCESSED = $(TMPDIR)/$(ONT)-preprocess.owl
6564

6665

67-
6866
FORMATS = $(sort owl ttl owl)
6967
FORMATS_INCL_TSV = $(sort $(FORMATS) tsv)
7068
RELEASE_ARTEFACTS = $(sort $(ONT)-base $(ONT)-full $(ONT)-simple $(ONT)-minimal )
@@ -128,12 +126,12 @@ reason_test: $(EDIT_PREPROCESSED)
128126
.PHONY: odkversion
129127
odkversion:
130128
@echo "ODK Makefile $(ODK_VERSION_MAKEFILE)"
131-
@odk-helper info --tools
129+
@odk-info --tools
132130
.PHONY: config_check
133131
config_check:
134132
@if [ "$$(tr -d '\r' < $(ONT)-odk.yaml | sha256sum | cut -c1-64)" = "$(CONFIG_HASH)" ]; then \
135133
echo "Repository is up-to-date." ; else \
136-
echo "Your ODK configuration has changed since this Makefile was generated. You may need to run 'sh run.sh update_repo'." ; fi
134+
echo "Your ODK configuration has changed since this Makefile was generated. You may need to run 'make update_repo'." ; fi
137135

138136

139137
$(TMPDIR) $(REPORTDIR) $(MIRRORDIR) $(IMPORTDIR) $(COMPONENTSDIR) $(SUBSETDIR):
@@ -151,20 +149,23 @@ export ROBOT_PLUGINS_DIRECTORY=$(TMPDIR)/plugins
151149
custom_robot_plugins:
152150

153151

152+
.PHONY: extra_robot_plugins
153+
extra_robot_plugins:
154+
154155

155156
# Install all ROBOT plugins to the runtime plugins directory
156157
.PHONY: all_robot_plugins
157-
all_robot_plugins: $(foreach plugin,$(notdir $(wildcard $(ODK_RESOURCES_DIR)/robot/plugins/*.jar)),$(ROBOT_PLUGINS_DIRECTORY)/$(plugin)) \
158+
all_robot_plugins: $(foreach plugin,$(notdir $(wildcard /tools/robot-plugins/*.jar)),$(ROBOT_PLUGINS_DIRECTORY)/$(plugin)) \
158159
$(foreach plugin,$(notdir $(wildcard ../../plugins/*.jar)),$(ROBOT_PLUGINS_DIRECTORY)/$(plugin)) \
159-
custom_robot_plugins \
160+
custom_robot_plugins extra_robot_plugins \
160161

161162
# Default rule to install plugins
162163
$(ROBOT_PLUGINS_DIRECTORY)/%.jar:
163164
@mkdir -p $(ROBOT_PLUGINS_DIRECTORY)
164165
@if [ -f ../../plugins/$*.jar ]; then \
165166
ln ../../plugins/$*.jar $@ ; \
166-
elif [ -f $(ODK_RESOURCES_DIR)/robot/plugins/$*.jar ]; then \
167-
cp $(ODK_RESOURCES_DIR)/robot/plugins/$*.jar $@ ; \
167+
elif [ -f /tools/robot-plugins/$*.jar ]; then \
168+
cp /tools/robot-plugins/$*.jar $@ ; \
168169
fi
169170

170171
# Specific rules for supplementary plugins defined in configuration
@@ -224,11 +225,6 @@ RELEASED_MAPPING_FILES = $(foreach p, $(RELEASED_MAPPINGS), $(MAPPINGDIR)/$(p).s
224225
.PHONY: all_mappings
225226
all_mappings: $(MAPPING_FILES)
226227

227-
# ----------------------------------------
228-
# Bridge assets
229-
# ----------------------------------------
230-
231-
BRIDGE_FILES =
232228

233229
# ----------------------------------------
234230
# QC Reports & Utilities
@@ -283,8 +279,13 @@ $(REPORTDIR)/$(SRC)-obo-report.tsv: $(SRCMERGED) | $(REPORTDIR)
283279
$(REPORTDIR)/%-obo-report.tsv: % | $(REPORTDIR)
284280
$(ROBOT) report -i $< $(REPORT_LABEL) $(REPORT_PROFILE_OPTS) --fail-on $(REPORT_FAIL_ON) --print 5 -o $@
285281

286-
check_for_robot_updates:
287-
@odk-helper check-robot-profile
282+
check_for_robot_updates:
283+
@cut -f2 "/tools/templates/src/ontology/profile.txt" | sort > $(TMPDIR)/sorted_tsv2.txt
284+
@cut -f2 "$(ROBOT_PROFILE)" | sort > $(TMPDIR)/sorted_tsv1.txt
285+
@comm -23 $(TMPDIR)/sorted_tsv2.txt $(TMPDIR)/sorted_tsv1.txt > $(TMPDIR)/missing.txt
286+
@echo "Missing tests:"
287+
@cat $(TMPDIR)/missing.txt
288+
@rm $(TMPDIR)/sorted_tsv1.txt $(TMPDIR)/sorted_tsv2.txt $(TMPDIR)/missing.txt $(TMPDIR)/report_profile_robot.txt
288289

289290
# ----------------------------------------
290291
# Release assets
@@ -295,13 +296,11 @@ ASSETS = \
295296
$(MAIN_FILES) \
296297
$(REPORT_FILES) \
297298
$(SUBSET_FILES) \
298-
$(MAPPING_FILES) \
299-
$(BRIDGE_FILES)
299+
$(MAPPING_FILES)
300300

301301
RELEASE_ASSETS = \
302302
$(MAIN_FILES) \
303-
$(SUBSET_FILES)\
304-
$(BRIDGE_FILES)
303+
$(SUBSET_FILES)
305304

306305
.PHONY: all_assets
307306
all_assets: $(ASSETS) check_rdfxml_assets
@@ -312,7 +311,7 @@ show_assets:
312311
du -sh $(ASSETS)
313312

314313
check_rdfxml_%: %
315-
@odk-helper check-rdfxml $<
314+
@check-rdfxml $<
316315

317316
.PHONY: check_rdfxml_assets
318317
check_rdfxml_assets: $(foreach product,$(MAIN_PRODUCTS),check_rdfxml_$(product).owl)
@@ -611,7 +610,7 @@ mirror-bfo: | $(TMPDIR)
611610
.PHONY: mirror-ro
612611
.PRECIOUS: $(MIRRORDIR)/ro.owl
613612
mirror-ro: | $(TMPDIR)
614-
$(ROBOT) convert -I http://purl.obolibrary.org/obo/ro.owl -o $(TMPDIR)/$@.owl
613+
$(ROBOT) convert -I http://purl.obolibrary.org/obo/ro/releases/2025-12-17/ro.owl -o $(TMPDIR)/$@.owl
615614

616615

617616
## ONTOLOGY: iao
@@ -626,8 +625,7 @@ mirror-iao: | $(TMPDIR)
626625
.PHONY: mirror-obi
627626
.PRECIOUS: $(MIRRORDIR)/obi.owl
628627
mirror-obi: | $(TMPDIR)
629-
curl -L $(OBOBASE)/obi.owl --create-dirs -o $(TMPDIR)/obi-download.owl --retry 4 --max-time 200 && \
630-
$(ROBOT) convert -i $(TMPDIR)/obi-download.owl -o $(TMPDIR)/$@.owl
628+
$(ROBOT) convert -I http://purl.obolibrary.org/obo/obi/2025-12-18/obi.owl -o $(TMPDIR)/$@.owl
631629

632630

633631
## ONTOLOGY: chebi
@@ -665,14 +663,14 @@ mirror-cob: | $(TMPDIR)
665663
.PHONY: mirror-nfdicore
666664
.PRECIOUS: $(MIRRORDIR)/nfdicore.owl
667665
mirror-nfdicore: | $(TMPDIR)
668-
$(ROBOT) convert -I https://raw.githubusercontent.com/ISE-FIZKarlsruhe/nfdicore/refs/tags/v3.0.4/nfdicore-base.owl -o $(TMPDIR)/$@.owl
666+
$(ROBOT) convert -I https://raw.githubusercontent.com/ISE-FIZKarlsruhe/nfdicore/refs/tags/v3.0.5/nfdicore-base.owl -o $(TMPDIR)/$@.owl
669667

670668

671669
## ONTOLOGY: time
672670
.PHONY: mirror-time
673671
.PRECIOUS: $(MIRRORDIR)/time.owl
674672
mirror-time: | $(TMPDIR)
675-
$(ROBOT) convert -I https://raw.githubusercontent.com/w3c/sdw/gh-pages/time/rdf/time.ttl -o $(TMPDIR)/$@.owl
673+
$(ROBOT) convert -I https://github.com/w3c/sdw-time/raw/refs/heads/gh-pages/rdf/time.ttl -o $(TMPDIR)/$@.owl
676674

677675

678676
$(MIRRORDIR)/%.owl: mirror-% | $(MIRRORDIR)
@@ -827,7 +825,7 @@ validate-all-tsv: $(ALL_TSV_FILES)
827825
# can use to pull the (currently inofficial) OBO EPM into the workspace.
828826
# Users are instructed to refer to the EPM only through the variable $(EXTENDED_PREFIX_MAP) as
829827
# its location might change in a feature version of ODK.
830-
$(EXTENDED_PREFIX_MAP): $(ODK_RESOURCES_DIR)/obo.epm.json
828+
$(EXTENDED_PREFIX_MAP): /tools/obo.epm.json
831829
cp $< $@
832830

833831

src/ontology/components/imports-edit.owl

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,8 +21,10 @@ Import(<https://w3id.org/pmd/co/imports/uo_import.owl>)
2121
Declaration(Class(obo:CHEBI_74236))
2222
Declaration(Class(qudt:QuantityValue))
2323
Declaration(Class(qudt:Unit))
24+
Declaration(Class(:PMD_0020259))
2425
Declaration(ObjectProperty(qudt:hasUnit))
2526
Declaration(DataProperty(qudt:numericValue))
27+
Declaration(NamedIndividual(<http://qudt.org/vocab/unit/PER-MOL>))
2628
Declaration(AnnotationProperty(:PMD_0000060))
2729

2830
############################
@@ -64,7 +66,7 @@ SubDataPropertyOf(qudt:numericValue obo:OBI_0001937)
6466

6567
# Class: obo:CHEBI_74236 (polymerisation monomer)
6668

67-
SubClassOf(obo:CHEBI_74236 obo:BFO_0000023)
69+
SubClassOf(obo:CHEBI_74236 :PMD_0020259)
6870

6971
# Class: obo:NCBITaxon_9606 (homo sapiens)
7072

@@ -90,6 +92,15 @@ For example, the meter is a quantity of length that has been rigorously defined
9092
More formally, the value of a physical quantity Q with respect to a unit (U) is expressed as the scalar multiple of a real number (n) and U, as $Q = nU$."@en)
9193

9294

95+
############################
96+
# Named Individuals
97+
############################
98+
99+
# Individual: <http://qudt.org/vocab/unit/PER-MOL> (<http://qudt.org/vocab/unit/PER-MOL>)
100+
101+
ClassAssertion(qudt:Unit <http://qudt.org/vocab/unit/PER-MOL>)
102+
103+
93104
SubObjectPropertyOf(ObjectPropertyChain(obo:BFO_0000055 obo:RO_0000059) obo:STATO_0000102)
94105
AnnotationAssertion(obo:IAO_0000112 obo:IAO_0000098 "you might consinder EDAM formats as sublasses here http://edamontology.org/format_1915")
95106
AnnotationAssertion(:PMD_0000060 obo:IAO_0020000 "true"^^xsd:boolean)

0 commit comments

Comments
 (0)