From aaa6618da24938ec1829c51cfcfa1c0874883397 Mon Sep 17 00:00:00 2001 From: Anne Thessen Date: Thu, 15 Aug 2019 14:35:51 -0400 Subject: [PATCH] first passing test --- biolink-model.yaml | 88 + biolink/__init__.py | 3 +- tests/biolink-model.yaml | 3799 ++++++++++++++ tests/biolink/__init__.py | 14 + tests/biolink/model.py | 9807 +++++++++++++++++++++++++++++++++++ tests/test_biolink_model.py | 1 - 6 files changed, 13710 insertions(+), 2 deletions(-) create mode 100644 tests/biolink-model.yaml create mode 100644 tests/biolink/__init__.py create mode 100644 tests/biolink/model.py diff --git a/biolink-model.yaml b/biolink-model.yaml index b1604f2c27..8c77cb421e 100644 --- a/biolink-model.yaml +++ b/biolink-model.yaml @@ -1135,6 +1135,54 @@ slots: A grouping for any property that holds between a node and a value domain: named thing + title: + is_a: node property + domain: data set version + slot_uri: dct:title + + source data file: + is_a: node property + domain: data set version + range: data file + slot_uri: dcterms:source + + source web page: + is_a: node property + domain: data set summary + slot_uri: dcterms:source + + retrievedOn: + is_a: node property + domain: source file + range: date + slot_uri: pav:retrievedOn + + versionOf: + is_a: node property + domain: data set version + range: data set + slot_uri: dct:isVersionOf + + source version: + is_a: node property + domain: source file + slot_uri: pav:version + + downloadURL: + is_a: node property + domain: distribution level + slot_uri: dct:downloadURL + + distribution: + is_a: node property + domain: data set version + range: distribution level + slot_uri: void:Dataset + + type: + is_a: node property + slot_uri: rdf:type + id: is_a: node property identifier: true @@ -1628,6 +1676,46 @@ classes: - UMLSSC:T168 - UMLSST:food + data file: + is_a: named thing + class_uri: EFO:0004095 + + source file: + is_a: data file + slots: + - source version + - retrievedOn + +# data set descriptor: +# abstract: true +# mixin: true + + data set: + is_a: named thing + class_uri: IAO:0000100 + + data set version: + is_a: data set + slots: + - title +# - description + - source data file + - versionOf + - type + - distribution + + distribution level: + is_a: data set version + mixin: true + slots: + - downloadURL + + data set summary: + is_a: data set version + mixin: true + slots: + - source web page + biological entity: is_a: named thing abstract: true diff --git a/biolink/__init__.py b/biolink/__init__.py index 8987fe87ca..d7adceb5f4 100644 --- a/biolink/__init__.py +++ b/biolink/__init__.py @@ -1,8 +1,9 @@ # Biolink model file locations import os +from typing import Union basedir = os.path.abspath(os.path.join(__file__, '..', '..')) -BIOLINK_MODEL_YAML = os.path.join(basedir, 'biolink-model.yaml') +BIOLINK_MODEL_YAML = os.path.join(basedir, 'biolink-model.yaml') # type: Union[bytes, str] BIOLINK_MODEL_JSONLD = os.path.join(basedir, 'context.jsonld') BIOLINK_MODEL_SHEX = os.path.join(basedir, 'shex', 'biolink-model.shex') BIOLINK_MODEL_RDF = os.path.join(basedir, 'rdf', 'biolink-model.ttl') diff --git a/tests/biolink-model.yaml b/tests/biolink-model.yaml new file mode 100644 index 0000000000..8c77cb421e --- /dev/null +++ b/tests/biolink-model.yaml @@ -0,0 +1,3799 @@ +id: https://w3id.org/biolink/biolink-model +name: biolink_model +description: Entity and association taxonomy and datamodel for life-sciences data +license: https://creativecommons.org/publicdomain/zero/1.0/ + +prefixes: + biolink: https://w3id.org/biolink/vocab/ + biolinkml: https://w3id.org/biolink/biolinkml/ + OBAN: http://purl.org/oban/ + SIO: http://semanticscience.org/resource/SIO_ + wgs: http://www.w3.org/2003/01/geo/wgs84_pos + UMLSSG: https://uts-ws.nlm.nih.gov/rest/semantic-network/semantic-network/current/GROUP/ + UMLSST: https://uts-ws.nlm.nih.gov/rest/semantic-network/semantic-network/current/STY/ + UMLSSC: https://uts-ws.nlm.nih.gov/rest/semantic-network/semantic-network/current/TUI/ + +default_prefix: biolink +default_range: string + +default_curi_maps: + - obo_context + - monarch_context + - idot_context + - semweb_context + +emit_prefixes: + - rdf + - rdfs + - xsd + - skos + - OIO + - BIOGRID + +subsets: + translator_minimal: + description: Minimum subset of translator work + + testing: + description: (tbd) + + +imports: + - biolinkml:types + +types: + + chemical formula value: + uri: xsd:string + base: str + description: A chemical formula + notes: + - Should be implemented as a stronger type + + identifier type: + typeof: string + description: >- + A string that is intended to uniquely identify a thing + May be URI in full or compact (CURIE) form + + iri type: + typeof: uri + description: >- + An IRI + + label type: + typeof: string + description: >- + A string that provides a human-readable name for a thing + + narrative text: + typeof: string + description: >- + A string that provides a human-readable description of something + + symbol type: + typeof: string + + frequency: + typeof: string + uri: UO:0000105 + + perecentage frequency value: + typeof: double + uri: UO:0000187 + + quotient: + aliases: ['ratio'] + typeof: double + uri: UO:0010006 + + unit: + typeof: string + uri: UO:0000000 + id_prefixes: + - UO + + time type: + typeof: time + + biological sequence: + typeof: string + +slots: + +## predicates/relations + + related to: + description: >- + A relationship that is asserted between two named things + domain: named thing + range: named thing + multivalued: true + slot_uri: owl:ObjectProperty + inherited: true + mappings: + - SEMMEDDB:ASSOCIATED_WITH + + interacts with: + domain: named thing + range: named thing + description: >- + holds between any two entities that directly or indirectly interact with each other + is_a: related to + in_subset: + - translator_minimal + slot_uri: RO:0002434 + + physically interacts with: + is_a: interacts with + description: >- + holds between two entities that make physical contact as part of some interaction + in_subset: + - translator_minimal + symmetric: true + slot_uri: WD:P129 + mappings: + - SEMMEDDB:INTERACTS_WITH + + molecularly interacts with: + is_a: physically interacts with + domain: molecular entity + range: molecular entity + in_subset: + - translator_minimal + slot_uri: RO:0002436 + + genetically interacts with: + is_a: interacts with + description: >- + holds between two genes whose phenotypic effects are dependent on each other in some way - such that their combined phenotypic effects are the result of some interaction between the activity of their gene products. Examples include epistasis and synthetic lethality. + domain: gene + range: gene + in_subset: + - translator_minimal + slot_uri: RO:0002435 + + affects: + is_a: related to + description: >- + describes an entity that has a direct affect on the state or quality of another existing entity. + Use of the 'affects' predicate implies that the affected entity already exists, unlike predicates such as 'affects risk for' and 'prevents, where the outcome is something that may or may not come to be. + in_subset: + - translator_minimal + slot_uri: SEMMEDDB:AFFECTS + + affects abundance of: + description: >- + holds between two molecular entities where the action or effect of one changes the amount of the other within a system of interest + is_a: affects + in_subset: + - translator_minimal + domain: molecular entity + range: molecular entity + + increases abundance of: + description: >- + holds between two molecular entities where the action or effect of one increases the amount of the other within a system of interest + is_a: affects abundance of + in_subset: + - translator_minimal + domain: molecular entity + range: molecular entity + + decreases abundance of: + description: >- + holds between two molecular entities where the action or effect of one decreases the amount of the other within a system of interest + is_a: affects abundance of + in_subset: + - translator_minimal + domain: molecular entity + range: molecular entity + + affects activity of: + description: >- + holds between two molecular entities where the action or effect of one changes the activity of the other within a system of interest + is_a: affects + in_subset: + - translator_minimal + domain: molecular entity + range: molecular entity + + increases activity of: + description: >- + holds between two molecular entities where the action or effect of one increases the activity of the other within a system of interest + is_a: affects activity of + in_subset: + - translator_minimal + domain: molecular entity + range: molecular entity + + decreases activity of: + description: >- + holds between two molecular entities where the action or effect of one decreases the activity of the other within a system of interest + is_a: affects activity of + in_subset: + - translator_minimal + domain: molecular entity + range: molecular entity + + affects expression of: + description: >- + holds between two molecular entities where the action or effect of one changes the level of expression of the other within a system of interest + is_a: affects + in_subset: + - translator_minimal + domain: molecular entity + range: genomic entity + + increases expression of: + description: >- + holds between two molecular entities where the action or effect of one increases the level of expression of the other within a system of interest + is_a: affects expression of + in_subset: + - translator_minimal + domain: molecular entity + range: genomic entity + + decreases expression of: + description: >- + holds between two molecular entities where the action or effect of one decreases the level of expression of the other within a system of interest + is_a: affects expression of + in_subset: + - translator_minimal + domain: molecular entity + range: genomic entity + + affects folding of: + description: >- + holds between two molecular entities where the action or effect of one changes the rate or quality of folding of the other + is_a: affects + in_subset: + - translator_minimal + domain: molecular entity + range: molecular entity + + increases folding of: + description: >- + holds between two molecular entities where the action or effect of one increases the rate or quality of folding of the other + is_a: affects folding of + in_subset: + - translator_minimal + domain: molecular entity + range: molecular entity + + decreases folding of: + description: >- + holds between two molecular entities where the action or effect of one decreases the rate or quality of folding of the other + is_a: affects folding of + in_subset: + - translator_minimal + domain: molecular entity + range: molecular entity + + affects localization of: + description: >- + holds between two molecular entities where the action or effect of one changes the localization of the other within a system of interest + is_a: affects + in_subset: + - translator_minimal + domain: molecular entity + range: molecular entity + + increases localization of: + description: >- + holds between two molecular entities where the action or effect of one increases the proper localization of the other within a system of interest + is_a: affects localization of + in_subset: + - translator_minimal + domain: molecular entity + range: molecular entity + + decreases localization of: + description: >- + holds between two molecular entities where the action or effect of one decreases the proper localization of the other within a system of interest + is_a: affects localization of + in_subset: + - translator_minimal + domain: molecular entity + range: molecular entity + + affects metabolic processing of: + description: >- + holds between two molecular entities where the action or effect of one impacts the metabolic processing of the other within a system of interest + is_a: affects + in_subset: + - translator_minimal + domain: molecular entity + range: molecular entity + + increases metabolic processing of: + description: >- + holds between two molecular entities where the action or effect of one increases the rate of metabolic processing of the other within a system of interest + is_a: affects metabolic processing of + in_subset: + - translator_minimal + domain: molecular entity + range: molecular entity + + decreases metabolic processing of: + description: >- + holds between two molecular entities where the action or effect of one decreases the rate of metabolic processing of the other within a system of interest + is_a: affects metabolic processing of + in_subset: + - translator_minimal + domain: molecular entity + range: molecular entity + + affects molecular modification of: + description: >- + holds between two molecular entities where the action or effect of one leads changes in the molecular modification(s) of the other (e.g. via post-translational modifications of proteins such as the addition of phosphoryl group, or via redox reaction that adds or subtracts electrons) + is_a: affects + in_subset: + - translator_minimal + domain: molecular entity + range: molecular entity + + increases molecular modification of: + description: >- + holds between two molecular entities where the action or effect of one leads to increased molecular modification(s) of the other (e.g. via post-translational modifications of proteins such as the addition of phosphoryl group, or via redox reaction that adds or subtracts electrons) + is_a: affects molecular modification of + in_subset: + - translator_minimal + domain: molecular entity + range: molecular entity + + decreases molecular modification of: + description: >- + holds between two molecular entities where the action or effect of one leads to decreased molecular modification(s) of the other (e.g. via post-translational modifications of proteins such as the addition of phosphoryl group, or via redox reaction that adds or subtracts electrons) + is_a: affects molecular modification of + in_subset: + - translator_minimal + domain: molecular entity + range: molecular entity + + affects synthesis of: + description: >- + holds between two molecular entities where the action or effect of one impacts the rate of chemical synthesis of the other + is_a: affects + in_subset: + - translator_minimal + domain: molecular entity + range: molecular entity + + increases synthesis of: + description: >- + holds between two molecular entities where the action or effect of one increases the rate of chemical synthesis of the other + is_a: affects synthesis of + in_subset: + - translator_minimal + domain: molecular entity + range: molecular entity + + decreases synthesis of: + description: >- + holds between two molecular entities where the action or effect of one decreases the rate of chemical synthesis of the other + is_a: affects synthesis of + in_subset: + - translator_minimal + domain: molecular entity + range: molecular entity + + affects degradation of: + description: >- + holds between two molecular entities where the action or effect of one impacts the rate of degradation of the other within a system of interest + is_a: affects + in_subset: + - translator_minimal + domain: molecular entity + range: molecular entity + + increases degradation of: + description: >- + holds between two molecular entities where the action or effect of one increases the rate of degradation of the other within a system of interest + is_a: affects degradation of + in_subset: + - translator_minimal + domain: molecular entity + range: molecular entity + + decreases degradation of: + description: >- + holds between two molecular entities where the action or effect of one decreases the rate of degradation of the other within a system of interest + is_a: affects degradation of + in_subset: + - translator_minimal + domain: molecular entity + range: molecular entity + + affects mutation rate of: + description: >- + holds between a molecular entity and a genomic entity where the action or effect of the molecular entity impacts the rate of mutation of the genomic entity within a system of interest + is_a: affects + in_subset: + - translator_minimal + domain: molecular entity + range: genomic entity + + increases mutation rate of: + description: >- + holds between a molecular entity and a genomic entity where the action or effect of the molecular entity increases the rate of mutation of the genomic entity within a system of interest + is_a: affects mutation rate of + in_subset: + - translator_minimal + domain: molecular entity + range: genomic entity + + decreases mutation rate of: + description: >- + holds between a molecular entity and a genomic entity where the action or effect of the molecular entity decreases the rate of mutation of the genomic entity within a system of interest + is_a: affects mutation rate of + in_subset: + - translator_minimal + domain: molecular entity + range: genomic entity + + affects response to: + description: >- + holds between two molecular entities where the action or effect of one impacts the susceptibility of a biological entity or system (e.g. an organism, cell, cellular component, macromolecular machine, biological or pathological process) to the other + is_a: affects + in_subset: + - translator_minimal + domain: molecular entity + range: molecular entity + + increases response to: + description: >- + holds between two molecular entities where the action or effect of one increases the susceptibility of a biological entity or system (e.g. an organism, cell, cellular component, macromolecular machine, biological or pathological process) to the other + is_a: affects response to + in_subset: + - translator_minimal + domain: molecular entity + range: molecular entity + + decreases response to: + description: >- + holds between two molecular entities where the action or effect of one decreases the susceptibility of a biological entity or system (e.g. an organism, cell, cellular component, macromolecular machine, biological or pathological process) to the other + is_a: affects response to + in_subset: + - translator_minimal + domain: molecular entity + range: molecular entity + + affects splicing of: + description: >- + holds between a molecular entity and an mRNA where the action or effect of the molecular entity impacts the splicing of the mRNA + is_a: affects + in_subset: + - translator_minimal + domain: molecular entity + range: transcript + + increases splicing of: + description: >- + holds between a molecular entity and an mRNA where the action or effect of the molecular entity increases the proper splicing of the mRNA + is_a: affects splicing of + in_subset: + - translator_minimal + domain: molecular entity + range: transcript + + decreases splicing of: + description: >- + holds between a molecular entity and an mRNA where the action or effect of the molecular entity decreases the proper splicing of the mRNA + is_a: affects splicing of + in_subset: + - translator_minimal + domain: molecular entity + range: transcript + + affects stability of: + description: >- + holds between two molecular entities where the action or effect of one impacts the stability of the other within a system of interest + is_a: affects + in_subset: + - translator_minimal + domain: molecular entity + range: molecular entity + + increases stability of: + description: >- + holds between two molecular entities where the action or effect of one increases the stability of the other within a system of interest + is_a: affects stability of + in_subset: + - translator_minimal + domain: molecular entity + range: molecular entity + + decreases stability of: + description: >- + holds between two molecular entities where the action or effect of one decreases the stability of the other within a system of interest + is_a: affects stability of + in_subset: + - translator_minimal + domain: molecular entity + range: molecular entity + + affects transport of: + description: >- + holds between two molecular entities where the action or effect of one impacts the rate of transport of the other across some boundary in a system of interest + is_a: affects + in_subset: + - translator_minimal + domain: molecular entity + range: molecular entity + + increases transport of: + description: >- + holds between two molecular entities where the action or effect of one increases the rate of transport of the other across some boundary in a system of interest + is_a: affects transport of + in_subset: + - translator_minimal + domain: molecular entity + range: molecular entity + + decreases transport of: + description: >- + holds between two molecular entities where the action or effect of one decreases the rate of transport of the other across some boundary in a system of interest + is_a: affects transport of + in_subset: + - translator_minimal + domain: molecular entity + range: molecular entity + + affects secretion of: + description: >- + holds between two molecular entities where the action or effect of one impacts the rate of secretion of the other out of a cell, gland, or organ + is_a: affects + in_subset: + - translator_minimal + domain: molecular entity + range: molecular entity + + increases secretion of: + description: >- + holds between two molecular entities where the action or effect of one increases the rate of secretion of the other out of a cell, gland, or organ + is_a: affects secretion of + in_subset: + - translator_minimal + domain: molecular entity + range: molecular entity + + decreases secretion of: + description: >- + holds between two molecular entities where the action or effect of one decreases the rate of secretion of the other out of a cell, gland, or organ + is_a: affects secretion of + in_subset: + - translator_minimal + domain: molecular entity + range: molecular entity + + affects uptake of: + description: >- + holds between two molecular entities where the action or effect of one impacts the rate of uptake of the other into of a cell, gland, or organ + is_a: affects + in_subset: + - translator_minimal + domain: molecular entity + range: molecular entity + + increases uptake of: + description: >- + holds between two molecular entities where the action or effect of one increases the rate of uptake of the other into of a cell, gland, or organ + is_a: affects uptake of + in_subset: + - translator_minimal + domain: molecular entity + range: molecular entity + + decreases uptake of: + description: >- + holds between two molecular entities where the action or effect of one decreases the rate of uptake of the other into of a cell, gland, or organ + is_a: affects uptake of + in_subset: + - translator_minimal + domain: molecular entity + range: molecular entity + + regulates: + is_a: affects + comments: + - This is a grouping for process-process and entity-entity relations + mixin: true + abstract: true + slot_uri: WD:P128 + + positively regulates: + comments: + - This is a grouping for process-process and entity-entity relations + is_a: regulates + mixin: true + abstract: true + + negatively regulates: + comments: + - This is a grouping for process-process and entity-entity relations + is_a: regulates + mixin: true + abstract: true + + regulates, process to process: + is_a: regulates + domain: occurrent + range: occurrent + slot_uri: RO:0002211 + + positively regulates, process to process: + is_a: regulates, process to process + mixins: + - positively regulates + slot_uri: RO:0002213 + + negatively regulates, process to process: + is_a: regulates, process to process + mixins: + - negatively regulates + slot_uri: RO:0002212 + + regulates, entity to entity: + aliases: ['activity directly regulates activity of'] + is_a: regulates + domain: molecular entity + range: molecular entity + local_names: + translator: regulates + ro: activity directly regulates activity of + in_subset: + - translator_minimal + slot_uri: RO:0002448 + + positively regulates, entity to entity: + aliases: ['activity directly positively regulates activity of'] + is_a: regulates, entity to entity + mixins: + - positively regulates + local_names: + translator: positively regulates + ro: activity directly positively regulates activity of + in_subset: + - translator_minimal + slot_uri: RO:0002450 + mappings: + - SEMMEDDB:STIMULATES + + negatively regulates, entity to entity: + aliases: ['activity directly negatively regulates activity of'] + is_a: regulates, entity to entity + mixins: + - negatively regulates + local_names: + translator: negatively regulates + ro: activity directly negatively regulates activity of + in_subset: + - translator_minimal + slot_uri: RO:0002449 + mappings: + - SEMMEDDB:INHIBITS + + disrupts: + is_a: affects + description: >- + describes a relationship where one entity degrades or interferes with the structure, function, or occurrence of another. + in_subset: + - translator_minimal + slot_uri: SEMMEDDB:DISRUPTS + + has gene product: + is_a: related to + description: >- + holds between a gene and a transcribed and/or translated product generated from it + domain: gene + range: gene product + in_subset: + - translator_minimal + slot_uri: RO:0002205 + mappings: + - WD:P688 + + homologous to: + is_a: related to + aliases: ['in homology relationship with'] + description: >- + holds between two biological entities that have common evolutionary origin + comments: + - typically used to describe homology relationships between genes or gene products + in_subset: + - translator_minimal + slot_uri: RO:HOM0000001 + mappings: + - SIO:010302 + + paralogous to: + is_a: homologous to + description: >- + a homology relationship that holds between entities (typically genes) that diverged after a duplication event. + in_subset: + - translator_minimal + slot_uri: RO:HOM0000011 + + orthologous to: + is_a: homologous to + description: >- + a homology relationship between entities (typically genes) that diverged after a speciation event. + in_subset: + - translator_minimal + slot_uri: RO:HOM0000017 + mappings: + - WD:P684 + + xenologous to: + is_a: homologous to + description: >- + a homology relationship characterized by an interspecies (horizontal) transfer since the common ancestor. + in_subset: + - translator_minimal + slot_uri: RO:HOM0000018 + + coexists with: + is_a: related to + description: >- + holds between two entities that are co-located in the same aggregate object, process, or spatio-temporal region + in_subset: + - translator_minimal + slot_uri: SEMMEDDB:COEXISTS_WITH + + in pathway with: + description: >- + holds between two genes or gene products that are part of in the same biological pathway + is_a: coexists with + domain: gene or gene product + range: gene or gene product + in_subset: + - translator_minimal + + in complex with: + description: >- + holds between two genes or gene products that are part of (or code for products that are part of) in the same macromolecular complex + is_a: coexists with + domain: gene or gene product + range: gene or gene product + in_subset: + - translator_minimal + + in cell population with: + description: >- + holds between two genes or gene products that are expressed in the same cell type or population + is_a: coexists with + domain: gene or gene product + range: gene or gene product + in_subset: + - translator_minimal + + colocalizes with: + description: >- + holds between two entities that are observed to be located in the same place. + is_a: coexists with + in_subset: + - translator_minimal + slot_uri: RO:00002325 + + gene associated with condition: + is_a: related to + description: >- + holds between a gene and a disease or phenotypic feature that the gene or its alleles/products may influence, contribute to, or correlate with + domain: gene + range: disease or phenotypic feature + in_subset: + - translator_minimal + slot_uri: WD:P2293 + + affects risk for: + is_a: related to + description: >- + holds between two entities where exposure to one entity alters the chance of developing the other + in_subset: + - translator_minimal + + predisposes: + is_a: affects risk for + description: >- + holds between two entities where exposure to one entity increases the chance of developing the other + in_subset: + - translator_minimal + slot_uri: SEMMEDDB:PREDISPOSES + + contributes to: + is_a: related to + description: >- + holds between two entities where the occurrence, existence, or activity of one causes or contributes to the occurrence or generation of the other + in_subset: + - translator_minimal + slot_uri: RO:0002326 + + causes: + description: >- + holds between two entities where the occurrence, existence, or activity of one causes the occurrence or generation of the other + is_a: contributes to + in_subset: + - translator_minimal + slot_uri: RO:0002410 + mappings: + - SEMMEDDB:CAUSES + - WD:P1542 + + treats: + aliases: ['is substance that treats'] + is_a: affects + description: >- + holds between a therapeutic procedure or chemical substance and a disease or phenotypic feature that it is used to treat + domain: treatment + required: true + range: disease or phenotypic feature + in_subset: + - translator_minimal + inverse: treated by + slot_uri: RO:0002606 + mappings: + - RO:0003307 + - SEMMEDDB:TREATS + - WD:P2175 + + prevents : + is_a: affects risk for + description: >- + holds between an entity whose application or use reduces the likelihood of a potential outcome. + Typically used to associate a chemical substance, exposure, activity, or medical intervention that can prevent + the onset a disease or phenotypic feature. + in_subset: + - translator_minimal + slot_uri: RO:0002599 + mappings: + - SEMMEDDB:PREVENTS + + correlated with: + is_a: related to + description: >- + holds between a disease or phenotypic feature and a measurable molecular entity that is used as an indicator of the presence or state of the disease or feature. + domain: disease or phenotypic feature + range: molecular entity + in_subset: + - translator_minimal + slot_uri: RO:0002610 + + has biomarker: + is_a: correlated with + description: >- + holds between a disease or phenotypic feature and a measurable molecular entity that is used as an indicator of the presence or state of the disease or feature. + domain: disease or phenotypic feature + range: molecular entity + in_subset: + - translator_minimal + inverse: biomarker for + + biomarker for: + is_a: correlated with + description: >- + holds between a measurable molecular entity and a disease or phenotypic feature, where the entity is used as an indicator of the presence or state of the disease or feature. + domain: molecular entity + range: disease or phenotypic feature + in_subset: + - translator_minimal + inverse: has biomarker + slot_uri: RO:0002607 + + treated by: + is_a: related to + description: >- + holds between a disease or phenotypic feature and a therapeutic process or chemical substance that is used to treat the condition + domain: disease or phenotypic feature + in_subset: + - translator_minimal + inverse: treats + slot_uri: RO:0002302 + mappings: + - WD:P2176 + + expressed in: + is_a: related to + description: >- + holds between a gene or gene product and an anatomical entity in which it is expressed + domain: gene or gene product + range: anatomical entity + in_subset: + - translator_minimal + inverse: expresses + slot_uri: RO:0002206 + + expresses: + is_a: related to + description: >- + holds between an anatomical entity and gene or gene product that is expressed there + domain: anatomical entity + range: gene or gene product + in_subset: + - translator_minimal + inverse: expressed in + slot_uri: RO:0002292 + + has phenotype: + is_a: related to + description: >- + holds between a biological entity and a phenotype, where a phenotype is construed broadly as any kind of quality of an organism part, a collection of these qualities, or a change in quality or qualities (e.g. abnormally increased temperature). + domain: biological entity + range: phenotypic feature + notes: + - check the range + in_subset: + - translator_minimal + slot_uri: RO:0002200 + + occurs in: + is_a: related to + description: >- + holds between a process and a material entity or site within which the process occurs + in_subset: + - translator_minimal + slot_uri: BFO:0000066 + mappings: + - SEMMEDDB:OCCURS_IN + - SEMMEDDB:PROCESS_OF + + located in: + is_a: related to + description: >- + holds between a material entity and a material entity or site within which it is located (but of which it is not considered a part) + in_subset: + - translator_minimal + inverse: location of + slot_uri: RO:0001025 + + location of: + is_a: related to + description: >- + holds between material entity or site and a material entity that is located within it (but not considered a part of it) + in_subset: + - translator_minimal + inverse: located in + slot_uri: RO:0001015 + mappings: + - SEMMEDDB:LOCATION_OF + - WD:276 + + model of: + is_a: related to + description: >- + holds between an entity and some other entity it approximates for purposes of scientific study, in virtue of its exibiting similar features of the studied entity. + in_subset: + - translator_minimal + slot_uri: RO:0003301 + + overlaps: + is_a: related to + description: >- + holds between entties that overlap in their extents (materials or processes) + in_subset: + - translator_minimal + slot_uri: RO:0002131 + + has part: + is_a: overlaps + description: >- + holds between wholes and their parts (material entities or processes) + in_subset: + - translator_minimal + inverse: part of + slot_uri: BFO:0000051 + mappings: + - WD:P527 + + part of: + is_a: overlaps + description: >- + holds between parts and wholes (material entities or processes) + in_subset: + - translator_minimal + inverse: has part + slot_uri: BFO:0000050 + mappings: + - SEMMEDDB:PART_OF + - WD:P361 + + has participant: + is_a: related to + description: >- + holds between a process and a continuant, where the continuant is somehow involved in the process + domain: occurrent + in_subset: + - translator_minimal + inverse: participates in + slot_uri: RO:0000057 + mappings: + - WD:P2283 + + has input: + is_a: has participant + description: >- + holds between a process and a continuant, where the continuant is an input into the process + domain: occurrent + in_subset: + - translator_minimal + slot_uri: RO:0002233 + mappings: + - SEMMEDDB:USES + + participates in: + is_a: related to + description: >- + holds between a continuant and a process, where the continuant is somehow involved in the process + range: occurrent + in_subset: + - translator_minimal + inverse: has participant + slot_uri: RO:0000056 + + actively involved in: + is_a: participates in + description: >- + holds between a continuant and a process or function, where the continuant actively contributes to part or all of the process or function it realizes + range: occurrent + in_subset: + - translator_minimal + slot_uri: RO:0002331 + + capable of: + is_a: actively involved in + description: >- + holds between a continuant and process or function, where the continuant alone has the ability to carry out the process or function. + range: occurrent + in_subset: + - translator_minimal + slot_uri: RO:0002215 + + derives into: + is_a: related to + description: >- + holds between two distinct material entities, the old entity and the new entity, in which the new entity begins to exist when the old entity ceases to exist, and the new entity inherits the significant portion of the matter of the old entity + in_subset: + - translator_minimal + inverse: derives from + slot_uri: RO:0001001 + mappings: + - SEMMEDDB:CONVERTS_TO + + derives from: + is_a: related to + description: >- + holds between two distinct material entities, the new entity and the old entity, in which the new entity begins to exist when the old entity ceases to exist, and the new entity inherits the significant portion of the matter of the old entity + in_subset: + - translator_minimal + inverse: derives into + slot_uri: RO:0001000 + + manifestation of: + is_a: related to + description: >- + used in SemMedDB for linking things like dysfunctions and processes to some disease or syndrome + range: disease + in_subset: + - translator_minimal + slot_uri: SEMMEDDB:MANIFESTATION_OF + mappings: + - WD:P1557 + + produces: + is_a: related to + description: >- + holds between a material entity and a product that is generated through the intentional actions or functioning of the material entity + in_subset: + - translator_minimal + slot_uri: RO:0003000 + mappings: + - WD:P1056 + - SEMMEDDB:PRODUCES + + precedes: + is_a: related to + description: >- + holds between two processes, where one completes before the other begins + domain: occurrent + range: occurrent + in_subset: + - translator_minimal + slot_uri: BFO:0000063 + mappings: + - SEMMEDDB:PRECEDES + - WD:P156 + + same as: + is_a: related to + description: >- + holds between two entities that are considered equivalent to each other + in_subset: + - translator_minimal + slot_uri: owl:equivalentClass + mappings: + - owl:sameAs + - skos:exactMatch + - WD:P2888 + + subclass of: + is_a: related to + description: >- + holds between two classes where the domain class is a specialization of the range class + domain: ontology class + range: ontology class + in_subset: + - translator_minimal + slot_uri: rdfs:subClassOf + mappings: + - SEMMEDDB:IS_A + - WD:P279 + +## property slots + + node property: + description: >- + A grouping for any property that holds between a node and a value + domain: named thing + + title: + is_a: node property + domain: data set version + slot_uri: dct:title + + source data file: + is_a: node property + domain: data set version + range: data file + slot_uri: dcterms:source + + source web page: + is_a: node property + domain: data set summary + slot_uri: dcterms:source + + retrievedOn: + is_a: node property + domain: source file + range: date + slot_uri: pav:retrievedOn + + versionOf: + is_a: node property + domain: data set version + range: data set + slot_uri: dct:isVersionOf + + source version: + is_a: node property + domain: source file + slot_uri: pav:version + + downloadURL: + is_a: node property + domain: distribution level + slot_uri: dct:downloadURL + + distribution: + is_a: node property + domain: data set version + range: distribution level + slot_uri: void:Dataset + + type: + is_a: node property + slot_uri: rdf:type + + id: + is_a: node property + identifier: true + description: >- + A unique identifier for a thing. + Must be either a CURIE shorthand for a URI or a complete URI + in_subset: + - translator_minimal + domain: named thing + range: identifier type + required: true + + association_id: + is_a: node property + identifier: true + description: >- + A unique identifier for an association + in_subset: + - translator_minimal + domain: association + range: identifier type + alias: id + + iri: + is_a: node property + description: >- + An IRI for the node. This is determined by the id using expansion rules. + in_subset: + - translator_minimal + domain: named thing + range: iri type + + name: + is_a: node property + aliases: ['label', 'display name'] + domain: named thing + range: label type + description: >- + A human-readable name for a thing + in_subset: + - translator_minimal + required: true + slot_uri: rdfs:label + + synonym: + is_a: node property + aliases: ['alias'] + domain: named thing + range: label type + description: >- + Alternate human-readable names for a thing + multivalued: true + in_subset: + - translator_minimal + + category: + is_a: node property + domain: named thing + range: iri type + description: >- + Name of the high level ontology class in which this entity is categorized. Corresponds to the label for the biolink entity type class. + In a neo4j database this MAY correspond to the neo4j label tag + is_class_field: true + multivalued: true + in_subset: + - translator_minimal + required: true + slot_uri: rdfs:subClassOf + + full name: + is_a: node property + domain: named thing + range: label type + description: >- + a long-form human readable name for a thing + + description: + is_a: node property + domain: named thing + range: narrative text + description: >- + a human-readable description of a thing + in_subset: + - translator_minimal + slot_uri: dcterms:description + + systematic synonym: + is_a: node property + domain: named thing + range: label type + description: >- + more commonly used for gene symbols in yeast + + association slot: + abstract: true + domain: association + aliases: ['edge property', 'statement property'] + description: >- + any slot that relates an association to another entity + + subject: + is_a: association slot + local_names: + ga4gh: annotation subject + neo4j: node with outgoing relationship + description: >- + connects an association to the subject of the association. + For example, in a gene-to-phenotype association, the gene is subject and phenotype is object. + required: true + range: iri type + slot_uri: rdf:subject + mappings: + - owl:annotatedSource + - oban:association_has_subject + + object: + is_a: association slot + description: >- + connects an association to the object of the association. + For example, in a gene-to-phenotype association, the gene is subject and phenotype is object. + required: true + range: iri type + local_names: + ga4gh: descriptor + neo4j: node with incoming relationship + slot_uri: rdf:object + mappings: + - owl:annotatedTarget + - oban:association_has_object + + edge label: + is_a: association slot + description: >- + A high-level grouping for the relationship type. AKA minimal predicate. + This is analogous to category for nodes. + domain: association + notes: + - in neo4j this corresponds to the relationship type and the convention is for a snake_case label + range: label type + required: true + + relation: + is_a: association slot + description: >- + the relationship type by which a subject is connected to an object in an association + domain: association + range: iri type + required: true + local_names: + ga4gh: annotation predicate + translator: predicate + slot_uri: rdf:predicate + mappings: + - "owl:annotatedProperty" + - "oban:association_has_predicate" + + negated: + is_a: association slot + range: boolean + description: >- + if set to true, then the association is negated i.e. is not true + + has confidence level: + is_a: association slot + range: confidence level + description: >- + connects an association to a qualitative term denoting the level of confidence + + has evidence: + is_a: association slot + range: evidence type + description: >- + connects an association to an instance of supporting evidence + slot_uri: RO:0002558 + + provided by: + is_a: association slot + range: provider + description: >- + connects an association to the agent (person, organization or group) that provided it + slot_uri: pav:providedBy + + association type: + is_a: association slot + range: ontology class + description: >- + connects an association to the type of association (e.g. gene to phenotype) + slot_uri: rdf:type + + creation date: + is_a: node property + range: date + description: >- + date on which thing was created. This can be applied to nodes or edges + slot_uri: dcterms:created + + update date: + is_a: node property + range: date + description: >- + date on which thing was updated. This can be applied to nodes or edges + + in taxon: + is_a: related to + domain: thing with taxon + range: organism taxon + description: >- + connects a thing to a class representing a taxon + in_subset: + - translator_minimal + slot_uri: RO:0002162 + mappings: + - WD:P703 + + latitude: + is_a: node property + range: float + description: >- + latitude + slot_uri: wgs:lat + + longitude: + is_a: node property + range: float + description: >- + longitude + slot_uri: wgs:long + + has chemical formula: + is_a: node property + range: chemical formula value + description: >- + description of chemical compound based on element symbols + slot_uri: WD:P274 + + aggregate statistic: + is_a: node property + abstract: true + + has count: + description: >- + number of things with a particular property + is_a: aggregate statistic + range: integer + + has total: + description: >- + total number of things in a particular reference set + is_a: aggregate statistic + range: integer + + has quotient: + is_a: aggregate statistic + range: double + + has percentage: + description: >- + equivalent to has quotient multiplied by 100 + is_a: aggregate statistic + range: double + + timepoint: + is_a: node property + range: time type + description: >- + a point in time + + stage qualifier: + is_a: association slot + range: life stage +# path: "object/during" + description: >- + stage at which expression takes place + + quantifier qualifier: + is_a: association slot + range: ontology class + description: >- + A measurable quantity for the object of the association + + qualifiers: + singular_name: qualifier + description: >- + connects an association to qualifiers that modify or qualify the meaning of that association + local_names: + ga4gh: annotation qualifier + is_a: association slot + multivalued: true + range: ontology class + + frequency qualifier: + description: >- + a qualifier used in a phenotypic association to state how frequent the phenotype is observed in the subject + is_a: association slot + range: frequency value + + severity qualifier: + description: >- + a qualifier used in a phenotypic association to state how severe the phenotype is in the subject + is_a: association slot + range: severity value + + sex qualifier: + description: >- + a qualifier used in a phenotypic association to state whether the association is specific to a particular sex. + is_a: association slot + range: biological sex + + onset qualifier: + description: >- + a qualifier used in a phenotypic association to state when the phenotype appears is in the subject + is_a: association slot + range: onset + + clinical modifier qualifier: + description: >- + Used to characterize and specify the phenotypic abnormalities defined in the Phenotypic abnormality subontology, + with respect to severity, laterality, age of onset, and other aspects + is_a: association slot + range: clinical modifier + + sequence variant qualifier: + description: >- + a qualifier used in an association where the variant + is_a: association slot + range: sequence variant + + publications: + singular_name: publication + description: >- + connects an association to publications supporting the association + is_a: association slot + multivalued: true + range: publication + + has biological sequence: + is_a: node property + description: >- + connects a genomic feature to its sequence + range: biological sequence + + has molecular consequence: + is_a: related to + description: >- + connects a sequence variant to a class describing the molecular + consequence. E.g. SO:0001583 + range: ontology class + + ## genotypes + + has gene: + is_a: node property + description: >- + connects and entity to a single gene + range: gene + + has zygosity: + is_a: node property +# domain: single locus feature complement + range: zygosity + + filler: + is_a: node property + range: named thing + description: >- + The value in a property-value tuple + + phase: + is_a: node property + description: >- + TODO + + genome build: + is_a: node property + description: >- + TODO + + interbase coordinate: + is_a: node property + description: >- + TODO + + start interbase coordinate: + is_a: interbase coordinate + + end interbase coordinate: + is_a: interbase coordinate + + +classes: + + attribute: + subclass_of: PATO:0000001 + mixins: + - ontology class + description: >- + A property or characteristic of an entity + + ## ------ + ## THINGS + ## ------ + + biological sex: + subclass_of: "PATO:0000047" + is_a: attribute + + phenotypic sex: + description: >- + An attribute corresponding to the phenotypic sex of the individual, based upon the reproductive organs present. + subclass_of: "PATO:0001894" + is_a: biological sex + + genotypic sex: + description: >- + An attribute corresponding to the genotypic sex of the individual, based upon genotypic composition of sex chromosomes. + subclass_of: "PATO:0020000" + is_a: biological sex + + severity value: + description: >- + describes the severity of a phenotypic feature or disease + is_a: attribute + + frequency value: + description: >- + describes the frequency of occurrence of an event or condition + is_a: attribute + + clinical modifier: + description: >- + Used to characterize and specify the phenotypic abnormalities defined in the Phenotypic abnormality subontology, + with respect to severity, laterality, age of onset, and other aspects + subclass_of: "HP:0012823" + is_a: attribute + + onset: + description: >- + The age group in which manifestations appear + class_uri: HP:0003674 + is_a: attribute + + relationship quantifier: + abstract: true + mixin: true + + sensitivity quantifier: + is_a: relationship quantifier + mixin: true + + specificity quantifier: + is_a: relationship quantifier + mixin: true + + pathognomonicity quantifier: + is_a: specificity quantifier + description: >- + A relationship quantifier between a variant or symptom and a disease, which is + high when the presence of the feature implies the existence of the disease + mixin: true + + frequency quantifier: + is_a: relationship quantifier + mixin: true + slots: + - has count + - has total + - has quotient + - has percentage + + named thing: + description: "a databased entity or concept/class" + slots: + - id + - name + - category + subclass_of: BFO:0000001 + class_uri: WD:Q35120 + mappings: + # UMLS Semantic Group "Objects" + - UMLSSG:OBJC + # Entity + - UMLSSC:T071 + - UMLSST:enty + # Physical Object + - UMLSSC:T072 + - UMLSST:phob + # Manufactured Object + - UMLSSC:T073 + - UMLSST:mnob + # Food + - UMLSSC:T168 + - UMLSST:food + + data file: + is_a: named thing + class_uri: EFO:0004095 + + source file: + is_a: data file + slots: + - source version + - retrievedOn + +# data set descriptor: +# abstract: true +# mixin: true + + data set: + is_a: named thing + class_uri: IAO:0000100 + + data set version: + is_a: data set + slots: + - title +# - description + - source data file + - versionOf + - type + - distribution + + distribution level: + is_a: data set version + mixin: true + slots: + - downloadURL + + data set summary: + is_a: data set version + mixin: true + slots: + - source web page + + biological entity: + is_a: named thing + abstract: true + class_uri: WD:Q28845870 + mappings: + # UMLS Semantic Type "Experimental Model of Disease" + - UMLSSC:T050 + - UMLSST:emod + + ontology class: + is_a: named thing + description: "a concept or class in an ontology, vocabulary or thesaurus" + + relationship type: + is_a: ontology class + description: >- + An OWL property used as an edge label + + gene ontology class: + description: >- + an ontology class that describes a functional aspect of a gene, gene prodoct or complex + is_a: ontology class + in_subset: + - testing + + thing with taxon: + abstract: true + mixin: true + description: >- + A mixin that can be used on any entity with a taxon + slots: + - in taxon + + organism taxon: + is_a: ontology class + values_from: + - NCBITaxon + class_uri: WD:Q16521 + + organismal entity: + description: >- + A named entity that is either a part of an organism, a whole organism, population or clade of organisms, excluding molecular entities + abstract: true + is_a: biological entity + class_uri: WD:Q7239 + + individual organism: + mixins: + - thing with taxon + is_a: organismal entity + subclass_of: "NCBITaxon:1" + class_uri: SIO:010000 + mappings: + - WD:Q795052 + # UMLS Semantic Group "Living Beings" + # Several of the associated semantic types here are probably not + # that relevant to the Biolink world but we keep them here for now. + - UMLSSG:LIVB + # Organism + - UMLSSC:T001 + - UMLSST:orgm + # Plant + - UMLSSC:T002 + - UMLSST:plnt + # Fungus + - UMLSSC:T004 + - UMLSST:fngs + # Virus + - UMLSSC:T005 + - UMLSST:virs + # Bacterium + - UMLSSC:T007 + - UMLSST:bact + # Animal + - UMLSSC:T008 + - UMLSST:anim + # Vertebrate + - UMLSSC:T010 + - UMLSST:vtbt + # Amphibian + - UMLSSC:T011 + - UMLSST:amph + # Bird + - UMLSSC:T012 + - UMLSST:bird + # Fish + - UMLSSC:T013 + - UMLSST:fish + # Reptile + - UMLSSC:T014 + - UMLSST:rept + # Mammal + - UMLSSC:T015 + - UMLSST:mamm + # Human + - UMLSSC:T016 + - UMLSST:humn + # Group + - UMLSSC:T096 + - UMLSST:grup + # Professional or Occupational Group + - UMLSSC:T097 + - UMLSST:prog + # Family Group + - UMLSSC:T099 + - UMLSST:famg + # Age Group + - UMLSSC:T100 + - UMLSST:aggp + # Patient or Disabled Group + - UMLSSC:T101 + - UMLSST:podg + # Archaeon + - UMLSSC:T194 + - UMLSST:arch + # Eukaryote + - UMLSSC:T204 + - UMLSST:euka + + case: + aliases: ['patient', 'proband'] + is_a: individual organism + description: >- + An individual organism that has a patient role in some clinical context. + + population of individual organisms: + description: >- + A collection of individuals from the same taxonomic class distinguished by one or more characteristics. + Characteristics can include, but are not limited to, shared geographic location, genetics, phenotypes [Alliance for Genome Resources] + local_names: + ga4gh: population + agr: population + mixins: + - thing with taxon + is_a: organismal entity + subclass_of: PCO:0000001 + class_uri: SIO:001061 + mappings: + # UMLS Semantic Type "Population Group" + - UMLSSC:T098 + - UMLSST:popg + id_prefixes: + - HANCESTRO + + biosample: + aliases: ['biospecimen', 'sample'] + mixins: + - thing with taxon + is_a: organismal entity + class_uri: SIO:001050 + + disease or phenotypic feature: + aliases: ['phenome'] + is_a: biological entity + description: >- + Either one of a disease or an individual phenotypic feature. Some knowledge resources such as Monarch treat these as distinct, others such as MESH conflate. + mixins: + - thing with taxon + union_of: + - disease + - phenotypic feature + mappings: + # UMLS Semantic Type "Finding" + - UMLSSC:T033 + - UMLSST:fndg + + disease: + aliases: ['condition', 'disorder', 'medical condition'] + is_a: disease or phenotypic feature + class_uri: MONDO:0000001 + mappings: + - WD:Q12136 + - SIO:010299 + # UMLS Semantic Group "Disorders" + - UMLSSG:DISO + # Congenital Abnormality + - UMLSSC:T019 + - UMLSST:cgab + # Acquired Abnormality + - UMLSSC:T020 + - UMLSST:acab + # Injury or Poisoning + - UMLSSC:T037 + - UMLSST:inpo + # Pathologic Function + - UMLSSC:T046 + - UMLSST:patf + # Disease or Syndrome + - UMLSSC:T047 + - UMLSST:dsyn + # Mental or Behavioral Dysfunction + - UMLSSC:T048 + - UMLSST:mobd + # Cell or Molecular Dysfunction + - UMLSSC:T049 + - UMLSST:comd + # Sign or Symptom + - UMLSSC:T184 + - UMLSST:sosy + # Anatomical Abnormality + - UMLSSC:T190 + - UMLSST:anab + # Neoplastic Process + - UMLSSC:T191 + - UMLSST:neop + + phenotypic feature: + aliases: ['sign', 'symptom', 'phenotype', 'trait', 'endophenotype'] + is_a: disease or phenotypic feature + subclass_of: UPHENO:0001001 + class_uri: UPHENO:0001001 + mappings: + - SIO:010056 + - WD:Q169872 + + environment: + aliases: ['environment', 'exposure', 'experimental condition'] + is_a: biological entity + description: >- + A feature of the environment of an organism that influences one or more phenotypic features + of that organism, potentially mediated by genes + class_uri: SIO:000955 + + information content entity: + aliases: ['information', 'information artefact', 'information entity'] + abstract: true + is_a: named thing + description: >- + a piece of information that typically describes some piece of biology or is used as support. + class_uri: IAO:0000030 + mappings: + # UMLS Semantic Group "Concepts & Ideas" + - UMLSSG:CONC + # Conceptual Entity + - UMLSSC:T077 + - UMLSST:cnce + # Idea or Concept + - UMLSSC:T078 + - UMLSST:idcn + # Temporal Concept + - UMLSSC:T079 + - UMLSST:tmco + # Qualitative Concept + - UMLSSC:T080 + - UMLSST:qlco + # Quantitative Concept + - UMLSSC:T081 + - UMLSST:qnco + # Spatial Concept + - UMLSSC:T082 + - UMLSST:spco + # Regulation or Law + - UMLSSC:T089 + - UMLSST:rnlw + # Group Attribute + - UMLSSC:T102 + - UMLSST:grpa + # Functional Concept + - UMLSSC:T169 + - UMLSST:ftcn + # Language + - UMLSSC:T171 + - UMLSST:lang + # Classification + - UMLSSC:T185 + - UMLSST:clas + + confidence level: + is_a: information content entity + description: >- + Level of confidence in a statement + values_from: + - cio + class_uri: CIO:0000028 + + evidence type: + is_a: information content entity + aliases: ['evidence code'] + description: >- + Class of evidence that supports an association + values_from: + - eco + class_uri: ECO:0000000 + + publication: + is_a: information content entity + aliases: ['reference'] + description: >- + Any published piece of information. Can refer to a whole publication, + or to a part of it (e.g. a figure, figure legend, or section highlighted by NLP). + The scope is intended to be general and include information published on the web as well as journals. + class_uri: IAO:0000311 + mappings: + # UMLS Semantic Type "Intellectual Product" + - UMLSSC:T170 + - UMLSST:inpr + + id_prefixes: + - PMID + + administrative entity: + is_a: named thing + abstract: true + + provider: + is_a: administrative entity + aliases: ['agent', 'group'] + description: >- + person, group, organization or project that provides a piece of information + mappings: # Organizations + - UMLSSG:ORGA + # Organization + - UMLSSC:T092 + - UMLSST:orgt + # Health Care Related Organization + - UMLSSC:T093 + - UMLSST:hcro + # Professional Society + - UMLSSC:T094 + - UMLSST:pros + # Self-help or Relief Organization + - UMLSSC:T095 + - UMLSST:shro + + molecular entity: + is_a: biological entity + mixins: + - thing with taxon + aliases: ['bioentity'] + description: "A gene, gene product, small molecule or macromolecule (including protein complex)" + #notes: + # - "Check SIO mapping - also mapped to chemical substance.": Resolved by changing SIO:010004 to SIO:010341 + class_uri: SIO:010341 + mappings: + - WD:Q43460564 + # UMLS Semantic Group "Genes & Molecular Sequences" + - UMLSSG:GENE + # Molecular Sequence + - UMLSSC:T085 + - UMLSST:mosq + + chemical substance: + is_a: molecular entity + description: >- + May be a chemical entity or a formulation with a chemical entity as active ingredient, or a complex + material with multiple chemical entities as part + subclass_of: "CHEBI:24431" + class_uri: SIO:010004 + mappings: + - WD:Q79529 + # UMLS Semantic Type "Substance" + - UMLSSC:T167 + - UMLSST:sbst + # UMLS Semantic Group "Chemicals & Drugs" + - UMLSSG:CHEM + # Chemical + - UMLSSC:T103 + - UMLSST:chem + # Chemical Viewed Structurally + - UMLSSC:T104 + - UMLSST:chvs + # Organic Chemical + - UMLSSC:T109 + - UMLSST:orch + # Nucleic Acid, Nucleoside, or Nucleotide + - UMLSSC:T114 + - UMLSST:nnon + # Chemical Viewed Functionally + - UMLSSC:T120 + - UMLSST:chvf + # Pharmacologic Substance + - UMLSSC:T121 + - UMLSST:phsu + # Biomedical or Dental Material + - UMLSSC:T122 + - UMLSST:bodm + # Biologically Active Substance + - UMLSSC:T123 + - UMLSST:bacs + # Hormone + - UMLSSC:T125 + - UMLSST:horm + # Enzyme + - UMLSSC:T126 + - UMLSST:enzy + # Vitamin + - UMLSSC:T127 + - UMLSST:vita + # Immunologic Factor + - UMLSSC:T129 + - UMLSST:imft + # Indicator, Reagent, or Diagnostic Aid + - UMLSSC:T130 + - UMLSST:irda + # Hazardous or Poisonous Substance + - UMLSSC:T131 + - UMLSST:hops + # Receptor + - UMLSSC:T192 + - UMLSST:rcpt + # Antibiotic + - UMLSSC:T195 + - UMLSST:antb + # Element, Ion, or Isotope + - UMLSSC:T196 + - UMLSST:elii + # Inorganic Chemical + - UMLSSC:T197 + - UMLSST:inch + id_prefixes: + - CHEBI + - CHEMBL.COMPOUND + + carbohydrate: + is_a: chemical substance + mappings: + # UMLS Semantic Type "Carbohydrate Sequence" + - UMLSSC:T088 + - UMLSST:crbs + + drug: + is_a: chemical substance + description: >- + A substance intended for use in the diagnosis, cure, mitigation, treatment, or prevention of disease + comments: + - The CHEBI ID represents a role rather than a substance + class_uri: WD:Q12140 + mappings: + - CHEBI:23888 + # UMLS Semantic Type "Clinical Drug" + - UMLSSC:T200 + - UMLSST:clnd + + metabolite: + is_a: chemical substance + description: >- + Any intermediate or product resulting from metabolism. Includes primary and secondary metabolites. + comments: + - The CHEBI ID represents a role rather than a substance + class_uri: CHEBI:25212 +# +# attribute: +# subclass_of: PATO:0000001 +# mixins: +# - ontology class +# description: >- +# A property or characteristic of an entity + + anatomical entity: + is_a: organismal entity + mixins: + - thing with taxon + subclass_of: UBERON:0001062 + description: >- + A subcellular location, cell type or gross anatomical part + class_uri: SIO:010046 + mappings: + - WD:Q4936952 + # UMLS Semantic Group "Anatomy" + - UMLSSG:ANAT + # Body System + - UMLSSC:T022 + - UMLSST:bdsy + # Body Location or Region + - UMLSSC:T029 + - UMLSST:blor + # Body Space or Junction + - UMLSSC:T030 + - UMLSST:bsoj + # Body Substance + - UMLSSC:T031 + - UMLSST:bdsu + + life stage: + is_a: organismal entity + mixins: + - thing with taxon + subclass_of: UBERON:0000105 + description: >- + A stage of development or growth of an organism, including post-natal adult stages + + planetary entity: + is_a: named thing + description: >- + Any entity or process that exists at the level of the whole planet + + environmental process: + is_a: planetary entity + mixins: + - occurrent + subclass_of: ENVO:02500000 + + environmental feature: + is_a: planetary entity + subclass_of: ENVO:00002297 + + clinical entity: + is_a: named thing + description: >- + Any entity or process that exists in the clinical domain and outside the biological realm. Diseases are placed under biological entities + + clinical trial: + is_a: clinical entity + + clinical intervention: + is_a: clinical entity + + device: + is_a: named thing + description: >- + A thing made or adapted for a particular purpose, especially a piece of mechanical or electronic equipment + mappings: # Devices + - UMLSSG:DEVI + # Medical Device + - UMLSSC:T074 + - UMLSST:medd + # Research Device + - UMLSSC:T075 + - UMLSST:resd + # Drug Delivery Device + - UMLSSC:T203 + - UMLSST:drdd + + genomic entity: + is_a: molecular entity + aliases: ['sequence feature'] + description: >- + an entity that can either be directly located on a genome (gene, transcript, exon, regulatory region) or is encoded in a genome (protein) + slots: + - has biological sequence + class_uri: SO:0000110 + mappings: + # Gene or Genome + - UMLSSC:T028 + - UMLSST:gngm + # Nucleotide Sequence + - UMLSSC:T086 + - UMLSST:nusq + genome: + is_a: genomic entity + description: >- + A genome is the sum of genetic material within a cell or virion. + class_uri: SO:0001026 + mappings: + - SIO:000984 + - WD:Q7020 + + transcript: + is_a: genomic entity + description: >- + An RNA synthesized on a DNA or RNA template by an RNA polymerase + class_uri: SO:0000673 + mappings: + - SIO:010450 + + exon: + is_a: genomic entity + description: >- + A region of the transcript sequence within a gene which is not removed from the primary RNA transcript by RNA splicing + class_uri: SO:0000147 + mappings: + - SIO:010445 + - WD:Q373027 + + coding sequence: + is_a: genomic entity + class_uri: SO:0000316 + mappings: + - SIO:001390 + + macromolecular machine: + is_a: genomic entity + union_of: + - gene + - gene product + - macromolecular complex + description: >- + A union of gene, gene product, and macromolecular complex. + These are the basic units of function in a cell. They either carry out individual + biological activities, or they encode molecules which do this. + slot_usage: + name: + range: symbol type + description: >- + genes are typically designated by a short symbol and a full name. We map the symbol to the default display name + and use an additional slot for full name + + gene or gene product: + is_a: macromolecular machine + union_of: + - gene + - gene product + description: >- + a union of genes or gene products. + Frequently an identifier for one will be used as proxy for another + id_prefixes: + - CHEMBL.TARGET + + gene: + is_a: gene or gene product + aliases: ['locus'] + class_uri: SO:0000704 + mappings: + - SIO:010035 + - WD:Q7187 + id_prefixes: + - NCBIGene + - ENSEMBL + - HGNC + - MGI + - ZFIN + - dictyBase + - WB + - SGD + - PomBase + + gene product: + is_a: gene or gene product + description: >- + The functional molecular product of a single gene. Gene products are either proteins or functional RNA molecules + union_of: + - protein + - RNA product + class_uri: WD:Q424689 + + protein: + is_a: gene product + aliases: ['polypeptide'] + description: >- + A gene product that is composed of a chain of amino acid sequences and is produced by ribosome-mediated translation of mRNA + class_uri: PR:000000001 + mappings: + - SIO:010043 + - WD:Q8054 + # UMLS Semantic Type: "Amino Acid Sequence" + - UMLSSC:T087 + - UMLSST:amas + # Amino Acid, Peptide, or Protein + - UMLSSC:T116 + - UMLSST:aapp + id_prefixes: + - UniProtKB + - PR + - ENSEMBL + + gene product isoform: + is_a: gene product + description: >- + This is an abstract class that can be mixed in with different kinds of gene products to indicate that the gene product is intended to + represent a specific isoform rather than a canonical or reference or generic product. The designation of canonical or reference may be arbitrary, + or it may represent the superclass of all isoforms. +# entity: true + abstract: true + + protein isoform: + aliases: ['proteoform'] + is_a: protein + description: >- + Represents a protein that is a specific isoform of the canonical or reference protein. See https://www.ncbi.nlm.nih.gov/pmc/articles/PMC4114032/ + mixins: + - gene product isoform + id_prefixes: + - UniProtKB + - PR + - ENSEMBL + + RNA product: + is_a: gene product + class_uri: CHEBI:33697 + mappings: + - SIO:010450 + - WD:Q11053 + id_prefixes: + - RNAcentral + + RNA product isoform: + is_a: RNA product + description: >- + Represents a protein that is a specific isoform of the canonical or reference RNA + mixins: + - gene product isoform + id_prefixes: + - RNAcentral + + noncoding RNA product: + is_a: RNA product + id_prefixes: + - RNAcentral + - NCBIGene + - ENSEMBL + subclass_of: SO:0000655 + class_uri: SIO:001235 + + microRNA: + is_a: noncoding RNA product + subclass_of: SO:0000276 + class_uri: SIO:001397 + mappings: + - WD:Q310899 + id_prefixes: + - MIR + + macromolecular complex: + is_a: macromolecular machine + subclass_of: "GO:0032991" + class_uri: SIO:010046 + mappings: + - WD:Q22325163 + id_prefixes: + - IntAct + - GO + - PR + - Reactome + + gene grouping: + abstract: true + mixin: true + description: >- + any grouping of multiple genes or gene products + + gene family: + is_a: molecular entity + class_uri: SIO:001380 + mappings: + - "NCIT:C20130" + - WD:Q417841 + mixins: + - gene grouping + description: >- + any grouping of multiple genes or gene products related by common descent + id_prefixes: + - PANTHER + + zygosity: + is_a: attribute + class_uri: GENO:0000133 + + genotype: + is_a: genomic entity + description: >- + An information content entity that describes a genome by specifying the total variation in genomic sequence and/or gene expression, relative to some extablished background + comments: + - Consider renaming as genotypic entity + slots: + - has zygosity + class_uri: GENO:0000536 + mappings: + - SIO:001079 + + haplotype: + is_a: genomic entity + description: >- + A set of zero or more Alleles on a single instance of a Sequence[VMC] +# slots: +# - completeness + class_uri: GENO:0000871 + mappings: + - VMC:Haplotype + + sequence variant: + aliases: ['allele'] + local_names: + agr: allele + is_a: genomic entity + description: >- + An allele that varies in its sequence from what is considered the reference allele at that locus. + comments: + - >- + This class is for modeling the specific state at a locus. A single dbSNP rs ID could correspond to more + than one sequence variants (e.g CIViC:1252 and CIViC:1253, two distinct BRCA2 alleles for rs28897743) + class_uri: GENO:0000002 + mappings: + - WD:Q15304597 + - SIO:010277 + - VMC:Allele + id_prefixes: + - ClinVar + - WD + - CIViC + alt_descriptions: + AGR: "An enitity that describes a single affected, endogenous allele. These can be of any type that matches that definition" + VMC: "A contiguous change at a Location" + slots: + - has gene + slot_usage: + has gene: + multivalued: true + description: Each allele can be associated with any number of genes + has biological sequence: + description: >- + The state of the sequence w.r.t a reference sequence + id: + examples: + - value: ZFIN:ZDB-ALT-980203-1091 + description: ti282a allele from ZFIN + - value: ClinVarVariant:17681 + description: NM_007294.3(BRCA1):c.2521C>T (p.Arg841Trp) + + drug exposure: + aliases: ['drug intake', 'drug dose'] + is_a: environment + description: >- + A drug exposure is an intake of a particular chemical substance +# slots: +# - has input + slot_usage: + drug: + range: chemical substance + required: true + multivalued: true + class_uri: ECTO:0000509 + mappings: + - SIO:001005 + + treatment: + aliases: ['medical action'] + is_a: environment + description: >- + A treatment is targeted at a disease or phenotype and may involve multiple drug 'exposures' + + slot_usage: + has exposure parts: + multivalued: true + range: drug exposure + required: true + class_uri: OGMS:0000090 + mappings: + - SIO:001398 + + geographic location: + is_a: planetary entity + description: >- + a location that can be described in lat/long coordinates + slots: + - latitude + - longitude + mappings: # Geographic Areas + - UMLSSG:GEOG + # Geographic Area + - UMLSST:geoa + - UMLSSC:T083 + + geographic location at time: + is_a: geographic location + description: >- + a location that can be described in lat/long coordinates, for a particular time + slots: + - timepoint + + ## ------ + ## ASSOCIATIONS + ## ------ + + association: + description: >- + A typed association between two entities, supported by evidence + comments: + - This is roughly the model used by biolink and ontobio at the moment + slots: + - association_id + - subject + - relation + - object + - negated + - association type + - qualifiers + - publications + - provided by + class_uri: OBAN:association + mappings: + - "rdf:Statement" + - "owl:Axiom" + + genotype to genotype part association: + is_a: association + defining_slots: + - subject + - object + description: >- + Any association between one genotype and a genotypic entity that is a sub-component of it + slot_usage: + relation: + subproperty_of: has variant part + subject: + range: genotype + description: >- + parent genotype + object: + range: genotype + description: >- + child genotype + + genotype to gene association: + is_a: association + defining_slots: + - subject + - object + description: >- + Any association between a genotype and a gene. + The genotype have have multiple variants in that gene or a single one. There is no assumption of cardinality + slot_usage: + relation: + description: >- + the relationship type used to connect genotype to gene + subject: + range: genotype + description: >- + parent genotype + object: + range: gene + description: >- + gene implicated in genotype + + genotype to variant association: + is_a: association + defining_slots: + - subject + - object + description: >- + Any association between a genotype and a sequence variant. + slot_usage: + relation: + description: >- + the relationship type used to connect genotype to gene + subject: + range: genotype + description: >- + parent genotype + object: + range: sequence variant + description: >- + gene implicated in genotype + + gene to gene association: + aliases: ['molecular or genetic interaction'] + abstract: true + is_a: association + defining_slots: + - subject + - object + description: >- + abstract parent class for different kinds of gene-gene or gene product to gene product relationships. + Includes homology and interaction. + slot_usage: + subject: + range: gene or gene product + description: >- + the subject gene in the association. If the relation is symmetric, subject vs object is arbitrary. + We allow a gene product to stand as proxy for the gene or vice versa + object: + range: gene or gene product + description: >- + the object gene in the association. If the relation is symmetric, subject vs object is arbitrary. + We allow a gene product to stand as proxy for the gene or vice versa + + + gene to gene homology association: + is_a: gene to gene association + defining_slots: + - subject + - object + - relation + description: >- + A homology association between two genes. May be orthology (in which case the species of subject and object + should differ) or paralogy (in which case the species may be the same) + slot_usage: + relation: + subproperty_of: homologous to + symmetric: true + description: >- + homology relationship type + + + pairwise interaction association: + is_a: association + mixin: true + abstract: true + description: >- + An interaction at the molecular level between two physical entities + defining_slots: + - subject + - object + - relation + slot_usage: + subject: + range: molecular entity + id: + description: >- + identifier for the interaction. This may come from an interaction database such as IMEX. + examples: + - value: WB:WBInteraction000538741 + values_from: + - IMEX + - BioGRID + relation: + subproperty_of: molecularly interacts with +# range: molecularly interacts with + values_from: + - ro + - mi + description: "interaction relationship type" + examples: + - value: RO:0002447 + description: the subject molecular phosphorylates the object molecule + object: + range: molecular entity + interacting molecules category: + # TODO: Is this correct? + range: ontology class +# subclass_of: "MI:1046" + examples: + - value: MI:1048 + description: smallmolecule-protein + + pairwise gene to gene interaction: + is_a: gene to gene association + defining_slots: + - subject + - object + - relation + mixins: + - pairwise interaction association + description: >- + An interaction between two genes or two gene products. + May be physical (e.g. protein binding) or genetic (between genes). + May be symmetric (e.g. protein interaction) or directed (e.g. phosphorylation) + slot_usage: + relation: + subproperty_of: molecularly interacts with + symmetric: true + values_from: + - ro + - mi + description: "interaction relationship type" + + cell line to thing association: + is_a: association + defining_slots: + - subject + abstract: true + description: >- + An relationship between a cell line and another entity + slot_usage: + subject: + range: cell line + + # TODO: figure out what gives with subject ange + cell line to disease or phenotypic feature association: + is_a: association + mixins: + - cell line to thing association + - thing to disease or phenotypic feature association + description: >- + An relationship between a cell line and a disease or a phenotype, where the cell line is derived from an individual with that disease or phenotype + slot_usage: + subject: +# - range: cell line +# - range: disease or phenotypic feature + range: disease or phenotypic feature + + chemical to thing association: + is_a: association + defining_slots: + - subject + abstract: true + description: >- + An interaction between a chemical entity and another entity + slot_usage: + subject: + range: chemical substance + description: "the chemical substance or entity that is an interactor" + + case to thing association: + is_a: association + defining_slots: + - subject + abstract: true + description: >- + An abstract association for use where the case is the subject + slot_usage: + subject: + range: case + description: "the case (e.g. patient) that has the property" + + chemical to disease or phenotypic feature association: + is_a: association + class_uri: SIO:000993 + defining_slots: + - subject + - object + mixins: + - chemical to thing association + - thing to disease or phenotypic feature association + description: >- + An interaction between a chemical entity and a phenotype or disease, where the presence of the chemical gives rise to + or exacerbates the phenotype + slot_usage: + object: + range: disease or phenotypic feature + description: "the disease or phenotype that is affected by the chemical" + + chemical to pathway association: + is_a: association + class_uri: SIO:001250 + defining_slots: + - subject + - object + mixins: + - chemical to thing association + description: >- + An interaction between a chemical entity and a biological process or pathway + slot_usage: + object: + range: pathway + description: "the pathway that is affected by the chemical" + + chemical to gene association: + is_a: association + class_uri: SIO:001257 + defining_slots: + - subject + - object + mixins: + - chemical to thing association + description: >- + An interaction between a chemical entity and a gene or gene product + slot_usage: + object: + range: gene or gene product + description: "the gene or gene product that is affected by the chemical" + + biosample to thing association: + is_a: association + defining_slots: + - subject + abstract: true + description: >- + An association between a biosample and something + slot_usage: + subject: + range: biosample + description: >- + the biosample being described + + biosample to disease or phenotypic feature association: + is_a: association + defining_slots: + - subject + - object + mixins: + - biosample to thing association + - thing to disease or phenotypic feature association + description: >- + An association between a biosample and a disease or phenotype + + frequency qualifier mixin: + mixin: true + description: >- + Qualifier for freqency type associations + slots: + - frequency qualifier + + entity to feature or disease qualifiers: + abstract: true + mixin: true + is_a: frequency qualifier mixin + description: >- + Qualifiers for entity to disease or phenotype associations + slots: + - severity qualifier + - onset qualifier + + entity to phenotypic feature association: + abstract: true + defining_slots: + - object + is_a: association + mixins: + - entity to feature or disease qualifiers + slot_usage: + description: + description: >- + A description of specific aspects of this phenotype, not otherwise + covered by the phenotype ontology class + object: + range: phenotypic feature + description: "phenotypic class" + values_from: ['upheno', 'hp', 'mp', 'wbphenotypic feature'] + examples: + - value: HP:0002487 + description: Hyperkinesis + - value: WBPhenotype:0000180 + description: axon morphology variant + - value: MP:0001569 + description: abnormal circulating bilirubin level + slots: + - sex qualifier + + entity to disease association: + description: >- + mixin class for any association whose object (target node) is a disease + abstract: true + mixin: true + is_a: entity to feature or disease qualifiers + defining_slots: + - object + slot_usage: + object: + range: disease + description: "disease" + examples: + - value: MONDO:0020066 + description: "Ehlers-Danlos syndrome" + + + disease or phenotypic feature association to thing association: + abstract: true + is_a: association + defining_slots: + - subject + slot_usage: + subject: + range: disease or phenotypic feature + description: "disease or phenotype" + examples: + - value: MONDO:0017314 + description: "Ehlers-Danlos syndrome, vascular type" + - value: MP:0013229 + description: "abnormal brain ventricle size" + + disease or phenotypic feature association to location association: + is_a: disease or phenotypic feature association to thing association + description: >- + An association between either a disease or a phenotypic feature and an anatomical entity, + where the disease/feature manifests in that site. + class_uri: NCIT:R100 + slot_usage: + object: + range: anatomical entity + description: "anatomical entity in which the disease or feature is found" + examples: + - value: UBERON:0002048 + description: "lung" + + thing to disease or phenotypic feature association: + abstract: true + is_a: association + defining_slots: + - object + slot_usage: + object: + range: disease or phenotypic feature + description: "disease or phenotype" + examples: + - value: MONDO:0017314 + description: "Ehlers-Danlos syndrome, vascular type" + - value: MP:0013229 + description: "abnormal brain ventricle size" + + disease to thing association: + abstract: true + is_a: association + defining_slots: + - subject + slot_usage: + subject: + range: disease + description: "disease class" + values_from: ['mondo', 'omim', 'orphanet', 'ncit', 'doid'] + examples: + - value: MONDO:0017314 + description: "Ehlers-Danlos syndrome, vascular type" + + + genotype to phenotypic feature association: + is_a: association + defining_slots: + - subject + - object + description: >- + Any association between one genotype and a phenotypic feature, where having the genotype confers the phenotype, + either in isolation or through environment + mixins: + - entity to phenotypic feature association + - genotype to thing association + slot_usage: + relation: + subproperty_of: has phenotype + subject: + range: genotype + description: >- + genotype that is associated with the phenotypic feature + + environment to phenotypic feature association: + is_a: association + defining_slots: + - subject + - object + description: >- + Any association between an environment and a phenotypic feature, where being in the environment influences the phenotype + mixins: + - entity to phenotypic feature association + slot_usage: + subject: + range: environment + + disease to phenotypic feature association: + is_a: association + defining_slots: + - subject + - object + description: "An association between a disease and a phenotypic feature in which the phenotypic feature is associated with the disease in some way" + mixins: + - entity to phenotypic feature association + - disease to thing association + + case to phenotypic feature association: + is_a: association + defining_slots: + - subject + - object + description: "An association between a case (e.g. individual patient) and a phenotypic feature in which the individual has or has had the phenotype" + mixins: + - entity to phenotypic feature association + - case to thing association + + gene to thing association: + is_a: association + defining_slots: + - subject + abstract: true + slot_usage: + subject: + range: gene or gene product + description: "gene that is the subject of the association" + + variant to thing association: + is_a: association + local_names: + ga4gh: variant annotation + defining_slots: + - subject + abstract: true + mixin: true + slot_usage: + subject: + range: sequence variant + description: >- + a sequence variant in which the allele state is associated with some other entity + examples: + - value: ClinVar:38077 + description: "ClinVar representation of NM_000059.3(BRCA2):c.7007G>A (p.Arg2336His)" + - value: ClinGen:CA024716 + description: "chr13:g.32921033G>C (hg19) in ClinGen" + + gene to phenotypic feature association: + is_a: association + class_uri: http://bio2rdf.org/wormbase_vocabulary:Gene-Phenotype-Association + defining_slots: + - subject + - object + mixins: + - entity to phenotypic feature association + - gene to thing association + slot_usage: + subject: + range: gene or gene product + description: "gene in which variation is correlated with the phenotypic feature" + examples: + - value: HGNC:2197 + description: "COL1A1 (Human)" + + gene to disease association: + is_a: association + comments: + - NCIT:R176 refers to the inverse relationship + class_uri: SIO:000983 + defining_slots: + - subject + - object + mixins: + - entity to disease association + - gene to thing association + slot_usage: + subject: + range: gene or gene product + description: >- + gene in which variation is correlated with the disease - may be protective or causative or associative, or as a model + + variant to population association: + description: >- + An association between a variant and a population, where the variant has particular frequency in the population + is_a: association + defining_slots: + - subject + - object + mixins: + - variant to thing association + - frequency quantifier + - frequency qualifier mixin + slot_usage: + subject: + range: sequence variant + description: >- + an allele that has a certain frequency in a given population + examples: + - value: "NC_000017.11:g.43051071A>T" + description: >- + 17:41203088 A/C in gnomad + object: + range: population of individual organisms + description: >- + the population that is observed to have the frequency + examples: + - value: HANCESTRO:0010 + description: African + has quotient: + description: >- + frequency of allele in population, expressed as a number with allele divided by number in reference population, aka allele frequency + examples: + - value: "0.0001666" + has count: + description: >- + number in object population that carry a particular allele, aka allele count + examples: + - value: "4" + description: 4 individuals in gnomad set + has total: + description: >- + number all populations that carry a particular allele, aka allele number + examples: + - value: "24014" + description: 24014 individuals in gnomad set + + population to population association: + description: >- + An association between a two populations + is_a: association + defining_slots: + - subject + - object + slot_usage: + subject: + range: population of individual organisms + description: >- + the population that form the subject of the association + object: + range: population of individual organisms + description: >- + the population that form the object of the association + relation: + description: >- + A relationship type that holds between the subject and object populations. Standard mereological + relations can be used. E.g. subject part-of object, subject overlaps object. Derivation relationships + can also be used + + variant to phenotypic feature association: + is_a: association + defining_slots: + - subject + - object + mixins: + - variant to thing association + - entity to phenotypic feature association + slot_usage: + subject: + range: sequence variant + description: >- + a sequence variant in which the allele state is associated in some way with the phenotype state + + variant to disease association: + is_a: association + comments: + - TODO decide no how to model pathogenicity + defining_slots: + - subject + - object + mixins: + - variant to thing association + - entity to disease association + slot_usage: + subject: + description: >- + a sequence variant in which the allele state is associated in some way with the disease state + examples: + - value: ClinVar:52241 + description: "NM_000059.3(BRCA2):c.7007G>C (p.Arg2336Pro)" + relation: + description: >- + E.g. is pathogenic for + subproperty_of: related condition + object: + description: >- + a disease that is associated with that variant + examples: + - value: MONDO:0016419 + description: hereditary breast cancer + + model to disease mixin: + mixin: true + abstract: true + description: >- + This mixin is used for any association class for which the subject (source node) plays the role of a 'model', in that it recapitulates some + features of the disease in a way that is useful for studying the disease outside a patient carrying the disease + slot_usage: + subject: + description: >- + The entity that serves as the model of the disease. This may be an organism, a strain of organism, a genotype or variant that exhibits + similar features, or a gene that when mutated exhibits features of the disease + relation: + subproperty_of: model of + description: >- + The relationship to the disease + + gene as a model of disease association: + is_a: gene to disease association + defining_slots: + - subject + - object + - relation + mixins: + - model to disease mixin + - entity to disease association + slot_usage: + subject: + range: gene or gene product + description: >- + A gene that has a role in modeling the disease. This may be a model organism ortholog of a known disease gene, + or it may be a gene whose mutants recapitulate core features of the disease. + + gene has variant that contributes to disease association: + is_a: gene to disease association + defining_slots: + - subject + - object + - relation + slots: + - sequence variant qualifier + slot_usage: + subject: + range: gene or gene product + description: >- + A gene that has a role in modeling the disease. This may be a model organism ortholog of a known disease gene, + or it may be a gene whose mutants recapitulate core features of the disease. + + genotype to thing association: + is_a: association + defining_slots: + - subject + abstract: true + slot_usage: + subject: + range: genotype + description: "genotype that is the subject of the association" + + gene to expression site association: + is_a: association + defining_slots: + - subject + - object + - relation + description: >- + An association between a gene and an expression site, possibly qualified by stage/timing info. + notes: + - "TBD: introduce subclasses for distinction between wild-type and experimental conditions?" + see_also: "https://github.com/monarch-initiative/ingest-artifacts/tree/master/sources/BGee" + slots: + - stage qualifier + - quantifier qualifier + slot_usage: + subject: + range: gene or gene product + description: "gene in which variation is correlated with the phenotypic feature" + object: + range: anatomical entity + description: "location in which the gene is expressed" + examples: + - value: UBERON:0002037 + description: cerebellum + relation: + description: "expression relationship" + subproperty_of: expressed in + stage qualifier: + range: life stage + description: "stage at which the gene is expressed in the site" + examples: + - value: UBERON:0000069 + description: larval stage + quantifier qualifier: + description: >- + can be used to indicate magnitude, or also ranking + + sequence variant modulates treatment association: + is_a: association + description: >- + An association between a sequence variant and a treatment or health intervention. + The treatment object itself encompasses both the disease and the drug used. + comments: + - An alternate way to model the same information could be via a qualifier + defining_slots: + - subject + - object + abstract: true + slot_usage: + subject: + range: sequence variant + description: "variant that modulates the treatment of some disease" + object: + range: treatment + description: "treatment whose efficacy is modulated by the subject variant" + + functional association: + is_a: association + description: >- + An association between a macromolecular machine (gene, gene product or complex of gene products) and + either a molecular activity, a biological process or a cellular location in which a function is executed + slot_usage: + subject: + range: macromolecular machine +# aliases: +# bioentity: +# schema: amigo + description: "gene, product or macromolecular complex that has the function associated with the GO term" + examples: + - value: ZFIN:ZDB-GENE-050417-357 + description: twist1b + object: + range: gene ontology class +# aliases: +# class: +# schema: amigo + description: "class describing the activity, process or localization of the gene product" + values_from: + - go + examples: + - value: GO:0016301 + description: kinase activity + - value: GO:0045211 + description: postsynaptic membrane + + macromolecular machine to molecular activity association: + is_a: functional association + description: >- + A functional association between a macromolecular machine (gene, gene product or complex) and + a molecular activity (as represented in the GO molecular function branch), where the entity + carries out the activity, or contributes to its execution + slot_usage: + object: + range: molecular activity + + macromolecular machine to biological process association: + is_a: functional association + description: >- + A functional association between a macromolecular machine (gene, gene product or complex) and + a biological process or pathway (as represented in the GO biological process branch), where the entity + carries out some part of the process, regulates it, or acts upstream of it + slot_usage: + object: + range: biological process + + macromolecular machine to cellular component association: + is_a: functional association + description: >- + A functional association between a macromolecular machine (gene, gene product or complex) and + a cellular component (as represented in the GO cellular component branch), where the entity + carries out its function in the cellular component + slot_usage: + object: + range: cellular component + + gene to go term association: + aliases: ['functional association'] + is_a: functional association + class_uri: http://bio2rdf.org/wormbase_vocabulary:Gene-GO-Association + defining_slots: + - subject + - object + slot_usage: + subject: + range: molecular entity +# aliases: +# bioentity: +# schema: amigo + description: "gene, product or macromolecular complex that has the function associated with the GO term" + examples: + - value: ZFIN:ZDB-GENE-050417-357 + description: twist1b + object: + range: gene ontology class +# aliases: +# class: +# schema: amigo + description: "class describing the activity, process or localization of the gene product" + values_from: + - go + examples: + - value: GO:0016301 + description: kinase activity + + ## ------ + ## SEQUENCE FEATURES + ## ------ + + genomic sequence localization: + is_a: association + description: >- + A relationship between a sequence feature and an entity it is localized to. The reference entity may be + a chromosome, chromosome region or information entity such as a contig + slot_usage: + subject: + aliases: ['sequence feature'] + range: genomic entity ## todo protein + object: + aliases: ['reference'] + range: genomic entity ## typically a chromosomel use monochrom + slots: + - start interbase coordinate + - end interbase coordinate + - genome build + - phase + class_uri: faldo:location + + sequence feature relationship: + is_a: association + defining_slots: + - subject + - object + description: >- + For example, a particular exon is part of a particular transcript or gene + slot_usage: + subject: + range: genomic entity ## todo protein + object: + range: genomic entity ## typically a chromosome + + transcript to gene relationship: + is_a: sequence feature relationship + defining_slots: + - subject + - object + description: >- + A gene is a collection of transcripts + slot_usage: + subject: + range: transcript + object: + range: gene + + gene to gene product relationship: + is_a: sequence feature relationship + defining_slots: + - subject + - object + description: >- + A gene is transcribed and potentially translated to a gene product + slot_usage: + subject: + range: gene + object: + range: gene product + relation: + subproperty_of: has gene product + + exon to transcript relationship: + is_a: sequence feature relationship + defining_slots: + - subject + - object + description: >- + A transcript is formed from multiple exons + slot_usage: + subject: + range: exon + object: + range: transcript + + gene regulatory relationship: + is_a: association + description: >- + A regulatory relationship between two genes + slot_usage: + relation: + description: >- + the direction is always from regulator to regulated + subject: + range: gene or gene product + role: regulatory gene + object: + range: gene or gene product + role: regulated gene + + anatomical entity to anatomical entity association: +# schema: gocam + is_a: association + defining_slots: + - subject + - object + slot_usage: + subject: + range: anatomical entity + object: + range: anatomical entity + + anatomical entity to anatomical entity part of association: +# schema: gocam + is_a: anatomical entity to anatomical entity association + description: >- + A relationship between two anatomical entities where the relationship is mereological, i.e + the two entities are related by parthood. This includes relationships between cellular components + and cells, between cells and tissues, tissues and whole organisms + defining_slots: + - relation + slot_usage: + subject: + range: anatomical entity + description: >- + the part + object: + range: anatomical entity + description: >- + the whole + relation: + subproperty_of: part of + + anatomical entity to anatomical entity ontogenic association: + is_a: anatomical entity to anatomical entity association + description: >- + A relationship between two anatomical entities where the relationship is ontogenic, i.e + the two entities are related by development. A number of different relationship types + can be used to specify the precise nature of the relationship + defining_slots: + - relation + slot_usage: + subject: + range: anatomical entity + description: >- + the structure at a later time + object: + range: anatomical entity + description: >- + the structure at an earlier time + relation: + subproperty_of: develops from + + occurrent: + description: >- + A processual entity + is_a: named thing + class_uri: BFO:0000003 + + biological process or activity: + is_a: biological entity + description: >- + Either an individual molecular activity, or a collection of causally connected molecular activities +# union_of: +# - molecular activity +# - biological process + id_prefixes: + - GO + - Reactome + + molecular activity: + is_a: biological process or activity + aliases: ['molecular function', 'molecular event', 'reaction'] + mixins: + - occurrent + description: >- + An execution of a molecular function carried out by a gene product or macromolecular complex. + class_uri: GO:0003674 + mappings: + # UMLS Semantic Type "Molecular Function" + - UMLSSC:T044 + - UMLSST:moft + id_prefixes: + - GO + - Reactome + + activity and behavior: + is_a: occurrent + description: >- + Activity or behavior of any independent integral living, organization or mechanical actor in the world + mappings: + #Activities & Behaviors + - UMLSSG:ACTI + # Event + - UMLSSC:T051 + - UMLSST:evnt + # Activity + - UMLSSC:T052 + - UMLSST:acty + # Behavior + - UMLSSC:T053 + - UMLSST:bhvr + # Social Behavior + - UMLSSC:T054 + - UMLSST:socb + # Individual Behavior + - UMLSSC:T055 + - UMLSST:inbe + # Daily or Recreational Activity + - UMLSSC:T056 + - UMLSST:dora + # Occupational Activity + - UMLSSC:T057 + - UMLSST:ocac + # Governmental or Regulatory Activity + - UMLSSC:T064 + - UMLSST:gora + # Machine Activity + - UMLSSC:T066 + - UMLSST:mcha + + procedure: + is_a: occurrent + description: >- + A series of actions conducted in a certain order or manner + mappings: # Procedures + - UMLSSG:PROC + # Health Care Activity + - UMLSSC:T058 + - UMLSST:hlca + # Laboratory Procedure + - UMLSSC:T059 + - UMLSST:lbpr + # Diagnostic Procedure + - UMLSSC:T060 + - UMLSST:diap + # Therapeutic or Preventive Procedure + - UMLSSC:T061 + - UMLSST:topp + # Research Activity + - UMLSSC:T062 + - UMLSST:resa + # Molecular Biology Research Technique + - UMLSSC:T063 + - UMLSST:mbrt + # Educational Activity + - UMLSSC:T065 + - UMLSST:edac + + phenomenon: + is_a: occurrent + description: >- + a fact or situation that is observed to exist or happen, especially one whose cause or explanation is in question + mappings: + # Phenomena + - UMLSSG:PHEN + # Laboratory or Test Result + - UMLSSC:T034 + - UMLSST:lbtr + # Biologic Function + - UMLSSC:T038 + - UMLSST:biof + # Phenomenon or Process + - UMLSSC:T067 + - UMLSST:phpr + # Human-caused Phenomenon or Process + - UMLSSC:T068 + - UMLSST:hcpp + # Environmental Effect of Humans + - UMLSSC:T069 + - UMLSST:eehu + # Natural Phenomenon or Process + - UMLSSC:T070 + - UMLSST:npop + + biological process: + is_a: biological process or activity + mixins: + - occurrent + description: >- + One or more causally connected executions of molecular functions + class_uri: GO:0008150 + mappings: + - SIO:000006 + - WD:Q2996394 + id_prefixes: + - GO + - Reactome + + pathway: + is_a: biological process + class_uri: GO:0007165 + mappings: + - SIO:010526 + - PW:0000001 + - WD:Q4915012 + id_prefixes: + - GO + - Reactome + + physiological process: + aliases: ['physiology'] + is_a: biological process + mappings: # Physiology + - UMLSSG:PHYS + # Organism Attribute + - UMLSSC:T032 + - UMLSST:orga + # Physiologic Function + - UMLSSC:T039 + - UMLSST:phsf + # Organism Function + - UMLSSC:T040 + - UMLSST:orgf + # Mental Process + - UMLSSC:T041 + - UMLSST:menp + # Organ or Tissue Function + - UMLSSC:T042 + - UMLSST:ortf + # Cell Function + - UMLSSC:T043 + - UMLSST:celf + # Genetic Function + - UMLSSC:T045 + - UMLSST:genf + # Clinical Attribute + - UMLSSC:T201 + - UMLSST:clna + + cellular component: + is_a: anatomical entity + description: >- + A location in or around a cell + class_uri: GO:0005575 + mappings: + - SIO:001400 + - WD:Q5058355 + # Cell Component + - UMLSSC:T026 + - UMLSST:celc + id_prefixes: + - GO + + cell: + is_a: anatomical entity + class_uri: GO:0005623 + mappings: + - CL:0000000 + - SIO:010001 + - WD:Q7868 + # UMLS Semantic Type "Cell" + - UMLSSC:T025 + - UMLSST:cell + id_prefixes: + - CL + - PO + + cell line: + is_a: biosample + class_uri: CLO:0000031 + id_prefixes: + - CLO + + gross anatomical structure: + aliases: ['tissue', 'organ'] + is_a: anatomical entity + class_uri: UBERON:0010000 + mappings: + - SIO:010046 + - WD:Q4936952 + # UMLS Semantic Type "Anatomical Structure" + - UMLSSC:T017 + - UMLSST:anst + # UMLS Semantic Type "Fully Formed Anatomical Structure" + - UMLSSC:T021 + - UMLSST:ffas + # UMLS Semantic Type "Body Part, Organ, or Organ Component" + - UMLSSC:T023 + - UMLSST:bpoc + # UMLS Semantic Type "Tissue" + - UMLSSC:T024 + - UMLSST:tisu + # Embryonic Structure + - UMLSSC:T018 + - UMLSST:emst + id_prefixes: + - UBERON + - PO + - FAO diff --git a/tests/biolink/__init__.py b/tests/biolink/__init__.py new file mode 100644 index 0000000000..d7adceb5f4 --- /dev/null +++ b/tests/biolink/__init__.py @@ -0,0 +1,14 @@ +# Biolink model file locations +import os +from typing import Union + +basedir = os.path.abspath(os.path.join(__file__, '..', '..')) +BIOLINK_MODEL_YAML = os.path.join(basedir, 'biolink-model.yaml') # type: Union[bytes, str] +BIOLINK_MODEL_JSONLD = os.path.join(basedir, 'context.jsonld') +BIOLINK_MODEL_SHEX = os.path.join(basedir, 'shex', 'biolink-model.shex') +BIOLINK_MODEL_RDF = os.path.join(basedir, 'rdf', 'biolink-model.ttl') +BIOLINK_MODEL_OWL = os.path.join(basedir, 'ontology', 'biolink-model.owl') +BIOLINK_MODEL_JSON = os.path.join(basedir, 'biolink-model.json') +BIOLINK_MODEL_JSON_SCHEMA = os.path.join(basedir, 'json-schema', 'biolink-model.json') +BIOLINK_MODEL_JAVA = os.path.join(basedir, 'java') +BIOLINK_MODEL_PYTHON = os.path.join(basedir, 'biolink', 'model.py') diff --git a/tests/biolink/model.py b/tests/biolink/model.py new file mode 100644 index 0000000000..a320934bea --- /dev/null +++ b/tests/biolink/model.py @@ -0,0 +1,9807 @@ +# Auto generated from biolink-model.yaml by pythongen.py version: 0.2.0 +# Generation date: 2019-06-27 17:41 +# Schema: biolink_model +# +# id: https://w3id.org/biolink/biolink-model +# description: Entity and association taxonomy and datamodel for life-sciences data +# license: https://creativecommons.org/publicdomain/zero/1.0/ + +from typing import Optional, List, Union, Dict, ClassVar +from dataclasses import dataclass +from biolinkml.utils.metamodelcore import empty_list, empty_dict +from biolinkml.utils.yamlutils import YAMLRoot +from biolinkml.utils.metamodelcore import Bool, URI, XSDDate, XSDTime +from includes.types import Boolean, Date, Double, Float, Integer, String, Time, Uri + +metamodel_version = "1.3.5" + +# Types +class ChemicalFormulaValue(str): + """ A chemical formula """ + pass + + +class IdentifierType(String): + """ A string that is intended to uniquely identify a thing May be URI in full or compact (CURIE) form """ + pass + + +class IriType(Uri): + """ An IRI """ + pass + + +class LabelType(String): + """ A string that provides a human-readable name for a thing """ + pass + + +class NarrativeText(String): + """ A string that provides a human-readable description of something """ + pass + + +class SymbolType(String): + pass + + +class Frequency(String): + pass + + +class PerecentageFrequencyValue(Double): + pass + + +class Quotient(Double): + pass + + +class Unit(String): + pass + + +class TimeType(Time): + pass + + +class BiologicalSequence(String): + pass + + +# Class references +class AttributeId(IdentifierType): + pass + + +class BiologicalSexId(AttributeId): + pass + + +class PhenotypicSexId(BiologicalSexId): + pass + + +class GenotypicSexId(BiologicalSexId): + pass + + +class SeverityValueId(AttributeId): + pass + + +class FrequencyValueId(AttributeId): + pass + + +class ClinicalModifierId(AttributeId): + pass + + +class OnsetId(AttributeId): + pass + + +class NamedThingId(IdentifierType): + pass + + +class BiologicalEntityId(NamedThingId): + pass + + +class OntologyClassId(NamedThingId): + pass + + +class RelationshipTypeId(OntologyClassId): + pass + + +class GeneOntologyClassId(OntologyClassId): + pass + + +class OrganismTaxonId(OntologyClassId): + pass + + +class OrganismalEntityId(BiologicalEntityId): + pass + + +class IndividualOrganismId(OrganismalEntityId): + pass + + +class CaseId(IndividualOrganismId): + pass + + +class PopulationOfIndividualOrganismsId(OrganismalEntityId): + pass + + +class BiosampleId(OrganismalEntityId): + pass + + +class DiseaseOrPhenotypicFeatureId(BiologicalEntityId): + pass + + +class DiseaseId(DiseaseOrPhenotypicFeatureId): + pass + + +class PhenotypicFeatureId(DiseaseOrPhenotypicFeatureId): + pass + + +class EnvironmentId(BiologicalEntityId): + pass + + +class InformationContentEntityId(NamedThingId): + pass + + +class ConfidenceLevelId(InformationContentEntityId): + pass + + +class EvidenceTypeId(InformationContentEntityId): + pass + + +class PublicationId(InformationContentEntityId): + pass + + +class AdministrativeEntityId(NamedThingId): + pass + + +class ProviderId(AdministrativeEntityId): + pass + + +class MolecularEntityId(BiologicalEntityId): + pass + + +class ChemicalSubstanceId(MolecularEntityId): + pass + + +class CarbohydrateId(ChemicalSubstanceId): + pass + + +class DrugId(ChemicalSubstanceId): + pass + + +class MetaboliteId(ChemicalSubstanceId): + pass + + +class AnatomicalEntityId(OrganismalEntityId): + pass + + +class LifeStageId(OrganismalEntityId): + pass + + +class PlanetaryEntityId(NamedThingId): + pass + + +class EnvironmentalProcessId(PlanetaryEntityId): + pass + + +class EnvironmentalFeatureId(PlanetaryEntityId): + pass + + +class ClinicalEntityId(NamedThingId): + pass + + +class ClinicalTrialId(ClinicalEntityId): + pass + + +class ClinicalInterventionId(ClinicalEntityId): + pass + + +class DeviceId(NamedThingId): + pass + + +class GenomicEntityId(MolecularEntityId): + pass + + +class GenomeId(GenomicEntityId): + pass + + +class TranscriptId(GenomicEntityId): + pass + + +class ExonId(GenomicEntityId): + pass + + +class CodingSequenceId(GenomicEntityId): + pass + + +class MacromolecularMachineId(GenomicEntityId): + pass + + +class GeneOrGeneProductId(MacromolecularMachineId): + pass + + +class GeneId(GeneOrGeneProductId): + pass + + +class GeneProductId(GeneOrGeneProductId): + pass + + +class ProteinId(GeneProductId): + pass + + +class GeneProductIsoformId(GeneProductId): + pass + + +class ProteinIsoformId(ProteinId): + pass + + +class RNAProductId(GeneProductId): + pass + + +class RNAProductIsoformId(RNAProductId): + pass + + +class NoncodingRNAProductId(RNAProductId): + pass + + +class MicroRNAId(NoncodingRNAProductId): + pass + + +class MacromolecularComplexId(MacromolecularMachineId): + pass + + +class GeneFamilyId(MolecularEntityId): + pass + + +class ZygosityId(AttributeId): + pass + + +class GenotypeId(GenomicEntityId): + pass + + +class HaplotypeId(GenomicEntityId): + pass + + +class SequenceVariantId(GenomicEntityId): + pass + + +class DrugExposureId(EnvironmentId): + pass + + +class TreatmentId(EnvironmentId): + pass + + +class GeographicLocationId(PlanetaryEntityId): + pass + + +class GeographicLocationAtTimeId(GeographicLocationId): + pass + + +class AssociationId(IdentifierType): + pass + + +class GenotypeToGenotypePartAssociationId(AssociationId): + pass + + +class GenotypeToGeneAssociationId(AssociationId): + pass + + +class GenotypeToVariantAssociationId(AssociationId): + pass + + +class GeneToGeneAssociationId(AssociationId): + pass + + +class GeneToGeneHomologyAssociationId(GeneToGeneAssociationId): + pass + + +class PairwiseInteractionAssociationId(AssociationId): + pass + + +class PairwiseGeneToGeneInteractionId(GeneToGeneAssociationId): + pass + + +class CellLineToThingAssociationId(AssociationId): + pass + + +class CellLineToDiseaseOrPhenotypicFeatureAssociationId(AssociationId): + pass + + +class ChemicalToThingAssociationId(AssociationId): + pass + + +class CaseToThingAssociationId(AssociationId): + pass + + +class ChemicalToDiseaseOrPhenotypicFeatureAssociationId(AssociationId): + pass + + +class ChemicalToPathwayAssociationId(AssociationId): + pass + + +class ChemicalToGeneAssociationId(AssociationId): + pass + + +class BiosampleToThingAssociationId(AssociationId): + pass + + +class BiosampleToDiseaseOrPhenotypicFeatureAssociationId(AssociationId): + pass + + +class EntityToPhenotypicFeatureAssociationId(AssociationId): + pass + + +class DiseaseOrPhenotypicFeatureAssociationToThingAssociationId(AssociationId): + pass + + +class DiseaseOrPhenotypicFeatureAssociationToLocationAssociationId(DiseaseOrPhenotypicFeatureAssociationToThingAssociationId): + pass + + +class ThingToDiseaseOrPhenotypicFeatureAssociationId(AssociationId): + pass + + +class DiseaseToThingAssociationId(AssociationId): + pass + + +class GenotypeToPhenotypicFeatureAssociationId(AssociationId): + pass + + +class EnvironmentToPhenotypicFeatureAssociationId(AssociationId): + pass + + +class DiseaseToPhenotypicFeatureAssociationId(AssociationId): + pass + + +class CaseToPhenotypicFeatureAssociationId(AssociationId): + pass + + +class GeneToThingAssociationId(AssociationId): + pass + + +class VariantToThingAssociationId(AssociationId): + pass + + +class GeneToPhenotypicFeatureAssociationId(AssociationId): + pass + + +class GeneToDiseaseAssociationId(AssociationId): + pass + + +class VariantToPopulationAssociationId(AssociationId): + pass + + +class PopulationToPopulationAssociationId(AssociationId): + pass + + +class VariantToPhenotypicFeatureAssociationId(AssociationId): + pass + + +class VariantToDiseaseAssociationId(AssociationId): + pass + + +class GeneAsAModelOfDiseaseAssociationId(GeneToDiseaseAssociationId): + pass + + +class GeneHasVariantThatContributesToDiseaseAssociationId(GeneToDiseaseAssociationId): + pass + + +class GenotypeToThingAssociationId(AssociationId): + pass + + +class GeneToExpressionSiteAssociationId(AssociationId): + pass + + +class SequenceVariantModulatesTreatmentAssociationId(AssociationId): + pass + + +class FunctionalAssociationId(AssociationId): + pass + + +class MacromolecularMachineToMolecularActivityAssociationId(FunctionalAssociationId): + pass + + +class MacromolecularMachineToBiologicalProcessAssociationId(FunctionalAssociationId): + pass + + +class MacromolecularMachineToCellularComponentAssociationId(FunctionalAssociationId): + pass + + +class GeneToGoTermAssociationId(FunctionalAssociationId): + pass + + +class GenomicSequenceLocalizationId(AssociationId): + pass + + +class SequenceFeatureRelationshipId(AssociationId): + pass + + +class TranscriptToGeneRelationshipId(SequenceFeatureRelationshipId): + pass + + +class GeneToGeneProductRelationshipId(SequenceFeatureRelationshipId): + pass + + +class ExonToTranscriptRelationshipId(SequenceFeatureRelationshipId): + pass + + +class GeneRegulatoryRelationshipId(AssociationId): + pass + + +class AnatomicalEntityToAnatomicalEntityAssociationId(AssociationId): + pass + + +class AnatomicalEntityToAnatomicalEntityPartOfAssociationId(AnatomicalEntityToAnatomicalEntityAssociationId): + pass + + +class AnatomicalEntityToAnatomicalEntityOntogenicAssociationId(AnatomicalEntityToAnatomicalEntityAssociationId): + pass + + +class OccurrentId(NamedThingId): + pass + + +class BiologicalProcessOrActivityId(BiologicalEntityId): + pass + + +class MolecularActivityId(BiologicalProcessOrActivityId): + pass + + +class ActivityAndBehaviorId(OccurrentId): + pass + + +class ProcedureId(OccurrentId): + pass + + +class PhenomenonId(OccurrentId): + pass + + +class BiologicalProcessId(BiologicalProcessOrActivityId): + pass + + +class PathwayId(BiologicalProcessId): + pass + + +class PhysiologicalProcessId(BiologicalProcessId): + pass + + +class CellularComponentId(AnatomicalEntityId): + pass + + +class CellId(AnatomicalEntityId): + pass + + +class CellLineId(BiosampleId): + pass + + +class GrossAnatomicalStructureId(AnatomicalEntityId): + pass + + +@dataclass +class Attribute(YAMLRoot): + """ + A property or characteristic of an entity + """ + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "subclass_of"] + + # === attribute === + id: Union[str, AttributeId] + name: Union[str, LabelType] + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + subclass_of: List[Union[str, OntologyClassId]] = empty_list() + + def _fix_elements(self): + super()._fix_elements() + if not isinstance(self.id, AttributeId): + self.id = AttributeId(self.id) + if not isinstance(self.name, LabelType): + self.name = LabelType(self.name) + if not isinstance(self.category, IriType): + self.category = IriType(self.category) + self.related_to = [v if isinstance(v, NamedThingId) + else NamedThingId(v) for v in self.related_to] + self.interacts_with = [v if isinstance(v, NamedThingId) + else NamedThingId(v) for v in self.interacts_with] + if self.iri is not None and not isinstance(self.iri, IriType): + self.iri = IriType(self.iri) + self.synonym = [v if isinstance(v, LabelType) + else LabelType(v) for v in self.synonym] + if self.full_name is not None and not isinstance(self.full_name, LabelType): + self.full_name = LabelType(self.full_name) + if self.description is not None and not isinstance(self.description, NarrativeText): + self.description = NarrativeText(self.description) + if self.systematic_synonym is not None and not isinstance(self.systematic_synonym, LabelType): + self.systematic_synonym = LabelType(self.systematic_synonym) + self.subclass_of = [v if isinstance(v, OntologyClassId) + else OntologyClassId(v) for v in self.subclass_of] + + +@dataclass +class BiologicalSex(Attribute): + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "subclass_of"] + + # === attribute === + id: Union[str, BiologicalSexId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + subclass_of: List[Union[str, OntologyClassId]] = empty_list() + + # === biological sex === + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, BiologicalSexId): + self.id = BiologicalSexId(self.id) + + +@dataclass +class PhenotypicSex(BiologicalSex): + """ + An attribute corresponding to the phenotypic sex of the individual, based upon the reproductive organs present. + """ + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "subclass_of"] + + # === attribute === + id: Union[str, PhenotypicSexId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + subclass_of: List[Union[str, OntologyClassId]] = empty_list() + + # === biological sex === + + # === phenotypic sex === + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, PhenotypicSexId): + self.id = PhenotypicSexId(self.id) + + +@dataclass +class GenotypicSex(BiologicalSex): + """ + An attribute corresponding to the genotypic sex of the individual, based upon genotypic composition of sex + chromosomes. + """ + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "subclass_of"] + + # === attribute === + id: Union[str, GenotypicSexId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + subclass_of: List[Union[str, OntologyClassId]] = empty_list() + + # === biological sex === + + # === genotypic sex === + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, GenotypicSexId): + self.id = GenotypicSexId(self.id) + + +@dataclass +class SeverityValue(Attribute): + """ + describes the severity of a phenotypic feature or disease + """ + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "subclass_of"] + + # === attribute === + id: Union[str, SeverityValueId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + subclass_of: List[Union[str, OntologyClassId]] = empty_list() + + # === severity value === + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, SeverityValueId): + self.id = SeverityValueId(self.id) + + +@dataclass +class FrequencyValue(Attribute): + """ + describes the frequency of occurrence of an event or condition + """ + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "subclass_of"] + + # === attribute === + id: Union[str, FrequencyValueId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + subclass_of: List[Union[str, OntologyClassId]] = empty_list() + + # === frequency value === + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, FrequencyValueId): + self.id = FrequencyValueId(self.id) + + +@dataclass +class ClinicalModifier(Attribute): + """ + Used to characterize and specify the phenotypic abnormalities defined in the Phenotypic abnormality subontology, + with respect to severity, laterality, age of onset, and other aspects + """ + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "subclass_of"] + + # === attribute === + id: Union[str, ClinicalModifierId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + subclass_of: List[Union[str, OntologyClassId]] = empty_list() + + # === clinical modifier === + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, ClinicalModifierId): + self.id = ClinicalModifierId(self.id) + + +@dataclass +class Onset(Attribute): + """ + The age group in which manifestations appear + """ + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "subclass_of"] + + # === attribute === + id: Union[str, OnsetId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + subclass_of: List[Union[str, OntologyClassId]] = empty_list() + + # === onset === + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, OnsetId): + self.id = OnsetId(self.id) + + +@dataclass +class NamedThing(YAMLRoot): + """ + a databased entity or concept/class + """ + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "physically_interacts_with", "affects", "regulates", "positively_regulates", "negatively_regulates", "disrupts", "homologous_to", "paralogous_to", "orthologous_to", "xenologous_to", "coexists_with", "colocalizes_with", "affects_risk_for", "predisposes", "contributes_to", "causes", "prevents", "occurs_in", "located_in", "location_of", "model_of", "overlaps", "has_part", "part_of", "participates_in", "actively_involved_in", "capable_of", "derives_into", "derives_from", "manifestation_of", "produces", "same_as", "has_molecular_consequence"] + + # === named thing === + id: Union[str, NamedThingId] + name: Union[str, LabelType] + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + def _fix_elements(self): + super()._fix_elements() + if not isinstance(self.id, NamedThingId): + self.id = NamedThingId(self.id) + if not isinstance(self.name, LabelType): + self.name = LabelType(self.name) + if not isinstance(self.category, IriType): + self.category = IriType(self.category) + self.related_to = [v if isinstance(v, NamedThingId) + else NamedThingId(v) for v in self.related_to] + self.interacts_with = [v if isinstance(v, NamedThingId) + else NamedThingId(v) for v in self.interacts_with] + if self.iri is not None and not isinstance(self.iri, IriType): + self.iri = IriType(self.iri) + self.synonym = [v if isinstance(v, LabelType) + else LabelType(v) for v in self.synonym] + if self.full_name is not None and not isinstance(self.full_name, LabelType): + self.full_name = LabelType(self.full_name) + if self.description is not None and not isinstance(self.description, NarrativeText): + self.description = NarrativeText(self.description) + if self.systematic_synonym is not None and not isinstance(self.systematic_synonym, LabelType): + self.systematic_synonym = LabelType(self.systematic_synonym) + self.physically_interacts_with = [v if isinstance(v, NamedThingId) + else NamedThingId(v) for v in self.physically_interacts_with] + self.affects = [v if isinstance(v, NamedThingId) + else NamedThingId(v) for v in self.affects] + self.regulates = [v if isinstance(v, NamedThingId) + else NamedThingId(v) for v in self.regulates] + self.positively_regulates = [v if isinstance(v, NamedThingId) + else NamedThingId(v) for v in self.positively_regulates] + self.negatively_regulates = [v if isinstance(v, NamedThingId) + else NamedThingId(v) for v in self.negatively_regulates] + self.disrupts = [v if isinstance(v, NamedThingId) + else NamedThingId(v) for v in self.disrupts] + self.homologous_to = [v if isinstance(v, NamedThingId) + else NamedThingId(v) for v in self.homologous_to] + self.paralogous_to = [v if isinstance(v, NamedThingId) + else NamedThingId(v) for v in self.paralogous_to] + self.orthologous_to = [v if isinstance(v, NamedThingId) + else NamedThingId(v) for v in self.orthologous_to] + self.xenologous_to = [v if isinstance(v, NamedThingId) + else NamedThingId(v) for v in self.xenologous_to] + self.coexists_with = [v if isinstance(v, NamedThingId) + else NamedThingId(v) for v in self.coexists_with] + self.colocalizes_with = [v if isinstance(v, NamedThingId) + else NamedThingId(v) for v in self.colocalizes_with] + self.affects_risk_for = [v if isinstance(v, NamedThingId) + else NamedThingId(v) for v in self.affects_risk_for] + self.predisposes = [v if isinstance(v, NamedThingId) + else NamedThingId(v) for v in self.predisposes] + self.contributes_to = [v if isinstance(v, NamedThingId) + else NamedThingId(v) for v in self.contributes_to] + self.causes = [v if isinstance(v, NamedThingId) + else NamedThingId(v) for v in self.causes] + self.prevents = [v if isinstance(v, NamedThingId) + else NamedThingId(v) for v in self.prevents] + self.occurs_in = [v if isinstance(v, NamedThingId) + else NamedThingId(v) for v in self.occurs_in] + self.located_in = [v if isinstance(v, NamedThingId) + else NamedThingId(v) for v in self.located_in] + self.location_of = [v if isinstance(v, NamedThingId) + else NamedThingId(v) for v in self.location_of] + self.model_of = [v if isinstance(v, NamedThingId) + else NamedThingId(v) for v in self.model_of] + self.overlaps = [v if isinstance(v, NamedThingId) + else NamedThingId(v) for v in self.overlaps] + self.has_part = [v if isinstance(v, NamedThingId) + else NamedThingId(v) for v in self.has_part] + self.part_of = [v if isinstance(v, NamedThingId) + else NamedThingId(v) for v in self.part_of] + self.participates_in = [v if isinstance(v, OccurrentId) + else OccurrentId(v) for v in self.participates_in] + self.actively_involved_in = [v if isinstance(v, OccurrentId) + else OccurrentId(v) for v in self.actively_involved_in] + self.capable_of = [v if isinstance(v, OccurrentId) + else OccurrentId(v) for v in self.capable_of] + self.derives_into = [v if isinstance(v, NamedThingId) + else NamedThingId(v) for v in self.derives_into] + self.derives_from = [v if isinstance(v, NamedThingId) + else NamedThingId(v) for v in self.derives_from] + self.manifestation_of = [v if isinstance(v, DiseaseId) + else DiseaseId(v) for v in self.manifestation_of] + self.produces = [v if isinstance(v, NamedThingId) + else NamedThingId(v) for v in self.produces] + self.same_as = [v if isinstance(v, NamedThingId) + else NamedThingId(v) for v in self.same_as] + if self.creation_date is not None and not isinstance(self.creation_date, XSDDate): + self.creation_date = XSDDate(self.creation_date) + if self.update_date is not None and not isinstance(self.update_date, XSDDate): + self.update_date = XSDDate(self.update_date) + self.has_molecular_consequence = [v if isinstance(v, OntologyClassId) + else OntologyClassId(v) for v in self.has_molecular_consequence] + if self.filler is not None and not isinstance(self.filler, NamedThingId): + self.filler = NamedThingId(self.filler) + + +@dataclass +class BiologicalEntity(NamedThing): + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "has_phenotype"] + + # === named thing === + id: Union[str, BiologicalEntityId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === biological entity === + has_phenotype: List[Union[str, PhenotypicFeatureId]] = empty_list() + + def _fix_elements(self): + super()._fix_elements() + self.has_phenotype = [v if isinstance(v, PhenotypicFeatureId) + else PhenotypicFeatureId(v) for v in self.has_phenotype] + + +@dataclass +class OntologyClass(NamedThing): + """ + a concept or class in an ontology, vocabulary or thesaurus + """ + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "subclass_of"] + + # === named thing === + id: Union[str, OntologyClassId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === ontology class === + subclass_of: List[Union[str, OntologyClassId]] = empty_list() + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, OntologyClassId): + self.id = OntologyClassId(self.id) + self.subclass_of = [v if isinstance(v, OntologyClassId) + else OntologyClassId(v) for v in self.subclass_of] + + +@dataclass +class RelationshipType(OntologyClass): + """ + An OWL property used as an edge label + """ + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "subclass_of"] + + # === named thing === + id: Union[str, RelationshipTypeId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === ontology class === + subclass_of: List[Union[str, OntologyClassId]] = empty_list() + + # === relationship type === + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, RelationshipTypeId): + self.id = RelationshipTypeId(self.id) + + +@dataclass +class GeneOntologyClass(OntologyClass): + """ + an ontology class that describes a functional aspect of a gene, gene prodoct or complex + """ + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "subclass_of"] + + # === named thing === + id: Union[str, GeneOntologyClassId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === ontology class === + subclass_of: List[Union[str, OntologyClassId]] = empty_list() + + # === gene ontology class === + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, GeneOntologyClassId): + self.id = GeneOntologyClassId(self.id) + + +@dataclass +class OrganismTaxon(OntologyClass): + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "subclass_of"] + + # === named thing === + id: Union[str, OrganismTaxonId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === ontology class === + subclass_of: List[Union[str, OntologyClassId]] = empty_list() + + # === organism taxon === + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, OrganismTaxonId): + self.id = OrganismTaxonId(self.id) + + +@dataclass +class OrganismalEntity(BiologicalEntity): + """ + A named entity that is either a part of an organism, a whole organism, population or clade of organisms, excluding + molecular entities + """ + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "has_phenotype"] + + # === named thing === + id: Union[str, OrganismalEntityId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === biological entity === + has_phenotype: List[Union[str, PhenotypicFeatureId]] = empty_list() + + # === organismal entity === + + +@dataclass +class IndividualOrganism(OrganismalEntity): + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "has_phenotype", "in_taxon"] + + # === named thing === + id: Union[str, IndividualOrganismId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === biological entity === + has_phenotype: List[Union[str, PhenotypicFeatureId]] = empty_list() + + # === organismal entity === + + # === individual organism === + in_taxon: List[Union[str, OrganismTaxonId]] = empty_list() + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, IndividualOrganismId): + self.id = IndividualOrganismId(self.id) + self.in_taxon = [v if isinstance(v, OrganismTaxonId) + else OrganismTaxonId(v) for v in self.in_taxon] + + +@dataclass +class Case(IndividualOrganism): + """ + An individual organism that has a patient role in some clinical context. + """ + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "has_phenotype", "in_taxon"] + + # === named thing === + id: Union[str, CaseId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === biological entity === + has_phenotype: List[Union[str, PhenotypicFeatureId]] = empty_list() + + # === organismal entity === + + # === individual organism === + in_taxon: List[Union[str, OrganismTaxonId]] = empty_list() + + # === case === + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, CaseId): + self.id = CaseId(self.id) + + +@dataclass +class PopulationOfIndividualOrganisms(OrganismalEntity): + """ + A collection of individuals from the same taxonomic class distinguished by one or more characteristics. + Characteristics can include, but are not limited to, shared geographic location, genetics, phenotypes [Alliance + for Genome Resources] + """ + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "has_phenotype", "in_taxon"] + + # === named thing === + id: Union[str, PopulationOfIndividualOrganismsId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === biological entity === + has_phenotype: List[Union[str, PhenotypicFeatureId]] = empty_list() + + # === organismal entity === + + # === population of individual organisms === + in_taxon: List[Union[str, OrganismTaxonId]] = empty_list() + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, PopulationOfIndividualOrganismsId): + self.id = PopulationOfIndividualOrganismsId(self.id) + self.in_taxon = [v if isinstance(v, OrganismTaxonId) + else OrganismTaxonId(v) for v in self.in_taxon] + + +@dataclass +class Biosample(OrganismalEntity): + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "has_phenotype", "in_taxon"] + + # === named thing === + id: Union[str, BiosampleId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === biological entity === + has_phenotype: List[Union[str, PhenotypicFeatureId]] = empty_list() + + # === organismal entity === + + # === biosample === + in_taxon: List[Union[str, OrganismTaxonId]] = empty_list() + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, BiosampleId): + self.id = BiosampleId(self.id) + self.in_taxon = [v if isinstance(v, OrganismTaxonId) + else OrganismTaxonId(v) for v in self.in_taxon] + + +@dataclass +class DiseaseOrPhenotypicFeature(BiologicalEntity): + """ + Either one of a disease or an individual phenotypic feature. Some knowledge resources such as Monarch treat these + as distinct, others such as MESH conflate. + """ + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "has_phenotype", "correlated_with", "has_biomarker", "treated_by", "in_taxon"] + + # === named thing === + id: Union[str, DiseaseOrPhenotypicFeatureId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === biological entity === + has_phenotype: List[Union[str, PhenotypicFeatureId]] = empty_list() + + # === disease or phenotypic feature === + correlated_with: List[Union[str, MolecularEntityId]] = empty_list() + has_biomarker: List[Union[str, MolecularEntityId]] = empty_list() + treated_by: List[Union[str, NamedThingId]] = empty_list() + in_taxon: List[Union[str, OrganismTaxonId]] = empty_list() + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, DiseaseOrPhenotypicFeatureId): + self.id = DiseaseOrPhenotypicFeatureId(self.id) + self.correlated_with = [v if isinstance(v, MolecularEntityId) + else MolecularEntityId(v) for v in self.correlated_with] + self.has_biomarker = [v if isinstance(v, MolecularEntityId) + else MolecularEntityId(v) for v in self.has_biomarker] + self.treated_by = [v if isinstance(v, NamedThingId) + else NamedThingId(v) for v in self.treated_by] + self.in_taxon = [v if isinstance(v, OrganismTaxonId) + else OrganismTaxonId(v) for v in self.in_taxon] + + +@dataclass +class Disease(DiseaseOrPhenotypicFeature): + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "has_phenotype", "correlated_with", "has_biomarker", "treated_by", "in_taxon"] + + # === named thing === + id: Union[str, DiseaseId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === biological entity === + has_phenotype: List[Union[str, PhenotypicFeatureId]] = empty_list() + + # === disease or phenotypic feature === + correlated_with: List[Union[str, MolecularEntityId]] = empty_list() + has_biomarker: List[Union[str, MolecularEntityId]] = empty_list() + treated_by: List[Union[str, NamedThingId]] = empty_list() + in_taxon: List[Union[str, OrganismTaxonId]] = empty_list() + + # === disease === + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, DiseaseId): + self.id = DiseaseId(self.id) + + +@dataclass +class PhenotypicFeature(DiseaseOrPhenotypicFeature): + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "has_phenotype", "correlated_with", "has_biomarker", "treated_by", "in_taxon"] + + # === named thing === + id: Union[str, PhenotypicFeatureId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === biological entity === + has_phenotype: List[Union[str, PhenotypicFeatureId]] = empty_list() + + # === disease or phenotypic feature === + correlated_with: List[Union[str, MolecularEntityId]] = empty_list() + has_biomarker: List[Union[str, MolecularEntityId]] = empty_list() + treated_by: List[Union[str, NamedThingId]] = empty_list() + in_taxon: List[Union[str, OrganismTaxonId]] = empty_list() + + # === phenotypic feature === + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, PhenotypicFeatureId): + self.id = PhenotypicFeatureId(self.id) + + +@dataclass +class Environment(BiologicalEntity): + """ + A feature of the environment of an organism that influences one or more phenotypic features of that organism, + potentially mediated by genes + """ + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "has_phenotype"] + + # === named thing === + id: Union[str, EnvironmentId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === biological entity === + has_phenotype: List[Union[str, PhenotypicFeatureId]] = empty_list() + + # === environment === + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, EnvironmentId): + self.id = EnvironmentId(self.id) + + +@dataclass +class InformationContentEntity(NamedThing): + """ + a piece of information that typically describes some piece of biology or is used as support. + """ + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with"] + + # === named thing === + id: Union[str, InformationContentEntityId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === information content entity === + + +@dataclass +class ConfidenceLevel(InformationContentEntity): + """ + Level of confidence in a statement + """ + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with"] + + # === named thing === + id: Union[str, ConfidenceLevelId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === information content entity === + + # === confidence level === + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, ConfidenceLevelId): + self.id = ConfidenceLevelId(self.id) + + +@dataclass +class EvidenceType(InformationContentEntity): + """ + Class of evidence that supports an association + """ + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with"] + + # === named thing === + id: Union[str, EvidenceTypeId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === information content entity === + + # === evidence type === + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, EvidenceTypeId): + self.id = EvidenceTypeId(self.id) + + +@dataclass +class Publication(InformationContentEntity): + """ + Any published piece of information. Can refer to a whole publication, or to a part of it (e.g. a figure, figure + legend, or section highlighted by NLP). The scope is intended to be general and include information published on + the web as well as journals. + """ + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with"] + + # === named thing === + id: Union[str, PublicationId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === information content entity === + + # === publication === + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, PublicationId): + self.id = PublicationId(self.id) + + +@dataclass +class AdministrativeEntity(NamedThing): + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with"] + + # === named thing === + id: Union[str, AdministrativeEntityId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === administrative entity === + + +@dataclass +class Provider(AdministrativeEntity): + """ + person, group, organization or project that provides a piece of information + """ + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with"] + + # === named thing === + id: Union[str, ProviderId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === administrative entity === + + # === provider === + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, ProviderId): + self.id = ProviderId(self.id) + + +@dataclass +class MolecularEntity(BiologicalEntity): + """ + A gene, gene product, small molecule or macromolecule (including protein complex) + """ + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "has_phenotype", "molecularly_interacts_with", "affects_abundance_of", "increases_abundance_of", "decreases_abundance_of", "affects_activity_of", "increases_activity_of", "decreases_activity_of", "affects_expression_of", "increases_expression_of", "decreases_expression_of", "affects_folding_of", "increases_folding_of", "decreases_folding_of", "affects_localization_of", "increases_localization_of", "decreases_localization_of", "affects_metabolic_processing_of", "increases_metabolic_processing_of", "decreases_metabolic_processing_of", "affects_molecular_modification_of", "increases_molecular_modification_of", "decreases_molecular_modification_of", "affects_synthesis_of", "increases_synthesis_of", "decreases_synthesis_of", "affects_degradation_of", "increases_degradation_of", "decreases_degradation_of", "affects_mutation_rate_of", "increases_mutation_rate_of", "decreases_mutation_rate_of", "affects_response_to", "increases_response_to", "decreases_response_to", "affects_splicing_of", "increases_splicing_of", "decreases_splicing_of", "affects_stability_of", "increases_stability_of", "decreases_stability_of", "affects_transport_of", "increases_transport_of", "decreases_transport_of", "affects_secretion_of", "increases_secretion_of", "decreases_secretion_of", "affects_uptake_of", "increases_uptake_of", "decreases_uptake_of", "regulates_entity_to_entity", "biomarker_for", "in_taxon", "positively_regulates_entity_to_entity", "negatively_regulates_entity_to_entity"] + + # === named thing === + id: Union[str, MolecularEntityId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === biological entity === + has_phenotype: List[Union[str, PhenotypicFeatureId]] = empty_list() + + # === molecular entity === + molecularly_interacts_with: List[Union[str, MolecularEntityId]] = empty_list() + affects_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + increases_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + decreases_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + affects_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + increases_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + decreases_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + affects_response_to: List[Union[str, MolecularEntityId]] = empty_list() + increases_response_to: List[Union[str, MolecularEntityId]] = empty_list() + decreases_response_to: List[Union[str, MolecularEntityId]] = empty_list() + affects_splicing_of: List[Union[str, TranscriptId]] = empty_list() + increases_splicing_of: List[Union[str, TranscriptId]] = empty_list() + decreases_splicing_of: List[Union[str, TranscriptId]] = empty_list() + affects_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + biomarker_for: List[Union[str, DiseaseOrPhenotypicFeatureId]] = empty_list() + in_taxon: List[Union[str, OrganismTaxonId]] = empty_list() + positively_regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + negatively_regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, MolecularEntityId): + self.id = MolecularEntityId(self.id) + self.molecularly_interacts_with = [v if isinstance(v, MolecularEntityId) + else MolecularEntityId(v) for v in self.molecularly_interacts_with] + self.affects_abundance_of = [v if isinstance(v, MolecularEntityId) + else MolecularEntityId(v) for v in self.affects_abundance_of] + self.increases_abundance_of = [v if isinstance(v, MolecularEntityId) + else MolecularEntityId(v) for v in self.increases_abundance_of] + self.decreases_abundance_of = [v if isinstance(v, MolecularEntityId) + else MolecularEntityId(v) for v in self.decreases_abundance_of] + self.affects_activity_of = [v if isinstance(v, MolecularEntityId) + else MolecularEntityId(v) for v in self.affects_activity_of] + self.increases_activity_of = [v if isinstance(v, MolecularEntityId) + else MolecularEntityId(v) for v in self.increases_activity_of] + self.decreases_activity_of = [v if isinstance(v, MolecularEntityId) + else MolecularEntityId(v) for v in self.decreases_activity_of] + self.affects_expression_of = [v if isinstance(v, GenomicEntityId) + else GenomicEntityId(v) for v in self.affects_expression_of] + self.increases_expression_of = [v if isinstance(v, GenomicEntityId) + else GenomicEntityId(v) for v in self.increases_expression_of] + self.decreases_expression_of = [v if isinstance(v, GenomicEntityId) + else GenomicEntityId(v) for v in self.decreases_expression_of] + self.affects_folding_of = [v if isinstance(v, MolecularEntityId) + else MolecularEntityId(v) for v in self.affects_folding_of] + self.increases_folding_of = [v if isinstance(v, MolecularEntityId) + else MolecularEntityId(v) for v in self.increases_folding_of] + self.decreases_folding_of = [v if isinstance(v, MolecularEntityId) + else MolecularEntityId(v) for v in self.decreases_folding_of] + self.affects_localization_of = [v if isinstance(v, MolecularEntityId) + else MolecularEntityId(v) for v in self.affects_localization_of] + self.increases_localization_of = [v if isinstance(v, MolecularEntityId) + else MolecularEntityId(v) for v in self.increases_localization_of] + self.decreases_localization_of = [v if isinstance(v, MolecularEntityId) + else MolecularEntityId(v) for v in self.decreases_localization_of] + self.affects_metabolic_processing_of = [v if isinstance(v, MolecularEntityId) + else MolecularEntityId(v) for v in self.affects_metabolic_processing_of] + self.increases_metabolic_processing_of = [v if isinstance(v, MolecularEntityId) + else MolecularEntityId(v) for v in self.increases_metabolic_processing_of] + self.decreases_metabolic_processing_of = [v if isinstance(v, MolecularEntityId) + else MolecularEntityId(v) for v in self.decreases_metabolic_processing_of] + self.affects_molecular_modification_of = [v if isinstance(v, MolecularEntityId) + else MolecularEntityId(v) for v in self.affects_molecular_modification_of] + self.increases_molecular_modification_of = [v if isinstance(v, MolecularEntityId) + else MolecularEntityId(v) for v in self.increases_molecular_modification_of] + self.decreases_molecular_modification_of = [v if isinstance(v, MolecularEntityId) + else MolecularEntityId(v) for v in self.decreases_molecular_modification_of] + self.affects_synthesis_of = [v if isinstance(v, MolecularEntityId) + else MolecularEntityId(v) for v in self.affects_synthesis_of] + self.increases_synthesis_of = [v if isinstance(v, MolecularEntityId) + else MolecularEntityId(v) for v in self.increases_synthesis_of] + self.decreases_synthesis_of = [v if isinstance(v, MolecularEntityId) + else MolecularEntityId(v) for v in self.decreases_synthesis_of] + self.affects_degradation_of = [v if isinstance(v, MolecularEntityId) + else MolecularEntityId(v) for v in self.affects_degradation_of] + self.increases_degradation_of = [v if isinstance(v, MolecularEntityId) + else MolecularEntityId(v) for v in self.increases_degradation_of] + self.decreases_degradation_of = [v if isinstance(v, MolecularEntityId) + else MolecularEntityId(v) for v in self.decreases_degradation_of] + self.affects_mutation_rate_of = [v if isinstance(v, GenomicEntityId) + else GenomicEntityId(v) for v in self.affects_mutation_rate_of] + self.increases_mutation_rate_of = [v if isinstance(v, GenomicEntityId) + else GenomicEntityId(v) for v in self.increases_mutation_rate_of] + self.decreases_mutation_rate_of = [v if isinstance(v, GenomicEntityId) + else GenomicEntityId(v) for v in self.decreases_mutation_rate_of] + self.affects_response_to = [v if isinstance(v, MolecularEntityId) + else MolecularEntityId(v) for v in self.affects_response_to] + self.increases_response_to = [v if isinstance(v, MolecularEntityId) + else MolecularEntityId(v) for v in self.increases_response_to] + self.decreases_response_to = [v if isinstance(v, MolecularEntityId) + else MolecularEntityId(v) for v in self.decreases_response_to] + self.affects_splicing_of = [v if isinstance(v, TranscriptId) + else TranscriptId(v) for v in self.affects_splicing_of] + self.increases_splicing_of = [v if isinstance(v, TranscriptId) + else TranscriptId(v) for v in self.increases_splicing_of] + self.decreases_splicing_of = [v if isinstance(v, TranscriptId) + else TranscriptId(v) for v in self.decreases_splicing_of] + self.affects_stability_of = [v if isinstance(v, MolecularEntityId) + else MolecularEntityId(v) for v in self.affects_stability_of] + self.increases_stability_of = [v if isinstance(v, MolecularEntityId) + else MolecularEntityId(v) for v in self.increases_stability_of] + self.decreases_stability_of = [v if isinstance(v, MolecularEntityId) + else MolecularEntityId(v) for v in self.decreases_stability_of] + self.affects_transport_of = [v if isinstance(v, MolecularEntityId) + else MolecularEntityId(v) for v in self.affects_transport_of] + self.increases_transport_of = [v if isinstance(v, MolecularEntityId) + else MolecularEntityId(v) for v in self.increases_transport_of] + self.decreases_transport_of = [v if isinstance(v, MolecularEntityId) + else MolecularEntityId(v) for v in self.decreases_transport_of] + self.affects_secretion_of = [v if isinstance(v, MolecularEntityId) + else MolecularEntityId(v) for v in self.affects_secretion_of] + self.increases_secretion_of = [v if isinstance(v, MolecularEntityId) + else MolecularEntityId(v) for v in self.increases_secretion_of] + self.decreases_secretion_of = [v if isinstance(v, MolecularEntityId) + else MolecularEntityId(v) for v in self.decreases_secretion_of] + self.affects_uptake_of = [v if isinstance(v, MolecularEntityId) + else MolecularEntityId(v) for v in self.affects_uptake_of] + self.increases_uptake_of = [v if isinstance(v, MolecularEntityId) + else MolecularEntityId(v) for v in self.increases_uptake_of] + self.decreases_uptake_of = [v if isinstance(v, MolecularEntityId) + else MolecularEntityId(v) for v in self.decreases_uptake_of] + self.regulates_entity_to_entity = [v if isinstance(v, MolecularEntityId) + else MolecularEntityId(v) for v in self.regulates_entity_to_entity] + self.biomarker_for = [v if isinstance(v, DiseaseOrPhenotypicFeatureId) + else DiseaseOrPhenotypicFeatureId(v) for v in self.biomarker_for] + self.in_taxon = [v if isinstance(v, OrganismTaxonId) + else OrganismTaxonId(v) for v in self.in_taxon] + self.positively_regulates_entity_to_entity = [v if isinstance(v, MolecularEntityId) + else MolecularEntityId(v) for v in self.positively_regulates_entity_to_entity] + self.negatively_regulates_entity_to_entity = [v if isinstance(v, MolecularEntityId) + else MolecularEntityId(v) for v in self.negatively_regulates_entity_to_entity] + + +@dataclass +class ChemicalSubstance(MolecularEntity): + """ + May be a chemical entity or a formulation with a chemical entity as active ingredient, or a complex material with + multiple chemical entities as part + """ + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "has_phenotype", "molecularly_interacts_with", "affects_abundance_of", "increases_abundance_of", "decreases_abundance_of", "affects_activity_of", "increases_activity_of", "decreases_activity_of", "affects_expression_of", "increases_expression_of", "decreases_expression_of", "affects_folding_of", "increases_folding_of", "decreases_folding_of", "affects_localization_of", "increases_localization_of", "decreases_localization_of", "affects_metabolic_processing_of", "increases_metabolic_processing_of", "decreases_metabolic_processing_of", "affects_molecular_modification_of", "increases_molecular_modification_of", "decreases_molecular_modification_of", "affects_synthesis_of", "increases_synthesis_of", "decreases_synthesis_of", "affects_degradation_of", "increases_degradation_of", "decreases_degradation_of", "affects_mutation_rate_of", "increases_mutation_rate_of", "decreases_mutation_rate_of", "affects_response_to", "increases_response_to", "decreases_response_to", "affects_splicing_of", "increases_splicing_of", "decreases_splicing_of", "affects_stability_of", "increases_stability_of", "decreases_stability_of", "affects_transport_of", "increases_transport_of", "decreases_transport_of", "affects_secretion_of", "increases_secretion_of", "decreases_secretion_of", "affects_uptake_of", "increases_uptake_of", "decreases_uptake_of", "regulates_entity_to_entity", "biomarker_for", "in_taxon"] + + # === named thing === + id: Union[str, ChemicalSubstanceId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === biological entity === + has_phenotype: List[Union[str, PhenotypicFeatureId]] = empty_list() + + # === molecular entity === + molecularly_interacts_with: List[Union[str, MolecularEntityId]] = empty_list() + affects_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + increases_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + decreases_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + affects_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + increases_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + decreases_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + affects_response_to: List[Union[str, MolecularEntityId]] = empty_list() + increases_response_to: List[Union[str, MolecularEntityId]] = empty_list() + decreases_response_to: List[Union[str, MolecularEntityId]] = empty_list() + affects_splicing_of: List[Union[str, TranscriptId]] = empty_list() + increases_splicing_of: List[Union[str, TranscriptId]] = empty_list() + decreases_splicing_of: List[Union[str, TranscriptId]] = empty_list() + affects_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + biomarker_for: List[Union[str, DiseaseOrPhenotypicFeatureId]] = empty_list() + in_taxon: List[Union[str, OrganismTaxonId]] = empty_list() + positively_regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + negatively_regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + + # === chemical substance === + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, ChemicalSubstanceId): + self.id = ChemicalSubstanceId(self.id) + + +@dataclass +class Carbohydrate(ChemicalSubstance): + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "has_phenotype", "molecularly_interacts_with", "affects_abundance_of", "increases_abundance_of", "decreases_abundance_of", "affects_activity_of", "increases_activity_of", "decreases_activity_of", "affects_expression_of", "increases_expression_of", "decreases_expression_of", "affects_folding_of", "increases_folding_of", "decreases_folding_of", "affects_localization_of", "increases_localization_of", "decreases_localization_of", "affects_metabolic_processing_of", "increases_metabolic_processing_of", "decreases_metabolic_processing_of", "affects_molecular_modification_of", "increases_molecular_modification_of", "decreases_molecular_modification_of", "affects_synthesis_of", "increases_synthesis_of", "decreases_synthesis_of", "affects_degradation_of", "increases_degradation_of", "decreases_degradation_of", "affects_mutation_rate_of", "increases_mutation_rate_of", "decreases_mutation_rate_of", "affects_response_to", "increases_response_to", "decreases_response_to", "affects_splicing_of", "increases_splicing_of", "decreases_splicing_of", "affects_stability_of", "increases_stability_of", "decreases_stability_of", "affects_transport_of", "increases_transport_of", "decreases_transport_of", "affects_secretion_of", "increases_secretion_of", "decreases_secretion_of", "affects_uptake_of", "increases_uptake_of", "decreases_uptake_of", "regulates_entity_to_entity", "biomarker_for", "in_taxon"] + + # === named thing === + id: Union[str, CarbohydrateId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === biological entity === + has_phenotype: List[Union[str, PhenotypicFeatureId]] = empty_list() + + # === molecular entity === + molecularly_interacts_with: List[Union[str, MolecularEntityId]] = empty_list() + affects_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + increases_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + decreases_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + affects_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + increases_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + decreases_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + affects_response_to: List[Union[str, MolecularEntityId]] = empty_list() + increases_response_to: List[Union[str, MolecularEntityId]] = empty_list() + decreases_response_to: List[Union[str, MolecularEntityId]] = empty_list() + affects_splicing_of: List[Union[str, TranscriptId]] = empty_list() + increases_splicing_of: List[Union[str, TranscriptId]] = empty_list() + decreases_splicing_of: List[Union[str, TranscriptId]] = empty_list() + affects_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + biomarker_for: List[Union[str, DiseaseOrPhenotypicFeatureId]] = empty_list() + in_taxon: List[Union[str, OrganismTaxonId]] = empty_list() + positively_regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + negatively_regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + + # === chemical substance === + + # === carbohydrate === + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, CarbohydrateId): + self.id = CarbohydrateId(self.id) + + +@dataclass +class Drug(ChemicalSubstance): + """ + A substance intended for use in the diagnosis, cure, mitigation, treatment, or prevention of disease + """ + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "has_phenotype", "molecularly_interacts_with", "affects_abundance_of", "increases_abundance_of", "decreases_abundance_of", "affects_activity_of", "increases_activity_of", "decreases_activity_of", "affects_expression_of", "increases_expression_of", "decreases_expression_of", "affects_folding_of", "increases_folding_of", "decreases_folding_of", "affects_localization_of", "increases_localization_of", "decreases_localization_of", "affects_metabolic_processing_of", "increases_metabolic_processing_of", "decreases_metabolic_processing_of", "affects_molecular_modification_of", "increases_molecular_modification_of", "decreases_molecular_modification_of", "affects_synthesis_of", "increases_synthesis_of", "decreases_synthesis_of", "affects_degradation_of", "increases_degradation_of", "decreases_degradation_of", "affects_mutation_rate_of", "increases_mutation_rate_of", "decreases_mutation_rate_of", "affects_response_to", "increases_response_to", "decreases_response_to", "affects_splicing_of", "increases_splicing_of", "decreases_splicing_of", "affects_stability_of", "increases_stability_of", "decreases_stability_of", "affects_transport_of", "increases_transport_of", "decreases_transport_of", "affects_secretion_of", "increases_secretion_of", "decreases_secretion_of", "affects_uptake_of", "increases_uptake_of", "decreases_uptake_of", "regulates_entity_to_entity", "biomarker_for", "in_taxon"] + + # === named thing === + id: Union[str, DrugId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === biological entity === + has_phenotype: List[Union[str, PhenotypicFeatureId]] = empty_list() + + # === molecular entity === + molecularly_interacts_with: List[Union[str, MolecularEntityId]] = empty_list() + affects_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + increases_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + decreases_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + affects_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + increases_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + decreases_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + affects_response_to: List[Union[str, MolecularEntityId]] = empty_list() + increases_response_to: List[Union[str, MolecularEntityId]] = empty_list() + decreases_response_to: List[Union[str, MolecularEntityId]] = empty_list() + affects_splicing_of: List[Union[str, TranscriptId]] = empty_list() + increases_splicing_of: List[Union[str, TranscriptId]] = empty_list() + decreases_splicing_of: List[Union[str, TranscriptId]] = empty_list() + affects_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + biomarker_for: List[Union[str, DiseaseOrPhenotypicFeatureId]] = empty_list() + in_taxon: List[Union[str, OrganismTaxonId]] = empty_list() + positively_regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + negatively_regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + + # === chemical substance === + + # === drug === + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, DrugId): + self.id = DrugId(self.id) + + +@dataclass +class Metabolite(ChemicalSubstance): + """ + Any intermediate or product resulting from metabolism. Includes primary and secondary metabolites. + """ + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "has_phenotype", "molecularly_interacts_with", "affects_abundance_of", "increases_abundance_of", "decreases_abundance_of", "affects_activity_of", "increases_activity_of", "decreases_activity_of", "affects_expression_of", "increases_expression_of", "decreases_expression_of", "affects_folding_of", "increases_folding_of", "decreases_folding_of", "affects_localization_of", "increases_localization_of", "decreases_localization_of", "affects_metabolic_processing_of", "increases_metabolic_processing_of", "decreases_metabolic_processing_of", "affects_molecular_modification_of", "increases_molecular_modification_of", "decreases_molecular_modification_of", "affects_synthesis_of", "increases_synthesis_of", "decreases_synthesis_of", "affects_degradation_of", "increases_degradation_of", "decreases_degradation_of", "affects_mutation_rate_of", "increases_mutation_rate_of", "decreases_mutation_rate_of", "affects_response_to", "increases_response_to", "decreases_response_to", "affects_splicing_of", "increases_splicing_of", "decreases_splicing_of", "affects_stability_of", "increases_stability_of", "decreases_stability_of", "affects_transport_of", "increases_transport_of", "decreases_transport_of", "affects_secretion_of", "increases_secretion_of", "decreases_secretion_of", "affects_uptake_of", "increases_uptake_of", "decreases_uptake_of", "regulates_entity_to_entity", "biomarker_for", "in_taxon"] + + # === named thing === + id: Union[str, MetaboliteId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === biological entity === + has_phenotype: List[Union[str, PhenotypicFeatureId]] = empty_list() + + # === molecular entity === + molecularly_interacts_with: List[Union[str, MolecularEntityId]] = empty_list() + affects_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + increases_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + decreases_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + affects_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + increases_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + decreases_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + affects_response_to: List[Union[str, MolecularEntityId]] = empty_list() + increases_response_to: List[Union[str, MolecularEntityId]] = empty_list() + decreases_response_to: List[Union[str, MolecularEntityId]] = empty_list() + affects_splicing_of: List[Union[str, TranscriptId]] = empty_list() + increases_splicing_of: List[Union[str, TranscriptId]] = empty_list() + decreases_splicing_of: List[Union[str, TranscriptId]] = empty_list() + affects_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + biomarker_for: List[Union[str, DiseaseOrPhenotypicFeatureId]] = empty_list() + in_taxon: List[Union[str, OrganismTaxonId]] = empty_list() + positively_regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + negatively_regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + + # === chemical substance === + + # === metabolite === + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, MetaboliteId): + self.id = MetaboliteId(self.id) + + +@dataclass +class AnatomicalEntity(OrganismalEntity): + """ + A subcellular location, cell type or gross anatomical part + """ + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "has_phenotype", "expresses", "in_taxon"] + + # === named thing === + id: Union[str, AnatomicalEntityId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === biological entity === + has_phenotype: List[Union[str, PhenotypicFeatureId]] = empty_list() + + # === organismal entity === + + # === anatomical entity === + expresses: List[Union[str, GeneOrGeneProductId]] = empty_list() + in_taxon: List[Union[str, OrganismTaxonId]] = empty_list() + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, AnatomicalEntityId): + self.id = AnatomicalEntityId(self.id) + self.expresses = [v if isinstance(v, GeneOrGeneProductId) + else GeneOrGeneProductId(v) for v in self.expresses] + self.in_taxon = [v if isinstance(v, OrganismTaxonId) + else OrganismTaxonId(v) for v in self.in_taxon] + + +@dataclass +class LifeStage(OrganismalEntity): + """ + A stage of development or growth of an organism, including post-natal adult stages + """ + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "has_phenotype", "in_taxon"] + + # === named thing === + id: Union[str, LifeStageId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === biological entity === + has_phenotype: List[Union[str, PhenotypicFeatureId]] = empty_list() + + # === organismal entity === + + # === life stage === + in_taxon: List[Union[str, OrganismTaxonId]] = empty_list() + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, LifeStageId): + self.id = LifeStageId(self.id) + self.in_taxon = [v if isinstance(v, OrganismTaxonId) + else OrganismTaxonId(v) for v in self.in_taxon] + + +@dataclass +class PlanetaryEntity(NamedThing): + """ + Any entity or process that exists at the level of the whole planet + """ + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with"] + + # === named thing === + id: Union[str, PlanetaryEntityId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === planetary entity === + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, PlanetaryEntityId): + self.id = PlanetaryEntityId(self.id) + + +@dataclass +class EnvironmentalProcess(PlanetaryEntity): + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "regulates_process_to_process", "has_participant", "has_input", "precedes"] + + # === named thing === + id: Union[str, EnvironmentalProcessId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === planetary entity === + + # === environmental process === + regulates_process_to_process: List[Union[str, OccurrentId]] = empty_list() + has_participant: List[Union[str, NamedThingId]] = empty_list() + has_input: List[Union[str, NamedThingId]] = empty_list() + precedes: List[Union[str, OccurrentId]] = empty_list() + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, EnvironmentalProcessId): + self.id = EnvironmentalProcessId(self.id) + self.regulates_process_to_process = [v if isinstance(v, OccurrentId) + else OccurrentId(v) for v in self.regulates_process_to_process] + self.has_participant = [v if isinstance(v, NamedThingId) + else NamedThingId(v) for v in self.has_participant] + self.has_input = [v if isinstance(v, NamedThingId) + else NamedThingId(v) for v in self.has_input] + self.precedes = [v if isinstance(v, OccurrentId) + else OccurrentId(v) for v in self.precedes] + + +@dataclass +class EnvironmentalFeature(PlanetaryEntity): + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with"] + + # === named thing === + id: Union[str, EnvironmentalFeatureId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === planetary entity === + + # === environmental feature === + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, EnvironmentalFeatureId): + self.id = EnvironmentalFeatureId(self.id) + + +@dataclass +class ClinicalEntity(NamedThing): + """ + Any entity or process that exists in the clinical domain and outside the biological realm. Diseases are placed + under biological entities + """ + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with"] + + # === named thing === + id: Union[str, ClinicalEntityId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === clinical entity === + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, ClinicalEntityId): + self.id = ClinicalEntityId(self.id) + + +@dataclass +class ClinicalTrial(ClinicalEntity): + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with"] + + # === named thing === + id: Union[str, ClinicalTrialId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === clinical entity === + + # === clinical trial === + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, ClinicalTrialId): + self.id = ClinicalTrialId(self.id) + + +@dataclass +class ClinicalIntervention(ClinicalEntity): + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with"] + + # === named thing === + id: Union[str, ClinicalInterventionId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === clinical entity === + + # === clinical intervention === + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, ClinicalInterventionId): + self.id = ClinicalInterventionId(self.id) + + +@dataclass +class Device(NamedThing): + """ + A thing made or adapted for a particular purpose, especially a piece of mechanical or electronic equipment + """ + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with"] + + # === named thing === + id: Union[str, DeviceId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === device === + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, DeviceId): + self.id = DeviceId(self.id) + + +@dataclass +class GenomicEntity(MolecularEntity): + """ + an entity that can either be directly located on a genome (gene, transcript, exon, regulatory region) or is + encoded in a genome (protein) + """ + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "has_phenotype", "molecularly_interacts_with", "affects_abundance_of", "increases_abundance_of", "decreases_abundance_of", "affects_activity_of", "increases_activity_of", "decreases_activity_of", "affects_expression_of", "increases_expression_of", "decreases_expression_of", "affects_folding_of", "increases_folding_of", "decreases_folding_of", "affects_localization_of", "increases_localization_of", "decreases_localization_of", "affects_metabolic_processing_of", "increases_metabolic_processing_of", "decreases_metabolic_processing_of", "affects_molecular_modification_of", "increases_molecular_modification_of", "decreases_molecular_modification_of", "affects_synthesis_of", "increases_synthesis_of", "decreases_synthesis_of", "affects_degradation_of", "increases_degradation_of", "decreases_degradation_of", "affects_mutation_rate_of", "increases_mutation_rate_of", "decreases_mutation_rate_of", "affects_response_to", "increases_response_to", "decreases_response_to", "affects_splicing_of", "increases_splicing_of", "decreases_splicing_of", "affects_stability_of", "increases_stability_of", "decreases_stability_of", "affects_transport_of", "increases_transport_of", "decreases_transport_of", "affects_secretion_of", "increases_secretion_of", "decreases_secretion_of", "affects_uptake_of", "increases_uptake_of", "decreases_uptake_of", "regulates_entity_to_entity", "biomarker_for", "in_taxon"] + + # === named thing === + id: Union[str, GenomicEntityId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === biological entity === + has_phenotype: List[Union[str, PhenotypicFeatureId]] = empty_list() + + # === molecular entity === + molecularly_interacts_with: List[Union[str, MolecularEntityId]] = empty_list() + affects_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + increases_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + decreases_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + affects_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + increases_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + decreases_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + affects_response_to: List[Union[str, MolecularEntityId]] = empty_list() + increases_response_to: List[Union[str, MolecularEntityId]] = empty_list() + decreases_response_to: List[Union[str, MolecularEntityId]] = empty_list() + affects_splicing_of: List[Union[str, TranscriptId]] = empty_list() + increases_splicing_of: List[Union[str, TranscriptId]] = empty_list() + decreases_splicing_of: List[Union[str, TranscriptId]] = empty_list() + affects_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + biomarker_for: List[Union[str, DiseaseOrPhenotypicFeatureId]] = empty_list() + in_taxon: List[Union[str, OrganismTaxonId]] = empty_list() + positively_regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + negatively_regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + + # === genomic entity === + has_biological_sequence: Optional[Union[str, BiologicalSequence]] = None + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, GenomicEntityId): + self.id = GenomicEntityId(self.id) + if self.has_biological_sequence is not None and not isinstance(self.has_biological_sequence, BiologicalSequence): + self.has_biological_sequence = BiologicalSequence(self.has_biological_sequence) + + +@dataclass +class Genome(GenomicEntity): + """ + A genome is the sum of genetic material within a cell or virion. + """ + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "has_phenotype", "molecularly_interacts_with", "affects_abundance_of", "increases_abundance_of", "decreases_abundance_of", "affects_activity_of", "increases_activity_of", "decreases_activity_of", "affects_expression_of", "increases_expression_of", "decreases_expression_of", "affects_folding_of", "increases_folding_of", "decreases_folding_of", "affects_localization_of", "increases_localization_of", "decreases_localization_of", "affects_metabolic_processing_of", "increases_metabolic_processing_of", "decreases_metabolic_processing_of", "affects_molecular_modification_of", "increases_molecular_modification_of", "decreases_molecular_modification_of", "affects_synthesis_of", "increases_synthesis_of", "decreases_synthesis_of", "affects_degradation_of", "increases_degradation_of", "decreases_degradation_of", "affects_mutation_rate_of", "increases_mutation_rate_of", "decreases_mutation_rate_of", "affects_response_to", "increases_response_to", "decreases_response_to", "affects_splicing_of", "increases_splicing_of", "decreases_splicing_of", "affects_stability_of", "increases_stability_of", "decreases_stability_of", "affects_transport_of", "increases_transport_of", "decreases_transport_of", "affects_secretion_of", "increases_secretion_of", "decreases_secretion_of", "affects_uptake_of", "increases_uptake_of", "decreases_uptake_of", "regulates_entity_to_entity", "biomarker_for", "in_taxon"] + + # === named thing === + id: Union[str, GenomeId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === biological entity === + has_phenotype: List[Union[str, PhenotypicFeatureId]] = empty_list() + + # === molecular entity === + molecularly_interacts_with: List[Union[str, MolecularEntityId]] = empty_list() + affects_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + increases_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + decreases_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + affects_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + increases_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + decreases_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + affects_response_to: List[Union[str, MolecularEntityId]] = empty_list() + increases_response_to: List[Union[str, MolecularEntityId]] = empty_list() + decreases_response_to: List[Union[str, MolecularEntityId]] = empty_list() + affects_splicing_of: List[Union[str, TranscriptId]] = empty_list() + increases_splicing_of: List[Union[str, TranscriptId]] = empty_list() + decreases_splicing_of: List[Union[str, TranscriptId]] = empty_list() + affects_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + biomarker_for: List[Union[str, DiseaseOrPhenotypicFeatureId]] = empty_list() + in_taxon: List[Union[str, OrganismTaxonId]] = empty_list() + positively_regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + negatively_regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + + # === genomic entity === + has_biological_sequence: Optional[Union[str, BiologicalSequence]] = None + + # === genome === + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, GenomeId): + self.id = GenomeId(self.id) + + +@dataclass +class Transcript(GenomicEntity): + """ + An RNA synthesized on a DNA or RNA template by an RNA polymerase + """ + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "has_phenotype", "molecularly_interacts_with", "affects_abundance_of", "increases_abundance_of", "decreases_abundance_of", "affects_activity_of", "increases_activity_of", "decreases_activity_of", "affects_expression_of", "increases_expression_of", "decreases_expression_of", "affects_folding_of", "increases_folding_of", "decreases_folding_of", "affects_localization_of", "increases_localization_of", "decreases_localization_of", "affects_metabolic_processing_of", "increases_metabolic_processing_of", "decreases_metabolic_processing_of", "affects_molecular_modification_of", "increases_molecular_modification_of", "decreases_molecular_modification_of", "affects_synthesis_of", "increases_synthesis_of", "decreases_synthesis_of", "affects_degradation_of", "increases_degradation_of", "decreases_degradation_of", "affects_mutation_rate_of", "increases_mutation_rate_of", "decreases_mutation_rate_of", "affects_response_to", "increases_response_to", "decreases_response_to", "affects_splicing_of", "increases_splicing_of", "decreases_splicing_of", "affects_stability_of", "increases_stability_of", "decreases_stability_of", "affects_transport_of", "increases_transport_of", "decreases_transport_of", "affects_secretion_of", "increases_secretion_of", "decreases_secretion_of", "affects_uptake_of", "increases_uptake_of", "decreases_uptake_of", "regulates_entity_to_entity", "biomarker_for", "in_taxon"] + + # === named thing === + id: Union[str, TranscriptId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === biological entity === + has_phenotype: List[Union[str, PhenotypicFeatureId]] = empty_list() + + # === molecular entity === + molecularly_interacts_with: List[Union[str, MolecularEntityId]] = empty_list() + affects_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + increases_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + decreases_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + affects_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + increases_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + decreases_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + affects_response_to: List[Union[str, MolecularEntityId]] = empty_list() + increases_response_to: List[Union[str, MolecularEntityId]] = empty_list() + decreases_response_to: List[Union[str, MolecularEntityId]] = empty_list() + affects_splicing_of: List[Union[str, TranscriptId]] = empty_list() + increases_splicing_of: List[Union[str, TranscriptId]] = empty_list() + decreases_splicing_of: List[Union[str, TranscriptId]] = empty_list() + affects_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + biomarker_for: List[Union[str, DiseaseOrPhenotypicFeatureId]] = empty_list() + in_taxon: List[Union[str, OrganismTaxonId]] = empty_list() + positively_regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + negatively_regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + + # === genomic entity === + has_biological_sequence: Optional[Union[str, BiologicalSequence]] = None + + # === transcript === + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, TranscriptId): + self.id = TranscriptId(self.id) + + +@dataclass +class Exon(GenomicEntity): + """ + A region of the transcript sequence within a gene which is not removed from the primary RNA transcript by RNA + splicing + """ + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "has_phenotype", "molecularly_interacts_with", "affects_abundance_of", "increases_abundance_of", "decreases_abundance_of", "affects_activity_of", "increases_activity_of", "decreases_activity_of", "affects_expression_of", "increases_expression_of", "decreases_expression_of", "affects_folding_of", "increases_folding_of", "decreases_folding_of", "affects_localization_of", "increases_localization_of", "decreases_localization_of", "affects_metabolic_processing_of", "increases_metabolic_processing_of", "decreases_metabolic_processing_of", "affects_molecular_modification_of", "increases_molecular_modification_of", "decreases_molecular_modification_of", "affects_synthesis_of", "increases_synthesis_of", "decreases_synthesis_of", "affects_degradation_of", "increases_degradation_of", "decreases_degradation_of", "affects_mutation_rate_of", "increases_mutation_rate_of", "decreases_mutation_rate_of", "affects_response_to", "increases_response_to", "decreases_response_to", "affects_splicing_of", "increases_splicing_of", "decreases_splicing_of", "affects_stability_of", "increases_stability_of", "decreases_stability_of", "affects_transport_of", "increases_transport_of", "decreases_transport_of", "affects_secretion_of", "increases_secretion_of", "decreases_secretion_of", "affects_uptake_of", "increases_uptake_of", "decreases_uptake_of", "regulates_entity_to_entity", "biomarker_for", "in_taxon"] + + # === named thing === + id: Union[str, ExonId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === biological entity === + has_phenotype: List[Union[str, PhenotypicFeatureId]] = empty_list() + + # === molecular entity === + molecularly_interacts_with: List[Union[str, MolecularEntityId]] = empty_list() + affects_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + increases_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + decreases_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + affects_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + increases_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + decreases_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + affects_response_to: List[Union[str, MolecularEntityId]] = empty_list() + increases_response_to: List[Union[str, MolecularEntityId]] = empty_list() + decreases_response_to: List[Union[str, MolecularEntityId]] = empty_list() + affects_splicing_of: List[Union[str, TranscriptId]] = empty_list() + increases_splicing_of: List[Union[str, TranscriptId]] = empty_list() + decreases_splicing_of: List[Union[str, TranscriptId]] = empty_list() + affects_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + biomarker_for: List[Union[str, DiseaseOrPhenotypicFeatureId]] = empty_list() + in_taxon: List[Union[str, OrganismTaxonId]] = empty_list() + positively_regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + negatively_regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + + # === genomic entity === + has_biological_sequence: Optional[Union[str, BiologicalSequence]] = None + + # === exon === + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, ExonId): + self.id = ExonId(self.id) + + +@dataclass +class CodingSequence(GenomicEntity): + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "has_phenotype", "molecularly_interacts_with", "affects_abundance_of", "increases_abundance_of", "decreases_abundance_of", "affects_activity_of", "increases_activity_of", "decreases_activity_of", "affects_expression_of", "increases_expression_of", "decreases_expression_of", "affects_folding_of", "increases_folding_of", "decreases_folding_of", "affects_localization_of", "increases_localization_of", "decreases_localization_of", "affects_metabolic_processing_of", "increases_metabolic_processing_of", "decreases_metabolic_processing_of", "affects_molecular_modification_of", "increases_molecular_modification_of", "decreases_molecular_modification_of", "affects_synthesis_of", "increases_synthesis_of", "decreases_synthesis_of", "affects_degradation_of", "increases_degradation_of", "decreases_degradation_of", "affects_mutation_rate_of", "increases_mutation_rate_of", "decreases_mutation_rate_of", "affects_response_to", "increases_response_to", "decreases_response_to", "affects_splicing_of", "increases_splicing_of", "decreases_splicing_of", "affects_stability_of", "increases_stability_of", "decreases_stability_of", "affects_transport_of", "increases_transport_of", "decreases_transport_of", "affects_secretion_of", "increases_secretion_of", "decreases_secretion_of", "affects_uptake_of", "increases_uptake_of", "decreases_uptake_of", "regulates_entity_to_entity", "biomarker_for", "in_taxon"] + + # === named thing === + id: Union[str, CodingSequenceId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === biological entity === + has_phenotype: List[Union[str, PhenotypicFeatureId]] = empty_list() + + # === molecular entity === + molecularly_interacts_with: List[Union[str, MolecularEntityId]] = empty_list() + affects_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + increases_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + decreases_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + affects_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + increases_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + decreases_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + affects_response_to: List[Union[str, MolecularEntityId]] = empty_list() + increases_response_to: List[Union[str, MolecularEntityId]] = empty_list() + decreases_response_to: List[Union[str, MolecularEntityId]] = empty_list() + affects_splicing_of: List[Union[str, TranscriptId]] = empty_list() + increases_splicing_of: List[Union[str, TranscriptId]] = empty_list() + decreases_splicing_of: List[Union[str, TranscriptId]] = empty_list() + affects_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + biomarker_for: List[Union[str, DiseaseOrPhenotypicFeatureId]] = empty_list() + in_taxon: List[Union[str, OrganismTaxonId]] = empty_list() + positively_regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + negatively_regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + + # === genomic entity === + has_biological_sequence: Optional[Union[str, BiologicalSequence]] = None + + # === coding sequence === + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, CodingSequenceId): + self.id = CodingSequenceId(self.id) + + +@dataclass +class MacromolecularMachine(GenomicEntity): + """ + A union of gene, gene product, and macromolecular complex. These are the basic units of function in a cell. They + either carry out individual biological activities, or they encode molecules which do this. + """ + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "has_phenotype", "molecularly_interacts_with", "affects_abundance_of", "increases_abundance_of", "decreases_abundance_of", "affects_activity_of", "increases_activity_of", "decreases_activity_of", "affects_expression_of", "increases_expression_of", "decreases_expression_of", "affects_folding_of", "increases_folding_of", "decreases_folding_of", "affects_localization_of", "increases_localization_of", "decreases_localization_of", "affects_metabolic_processing_of", "increases_metabolic_processing_of", "decreases_metabolic_processing_of", "affects_molecular_modification_of", "increases_molecular_modification_of", "decreases_molecular_modification_of", "affects_synthesis_of", "increases_synthesis_of", "decreases_synthesis_of", "affects_degradation_of", "increases_degradation_of", "decreases_degradation_of", "affects_mutation_rate_of", "increases_mutation_rate_of", "decreases_mutation_rate_of", "affects_response_to", "increases_response_to", "decreases_response_to", "affects_splicing_of", "increases_splicing_of", "decreases_splicing_of", "affects_stability_of", "increases_stability_of", "decreases_stability_of", "affects_transport_of", "increases_transport_of", "decreases_transport_of", "affects_secretion_of", "increases_secretion_of", "decreases_secretion_of", "affects_uptake_of", "increases_uptake_of", "decreases_uptake_of", "regulates_entity_to_entity", "biomarker_for", "in_taxon"] + + # === named thing === + id: Union[str, MacromolecularMachineId] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === biological entity === + has_phenotype: List[Union[str, PhenotypicFeatureId]] = empty_list() + + # === molecular entity === + molecularly_interacts_with: List[Union[str, MolecularEntityId]] = empty_list() + affects_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + increases_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + decreases_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + affects_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + increases_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + decreases_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + affects_response_to: List[Union[str, MolecularEntityId]] = empty_list() + increases_response_to: List[Union[str, MolecularEntityId]] = empty_list() + decreases_response_to: List[Union[str, MolecularEntityId]] = empty_list() + affects_splicing_of: List[Union[str, TranscriptId]] = empty_list() + increases_splicing_of: List[Union[str, TranscriptId]] = empty_list() + decreases_splicing_of: List[Union[str, TranscriptId]] = empty_list() + affects_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + biomarker_for: List[Union[str, DiseaseOrPhenotypicFeatureId]] = empty_list() + in_taxon: List[Union[str, OrganismTaxonId]] = empty_list() + positively_regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + negatively_regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + + # === genomic entity === + has_biological_sequence: Optional[Union[str, BiologicalSequence]] = None + + # === macromolecular machine === + name: Union[str, SymbolType] = None + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, MacromolecularMachineId): + self.id = MacromolecularMachineId(self.id) + if self.name is not None and not isinstance(self.name, SymbolType): + self.name = SymbolType(self.name) + + +@dataclass +class GeneOrGeneProduct(MacromolecularMachine): + """ + a union of genes or gene products. Frequently an identifier for one will be used as proxy for another + """ + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "has_phenotype", "molecularly_interacts_with", "affects_abundance_of", "increases_abundance_of", "decreases_abundance_of", "affects_activity_of", "increases_activity_of", "decreases_activity_of", "affects_expression_of", "increases_expression_of", "decreases_expression_of", "affects_folding_of", "increases_folding_of", "decreases_folding_of", "affects_localization_of", "increases_localization_of", "decreases_localization_of", "affects_metabolic_processing_of", "increases_metabolic_processing_of", "decreases_metabolic_processing_of", "affects_molecular_modification_of", "increases_molecular_modification_of", "decreases_molecular_modification_of", "affects_synthesis_of", "increases_synthesis_of", "decreases_synthesis_of", "affects_degradation_of", "increases_degradation_of", "decreases_degradation_of", "affects_mutation_rate_of", "increases_mutation_rate_of", "decreases_mutation_rate_of", "affects_response_to", "increases_response_to", "decreases_response_to", "affects_splicing_of", "increases_splicing_of", "decreases_splicing_of", "affects_stability_of", "increases_stability_of", "decreases_stability_of", "affects_transport_of", "increases_transport_of", "decreases_transport_of", "affects_secretion_of", "increases_secretion_of", "decreases_secretion_of", "affects_uptake_of", "increases_uptake_of", "decreases_uptake_of", "regulates_entity_to_entity", "biomarker_for", "in_taxon", "in_pathway_with", "in_complex_with", "in_cell_population_with", "expressed_in"] + + # === named thing === + id: Union[str, GeneOrGeneProductId] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === biological entity === + has_phenotype: List[Union[str, PhenotypicFeatureId]] = empty_list() + + # === molecular entity === + molecularly_interacts_with: List[Union[str, MolecularEntityId]] = empty_list() + affects_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + increases_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + decreases_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + affects_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + increases_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + decreases_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + affects_response_to: List[Union[str, MolecularEntityId]] = empty_list() + increases_response_to: List[Union[str, MolecularEntityId]] = empty_list() + decreases_response_to: List[Union[str, MolecularEntityId]] = empty_list() + affects_splicing_of: List[Union[str, TranscriptId]] = empty_list() + increases_splicing_of: List[Union[str, TranscriptId]] = empty_list() + decreases_splicing_of: List[Union[str, TranscriptId]] = empty_list() + affects_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + biomarker_for: List[Union[str, DiseaseOrPhenotypicFeatureId]] = empty_list() + in_taxon: List[Union[str, OrganismTaxonId]] = empty_list() + positively_regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + negatively_regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + + # === genomic entity === + has_biological_sequence: Optional[Union[str, BiologicalSequence]] = None + + # === macromolecular machine === + name: Union[str, SymbolType] = None + + # === gene or gene product === + in_pathway_with: List[Union[str, GeneOrGeneProductId]] = empty_list() + in_complex_with: List[Union[str, GeneOrGeneProductId]] = empty_list() + in_cell_population_with: List[Union[str, GeneOrGeneProductId]] = empty_list() + expressed_in: List[Union[str, AnatomicalEntityId]] = empty_list() + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, GeneOrGeneProductId): + self.id = GeneOrGeneProductId(self.id) + self.in_pathway_with = [v if isinstance(v, GeneOrGeneProductId) + else GeneOrGeneProductId(v) for v in self.in_pathway_with] + self.in_complex_with = [v if isinstance(v, GeneOrGeneProductId) + else GeneOrGeneProductId(v) for v in self.in_complex_with] + self.in_cell_population_with = [v if isinstance(v, GeneOrGeneProductId) + else GeneOrGeneProductId(v) for v in self.in_cell_population_with] + self.expressed_in = [v if isinstance(v, AnatomicalEntityId) + else AnatomicalEntityId(v) for v in self.expressed_in] + + +@dataclass +class Gene(GeneOrGeneProduct): + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "has_phenotype", "molecularly_interacts_with", "affects_abundance_of", "increases_abundance_of", "decreases_abundance_of", "affects_activity_of", "increases_activity_of", "decreases_activity_of", "affects_expression_of", "increases_expression_of", "decreases_expression_of", "affects_folding_of", "increases_folding_of", "decreases_folding_of", "affects_localization_of", "increases_localization_of", "decreases_localization_of", "affects_metabolic_processing_of", "increases_metabolic_processing_of", "decreases_metabolic_processing_of", "affects_molecular_modification_of", "increases_molecular_modification_of", "decreases_molecular_modification_of", "affects_synthesis_of", "increases_synthesis_of", "decreases_synthesis_of", "affects_degradation_of", "increases_degradation_of", "decreases_degradation_of", "affects_mutation_rate_of", "increases_mutation_rate_of", "decreases_mutation_rate_of", "affects_response_to", "increases_response_to", "decreases_response_to", "affects_splicing_of", "increases_splicing_of", "decreases_splicing_of", "affects_stability_of", "increases_stability_of", "decreases_stability_of", "affects_transport_of", "increases_transport_of", "decreases_transport_of", "affects_secretion_of", "increases_secretion_of", "decreases_secretion_of", "affects_uptake_of", "increases_uptake_of", "decreases_uptake_of", "regulates_entity_to_entity", "biomarker_for", "in_taxon", "in_pathway_with", "in_complex_with", "in_cell_population_with", "expressed_in", "genetically_interacts_with", "has_gene_product", "gene_associated_with_condition"] + + # === named thing === + id: Union[str, GeneId] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === biological entity === + has_phenotype: List[Union[str, PhenotypicFeatureId]] = empty_list() + + # === molecular entity === + molecularly_interacts_with: List[Union[str, MolecularEntityId]] = empty_list() + affects_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + increases_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + decreases_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + affects_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + increases_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + decreases_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + affects_response_to: List[Union[str, MolecularEntityId]] = empty_list() + increases_response_to: List[Union[str, MolecularEntityId]] = empty_list() + decreases_response_to: List[Union[str, MolecularEntityId]] = empty_list() + affects_splicing_of: List[Union[str, TranscriptId]] = empty_list() + increases_splicing_of: List[Union[str, TranscriptId]] = empty_list() + decreases_splicing_of: List[Union[str, TranscriptId]] = empty_list() + affects_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + biomarker_for: List[Union[str, DiseaseOrPhenotypicFeatureId]] = empty_list() + in_taxon: List[Union[str, OrganismTaxonId]] = empty_list() + positively_regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + negatively_regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + + # === genomic entity === + has_biological_sequence: Optional[Union[str, BiologicalSequence]] = None + + # === macromolecular machine === + name: Union[str, SymbolType] = None + + # === gene or gene product === + in_pathway_with: List[Union[str, GeneOrGeneProductId]] = empty_list() + in_complex_with: List[Union[str, GeneOrGeneProductId]] = empty_list() + in_cell_population_with: List[Union[str, GeneOrGeneProductId]] = empty_list() + expressed_in: List[Union[str, AnatomicalEntityId]] = empty_list() + + # === gene === + genetically_interacts_with: List[Union[str, GeneId]] = empty_list() + has_gene_product: List[Union[str, GeneProductId]] = empty_list() + gene_associated_with_condition: List[Union[str, DiseaseOrPhenotypicFeatureId]] = empty_list() + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, GeneId): + self.id = GeneId(self.id) + self.genetically_interacts_with = [v if isinstance(v, GeneId) + else GeneId(v) for v in self.genetically_interacts_with] + self.has_gene_product = [v if isinstance(v, GeneProductId) + else GeneProductId(v) for v in self.has_gene_product] + self.gene_associated_with_condition = [v if isinstance(v, DiseaseOrPhenotypicFeatureId) + else DiseaseOrPhenotypicFeatureId(v) for v in self.gene_associated_with_condition] + + +@dataclass +class GeneProduct(GeneOrGeneProduct): + """ + The functional molecular product of a single gene. Gene products are either proteins or functional RNA molecules + """ + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "has_phenotype", "molecularly_interacts_with", "affects_abundance_of", "increases_abundance_of", "decreases_abundance_of", "affects_activity_of", "increases_activity_of", "decreases_activity_of", "affects_expression_of", "increases_expression_of", "decreases_expression_of", "affects_folding_of", "increases_folding_of", "decreases_folding_of", "affects_localization_of", "increases_localization_of", "decreases_localization_of", "affects_metabolic_processing_of", "increases_metabolic_processing_of", "decreases_metabolic_processing_of", "affects_molecular_modification_of", "increases_molecular_modification_of", "decreases_molecular_modification_of", "affects_synthesis_of", "increases_synthesis_of", "decreases_synthesis_of", "affects_degradation_of", "increases_degradation_of", "decreases_degradation_of", "affects_mutation_rate_of", "increases_mutation_rate_of", "decreases_mutation_rate_of", "affects_response_to", "increases_response_to", "decreases_response_to", "affects_splicing_of", "increases_splicing_of", "decreases_splicing_of", "affects_stability_of", "increases_stability_of", "decreases_stability_of", "affects_transport_of", "increases_transport_of", "decreases_transport_of", "affects_secretion_of", "increases_secretion_of", "decreases_secretion_of", "affects_uptake_of", "increases_uptake_of", "decreases_uptake_of", "regulates_entity_to_entity", "biomarker_for", "in_taxon", "in_pathway_with", "in_complex_with", "in_cell_population_with", "expressed_in"] + + # === named thing === + id: Union[str, GeneProductId] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === biological entity === + has_phenotype: List[Union[str, PhenotypicFeatureId]] = empty_list() + + # === molecular entity === + molecularly_interacts_with: List[Union[str, MolecularEntityId]] = empty_list() + affects_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + increases_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + decreases_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + affects_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + increases_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + decreases_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + affects_response_to: List[Union[str, MolecularEntityId]] = empty_list() + increases_response_to: List[Union[str, MolecularEntityId]] = empty_list() + decreases_response_to: List[Union[str, MolecularEntityId]] = empty_list() + affects_splicing_of: List[Union[str, TranscriptId]] = empty_list() + increases_splicing_of: List[Union[str, TranscriptId]] = empty_list() + decreases_splicing_of: List[Union[str, TranscriptId]] = empty_list() + affects_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + biomarker_for: List[Union[str, DiseaseOrPhenotypicFeatureId]] = empty_list() + in_taxon: List[Union[str, OrganismTaxonId]] = empty_list() + positively_regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + negatively_regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + + # === genomic entity === + has_biological_sequence: Optional[Union[str, BiologicalSequence]] = None + + # === macromolecular machine === + name: Union[str, SymbolType] = None + + # === gene or gene product === + in_pathway_with: List[Union[str, GeneOrGeneProductId]] = empty_list() + in_complex_with: List[Union[str, GeneOrGeneProductId]] = empty_list() + in_cell_population_with: List[Union[str, GeneOrGeneProductId]] = empty_list() + expressed_in: List[Union[str, AnatomicalEntityId]] = empty_list() + + # === gene product === + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, GeneProductId): + self.id = GeneProductId(self.id) + + +@dataclass +class Protein(GeneProduct): + """ + A gene product that is composed of a chain of amino acid sequences and is produced by ribosome-mediated + translation of mRNA + """ + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "has_phenotype", "molecularly_interacts_with", "affects_abundance_of", "increases_abundance_of", "decreases_abundance_of", "affects_activity_of", "increases_activity_of", "decreases_activity_of", "affects_expression_of", "increases_expression_of", "decreases_expression_of", "affects_folding_of", "increases_folding_of", "decreases_folding_of", "affects_localization_of", "increases_localization_of", "decreases_localization_of", "affects_metabolic_processing_of", "increases_metabolic_processing_of", "decreases_metabolic_processing_of", "affects_molecular_modification_of", "increases_molecular_modification_of", "decreases_molecular_modification_of", "affects_synthesis_of", "increases_synthesis_of", "decreases_synthesis_of", "affects_degradation_of", "increases_degradation_of", "decreases_degradation_of", "affects_mutation_rate_of", "increases_mutation_rate_of", "decreases_mutation_rate_of", "affects_response_to", "increases_response_to", "decreases_response_to", "affects_splicing_of", "increases_splicing_of", "decreases_splicing_of", "affects_stability_of", "increases_stability_of", "decreases_stability_of", "affects_transport_of", "increases_transport_of", "decreases_transport_of", "affects_secretion_of", "increases_secretion_of", "decreases_secretion_of", "affects_uptake_of", "increases_uptake_of", "decreases_uptake_of", "regulates_entity_to_entity", "biomarker_for", "in_taxon", "in_pathway_with", "in_complex_with", "in_cell_population_with", "expressed_in"] + + # === named thing === + id: Union[str, ProteinId] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === biological entity === + has_phenotype: List[Union[str, PhenotypicFeatureId]] = empty_list() + + # === molecular entity === + molecularly_interacts_with: List[Union[str, MolecularEntityId]] = empty_list() + affects_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + increases_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + decreases_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + affects_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + increases_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + decreases_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + affects_response_to: List[Union[str, MolecularEntityId]] = empty_list() + increases_response_to: List[Union[str, MolecularEntityId]] = empty_list() + decreases_response_to: List[Union[str, MolecularEntityId]] = empty_list() + affects_splicing_of: List[Union[str, TranscriptId]] = empty_list() + increases_splicing_of: List[Union[str, TranscriptId]] = empty_list() + decreases_splicing_of: List[Union[str, TranscriptId]] = empty_list() + affects_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + biomarker_for: List[Union[str, DiseaseOrPhenotypicFeatureId]] = empty_list() + in_taxon: List[Union[str, OrganismTaxonId]] = empty_list() + positively_regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + negatively_regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + + # === genomic entity === + has_biological_sequence: Optional[Union[str, BiologicalSequence]] = None + + # === macromolecular machine === + name: Union[str, SymbolType] = None + + # === gene or gene product === + in_pathway_with: List[Union[str, GeneOrGeneProductId]] = empty_list() + in_complex_with: List[Union[str, GeneOrGeneProductId]] = empty_list() + in_cell_population_with: List[Union[str, GeneOrGeneProductId]] = empty_list() + expressed_in: List[Union[str, AnatomicalEntityId]] = empty_list() + + # === gene product === + + # === protein === + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, ProteinId): + self.id = ProteinId(self.id) + + +@dataclass +class GeneProductIsoform(GeneProduct): + """ + This is an abstract class that can be mixed in with different kinds of gene products to indicate that the gene + product is intended to represent a specific isoform rather than a canonical or reference or generic product. The + designation of canonical or reference may be arbitrary, or it may represent the superclass of all isoforms. + """ + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "has_phenotype", "molecularly_interacts_with", "affects_abundance_of", "increases_abundance_of", "decreases_abundance_of", "affects_activity_of", "increases_activity_of", "decreases_activity_of", "affects_expression_of", "increases_expression_of", "decreases_expression_of", "affects_folding_of", "increases_folding_of", "decreases_folding_of", "affects_localization_of", "increases_localization_of", "decreases_localization_of", "affects_metabolic_processing_of", "increases_metabolic_processing_of", "decreases_metabolic_processing_of", "affects_molecular_modification_of", "increases_molecular_modification_of", "decreases_molecular_modification_of", "affects_synthesis_of", "increases_synthesis_of", "decreases_synthesis_of", "affects_degradation_of", "increases_degradation_of", "decreases_degradation_of", "affects_mutation_rate_of", "increases_mutation_rate_of", "decreases_mutation_rate_of", "affects_response_to", "increases_response_to", "decreases_response_to", "affects_splicing_of", "increases_splicing_of", "decreases_splicing_of", "affects_stability_of", "increases_stability_of", "decreases_stability_of", "affects_transport_of", "increases_transport_of", "decreases_transport_of", "affects_secretion_of", "increases_secretion_of", "decreases_secretion_of", "affects_uptake_of", "increases_uptake_of", "decreases_uptake_of", "regulates_entity_to_entity", "biomarker_for", "in_taxon", "in_pathway_with", "in_complex_with", "in_cell_population_with", "expressed_in"] + + # === named thing === + id: Union[str, GeneProductIsoformId] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === biological entity === + has_phenotype: List[Union[str, PhenotypicFeatureId]] = empty_list() + + # === molecular entity === + molecularly_interacts_with: List[Union[str, MolecularEntityId]] = empty_list() + affects_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + increases_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + decreases_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + affects_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + increases_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + decreases_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + affects_response_to: List[Union[str, MolecularEntityId]] = empty_list() + increases_response_to: List[Union[str, MolecularEntityId]] = empty_list() + decreases_response_to: List[Union[str, MolecularEntityId]] = empty_list() + affects_splicing_of: List[Union[str, TranscriptId]] = empty_list() + increases_splicing_of: List[Union[str, TranscriptId]] = empty_list() + decreases_splicing_of: List[Union[str, TranscriptId]] = empty_list() + affects_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + biomarker_for: List[Union[str, DiseaseOrPhenotypicFeatureId]] = empty_list() + in_taxon: List[Union[str, OrganismTaxonId]] = empty_list() + positively_regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + negatively_regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + + # === genomic entity === + has_biological_sequence: Optional[Union[str, BiologicalSequence]] = None + + # === macromolecular machine === + name: Union[str, SymbolType] = None + + # === gene or gene product === + in_pathway_with: List[Union[str, GeneOrGeneProductId]] = empty_list() + in_complex_with: List[Union[str, GeneOrGeneProductId]] = empty_list() + in_cell_population_with: List[Union[str, GeneOrGeneProductId]] = empty_list() + expressed_in: List[Union[str, AnatomicalEntityId]] = empty_list() + + # === gene product === + + # === gene product isoform === + + +@dataclass +class ProteinIsoform(Protein): + """ + Represents a protein that is a specific isoform of the canonical or reference protein. See + https://www.ncbi.nlm.nih.gov/pmc/articles/PMC4114032/ + """ + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "has_phenotype", "molecularly_interacts_with", "affects_abundance_of", "increases_abundance_of", "decreases_abundance_of", "affects_activity_of", "increases_activity_of", "decreases_activity_of", "affects_expression_of", "increases_expression_of", "decreases_expression_of", "affects_folding_of", "increases_folding_of", "decreases_folding_of", "affects_localization_of", "increases_localization_of", "decreases_localization_of", "affects_metabolic_processing_of", "increases_metabolic_processing_of", "decreases_metabolic_processing_of", "affects_molecular_modification_of", "increases_molecular_modification_of", "decreases_molecular_modification_of", "affects_synthesis_of", "increases_synthesis_of", "decreases_synthesis_of", "affects_degradation_of", "increases_degradation_of", "decreases_degradation_of", "affects_mutation_rate_of", "increases_mutation_rate_of", "decreases_mutation_rate_of", "affects_response_to", "increases_response_to", "decreases_response_to", "affects_splicing_of", "increases_splicing_of", "decreases_splicing_of", "affects_stability_of", "increases_stability_of", "decreases_stability_of", "affects_transport_of", "increases_transport_of", "decreases_transport_of", "affects_secretion_of", "increases_secretion_of", "decreases_secretion_of", "affects_uptake_of", "increases_uptake_of", "decreases_uptake_of", "regulates_entity_to_entity", "biomarker_for", "in_taxon", "in_pathway_with", "in_complex_with", "in_cell_population_with", "expressed_in"] + + # === named thing === + id: Union[str, ProteinIsoformId] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === biological entity === + has_phenotype: List[Union[str, PhenotypicFeatureId]] = empty_list() + + # === molecular entity === + molecularly_interacts_with: List[Union[str, MolecularEntityId]] = empty_list() + affects_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + increases_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + decreases_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + affects_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + increases_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + decreases_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + affects_response_to: List[Union[str, MolecularEntityId]] = empty_list() + increases_response_to: List[Union[str, MolecularEntityId]] = empty_list() + decreases_response_to: List[Union[str, MolecularEntityId]] = empty_list() + affects_splicing_of: List[Union[str, TranscriptId]] = empty_list() + increases_splicing_of: List[Union[str, TranscriptId]] = empty_list() + decreases_splicing_of: List[Union[str, TranscriptId]] = empty_list() + affects_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + biomarker_for: List[Union[str, DiseaseOrPhenotypicFeatureId]] = empty_list() + in_taxon: List[Union[str, OrganismTaxonId]] = empty_list() + positively_regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + negatively_regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + + # === genomic entity === + has_biological_sequence: Optional[Union[str, BiologicalSequence]] = None + + # === macromolecular machine === + name: Union[str, SymbolType] = None + + # === gene or gene product === + in_pathway_with: List[Union[str, GeneOrGeneProductId]] = empty_list() + in_complex_with: List[Union[str, GeneOrGeneProductId]] = empty_list() + in_cell_population_with: List[Union[str, GeneOrGeneProductId]] = empty_list() + expressed_in: List[Union[str, AnatomicalEntityId]] = empty_list() + + # === gene product === + + # === protein === + + # === protein isoform === + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, ProteinIsoformId): + self.id = ProteinIsoformId(self.id) + + +@dataclass +class RNAProduct(GeneProduct): + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "has_phenotype", "molecularly_interacts_with", "affects_abundance_of", "increases_abundance_of", "decreases_abundance_of", "affects_activity_of", "increases_activity_of", "decreases_activity_of", "affects_expression_of", "increases_expression_of", "decreases_expression_of", "affects_folding_of", "increases_folding_of", "decreases_folding_of", "affects_localization_of", "increases_localization_of", "decreases_localization_of", "affects_metabolic_processing_of", "increases_metabolic_processing_of", "decreases_metabolic_processing_of", "affects_molecular_modification_of", "increases_molecular_modification_of", "decreases_molecular_modification_of", "affects_synthesis_of", "increases_synthesis_of", "decreases_synthesis_of", "affects_degradation_of", "increases_degradation_of", "decreases_degradation_of", "affects_mutation_rate_of", "increases_mutation_rate_of", "decreases_mutation_rate_of", "affects_response_to", "increases_response_to", "decreases_response_to", "affects_splicing_of", "increases_splicing_of", "decreases_splicing_of", "affects_stability_of", "increases_stability_of", "decreases_stability_of", "affects_transport_of", "increases_transport_of", "decreases_transport_of", "affects_secretion_of", "increases_secretion_of", "decreases_secretion_of", "affects_uptake_of", "increases_uptake_of", "decreases_uptake_of", "regulates_entity_to_entity", "biomarker_for", "in_taxon", "in_pathway_with", "in_complex_with", "in_cell_population_with", "expressed_in"] + + # === named thing === + id: Union[str, RNAProductId] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === biological entity === + has_phenotype: List[Union[str, PhenotypicFeatureId]] = empty_list() + + # === molecular entity === + molecularly_interacts_with: List[Union[str, MolecularEntityId]] = empty_list() + affects_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + increases_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + decreases_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + affects_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + increases_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + decreases_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + affects_response_to: List[Union[str, MolecularEntityId]] = empty_list() + increases_response_to: List[Union[str, MolecularEntityId]] = empty_list() + decreases_response_to: List[Union[str, MolecularEntityId]] = empty_list() + affects_splicing_of: List[Union[str, TranscriptId]] = empty_list() + increases_splicing_of: List[Union[str, TranscriptId]] = empty_list() + decreases_splicing_of: List[Union[str, TranscriptId]] = empty_list() + affects_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + biomarker_for: List[Union[str, DiseaseOrPhenotypicFeatureId]] = empty_list() + in_taxon: List[Union[str, OrganismTaxonId]] = empty_list() + positively_regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + negatively_regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + + # === genomic entity === + has_biological_sequence: Optional[Union[str, BiologicalSequence]] = None + + # === macromolecular machine === + name: Union[str, SymbolType] = None + + # === gene or gene product === + in_pathway_with: List[Union[str, GeneOrGeneProductId]] = empty_list() + in_complex_with: List[Union[str, GeneOrGeneProductId]] = empty_list() + in_cell_population_with: List[Union[str, GeneOrGeneProductId]] = empty_list() + expressed_in: List[Union[str, AnatomicalEntityId]] = empty_list() + + # === gene product === + + # === RNA product === + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, RNAProductId): + self.id = RNAProductId(self.id) + + +@dataclass +class RNAProductIsoform(RNAProduct): + """ + Represents a protein that is a specific isoform of the canonical or reference RNA + """ + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "has_phenotype", "molecularly_interacts_with", "affects_abundance_of", "increases_abundance_of", "decreases_abundance_of", "affects_activity_of", "increases_activity_of", "decreases_activity_of", "affects_expression_of", "increases_expression_of", "decreases_expression_of", "affects_folding_of", "increases_folding_of", "decreases_folding_of", "affects_localization_of", "increases_localization_of", "decreases_localization_of", "affects_metabolic_processing_of", "increases_metabolic_processing_of", "decreases_metabolic_processing_of", "affects_molecular_modification_of", "increases_molecular_modification_of", "decreases_molecular_modification_of", "affects_synthesis_of", "increases_synthesis_of", "decreases_synthesis_of", "affects_degradation_of", "increases_degradation_of", "decreases_degradation_of", "affects_mutation_rate_of", "increases_mutation_rate_of", "decreases_mutation_rate_of", "affects_response_to", "increases_response_to", "decreases_response_to", "affects_splicing_of", "increases_splicing_of", "decreases_splicing_of", "affects_stability_of", "increases_stability_of", "decreases_stability_of", "affects_transport_of", "increases_transport_of", "decreases_transport_of", "affects_secretion_of", "increases_secretion_of", "decreases_secretion_of", "affects_uptake_of", "increases_uptake_of", "decreases_uptake_of", "regulates_entity_to_entity", "biomarker_for", "in_taxon", "in_pathway_with", "in_complex_with", "in_cell_population_with", "expressed_in"] + + # === named thing === + id: Union[str, RNAProductIsoformId] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === biological entity === + has_phenotype: List[Union[str, PhenotypicFeatureId]] = empty_list() + + # === molecular entity === + molecularly_interacts_with: List[Union[str, MolecularEntityId]] = empty_list() + affects_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + increases_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + decreases_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + affects_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + increases_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + decreases_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + affects_response_to: List[Union[str, MolecularEntityId]] = empty_list() + increases_response_to: List[Union[str, MolecularEntityId]] = empty_list() + decreases_response_to: List[Union[str, MolecularEntityId]] = empty_list() + affects_splicing_of: List[Union[str, TranscriptId]] = empty_list() + increases_splicing_of: List[Union[str, TranscriptId]] = empty_list() + decreases_splicing_of: List[Union[str, TranscriptId]] = empty_list() + affects_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + biomarker_for: List[Union[str, DiseaseOrPhenotypicFeatureId]] = empty_list() + in_taxon: List[Union[str, OrganismTaxonId]] = empty_list() + positively_regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + negatively_regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + + # === genomic entity === + has_biological_sequence: Optional[Union[str, BiologicalSequence]] = None + + # === macromolecular machine === + name: Union[str, SymbolType] = None + + # === gene or gene product === + in_pathway_with: List[Union[str, GeneOrGeneProductId]] = empty_list() + in_complex_with: List[Union[str, GeneOrGeneProductId]] = empty_list() + in_cell_population_with: List[Union[str, GeneOrGeneProductId]] = empty_list() + expressed_in: List[Union[str, AnatomicalEntityId]] = empty_list() + + # === gene product === + + # === RNA product === + + # === RNA product isoform === + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, RNAProductIsoformId): + self.id = RNAProductIsoformId(self.id) + + +@dataclass +class NoncodingRNAProduct(RNAProduct): + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "has_phenotype", "molecularly_interacts_with", "affects_abundance_of", "increases_abundance_of", "decreases_abundance_of", "affects_activity_of", "increases_activity_of", "decreases_activity_of", "affects_expression_of", "increases_expression_of", "decreases_expression_of", "affects_folding_of", "increases_folding_of", "decreases_folding_of", "affects_localization_of", "increases_localization_of", "decreases_localization_of", "affects_metabolic_processing_of", "increases_metabolic_processing_of", "decreases_metabolic_processing_of", "affects_molecular_modification_of", "increases_molecular_modification_of", "decreases_molecular_modification_of", "affects_synthesis_of", "increases_synthesis_of", "decreases_synthesis_of", "affects_degradation_of", "increases_degradation_of", "decreases_degradation_of", "affects_mutation_rate_of", "increases_mutation_rate_of", "decreases_mutation_rate_of", "affects_response_to", "increases_response_to", "decreases_response_to", "affects_splicing_of", "increases_splicing_of", "decreases_splicing_of", "affects_stability_of", "increases_stability_of", "decreases_stability_of", "affects_transport_of", "increases_transport_of", "decreases_transport_of", "affects_secretion_of", "increases_secretion_of", "decreases_secretion_of", "affects_uptake_of", "increases_uptake_of", "decreases_uptake_of", "regulates_entity_to_entity", "biomarker_for", "in_taxon", "in_pathway_with", "in_complex_with", "in_cell_population_with", "expressed_in"] + + # === named thing === + id: Union[str, NoncodingRNAProductId] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === biological entity === + has_phenotype: List[Union[str, PhenotypicFeatureId]] = empty_list() + + # === molecular entity === + molecularly_interacts_with: List[Union[str, MolecularEntityId]] = empty_list() + affects_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + increases_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + decreases_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + affects_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + increases_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + decreases_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + affects_response_to: List[Union[str, MolecularEntityId]] = empty_list() + increases_response_to: List[Union[str, MolecularEntityId]] = empty_list() + decreases_response_to: List[Union[str, MolecularEntityId]] = empty_list() + affects_splicing_of: List[Union[str, TranscriptId]] = empty_list() + increases_splicing_of: List[Union[str, TranscriptId]] = empty_list() + decreases_splicing_of: List[Union[str, TranscriptId]] = empty_list() + affects_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + biomarker_for: List[Union[str, DiseaseOrPhenotypicFeatureId]] = empty_list() + in_taxon: List[Union[str, OrganismTaxonId]] = empty_list() + positively_regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + negatively_regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + + # === genomic entity === + has_biological_sequence: Optional[Union[str, BiologicalSequence]] = None + + # === macromolecular machine === + name: Union[str, SymbolType] = None + + # === gene or gene product === + in_pathway_with: List[Union[str, GeneOrGeneProductId]] = empty_list() + in_complex_with: List[Union[str, GeneOrGeneProductId]] = empty_list() + in_cell_population_with: List[Union[str, GeneOrGeneProductId]] = empty_list() + expressed_in: List[Union[str, AnatomicalEntityId]] = empty_list() + + # === gene product === + + # === RNA product === + + # === noncoding RNA product === + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, NoncodingRNAProductId): + self.id = NoncodingRNAProductId(self.id) + + +@dataclass +class MicroRNA(NoncodingRNAProduct): + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "has_phenotype", "molecularly_interacts_with", "affects_abundance_of", "increases_abundance_of", "decreases_abundance_of", "affects_activity_of", "increases_activity_of", "decreases_activity_of", "affects_expression_of", "increases_expression_of", "decreases_expression_of", "affects_folding_of", "increases_folding_of", "decreases_folding_of", "affects_localization_of", "increases_localization_of", "decreases_localization_of", "affects_metabolic_processing_of", "increases_metabolic_processing_of", "decreases_metabolic_processing_of", "affects_molecular_modification_of", "increases_molecular_modification_of", "decreases_molecular_modification_of", "affects_synthesis_of", "increases_synthesis_of", "decreases_synthesis_of", "affects_degradation_of", "increases_degradation_of", "decreases_degradation_of", "affects_mutation_rate_of", "increases_mutation_rate_of", "decreases_mutation_rate_of", "affects_response_to", "increases_response_to", "decreases_response_to", "affects_splicing_of", "increases_splicing_of", "decreases_splicing_of", "affects_stability_of", "increases_stability_of", "decreases_stability_of", "affects_transport_of", "increases_transport_of", "decreases_transport_of", "affects_secretion_of", "increases_secretion_of", "decreases_secretion_of", "affects_uptake_of", "increases_uptake_of", "decreases_uptake_of", "regulates_entity_to_entity", "biomarker_for", "in_taxon", "in_pathway_with", "in_complex_with", "in_cell_population_with", "expressed_in"] + + # === named thing === + id: Union[str, MicroRNAId] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === biological entity === + has_phenotype: List[Union[str, PhenotypicFeatureId]] = empty_list() + + # === molecular entity === + molecularly_interacts_with: List[Union[str, MolecularEntityId]] = empty_list() + affects_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + increases_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + decreases_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + affects_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + increases_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + decreases_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + affects_response_to: List[Union[str, MolecularEntityId]] = empty_list() + increases_response_to: List[Union[str, MolecularEntityId]] = empty_list() + decreases_response_to: List[Union[str, MolecularEntityId]] = empty_list() + affects_splicing_of: List[Union[str, TranscriptId]] = empty_list() + increases_splicing_of: List[Union[str, TranscriptId]] = empty_list() + decreases_splicing_of: List[Union[str, TranscriptId]] = empty_list() + affects_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + biomarker_for: List[Union[str, DiseaseOrPhenotypicFeatureId]] = empty_list() + in_taxon: List[Union[str, OrganismTaxonId]] = empty_list() + positively_regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + negatively_regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + + # === genomic entity === + has_biological_sequence: Optional[Union[str, BiologicalSequence]] = None + + # === macromolecular machine === + name: Union[str, SymbolType] = None + + # === gene or gene product === + in_pathway_with: List[Union[str, GeneOrGeneProductId]] = empty_list() + in_complex_with: List[Union[str, GeneOrGeneProductId]] = empty_list() + in_cell_population_with: List[Union[str, GeneOrGeneProductId]] = empty_list() + expressed_in: List[Union[str, AnatomicalEntityId]] = empty_list() + + # === gene product === + + # === RNA product === + + # === noncoding RNA product === + + # === microRNA === + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, MicroRNAId): + self.id = MicroRNAId(self.id) + + +@dataclass +class MacromolecularComplex(MacromolecularMachine): + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "has_phenotype", "molecularly_interacts_with", "affects_abundance_of", "increases_abundance_of", "decreases_abundance_of", "affects_activity_of", "increases_activity_of", "decreases_activity_of", "affects_expression_of", "increases_expression_of", "decreases_expression_of", "affects_folding_of", "increases_folding_of", "decreases_folding_of", "affects_localization_of", "increases_localization_of", "decreases_localization_of", "affects_metabolic_processing_of", "increases_metabolic_processing_of", "decreases_metabolic_processing_of", "affects_molecular_modification_of", "increases_molecular_modification_of", "decreases_molecular_modification_of", "affects_synthesis_of", "increases_synthesis_of", "decreases_synthesis_of", "affects_degradation_of", "increases_degradation_of", "decreases_degradation_of", "affects_mutation_rate_of", "increases_mutation_rate_of", "decreases_mutation_rate_of", "affects_response_to", "increases_response_to", "decreases_response_to", "affects_splicing_of", "increases_splicing_of", "decreases_splicing_of", "affects_stability_of", "increases_stability_of", "decreases_stability_of", "affects_transport_of", "increases_transport_of", "decreases_transport_of", "affects_secretion_of", "increases_secretion_of", "decreases_secretion_of", "affects_uptake_of", "increases_uptake_of", "decreases_uptake_of", "regulates_entity_to_entity", "biomarker_for", "in_taxon"] + + # === named thing === + id: Union[str, MacromolecularComplexId] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === biological entity === + has_phenotype: List[Union[str, PhenotypicFeatureId]] = empty_list() + + # === molecular entity === + molecularly_interacts_with: List[Union[str, MolecularEntityId]] = empty_list() + affects_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + increases_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + decreases_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + affects_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + increases_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + decreases_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + affects_response_to: List[Union[str, MolecularEntityId]] = empty_list() + increases_response_to: List[Union[str, MolecularEntityId]] = empty_list() + decreases_response_to: List[Union[str, MolecularEntityId]] = empty_list() + affects_splicing_of: List[Union[str, TranscriptId]] = empty_list() + increases_splicing_of: List[Union[str, TranscriptId]] = empty_list() + decreases_splicing_of: List[Union[str, TranscriptId]] = empty_list() + affects_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + biomarker_for: List[Union[str, DiseaseOrPhenotypicFeatureId]] = empty_list() + in_taxon: List[Union[str, OrganismTaxonId]] = empty_list() + positively_regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + negatively_regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + + # === genomic entity === + has_biological_sequence: Optional[Union[str, BiologicalSequence]] = None + + # === macromolecular machine === + name: Union[str, SymbolType] = None + + # === macromolecular complex === + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, MacromolecularComplexId): + self.id = MacromolecularComplexId(self.id) + + +@dataclass +class GeneFamily(MolecularEntity): + """ + any grouping of multiple genes or gene products related by common descent + """ + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "has_phenotype", "molecularly_interacts_with", "affects_abundance_of", "increases_abundance_of", "decreases_abundance_of", "affects_activity_of", "increases_activity_of", "decreases_activity_of", "affects_expression_of", "increases_expression_of", "decreases_expression_of", "affects_folding_of", "increases_folding_of", "decreases_folding_of", "affects_localization_of", "increases_localization_of", "decreases_localization_of", "affects_metabolic_processing_of", "increases_metabolic_processing_of", "decreases_metabolic_processing_of", "affects_molecular_modification_of", "increases_molecular_modification_of", "decreases_molecular_modification_of", "affects_synthesis_of", "increases_synthesis_of", "decreases_synthesis_of", "affects_degradation_of", "increases_degradation_of", "decreases_degradation_of", "affects_mutation_rate_of", "increases_mutation_rate_of", "decreases_mutation_rate_of", "affects_response_to", "increases_response_to", "decreases_response_to", "affects_splicing_of", "increases_splicing_of", "decreases_splicing_of", "affects_stability_of", "increases_stability_of", "decreases_stability_of", "affects_transport_of", "increases_transport_of", "decreases_transport_of", "affects_secretion_of", "increases_secretion_of", "decreases_secretion_of", "affects_uptake_of", "increases_uptake_of", "decreases_uptake_of", "regulates_entity_to_entity", "biomarker_for", "in_taxon"] + + # === named thing === + id: Union[str, GeneFamilyId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === biological entity === + has_phenotype: List[Union[str, PhenotypicFeatureId]] = empty_list() + + # === molecular entity === + molecularly_interacts_with: List[Union[str, MolecularEntityId]] = empty_list() + affects_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + increases_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + decreases_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + affects_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + increases_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + decreases_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + affects_response_to: List[Union[str, MolecularEntityId]] = empty_list() + increases_response_to: List[Union[str, MolecularEntityId]] = empty_list() + decreases_response_to: List[Union[str, MolecularEntityId]] = empty_list() + affects_splicing_of: List[Union[str, TranscriptId]] = empty_list() + increases_splicing_of: List[Union[str, TranscriptId]] = empty_list() + decreases_splicing_of: List[Union[str, TranscriptId]] = empty_list() + affects_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + biomarker_for: List[Union[str, DiseaseOrPhenotypicFeatureId]] = empty_list() + in_taxon: List[Union[str, OrganismTaxonId]] = empty_list() + positively_regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + negatively_regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + + # === gene family === + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, GeneFamilyId): + self.id = GeneFamilyId(self.id) + + +@dataclass +class Zygosity(Attribute): + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "subclass_of"] + + # === attribute === + id: Union[str, ZygosityId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + subclass_of: List[Union[str, OntologyClassId]] = empty_list() + + # === zygosity === + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, ZygosityId): + self.id = ZygosityId(self.id) + + +@dataclass +class Genotype(GenomicEntity): + """ + An information content entity that describes a genome by specifying the total variation in genomic sequence and/or + gene expression, relative to some extablished background + """ + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "has_phenotype", "molecularly_interacts_with", "affects_abundance_of", "increases_abundance_of", "decreases_abundance_of", "affects_activity_of", "increases_activity_of", "decreases_activity_of", "affects_expression_of", "increases_expression_of", "decreases_expression_of", "affects_folding_of", "increases_folding_of", "decreases_folding_of", "affects_localization_of", "increases_localization_of", "decreases_localization_of", "affects_metabolic_processing_of", "increases_metabolic_processing_of", "decreases_metabolic_processing_of", "affects_molecular_modification_of", "increases_molecular_modification_of", "decreases_molecular_modification_of", "affects_synthesis_of", "increases_synthesis_of", "decreases_synthesis_of", "affects_degradation_of", "increases_degradation_of", "decreases_degradation_of", "affects_mutation_rate_of", "increases_mutation_rate_of", "decreases_mutation_rate_of", "affects_response_to", "increases_response_to", "decreases_response_to", "affects_splicing_of", "increases_splicing_of", "decreases_splicing_of", "affects_stability_of", "increases_stability_of", "decreases_stability_of", "affects_transport_of", "increases_transport_of", "decreases_transport_of", "affects_secretion_of", "increases_secretion_of", "decreases_secretion_of", "affects_uptake_of", "increases_uptake_of", "decreases_uptake_of", "regulates_entity_to_entity", "biomarker_for", "in_taxon"] + + # === named thing === + id: Union[str, GenotypeId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === biological entity === + has_phenotype: List[Union[str, PhenotypicFeatureId]] = empty_list() + + # === molecular entity === + molecularly_interacts_with: List[Union[str, MolecularEntityId]] = empty_list() + affects_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + increases_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + decreases_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + affects_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + increases_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + decreases_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + affects_response_to: List[Union[str, MolecularEntityId]] = empty_list() + increases_response_to: List[Union[str, MolecularEntityId]] = empty_list() + decreases_response_to: List[Union[str, MolecularEntityId]] = empty_list() + affects_splicing_of: List[Union[str, TranscriptId]] = empty_list() + increases_splicing_of: List[Union[str, TranscriptId]] = empty_list() + decreases_splicing_of: List[Union[str, TranscriptId]] = empty_list() + affects_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + biomarker_for: List[Union[str, DiseaseOrPhenotypicFeatureId]] = empty_list() + in_taxon: List[Union[str, OrganismTaxonId]] = empty_list() + positively_regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + negatively_regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + + # === genomic entity === + has_biological_sequence: Optional[Union[str, BiologicalSequence]] = None + + # === genotype === + has_zygosity: Optional[Union[str, ZygosityId]] = None + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, GenotypeId): + self.id = GenotypeId(self.id) + if self.has_zygosity is not None and not isinstance(self.has_zygosity, ZygosityId): + self.has_zygosity = ZygosityId(self.has_zygosity) + + +@dataclass +class Haplotype(GenomicEntity): + """ + A set of zero or more Alleles on a single instance of a Sequence[VMC] + """ + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "has_phenotype", "molecularly_interacts_with", "affects_abundance_of", "increases_abundance_of", "decreases_abundance_of", "affects_activity_of", "increases_activity_of", "decreases_activity_of", "affects_expression_of", "increases_expression_of", "decreases_expression_of", "affects_folding_of", "increases_folding_of", "decreases_folding_of", "affects_localization_of", "increases_localization_of", "decreases_localization_of", "affects_metabolic_processing_of", "increases_metabolic_processing_of", "decreases_metabolic_processing_of", "affects_molecular_modification_of", "increases_molecular_modification_of", "decreases_molecular_modification_of", "affects_synthesis_of", "increases_synthesis_of", "decreases_synthesis_of", "affects_degradation_of", "increases_degradation_of", "decreases_degradation_of", "affects_mutation_rate_of", "increases_mutation_rate_of", "decreases_mutation_rate_of", "affects_response_to", "increases_response_to", "decreases_response_to", "affects_splicing_of", "increases_splicing_of", "decreases_splicing_of", "affects_stability_of", "increases_stability_of", "decreases_stability_of", "affects_transport_of", "increases_transport_of", "decreases_transport_of", "affects_secretion_of", "increases_secretion_of", "decreases_secretion_of", "affects_uptake_of", "increases_uptake_of", "decreases_uptake_of", "regulates_entity_to_entity", "biomarker_for", "in_taxon"] + + # === named thing === + id: Union[str, HaplotypeId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === biological entity === + has_phenotype: List[Union[str, PhenotypicFeatureId]] = empty_list() + + # === molecular entity === + molecularly_interacts_with: List[Union[str, MolecularEntityId]] = empty_list() + affects_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + increases_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + decreases_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + affects_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + increases_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + decreases_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + affects_response_to: List[Union[str, MolecularEntityId]] = empty_list() + increases_response_to: List[Union[str, MolecularEntityId]] = empty_list() + decreases_response_to: List[Union[str, MolecularEntityId]] = empty_list() + affects_splicing_of: List[Union[str, TranscriptId]] = empty_list() + increases_splicing_of: List[Union[str, TranscriptId]] = empty_list() + decreases_splicing_of: List[Union[str, TranscriptId]] = empty_list() + affects_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + biomarker_for: List[Union[str, DiseaseOrPhenotypicFeatureId]] = empty_list() + in_taxon: List[Union[str, OrganismTaxonId]] = empty_list() + positively_regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + negatively_regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + + # === genomic entity === + has_biological_sequence: Optional[Union[str, BiologicalSequence]] = None + + # === haplotype === + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, HaplotypeId): + self.id = HaplotypeId(self.id) + + +@dataclass +class SequenceVariant(GenomicEntity): + """ + An allele that varies in its sequence from what is considered the reference allele at that locus. + """ + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "has_phenotype", "molecularly_interacts_with", "affects_abundance_of", "increases_abundance_of", "decreases_abundance_of", "affects_activity_of", "increases_activity_of", "decreases_activity_of", "affects_expression_of", "increases_expression_of", "decreases_expression_of", "affects_folding_of", "increases_folding_of", "decreases_folding_of", "affects_localization_of", "increases_localization_of", "decreases_localization_of", "affects_metabolic_processing_of", "increases_metabolic_processing_of", "decreases_metabolic_processing_of", "affects_molecular_modification_of", "increases_molecular_modification_of", "decreases_molecular_modification_of", "affects_synthesis_of", "increases_synthesis_of", "decreases_synthesis_of", "affects_degradation_of", "increases_degradation_of", "decreases_degradation_of", "affects_mutation_rate_of", "increases_mutation_rate_of", "decreases_mutation_rate_of", "affects_response_to", "increases_response_to", "decreases_response_to", "affects_splicing_of", "increases_splicing_of", "decreases_splicing_of", "affects_stability_of", "increases_stability_of", "decreases_stability_of", "affects_transport_of", "increases_transport_of", "decreases_transport_of", "affects_secretion_of", "increases_secretion_of", "decreases_secretion_of", "affects_uptake_of", "increases_uptake_of", "decreases_uptake_of", "regulates_entity_to_entity", "biomarker_for", "in_taxon"] + + # === named thing === + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === biological entity === + has_phenotype: List[Union[str, PhenotypicFeatureId]] = empty_list() + + # === molecular entity === + molecularly_interacts_with: List[Union[str, MolecularEntityId]] = empty_list() + affects_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_abundance_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_activity_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + increases_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + decreases_expression_of: List[Union[str, GenomicEntityId]] = empty_list() + affects_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_folding_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_localization_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_metabolic_processing_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_molecular_modification_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_synthesis_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_degradation_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + increases_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + decreases_mutation_rate_of: List[Union[str, GenomicEntityId]] = empty_list() + affects_response_to: List[Union[str, MolecularEntityId]] = empty_list() + increases_response_to: List[Union[str, MolecularEntityId]] = empty_list() + decreases_response_to: List[Union[str, MolecularEntityId]] = empty_list() + affects_splicing_of: List[Union[str, TranscriptId]] = empty_list() + increases_splicing_of: List[Union[str, TranscriptId]] = empty_list() + decreases_splicing_of: List[Union[str, TranscriptId]] = empty_list() + affects_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_stability_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_transport_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_secretion_of: List[Union[str, MolecularEntityId]] = empty_list() + affects_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + increases_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + decreases_uptake_of: List[Union[str, MolecularEntityId]] = empty_list() + regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + biomarker_for: List[Union[str, DiseaseOrPhenotypicFeatureId]] = empty_list() + in_taxon: List[Union[str, OrganismTaxonId]] = empty_list() + positively_regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + negatively_regulates_entity_to_entity: List[Union[str, MolecularEntityId]] = empty_list() + + # === genomic entity === + + # === sequence variant === + id: Union[str, SequenceVariantId] = None + has_biological_sequence: Optional[Union[str, BiologicalSequence]] = None + has_gene: List[Union[str, GeneId]] = empty_list() + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, SequenceVariantId): + self.id = SequenceVariantId(self.id) + if self.has_biological_sequence is not None and not isinstance(self.has_biological_sequence, BiologicalSequence): + self.has_biological_sequence = BiologicalSequence(self.has_biological_sequence) + self.has_gene = [v if isinstance(v, GeneId) + else GeneId(v) for v in self.has_gene] + + +@dataclass +class DrugExposure(Environment): + """ + A drug exposure is an intake of a particular chemical substance + """ + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "has_phenotype"] + + # === named thing === + id: Union[str, DrugExposureId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === biological entity === + has_phenotype: List[Union[str, PhenotypicFeatureId]] = empty_list() + + # === environment === + + # === drug exposure === + drug: List[Union[str, ChemicalSubstanceId]] = empty_list() + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, DrugExposureId): + self.id = DrugExposureId(self.id) + self.drug = [v if isinstance(v, ChemicalSubstanceId) + else ChemicalSubstanceId(v) for v in self.drug] + + +@dataclass +class Treatment(Environment): + """ + A treatment is targeted at a disease or phenotype and may involve multiple drug 'exposures' + """ + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "has_phenotype", "treats"] + + # === named thing === + id: Union[str, TreatmentId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === biological entity === + has_phenotype: List[Union[str, PhenotypicFeatureId]] = empty_list() + + # === environment === + + # === treatment === + treats: List[Union[str, DiseaseOrPhenotypicFeatureId]] = empty_list() + has_exposure_parts: List[Union[str, DrugExposureId]] = empty_list() + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, TreatmentId): + self.id = TreatmentId(self.id) + self.treats = [v if isinstance(v, DiseaseOrPhenotypicFeatureId) + else DiseaseOrPhenotypicFeatureId(v) for v in self.treats] + self.has_exposure_parts = [v if isinstance(v, DrugExposureId) + else DrugExposureId(v) for v in self.has_exposure_parts] + + +@dataclass +class GeographicLocation(PlanetaryEntity): + """ + a location that can be described in lat/long coordinates + """ + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with"] + + # === named thing === + id: Union[str, GeographicLocationId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === planetary entity === + + # === geographic location === + latitude: Optional[float] = None + longitude: Optional[float] = None + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, GeographicLocationId): + self.id = GeographicLocationId(self.id) + + +@dataclass +class GeographicLocationAtTime(GeographicLocation): + """ + a location that can be described in lat/long coordinates, for a particular time + """ + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with"] + + # === named thing === + id: Union[str, GeographicLocationAtTimeId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === planetary entity === + + # === geographic location === + latitude: Optional[float] = None + longitude: Optional[float] = None + + # === geographic location at time === + timepoint: Optional[Union[str, TimeType]] = None + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, GeographicLocationAtTimeId): + self.id = GeographicLocationAtTimeId(self.id) + if self.timepoint is not None and not isinstance(self.timepoint, TimeType): + self.timepoint = TimeType(self.timepoint) + + +@dataclass +class Association(YAMLRoot): + """ + A typed association between two entities, supported by evidence + """ + _inherited_slots: ClassVar[List[str]] = [] + + # === association === + id: Union[str, AssociationId] + subject: Union[str, IriType] + relation: Union[str, IriType] + object: Union[str, IriType] + edge_label: Union[str, LabelType] + negated: Optional[Bool] = None + association_type: Optional[Union[str, OntologyClassId]] = None + qualifiers: List[Union[str, OntologyClassId]] = empty_list() + publications: List[Union[str, PublicationId]] = empty_list() + provided_by: Optional[Union[str, ProviderId]] = None + association_slot: Optional[str] = None + has_confidence_level: Optional[Union[str, ConfidenceLevelId]] = None + has_evidence: Optional[Union[str, EvidenceTypeId]] = None + clinical_modifier_qualifier: Optional[Union[str, ClinicalModifierId]] = None + + def _fix_elements(self): + super()._fix_elements() + if not isinstance(self.id, AssociationId): + self.id = AssociationId(self.id) + if not isinstance(self.subject, IriType): + self.subject = IriType(self.subject) + if not isinstance(self.relation, IriType): + self.relation = IriType(self.relation) + if not isinstance(self.object, IriType): + self.object = IriType(self.object) + if self.association_type is not None and not isinstance(self.association_type, OntologyClassId): + self.association_type = OntologyClassId(self.association_type) + self.qualifiers = [v if isinstance(v, OntologyClassId) + else OntologyClassId(v) for v in self.qualifiers] + self.publications = [v if isinstance(v, PublicationId) + else PublicationId(v) for v in self.publications] + if self.provided_by is not None and not isinstance(self.provided_by, ProviderId): + self.provided_by = ProviderId(self.provided_by) + if not isinstance(self.edge_label, LabelType): + self.edge_label = LabelType(self.edge_label) + if self.has_confidence_level is not None and not isinstance(self.has_confidence_level, ConfidenceLevelId): + self.has_confidence_level = ConfidenceLevelId(self.has_confidence_level) + if self.has_evidence is not None and not isinstance(self.has_evidence, EvidenceTypeId): + self.has_evidence = EvidenceTypeId(self.has_evidence) + if self.clinical_modifier_qualifier is not None and not isinstance(self.clinical_modifier_qualifier, ClinicalModifierId): + self.clinical_modifier_qualifier = ClinicalModifierId(self.clinical_modifier_qualifier) + + +@dataclass +class GenotypeToGenotypePartAssociation(Association): + """ + Any association between one genotype and a genotypic entity that is a sub-component of it + """ + _inherited_slots: ClassVar[List[str]] = [] + + # === association === + id: Union[str, GenotypeToGenotypePartAssociationId] = None + edge_label: Union[str, LabelType] = None + negated: Optional[Bool] = None + association_type: Optional[Union[str, OntologyClassId]] = None + qualifiers: List[Union[str, OntologyClassId]] = empty_list() + publications: List[Union[str, PublicationId]] = empty_list() + provided_by: Optional[Union[str, ProviderId]] = None + association_slot: Optional[str] = None + has_confidence_level: Optional[Union[str, ConfidenceLevelId]] = None + has_evidence: Optional[Union[str, EvidenceTypeId]] = None + clinical_modifier_qualifier: Optional[Union[str, ClinicalModifierId]] = None + + # === genotype to genotype part association === + subject: Union[str, GenotypeId] = None + relation: Union[str, IriType] = None + object: Union[str, GenotypeId] = None + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, GenotypeToGenotypePartAssociationId): + self.id = GenotypeToGenotypePartAssociationId(self.id) + if self.subject is not None and not isinstance(self.subject, GenotypeId): + self.subject = GenotypeId(self.subject) + if self.relation is not None and not isinstance(self.relation, IriType): + self.relation = IriType(self.relation) + if self.object is not None and not isinstance(self.object, GenotypeId): + self.object = GenotypeId(self.object) + + +@dataclass +class GenotypeToGeneAssociation(Association): + """ + Any association between a genotype and a gene. The genotype have have multiple variants in that gene or a single + one. There is no assumption of cardinality + """ + _inherited_slots: ClassVar[List[str]] = [] + + # === association === + id: Union[str, GenotypeToGeneAssociationId] = None + edge_label: Union[str, LabelType] = None + negated: Optional[Bool] = None + association_type: Optional[Union[str, OntologyClassId]] = None + qualifiers: List[Union[str, OntologyClassId]] = empty_list() + publications: List[Union[str, PublicationId]] = empty_list() + provided_by: Optional[Union[str, ProviderId]] = None + association_slot: Optional[str] = None + has_confidence_level: Optional[Union[str, ConfidenceLevelId]] = None + has_evidence: Optional[Union[str, EvidenceTypeId]] = None + clinical_modifier_qualifier: Optional[Union[str, ClinicalModifierId]] = None + + # === genotype to gene association === + subject: Union[str, GenotypeId] = None + relation: Union[str, IriType] = None + object: Union[str, GeneId] = None + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, GenotypeToGeneAssociationId): + self.id = GenotypeToGeneAssociationId(self.id) + if self.subject is not None and not isinstance(self.subject, GenotypeId): + self.subject = GenotypeId(self.subject) + if self.relation is not None and not isinstance(self.relation, IriType): + self.relation = IriType(self.relation) + if self.object is not None and not isinstance(self.object, GeneId): + self.object = GeneId(self.object) + + +@dataclass +class GenotypeToVariantAssociation(Association): + """ + Any association between a genotype and a sequence variant. + """ + _inherited_slots: ClassVar[List[str]] = [] + + # === association === + id: Union[str, GenotypeToVariantAssociationId] = None + edge_label: Union[str, LabelType] = None + negated: Optional[Bool] = None + association_type: Optional[Union[str, OntologyClassId]] = None + qualifiers: List[Union[str, OntologyClassId]] = empty_list() + publications: List[Union[str, PublicationId]] = empty_list() + provided_by: Optional[Union[str, ProviderId]] = None + association_slot: Optional[str] = None + has_confidence_level: Optional[Union[str, ConfidenceLevelId]] = None + has_evidence: Optional[Union[str, EvidenceTypeId]] = None + clinical_modifier_qualifier: Optional[Union[str, ClinicalModifierId]] = None + + # === genotype to variant association === + subject: Union[str, GenotypeId] = None + relation: Union[str, IriType] = None + object: Union[str, SequenceVariantId] = None + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, GenotypeToVariantAssociationId): + self.id = GenotypeToVariantAssociationId(self.id) + if self.subject is not None and not isinstance(self.subject, GenotypeId): + self.subject = GenotypeId(self.subject) + if self.relation is not None and not isinstance(self.relation, IriType): + self.relation = IriType(self.relation) + if self.object is not None and not isinstance(self.object, SequenceVariantId): + self.object = SequenceVariantId(self.object) + + +@dataclass +class GeneToGeneAssociation(Association): + """ + abstract parent class for different kinds of gene-gene or gene product to gene product relationships. Includes + homology and interaction. + """ + _inherited_slots: ClassVar[List[str]] = [] + + # === association === + id: Union[str, GeneToGeneAssociationId] = None + relation: Union[str, IriType] = None + edge_label: Union[str, LabelType] = None + negated: Optional[Bool] = None + association_type: Optional[Union[str, OntologyClassId]] = None + qualifiers: List[Union[str, OntologyClassId]] = empty_list() + publications: List[Union[str, PublicationId]] = empty_list() + provided_by: Optional[Union[str, ProviderId]] = None + association_slot: Optional[str] = None + has_confidence_level: Optional[Union[str, ConfidenceLevelId]] = None + has_evidence: Optional[Union[str, EvidenceTypeId]] = None + clinical_modifier_qualifier: Optional[Union[str, ClinicalModifierId]] = None + + # === gene to gene association === + subject: Union[str, GeneOrGeneProductId] = None + object: Union[str, GeneOrGeneProductId] = None + + def _fix_elements(self): + super()._fix_elements() + if self.subject is not None and not isinstance(self.subject, GeneOrGeneProductId): + self.subject = GeneOrGeneProductId(self.subject) + if self.object is not None and not isinstance(self.object, GeneOrGeneProductId): + self.object = GeneOrGeneProductId(self.object) + + +@dataclass +class GeneToGeneHomologyAssociation(GeneToGeneAssociation): + """ + A homology association between two genes. May be orthology (in which case the species of subject and object should + differ) or paralogy (in which case the species may be the same) + """ + _inherited_slots: ClassVar[List[str]] = [] + + # === association === + id: Union[str, GeneToGeneHomologyAssociationId] = None + edge_label: Union[str, LabelType] = None + negated: Optional[Bool] = None + association_type: Optional[Union[str, OntologyClassId]] = None + qualifiers: List[Union[str, OntologyClassId]] = empty_list() + publications: List[Union[str, PublicationId]] = empty_list() + provided_by: Optional[Union[str, ProviderId]] = None + association_slot: Optional[str] = None + has_confidence_level: Optional[Union[str, ConfidenceLevelId]] = None + has_evidence: Optional[Union[str, EvidenceTypeId]] = None + clinical_modifier_qualifier: Optional[Union[str, ClinicalModifierId]] = None + + # === gene to gene association === + subject: Union[str, GeneOrGeneProductId] = None + object: Union[str, GeneOrGeneProductId] = None + + # === gene to gene homology association === + relation: Union[str, IriType] = None + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, GeneToGeneHomologyAssociationId): + self.id = GeneToGeneHomologyAssociationId(self.id) + if self.relation is not None and not isinstance(self.relation, IriType): + self.relation = IriType(self.relation) + + +@dataclass +class PairwiseGeneToGeneInteraction(GeneToGeneAssociation): + """ + An interaction between two genes or two gene products. May be physical (e.g. protein binding) or genetic (between + genes). May be symmetric (e.g. protein interaction) or directed (e.g. phosphorylation) + """ + _inherited_slots: ClassVar[List[str]] = [] + + # === association === + id: Union[str, PairwiseGeneToGeneInteractionId] = None + edge_label: Union[str, LabelType] = None + negated: Optional[Bool] = None + association_type: Optional[Union[str, OntologyClassId]] = None + qualifiers: List[Union[str, OntologyClassId]] = empty_list() + publications: List[Union[str, PublicationId]] = empty_list() + provided_by: Optional[Union[str, ProviderId]] = None + association_slot: Optional[str] = None + has_confidence_level: Optional[Union[str, ConfidenceLevelId]] = None + has_evidence: Optional[Union[str, EvidenceTypeId]] = None + clinical_modifier_qualifier: Optional[Union[str, ClinicalModifierId]] = None + + # === gene to gene association === + subject: Union[str, GeneOrGeneProductId] = None + object: Union[str, GeneOrGeneProductId] = None + + # === pairwise gene to gene interaction === + relation: Union[str, IriType] = None + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, PairwiseGeneToGeneInteractionId): + self.id = PairwiseGeneToGeneInteractionId(self.id) + if self.relation is not None and not isinstance(self.relation, IriType): + self.relation = IriType(self.relation) + + +@dataclass +class CellLineToThingAssociation(Association): + """ + An relationship between a cell line and another entity + """ + _inherited_slots: ClassVar[List[str]] = [] + + # === association === + id: Union[str, CellLineToThingAssociationId] = None + relation: Union[str, IriType] = None + object: Union[str, IriType] = None + edge_label: Union[str, LabelType] = None + negated: Optional[Bool] = None + association_type: Optional[Union[str, OntologyClassId]] = None + qualifiers: List[Union[str, OntologyClassId]] = empty_list() + publications: List[Union[str, PublicationId]] = empty_list() + provided_by: Optional[Union[str, ProviderId]] = None + association_slot: Optional[str] = None + has_confidence_level: Optional[Union[str, ConfidenceLevelId]] = None + has_evidence: Optional[Union[str, EvidenceTypeId]] = None + clinical_modifier_qualifier: Optional[Union[str, ClinicalModifierId]] = None + + # === cell line to thing association === + subject: Union[str, CellLineId] = None + + def _fix_elements(self): + super()._fix_elements() + if self.subject is not None and not isinstance(self.subject, CellLineId): + self.subject = CellLineId(self.subject) + + +@dataclass +class CellLineToDiseaseOrPhenotypicFeatureAssociation(Association): + """ + An relationship between a cell line and a disease or a phenotype, where the cell line is derived from an + individual with that disease or phenotype + """ + _inherited_slots: ClassVar[List[str]] = [] + + # === association === + id: Union[str, CellLineToDiseaseOrPhenotypicFeatureAssociationId] = None + relation: Union[str, IriType] = None + object: Union[str, IriType] = None + edge_label: Union[str, LabelType] = None + negated: Optional[Bool] = None + association_type: Optional[Union[str, OntologyClassId]] = None + qualifiers: List[Union[str, OntologyClassId]] = empty_list() + publications: List[Union[str, PublicationId]] = empty_list() + provided_by: Optional[Union[str, ProviderId]] = None + association_slot: Optional[str] = None + has_confidence_level: Optional[Union[str, ConfidenceLevelId]] = None + has_evidence: Optional[Union[str, EvidenceTypeId]] = None + clinical_modifier_qualifier: Optional[Union[str, ClinicalModifierId]] = None + + # === cell line to disease or phenotypic feature association === + subject: Union[str, DiseaseOrPhenotypicFeatureId] = None + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, CellLineToDiseaseOrPhenotypicFeatureAssociationId): + self.id = CellLineToDiseaseOrPhenotypicFeatureAssociationId(self.id) + if self.subject is not None and not isinstance(self.subject, DiseaseOrPhenotypicFeatureId): + self.subject = DiseaseOrPhenotypicFeatureId(self.subject) + + +@dataclass +class ChemicalToThingAssociation(Association): + """ + An interaction between a chemical entity and another entity + """ + _inherited_slots: ClassVar[List[str]] = [] + + # === association === + id: Union[str, ChemicalToThingAssociationId] = None + relation: Union[str, IriType] = None + object: Union[str, IriType] = None + edge_label: Union[str, LabelType] = None + negated: Optional[Bool] = None + association_type: Optional[Union[str, OntologyClassId]] = None + qualifiers: List[Union[str, OntologyClassId]] = empty_list() + publications: List[Union[str, PublicationId]] = empty_list() + provided_by: Optional[Union[str, ProviderId]] = None + association_slot: Optional[str] = None + has_confidence_level: Optional[Union[str, ConfidenceLevelId]] = None + has_evidence: Optional[Union[str, EvidenceTypeId]] = None + clinical_modifier_qualifier: Optional[Union[str, ClinicalModifierId]] = None + + # === chemical to thing association === + subject: Union[str, ChemicalSubstanceId] = None + + def _fix_elements(self): + super()._fix_elements() + if self.subject is not None and not isinstance(self.subject, ChemicalSubstanceId): + self.subject = ChemicalSubstanceId(self.subject) + + +@dataclass +class CaseToThingAssociation(Association): + """ + An abstract association for use where the case is the subject + """ + _inherited_slots: ClassVar[List[str]] = [] + + # === association === + id: Union[str, CaseToThingAssociationId] = None + relation: Union[str, IriType] = None + object: Union[str, IriType] = None + edge_label: Union[str, LabelType] = None + negated: Optional[Bool] = None + association_type: Optional[Union[str, OntologyClassId]] = None + qualifiers: List[Union[str, OntologyClassId]] = empty_list() + publications: List[Union[str, PublicationId]] = empty_list() + provided_by: Optional[Union[str, ProviderId]] = None + association_slot: Optional[str] = None + has_confidence_level: Optional[Union[str, ConfidenceLevelId]] = None + has_evidence: Optional[Union[str, EvidenceTypeId]] = None + clinical_modifier_qualifier: Optional[Union[str, ClinicalModifierId]] = None + + # === case to thing association === + subject: Union[str, CaseId] = None + + def _fix_elements(self): + super()._fix_elements() + if self.subject is not None and not isinstance(self.subject, CaseId): + self.subject = CaseId(self.subject) + + +@dataclass +class ChemicalToDiseaseOrPhenotypicFeatureAssociation(Association): + """ + An interaction between a chemical entity and a phenotype or disease, where the presence of the chemical gives rise + to or exacerbates the phenotype + """ + _inherited_slots: ClassVar[List[str]] = [] + + # === association === + id: Union[str, ChemicalToDiseaseOrPhenotypicFeatureAssociationId] = None + subject: Union[str, IriType] = None + relation: Union[str, IriType] = None + edge_label: Union[str, LabelType] = None + negated: Optional[Bool] = None + association_type: Optional[Union[str, OntologyClassId]] = None + qualifiers: List[Union[str, OntologyClassId]] = empty_list() + publications: List[Union[str, PublicationId]] = empty_list() + provided_by: Optional[Union[str, ProviderId]] = None + association_slot: Optional[str] = None + has_confidence_level: Optional[Union[str, ConfidenceLevelId]] = None + has_evidence: Optional[Union[str, EvidenceTypeId]] = None + clinical_modifier_qualifier: Optional[Union[str, ClinicalModifierId]] = None + + # === chemical to disease or phenotypic feature association === + object: Union[str, DiseaseOrPhenotypicFeatureId] = None + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, ChemicalToDiseaseOrPhenotypicFeatureAssociationId): + self.id = ChemicalToDiseaseOrPhenotypicFeatureAssociationId(self.id) + if self.object is not None and not isinstance(self.object, DiseaseOrPhenotypicFeatureId): + self.object = DiseaseOrPhenotypicFeatureId(self.object) + + +@dataclass +class ChemicalToPathwayAssociation(Association): + """ + An interaction between a chemical entity and a biological process or pathway + """ + _inherited_slots: ClassVar[List[str]] = [] + + # === association === + id: Union[str, ChemicalToPathwayAssociationId] = None + subject: Union[str, IriType] = None + relation: Union[str, IriType] = None + edge_label: Union[str, LabelType] = None + negated: Optional[Bool] = None + association_type: Optional[Union[str, OntologyClassId]] = None + qualifiers: List[Union[str, OntologyClassId]] = empty_list() + publications: List[Union[str, PublicationId]] = empty_list() + provided_by: Optional[Union[str, ProviderId]] = None + association_slot: Optional[str] = None + has_confidence_level: Optional[Union[str, ConfidenceLevelId]] = None + has_evidence: Optional[Union[str, EvidenceTypeId]] = None + clinical_modifier_qualifier: Optional[Union[str, ClinicalModifierId]] = None + + # === chemical to pathway association === + object: Union[str, PathwayId] = None + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, ChemicalToPathwayAssociationId): + self.id = ChemicalToPathwayAssociationId(self.id) + if self.object is not None and not isinstance(self.object, PathwayId): + self.object = PathwayId(self.object) + + +@dataclass +class ChemicalToGeneAssociation(Association): + """ + An interaction between a chemical entity and a gene or gene product + """ + _inherited_slots: ClassVar[List[str]] = [] + + # === association === + id: Union[str, ChemicalToGeneAssociationId] = None + subject: Union[str, IriType] = None + relation: Union[str, IriType] = None + edge_label: Union[str, LabelType] = None + negated: Optional[Bool] = None + association_type: Optional[Union[str, OntologyClassId]] = None + qualifiers: List[Union[str, OntologyClassId]] = empty_list() + publications: List[Union[str, PublicationId]] = empty_list() + provided_by: Optional[Union[str, ProviderId]] = None + association_slot: Optional[str] = None + has_confidence_level: Optional[Union[str, ConfidenceLevelId]] = None + has_evidence: Optional[Union[str, EvidenceTypeId]] = None + clinical_modifier_qualifier: Optional[Union[str, ClinicalModifierId]] = None + + # === chemical to gene association === + object: Union[str, GeneOrGeneProductId] = None + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, ChemicalToGeneAssociationId): + self.id = ChemicalToGeneAssociationId(self.id) + if self.object is not None and not isinstance(self.object, GeneOrGeneProductId): + self.object = GeneOrGeneProductId(self.object) + + +@dataclass +class BiosampleToThingAssociation(Association): + """ + An association between a biosample and something + """ + _inherited_slots: ClassVar[List[str]] = [] + + # === association === + id: Union[str, BiosampleToThingAssociationId] = None + relation: Union[str, IriType] = None + object: Union[str, IriType] = None + edge_label: Union[str, LabelType] = None + negated: Optional[Bool] = None + association_type: Optional[Union[str, OntologyClassId]] = None + qualifiers: List[Union[str, OntologyClassId]] = empty_list() + publications: List[Union[str, PublicationId]] = empty_list() + provided_by: Optional[Union[str, ProviderId]] = None + association_slot: Optional[str] = None + has_confidence_level: Optional[Union[str, ConfidenceLevelId]] = None + has_evidence: Optional[Union[str, EvidenceTypeId]] = None + clinical_modifier_qualifier: Optional[Union[str, ClinicalModifierId]] = None + + # === biosample to thing association === + subject: Union[str, BiosampleId] = None + + def _fix_elements(self): + super()._fix_elements() + if self.subject is not None and not isinstance(self.subject, BiosampleId): + self.subject = BiosampleId(self.subject) + + +@dataclass +class BiosampleToDiseaseOrPhenotypicFeatureAssociation(Association): + """ + An association between a biosample and a disease or phenotype + """ + _inherited_slots: ClassVar[List[str]] = [] + + # === association === + id: Union[str, BiosampleToDiseaseOrPhenotypicFeatureAssociationId] = None + subject: Union[str, IriType] = None + relation: Union[str, IriType] = None + object: Union[str, IriType] = None + edge_label: Union[str, LabelType] = None + negated: Optional[Bool] = None + association_type: Optional[Union[str, OntologyClassId]] = None + qualifiers: List[Union[str, OntologyClassId]] = empty_list() + publications: List[Union[str, PublicationId]] = empty_list() + provided_by: Optional[Union[str, ProviderId]] = None + association_slot: Optional[str] = None + has_confidence_level: Optional[Union[str, ConfidenceLevelId]] = None + has_evidence: Optional[Union[str, EvidenceTypeId]] = None + clinical_modifier_qualifier: Optional[Union[str, ClinicalModifierId]] = None + + # === biosample to disease or phenotypic feature association === + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, BiosampleToDiseaseOrPhenotypicFeatureAssociationId): + self.id = BiosampleToDiseaseOrPhenotypicFeatureAssociationId(self.id) + + +@dataclass +class EntityToPhenotypicFeatureAssociation(Association): + _inherited_slots: ClassVar[List[str]] = [] + + # === association === + id: Union[str, EntityToPhenotypicFeatureAssociationId] = None + subject: Union[str, IriType] = None + relation: Union[str, IriType] = None + edge_label: Union[str, LabelType] = None + negated: Optional[Bool] = None + association_type: Optional[Union[str, OntologyClassId]] = None + qualifiers: List[Union[str, OntologyClassId]] = empty_list() + publications: List[Union[str, PublicationId]] = empty_list() + provided_by: Optional[Union[str, ProviderId]] = None + association_slot: Optional[str] = None + has_confidence_level: Optional[Union[str, ConfidenceLevelId]] = None + has_evidence: Optional[Union[str, EvidenceTypeId]] = None + clinical_modifier_qualifier: Optional[Union[str, ClinicalModifierId]] = None + + # === entity to phenotypic feature association === + object: Union[str, PhenotypicFeatureId] = None + sex_qualifier: Optional[Union[str, BiologicalSexId]] = None + frequency_qualifier: Optional[Union[str, FrequencyValueId]] = None + severity_qualifier: Optional[Union[str, SeverityValueId]] = None + onset_qualifier: Optional[Union[str, OnsetId]] = None + description: Optional[Union[str, NarrativeText]] = None + + def _fix_elements(self): + super()._fix_elements() + if self.object is not None and not isinstance(self.object, PhenotypicFeatureId): + self.object = PhenotypicFeatureId(self.object) + if self.sex_qualifier is not None and not isinstance(self.sex_qualifier, BiologicalSexId): + self.sex_qualifier = BiologicalSexId(self.sex_qualifier) + if self.frequency_qualifier is not None and not isinstance(self.frequency_qualifier, FrequencyValueId): + self.frequency_qualifier = FrequencyValueId(self.frequency_qualifier) + if self.severity_qualifier is not None and not isinstance(self.severity_qualifier, SeverityValueId): + self.severity_qualifier = SeverityValueId(self.severity_qualifier) + if self.onset_qualifier is not None and not isinstance(self.onset_qualifier, OnsetId): + self.onset_qualifier = OnsetId(self.onset_qualifier) + if self.description is not None and not isinstance(self.description, NarrativeText): + self.description = NarrativeText(self.description) + + +@dataclass +class DiseaseOrPhenotypicFeatureAssociationToThingAssociation(Association): + _inherited_slots: ClassVar[List[str]] = [] + + # === association === + id: Union[str, DiseaseOrPhenotypicFeatureAssociationToThingAssociationId] = None + relation: Union[str, IriType] = None + object: Union[str, IriType] = None + edge_label: Union[str, LabelType] = None + negated: Optional[Bool] = None + association_type: Optional[Union[str, OntologyClassId]] = None + qualifiers: List[Union[str, OntologyClassId]] = empty_list() + publications: List[Union[str, PublicationId]] = empty_list() + provided_by: Optional[Union[str, ProviderId]] = None + association_slot: Optional[str] = None + has_confidence_level: Optional[Union[str, ConfidenceLevelId]] = None + has_evidence: Optional[Union[str, EvidenceTypeId]] = None + clinical_modifier_qualifier: Optional[Union[str, ClinicalModifierId]] = None + + # === disease or phenotypic feature association to thing association === + subject: Union[str, DiseaseOrPhenotypicFeatureId] = None + + def _fix_elements(self): + super()._fix_elements() + if self.subject is not None and not isinstance(self.subject, DiseaseOrPhenotypicFeatureId): + self.subject = DiseaseOrPhenotypicFeatureId(self.subject) + + +@dataclass +class DiseaseOrPhenotypicFeatureAssociationToLocationAssociation(DiseaseOrPhenotypicFeatureAssociationToThingAssociation): + """ + An association between either a disease or a phenotypic feature and an anatomical entity, where the + disease/feature manifests in that site. + """ + _inherited_slots: ClassVar[List[str]] = [] + + # === association === + id: Union[str, DiseaseOrPhenotypicFeatureAssociationToLocationAssociationId] = None + relation: Union[str, IriType] = None + edge_label: Union[str, LabelType] = None + negated: Optional[Bool] = None + association_type: Optional[Union[str, OntologyClassId]] = None + qualifiers: List[Union[str, OntologyClassId]] = empty_list() + publications: List[Union[str, PublicationId]] = empty_list() + provided_by: Optional[Union[str, ProviderId]] = None + association_slot: Optional[str] = None + has_confidence_level: Optional[Union[str, ConfidenceLevelId]] = None + has_evidence: Optional[Union[str, EvidenceTypeId]] = None + clinical_modifier_qualifier: Optional[Union[str, ClinicalModifierId]] = None + + # === disease or phenotypic feature association to thing association === + subject: Union[str, DiseaseOrPhenotypicFeatureId] = None + + # === disease or phenotypic feature association to location association === + object: Union[str, AnatomicalEntityId] = None + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, DiseaseOrPhenotypicFeatureAssociationToLocationAssociationId): + self.id = DiseaseOrPhenotypicFeatureAssociationToLocationAssociationId(self.id) + if self.object is not None and not isinstance(self.object, AnatomicalEntityId): + self.object = AnatomicalEntityId(self.object) + + +@dataclass +class ThingToDiseaseOrPhenotypicFeatureAssociation(Association): + _inherited_slots: ClassVar[List[str]] = [] + + # === association === + id: Union[str, ThingToDiseaseOrPhenotypicFeatureAssociationId] = None + subject: Union[str, IriType] = None + relation: Union[str, IriType] = None + edge_label: Union[str, LabelType] = None + negated: Optional[Bool] = None + association_type: Optional[Union[str, OntologyClassId]] = None + qualifiers: List[Union[str, OntologyClassId]] = empty_list() + publications: List[Union[str, PublicationId]] = empty_list() + provided_by: Optional[Union[str, ProviderId]] = None + association_slot: Optional[str] = None + has_confidence_level: Optional[Union[str, ConfidenceLevelId]] = None + has_evidence: Optional[Union[str, EvidenceTypeId]] = None + clinical_modifier_qualifier: Optional[Union[str, ClinicalModifierId]] = None + + # === thing to disease or phenotypic feature association === + object: Union[str, DiseaseOrPhenotypicFeatureId] = None + + def _fix_elements(self): + super()._fix_elements() + if self.object is not None and not isinstance(self.object, DiseaseOrPhenotypicFeatureId): + self.object = DiseaseOrPhenotypicFeatureId(self.object) + + +@dataclass +class DiseaseToThingAssociation(Association): + _inherited_slots: ClassVar[List[str]] = [] + + # === association === + id: Union[str, DiseaseToThingAssociationId] = None + relation: Union[str, IriType] = None + object: Union[str, IriType] = None + edge_label: Union[str, LabelType] = None + negated: Optional[Bool] = None + association_type: Optional[Union[str, OntologyClassId]] = None + qualifiers: List[Union[str, OntologyClassId]] = empty_list() + publications: List[Union[str, PublicationId]] = empty_list() + provided_by: Optional[Union[str, ProviderId]] = None + association_slot: Optional[str] = None + has_confidence_level: Optional[Union[str, ConfidenceLevelId]] = None + has_evidence: Optional[Union[str, EvidenceTypeId]] = None + clinical_modifier_qualifier: Optional[Union[str, ClinicalModifierId]] = None + + # === disease to thing association === + subject: Union[str, DiseaseId] = None + + def _fix_elements(self): + super()._fix_elements() + if self.subject is not None and not isinstance(self.subject, DiseaseId): + self.subject = DiseaseId(self.subject) + + +@dataclass +class GenotypeToPhenotypicFeatureAssociation(Association): + """ + Any association between one genotype and a phenotypic feature, where having the genotype confers the phenotype, + either in isolation or through environment + """ + _inherited_slots: ClassVar[List[str]] = [] + + # === association === + id: Union[str, GenotypeToPhenotypicFeatureAssociationId] = None + object: Union[str, IriType] = None + edge_label: Union[str, LabelType] = None + negated: Optional[Bool] = None + association_type: Optional[Union[str, OntologyClassId]] = None + qualifiers: List[Union[str, OntologyClassId]] = empty_list() + publications: List[Union[str, PublicationId]] = empty_list() + provided_by: Optional[Union[str, ProviderId]] = None + association_slot: Optional[str] = None + has_confidence_level: Optional[Union[str, ConfidenceLevelId]] = None + has_evidence: Optional[Union[str, EvidenceTypeId]] = None + clinical_modifier_qualifier: Optional[Union[str, ClinicalModifierId]] = None + + # === genotype to phenotypic feature association === + subject: Union[str, GenotypeId] = None + relation: Union[str, IriType] = None + sex_qualifier: Optional[Union[str, BiologicalSexId]] = None + frequency_qualifier: Optional[Union[str, FrequencyValueId]] = None + severity_qualifier: Optional[Union[str, SeverityValueId]] = None + onset_qualifier: Optional[Union[str, OnsetId]] = None + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, GenotypeToPhenotypicFeatureAssociationId): + self.id = GenotypeToPhenotypicFeatureAssociationId(self.id) + if self.subject is not None and not isinstance(self.subject, GenotypeId): + self.subject = GenotypeId(self.subject) + if self.relation is not None and not isinstance(self.relation, IriType): + self.relation = IriType(self.relation) + if self.sex_qualifier is not None and not isinstance(self.sex_qualifier, BiologicalSexId): + self.sex_qualifier = BiologicalSexId(self.sex_qualifier) + if self.frequency_qualifier is not None and not isinstance(self.frequency_qualifier, FrequencyValueId): + self.frequency_qualifier = FrequencyValueId(self.frequency_qualifier) + if self.severity_qualifier is not None and not isinstance(self.severity_qualifier, SeverityValueId): + self.severity_qualifier = SeverityValueId(self.severity_qualifier) + if self.onset_qualifier is not None and not isinstance(self.onset_qualifier, OnsetId): + self.onset_qualifier = OnsetId(self.onset_qualifier) + + +@dataclass +class EnvironmentToPhenotypicFeatureAssociation(Association): + """ + Any association between an environment and a phenotypic feature, where being in the environment influences the + phenotype + """ + _inherited_slots: ClassVar[List[str]] = [] + + # === association === + id: Union[str, EnvironmentToPhenotypicFeatureAssociationId] = None + relation: Union[str, IriType] = None + object: Union[str, IriType] = None + edge_label: Union[str, LabelType] = None + negated: Optional[Bool] = None + association_type: Optional[Union[str, OntologyClassId]] = None + qualifiers: List[Union[str, OntologyClassId]] = empty_list() + publications: List[Union[str, PublicationId]] = empty_list() + provided_by: Optional[Union[str, ProviderId]] = None + association_slot: Optional[str] = None + has_confidence_level: Optional[Union[str, ConfidenceLevelId]] = None + has_evidence: Optional[Union[str, EvidenceTypeId]] = None + clinical_modifier_qualifier: Optional[Union[str, ClinicalModifierId]] = None + + # === environment to phenotypic feature association === + subject: Union[str, EnvironmentId] = None + sex_qualifier: Optional[Union[str, BiologicalSexId]] = None + frequency_qualifier: Optional[Union[str, FrequencyValueId]] = None + severity_qualifier: Optional[Union[str, SeverityValueId]] = None + onset_qualifier: Optional[Union[str, OnsetId]] = None + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, EnvironmentToPhenotypicFeatureAssociationId): + self.id = EnvironmentToPhenotypicFeatureAssociationId(self.id) + if self.subject is not None and not isinstance(self.subject, EnvironmentId): + self.subject = EnvironmentId(self.subject) + if self.sex_qualifier is not None and not isinstance(self.sex_qualifier, BiologicalSexId): + self.sex_qualifier = BiologicalSexId(self.sex_qualifier) + if self.frequency_qualifier is not None and not isinstance(self.frequency_qualifier, FrequencyValueId): + self.frequency_qualifier = FrequencyValueId(self.frequency_qualifier) + if self.severity_qualifier is not None and not isinstance(self.severity_qualifier, SeverityValueId): + self.severity_qualifier = SeverityValueId(self.severity_qualifier) + if self.onset_qualifier is not None and not isinstance(self.onset_qualifier, OnsetId): + self.onset_qualifier = OnsetId(self.onset_qualifier) + + +@dataclass +class DiseaseToPhenotypicFeatureAssociation(Association): + """ + An association between a disease and a phenotypic feature in which the phenotypic feature is associated with the + disease in some way + """ + _inherited_slots: ClassVar[List[str]] = [] + + # === association === + id: Union[str, DiseaseToPhenotypicFeatureAssociationId] = None + subject: Union[str, IriType] = None + relation: Union[str, IriType] = None + object: Union[str, IriType] = None + edge_label: Union[str, LabelType] = None + negated: Optional[Bool] = None + association_type: Optional[Union[str, OntologyClassId]] = None + qualifiers: List[Union[str, OntologyClassId]] = empty_list() + publications: List[Union[str, PublicationId]] = empty_list() + provided_by: Optional[Union[str, ProviderId]] = None + association_slot: Optional[str] = None + has_confidence_level: Optional[Union[str, ConfidenceLevelId]] = None + has_evidence: Optional[Union[str, EvidenceTypeId]] = None + clinical_modifier_qualifier: Optional[Union[str, ClinicalModifierId]] = None + + # === disease to phenotypic feature association === + sex_qualifier: Optional[Union[str, BiologicalSexId]] = None + frequency_qualifier: Optional[Union[str, FrequencyValueId]] = None + severity_qualifier: Optional[Union[str, SeverityValueId]] = None + onset_qualifier: Optional[Union[str, OnsetId]] = None + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, DiseaseToPhenotypicFeatureAssociationId): + self.id = DiseaseToPhenotypicFeatureAssociationId(self.id) + if self.sex_qualifier is not None and not isinstance(self.sex_qualifier, BiologicalSexId): + self.sex_qualifier = BiologicalSexId(self.sex_qualifier) + if self.frequency_qualifier is not None and not isinstance(self.frequency_qualifier, FrequencyValueId): + self.frequency_qualifier = FrequencyValueId(self.frequency_qualifier) + if self.severity_qualifier is not None and not isinstance(self.severity_qualifier, SeverityValueId): + self.severity_qualifier = SeverityValueId(self.severity_qualifier) + if self.onset_qualifier is not None and not isinstance(self.onset_qualifier, OnsetId): + self.onset_qualifier = OnsetId(self.onset_qualifier) + + +@dataclass +class CaseToPhenotypicFeatureAssociation(Association): + """ + An association between a case (e.g. individual patient) and a phenotypic feature in which the individual has or + has had the phenotype + """ + _inherited_slots: ClassVar[List[str]] = [] + + # === association === + id: Union[str, CaseToPhenotypicFeatureAssociationId] = None + subject: Union[str, IriType] = None + relation: Union[str, IriType] = None + object: Union[str, IriType] = None + edge_label: Union[str, LabelType] = None + negated: Optional[Bool] = None + association_type: Optional[Union[str, OntologyClassId]] = None + qualifiers: List[Union[str, OntologyClassId]] = empty_list() + publications: List[Union[str, PublicationId]] = empty_list() + provided_by: Optional[Union[str, ProviderId]] = None + association_slot: Optional[str] = None + has_confidence_level: Optional[Union[str, ConfidenceLevelId]] = None + has_evidence: Optional[Union[str, EvidenceTypeId]] = None + clinical_modifier_qualifier: Optional[Union[str, ClinicalModifierId]] = None + + # === case to phenotypic feature association === + sex_qualifier: Optional[Union[str, BiologicalSexId]] = None + frequency_qualifier: Optional[Union[str, FrequencyValueId]] = None + severity_qualifier: Optional[Union[str, SeverityValueId]] = None + onset_qualifier: Optional[Union[str, OnsetId]] = None + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, CaseToPhenotypicFeatureAssociationId): + self.id = CaseToPhenotypicFeatureAssociationId(self.id) + if self.sex_qualifier is not None and not isinstance(self.sex_qualifier, BiologicalSexId): + self.sex_qualifier = BiologicalSexId(self.sex_qualifier) + if self.frequency_qualifier is not None and not isinstance(self.frequency_qualifier, FrequencyValueId): + self.frequency_qualifier = FrequencyValueId(self.frequency_qualifier) + if self.severity_qualifier is not None and not isinstance(self.severity_qualifier, SeverityValueId): + self.severity_qualifier = SeverityValueId(self.severity_qualifier) + if self.onset_qualifier is not None and not isinstance(self.onset_qualifier, OnsetId): + self.onset_qualifier = OnsetId(self.onset_qualifier) + + +@dataclass +class GeneToThingAssociation(Association): + _inherited_slots: ClassVar[List[str]] = [] + + # === association === + id: Union[str, GeneToThingAssociationId] = None + relation: Union[str, IriType] = None + object: Union[str, IriType] = None + edge_label: Union[str, LabelType] = None + negated: Optional[Bool] = None + association_type: Optional[Union[str, OntologyClassId]] = None + qualifiers: List[Union[str, OntologyClassId]] = empty_list() + publications: List[Union[str, PublicationId]] = empty_list() + provided_by: Optional[Union[str, ProviderId]] = None + association_slot: Optional[str] = None + has_confidence_level: Optional[Union[str, ConfidenceLevelId]] = None + has_evidence: Optional[Union[str, EvidenceTypeId]] = None + clinical_modifier_qualifier: Optional[Union[str, ClinicalModifierId]] = None + + # === gene to thing association === + subject: Union[str, GeneOrGeneProductId] = None + + def _fix_elements(self): + super()._fix_elements() + if self.subject is not None and not isinstance(self.subject, GeneOrGeneProductId): + self.subject = GeneOrGeneProductId(self.subject) + + +@dataclass +class GeneToPhenotypicFeatureAssociation(Association): + _inherited_slots: ClassVar[List[str]] = [] + + # === association === + id: Union[str, GeneToPhenotypicFeatureAssociationId] = None + relation: Union[str, IriType] = None + object: Union[str, IriType] = None + edge_label: Union[str, LabelType] = None + negated: Optional[Bool] = None + association_type: Optional[Union[str, OntologyClassId]] = None + qualifiers: List[Union[str, OntologyClassId]] = empty_list() + publications: List[Union[str, PublicationId]] = empty_list() + provided_by: Optional[Union[str, ProviderId]] = None + association_slot: Optional[str] = None + has_confidence_level: Optional[Union[str, ConfidenceLevelId]] = None + has_evidence: Optional[Union[str, EvidenceTypeId]] = None + clinical_modifier_qualifier: Optional[Union[str, ClinicalModifierId]] = None + + # === gene to phenotypic feature association === + subject: Union[str, GeneOrGeneProductId] = None + sex_qualifier: Optional[Union[str, BiologicalSexId]] = None + frequency_qualifier: Optional[Union[str, FrequencyValueId]] = None + severity_qualifier: Optional[Union[str, SeverityValueId]] = None + onset_qualifier: Optional[Union[str, OnsetId]] = None + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, GeneToPhenotypicFeatureAssociationId): + self.id = GeneToPhenotypicFeatureAssociationId(self.id) + if self.subject is not None and not isinstance(self.subject, GeneOrGeneProductId): + self.subject = GeneOrGeneProductId(self.subject) + if self.sex_qualifier is not None and not isinstance(self.sex_qualifier, BiologicalSexId): + self.sex_qualifier = BiologicalSexId(self.sex_qualifier) + if self.frequency_qualifier is not None and not isinstance(self.frequency_qualifier, FrequencyValueId): + self.frequency_qualifier = FrequencyValueId(self.frequency_qualifier) + if self.severity_qualifier is not None and not isinstance(self.severity_qualifier, SeverityValueId): + self.severity_qualifier = SeverityValueId(self.severity_qualifier) + if self.onset_qualifier is not None and not isinstance(self.onset_qualifier, OnsetId): + self.onset_qualifier = OnsetId(self.onset_qualifier) + + +@dataclass +class GeneToDiseaseAssociation(Association): + _inherited_slots: ClassVar[List[str]] = [] + + # === association === + id: Union[str, GeneToDiseaseAssociationId] = None + relation: Union[str, IriType] = None + object: Union[str, IriType] = None + edge_label: Union[str, LabelType] = None + negated: Optional[Bool] = None + association_type: Optional[Union[str, OntologyClassId]] = None + qualifiers: List[Union[str, OntologyClassId]] = empty_list() + publications: List[Union[str, PublicationId]] = empty_list() + provided_by: Optional[Union[str, ProviderId]] = None + association_slot: Optional[str] = None + has_confidence_level: Optional[Union[str, ConfidenceLevelId]] = None + has_evidence: Optional[Union[str, EvidenceTypeId]] = None + clinical_modifier_qualifier: Optional[Union[str, ClinicalModifierId]] = None + + # === gene to disease association === + subject: Union[str, GeneOrGeneProductId] = None + frequency_qualifier: Optional[Union[str, FrequencyValueId]] = None + severity_qualifier: Optional[Union[str, SeverityValueId]] = None + onset_qualifier: Optional[Union[str, OnsetId]] = None + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, GeneToDiseaseAssociationId): + self.id = GeneToDiseaseAssociationId(self.id) + if self.subject is not None and not isinstance(self.subject, GeneOrGeneProductId): + self.subject = GeneOrGeneProductId(self.subject) + if self.frequency_qualifier is not None and not isinstance(self.frequency_qualifier, FrequencyValueId): + self.frequency_qualifier = FrequencyValueId(self.frequency_qualifier) + if self.severity_qualifier is not None and not isinstance(self.severity_qualifier, SeverityValueId): + self.severity_qualifier = SeverityValueId(self.severity_qualifier) + if self.onset_qualifier is not None and not isinstance(self.onset_qualifier, OnsetId): + self.onset_qualifier = OnsetId(self.onset_qualifier) + + +@dataclass +class VariantToPopulationAssociation(Association): + """ + An association between a variant and a population, where the variant has particular frequency in the population + """ + _inherited_slots: ClassVar[List[str]] = [] + + # === association === + id: Union[str, VariantToPopulationAssociationId] = None + relation: Union[str, IriType] = None + edge_label: Union[str, LabelType] = None + negated: Optional[Bool] = None + association_type: Optional[Union[str, OntologyClassId]] = None + qualifiers: List[Union[str, OntologyClassId]] = empty_list() + publications: List[Union[str, PublicationId]] = empty_list() + provided_by: Optional[Union[str, ProviderId]] = None + association_slot: Optional[str] = None + has_confidence_level: Optional[Union[str, ConfidenceLevelId]] = None + has_evidence: Optional[Union[str, EvidenceTypeId]] = None + clinical_modifier_qualifier: Optional[Union[str, ClinicalModifierId]] = None + + # === variant to population association === + subject: Union[str, SequenceVariantId] = None + object: Union[str, PopulationOfIndividualOrganismsId] = None + has_count: Optional[int] = None + has_total: Optional[int] = None + has_quotient: Optional[float] = None + has_percentage: Optional[float] = None + frequency_qualifier: Optional[Union[str, FrequencyValueId]] = None + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, VariantToPopulationAssociationId): + self.id = VariantToPopulationAssociationId(self.id) + if self.subject is not None and not isinstance(self.subject, SequenceVariantId): + self.subject = SequenceVariantId(self.subject) + if self.object is not None and not isinstance(self.object, PopulationOfIndividualOrganismsId): + self.object = PopulationOfIndividualOrganismsId(self.object) + if self.frequency_qualifier is not None and not isinstance(self.frequency_qualifier, FrequencyValueId): + self.frequency_qualifier = FrequencyValueId(self.frequency_qualifier) + + +@dataclass +class PopulationToPopulationAssociation(Association): + """ + An association between a two populations + """ + _inherited_slots: ClassVar[List[str]] = [] + + # === association === + id: Union[str, PopulationToPopulationAssociationId] = None + edge_label: Union[str, LabelType] = None + negated: Optional[Bool] = None + association_type: Optional[Union[str, OntologyClassId]] = None + qualifiers: List[Union[str, OntologyClassId]] = empty_list() + publications: List[Union[str, PublicationId]] = empty_list() + provided_by: Optional[Union[str, ProviderId]] = None + association_slot: Optional[str] = None + has_confidence_level: Optional[Union[str, ConfidenceLevelId]] = None + has_evidence: Optional[Union[str, EvidenceTypeId]] = None + clinical_modifier_qualifier: Optional[Union[str, ClinicalModifierId]] = None + + # === population to population association === + subject: Union[str, PopulationOfIndividualOrganismsId] = None + relation: Union[str, IriType] = None + object: Union[str, PopulationOfIndividualOrganismsId] = None + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, PopulationToPopulationAssociationId): + self.id = PopulationToPopulationAssociationId(self.id) + if self.subject is not None and not isinstance(self.subject, PopulationOfIndividualOrganismsId): + self.subject = PopulationOfIndividualOrganismsId(self.subject) + if self.relation is not None and not isinstance(self.relation, IriType): + self.relation = IriType(self.relation) + if self.object is not None and not isinstance(self.object, PopulationOfIndividualOrganismsId): + self.object = PopulationOfIndividualOrganismsId(self.object) + + +@dataclass +class VariantToPhenotypicFeatureAssociation(Association): + _inherited_slots: ClassVar[List[str]] = [] + + # === association === + id: Union[str, VariantToPhenotypicFeatureAssociationId] = None + relation: Union[str, IriType] = None + object: Union[str, IriType] = None + edge_label: Union[str, LabelType] = None + negated: Optional[Bool] = None + association_type: Optional[Union[str, OntologyClassId]] = None + qualifiers: List[Union[str, OntologyClassId]] = empty_list() + publications: List[Union[str, PublicationId]] = empty_list() + provided_by: Optional[Union[str, ProviderId]] = None + association_slot: Optional[str] = None + has_confidence_level: Optional[Union[str, ConfidenceLevelId]] = None + has_evidence: Optional[Union[str, EvidenceTypeId]] = None + clinical_modifier_qualifier: Optional[Union[str, ClinicalModifierId]] = None + + # === variant to phenotypic feature association === + subject: Union[str, SequenceVariantId] = None + sex_qualifier: Optional[Union[str, BiologicalSexId]] = None + frequency_qualifier: Optional[Union[str, FrequencyValueId]] = None + severity_qualifier: Optional[Union[str, SeverityValueId]] = None + onset_qualifier: Optional[Union[str, OnsetId]] = None + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, VariantToPhenotypicFeatureAssociationId): + self.id = VariantToPhenotypicFeatureAssociationId(self.id) + if self.subject is not None and not isinstance(self.subject, SequenceVariantId): + self.subject = SequenceVariantId(self.subject) + if self.sex_qualifier is not None and not isinstance(self.sex_qualifier, BiologicalSexId): + self.sex_qualifier = BiologicalSexId(self.sex_qualifier) + if self.frequency_qualifier is not None and not isinstance(self.frequency_qualifier, FrequencyValueId): + self.frequency_qualifier = FrequencyValueId(self.frequency_qualifier) + if self.severity_qualifier is not None and not isinstance(self.severity_qualifier, SeverityValueId): + self.severity_qualifier = SeverityValueId(self.severity_qualifier) + if self.onset_qualifier is not None and not isinstance(self.onset_qualifier, OnsetId): + self.onset_qualifier = OnsetId(self.onset_qualifier) + + +@dataclass +class VariantToDiseaseAssociation(Association): + _inherited_slots: ClassVar[List[str]] = [] + + # === association === + id: Union[str, VariantToDiseaseAssociationId] = None + edge_label: Union[str, LabelType] = None + negated: Optional[Bool] = None + association_type: Optional[Union[str, OntologyClassId]] = None + qualifiers: List[Union[str, OntologyClassId]] = empty_list() + publications: List[Union[str, PublicationId]] = empty_list() + provided_by: Optional[Union[str, ProviderId]] = None + association_slot: Optional[str] = None + has_confidence_level: Optional[Union[str, ConfidenceLevelId]] = None + has_evidence: Optional[Union[str, EvidenceTypeId]] = None + clinical_modifier_qualifier: Optional[Union[str, ClinicalModifierId]] = None + + # === variant to disease association === + subject: Union[str, IriType] = None + relation: Union[str, IriType] = None + object: Union[str, IriType] = None + frequency_qualifier: Optional[Union[str, FrequencyValueId]] = None + severity_qualifier: Optional[Union[str, SeverityValueId]] = None + onset_qualifier: Optional[Union[str, OnsetId]] = None + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, VariantToDiseaseAssociationId): + self.id = VariantToDiseaseAssociationId(self.id) + if self.subject is not None and not isinstance(self.subject, IriType): + self.subject = IriType(self.subject) + if self.relation is not None and not isinstance(self.relation, IriType): + self.relation = IriType(self.relation) + if self.object is not None and not isinstance(self.object, IriType): + self.object = IriType(self.object) + if self.frequency_qualifier is not None and not isinstance(self.frequency_qualifier, FrequencyValueId): + self.frequency_qualifier = FrequencyValueId(self.frequency_qualifier) + if self.severity_qualifier is not None and not isinstance(self.severity_qualifier, SeverityValueId): + self.severity_qualifier = SeverityValueId(self.severity_qualifier) + if self.onset_qualifier is not None and not isinstance(self.onset_qualifier, OnsetId): + self.onset_qualifier = OnsetId(self.onset_qualifier) + + +@dataclass +class GeneAsAModelOfDiseaseAssociation(GeneToDiseaseAssociation): + _inherited_slots: ClassVar[List[str]] = [] + + # === association === + id: Union[str, GeneAsAModelOfDiseaseAssociationId] = None + relation: Union[str, IriType] = None + object: Union[str, IriType] = None + edge_label: Union[str, LabelType] = None + negated: Optional[Bool] = None + association_type: Optional[Union[str, OntologyClassId]] = None + qualifiers: List[Union[str, OntologyClassId]] = empty_list() + publications: List[Union[str, PublicationId]] = empty_list() + provided_by: Optional[Union[str, ProviderId]] = None + association_slot: Optional[str] = None + has_confidence_level: Optional[Union[str, ConfidenceLevelId]] = None + has_evidence: Optional[Union[str, EvidenceTypeId]] = None + clinical_modifier_qualifier: Optional[Union[str, ClinicalModifierId]] = None + + # === gene to disease association === + frequency_qualifier: Optional[Union[str, FrequencyValueId]] = None + severity_qualifier: Optional[Union[str, SeverityValueId]] = None + onset_qualifier: Optional[Union[str, OnsetId]] = None + + # === gene as a model of disease association === + subject: Union[str, GeneOrGeneProductId] = None + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, GeneAsAModelOfDiseaseAssociationId): + self.id = GeneAsAModelOfDiseaseAssociationId(self.id) + if self.subject is not None and not isinstance(self.subject, GeneOrGeneProductId): + self.subject = GeneOrGeneProductId(self.subject) + + +@dataclass +class GeneHasVariantThatContributesToDiseaseAssociation(GeneToDiseaseAssociation): + _inherited_slots: ClassVar[List[str]] = [] + + # === association === + id: Union[str, GeneHasVariantThatContributesToDiseaseAssociationId] = None + relation: Union[str, IriType] = None + object: Union[str, IriType] = None + edge_label: Union[str, LabelType] = None + negated: Optional[Bool] = None + association_type: Optional[Union[str, OntologyClassId]] = None + qualifiers: List[Union[str, OntologyClassId]] = empty_list() + publications: List[Union[str, PublicationId]] = empty_list() + provided_by: Optional[Union[str, ProviderId]] = None + association_slot: Optional[str] = None + has_confidence_level: Optional[Union[str, ConfidenceLevelId]] = None + has_evidence: Optional[Union[str, EvidenceTypeId]] = None + clinical_modifier_qualifier: Optional[Union[str, ClinicalModifierId]] = None + + # === gene to disease association === + frequency_qualifier: Optional[Union[str, FrequencyValueId]] = None + severity_qualifier: Optional[Union[str, SeverityValueId]] = None + onset_qualifier: Optional[Union[str, OnsetId]] = None + + # === gene has variant that contributes to disease association === + subject: Union[str, GeneOrGeneProductId] = None + sequence_variant_qualifier: Optional[Union[str, SequenceVariantId]] = None + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, GeneHasVariantThatContributesToDiseaseAssociationId): + self.id = GeneHasVariantThatContributesToDiseaseAssociationId(self.id) + if self.subject is not None and not isinstance(self.subject, GeneOrGeneProductId): + self.subject = GeneOrGeneProductId(self.subject) + if self.sequence_variant_qualifier is not None and not isinstance(self.sequence_variant_qualifier, SequenceVariantId): + self.sequence_variant_qualifier = SequenceVariantId(self.sequence_variant_qualifier) + + +@dataclass +class GenotypeToThingAssociation(Association): + _inherited_slots: ClassVar[List[str]] = [] + + # === association === + id: Union[str, GenotypeToThingAssociationId] = None + relation: Union[str, IriType] = None + object: Union[str, IriType] = None + edge_label: Union[str, LabelType] = None + negated: Optional[Bool] = None + association_type: Optional[Union[str, OntologyClassId]] = None + qualifiers: List[Union[str, OntologyClassId]] = empty_list() + publications: List[Union[str, PublicationId]] = empty_list() + provided_by: Optional[Union[str, ProviderId]] = None + association_slot: Optional[str] = None + has_confidence_level: Optional[Union[str, ConfidenceLevelId]] = None + has_evidence: Optional[Union[str, EvidenceTypeId]] = None + clinical_modifier_qualifier: Optional[Union[str, ClinicalModifierId]] = None + + # === genotype to thing association === + subject: Union[str, GenotypeId] = None + + def _fix_elements(self): + super()._fix_elements() + if self.subject is not None and not isinstance(self.subject, GenotypeId): + self.subject = GenotypeId(self.subject) + + +@dataclass +class GeneToExpressionSiteAssociation(Association): + """ + An association between a gene and an expression site, possibly qualified by stage/timing info. + """ + _inherited_slots: ClassVar[List[str]] = [] + + # === association === + id: Union[str, GeneToExpressionSiteAssociationId] = None + edge_label: Union[str, LabelType] = None + negated: Optional[Bool] = None + association_type: Optional[Union[str, OntologyClassId]] = None + qualifiers: List[Union[str, OntologyClassId]] = empty_list() + publications: List[Union[str, PublicationId]] = empty_list() + provided_by: Optional[Union[str, ProviderId]] = None + association_slot: Optional[str] = None + has_confidence_level: Optional[Union[str, ConfidenceLevelId]] = None + has_evidence: Optional[Union[str, EvidenceTypeId]] = None + clinical_modifier_qualifier: Optional[Union[str, ClinicalModifierId]] = None + + # === gene to expression site association === + subject: Union[str, GeneOrGeneProductId] = None + relation: Union[str, IriType] = None + object: Union[str, AnatomicalEntityId] = None + stage_qualifier: Optional[Union[str, LifeStageId]] = None + quantifier_qualifier: Optional[Union[str, OntologyClassId]] = None + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, GeneToExpressionSiteAssociationId): + self.id = GeneToExpressionSiteAssociationId(self.id) + if self.subject is not None and not isinstance(self.subject, GeneOrGeneProductId): + self.subject = GeneOrGeneProductId(self.subject) + if self.relation is not None and not isinstance(self.relation, IriType): + self.relation = IriType(self.relation) + if self.object is not None and not isinstance(self.object, AnatomicalEntityId): + self.object = AnatomicalEntityId(self.object) + if self.stage_qualifier is not None and not isinstance(self.stage_qualifier, LifeStageId): + self.stage_qualifier = LifeStageId(self.stage_qualifier) + if self.quantifier_qualifier is not None and not isinstance(self.quantifier_qualifier, OntologyClassId): + self.quantifier_qualifier = OntologyClassId(self.quantifier_qualifier) + + +@dataclass +class SequenceVariantModulatesTreatmentAssociation(Association): + """ + An association between a sequence variant and a treatment or health intervention. The treatment object itself + encompasses both the disease and the drug used. + """ + _inherited_slots: ClassVar[List[str]] = [] + + # === association === + id: Union[str, SequenceVariantModulatesTreatmentAssociationId] = None + relation: Union[str, IriType] = None + edge_label: Union[str, LabelType] = None + negated: Optional[Bool] = None + association_type: Optional[Union[str, OntologyClassId]] = None + qualifiers: List[Union[str, OntologyClassId]] = empty_list() + publications: List[Union[str, PublicationId]] = empty_list() + provided_by: Optional[Union[str, ProviderId]] = None + association_slot: Optional[str] = None + has_confidence_level: Optional[Union[str, ConfidenceLevelId]] = None + has_evidence: Optional[Union[str, EvidenceTypeId]] = None + clinical_modifier_qualifier: Optional[Union[str, ClinicalModifierId]] = None + + # === sequence variant modulates treatment association === + subject: Union[str, SequenceVariantId] = None + object: Union[str, TreatmentId] = None + + def _fix_elements(self): + super()._fix_elements() + if self.subject is not None and not isinstance(self.subject, SequenceVariantId): + self.subject = SequenceVariantId(self.subject) + if self.object is not None and not isinstance(self.object, TreatmentId): + self.object = TreatmentId(self.object) + + +@dataclass +class FunctionalAssociation(Association): + """ + An association between a macromolecular machine (gene, gene product or complex of gene products) and either a + molecular activity, a biological process or a cellular location in which a function is executed + """ + _inherited_slots: ClassVar[List[str]] = [] + + # === association === + id: Union[str, FunctionalAssociationId] = None + relation: Union[str, IriType] = None + edge_label: Union[str, LabelType] = None + negated: Optional[Bool] = None + association_type: Optional[Union[str, OntologyClassId]] = None + qualifiers: List[Union[str, OntologyClassId]] = empty_list() + publications: List[Union[str, PublicationId]] = empty_list() + provided_by: Optional[Union[str, ProviderId]] = None + association_slot: Optional[str] = None + has_confidence_level: Optional[Union[str, ConfidenceLevelId]] = None + has_evidence: Optional[Union[str, EvidenceTypeId]] = None + clinical_modifier_qualifier: Optional[Union[str, ClinicalModifierId]] = None + + # === functional association === + subject: Union[str, MacromolecularMachineId] = None + object: Union[str, GeneOntologyClassId] = None + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, FunctionalAssociationId): + self.id = FunctionalAssociationId(self.id) + if self.subject is not None and not isinstance(self.subject, MacromolecularMachineId): + self.subject = MacromolecularMachineId(self.subject) + if self.object is not None and not isinstance(self.object, GeneOntologyClassId): + self.object = GeneOntologyClassId(self.object) + + +@dataclass +class MacromolecularMachineToMolecularActivityAssociation(FunctionalAssociation): + """ + A functional association between a macromolecular machine (gene, gene product or complex) and a molecular activity + (as represented in the GO molecular function branch), where the entity carries out the activity, or contributes to + its execution + """ + _inherited_slots: ClassVar[List[str]] = [] + + # === association === + id: Union[str, MacromolecularMachineToMolecularActivityAssociationId] = None + relation: Union[str, IriType] = None + edge_label: Union[str, LabelType] = None + negated: Optional[Bool] = None + association_type: Optional[Union[str, OntologyClassId]] = None + qualifiers: List[Union[str, OntologyClassId]] = empty_list() + publications: List[Union[str, PublicationId]] = empty_list() + provided_by: Optional[Union[str, ProviderId]] = None + association_slot: Optional[str] = None + has_confidence_level: Optional[Union[str, ConfidenceLevelId]] = None + has_evidence: Optional[Union[str, EvidenceTypeId]] = None + clinical_modifier_qualifier: Optional[Union[str, ClinicalModifierId]] = None + + # === functional association === + subject: Union[str, MacromolecularMachineId] = None + + # === macromolecular machine to molecular activity association === + object: Union[str, MolecularActivityId] = None + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, MacromolecularMachineToMolecularActivityAssociationId): + self.id = MacromolecularMachineToMolecularActivityAssociationId(self.id) + if self.object is not None and not isinstance(self.object, MolecularActivityId): + self.object = MolecularActivityId(self.object) + + +@dataclass +class MacromolecularMachineToBiologicalProcessAssociation(FunctionalAssociation): + """ + A functional association between a macromolecular machine (gene, gene product or complex) and a biological process + or pathway (as represented in the GO biological process branch), where the entity carries out some part of the + process, regulates it, or acts upstream of it + """ + _inherited_slots: ClassVar[List[str]] = [] + + # === association === + id: Union[str, MacromolecularMachineToBiologicalProcessAssociationId] = None + relation: Union[str, IriType] = None + edge_label: Union[str, LabelType] = None + negated: Optional[Bool] = None + association_type: Optional[Union[str, OntologyClassId]] = None + qualifiers: List[Union[str, OntologyClassId]] = empty_list() + publications: List[Union[str, PublicationId]] = empty_list() + provided_by: Optional[Union[str, ProviderId]] = None + association_slot: Optional[str] = None + has_confidence_level: Optional[Union[str, ConfidenceLevelId]] = None + has_evidence: Optional[Union[str, EvidenceTypeId]] = None + clinical_modifier_qualifier: Optional[Union[str, ClinicalModifierId]] = None + + # === functional association === + subject: Union[str, MacromolecularMachineId] = None + + # === macromolecular machine to biological process association === + object: Union[str, BiologicalProcessId] = None + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, MacromolecularMachineToBiologicalProcessAssociationId): + self.id = MacromolecularMachineToBiologicalProcessAssociationId(self.id) + if self.object is not None and not isinstance(self.object, BiologicalProcessId): + self.object = BiologicalProcessId(self.object) + + +@dataclass +class MacromolecularMachineToCellularComponentAssociation(FunctionalAssociation): + """ + A functional association between a macromolecular machine (gene, gene product or complex) and a cellular component + (as represented in the GO cellular component branch), where the entity carries out its function in the cellular + component + """ + _inherited_slots: ClassVar[List[str]] = [] + + # === association === + id: Union[str, MacromolecularMachineToCellularComponentAssociationId] = None + relation: Union[str, IriType] = None + edge_label: Union[str, LabelType] = None + negated: Optional[Bool] = None + association_type: Optional[Union[str, OntologyClassId]] = None + qualifiers: List[Union[str, OntologyClassId]] = empty_list() + publications: List[Union[str, PublicationId]] = empty_list() + provided_by: Optional[Union[str, ProviderId]] = None + association_slot: Optional[str] = None + has_confidence_level: Optional[Union[str, ConfidenceLevelId]] = None + has_evidence: Optional[Union[str, EvidenceTypeId]] = None + clinical_modifier_qualifier: Optional[Union[str, ClinicalModifierId]] = None + + # === functional association === + subject: Union[str, MacromolecularMachineId] = None + + # === macromolecular machine to cellular component association === + object: Union[str, CellularComponentId] = None + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, MacromolecularMachineToCellularComponentAssociationId): + self.id = MacromolecularMachineToCellularComponentAssociationId(self.id) + if self.object is not None and not isinstance(self.object, CellularComponentId): + self.object = CellularComponentId(self.object) + + +@dataclass +class GeneToGoTermAssociation(FunctionalAssociation): + _inherited_slots: ClassVar[List[str]] = [] + + # === association === + id: Union[str, GeneToGoTermAssociationId] = None + relation: Union[str, IriType] = None + edge_label: Union[str, LabelType] = None + negated: Optional[Bool] = None + association_type: Optional[Union[str, OntologyClassId]] = None + qualifiers: List[Union[str, OntologyClassId]] = empty_list() + publications: List[Union[str, PublicationId]] = empty_list() + provided_by: Optional[Union[str, ProviderId]] = None + association_slot: Optional[str] = None + has_confidence_level: Optional[Union[str, ConfidenceLevelId]] = None + has_evidence: Optional[Union[str, EvidenceTypeId]] = None + clinical_modifier_qualifier: Optional[Union[str, ClinicalModifierId]] = None + + # === functional association === + + # === gene to go term association === + subject: Union[str, MolecularEntityId] = None + object: Union[str, GeneOntologyClassId] = None + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, GeneToGoTermAssociationId): + self.id = GeneToGoTermAssociationId(self.id) + if self.subject is not None and not isinstance(self.subject, MolecularEntityId): + self.subject = MolecularEntityId(self.subject) + if self.object is not None and not isinstance(self.object, GeneOntologyClassId): + self.object = GeneOntologyClassId(self.object) + + +@dataclass +class GenomicSequenceLocalization(Association): + """ + A relationship between a sequence feature and an entity it is localized to. The reference entity may be a + chromosome, chromosome region or information entity such as a contig + """ + _inherited_slots: ClassVar[List[str]] = [] + + # === association === + id: Union[str, GenomicSequenceLocalizationId] = None + relation: Union[str, IriType] = None + edge_label: Union[str, LabelType] = None + negated: Optional[Bool] = None + association_type: Optional[Union[str, OntologyClassId]] = None + qualifiers: List[Union[str, OntologyClassId]] = empty_list() + publications: List[Union[str, PublicationId]] = empty_list() + provided_by: Optional[Union[str, ProviderId]] = None + association_slot: Optional[str] = None + has_confidence_level: Optional[Union[str, ConfidenceLevelId]] = None + has_evidence: Optional[Union[str, EvidenceTypeId]] = None + clinical_modifier_qualifier: Optional[Union[str, ClinicalModifierId]] = None + + # === genomic sequence localization === + subject: Union[str, GenomicEntityId] = None + object: Union[str, GenomicEntityId] = None + start_interbase_coordinate: Optional[str] = None + end_interbase_coordinate: Optional[str] = None + genome_build: Optional[str] = None + phase: Optional[str] = None + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, GenomicSequenceLocalizationId): + self.id = GenomicSequenceLocalizationId(self.id) + if self.subject is not None and not isinstance(self.subject, GenomicEntityId): + self.subject = GenomicEntityId(self.subject) + if self.object is not None and not isinstance(self.object, GenomicEntityId): + self.object = GenomicEntityId(self.object) + + +@dataclass +class SequenceFeatureRelationship(Association): + """ + For example, a particular exon is part of a particular transcript or gene + """ + _inherited_slots: ClassVar[List[str]] = [] + + # === association === + id: Union[str, SequenceFeatureRelationshipId] = None + relation: Union[str, IriType] = None + edge_label: Union[str, LabelType] = None + negated: Optional[Bool] = None + association_type: Optional[Union[str, OntologyClassId]] = None + qualifiers: List[Union[str, OntologyClassId]] = empty_list() + publications: List[Union[str, PublicationId]] = empty_list() + provided_by: Optional[Union[str, ProviderId]] = None + association_slot: Optional[str] = None + has_confidence_level: Optional[Union[str, ConfidenceLevelId]] = None + has_evidence: Optional[Union[str, EvidenceTypeId]] = None + clinical_modifier_qualifier: Optional[Union[str, ClinicalModifierId]] = None + + # === sequence feature relationship === + subject: Union[str, GenomicEntityId] = None + object: Union[str, GenomicEntityId] = None + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, SequenceFeatureRelationshipId): + self.id = SequenceFeatureRelationshipId(self.id) + if self.subject is not None and not isinstance(self.subject, GenomicEntityId): + self.subject = GenomicEntityId(self.subject) + if self.object is not None and not isinstance(self.object, GenomicEntityId): + self.object = GenomicEntityId(self.object) + + +@dataclass +class TranscriptToGeneRelationship(SequenceFeatureRelationship): + """ + A gene is a collection of transcripts + """ + _inherited_slots: ClassVar[List[str]] = [] + + # === association === + id: Union[str, TranscriptToGeneRelationshipId] = None + relation: Union[str, IriType] = None + edge_label: Union[str, LabelType] = None + negated: Optional[Bool] = None + association_type: Optional[Union[str, OntologyClassId]] = None + qualifiers: List[Union[str, OntologyClassId]] = empty_list() + publications: List[Union[str, PublicationId]] = empty_list() + provided_by: Optional[Union[str, ProviderId]] = None + association_slot: Optional[str] = None + has_confidence_level: Optional[Union[str, ConfidenceLevelId]] = None + has_evidence: Optional[Union[str, EvidenceTypeId]] = None + clinical_modifier_qualifier: Optional[Union[str, ClinicalModifierId]] = None + + # === sequence feature relationship === + + # === transcript to gene relationship === + subject: Union[str, TranscriptId] = None + object: Union[str, GeneId] = None + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, TranscriptToGeneRelationshipId): + self.id = TranscriptToGeneRelationshipId(self.id) + if self.subject is not None and not isinstance(self.subject, TranscriptId): + self.subject = TranscriptId(self.subject) + if self.object is not None and not isinstance(self.object, GeneId): + self.object = GeneId(self.object) + + +@dataclass +class GeneToGeneProductRelationship(SequenceFeatureRelationship): + """ + A gene is transcribed and potentially translated to a gene product + """ + _inherited_slots: ClassVar[List[str]] = [] + + # === association === + id: Union[str, GeneToGeneProductRelationshipId] = None + edge_label: Union[str, LabelType] = None + negated: Optional[Bool] = None + association_type: Optional[Union[str, OntologyClassId]] = None + qualifiers: List[Union[str, OntologyClassId]] = empty_list() + publications: List[Union[str, PublicationId]] = empty_list() + provided_by: Optional[Union[str, ProviderId]] = None + association_slot: Optional[str] = None + has_confidence_level: Optional[Union[str, ConfidenceLevelId]] = None + has_evidence: Optional[Union[str, EvidenceTypeId]] = None + clinical_modifier_qualifier: Optional[Union[str, ClinicalModifierId]] = None + + # === sequence feature relationship === + + # === gene to gene product relationship === + subject: Union[str, GeneId] = None + relation: Union[str, IriType] = None + object: Union[str, GeneProductId] = None + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, GeneToGeneProductRelationshipId): + self.id = GeneToGeneProductRelationshipId(self.id) + if self.subject is not None and not isinstance(self.subject, GeneId): + self.subject = GeneId(self.subject) + if self.relation is not None and not isinstance(self.relation, IriType): + self.relation = IriType(self.relation) + if self.object is not None and not isinstance(self.object, GeneProductId): + self.object = GeneProductId(self.object) + + +@dataclass +class ExonToTranscriptRelationship(SequenceFeatureRelationship): + """ + A transcript is formed from multiple exons + """ + _inherited_slots: ClassVar[List[str]] = [] + + # === association === + id: Union[str, ExonToTranscriptRelationshipId] = None + relation: Union[str, IriType] = None + edge_label: Union[str, LabelType] = None + negated: Optional[Bool] = None + association_type: Optional[Union[str, OntologyClassId]] = None + qualifiers: List[Union[str, OntologyClassId]] = empty_list() + publications: List[Union[str, PublicationId]] = empty_list() + provided_by: Optional[Union[str, ProviderId]] = None + association_slot: Optional[str] = None + has_confidence_level: Optional[Union[str, ConfidenceLevelId]] = None + has_evidence: Optional[Union[str, EvidenceTypeId]] = None + clinical_modifier_qualifier: Optional[Union[str, ClinicalModifierId]] = None + + # === sequence feature relationship === + + # === exon to transcript relationship === + subject: Union[str, ExonId] = None + object: Union[str, TranscriptId] = None + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, ExonToTranscriptRelationshipId): + self.id = ExonToTranscriptRelationshipId(self.id) + if self.subject is not None and not isinstance(self.subject, ExonId): + self.subject = ExonId(self.subject) + if self.object is not None and not isinstance(self.object, TranscriptId): + self.object = TranscriptId(self.object) + + +@dataclass +class GeneRegulatoryRelationship(Association): + """ + A regulatory relationship between two genes + """ + _inherited_slots: ClassVar[List[str]] = [] + + # === association === + id: Union[str, GeneRegulatoryRelationshipId] = None + edge_label: Union[str, LabelType] = None + negated: Optional[Bool] = None + association_type: Optional[Union[str, OntologyClassId]] = None + qualifiers: List[Union[str, OntologyClassId]] = empty_list() + publications: List[Union[str, PublicationId]] = empty_list() + provided_by: Optional[Union[str, ProviderId]] = None + association_slot: Optional[str] = None + has_confidence_level: Optional[Union[str, ConfidenceLevelId]] = None + has_evidence: Optional[Union[str, EvidenceTypeId]] = None + clinical_modifier_qualifier: Optional[Union[str, ClinicalModifierId]] = None + + # === gene regulatory relationship === + subject: Union[str, GeneOrGeneProductId] = None + relation: Union[str, IriType] = None + object: Union[str, GeneOrGeneProductId] = None + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, GeneRegulatoryRelationshipId): + self.id = GeneRegulatoryRelationshipId(self.id) + if self.subject is not None and not isinstance(self.subject, GeneOrGeneProductId): + self.subject = GeneOrGeneProductId(self.subject) + if self.relation is not None and not isinstance(self.relation, IriType): + self.relation = IriType(self.relation) + if self.object is not None and not isinstance(self.object, GeneOrGeneProductId): + self.object = GeneOrGeneProductId(self.object) + + +@dataclass +class AnatomicalEntityToAnatomicalEntityAssociation(Association): + _inherited_slots: ClassVar[List[str]] = [] + + # === association === + id: Union[str, AnatomicalEntityToAnatomicalEntityAssociationId] = None + relation: Union[str, IriType] = None + edge_label: Union[str, LabelType] = None + negated: Optional[Bool] = None + association_type: Optional[Union[str, OntologyClassId]] = None + qualifiers: List[Union[str, OntologyClassId]] = empty_list() + publications: List[Union[str, PublicationId]] = empty_list() + provided_by: Optional[Union[str, ProviderId]] = None + association_slot: Optional[str] = None + has_confidence_level: Optional[Union[str, ConfidenceLevelId]] = None + has_evidence: Optional[Union[str, EvidenceTypeId]] = None + clinical_modifier_qualifier: Optional[Union[str, ClinicalModifierId]] = None + + # === anatomical entity to anatomical entity association === + subject: Union[str, AnatomicalEntityId] = None + object: Union[str, AnatomicalEntityId] = None + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, AnatomicalEntityToAnatomicalEntityAssociationId): + self.id = AnatomicalEntityToAnatomicalEntityAssociationId(self.id) + if self.subject is not None and not isinstance(self.subject, AnatomicalEntityId): + self.subject = AnatomicalEntityId(self.subject) + if self.object is not None and not isinstance(self.object, AnatomicalEntityId): + self.object = AnatomicalEntityId(self.object) + + +@dataclass +class AnatomicalEntityToAnatomicalEntityPartOfAssociation(AnatomicalEntityToAnatomicalEntityAssociation): + """ + A relationship between two anatomical entities where the relationship is mereological, i.e the two entities are + related by parthood. This includes relationships between cellular components and cells, between cells and tissues, + tissues and whole organisms + """ + _inherited_slots: ClassVar[List[str]] = [] + + # === association === + id: Union[str, AnatomicalEntityToAnatomicalEntityPartOfAssociationId] = None + edge_label: Union[str, LabelType] = None + negated: Optional[Bool] = None + association_type: Optional[Union[str, OntologyClassId]] = None + qualifiers: List[Union[str, OntologyClassId]] = empty_list() + publications: List[Union[str, PublicationId]] = empty_list() + provided_by: Optional[Union[str, ProviderId]] = None + association_slot: Optional[str] = None + has_confidence_level: Optional[Union[str, ConfidenceLevelId]] = None + has_evidence: Optional[Union[str, EvidenceTypeId]] = None + clinical_modifier_qualifier: Optional[Union[str, ClinicalModifierId]] = None + + # === anatomical entity to anatomical entity association === + + # === anatomical entity to anatomical entity part of association === + subject: Union[str, AnatomicalEntityId] = None + relation: Union[str, IriType] = None + object: Union[str, AnatomicalEntityId] = None + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, AnatomicalEntityToAnatomicalEntityPartOfAssociationId): + self.id = AnatomicalEntityToAnatomicalEntityPartOfAssociationId(self.id) + if self.subject is not None and not isinstance(self.subject, AnatomicalEntityId): + self.subject = AnatomicalEntityId(self.subject) + if self.relation is not None and not isinstance(self.relation, IriType): + self.relation = IriType(self.relation) + if self.object is not None and not isinstance(self.object, AnatomicalEntityId): + self.object = AnatomicalEntityId(self.object) + + +@dataclass +class AnatomicalEntityToAnatomicalEntityOntogenicAssociation(AnatomicalEntityToAnatomicalEntityAssociation): + """ + A relationship between two anatomical entities where the relationship is ontogenic, i.e the two entities are + related by development. A number of different relationship types can be used to specify the precise nature of the + relationship + """ + _inherited_slots: ClassVar[List[str]] = [] + + # === association === + id: Union[str, AnatomicalEntityToAnatomicalEntityOntogenicAssociationId] = None + edge_label: Union[str, LabelType] = None + negated: Optional[Bool] = None + association_type: Optional[Union[str, OntologyClassId]] = None + qualifiers: List[Union[str, OntologyClassId]] = empty_list() + publications: List[Union[str, PublicationId]] = empty_list() + provided_by: Optional[Union[str, ProviderId]] = None + association_slot: Optional[str] = None + has_confidence_level: Optional[Union[str, ConfidenceLevelId]] = None + has_evidence: Optional[Union[str, EvidenceTypeId]] = None + clinical_modifier_qualifier: Optional[Union[str, ClinicalModifierId]] = None + + # === anatomical entity to anatomical entity association === + + # === anatomical entity to anatomical entity ontogenic association === + subject: Union[str, AnatomicalEntityId] = None + relation: Union[str, IriType] = None + object: Union[str, AnatomicalEntityId] = None + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, AnatomicalEntityToAnatomicalEntityOntogenicAssociationId): + self.id = AnatomicalEntityToAnatomicalEntityOntogenicAssociationId(self.id) + if self.subject is not None and not isinstance(self.subject, AnatomicalEntityId): + self.subject = AnatomicalEntityId(self.subject) + if self.relation is not None and not isinstance(self.relation, IriType): + self.relation = IriType(self.relation) + if self.object is not None and not isinstance(self.object, AnatomicalEntityId): + self.object = AnatomicalEntityId(self.object) + + +@dataclass +class Occurrent(NamedThing): + """ + A processual entity + """ + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "regulates_process_to_process", "has_participant", "has_input", "precedes", "positively_regulates_process_to_process", "negatively_regulates_process_to_process"] + + # === named thing === + id: Union[str, OccurrentId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === occurrent === + regulates_process_to_process: List[Union[str, OccurrentId]] = empty_list() + has_participant: List[Union[str, NamedThingId]] = empty_list() + has_input: List[Union[str, NamedThingId]] = empty_list() + precedes: List[Union[str, OccurrentId]] = empty_list() + positively_regulates_process_to_process: List[Union[str, OccurrentId]] = empty_list() + negatively_regulates_process_to_process: List[Union[str, OccurrentId]] = empty_list() + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, OccurrentId): + self.id = OccurrentId(self.id) + self.regulates_process_to_process = [v if isinstance(v, OccurrentId) + else OccurrentId(v) for v in self.regulates_process_to_process] + self.has_participant = [v if isinstance(v, NamedThingId) + else NamedThingId(v) for v in self.has_participant] + self.has_input = [v if isinstance(v, NamedThingId) + else NamedThingId(v) for v in self.has_input] + self.precedes = [v if isinstance(v, OccurrentId) + else OccurrentId(v) for v in self.precedes] + self.positively_regulates_process_to_process = [v if isinstance(v, OccurrentId) + else OccurrentId(v) for v in self.positively_regulates_process_to_process] + self.negatively_regulates_process_to_process = [v if isinstance(v, OccurrentId) + else OccurrentId(v) for v in self.negatively_regulates_process_to_process] + + +@dataclass +class BiologicalProcessOrActivity(BiologicalEntity): + """ + Either an individual molecular activity, or a collection of causally connected molecular activities + """ + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "has_phenotype"] + + # === named thing === + id: Union[str, BiologicalProcessOrActivityId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === biological entity === + has_phenotype: List[Union[str, PhenotypicFeatureId]] = empty_list() + + # === biological process or activity === + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, BiologicalProcessOrActivityId): + self.id = BiologicalProcessOrActivityId(self.id) + + +@dataclass +class MolecularActivity(BiologicalProcessOrActivity): + """ + An execution of a molecular function carried out by a gene product or macromolecular complex. + """ + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "has_phenotype", "regulates_process_to_process", "has_participant", "has_input", "precedes"] + + # === named thing === + id: Union[str, MolecularActivityId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === biological entity === + has_phenotype: List[Union[str, PhenotypicFeatureId]] = empty_list() + + # === biological process or activity === + + # === molecular activity === + regulates_process_to_process: List[Union[str, OccurrentId]] = empty_list() + has_participant: List[Union[str, NamedThingId]] = empty_list() + has_input: List[Union[str, NamedThingId]] = empty_list() + precedes: List[Union[str, OccurrentId]] = empty_list() + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, MolecularActivityId): + self.id = MolecularActivityId(self.id) + self.regulates_process_to_process = [v if isinstance(v, OccurrentId) + else OccurrentId(v) for v in self.regulates_process_to_process] + self.has_participant = [v if isinstance(v, NamedThingId) + else NamedThingId(v) for v in self.has_participant] + self.has_input = [v if isinstance(v, NamedThingId) + else NamedThingId(v) for v in self.has_input] + self.precedes = [v if isinstance(v, OccurrentId) + else OccurrentId(v) for v in self.precedes] + + +@dataclass +class ActivityAndBehavior(Occurrent): + """ + Activity or behavior of any independent integral living, organization or mechanical actor in the world + """ + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "regulates_process_to_process", "has_participant", "has_input", "precedes"] + + # === named thing === + id: Union[str, ActivityAndBehaviorId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === occurrent === + regulates_process_to_process: List[Union[str, OccurrentId]] = empty_list() + has_participant: List[Union[str, NamedThingId]] = empty_list() + has_input: List[Union[str, NamedThingId]] = empty_list() + precedes: List[Union[str, OccurrentId]] = empty_list() + positively_regulates_process_to_process: List[Union[str, OccurrentId]] = empty_list() + negatively_regulates_process_to_process: List[Union[str, OccurrentId]] = empty_list() + + # === activity and behavior === + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, ActivityAndBehaviorId): + self.id = ActivityAndBehaviorId(self.id) + + +@dataclass +class Procedure(Occurrent): + """ + A series of actions conducted in a certain order or manner + """ + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "regulates_process_to_process", "has_participant", "has_input", "precedes"] + + # === named thing === + id: Union[str, ProcedureId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === occurrent === + regulates_process_to_process: List[Union[str, OccurrentId]] = empty_list() + has_participant: List[Union[str, NamedThingId]] = empty_list() + has_input: List[Union[str, NamedThingId]] = empty_list() + precedes: List[Union[str, OccurrentId]] = empty_list() + positively_regulates_process_to_process: List[Union[str, OccurrentId]] = empty_list() + negatively_regulates_process_to_process: List[Union[str, OccurrentId]] = empty_list() + + # === procedure === + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, ProcedureId): + self.id = ProcedureId(self.id) + + +@dataclass +class Phenomenon(Occurrent): + """ + a fact or situation that is observed to exist or happen, especially one whose cause or explanation is in question + """ + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "regulates_process_to_process", "has_participant", "has_input", "precedes"] + + # === named thing === + id: Union[str, PhenomenonId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === occurrent === + regulates_process_to_process: List[Union[str, OccurrentId]] = empty_list() + has_participant: List[Union[str, NamedThingId]] = empty_list() + has_input: List[Union[str, NamedThingId]] = empty_list() + precedes: List[Union[str, OccurrentId]] = empty_list() + positively_regulates_process_to_process: List[Union[str, OccurrentId]] = empty_list() + negatively_regulates_process_to_process: List[Union[str, OccurrentId]] = empty_list() + + # === phenomenon === + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, PhenomenonId): + self.id = PhenomenonId(self.id) + + +@dataclass +class BiologicalProcess(BiologicalProcessOrActivity): + """ + One or more causally connected executions of molecular functions + """ + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "has_phenotype", "regulates_process_to_process", "has_participant", "has_input", "precedes"] + + # === named thing === + id: Union[str, BiologicalProcessId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === biological entity === + has_phenotype: List[Union[str, PhenotypicFeatureId]] = empty_list() + + # === biological process or activity === + + # === biological process === + regulates_process_to_process: List[Union[str, OccurrentId]] = empty_list() + has_participant: List[Union[str, NamedThingId]] = empty_list() + has_input: List[Union[str, NamedThingId]] = empty_list() + precedes: List[Union[str, OccurrentId]] = empty_list() + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, BiologicalProcessId): + self.id = BiologicalProcessId(self.id) + self.regulates_process_to_process = [v if isinstance(v, OccurrentId) + else OccurrentId(v) for v in self.regulates_process_to_process] + self.has_participant = [v if isinstance(v, NamedThingId) + else NamedThingId(v) for v in self.has_participant] + self.has_input = [v if isinstance(v, NamedThingId) + else NamedThingId(v) for v in self.has_input] + self.precedes = [v if isinstance(v, OccurrentId) + else OccurrentId(v) for v in self.precedes] + + +@dataclass +class Pathway(BiologicalProcess): + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "has_phenotype", "regulates_process_to_process", "has_participant", "has_input", "precedes"] + + # === named thing === + id: Union[str, PathwayId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === biological entity === + has_phenotype: List[Union[str, PhenotypicFeatureId]] = empty_list() + + # === biological process or activity === + + # === biological process === + regulates_process_to_process: List[Union[str, OccurrentId]] = empty_list() + has_participant: List[Union[str, NamedThingId]] = empty_list() + has_input: List[Union[str, NamedThingId]] = empty_list() + precedes: List[Union[str, OccurrentId]] = empty_list() + + # === pathway === + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, PathwayId): + self.id = PathwayId(self.id) + + +@dataclass +class PhysiologicalProcess(BiologicalProcess): + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "has_phenotype", "regulates_process_to_process", "has_participant", "has_input", "precedes"] + + # === named thing === + id: Union[str, PhysiologicalProcessId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === biological entity === + has_phenotype: List[Union[str, PhenotypicFeatureId]] = empty_list() + + # === biological process or activity === + + # === biological process === + regulates_process_to_process: List[Union[str, OccurrentId]] = empty_list() + has_participant: List[Union[str, NamedThingId]] = empty_list() + has_input: List[Union[str, NamedThingId]] = empty_list() + precedes: List[Union[str, OccurrentId]] = empty_list() + + # === physiological process === + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, PhysiologicalProcessId): + self.id = PhysiologicalProcessId(self.id) + + +@dataclass +class CellularComponent(AnatomicalEntity): + """ + A location in or around a cell + """ + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "has_phenotype", "expresses", "in_taxon"] + + # === named thing === + id: Union[str, CellularComponentId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === biological entity === + has_phenotype: List[Union[str, PhenotypicFeatureId]] = empty_list() + + # === organismal entity === + + # === anatomical entity === + expresses: List[Union[str, GeneOrGeneProductId]] = empty_list() + in_taxon: List[Union[str, OrganismTaxonId]] = empty_list() + + # === cellular component === + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, CellularComponentId): + self.id = CellularComponentId(self.id) + + +@dataclass +class Cell(AnatomicalEntity): + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "has_phenotype", "expresses", "in_taxon"] + + # === named thing === + id: Union[str, CellId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === biological entity === + has_phenotype: List[Union[str, PhenotypicFeatureId]] = empty_list() + + # === organismal entity === + + # === anatomical entity === + expresses: List[Union[str, GeneOrGeneProductId]] = empty_list() + in_taxon: List[Union[str, OrganismTaxonId]] = empty_list() + + # === cell === + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, CellId): + self.id = CellId(self.id) + + +@dataclass +class CellLine(Biosample): + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "has_phenotype", "in_taxon"] + + # === named thing === + id: Union[str, CellLineId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === biological entity === + has_phenotype: List[Union[str, PhenotypicFeatureId]] = empty_list() + + # === organismal entity === + + # === biosample === + in_taxon: List[Union[str, OrganismTaxonId]] = empty_list() + + # === cell line === + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, CellLineId): + self.id = CellLineId(self.id) + + +@dataclass +class GrossAnatomicalStructure(AnatomicalEntity): + _inherited_slots: ClassVar[List[str]] = ["related_to", "interacts_with", "has_phenotype", "expresses", "in_taxon"] + + # === named thing === + id: Union[str, GrossAnatomicalStructureId] = None + name: Union[str, LabelType] = None + category: List[Union[str, IriType]] = empty_list() + related_to: List[Union[str, NamedThingId]] = empty_list() + interacts_with: List[Union[str, NamedThingId]] = empty_list() + node_property: Optional[str] = None + iri: Optional[Union[str, IriType]] = None + synonym: List[Union[str, LabelType]] = empty_list() + full_name: Optional[Union[str, LabelType]] = None + description: Optional[Union[str, NarrativeText]] = None + systematic_synonym: Optional[Union[str, LabelType]] = None + physically_interacts_with: List[Union[str, NamedThingId]] = empty_list() + affects: List[Union[str, NamedThingId]] = empty_list() + regulates: List[Union[str, NamedThingId]] = empty_list() + positively_regulates: List[Union[str, NamedThingId]] = empty_list() + negatively_regulates: List[Union[str, NamedThingId]] = empty_list() + disrupts: List[Union[str, NamedThingId]] = empty_list() + homologous_to: List[Union[str, NamedThingId]] = empty_list() + paralogous_to: List[Union[str, NamedThingId]] = empty_list() + orthologous_to: List[Union[str, NamedThingId]] = empty_list() + xenologous_to: List[Union[str, NamedThingId]] = empty_list() + coexists_with: List[Union[str, NamedThingId]] = empty_list() + colocalizes_with: List[Union[str, NamedThingId]] = empty_list() + affects_risk_for: List[Union[str, NamedThingId]] = empty_list() + predisposes: List[Union[str, NamedThingId]] = empty_list() + contributes_to: List[Union[str, NamedThingId]] = empty_list() + causes: List[Union[str, NamedThingId]] = empty_list() + prevents: List[Union[str, NamedThingId]] = empty_list() + occurs_in: List[Union[str, NamedThingId]] = empty_list() + located_in: List[Union[str, NamedThingId]] = empty_list() + location_of: List[Union[str, NamedThingId]] = empty_list() + model_of: List[Union[str, NamedThingId]] = empty_list() + overlaps: List[Union[str, NamedThingId]] = empty_list() + has_part: List[Union[str, NamedThingId]] = empty_list() + part_of: List[Union[str, NamedThingId]] = empty_list() + participates_in: List[Union[str, OccurrentId]] = empty_list() + actively_involved_in: List[Union[str, OccurrentId]] = empty_list() + capable_of: List[Union[str, OccurrentId]] = empty_list() + derives_into: List[Union[str, NamedThingId]] = empty_list() + derives_from: List[Union[str, NamedThingId]] = empty_list() + manifestation_of: List[Union[str, DiseaseId]] = empty_list() + produces: List[Union[str, NamedThingId]] = empty_list() + same_as: List[Union[str, NamedThingId]] = empty_list() + creation_date: Optional[Union[str, XSDDate]] = None + update_date: Optional[Union[str, XSDDate]] = None + has_chemical_formula: Optional[str] = None + aggregate_statistic: Optional[str] = None + has_molecular_consequence: List[Union[str, OntologyClassId]] = empty_list() + filler: Optional[Union[str, NamedThingId]] = None + interbase_coordinate: Optional[str] = None + + # === biological entity === + has_phenotype: List[Union[str, PhenotypicFeatureId]] = empty_list() + + # === organismal entity === + + # === anatomical entity === + expresses: List[Union[str, GeneOrGeneProductId]] = empty_list() + in_taxon: List[Union[str, OrganismTaxonId]] = empty_list() + + # === gross anatomical structure === + + def _fix_elements(self): + super()._fix_elements() + if self.id is not None and not isinstance(self.id, GrossAnatomicalStructureId): + self.id = GrossAnatomicalStructureId(self.id) + diff --git a/tests/test_biolink_model.py b/tests/test_biolink_model.py index 05ccb87188..46068538f4 100644 --- a/tests/test_biolink_model.py +++ b/tests/test_biolink_model.py @@ -1,4 +1,3 @@ -import sys import unittest from biolinkml.utils.schemaloader import SchemaLoader