Skip to content

Move clinically specific subclasses out of linkml-microschema-profile #21

@sierra-moxon

Description

@sierra-moxon

If we want to implement microschemas in the linkml org itself, should they should remain universally applicable to any domain?

e.g.,

keep these in linkml-microschema-profile:

MicroschemaDefinition:
    class_uri: coms:MicroschemaDefinition
    abstract: true
    description: >-
      A metaclass for classes that conform to the Microschema profile.
      Classes that instantiate this are designed for inline composition.
    comments:
      - Classes instantiating this SHOULD NOT have identifier slots
      - Classes instantiating this SHOULD be used with inlined=true
      - Classes instantiating this MAY compose other microschemas via attributes
    slots:
      - profile_version
      - semantic_mapping
      - domain_of_use

  ValueMicroschemaDefinition:
    class_uri: coms:ValueMicroschemaDefinition
    is_a: MicroschemaDefinition
    abstract: true
    description: >-
      A microschema representing a typed value with optional unit/system.
      Examples: Quantity, Timepoint, CodedValue, Range.

  #────────────────────────────────────────────────────────────────
  # VALUE MICROSCHEMAS: Leaf value types
  #────────────────────────────────────────────────────────────────

  Quantity:
    instantiates:
      - ValueMicroschemaDefinition
    class_uri: schema:QuantitativeValue
    description: >-
      A value with optional unit
    slots:
      - quantity_value
      - quantity_unit
      - comparator

  Timepoint:
    instantiates:
      - ValueMicroschemaDefinition
    description: >-
      A point in time, potentially relative
    slots:
      - datetime
      - relative_to_event
      - offset

  TimeInterval:
    instantiates:
      - ValueMicroschemaDefinition
    description: >-
      A period between two timepoints
    slots:
      - interval_start
      - interval_end
      - duration

  CodedValue:
    instantiates:
      - ValueMicroschemaDefinition
    description: >-
      A value from a controlled vocabulary
    slots:
      - code
      - code_label
      - code_system

The rest should be in a downstream/specific model that brings in these classes via implements or instantiates? Then I could tell a story about why I was "instantiating" linkml-microschema-profile:Quantity in my geochem schema (without explaining the clinical classes).

Metadata

Metadata

Assignees

Labels

enhancementNew feature or request

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions