Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

'--annotate-with-source true' does not work with extract --method subset #1157

Closed
allysonlister opened this issue Oct 12, 2023 · 3 comments · Fixed by #1160
Closed

'--annotate-with-source true' does not work with extract --method subset #1157

allysonlister opened this issue Oct 12, 2023 · 3 comments · Fixed by #1160
Assignees

Comments

@allysonlister
Copy link

(Apologies if I have named this ticket incorrectly, please update as required).

I'm trying to add --annotate-with-source true to my ODK build procedure and I'm testing the run with this robot command:

java -jar ~/Programs/robot.jar --catalog catalog-v001.xml query -i mirror/po.owl --update ../sparql/preprocess-module.ru extract -T imports/po_terms_combined.txt --copy-ontology-annotations true --force true --individuals exclude --annotate-with-source true --method subset --output test-po.owl

The above is a modified version of the command that is generated by the ODK's Makefile, and I'll put it in my own makefile if I can get it working. However, this command does not add any rdfs:isDefinedBy annotations at all.
My terms to extract only has one class (http://purl.obolibrary.org/obo/PO_0025131) and it looks great EXCEPT for the lack of an rdfs:isDefinedBy property as outlined in the ROBOT command:

<owl:Class rdf:about="http://purl.obolibrary.org/obo/PO_0025131">
        <obo:IAO_0000115>An anatomical entity that is or was part of a plant.</obo:IAO_0000115>
        <oboInOwl:created_by>rwalls</oboInOwl:created_by>
        <oboInOwl:creation_date>2010-11-15T11:41:38Z</oboInOwl:creation_date>
        <oboInOwl:hasDbXref>PO_GIT:224</oboInOwl:hasDbXref>
        <oboInOwl:hasExactSynonym>entidad anat&amp;#243mica vegetal (Spanish, exact)</oboInOwl:hasExactSynonym>
        <oboInOwl:hasExactSynonym>植物 解剖学(形態)的実体 (Japanese, exact)</oboInOwl:hasExactSynonym>
        <oboInOwl:hasOBONamespace>plant_anatomy</oboInOwl:hasOBONamespace>
        <oboInOwl:id>PO:0025131</oboInOwl:id>
        <rdfs:comment>Includes both material entities such as plant structures and immaterial entities such as plant anatomical spaces. CARO:0000000 &apos;anatomical entity&apos; is defined as: A part of a cellular organism that is either an immaterial entity or a material entity with granularity aboove the level of a protein complex.  Or, a substance produced by a cellular organism with granularity above the level of a protein complex.  Refers to BFO:0000004 &apos;independent continuant&apos;.</rdfs:comment>
        <rdfs:label>plant anatomical entity</rdfs:label>
    </owl:Class>

@jamesaoverton suggests on Slack that it may just be a missing bit of code from subset and would like this ticket created.

Thank you!

(Source)

@jamesaoverton
Copy link
Member

@hkir-dev Does the subset method you implemented in #1000 support --annotate-with-source? I skimmed the code and I think it does not, but I could be wrong.

@allysonlister
Copy link
Author

BTW, i've just run a similar command using --method MIREOT and I'm also not getting the isDefinedBy...

Command is

extract --lower-terms imports/iao_terms.txt --force true --copy-ontology-annotations true --annotate-with-source true --method MIREOT --intermediates all --output tmp/iao_extracted.owl

and there are no isDefinedBy annotation. Thanks!

@hkir-dev
Copy link
Contributor

Yes, during code review I observed the same. annotate-with-source is only supported by SLME (not supported by MIREOT and subset).

I created a pull request to add support to the subset: #1160

Adding annotate-with-source support to the MIREOT requires further refactoring since it was implemented in a different class.

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 a pull request may close this issue.

3 participants