INCATools / dosdp-tools

Utility for working with DOSDP design patterns and OWL ontologies
MIT License
24 stars 5 forks source link

Documentation request: how to overwrite generated columns #211

Open matentzn opened 4 years ago

matentzn commented 4 years ago

Ideally, I thought that given this:

annotations:
  - annotationProperty: exact_synonym
    text: "ultrasonography of %s"
    vars:
     - location

In my DOSDP pattern, I can simply add a column defined_class_exact_synonym to my TSV file to overwrite, but this does not work.

Adding override: exact_synonym_override currently does not work because this is not in the DOSDP spec. @dosumis

matentzn commented 4 years ago

Example:

annotations:
  - annotationProperty: exact_synonym
    text: "ultrasonography of %s"
    vars:
     - location
    override: exact_synonym_override
dosumis commented 4 years ago
  1. This won't work becuase the it would require some way to bind to the specific list element.
  2. While we discussed adding an explicit override keyword to DOSDP, we didn't implement this, instead (if I understand correctly), Jim implemented a manual list of pimary keywords that can be over-ridden: https://github.com/INCATools/dosdp-tools/pull/112/commits/fc24adee4fc5fb05a75367da37b116d8c65ffe90
  3. Instead of using the annotation keyword and an explicit reference to the relevant annotation property, you can add generated exact synonyms using:
    generated_synonyms:
    - 
     text: "ultrasonography of %s"
     vars:
        - location

    (see https://github.com/INCATools/dead_simple_owl_design_patterns/blob/master/spec/DOSDP_schema_full.yaml#L369)

It looks like override should work if @balhoff adds these fields to the enumerated list of fields that support override.