Skip to content

Commit

Permalink
add maturity label feature
Browse files Browse the repository at this point in the history
  • Loading branch information
ahwagner committed Oct 23, 2024
1 parent fe29951 commit 8711806
Show file tree
Hide file tree
Showing 15 changed files with 98 additions and 0 deletions.
14 changes: 14 additions & 0 deletions src/ga4gh/gks/metaschema/scripts/y2t.py
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,20 @@ def get_ancestor_with_attributes(class_name, proc):
def main(proc_schema):
for class_name, class_definition in proc_schema.defs.items():
with open(proc_schema.def_fp / (class_name + '.rst'), "w") as f:
maturity = class_definition.get('maturity', '')
if maturity == 'draft':
print("""
.. warning:: This data class is at a **draft** maturity level and may change
significantly in future releases. Maturity levels are described in
the :ref:`maturity-model`.
""", file=f)
elif maturity == 'trial use':
print("""
.. note:: This data class is at a **trial use** maturity level and may change
in future releases. Maturity levels are described in the :ref:`maturity-model`.
""", file=f)
print("**Computational Definition**\n", file=f)
print(class_definition['description'], file=f)
if proc_schema.class_is_passthrough(class_name):
Expand Down
6 changes: 6 additions & 0 deletions tests/data/vrs/def/Adjacency.rst
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@

.. warning:: This data class is at a **draft** maturity level and may change
significantly in future releases. Maturity levels are described in
the :ref:`maturity-model`.


**Computational Definition**

The `Adjacency` class can represent either the termination of a sequence or the adjoining of the end of a sequence with the beginning of an adjacent sequence, potentially with an intervening linker sequence.
Expand Down
6 changes: 6 additions & 0 deletions tests/data/vrs/def/Allele.rst
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@

.. warning:: This data class is at a **draft** maturity level and may change
significantly in future releases. Maturity levels are described in
the :ref:`maturity-model`.


**Computational Definition**

The state of a molecule at a :ref:`Location`.
Expand Down
6 changes: 6 additions & 0 deletions tests/data/vrs/def/CopyNumberChange.rst
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@

.. warning:: This data class is at a **draft** maturity level and may change
significantly in future releases. Maturity levels are described in
the :ref:`maturity-model`.


**Computational Definition**

An assessment of the copy number of a :ref:`Location` or a :ref:`Gene` within a system (e.g. genome, cell, etc.) relative to a baseline ploidy.
Expand Down
6 changes: 6 additions & 0 deletions tests/data/vrs/def/CopyNumberCount.rst
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@

.. warning:: This data class is at a **draft** maturity level and may change
significantly in future releases. Maturity levels are described in
the :ref:`maturity-model`.


**Computational Definition**

The absolute count of discrete copies of a :ref:`Location` or :ref:`Gene`, within a system (e.g. genome, cell, etc.).
Expand Down
6 changes: 6 additions & 0 deletions tests/data/vrs/def/Expression.rst
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@

.. warning:: This data class is at a **draft** maturity level and may change
significantly in future releases. Maturity levels are described in
the :ref:`maturity-model`.


**Computational Definition**

Representation of a variation by a specified nomenclature or syntax for a Variation object. Common examples of expressions for the description of molecular variation include the HGVS and ISCN nomenclatures.
Expand Down
6 changes: 6 additions & 0 deletions tests/data/vrs/def/Haplotype.rst
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@

.. warning:: This data class is at a **draft** maturity level and may change
significantly in future releases. Maturity levels are described in
the :ref:`maturity-model`.


**Computational Definition**

An ordered set of co-occurring :ref:`variants <Variation>` on the same molecule.
Expand Down
6 changes: 6 additions & 0 deletions tests/data/vrs/def/LengthExpression.rst
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@

.. warning:: This data class is at a **draft** maturity level and may change
significantly in future releases. Maturity levels are described in
the :ref:`maturity-model`.


**Computational Definition**

A sequence expressed only by its length.
Expand Down
6 changes: 6 additions & 0 deletions tests/data/vrs/def/LiteralSequenceExpression.rst
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@

.. warning:: This data class is at a **draft** maturity level and may change
significantly in future releases. Maturity levels are described in
the :ref:`maturity-model`.


**Computational Definition**

An explicit expression of a Sequence.
Expand Down
6 changes: 6 additions & 0 deletions tests/data/vrs/def/Range.rst
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@

.. warning:: This data class is at a **draft** maturity level and may change
significantly in future releases. Maturity levels are described in
the :ref:`maturity-model`.


**Computational Definition**

An inclusive range of values bounded by one or more integers.
6 changes: 6 additions & 0 deletions tests/data/vrs/def/ReferenceLengthExpression.rst
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@

.. warning:: This data class is at a **draft** maturity level and may change
significantly in future releases. Maturity levels are described in
the :ref:`maturity-model`.


**Computational Definition**

An expression of a length of a sequence from a repeating reference.
Expand Down
6 changes: 6 additions & 0 deletions tests/data/vrs/def/Residue.rst
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@

.. warning:: This data class is at a **draft** maturity level and may change
significantly in future releases. Maturity levels are described in
the :ref:`maturity-model`.


**Computational Definition**

A character representing a specific residue (i.e., molecular species) or groupings of these ("ambiguity codes"), using `one-letter IUPAC abbreviations <https://en.wikipedia.org/wiki/International_Union_of_Pure_and_Applied_Chemistry#Amino_acid_and_nucleotide_base_codes>`_ for nucleic acids and amino acids.
6 changes: 6 additions & 0 deletions tests/data/vrs/def/SequenceLocation.rst
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@

.. warning:: This data class is at a **draft** maturity level and may change
significantly in future releases. Maturity levels are described in
the :ref:`maturity-model`.


**Computational Definition**

A :ref:`Location` defined by an interval on a referenced :ref:`Sequence`.
Expand Down
6 changes: 6 additions & 0 deletions tests/data/vrs/def/SequenceReference.rst
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@

.. warning:: This data class is at a **draft** maturity level and may change
significantly in future releases. Maturity levels are described in
the :ref:`maturity-model`.


**Computational Definition**

A sequence of nucleic or amino acid character codes.
Expand Down
6 changes: 6 additions & 0 deletions tests/data/vrs/def/SequenceString.rst
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@

.. warning:: This data class is at a **draft** maturity level and may change
significantly in future releases. Maturity levels are described in
the :ref:`maturity-model`.


**Computational Definition**

A character string of :ref:`Residues <Residue>` that represents a biological sequence using the conventional sequence order (5’-to-3’ for nucleic acid sequences, and amino-to-carboxyl for amino acid sequences). IUPAC ambiguity codes are permitted in Sequence Strings.

0 comments on commit 8711806

Please sign in to comment.