Skip to content

Add basic support for ORCIDIO.#18

Merged
gouttegd merged 4 commits into
mainfrom
orcidio-support
Jun 21, 2026
Merged

Add basic support for ORCIDIO.#18
gouttegd merged 4 commits into
mainfrom
orcidio-support

Conversation

@gouttegd

@gouttegd gouttegd commented Jun 20, 2026

Copy link
Copy Markdown
Collaborator

This PR adds automatic support for importing the ORCIDIO “ontology” (INCATools/ontology-development-kit#1312).

It adds a new project-level configuration option: orcidio_support. When enabled, it creates a custom import module for ORCIDIO ($(IMPORTDIR)/orcidio_import.owl), which is generated by (1) extracting all ORCID references in IRI-valued annotations within the source ontology and (2) extracting all individuals corresponding to the referenced ORCIDs from the ORCIDIO ontology.

Add a new project-level configuration option: `orcidio_support`. When
enabled, it creates a custom import module for ORCIDIO. The module is
generated by (1) extracting all ORCID references in dcterms:contributor
annotations within the source ontology and (2) extracting all
individuals corresponding to the referenced ORCIDs from the ORCIDIO
ontology.
@gouttegd gouttegd self-assigned this Jun 20, 2026
@gouttegd

gouttegd commented Jun 20, 2026

Copy link
Copy Markdown
Collaborator Author

Todo:

  • Create a proper mirror of ORCIDIO, instead of always fetching it from its remote location.
  • Optionally allow the ontology owner to configure the annotation properties that are expected to reference ORCID identifiers.

gouttegd added 2 commits June 20, 2026 20:39
If `orcidio_support` is enabled, then instead of reading ORCIDIO from
its online location whenever we build the `orcidio_import` module, we
download the ontology separately and store it alongside the other
mirrored ontologies in `$(MIRRORDIR)`.

This allows (1) refreshing the import under MIR=false (to take into
account new ORCID references in the -edit file, but without refreshing
the ORCID mirror), and (2) avoiding rebuilding the import module just
because the ORCIDIO mirror has been refreshed, if there has been no
changes to the actual contents of ORCIDIO.
Update the ODK ROBOT plugin to version 0.3.3, where the default
behaviour of the `odk:extract-orcids` command is to extract ORCID
references from all IRI-valued annotations.

Add to the generated Makefile a ORCIDIO_PROPERTIES variable, intended to
list the properties to use when extracting ORCID references. The
variable is set to an empty list, which triggers the default behaviour
of the `odk:extract-orcids` command (extract from all annotations
regardless of the property). The variable is intended to allow the
ontology owner to tweak that behaviour, by overriding its definition in
the custom Makefile.
@gouttegd gouttegd marked this pull request as ready for review June 21, 2026 10:26
@gouttegd gouttegd requested a review from matentzn June 21, 2026 10:26

@matentzn matentzn left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  • we should update the OBOOK tutorial to point at the new flag once released

All great.

Comment thread src/incatools/odk/model.py Outdated
.PHONY: download-mirror-orcidio
download-mirror-orcidio: | $(TMPDIR) $(MIRRORDIR)
@odk-helper download --output $(TMPDIR)/$@.owl \
--reference $(MIRRORDIR)/orcidio.owl{% if project.import_group is defined %} \

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I did NOT look at the defaults for project.import_group, but is it in theory possible to request "orcidio_support" and not have any other imports configured?

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes. The orcidio_support setting is a top-level setting, which may very well be set while no imports are configured. Hence the check on project.import_group here.

The inline documentation for the `orcidio_support` option is the only
real user-facing documentation we currently have, so it should give a
better idea of what the option actually does.
@gouttegd gouttegd merged commit a8230e7 into main Jun 21, 2026
6 checks passed
@gouttegd gouttegd deleted the orcidio-support branch June 21, 2026 16:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants