-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #98 from TheJacksonLaboratory/G3-462-add-general-s…
…earch-functions-for-geneset-search G3 462 add general search functions for geneset search
- Loading branch information
Showing
9 changed files
with
403 additions
and
308 deletions.
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
"""Schema for search API.""" | ||
|
||
from datetime import date | ||
from typing import Optional, Set | ||
|
||
from geneweaver.core.enum import GenesetTier, ScoreType, Species | ||
from pydantic import BaseModel, Field | ||
|
||
|
||
class GenesetSearch(BaseModel): | ||
"""Schema for geneset search.""" | ||
|
||
search_text: str | ||
publication_id: Optional[int] = None | ||
pubmed_id: Optional[int] = None | ||
species: Optional[Set[Species]] = None | ||
curation_tier: Optional[Set[GenesetTier]] = None | ||
score_type: Optional[Set[ScoreType]] = None | ||
lte_count: Optional[int] = None | ||
gte_count: Optional[int] = None | ||
created_before: Optional[date] = None | ||
created_after: Optional[date] = None | ||
updated_before: Optional[date] = None | ||
updated_after: Optional[date] = None | ||
limit: Optional[int] = Field(25, ge=0, le=1000) | ||
offset: Optional[int] = None |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters