Tooluniverse polygenic risk score

From wu-yc/LabClaw · View interactive version

Tooluniverse polygenic risk score is an AI agent skill from the GitHub repository wu-yc/LabClaw. Build and interpret polygenic risk scores (PRS) for complex diseases using GWAS summary statistics. Calculates genetic risk profiles, interprets PRS percentiles, and assesses disease predisposition across conditions including type 2 diabetes, coronary artery disease, and Alzheimer's disease. Use whe

How to use this skill

Skill file

Polygenic Risk Score (PRS) Builder

Build and interpret polygenic risk scores for complex diseases using genome-wide association study (GWAS) data.

Overview

Use Cases:

What This Skill Does:

What This Skill Does NOT Do:

Methodology

PRS Calculation Formula

A polygenic risk score is calculated as a weighted sum across genetic variants:

PRS = Σ (dosage_i × effect_size_i)

Where:

Standardization

Raw PRS is standardized to z-scores for interpretation:

z-score = (PRS - population_mean) / population_std

This allows comparison to population distribution and percentile calculation.

Significance Thresholds

Effect Size Handling

Data Sources

This skill uses ToolUniverse GWAS tools to query:

  1. GWAS Catalog (EMBL-EBI)
  1. Open Targets Genetics

Key Concepts

Polygenic Risk Scores (PRS)

Polygenic risk scores aggregate the effects of many genetic variants to estimate an individual's genetic predisposition to a trait or disease. Unlike Mendelian diseases caused by single mutations, complex diseases involve hundreds to thousands of variants, each with small effects.

Key Properties:

GWAS (Genome-Wide Association Studies)

GWAS compare allele frequencies between cases and controls (or correlate with trait values) across millions of SNPs to identify disease-associated variants.

Study Design:

Effect Sizes and Odds Ratios

Linkage Disequilibrium (LD) and Clumping

Nearby variants are often inherited together (LD). To avoid double-counting:

Population Stratification

GWAS and PRS are most accurate when ancestries match:

Applications

Clinical Risk Assessment

PRS can stratify individuals for:

Example: Khera et al. (2018) showed PRS identifies 3× more individuals at >3-fold coronary artery disease risk than monogenic mutations.

Research Applications

Personal Genomics

Consumer genetic testing (23andMe, Ancestry DNA) provides raw genotypes. Users can:

Caution: Personal PRS should not replace medical advice. Results may cause anxiety if not properly contextualized.

Limitations and Considerations

Scientific Limitations

  1. Heritability Gap: PRS explains a fraction of genetic heritability
  1. Ancestry Bias: Most GWAS are European ancestry
  1. Winner's Curse: Discovery effect sizes often overestimated
  1. Missing Heritability: Unexplained genetic contribution from:

Clinical Limitations

  1. Not Diagnostic: PRS is probabilistic, not deterministic
  1. Environmental Factors: Many complex diseases are 50%+ environmental
  1. Pleiotropy: Same variants affect multiple traits
  1. Actionability: Not all high-risk predictions have interventions

Ethical Considerations

  1. Privacy: Genetic data is identifiable and permanent
  1. Discrimination: Potential for genetic discrimination
  1. Psychological Impact: Knowledge of high risk can cause anxiety
  1. Equity: Ancestry bias means unequal benefits

References

Key Publications

  1. Lambert et al. (2021): "The Polygenic Score Catalog as an open database for reproducibility and systematic evaluation"
  1. Khera et al. (2018): "Genome-wide polygenic scores for common diseases identify individuals with risk equivalent to monogenic mutations"
  1. Torkamani et al. (2018): "The personal and clinical utility of polygenic risk scores"
  1. Martin et al. (2019): "Clinical use of current polygenic risk scores may exacerbate health disparities"
  1. Choi et al. (2020): "Tutorial: a guide to performing polygenic risk score analyses"

Resources

Workflow

1. Trait Selection

Identify the disease or trait of interest:

2. Association Collection

Query GWAS databases for genome-wide significant associations:

prs = build_polygenic_risk_score(
    trait="coronary artery disease",
    p_threshold=5e-8,  # Genome-wide significance
    max_snps=1000
)

Considerations:

3. Effect Size Extraction

Extract beta coefficients or odds ratios:

4. SNP Filtering

Quality control filters:

5. Score Calculation

Calculate weighted sum of genotype dosages:

result = calculate_personal_prs(
    prs_weights=prs,
    genotypes=my_genotypes,
    population_mean=0.0,
    population_std=1.0
)

Genotype Sources:

6. Risk Interpretation

Convert to percentiles and risk categories:

result = interpret_prs_percentile(result)
print(f"Percentile: {result.percentile:.1f}%")
print(f"Risk: {result.risk_category}")

Risk Categories:

Clinical Interpretation:

Best Practices

PRS Construction

  1. Use validated PRS from PGS Catalog when available
  1. Match ancestries between GWAS and target population
  1. Include as many SNPs as practical
  1. Consider trait architecture

Clinical Use

  1. Combine with clinical risk scores
  1. Stratify screening and prevention
  1. Provide genetic counseling
  1. Consider actionability

Research Use

  1. Report methods transparently
  1. Validate in held-out cohorts
  1. Compare to existing PRS
  1. Test across ancestries

Disclaimer

This skill is for educational and research purposes only.

For clinical genetic testing, consult:

PRS is a rapidly evolving field. Guidelines and best practices will continue to change as research progresses.

Regulatory Status:

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.