Skip to content

Commit

Permalink
feat: update to latest fusor version (#315)
Browse files Browse the repository at this point in the history
  • Loading branch information
jsstevenson authored Aug 15, 2024
1 parent 8c1fc23 commit 94d6d6b
Show file tree
Hide file tree
Showing 3 changed files with 29 additions and 19 deletions.
38 changes: 24 additions & 14 deletions client/src/services/ResponseModels.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,10 @@
*/
export type Evidence = "observed" | "inferred";
/**
* Define possible classes of Regulatory Elements. Options are the possible values
* for /regulatory_class value property in the INSDC controlled vocabulary:
* https://www.insdc.org/controlled-vocabulary-regulatoryclass
* Define possible classes of Regulatory Elements.
*
* Options are the possible values for ``/regulatory_class`` value property in the
* `INSDC controlled vocabulary <https://www.insdc.org/controlled-vocabulary-regulatoryclass>`_.
*/
export type RegulatoryClass =
| "attenuator"
Expand Down Expand Up @@ -113,8 +114,8 @@ export interface AssayedFusion {
/**
* Define RegulatoryElement class.
*
* `featureId` would ideally be constrained as a CURIE, but Encode, our preferred
* feature ID source, doesn't currently have a registered CURIE structure for EH_
* ``featureId`` would ideally be constrained as a CURIE, but Encode, our preferred
* feature ID source, doesn't currently have a registered CURIE structure for ``EH_``
* identifiers. Consequently, we permit any kind of free text.
*/
export interface RegulatoryElement {
Expand Down Expand Up @@ -348,6 +349,7 @@ export interface GeneElement {
}
/**
* Define Templated Sequence Element class.
*
* A templated sequence is a contiguous genomic sequence found in the gene
* product.
*/
Expand Down Expand Up @@ -402,7 +404,9 @@ export interface LiteralSequenceExpression {
[k: string]: unknown;
}
/**
* Define UnknownGene class. This is primarily intended to represent a
* Define UnknownGene class.
*
* This is primarily intended to represent a
* partner in the result of a fusion partner-agnostic assay, which identifies
* the absence of an expected gene. For example, a FISH break-apart probe may
* indicate rearrangement of an MLL gene, but by design, the test cannot
Expand All @@ -414,6 +418,8 @@ export interface UnknownGeneElement {
type?: "UnknownGeneElement";
}
/**
* Define causative event information for a fusion.
*
* The evaluation of a fusion may be influenced by the underlying mechanism that
* generated the fusion. Often this will be a DNA rearrangement, but it could also be
* a read-through or trans-splicing event.
Expand Down Expand Up @@ -461,7 +467,9 @@ export interface CategoricalFusion {
criticalFunctionalDomains?: FunctionalDomain[] | null;
}
/**
* Define MultiplePossibleGenesElement class. This is primarily intended to
* Define MultiplePossibleGenesElement class.
*
* This is primarily intended to
* represent a partner in a categorical fusion, typifying generalizable
* characteristics of a class of fusions such as retained or lost regulatory elements
* and/or functional domains, often curated from biomedical literature for use in
Expand Down Expand Up @@ -672,12 +680,13 @@ export interface ExonCoordsRequest {
*/
export interface FormattedAssayedFusion {
fusion_type?: AssayedFusion & string;
structure:
structure: (
| TranscriptSegmentElement
| GeneElement
| TemplatedSequenceElement
| LinkerElement
| UnknownGeneElement;
| UnknownGeneElement
)[];
causative_event?: CausativeEvent | null;
assay?: Assay | null;
regulatory_element?: RegulatoryElement | null;
Expand All @@ -690,12 +699,13 @@ export interface FormattedAssayedFusion {
*/
export interface FormattedCategoricalFusion {
fusion_type?: CategoricalFusion & string;
structure:
structure: (
| TranscriptSegmentElement
| GeneElement
| TemplatedSequenceElement
| LinkerElement
| MultiplePossibleGenesElement;
| MultiplePossibleGenesElement
)[];
regulatory_element?: RegulatoryElement | null;
critical_functional_domains?: FunctionalDomain[] | null;
reading_frame_preserved?: boolean | null;
Expand Down Expand Up @@ -776,9 +786,9 @@ export interface Response {
export interface SequenceIDResponse {
warnings?: string[] | null;
sequence: string;
refseq_id: string | null;
ga4gh_id: string | null;
aliases: string[] | null;
refseq_id?: string | null;
ga4gh_id?: string | null;
aliases?: string[] | null;
}
/**
* Response model for service_info endpoint.
Expand Down
2 changes: 1 addition & 1 deletion server/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ dependencies = [
"click",
"boto3",
"botocore",
"fusor ~= 0.2.0",
"fusor ~= 0.3.0",
"cool-seq-tool ~= 0.5.1",
"pydantic == 2.4.2",
"gene-normalizer ~= 0.4.0",
Expand Down
8 changes: 4 additions & 4 deletions server/src/curfu/schemas.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@
from fusor.models import (
Assay,
AssayedFusion,
AssayedFusionElements,
AssayedFusionElement,
CategoricalFusion,
CategoricalFusionElements,
CategoricalFusionElement,
CausativeEvent,
FunctionalDomain,
Fusion,
Expand Down Expand Up @@ -301,7 +301,7 @@ class FormattedAssayedFusion(BaseModel):
"""

fusion_type: FusionType.ASSAYED_FUSION = FusionType.ASSAYED_FUSION
structure: AssayedFusionElements
structure: list[AssayedFusionElement]
causative_event: CausativeEvent | None = None
assay: Assay | None = None
regulatory_element: RegulatoryElement | None = None
Expand All @@ -315,7 +315,7 @@ class FormattedCategoricalFusion(BaseModel):
"""

fusion_type: FusionType.CATEGORICAL_FUSION = FusionType.CATEGORICAL_FUSION
structure: CategoricalFusionElements
structure: list[CategoricalFusionElement]
regulatory_element: RegulatoryElement | None = None
critical_functional_domains: list[FunctionalDomain] | None = None
reading_frame_preserved: bool | None = None
Expand Down

0 comments on commit 94d6d6b

Please sign in to comment.