PEtab icon indicating copy to clipboard operation
PEtab copied to clipboard

Extensions: required/optional

Open dweindl opened this issue 3 years ago • 2 comments

PEtab extensions were introduced in #537. We should be able to distinguish there between optional extensions and required extensions, i.e. those that modify the parameter estimation problem as such, and those that just add additional/optional information (e.g. annotations, info for visualization, ...). If some tool does not know about a certain optional extension, it can safely be ignored during import, if it does not know about a required extension, it should fail.

To include this information in the PEtab problem, I suggest to include a new field required in the yaml file, i.e. changing the schema to

  extensions:
    type: object
    description: |
      PEtab extensions being used.
    patternProperties:
      "^[a-zA-Z][\\-\\w]*$":

        type: object
        description: |
          Information on a specific extension
        properties:
          version:
            type: string
            pattern: ^([1-9][0-9]*!)?(0|[1-9][0-9]*)(\.(0|[1-9][0-9]*))*((a|b|rc)(0|[1-9][0-9]*))?(\.post(0|[1-9][0-9]*))?(\.dev(0|[1-9][0-9]*))?$
          required:      # <------- NEW
            type: bool   # <------- NEW

        required:
          - version
          - required     # <------- NEW
      additionalProperties: true

Opinions?

dweindl avatar May 20 '22 09:05 dweindl

that sounds good to me

fbergmann avatar May 20 '22 11:05 fbergmann

👍

FFroehlich avatar May 20 '22 15:05 FFroehlich