name: tooluniverse-precision-medicine-stratification
description: Comprehensive patient stratification for precision medicine by integrating genomic, clinical, and therapeutic data. Given a disease/condition, genomic data (germline variants, somatic mutations, expression), and optional clinical parameters, performs multi-phase analysis across 9 phases covering disease disambiguation, genetic risk assessment, disease-specific molecular stratification, pharmacogenomic profiling, comorbidity/DDI risk, pathway analysis, clinical evidence and guideline mapping, clinical trial matching, and integrated outcome prediction. Generates a quantitative Precision Medicine Risk Score (0-100) with risk tier assignment (Low/Intermediate/High/Very High), treatment algorithm (1st/2nd/3rd line), pharmacogenomic guidance, clinical trial matches, and monitoring plan. Use when clinicians ask about patient risk stratification, treatment selection, prognosis prediction, or personalized therapeutic strategy across cancer, metabolic, cardiovascular, neurological, or rare diseases.
Precision Medicine Patient Stratification
Transform patient genomic and clinical profiles into actionable risk stratification, treatment recommendations, and personalized therapeutic strategies. Integrates germline genetics, somatic alterations, pharmacogenomics, pathway biology, and clinical evidence to produce a quantitative risk score with tiered management recommendations.
KEY PRINCIPLES:
- Report-first approach - Create report file FIRST, then populate progressively
- Disease-specific logic - Cancer vs metabolic vs rare disease pipelines diverge at Phase 2
- Multi-level integration - Germline + somatic + expression + clinical data layers
- Evidence-graded - Every finding has an evidence tier (T1-T4)
- Quantitative output - Precision Medicine Risk Score (0-100) with transparent components
- Pharmacogenomic guidance - Drug selection AND dosing recommendations
- Guideline-concordant - Reference NCCN, ACC/AHA, ADA, and other guidelines
- Source-referenced - Every statement cites the tool/database source
- Completeness checklist - Mandatory section showing data availability and analysis coverage
- English-first queries - Always use English terms in tool calls. Respond in user's language
When to Use
Apply when user asks:
- "Stratify this breast cancer patient: ER+/HER2-, BRCA1 mutation, stage II"
- "What is the risk profile for this diabetes patient with HbA1c 8.5 and CYP2C19 poor metabolizer?"
- "NSCLC patient with EGFR L858R, stage IV, TMB 25 - treatment strategy?"
- "Predict prognosis and recommend treatment for this cardiovascular patient"
- "Patient has Marfan syndrome with FBN1 mutation - risk stratification"
- "Alzheimer's risk assessment: APOE e4/e4, family history positive"
- "Personalized treatment plan for type 2 diabetes with genetic risk factors"
- "Which therapy is best for this patient's molecular profile?"
NOT for (use other skills instead):
- Single variant interpretation -> Use
tooluniverse-variant-interpretation or tooluniverse-cancer-variant-interpretation
- Immunotherapy-specific prediction -> Use
tooluniverse-immunotherapy-response-prediction
- Drug safety profiling only -> Use
tooluniverse-adverse-event-detection
- Target validation -> Use
tooluniverse-drug-target-validation
- Clinical trial search only -> Use
tooluniverse-clinical-trial-matching
- Drug-drug interaction analysis only -> Use
tooluniverse-drug-drug-interaction
- PRS calculation only -> Use
tooluniverse-polygenic-risk-score
Input Parsing
Required Input
- Disease/condition: Free-text disease name (e.g., "breast cancer", "type 2 diabetes", "Marfan syndrome")
- At least one of: Germline variants, somatic mutations, gene list, or clinical biomarkers
Strongly Recommended
- Genomic data: Specific variants (e.g., "BRCA1 c.68_69delAG", "EGFR L858R"), gene names, or expression changes
- Clinical parameters: Age, sex, disease stage, biomarkers (HbA1c, PSA, LDL-C)
Optional (improves stratification)
- Comorbidities: Other conditions (e.g., "hypertension", "diabetes")
- Prior treatments: Previous therapies and responses
- Family history: Affected relatives, inheritance pattern
- Ethnicity: For population-specific risk calibration
- Current medications: For DDI and pharmacogenomic analysis
- Stratification goal: Risk assessment, treatment selection, prognosis, prevention
Input Format Examples
| Format |
Example |
How to Parse |
| Cancer + mutations + stage |
"Breast cancer, BRCA1 mut, ER+, HER2-, stage II" |
disease=breast_cancer, mutations=[BRCA1], biomarkers={ER:+, HER2:-}, stage=II |
| Metabolic + biomarkers + PGx |
"T2D, HbA1c 8.5, CYP2C19 *2/*2" |
disease=T2D, biomarkers={HbA1c:8.5}, pgx={CYP2C19:poor_metabolizer} |
| CVD risk profile |
"High LDL 190, SLCO1B1*5, family hx MI" |
disease=CVD, biomarkers={LDL:190}, pgx={SLCO1B1:*5}, family_hx=positive |
| Rare disease + variant |
"Marfan, FBN1 c.4082G>A" |
disease=Marfan, mutations=[FBN1 c.4082G>A], disease_type=rare |
| Neuro risk |
"Alzheimer risk, APOE e4/e4, age 55" |
disease=AD, genotype={APOE:e4/e4}, clinical={age:55} |
| Cancer + comprehensive |
"NSCLC, EGFR L858R, TMB 25, PD-L1 80%, stage IV" |
disease=NSCLC, mutations=[EGFR L858R], biomarkers={TMB:25, PDL1:80}, stage=IV |
Disease Type Classification
Classify the disease into one of these categories (determines Phase 2 routing):
| Category |
Examples |
Key Stratification Axes |
| CANCER |
Breast, lung, colorectal, melanoma, prostate |
Stage, molecular subtype, TMB, driver mutations, hormone receptors |
| METABOLIC |
Type 2 diabetes, obesity, metabolic syndrome, NAFLD |
HbA1c, BMI, genetic risk, comorbidities, CYP genotypes |
| CARDIOVASCULAR |
CAD, heart failure, atrial fibrillation, hypertension |
ASCVD risk, LDL, genetic risk, statin PGx, anticoagulant PGx |
| NEUROLOGICAL |
Alzheimer, Parkinson, epilepsy, multiple sclerosis |
APOE status, genetic risk, age of onset, PGx for anticonvulsants |
| RARE/MONOGENIC |
Marfan, CF, sickle cell, Huntington, PKU |
Causal variant, penetrance, genotype-phenotype correlation |
| AUTOIMMUNE |
RA, lupus, MS, Crohn's, ulcerative colitis |
HLA associations, genetic risk, biologics PGx |
Gene Symbol Normalization
| Common Alias |
Official Symbol |
Notes |
| HER2 |
ERBB2 |
Breast cancer biomarker |
| PD-L1 |
CD274 |
Immunotherapy biomarker |
| EGFR |
EGFR |
Lung cancer driver |
| BRCA1/2 |
BRCA1, BRCA2 |
Hereditary cancer |
| CYP2D6 |
CYP2D6 |
Drug metabolism |
| CYP2C19 |
CYP2C19 |
Clopidogrel, PPIs |
| CYP3A4 |
CYP3A4 |
Major drug metabolism |
| VKORC1 |
VKORC1 |
Warfarin dosing |
| SLCO1B1 |
SLCO1B1 |
Statin myopathy |
| DPYD |
DPYD |
Fluoropyrimidine toxicity |
| UGT1A1 |
UGT1A1 |
Irinotecan toxicity |
| TPMT |
TPMT |
Thiopurine toxicity |
Phase 0: Tool Parameter Reference (CRITICAL)
BEFORE calling ANY tool, verify parameters using this reference table.
Verified Tool Parameters
| Tool |
Parameters |
Response Structure |
Notes |
OpenTargets_get_disease_id_description_by_name |
diseaseName |
{data: {search: {hits: [{id, name, description}]}}} |
Disease to EFO ID |
OpenTargets_get_drug_id_description_by_name |
drugName |
{data: {search: {hits: [{id, name, description}]}}} |
Drug to ChEMBL ID |
OpenTargets_get_associated_drugs_by_disease_efoId |
efoId, size |
{data: {disease: {knownDrugs: {count, rows}}}} |
Drugs for disease |
OpenTargets_get_associated_targets_by_disease_efoId |
efoId, size |
{data: {disease: {associatedTargets: {count, rows}}}} |
Genetic associations |
OpenTargets_get_drug_mechanisms_of_action_by_chemblId |
chemblId |
{data: {drug: {mechanismsOfAction: {rows}}}} |
Drug MOA |
OpenTargets_get_approved_indications_by_drug_chemblId |
chemblId |
Approved indications list |
Check drug approvals |
OpenTargets_get_drug_adverse_events_by_chemblId |
chemblId |
{data: {drug: {adverseEvents: {count, rows}}}} |
Drug safety |
OpenTargets_get_associated_drugs_by_target_ensemblID |
ensemblId, size |
Drug-target associations |
Drugs targeting gene |
OpenTargets_get_target_safety_profile_by_ensemblID |
ensemblId |
Safety profile data |
Target safety |
OpenTargets_get_target_tractability_by_ensemblID |
ensemblId |
Tractability assessment |
Druggability |
OpenTargets_get_diseases_phenotypes_by_target_ensembl |
ensemblId |
Disease-phenotype associations |
Gene-disease links |
OpenTargets_target_disease_evidence |
ensemblId, efoId, size |
Evidence for target-disease pair |
Specific gene-disease evidence |
OpenTargets_search_gwas_studies_by_disease |
diseaseIds (array), size |
{data: {studies: {count, rows}}} |
GWAS studies |
OpenTargets_drug_pharmacogenomics_data |
chemblId |
Pharmacogenomic data |
Drug PGx |
MyGene_query_genes |
query (NOT q) |
{hits: [{_id, symbol, name, ensembl: {gene}}]} |
Gene resolution |
ensembl_lookup_gene |
gene_id, species='homo_sapiens' |
{data: {id, display_name, description, biotype}} |
REQUIRES species |
EnsemblVEP_annotate_rsid |
variant_id (NOT rsid) |
VEP annotation with SIFT/PolyPhen |
Variant impact |
EnsemblVEP_annotate_hgvs |
hgvs_notation, species |
VEP annotation |
HGVS variant annotation |
ensembl_get_variation |
variant_id, species |
Variant details |
rsID lookup |
clinvar_search_variants |
gene, significance, limit |
Variant list |
Search ClinVar |
clinvar_get_variant_details |
variant_id |
Variant details with clinical significance |
ClinVar details |
clinvar_get_clinical_significance |
variant_id |
Clinical significance only |
Quick pathogenicity |
civic_search_evidence_items |
therapy_name, disease_name |
{data: {evidenceItems: {nodes}}} |
Clinical evidence |
civic_search_variants |
name, gene_name |
{data: {variants: {nodes}}} |
Variant clinical significance |
civic_search_assertions |
therapy_name, disease_name |
{data: {assertions: {nodes}}} |
Clinical assertions |
cBioPortal_get_mutations |
study_id, gene_list (STRING, not array) |
{status, data: [{...}]} |
Somatic mutation data |
gwas_get_associations_for_trait |
trait |
GWAS associations |
Trait-SNP associations |
gwas_search_associations |
query |
GWAS associations |
Broad GWAS search |
gwas_get_snps_for_gene |
gene |
SNPs associated with gene |
Gene GWAS hits |
GWAS_search_associations_by_gene |
gene_name |
Gene GWAS associations |
Gene-trait links |
PharmGKB_get_clinical_annotations |
query |
Clinical annotations |
Drug-gene-phenotype |
PharmGKB_get_dosing_guidelines |
query |
Dosing guidelines |
PGx dosing |
PharmGKB_search_variants |
query |
Variant PGx data |
PGx variant search |
PharmGKB_get_gene_details |
query |
Gene PGx details |
PGx gene info |
PharmGKB_get_drug_details |
query |
Drug PGx details |
Drug PGx info |
fda_pharmacogenomic_biomarkers |
drug_name, biomarker, limit |
{count, shown, results: [{Drug, Biomarker, ...}]} |
FDA PGx biomarkers |
FDA_get_pharmacogenomics_info_by_drug_name |
drug_name, limit |
{meta, results} |
FDA PGx label info |
FDA_get_indications_by_drug_name |
drug_name, limit |
{meta, results} |
FDA indications |
FDA_get_clinical_studies_info_by_drug_name |
drug_name, limit |
{meta, results} |
Clinical study data |
FDA_get_contraindications_by_drug_name |
drug_name, limit |
{meta, results} |
Contraindications |
FDA_get_warnings_by_drug_name |
drug_name, limit |
{meta, results} |
Warnings |
FDA_get_boxed_warning_info_by_drug_name |
drug_name, limit |
May return NOT_FOUND |
Boxed warnings |
FDA_get_drug_interactions_by_drug_name |
drug_name, limit |
{meta, results} |
DDI info |
drugbank_get_drug_basic_info_by_drug_name_or_id |
query, case_sensitive, exact_match, limit |
Drug basic info |
ALL 4 REQUIRED |
drugbank_get_targets_by_drug_name_or_drugbank_id |
query, case_sensitive, exact_match, limit |
Drug targets |
ALL 4 REQUIRED |
drugbank_get_pharmacology_by_drug_name_or_drugbank_id |
query, case_sensitive, exact_match, limit |
Pharmacology |
ALL 4 REQUIRED |
drugbank_get_indications_by_drug_name_or_drugbank_id |
query, case_sensitive, exact_match, limit |
Indications |
ALL 4 REQUIRED |
drugbank_get_drug_interactions_by_drug_name_or_id |
query, case_sensitive, exact_match, limit |
DDI data |
ALL 4 REQUIRED |
drugbank_get_safety_by_drug_name_or_drugbank_id |
query, case_sensitive, exact_match, limit |
Safety data |
ALL 4 REQUIRED |
enrichr_gene_enrichment_analysis |
gene_list (array), libs (array, REQUIRED) |
Enrichment results |
Key libs: KEGG_2021_Human, Reactome_2022, GO_Biological_Process_2023 |
ReactomeAnalysis_pathway_enrichment |
identifiers (space-separated string) |
{data: {pathways: [{pathway_id, name, p_value, ...}]}} |
Pathway enrichment |
Reactome_map_uniprot_to_pathways |
id (UniProt accession) |
List of pathways |
Gene-to-pathway |
STRING_get_interaction_partners |
protein_ids (array), species (9606), limit |
Interaction partners |
PPI network |
STRING_functional_enrichment |
protein_ids (array), species (9606) |
Functional enrichment |
Network enrichment |
HPA_get_cancer_prognostics_by_gene |
gene_name |
Cancer prognostic data |
Prognostic markers |
HPA_get_rna_expression_by_source |
gene_name, source_type, source_name (ALL 3) |
Expression data |
Tissue expression |
gnomad_get_gene_constraints |
gene_symbol |
Gene constraint metrics |
LoF intolerance |
gnomad_get_variant |
variant_id |
Variant frequency |
Population frequency |
clinical_trials_search |
action='search_studies', condition, intervention, limit |
{total_count, studies} |
Trial search |
search_clinical_trials |
query_term (REQUIRED), condition, intervention, pageSize |
{studies, total_count} |
Alternative trial search |
PubMed_search_articles |
query, max_results |
Plain list of dicts |
Literature |
PubMed_Guidelines_Search |
query, limit (REQUIRED) |
List of guideline articles |
Clinical guidelines (may require API key) |
UniProt_get_function_by_accession |
accession |
List of strings |
Protein function |
UniProt_get_disease_variants_by_accession |
accession |
Disease variants |
Known pathogenic variants |
Response Format Notes
- OpenTargets: Always nested
{data: {entity: {field: ...}}} structure
- FDA label tools: Return
{meta: {disclaimer, terms, license, ...}, results: [...]}. Access via result['results'][0]['field']
- DrugBank: ALL tools require 4 params:
query, case_sensitive (bool), exact_match (bool), limit (int)
- PharmGKB: Returns complex nested objects. Check for
data wrapper
- PubMed_search_articles: Returns a plain list of dicts, NOT
{articles: [...]}
- ClinVar:
clinvar_search_variants returns list of variants with clinical significance
- gnomAD: May return "Service overloaded" - treat as transient, retry or skip
- fda_pharmacogenomic_biomarkers: Default limit=10, use
limit=1000 to get all
- cBioPortal_get_mutations:
gene_list is a STRING, not array. cBioPortal tools may have URL bugs
- ClinVar: May return either a plain list or
{status, data: {esearchresult: {count, idlist}}} - handle both
- EnsemblVEP: May return either a list
[{...}] or {data: {...}, metadata: {...}} - handle both
- PubMed_Guidelines_Search: Requires
limit parameter (NOT max_results), may require API key. Use PubMed_search_articles as fallback
- gwas_get_associations_for_trait: May return errors; use
gwas_search_associations instead
- MyGene CYP2D6: First result may be LOC110740340; always filter by
symbol match
Workflow Overview
Input: Disease + Genomic data + Clinical parameters + Stratification goal
Phase 1: Disease Disambiguation & Profile Standardization
- Resolve disease to EFO/MONDO IDs
- Classify disease type (cancer/metabolic/CVD/neuro/rare/autoimmune)
- Parse genomic data (variants, genes, expression)
- Resolve gene IDs (Ensembl, Entrez, UniProt)
Phase 2: Genetic Risk Assessment
- Germline variant pathogenicity (ClinVar, VEP)
- Gene-disease association strength (OpenTargets)
- GWAS-based polygenic risk estimation
- Population frequency (gnomAD)
- Gene constraint/intolerance (gnomAD)
Phase 3: Disease-Specific Molecular Stratification
CANCER PATH:
- Molecular subtyping (driver mutations, receptor status)
- Prognostic markers (stage + grade + molecular)
- TMB/MSI/HRD assessment
- Somatic mutation landscape (cBioPortal)
METABOLIC PATH:
- Genetic risk + clinical risk integration
- Complication risk (nephropathy, neuropathy, CVD)
- Monogenic subtypes (MODY, lipodystrophy)
CVD PATH:
- ASCVD risk integration
- Familial hypercholesterolemia genes
- Statin/anticoagulant PGx
RARE DISEASE PATH:
- Causal variant identification
- Genotype-phenotype correlation
- Penetrance estimation
Phase 4: Pharmacogenomic Profiling
- Drug-metabolizing enzyme genotypes (CYP2D6, CYP2C19, CYP3A4)
- Drug transporter variants (SLCO1B1, ABCB1)
- Drug target variants (VKORC1, DPYD, UGT1A1)
- HLA alleles (drug hypersensitivity risk)
- PharmGKB clinical annotations
- FDA pharmacogenomic biomarkers
Phase 5: Comorbidity & Drug Interaction Risk
- Disease-disease genetic overlap
- Impact on treatment selection
- Drug-drug interaction risk
- Pharmacogenomic DDI amplification
Phase 6: Molecular Pathway Analysis
- Dysregulated pathway identification (Reactome, KEGG)
- Network disruption analysis (STRING)
- Druggable pathway targets
- Pathway-based therapeutic opportunities
Phase 7: Clinical Evidence & Guidelines
- Guideline-based risk categories (NCCN, ACC/AHA, ADA)
- FDA-approved therapies for patient profile
- Literature evidence (PubMed)
- Biomarker-guided treatment evidence
Phase 8: Clinical Trial Matching
- Trials matching molecular profile
- Biomarker-driven trials
- Precision medicine basket/umbrella trials
- Risk-adapted trials
Phase 9: Integrated Scoring & Recommendations
- Calculate Precision Medicine Risk Score (0-100)
- Risk tier assignment (Low/Int/High/Very High)
- Treatment algorithm (1st/2nd/3rd line)
- Monitoring plan
- Outcome predictions
Phase 1: Disease Disambiguation & Profile Standardization
Step 1.1: Resolve Disease to EFO ID
# Get disease EFO ID
result = tu.tools.OpenTargets_get_disease_id_description_by_name(diseaseName='breast cancer')
# -> {data: {search: {hits: [{id: 'EFO_0000305', name: 'breast carcinoma', description: '...'}]}}}
efo_id = result['data']['search']['hits'][0]['id']
Common Disease EFO IDs (for reference):
| Disease |
EFO ID |
Category |
| Breast carcinoma |
EFO_0000305 |
CANCER |
| Non-small cell lung carcinoma |
EFO_0003060 |
CANCER |
| Colorectal cancer |
EFO_0000365 |
CANCER |
| Melanoma |
EFO_0000756 |
CANCER |
| Prostate carcinoma |
EFO_0001663 |
CANCER |
| Type 2 diabetes |
EFO_0001360 |
METABOLIC |
| Coronary artery disease |
EFO_0001645 |
CVD |
| Atrial fibrillation |
EFO_0000275 |
CVD |
| Alzheimer disease |
MONDO_0004975 |
NEUROLOGICAL |
| Parkinson disease |
EFO_0002508 |
NEUROLOGICAL |
| Rheumatoid arthritis |
EFO_0000685 |
AUTOIMMUNE |
| Marfan syndrome |
Orphanet_558 |
RARE |
| Cystic fibrosis |
EFO_0000508 |
RARE |
Step 1.2: Classify Disease Type
Based on disease name and EFO ID, classify into: CANCER, METABOLIC, CVD, NEUROLOGICAL, RARE, AUTOIMMUNE. This determines the Phase 3 routing.
Step 1.3: Parse Genomic Data
Parse each variant/gene into structured format:
"BRCA1 c.68_69delAG" -> {gene: "BRCA1", variant: "c.68_69delAG", type: "frameshift"}
"EGFR L858R" -> {gene: "EGFR", variant: "L858R", type: "missense"}
"CYP2C19 *2/*2" -> {gene: "CYP2C19", genotype: "*2/*2", metabolizer_status: "poor"}
"APOE e4/e4" -> {gene: "APOE", genotype: "e4/e4", risk_allele: "e4"}
Step 1.4: Resolve Gene IDs
# For each gene in profile
result = tu.tools.MyGene_query_genes(query='BRCA1')
# -> hits[0]: {_id: '672', symbol: 'BRCA1', ensembl: {gene: 'ENSG00000012048'}}
ensembl_id = result['hits'][0]['ensembl']['gene']
entrez_id = result['hits'][0]['_id']
Critical Gene IDs (pre-resolved):
| Gene |
Ensembl ID |
Entrez ID |
Category |
| BRCA1 |
ENSG00000012048 |
672 |
Cancer predisposition |
| BRCA2 |
ENSG00000139618 |
675 |
Cancer predisposition |
| TP53 |
ENSG00000141510 |
7157 |
Tumor suppressor |
| EGFR |
ENSG00000146648 |
1956 |
Cancer driver |
| BRAF |
ENSG00000157764 |
673 |
Cancer driver |
| KRAS |
ENSG00000133703 |
3845 |
Cancer driver |
| CYP2D6 |
ENSG00000100197 |
1565 |
Pharmacogenomics |
| CYP2C19 |
ENSG00000165841 |
1557 |
Pharmacogenomics |
| SLCO1B1 |
ENSG00000134538 |
10599 |
Pharmacogenomics |
| VKORC1 |
ENSG00000167397 |
79001 |
Pharmacogenomics |
| DPYD |
ENSG00000188641 |
1806 |
Pharmacogenomics |
| APOE |
ENSG00000130203 |
348 |
Neurological risk |
| LDLR |
ENSG00000130164 |
3949 |
CVD risk |
| PCSK9 |
ENSG00000169174 |
255738 |
CVD risk |
| FBN1 |
ENSG00000166147 |
2200 |
Marfan syndrome |
| CFTR |
ENSG00000001626 |
1080 |
Cystic fibrosis |
Phase 2: Genetic Risk Assessment
Step 2.1: Germline Variant Pathogenicity
For each germline variant provided:
# Search ClinVar for variant pathogenicity
result = tu.tools.clinvar_search_variants(gene='BRCA1', significance='pathogenic', limit=50)
# Check if patient's specific variant is in ClinVar
# For rsID variants, get VEP annotation
result = tu.tools.EnsemblVEP_annotate_rsid(variant_id='rs80357906')
# Returns SIFT, PolyPhen predictions, consequence type
# For HGVS variants
result = tu.tools.EnsemblVEP_annotate_hgvs(hgvs_notation='ENST00000357654.9:c.5266dupC', species='homo_sapiens')
Pathogenicity Classification (ACMG-aligned):
| Classification |
ClinVar Term |
Risk Score Points |
| Pathogenic |
Pathogenic |
25 (molecular component) |
| Likely pathogenic |
Likely pathogenic |
20 |
| VUS |
Uncertain significance |
10 (conservative) |
| Likely benign |
Likely benign |
2 |
| Benign |
Benign |
0 |
Step 2.2: Gene-Disease Association Strength
# Get genetic evidence for gene-disease pair
result = tu.tools.OpenTargets_target_disease_evidence(
ensemblId='ENSG00000012048', # BRCA1
efoId='EFO_0000305', # breast cancer
size=20
)
# Returns evidence items with scores
Step 2.3: GWAS-Based Polygenic Risk
# Search GWAS associations for disease
result = tu.tools.gwas_get_associations_for_trait(trait='breast cancer')
# Returns associated SNPs with effect sizes
# Search GWAS studies via OpenTargets
result = tu.tools.OpenTargets_search_gwas_studies_by_disease(
diseaseIds=['EFO_0000305'], size=25
)
# For specific genes, check GWAS hits
result = tu.tools.GWAS_search_associations_by_gene(gene_name='BRCA1')
PRS Estimation (from available GWAS data):
| PRS Percentile |
Risk Category |
Score Points (0-35) |
| >95th percentile |
Very high genetic risk |
35 |
| 90-95th |
High genetic risk |
30 |
| 75-90th |
Elevated genetic risk |
25 |
| 50-75th |
Average-high |
18 |
| 25-50th |
Average-low |
12 |
| 10-25th |
Below average |
8 |
| <10th |
Low genetic risk |
5 |
Note: With user-provided variants only (not full genotype), estimate approximate PRS by counting known risk alleles and their effect sizes from GWAS catalog. Flag as "estimated - full genotyping recommended for precise PRS."
Step 2.4: Population Frequency
# Check variant frequency in gnomAD
result = tu.tools.gnomad_get_variant(variant_id='1-55505647-G-T')
# Returns allele frequency across populations
Step 2.5: Gene Constraint
# Gene intolerance to loss of function
result = tu.tools.gnomad_get_gene_constraints(gene_symbol='BRCA1')
# Returns pLI, LOEUF scores - high pLI/low LOEUF = haploinsufficiency
Genetic Risk Score Component (0-35 points):
Combine pathogenicity + gene-disease association + PRS:
- Pathogenic variant in disease gene: 25+ points
- Strong GWAS associations (multiple risk alleles): up to 35 points
- VUS in relevant gene: 10-15 points
- No known pathogenic variants but some risk alleles: 5-15 points
Phase 3: Disease-Specific Molecular Stratification
CANCER PATH (Phase 3C)
Step 3C.1: Molecular Subtyping
# Get somatic mutation landscape from cBioPortal
result = tu.tools.cBioPortal_get_mutations(
study_id='brca_tcga_pub', # breast cancer TCGA
gene_list='BRCA1 BRCA2 TP53 PIK3CA ESR1 ERBB2' # STRING, not array
)
# Returns mutation frequencies, types
# Check cancer prognostic markers
result = tu.tools.HPA_get_cancer_prognostics_by_gene(gene_name='ESR1')
# Returns prognostic data for breast cancer
Cancer-Specific Subtype Definitions:
| Cancer |
Subtype System |
Key Markers |
High-Risk Features |
| Breast |
Luminal A/B, HER2+, TNBC |
ER, PR, HER2, Ki67 |
TNBC, high Ki67, TP53 mut |
| NSCLC |
Adenocarcinoma, squamous |
EGFR, ALK, ROS1, KRAS, PD-L1 |
KRAS G12C, no driver = chemoIO |
| CRC |
MSI-H vs MSS, CMS1-4 |
KRAS, BRAF, MSI, CMS |
BRAF V600E, MSS |
| Melanoma |
BRAF-mut, NRAS-mut, wild-type |
BRAF, NRAS, KIT, NF1 |
NRAS, uveal |
| Prostate |
Luminal vs basal, BRCA status |
AR, BRCA1/2, SPOP, TMPRSS2:ERG |
BRCA2, neuroendocrine |
Step 3C.2: TMB/MSI/HRD Assessment
If TMB provided:
# Check FDA TMB-H approvals
result = tu.tools.fda_pharmacogenomic_biomarkers(drug_name='pembrolizumab', limit=100)
# Look for "Tumor Mutational Burden" in Biomarker field
| Biomarker |
High-Risk Threshold |
Clinical Significance |
| TMB |
>= 10 mut/Mb (FDA cutoff) |
Pembrolizumab eligible (tissue-agnostic) |
| MSI-H |
MSI-high or dMMR |
Pembrolizumab/nivolumab eligible |
| HRD |
HRD-positive |
PARP inhibitor eligible |
Step 3C.3: Prognostic Stratification
Combine stage + molecular features:
| Stage |
Low-Risk Molecular |
High-Risk Molecular |
Score (0-30 clinical) |
| I |
Favorable subtype |
Unfavorable subtype |
5-10 |
| II |
Favorable subtype |
Unfavorable subtype |
10-18 |
| III |
Any |
Any |
18-25 |
| IV |
Any |
Any |
25-30 |
METABOLIC PATH (Phase 3M)
Step 3M.1: Clinical Risk Integration
# Check genetic risk factors for T2D
result = tu.tools.GWAS_search_associations_by_gene(gene_name='TCF7L2')
# TCF7L2 is strongest T2D risk gene
# Check monogenic diabetes genes
result = tu.tools.OpenTargets_target_disease_evidence(
ensemblId='ENSG00000148737', # TCF7L2
efoId='EFO_0001360', # T2D
size=20
)
T2D Stratification:
| Risk Factor |
Low Risk |
Moderate Risk |
High Risk |
Score Points |
| HbA1c |
<6.5% |
6.5-8.0% |
>8.0% |
5-30 |
| Genetic risk |
No risk alleles |
1-3 risk alleles |
MODY gene/many risk alleles |
5-25 |
| Complications |
None |
Microalbuminuria |
Retinopathy, neuropathy |
0-20 |
| Duration |
<5 years |
5-15 years |
>15 years |
0-10 |
CVD PATH (Phase 3V)
# Check PCSK9 and LDLR variants
result = tu.tools.clinvar_search_variants(gene='LDLR', significance='pathogenic', limit=20)
# Familial hypercholesterolemia check
# Check statin-relevant PGx
result = tu.tools.PharmGKB_get_clinical_annotations(query='SLCO1B1')
# SLCO1B1 *5 -> increased statin myopathy risk
CVD Risk Integration:
| Factor |
Score Points |
| LDL >190 mg/dL |
15 |
| FH gene mutation (LDLR/APOB/PCSK9) |
20 |
| ASCVD >20% 10-year risk |
30 |
| Family hx premature CVD |
10 |
| Lipoprotein(a) elevated |
8 |
| Multiple GWAS risk alleles |
5-15 |
RARE DISEASE PATH (Phase 3R)
# Check causal variant in disease gene
result = tu.tools.clinvar_search_variants(gene='FBN1', significance='pathogenic', limit=50)
# Marfan syndrome - FBN1 pathogenic variants
# Genotype-phenotype correlation
result = tu.tools.UniProt_get_disease_variants_by_accession(accession='P35555') # FBN1 UniProt
# Known disease variants and their phenotypes
Rare Disease Risk Assessment:
| Finding |
Risk Level |
Score Points |
| Pathogenic variant in causal gene |
Definitive |
30 |
| Likely pathogenic in causal gene |
Strong |
25 |
| VUS in causal gene |
Moderate |
15 |
| Family history + partial phenotype |
Suggestive |
10 |
| Single phenotype feature only |
Low |
5 |
Phase 4: Pharmacogenomic Profiling
Step 4.1: Drug-Metabolizing Enzyme Genotypes
# PharmGKB clinical annotations for CYP2C19
result = tu.tools.PharmGKB_get_clinical_annotations(query='CYP2C19')
# Returns drug-gene pairs with clinical annotation levels
# FDA pharmacogenomic biomarkers
result = tu.tools.fda_pharmacogenomic_biomarkers(drug_name='clopidogrel', limit=50)
# CYP2C19 poor metabolizer -> reduced clopidogrel efficacy
# PharmGKB dosing guidelines
result = tu.tools.PharmGKB_get_dosing_guidelines(query='CYP2C19')
# CPIC dosing guidelines
Key Pharmacogenes and Clinical Impact:
| Gene |
Star Alleles |
Metabolizer Status |
Clinical Impact |
Score Points |
| CYP2D6 |
*4/*4, *5/*5 |
Poor metabolizer |
Codeine, tamoxifen, many antidepressants |
8 |
| CYP2C19 |
*2/*2, *2/*3 |
Poor metabolizer |
Clopidogrel, voriconazole, PPIs |
8 |
| CYP2C9 |
*2/*3, *3/*3 |
Poor metabolizer |
Warfarin, NSAIDs, phenytoin |
5 |
| SLCO1B1 |
*5/*5 |
Decreased function |
Statin myopathy (simvastatin) |
5 |
| DPYD |
*2A |
DPD deficient |
5-FU/capecitabine severe toxicity |
10 |
| VKORC1 |
-1639G>A |
Warfarin sensitive |
Lower warfarin dose needed |
5 |
| UGT1A1 |
*28/*28 |
Poor glucuronidator |
Irinotecan toxicity |
5 |
| TPMT |
*2, *3A, *3C |
Poor metabolizer |
Thiopurine toxicity |
8 |
| HLA-B*5701 |
Present |
N/A |
Abacavir hypersensitivity |
10 |
| HLA-B*1502 |
Present |
N/A |
Carbamazepine SJS/TEN |
10 |
Step 4.2: Treatment-Specific PGx
# For the specific disease, identify relevant drugs and check PGx
# Example: breast cancer -> tamoxifen -> CYP2D6
result = tu.tools.PharmGKB_get_drug_details(query='tamoxifen')
# Returns PGx annotations for tamoxifen
# Get FDA PGx biomarkers for disease area
result = tu.tools.fda_pharmacogenomic_biomarkers(biomarker='CYP2D6', limit=100)
# All drugs with CYP2D6 PGx in FDA labels
Step 4.3: Drug Target Variants
# Check if patient has variants in drug targets
result = tu.tools.PharmGKB_search_variants(query='VKORC1')
# VKORC1 variants affecting warfarin response
Pharmacogenomic Risk Score (0-10 points):
- Poor metabolizer for treatment-relevant CYP: 8-10 points
- Intermediate metabolizer: 4-5 points
- High-risk HLA allele: 8-10 points
- Drug target variant: 3-5 points
- Normal metabolizer, no actionable PGx: 0 points
Phase 5: Comorbidity & Drug Interaction Risk
Step 5.1: Comorbidity Analysis
# Check disease-disease overlap via shared genetic targets
result = tu.tools.OpenTargets_get_associated_targets_by_disease_efoId(
efoId='EFO_0001360', # T2D
size=50
)
# Compare top targets between primary disease and comorbidities
# Literature on comorbidity
result = tu.tools.PubMed_search_articles(
query='type 2 diabetes cardiovascular comorbidity risk',
max_results=5
)
Step 5.2: Drug-Drug Interaction Risk
# If current medications provided, check DDI
result = tu.tools.drugbank_get_drug_interactions_by_drug_name_or_id(
query='metformin',
case_sensitive=False,
exact_match=False,
limit=20
)
# FDA DDI data
result = tu.tools.FDA_get_drug_interactions_by_drug_name(drug_name='metformin', limit=5)
Step 5.3: PGx-Amplified DDI Risk
If patient is a CYP2D6 poor metabolizer AND taking a CYP2D6 inhibitor -> compounded risk.
| Interaction Type |
Risk Level |
Management |
| PGx PM + CYP inhibitor |
Very high |
Alternative drug or dose reduction |
| PGx IM + CYP inhibitor |
High |
Monitor closely, possible dose reduction |
| PGx normal + CYP inhibitor |
Moderate |
Standard monitoring |
| No interacting drugs |
Low |
Standard care |
Phase 6: Molecular Pathway Analysis
Step 6.1: Dysregulated Pathways
# Pathway enrichment for affected genes
gene_list = ['BRCA1', 'TP53', 'PIK3CA'] # from patient mutations
result = tu.tools.enrichr_gene_enrichment_analysis(
gene_list=gene_list,
libs=['KEGG_2021_Human', 'Reactome_2022']
)
# Returns enriched pathways with p-values
# Reactome pathway analysis
# First get UniProt IDs, then map to pathways
result = tu.tools.Reactome_map_uniprot_to_pathways(id='P38398') # BRCA1 UniProt
# Returns list of pathways involving BRCA1
Step 6.2: Network Analysis
# Protein-protein interaction network
result = tu.tools.STRING_get_interaction_partners(
protein_ids=['BRCA1', 'TP53'],
species=9606,
limit=20
)
# Functional enrichment of network
result = tu.tools.STRING_functional_enrichment(
protein_ids=['BRCA1', 'TP53', 'PALB2', 'RAD51'],
species=9606
)
Step 6.3: Druggable Pathway Targets
# Check tractability of pathway nodes
for gene in pathway_genes:
result = tu.tools.OpenTargets_get_target_tractability_by_ensemblID(ensemblId=ensembl_id)
# Returns small molecule, antibody, PROTAC tractability
Key Druggable Pathways:
| Pathway |
Key Nodes |
Drug Classes |
Cancer Relevance |
| PI3K/AKT/mTOR |
PIK3CA, AKT1, MTOR |
PI3K inhibitors, mTOR inhibitors |
Breast, endometrial |
| RAS/MAPK |
KRAS, BRAF, MEK1/2 |
KRAS G12C inhibitors, BRAF inhibitors |
Lung, CRC, melanoma |
| DNA damage repair |
BRCA1/2, ATM, PALB2 |
PARP inhibitors |
Breast, ovarian, prostate |
| Cell cycle |
CDK4/6, RB1, CCND1 |
CDK4/6 inhibitors |
Breast |
| Immunocheckpoint |
PD-1, PD-L1, CTLA-4 |
ICIs |
Pan-cancer |
| Wnt/beta-catenin |
APC, CTNNB1, TCF |
Wnt inhibitors (investigational) |
CRC |
Phase 7: Clinical Evidence & Guidelines
Step 7.1: Guideline-Based Risk Categories
# Search clinical guidelines in PubMed
result = tu.tools.PubMed_Guidelines_Search(
query='NCCN breast cancer BRCA1 treatment guidelines',
max_results=5
)
# Search general evidence
result = tu.tools.PubMed_search_articles(
query='BRCA1 breast cancer treatment stratification',
max_results=10
)
Guideline References by Disease:
| Disease Category |
Guidelines |
Key Stratification |
| Breast cancer |
NCCN, ASCO, St. Gallen |
Luminal A/B, HER2+, TNBC, BRCA status |
| NSCLC |
NCCN, ESMO |
Driver mutation status, PD-L1, TMB |
| CRC |
NCCN |
MSI, RAS/BRAF, sidedness |
| T2D |
ADA Standards |
HbA1c, CVD risk, CKD stage |
| CVD |
ACC/AHA |
ASCVD risk score, LDL goals, PGx |
| AF |
ACC/AHA/HRS |
CHA2DS2-VASc, anticoagulant selection |
| Rare disease |
ACMG/AMP |
Variant classification, genetic counseling |
Step 7.2: FDA-Approved Therapies
# Get approved drugs for disease
result = tu.tools.OpenTargets_get_associated_drugs_by_disease_efoId(
efoId='EFO_0000305', # breast cancer
size=50
)
# Returns all known drugs with clinical status
# Check specific drug FDA info
result = tu.tools.FDA_get_indications_by_drug_name(drug_name='olaparib', limit=5)
# PARP inhibitor for BRCA-mutated breast cancer
# Get drug mechanism
result = tu.tools.FDA_get_mechanism_of_action_by_drug_name(drug_name='olaparib', limit=5)
Step 7.3: Biomarker-Drug Evidence
# CIViC evidence for biomarker-drug pair
result = tu.tools.civic_search_evidence_items(
therapy_name='olaparib',
disease_name='breast cancer'
)
# Returns clinical evidence items with evidence levels
# DrugBank for drug details
result = tu.tools.drugbank_get_drug_basic_info_by_drug_name_or_id(
query='olaparib',
case_sensitive=False,
exact_match=False,
limit=5
)
Phase 8: Clinical Trial Matching
Step 8.1: Biomarker-Driven Trials
# Search trials matching molecular profile
result = tu.tools.clinical_trials_search(
action='search_studies',
condition='breast cancer',
intervention='PARP inhibitor',
limit=10
)
# Returns {total_count, studies: [{nctId, title, status, conditions}]}
# Alternative search
result = tu.tools.search_clinical_trials(
query_term='BRCA1 breast cancer',
condition='breast cancer',
intervention='olaparib',
pageSize=10
)
Step 8.2: Precision Medicine Trials
# Search basket/umbrella trials
result = tu.tools.search_clinical_trials(
query_term='precision medicine biomarker-driven',
condition='breast cancer',
pageSize=10
)
# Search risk-adapted trials
result = tu.tools.search_clinical_trials(
query_term='high risk BRCA1',
condition='breast cancer',
pageSize=10
)
Step 8.3: Trial Details
# Get details for promising trials
result = tu.tools.clinical_trials_get_details(
action='get_study_details',
nct_id='NCT03344965'
)
# Returns full study protocol
Phase 9: Integrated Scoring & Recommendations
Precision Medicine Risk Score (0-100)
Score Components
Genetic Risk Component (0-35 points):
| Scenario |
Points |
| Pathogenic variant in high-penetrance disease gene (BRCA1, LDLR, FBN1) |
30-35 |
| Multiple moderate-risk variants (GWAS hits + moderate penetrance) |
20-28 |
| High PRS (>90th percentile) with no known pathogenic variants |
25-30 |
| Single moderate-risk variant |
12-18 |
| VUS in relevant gene |
8-12 |
| Average PRS, no pathogenic variants |
5-10 |
| Low genetic risk (low PRS, no risk alleles) |
0-5 |
Clinical Risk Component (0-30 points):
| Disease Type |
Factor |
Low (0-8) |
Moderate (10-20) |
High (22-30) |
| Cancer |
Stage |
I |
II-III |
IV |
| T2D |
HbA1c |
<7% |
7-9% |
>9% |
| CVD |
ASCVD 10-yr |
<10% |
10-20% |
>20% |
| Neuro |
Biomarker status |
No biomarkers |
Mild changes |
Established |
| Rare |
Phenotype match |
Partial |
Moderate |
Full phenotype |
Molecular Features Component (0-25 points):
| Feature |
Points |
| Cancer: High-risk driver mutations (TP53+PIK3CA, KRAS G12C) |
20-25 |
| Cancer: Actionable mutation (EGFR, BRAF V600E) |
15-20 |
| Cancer: High TMB or MSI-H (favorable for ICI) |
10-15 |
| Metabolic: Monogenic form (MODY, FH) |
20-25 |
| Metabolic: Multiple metabolic risk variants |
10-15 |
| CVD: FH gene mutation |
20-25 |
| Rare: Complete genotype-phenotype match |
20-25 |
| VUS requiring further workup |
5-10 |
Pharmacogenomic Risk Component (0-10 points):
| Finding |
Points |
| Poor metabolizer for treatment-critical CYP + high-risk HLA |
10 |
| Poor metabolizer for treatment-critical CYP |
7-8 |
| Intermediate metabolizer for relevant CYP |
4-5 |
| Drug target variant (e.g., VKORC1 for warfarin) |
3-5 |
| No actionable PGx findings |
0-2 |
Risk Tier Assignment
| Total Score | Risk
…(truncated)
1---2name: precision-medicine-stratification3description: ToolUniverse workflow — Precision Medicine Stratification4---56---7name: tooluniverse-precision-medicine-stratification8description: Comprehensive patient stratification for precision medicine by integrating genomic, clinical, and therapeutic data. Given a disease/condition, genomic data (germline variants, somatic mutations, expression), and optional clinical parameters, performs multi-phase analysis across 9 phases covering disease disambiguation, genetic risk assessment, disease-specific molecular stratification, pharmacogenomic profiling, comorbidity/DDI risk, pathway analysis, clinical evidence and guideline mapping, clinical trial matching, and integrated outcome prediction. Generates a quantitative Precision Medicine Risk Score (0-100) with risk tier assignment (Low/Intermediate/High/Very High), treatment algorithm (1st/2nd/3rd line), pharmacogenomic guidance, clinical trial matches, and monitoring plan. Use when clinicians ask about patient risk stratification, treatment selection, prognosis prediction, or personalized therapeutic strategy across cancer, metabolic, cardiovascular, neurological, or rare diseases.9---1011# Precision Medicine Patient Stratification1213Transform patient genomic and clinical profiles into actionable risk stratification, treatment recommendations, and personalized therapeutic strategies. Integrates germline genetics, somatic alterations, pharmacogenomics, pathway biology, and clinical evidence to produce a quantitative risk score with tiered management recommendations.1415**KEY PRINCIPLES**:161. **Report-first approach** - Create report file FIRST, then populate progressively172. **Disease-specific logic** - Cancer vs metabolic vs rare disease pipelines diverge at Phase 2183. **Multi-level integration** - Germline + somatic + expression + clinical data layers194. **Evidence-graded** - Every finding has an evidence tier (T1-T4)205. **Quantitative output** - Precision Medicine Risk Score (0-100) with transparent components216. **Pharmacogenomic guidance** - Drug selection AND dosing recommendations227. **Guideline-concordant** - Reference NCCN, ACC/AHA, ADA, and other guidelines238. **Source-referenced** - Every statement cites the tool/database source249. **Completeness checklist** - Mandatory section showing data availability and analysis coverage2510. **English-first queries** - Always use English terms in tool calls. Respond in user's language2627---2829## When to Use3031Apply when user asks:32- "Stratify this breast cancer patient: ER+/HER2-, BRCA1 mutation, stage II"33- "What is the risk profile for this diabetes patient with HbA1c 8.5 and CYP2C19 poor metabolizer?"34- "NSCLC patient with EGFR L858R, stage IV, TMB 25 - treatment strategy?"35- "Predict prognosis and recommend treatment for this cardiovascular patient"36- "Patient has Marfan syndrome with FBN1 mutation - risk stratification"37- "Alzheimer's risk assessment: APOE e4/e4, family history positive"38- "Personalized treatment plan for type 2 diabetes with genetic risk factors"39- "Which therapy is best for this patient's molecular profile?"4041**NOT for** (use other skills instead):42- Single variant interpretation -> Use `tooluniverse-variant-interpretation` or `tooluniverse-cancer-variant-interpretation`43- Immunotherapy-specific prediction -> Use `tooluniverse-immunotherapy-response-prediction`44- Drug safety profiling only -> Use `tooluniverse-adverse-event-detection`45- Target validation -> Use `tooluniverse-drug-target-validation`46- Clinical trial search only -> Use `tooluniverse-clinical-trial-matching`47- Drug-drug interaction analysis only -> Use `tooluniverse-drug-drug-interaction`48- PRS calculation only -> Use `tooluniverse-polygenic-risk-score`4950---5152## Input Parsing5354### Required Input55- **Disease/condition**: Free-text disease name (e.g., "breast cancer", "type 2 diabetes", "Marfan syndrome")56- **At least one of**: Germline variants, somatic mutations, gene list, or clinical biomarkers5758### Strongly Recommended59- **Genomic data**: Specific variants (e.g., "BRCA1 c.68_69delAG", "EGFR L858R"), gene names, or expression changes60- **Clinical parameters**: Age, sex, disease stage, biomarkers (HbA1c, PSA, LDL-C)6162### Optional (improves stratification)63- **Comorbidities**: Other conditions (e.g., "hypertension", "diabetes")64- **Prior treatments**: Previous therapies and responses65- **Family history**: Affected relatives, inheritance pattern66- **Ethnicity**: For population-specific risk calibration67- **Current medications**: For DDI and pharmacogenomic analysis68- **Stratification goal**: Risk assessment, treatment selection, prognosis, prevention6970### Input Format Examples7172| Format | Example | How to Parse |73|--------|---------|-------------|74| Cancer + mutations + stage | "Breast cancer, BRCA1 mut, ER+, HER2-, stage II" | disease=breast_cancer, mutations=[BRCA1], biomarkers={ER:+, HER2:-}, stage=II |75| Metabolic + biomarkers + PGx | "T2D, HbA1c 8.5, CYP2C19 *2/*2" | disease=T2D, biomarkers={HbA1c:8.5}, pgx={CYP2C19:poor_metabolizer} |76| CVD risk profile | "High LDL 190, SLCO1B1*5, family hx MI" | disease=CVD, biomarkers={LDL:190}, pgx={SLCO1B1:*5}, family_hx=positive |77| Rare disease + variant | "Marfan, FBN1 c.4082G>A" | disease=Marfan, mutations=[FBN1 c.4082G>A], disease_type=rare |78| Neuro risk | "Alzheimer risk, APOE e4/e4, age 55" | disease=AD, genotype={APOE:e4/e4}, clinical={age:55} |79| Cancer + comprehensive | "NSCLC, EGFR L858R, TMB 25, PD-L1 80%, stage IV" | disease=NSCLC, mutations=[EGFR L858R], biomarkers={TMB:25, PDL1:80}, stage=IV |8081### Disease Type Classification8283Classify the disease into one of these categories (determines Phase 2 routing):8485| Category | Examples | Key Stratification Axes |86|----------|----------|------------------------|87| **CANCER** | Breast, lung, colorectal, melanoma, prostate | Stage, molecular subtype, TMB, driver mutations, hormone receptors |88| **METABOLIC** | Type 2 diabetes, obesity, metabolic syndrome, NAFLD | HbA1c, BMI, genetic risk, comorbidities, CYP genotypes |89| **CARDIOVASCULAR** | CAD, heart failure, atrial fibrillation, hypertension | ASCVD risk, LDL, genetic risk, statin PGx, anticoagulant PGx |90| **NEUROLOGICAL** | Alzheimer, Parkinson, epilepsy, multiple sclerosis | APOE status, genetic risk, age of onset, PGx for anticonvulsants |91| **RARE/MONOGENIC** | Marfan, CF, sickle cell, Huntington, PKU | Causal variant, penetrance, genotype-phenotype correlation |92| **AUTOIMMUNE** | RA, lupus, MS, Crohn's, ulcerative colitis | HLA associations, genetic risk, biologics PGx |9394### Gene Symbol Normalization9596| Common Alias | Official Symbol | Notes |97|-------------|----------------|-------|98| HER2 | ERBB2 | Breast cancer biomarker |99| PD-L1 | CD274 | Immunotherapy biomarker |100| EGFR | EGFR | Lung cancer driver |101| BRCA1/2 | BRCA1, BRCA2 | Hereditary cancer |102| CYP2D6 | CYP2D6 | Drug metabolism |103| CYP2C19 | CYP2C19 | Clopidogrel, PPIs |104| CYP3A4 | CYP3A4 | Major drug metabolism |105| VKORC1 | VKORC1 | Warfarin dosing |106| SLCO1B1 | SLCO1B1 | Statin myopathy |107| DPYD | DPYD | Fluoropyrimidine toxicity |108| UGT1A1 | UGT1A1 | Irinotecan toxicity |109| TPMT | TPMT | Thiopurine toxicity |110111---112113## Phase 0: Tool Parameter Reference (CRITICAL)114115**BEFORE calling ANY tool**, verify parameters using this reference table.116117### Verified Tool Parameters118119| Tool | Parameters | Response Structure | Notes |120|------|-----------|-------------------|-------|121| `OpenTargets_get_disease_id_description_by_name` | `diseaseName` | `{data: {search: {hits: [{id, name, description}]}}}` | Disease to EFO ID |122| `OpenTargets_get_drug_id_description_by_name` | `drugName` | `{data: {search: {hits: [{id, name, description}]}}}` | Drug to ChEMBL ID |123| `OpenTargets_get_associated_drugs_by_disease_efoId` | `efoId`, `size` | `{data: {disease: {knownDrugs: {count, rows}}}}` | Drugs for disease |124| `OpenTargets_get_associated_targets_by_disease_efoId` | `efoId`, `size` | `{data: {disease: {associatedTargets: {count, rows}}}}` | Genetic associations |125| `OpenTargets_get_drug_mechanisms_of_action_by_chemblId` | `chemblId` | `{data: {drug: {mechanismsOfAction: {rows}}}}` | Drug MOA |126| `OpenTargets_get_approved_indications_by_drug_chemblId` | `chemblId` | Approved indications list | Check drug approvals |127| `OpenTargets_get_drug_adverse_events_by_chemblId` | `chemblId` | `{data: {drug: {adverseEvents: {count, rows}}}}` | Drug safety |128| `OpenTargets_get_associated_drugs_by_target_ensemblID` | `ensemblId`, `size` | Drug-target associations | Drugs targeting gene |129| `OpenTargets_get_target_safety_profile_by_ensemblID` | `ensemblId` | Safety profile data | Target safety |130| `OpenTargets_get_target_tractability_by_ensemblID` | `ensemblId` | Tractability assessment | Druggability |131| `OpenTargets_get_diseases_phenotypes_by_target_ensembl` | `ensemblId` | Disease-phenotype associations | Gene-disease links |132| `OpenTargets_target_disease_evidence` | `ensemblId`, `efoId`, `size` | Evidence for target-disease pair | Specific gene-disease evidence |133| `OpenTargets_search_gwas_studies_by_disease` | `diseaseIds` (array), `size` | `{data: {studies: {count, rows}}}` | GWAS studies |134| `OpenTargets_drug_pharmacogenomics_data` | `chemblId` | Pharmacogenomic data | Drug PGx |135| `MyGene_query_genes` | `query` (NOT `q`) | `{hits: [{_id, symbol, name, ensembl: {gene}}]}` | Gene resolution |136| `ensembl_lookup_gene` | `gene_id`, `species='homo_sapiens'` | `{data: {id, display_name, description, biotype}}` | REQUIRES species |137| `EnsemblVEP_annotate_rsid` | `variant_id` (NOT `rsid`) | VEP annotation with SIFT/PolyPhen | Variant impact |138| `EnsemblVEP_annotate_hgvs` | `hgvs_notation`, `species` | VEP annotation | HGVS variant annotation |139| `ensembl_get_variation` | `variant_id`, `species` | Variant details | rsID lookup |140| `clinvar_search_variants` | `gene`, `significance`, `limit` | Variant list | Search ClinVar |141| `clinvar_get_variant_details` | `variant_id` | Variant details with clinical significance | ClinVar details |142| `clinvar_get_clinical_significance` | `variant_id` | Clinical significance only | Quick pathogenicity |143| `civic_search_evidence_items` | `therapy_name`, `disease_name` | `{data: {evidenceItems: {nodes}}}` | Clinical evidence |144| `civic_search_variants` | `name`, `gene_name` | `{data: {variants: {nodes}}}` | Variant clinical significance |145| `civic_search_assertions` | `therapy_name`, `disease_name` | `{data: {assertions: {nodes}}}` | Clinical assertions |146| `cBioPortal_get_mutations` | `study_id`, `gene_list` (STRING, not array) | `{status, data: [{...}]}` | Somatic mutation data |147| `gwas_get_associations_for_trait` | `trait` | GWAS associations | Trait-SNP associations |148| `gwas_search_associations` | `query` | GWAS associations | Broad GWAS search |149| `gwas_get_snps_for_gene` | `gene` | SNPs associated with gene | Gene GWAS hits |150| `GWAS_search_associations_by_gene` | `gene_name` | Gene GWAS associations | Gene-trait links |151| `PharmGKB_get_clinical_annotations` | `query` | Clinical annotations | Drug-gene-phenotype |152| `PharmGKB_get_dosing_guidelines` | `query` | Dosing guidelines | PGx dosing |153| `PharmGKB_search_variants` | `query` | Variant PGx data | PGx variant search |154| `PharmGKB_get_gene_details` | `query` | Gene PGx details | PGx gene info |155| `PharmGKB_get_drug_details` | `query` | Drug PGx details | Drug PGx info |156| `fda_pharmacogenomic_biomarkers` | `drug_name`, `biomarker`, `limit` | `{count, shown, results: [{Drug, Biomarker, ...}]}` | FDA PGx biomarkers |157| `FDA_get_pharmacogenomics_info_by_drug_name` | `drug_name`, `limit` | `{meta, results}` | FDA PGx label info |158| `FDA_get_indications_by_drug_name` | `drug_name`, `limit` | `{meta, results}` | FDA indications |159| `FDA_get_clinical_studies_info_by_drug_name` | `drug_name`, `limit` | `{meta, results}` | Clinical study data |160| `FDA_get_contraindications_by_drug_name` | `drug_name`, `limit` | `{meta, results}` | Contraindications |161| `FDA_get_warnings_by_drug_name` | `drug_name`, `limit` | `{meta, results}` | Warnings |162| `FDA_get_boxed_warning_info_by_drug_name` | `drug_name`, `limit` | May return NOT_FOUND | Boxed warnings |163| `FDA_get_drug_interactions_by_drug_name` | `drug_name`, `limit` | `{meta, results}` | DDI info |164| `drugbank_get_drug_basic_info_by_drug_name_or_id` | `query`, `case_sensitive`, `exact_match`, `limit` | Drug basic info | ALL 4 REQUIRED |165| `drugbank_get_targets_by_drug_name_or_drugbank_id` | `query`, `case_sensitive`, `exact_match`, `limit` | Drug targets | ALL 4 REQUIRED |166| `drugbank_get_pharmacology_by_drug_name_or_drugbank_id` | `query`, `case_sensitive`, `exact_match`, `limit` | Pharmacology | ALL 4 REQUIRED |167| `drugbank_get_indications_by_drug_name_or_drugbank_id` | `query`, `case_sensitive`, `exact_match`, `limit` | Indications | ALL 4 REQUIRED |168| `drugbank_get_drug_interactions_by_drug_name_or_id` | `query`, `case_sensitive`, `exact_match`, `limit` | DDI data | ALL 4 REQUIRED |169| `drugbank_get_safety_by_drug_name_or_drugbank_id` | `query`, `case_sensitive`, `exact_match`, `limit` | Safety data | ALL 4 REQUIRED |170| `enrichr_gene_enrichment_analysis` | `gene_list` (array), `libs` (array, REQUIRED) | Enrichment results | Key libs: `KEGG_2021_Human`, `Reactome_2022`, `GO_Biological_Process_2023` |171| `ReactomeAnalysis_pathway_enrichment` | `identifiers` (space-separated string) | `{data: {pathways: [{pathway_id, name, p_value, ...}]}}` | Pathway enrichment |172| `Reactome_map_uniprot_to_pathways` | `id` (UniProt accession) | List of pathways | Gene-to-pathway |173| `STRING_get_interaction_partners` | `protein_ids` (array), `species` (9606), `limit` | Interaction partners | PPI network |174| `STRING_functional_enrichment` | `protein_ids` (array), `species` (9606) | Functional enrichment | Network enrichment |175| `HPA_get_cancer_prognostics_by_gene` | `gene_name` | Cancer prognostic data | Prognostic markers |176| `HPA_get_rna_expression_by_source` | `gene_name`, `source_type`, `source_name` (ALL 3) | Expression data | Tissue expression |177| `gnomad_get_gene_constraints` | `gene_symbol` | Gene constraint metrics | LoF intolerance |178| `gnomad_get_variant` | `variant_id` | Variant frequency | Population frequency |179| `clinical_trials_search` | `action='search_studies'`, `condition`, `intervention`, `limit` | `{total_count, studies}` | Trial search |180| `search_clinical_trials` | `query_term` (REQUIRED), `condition`, `intervention`, `pageSize` | `{studies, total_count}` | Alternative trial search |181| `PubMed_search_articles` | `query`, `max_results` | Plain list of dicts | Literature |182| `PubMed_Guidelines_Search` | `query`, `limit` (REQUIRED) | List of guideline articles | Clinical guidelines (may require API key) |183| `UniProt_get_function_by_accession` | `accession` | List of strings | Protein function |184| `UniProt_get_disease_variants_by_accession` | `accession` | Disease variants | Known pathogenic variants |185186### Response Format Notes187188- **OpenTargets**: Always nested `{data: {entity: {field: ...}}}` structure189- **FDA label tools**: Return `{meta: {disclaimer, terms, license, ...}, results: [...]}`. Access via `result['results'][0]['field']`190- **DrugBank**: ALL tools require 4 params: `query`, `case_sensitive` (bool), `exact_match` (bool), `limit` (int)191- **PharmGKB**: Returns complex nested objects. Check for `data` wrapper192- **PubMed_search_articles**: Returns a **plain list** of dicts, NOT `{articles: [...]}`193- **ClinVar**: `clinvar_search_variants` returns list of variants with clinical significance194- **gnomAD**: May return "Service overloaded" - treat as transient, retry or skip195- **fda_pharmacogenomic_biomarkers**: Default limit=10, use `limit=1000` to get all196- **cBioPortal_get_mutations**: `gene_list` is a STRING, not array. cBioPortal tools may have URL bugs197- **ClinVar**: May return either a plain list or `{status, data: {esearchresult: {count, idlist}}}` - handle both198- **EnsemblVEP**: May return either a list `[{...}]` or `{data: {...}, metadata: {...}}` - handle both199- **PubMed_Guidelines_Search**: Requires `limit` parameter (NOT `max_results`), may require API key. Use `PubMed_search_articles` as fallback200- **gwas_get_associations_for_trait**: May return errors; use `gwas_search_associations` instead201- **MyGene CYP2D6**: First result may be LOC110740340; always filter by `symbol` match202203---204205## Workflow Overview206207```208Input: Disease + Genomic data + Clinical parameters + Stratification goal209210Phase 1: Disease Disambiguation & Profile Standardization211 - Resolve disease to EFO/MONDO IDs212 - Classify disease type (cancer/metabolic/CVD/neuro/rare/autoimmune)213 - Parse genomic data (variants, genes, expression)214 - Resolve gene IDs (Ensembl, Entrez, UniProt)215216Phase 2: Genetic Risk Assessment217 - Germline variant pathogenicity (ClinVar, VEP)218 - Gene-disease association strength (OpenTargets)219 - GWAS-based polygenic risk estimation220 - Population frequency (gnomAD)221 - Gene constraint/intolerance (gnomAD)222223Phase 3: Disease-Specific Molecular Stratification224 CANCER PATH:225 - Molecular subtyping (driver mutations, receptor status)226 - Prognostic markers (stage + grade + molecular)227 - TMB/MSI/HRD assessment228 - Somatic mutation landscape (cBioPortal)229 METABOLIC PATH:230 - Genetic risk + clinical risk integration231 - Complication risk (nephropathy, neuropathy, CVD)232 - Monogenic subtypes (MODY, lipodystrophy)233 CVD PATH:234 - ASCVD risk integration235 - Familial hypercholesterolemia genes236 - Statin/anticoagulant PGx237 RARE DISEASE PATH:238 - Causal variant identification239 - Genotype-phenotype correlation240 - Penetrance estimation241242Phase 4: Pharmacogenomic Profiling243 - Drug-metabolizing enzyme genotypes (CYP2D6, CYP2C19, CYP3A4)244 - Drug transporter variants (SLCO1B1, ABCB1)245 - Drug target variants (VKORC1, DPYD, UGT1A1)246 - HLA alleles (drug hypersensitivity risk)247 - PharmGKB clinical annotations248 - FDA pharmacogenomic biomarkers249250Phase 5: Comorbidity & Drug Interaction Risk251 - Disease-disease genetic overlap252 - Impact on treatment selection253 - Drug-drug interaction risk254 - Pharmacogenomic DDI amplification255256Phase 6: Molecular Pathway Analysis257 - Dysregulated pathway identification (Reactome, KEGG)258 - Network disruption analysis (STRING)259 - Druggable pathway targets260 - Pathway-based therapeutic opportunities261262Phase 7: Clinical Evidence & Guidelines263 - Guideline-based risk categories (NCCN, ACC/AHA, ADA)264 - FDA-approved therapies for patient profile265 - Literature evidence (PubMed)266 - Biomarker-guided treatment evidence267268Phase 8: Clinical Trial Matching269 - Trials matching molecular profile270 - Biomarker-driven trials271 - Precision medicine basket/umbrella trials272 - Risk-adapted trials273274Phase 9: Integrated Scoring & Recommendations275 - Calculate Precision Medicine Risk Score (0-100)276 - Risk tier assignment (Low/Int/High/Very High)277 - Treatment algorithm (1st/2nd/3rd line)278 - Monitoring plan279 - Outcome predictions280```281282---283284## Phase 1: Disease Disambiguation & Profile Standardization285286### Step 1.1: Resolve Disease to EFO ID287288```python289# Get disease EFO ID290result = tu.tools.OpenTargets_get_disease_id_description_by_name(diseaseName='breast cancer')291# -> {data: {search: {hits: [{id: 'EFO_0000305', name: 'breast carcinoma', description: '...'}]}}}292efo_id = result['data']['search']['hits'][0]['id']293```294295**Common Disease EFO IDs** (for reference):296297| Disease | EFO ID | Category |298|---------|--------|----------|299| Breast carcinoma | EFO_0000305 | CANCER |300| Non-small cell lung carcinoma | EFO_0003060 | CANCER |301| Colorectal cancer | EFO_0000365 | CANCER |302| Melanoma | EFO_0000756 | CANCER |303| Prostate carcinoma | EFO_0001663 | CANCER |304| Type 2 diabetes | EFO_0001360 | METABOLIC |305| Coronary artery disease | EFO_0001645 | CVD |306| Atrial fibrillation | EFO_0000275 | CVD |307| Alzheimer disease | MONDO_0004975 | NEUROLOGICAL |308| Parkinson disease | EFO_0002508 | NEUROLOGICAL |309| Rheumatoid arthritis | EFO_0000685 | AUTOIMMUNE |310| Marfan syndrome | Orphanet_558 | RARE |311| Cystic fibrosis | EFO_0000508 | RARE |312313### Step 1.2: Classify Disease Type314315Based on disease name and EFO ID, classify into: CANCER, METABOLIC, CVD, NEUROLOGICAL, RARE, AUTOIMMUNE. This determines the Phase 3 routing.316317### Step 1.3: Parse Genomic Data318319Parse each variant/gene into structured format:320```321"BRCA1 c.68_69delAG" -> {gene: "BRCA1", variant: "c.68_69delAG", type: "frameshift"}322"EGFR L858R" -> {gene: "EGFR", variant: "L858R", type: "missense"}323"CYP2C19 *2/*2" -> {gene: "CYP2C19", genotype: "*2/*2", metabolizer_status: "poor"}324"APOE e4/e4" -> {gene: "APOE", genotype: "e4/e4", risk_allele: "e4"}325```326327### Step 1.4: Resolve Gene IDs328329```python330# For each gene in profile331result = tu.tools.MyGene_query_genes(query='BRCA1')332# -> hits[0]: {_id: '672', symbol: 'BRCA1', ensembl: {gene: 'ENSG00000012048'}}333ensembl_id = result['hits'][0]['ensembl']['gene']334entrez_id = result['hits'][0]['_id']335```336337**Critical Gene IDs** (pre-resolved):338339| Gene | Ensembl ID | Entrez ID | Category |340|------|-----------|-----------|----------|341| BRCA1 | ENSG00000012048 | 672 | Cancer predisposition |342| BRCA2 | ENSG00000139618 | 675 | Cancer predisposition |343| TP53 | ENSG00000141510 | 7157 | Tumor suppressor |344| EGFR | ENSG00000146648 | 1956 | Cancer driver |345| BRAF | ENSG00000157764 | 673 | Cancer driver |346| KRAS | ENSG00000133703 | 3845 | Cancer driver |347| CYP2D6 | ENSG00000100197 | 1565 | Pharmacogenomics |348| CYP2C19 | ENSG00000165841 | 1557 | Pharmacogenomics |349| SLCO1B1 | ENSG00000134538 | 10599 | Pharmacogenomics |350| VKORC1 | ENSG00000167397 | 79001 | Pharmacogenomics |351| DPYD | ENSG00000188641 | 1806 | Pharmacogenomics |352| APOE | ENSG00000130203 | 348 | Neurological risk |353| LDLR | ENSG00000130164 | 3949 | CVD risk |354| PCSK9 | ENSG00000169174 | 255738 | CVD risk |355| FBN1 | ENSG00000166147 | 2200 | Marfan syndrome |356| CFTR | ENSG00000001626 | 1080 | Cystic fibrosis |357358---359360## Phase 2: Genetic Risk Assessment361362### Step 2.1: Germline Variant Pathogenicity363364For each germline variant provided:365366```python367# Search ClinVar for variant pathogenicity368result = tu.tools.clinvar_search_variants(gene='BRCA1', significance='pathogenic', limit=50)369# Check if patient's specific variant is in ClinVar370371# For rsID variants, get VEP annotation372result = tu.tools.EnsemblVEP_annotate_rsid(variant_id='rs80357906')373# Returns SIFT, PolyPhen predictions, consequence type374375# For HGVS variants376result = tu.tools.EnsemblVEP_annotate_hgvs(hgvs_notation='ENST00000357654.9:c.5266dupC', species='homo_sapiens')377```378379**Pathogenicity Classification** (ACMG-aligned):380381| Classification | ClinVar Term | Risk Score Points |382|---------------|-------------|-------------------|383| Pathogenic | Pathogenic | 25 (molecular component) |384| Likely pathogenic | Likely pathogenic | 20 |385| VUS | Uncertain significance | 10 (conservative) |386| Likely benign | Likely benign | 2 |387| Benign | Benign | 0 |388389### Step 2.2: Gene-Disease Association Strength390391```python392# Get genetic evidence for gene-disease pair393result = tu.tools.OpenTargets_target_disease_evidence(394 ensemblId='ENSG00000012048', # BRCA1395 efoId='EFO_0000305', # breast cancer396 size=20397)398# Returns evidence items with scores399```400401### Step 2.3: GWAS-Based Polygenic Risk402403```python404# Search GWAS associations for disease405result = tu.tools.gwas_get_associations_for_trait(trait='breast cancer')406# Returns associated SNPs with effect sizes407408# Search GWAS studies via OpenTargets409result = tu.tools.OpenTargets_search_gwas_studies_by_disease(410 diseaseIds=['EFO_0000305'], size=25411)412413# For specific genes, check GWAS hits414result = tu.tools.GWAS_search_associations_by_gene(gene_name='BRCA1')415```416417**PRS Estimation** (from available GWAS data):418419| PRS Percentile | Risk Category | Score Points (0-35) |420|---------------|--------------|---------------------|421| >95th percentile | Very high genetic risk | 35 |422| 90-95th | High genetic risk | 30 |423| 75-90th | Elevated genetic risk | 25 |424| 50-75th | Average-high | 18 |425| 25-50th | Average-low | 12 |426| 10-25th | Below average | 8 |427| <10th | Low genetic risk | 5 |428429**Note**: With user-provided variants only (not full genotype), estimate approximate PRS by counting known risk alleles and their effect sizes from GWAS catalog. Flag as "estimated - full genotyping recommended for precise PRS."430431### Step 2.4: Population Frequency432433```python434# Check variant frequency in gnomAD435result = tu.tools.gnomad_get_variant(variant_id='1-55505647-G-T')436# Returns allele frequency across populations437```438439### Step 2.5: Gene Constraint440441```python442# Gene intolerance to loss of function443result = tu.tools.gnomad_get_gene_constraints(gene_symbol='BRCA1')444# Returns pLI, LOEUF scores - high pLI/low LOEUF = haploinsufficiency445```446447**Genetic Risk Score Component** (0-35 points):448449Combine pathogenicity + gene-disease association + PRS:450- Pathogenic variant in disease gene: 25+ points451- Strong GWAS associations (multiple risk alleles): up to 35 points452- VUS in relevant gene: 10-15 points453- No known pathogenic variants but some risk alleles: 5-15 points454455---456457## Phase 3: Disease-Specific Molecular Stratification458459### CANCER PATH (Phase 3C)460461#### Step 3C.1: Molecular Subtyping462463```python464# Get somatic mutation landscape from cBioPortal465result = tu.tools.cBioPortal_get_mutations(466 study_id='brca_tcga_pub', # breast cancer TCGA467 gene_list='BRCA1 BRCA2 TP53 PIK3CA ESR1 ERBB2' # STRING, not array468)469# Returns mutation frequencies, types470471# Check cancer prognostic markers472result = tu.tools.HPA_get_cancer_prognostics_by_gene(gene_name='ESR1')473# Returns prognostic data for breast cancer474```475476**Cancer-Specific Subtype Definitions**:477478| Cancer | Subtype System | Key Markers | High-Risk Features |479|--------|---------------|-------------|-------------------|480| Breast | Luminal A/B, HER2+, TNBC | ER, PR, HER2, Ki67 | TNBC, high Ki67, TP53 mut |481| NSCLC | Adenocarcinoma, squamous | EGFR, ALK, ROS1, KRAS, PD-L1 | KRAS G12C, no driver = chemoIO |482| CRC | MSI-H vs MSS, CMS1-4 | KRAS, BRAF, MSI, CMS | BRAF V600E, MSS |483| Melanoma | BRAF-mut, NRAS-mut, wild-type | BRAF, NRAS, KIT, NF1 | NRAS, uveal |484| Prostate | Luminal vs basal, BRCA status | AR, BRCA1/2, SPOP, TMPRSS2:ERG | BRCA2, neuroendocrine |485486#### Step 3C.2: TMB/MSI/HRD Assessment487488If TMB provided:489```python490# Check FDA TMB-H approvals491result = tu.tools.fda_pharmacogenomic_biomarkers(drug_name='pembrolizumab', limit=100)492# Look for "Tumor Mutational Burden" in Biomarker field493```494495| Biomarker | High-Risk Threshold | Clinical Significance |496|-----------|-------------------|----------------------|497| TMB | >= 10 mut/Mb (FDA cutoff) | Pembrolizumab eligible (tissue-agnostic) |498| MSI-H | MSI-high or dMMR | Pembrolizumab/nivolumab eligible |499| HRD | HRD-positive | PARP inhibitor eligible |500501#### Step 3C.3: Prognostic Stratification502503Combine stage + molecular features:504505| Stage | Low-Risk Molecular | High-Risk Molecular | Score (0-30 clinical) |506|-------|-------------------|--------------------|-----------------------|507| I | Favorable subtype | Unfavorable subtype | 5-10 |508| II | Favorable subtype | Unfavorable subtype | 10-18 |509| III | Any | Any | 18-25 |510| IV | Any | Any | 25-30 |511512### METABOLIC PATH (Phase 3M)513514#### Step 3M.1: Clinical Risk Integration515516```python517# Check genetic risk factors for T2D518result = tu.tools.GWAS_search_associations_by_gene(gene_name='TCF7L2')519# TCF7L2 is strongest T2D risk gene520521# Check monogenic diabetes genes522result = tu.tools.OpenTargets_target_disease_evidence(523 ensemblId='ENSG00000148737', # TCF7L2524 efoId='EFO_0001360', # T2D525 size=20526)527```528529**T2D Stratification**:530531| Risk Factor | Low Risk | Moderate Risk | High Risk | Score Points |532|-------------|----------|---------------|-----------|-------------|533| HbA1c | <6.5% | 6.5-8.0% | >8.0% | 5-30 |534| Genetic risk | No risk alleles | 1-3 risk alleles | MODY gene/many risk alleles | 5-25 |535| Complications | None | Microalbuminuria | Retinopathy, neuropathy | 0-20 |536| Duration | <5 years | 5-15 years | >15 years | 0-10 |537538### CVD PATH (Phase 3V)539540```python541# Check PCSK9 and LDLR variants542result = tu.tools.clinvar_search_variants(gene='LDLR', significance='pathogenic', limit=20)543# Familial hypercholesterolemia check544545# Check statin-relevant PGx546result = tu.tools.PharmGKB_get_clinical_annotations(query='SLCO1B1')547# SLCO1B1 *5 -> increased statin myopathy risk548```549550**CVD Risk Integration**:551552| Factor | Score Points |553|--------|-------------|554| LDL >190 mg/dL | 15 |555| FH gene mutation (LDLR/APOB/PCSK9) | 20 |556| ASCVD >20% 10-year risk | 30 |557| Family hx premature CVD | 10 |558| Lipoprotein(a) elevated | 8 |559| Multiple GWAS risk alleles | 5-15 |560561### RARE DISEASE PATH (Phase 3R)562563```python564# Check causal variant in disease gene565result = tu.tools.clinvar_search_variants(gene='FBN1', significance='pathogenic', limit=50)566# Marfan syndrome - FBN1 pathogenic variants567568# Genotype-phenotype correlation569result = tu.tools.UniProt_get_disease_variants_by_accession(accession='P35555') # FBN1 UniProt570# Known disease variants and their phenotypes571```572573**Rare Disease Risk Assessment**:574575| Finding | Risk Level | Score Points |576|---------|-----------|-------------|577| Pathogenic variant in causal gene | Definitive | 30 |578| Likely pathogenic in causal gene | Strong | 25 |579| VUS in causal gene | Moderate | 15 |580| Family history + partial phenotype | Suggestive | 10 |581| Single phenotype feature only | Low | 5 |582583---584585## Phase 4: Pharmacogenomic Profiling586587### Step 4.1: Drug-Metabolizing Enzyme Genotypes588589```python590# PharmGKB clinical annotations for CYP2C19591result = tu.tools.PharmGKB_get_clinical_annotations(query='CYP2C19')592# Returns drug-gene pairs with clinical annotation levels593594# FDA pharmacogenomic biomarkers595result = tu.tools.fda_pharmacogenomic_biomarkers(drug_name='clopidogrel', limit=50)596# CYP2C19 poor metabolizer -> reduced clopidogrel efficacy597598# PharmGKB dosing guidelines599result = tu.tools.PharmGKB_get_dosing_guidelines(query='CYP2C19')600# CPIC dosing guidelines601```602603**Key Pharmacogenes and Clinical Impact**:604605| Gene | Star Alleles | Metabolizer Status | Clinical Impact | Score Points |606|------|-------------|-------------------|----------------|-------------|607| CYP2D6 | *4/*4, *5/*5 | Poor metabolizer | Codeine, tamoxifen, many antidepressants | 8 |608| CYP2C19 | *2/*2, *2/*3 | Poor metabolizer | Clopidogrel, voriconazole, PPIs | 8 |609| CYP2C9 | *2/*3, *3/*3 | Poor metabolizer | Warfarin, NSAIDs, phenytoin | 5 |610| SLCO1B1 | *5/*5 | Decreased function | Statin myopathy (simvastatin) | 5 |611| DPYD | *2A | DPD deficient | 5-FU/capecitabine severe toxicity | 10 |612| VKORC1 | -1639G>A | Warfarin sensitive | Lower warfarin dose needed | 5 |613| UGT1A1 | *28/*28 | Poor glucuronidator | Irinotecan toxicity | 5 |614| TPMT | *2, *3A, *3C | Poor metabolizer | Thiopurine toxicity | 8 |615| HLA-B*5701 | Present | N/A | Abacavir hypersensitivity | 10 |616| HLA-B*1502 | Present | N/A | Carbamazepine SJS/TEN | 10 |617618### Step 4.2: Treatment-Specific PGx619620```python621# For the specific disease, identify relevant drugs and check PGx622# Example: breast cancer -> tamoxifen -> CYP2D6623result = tu.tools.PharmGKB_get_drug_details(query='tamoxifen')624# Returns PGx annotations for tamoxifen625626# Get FDA PGx biomarkers for disease area627result = tu.tools.fda_pharmacogenomic_biomarkers(biomarker='CYP2D6', limit=100)628# All drugs with CYP2D6 PGx in FDA labels629```630631### Step 4.3: Drug Target Variants632633```python634# Check if patient has variants in drug targets635result = tu.tools.PharmGKB_search_variants(query='VKORC1')636# VKORC1 variants affecting warfarin response637```638639**Pharmacogenomic Risk Score** (0-10 points):640- Poor metabolizer for treatment-relevant CYP: 8-10 points641- Intermediate metabolizer: 4-5 points642- High-risk HLA allele: 8-10 points643- Drug target variant: 3-5 points644- Normal metabolizer, no actionable PGx: 0 points645646---647648## Phase 5: Comorbidity & Drug Interaction Risk649650### Step 5.1: Comorbidity Analysis651652```python653# Check disease-disease overlap via shared genetic targets654result = tu.tools.OpenTargets_get_associated_targets_by_disease_efoId(655 efoId='EFO_0001360', # T2D656 size=50657)658# Compare top targets between primary disease and comorbidities659660# Literature on comorbidity661result = tu.tools.PubMed_search_articles(662 query='type 2 diabetes cardiovascular comorbidity risk',663 max_results=5664)665```666667### Step 5.2: Drug-Drug Interaction Risk668669```python670# If current medications provided, check DDI671result = tu.tools.drugbank_get_drug_interactions_by_drug_name_or_id(672 query='metformin',673 case_sensitive=False,674 exact_match=False,675 limit=20676)677678# FDA DDI data679result = tu.tools.FDA_get_drug_interactions_by_drug_name(drug_name='metformin', limit=5)680```681682### Step 5.3: PGx-Amplified DDI Risk683684If patient is a CYP2D6 poor metabolizer AND taking a CYP2D6 inhibitor -> compounded risk.685686| Interaction Type | Risk Level | Management |687|-----------------|-----------|------------|688| PGx PM + CYP inhibitor | Very high | Alternative drug or dose reduction |689| PGx IM + CYP inhibitor | High | Monitor closely, possible dose reduction |690| PGx normal + CYP inhibitor | Moderate | Standard monitoring |691| No interacting drugs | Low | Standard care |692693---694695## Phase 6: Molecular Pathway Analysis696697### Step 6.1: Dysregulated Pathways698699```python700# Pathway enrichment for affected genes701gene_list = ['BRCA1', 'TP53', 'PIK3CA'] # from patient mutations702result = tu.tools.enrichr_gene_enrichment_analysis(703 gene_list=gene_list,704 libs=['KEGG_2021_Human', 'Reactome_2022']705)706# Returns enriched pathways with p-values707708# Reactome pathway analysis709# First get UniProt IDs, then map to pathways710result = tu.tools.Reactome_map_uniprot_to_pathways(id='P38398') # BRCA1 UniProt711# Returns list of pathways involving BRCA1712```713714### Step 6.2: Network Analysis715716```python717# Protein-protein interaction network718result = tu.tools.STRING_get_interaction_partners(719 protein_ids=['BRCA1', 'TP53'],720 species=9606,721 limit=20722)723724# Functional enrichment of network725result = tu.tools.STRING_functional_enrichment(726 protein_ids=['BRCA1', 'TP53', 'PALB2', 'RAD51'],727 species=9606728)729```730731### Step 6.3: Druggable Pathway Targets732733```python734# Check tractability of pathway nodes735for gene in pathway_genes:736 result = tu.tools.OpenTargets_get_target_tractability_by_ensemblID(ensemblId=ensembl_id)737 # Returns small molecule, antibody, PROTAC tractability738```739740**Key Druggable Pathways**:741742| Pathway | Key Nodes | Drug Classes | Cancer Relevance |743|---------|-----------|-------------|-----------------|744| PI3K/AKT/mTOR | PIK3CA, AKT1, MTOR | PI3K inhibitors, mTOR inhibitors | Breast, endometrial |745| RAS/MAPK | KRAS, BRAF, MEK1/2 | KRAS G12C inhibitors, BRAF inhibitors | Lung, CRC, melanoma |746| DNA damage repair | BRCA1/2, ATM, PALB2 | PARP inhibitors | Breast, ovarian, prostate |747| Cell cycle | CDK4/6, RB1, CCND1 | CDK4/6 inhibitors | Breast |748| Immunocheckpoint | PD-1, PD-L1, CTLA-4 | ICIs | Pan-cancer |749| Wnt/beta-catenin | APC, CTNNB1, TCF | Wnt inhibitors (investigational) | CRC |750751---752753## Phase 7: Clinical Evidence & Guidelines754755### Step 7.1: Guideline-Based Risk Categories756757```python758# Search clinical guidelines in PubMed759result = tu.tools.PubMed_Guidelines_Search(760 query='NCCN breast cancer BRCA1 treatment guidelines',761 max_results=5762)763764# Search general evidence765result = tu.tools.PubMed_search_articles(766 query='BRCA1 breast cancer treatment stratification',767 max_results=10768)769```770771**Guideline References by Disease**:772773| Disease Category | Guidelines | Key Stratification |774|-----------------|-----------|-------------------|775| Breast cancer | NCCN, ASCO, St. Gallen | Luminal A/B, HER2+, TNBC, BRCA status |776| NSCLC | NCCN, ESMO | Driver mutation status, PD-L1, TMB |777| CRC | NCCN | MSI, RAS/BRAF, sidedness |778| T2D | ADA Standards | HbA1c, CVD risk, CKD stage |779| CVD | ACC/AHA | ASCVD risk score, LDL goals, PGx |780| AF | ACC/AHA/HRS | CHA2DS2-VASc, anticoagulant selection |781| Rare disease | ACMG/AMP | Variant classification, genetic counseling |782783### Step 7.2: FDA-Approved Therapies784785```python786# Get approved drugs for disease787result = tu.tools.OpenTargets_get_associated_drugs_by_disease_efoId(788 efoId='EFO_0000305', # breast cancer789 size=50790)791# Returns all known drugs with clinical status792793# Check specific drug FDA info794result = tu.tools.FDA_get_indications_by_drug_name(drug_name='olaparib', limit=5)795# PARP inhibitor for BRCA-mutated breast cancer796797# Get drug mechanism798result = tu.tools.FDA_get_mechanism_of_action_by_drug_name(drug_name='olaparib', limit=5)799```800801### Step 7.3: Biomarker-Drug Evidence802803```python804# CIViC evidence for biomarker-drug pair805result = tu.tools.civic_search_evidence_items(806 therapy_name='olaparib',807 disease_name='breast cancer'808)809# Returns clinical evidence items with evidence levels810811# DrugBank for drug details812result = tu.tools.drugbank_get_drug_basic_info_by_drug_name_or_id(813 query='olaparib',814 case_sensitive=False,815 exact_match=False,816 limit=5817)818```819820---821822## Phase 8: Clinical Trial Matching823824### Step 8.1: Biomarker-Driven Trials825826```python827# Search trials matching molecular profile828result = tu.tools.clinical_trials_search(829 action='search_studies',830 condition='breast cancer',831 intervention='PARP inhibitor',832 limit=10833)834# Returns {total_count, studies: [{nctId, title, status, conditions}]}835836# Alternative search837result = tu.tools.search_clinical_trials(838 query_term='BRCA1 breast cancer',839 condition='breast cancer',840 intervention='olaparib',841 pageSize=10842)843```844845### Step 8.2: Precision Medicine Trials846847```python848# Search basket/umbrella trials849result = tu.tools.search_clinical_trials(850 query_term='precision medicine biomarker-driven',851 condition='breast cancer',852 pageSize=10853)854855# Search risk-adapted trials856result = tu.tools.search_clinical_trials(857 query_term='high risk BRCA1',858 condition='breast cancer',859 pageSize=10860)861```862863### Step 8.3: Trial Details864865```python866# Get details for promising trials867result = tu.tools.clinical_trials_get_details(868 action='get_study_details',869 nct_id='NCT03344965'870)871# Returns full study protocol872```873874---875876## Phase 9: Integrated Scoring & Recommendations877878### Precision Medicine Risk Score (0-100)879880#### Score Components881882**Genetic Risk Component** (0-35 points):883884| Scenario | Points |885|----------|--------|886| Pathogenic variant in high-penetrance disease gene (BRCA1, LDLR, FBN1) | 30-35 |887| Multiple moderate-risk variants (GWAS hits + moderate penetrance) | 20-28 |888| High PRS (>90th percentile) with no known pathogenic variants | 25-30 |889| Single moderate-risk variant | 12-18 |890| VUS in relevant gene | 8-12 |891| Average PRS, no pathogenic variants | 5-10 |892| Low genetic risk (low PRS, no risk alleles) | 0-5 |893894**Clinical Risk Component** (0-30 points):895896| Disease Type | Factor | Low (0-8) | Moderate (10-20) | High (22-30) |897|-------------|--------|-----------|------------------|-------------|898| Cancer | Stage | I | II-III | IV |899| T2D | HbA1c | <7% | 7-9% | >9% |900| CVD | ASCVD 10-yr | <10% | 10-20% | >20% |901| Neuro | Biomarker status | No biomarkers | Mild changes | Established |902| Rare | Phenotype match | Partial | Moderate | Full phenotype |903904**Molecular Features Component** (0-25 points):905906| Feature | Points |907|---------|--------|908| Cancer: High-risk driver mutations (TP53+PIK3CA, KRAS G12C) | 20-25 |909| Cancer: Actionable mutation (EGFR, BRAF V600E) | 15-20 |910| Cancer: High TMB or MSI-H (favorable for ICI) | 10-15 |911| Metabolic: Monogenic form (MODY, FH) | 20-25 |912| Metabolic: Multiple metabolic risk variants | 10-15 |913| CVD: FH gene mutation | 20-25 |914| Rare: Complete genotype-phenotype match | 20-25 |915| VUS requiring further workup | 5-10 |916917**Pharmacogenomic Risk Component** (0-10 points):918919| Finding | Points |920|---------|--------|921| Poor metabolizer for treatment-critical CYP + high-risk HLA | 10 |922| Poor metabolizer for treatment-critical CYP | 7-8 |923| Intermediate metabolizer for relevant CYP | 4-5 |924| Drug target variant (e.g., VKORC1 for warfarin) | 3-5 |925| No actionable PGx findings | 0-2 |926927#### Risk Tier Assignment928929| Total Score | Risk930931…(truncated)