Install any skill in seconds. Free to start, no credit card required.
Get Started Free →Query ClinVar for variant pathogenicity classifications, review status, and disease associations via REST API or local VCF. Use when determining clinical significance of variants for diagnostic or research purposes.
.claude/skills/bio-clinical-databases-clinvar-lookup/SKILL.md| Test case | Without → With | Effect | Δ tokens | Δ turns |
|---|---|---|---|---|
| case-19 | ✗→✓ | ▲ Improved | — | — |
| case-04 | ✗→✓ | ▲ Improved | — | — |
| case-01 | ✗→✓ | ▲ Improved | — | — |
| case-09 | ✗→✓ | ▲ Improved | — | — |
| case-03 | ✗→✓ | ▲ Improved | — | — |
Reference examples tested with: Entrez Direct 21.0+, bcftools 1.19+
Before using code patterns, verify installed versions match. If versions differ:
pip show <package> then help(module.function) to check signatures<tool> --version then <tool> --help to confirm flagsIf code throws ImportError, AttributeError, or TypeError, introspect the installed package and adapt the example to match the actual API rather than retrying.
Goal: Retrieve ClinVar pathogenicity classifications and disease associations for variants via REST API.
Approach: Query NCBI E-utilities endpoints with variant IDs, gene symbols, or HGVS notation and parse JSON responses.
"Look up this variant in ClinVar" → Query ClinVar database for clinical significance, review status, and disease associations.
requests.get() against NCBI E-utilities (requests)esearch/efetch (Entrez Direct)pythonimport requests def query_clinvar_by_id(variation_id): '''Query ClinVar by variation ID''' url = f'https://eutils.ncbi.nlm.nih.gov/entrez/eutils/esummary.fcgi' params = { 'db': 'clinvar', 'id': variation_id, 'retmode': 'json' } response = requests.get(url, params=params) return response.json() result = query_clinvar_by_id('16609')
pythondef search_clinvar_gene(gene_symbol, pathogenic_only=False): '''Search ClinVar for variants in a gene''' url = 'https://eutils.ncbi.nlm.nih.gov/entrez/eutils/esearch.fcgi' term = f'{gene_symbol}[gene]' if pathogenic_only: term += ' AND pathogenic[clinical_significance]' params = { 'db': 'clinvar', 'term': term, 'retmax': 500, 'retmode': 'json' } response = requests.get(url, params=params) return response.json()
pythondef search_clinvar_hgvs(hgvs): '''Search ClinVar by HGVS notation''' url = 'https://eutils.ncbi.nlm.nih.gov/entrez/eutils/esearch.fcgi' params = { 'db': 'clinvar', 'term': f'{hgvs}[variant name]', 'retmode': 'json' } response = requests.get(url, params=params) return response.json()
Goal: Query variants against a local ClinVar VCF for fast, offline pathogenicity lookups.
Approach: Download the ClinVar VCF from NCBI FTP, then query by genomic coordinates using cyvcf2 or bcftools.
bash# GRCh38 wget https://ftp.ncbi.nlm.nih.gov/pub/clinvar/vcf_GRCh38/clinvar.vcf.gz wget https://ftp.ncbi.nlm.nih.gov/pub/clinvar/vcf_GRCh38/clinvar.vcf.gz.tbi # GRCh37 wget https://ftp.ncbi.nlm.nih.gov/pub/clinvar/vcf_GRCh37/clinvar.vcf.gz
pythonfrom cyvcf2 import VCF clinvar = VCF('clinvar.vcf.gz') def lookup_variant(chrom, pos, ref, alt): '''Look up variant in local ClinVar VCF''' region = f'{chrom}:{pos}-{pos}' for variant in clinvar(region): if variant.REF == ref and alt in variant.ALT: return { 'clnsig': variant.INFO.get('CLNSIG'), 'clnrevstat': variant.INFO.get('CLNREVSTAT'), 'clndn': variant.INFO.get('CLNDN'), 'clnvc': variant.INFO.get('CLNVC') } return None result = lookup_variant('7', 140453136, 'A', 'T')
| Value | Interpretation | |-------|----------------| | Pathogenic | Disease-causing | | Likely_pathogenic | Probably disease-causing | | Uncertain_significance | VUS - unknown | | Likely_benign | Probably not disease-causing | | Benign | Not disease-causing | | Conflicting_interpretations | Multiple labs disagree |
| Stars | Review Status | |-------|---------------| | 4 | Practice guideline | | 3 | Expert panel reviewed | | 2 | Multiple submitters, criteria provided | | 1 | Single submitter, criteria provided | | 0 | No assertion criteria |
Goal: Classify variants into actionable pathogenicity categories from raw ClinVar CLNSIG values.
Approach: Map ClinVar significance terms to simplified categories (pathogenic, benign, conflicting, VUS).
pythondef parse_clinvar_significance(clnsig): '''Parse ClinVar CLNSIG field''' pathogenic_terms = ['Pathogenic', 'Likely_pathogenic'] benign_terms = ['Benign', 'Likely_benign'] if any(term in clnsig for term in pathogenic_terms): return 'pathogenic' elif any(term in clnsig for term in benign_terms): return 'benign' elif 'Conflicting' in clnsig: return 'conflicting' else: return 'vus'
Goal: Annotate an entire VCF with ClinVar significance, review status, and disease names in one pass.
Approach: Use bcftools annotate to transfer ClinVar INFO fields from the ClinVar VCF to the input VCF.
bash# Annotate VCF with ClinVar bcftools annotate \ -a clinvar.vcf.gz \ -c INFO/CLNSIG,INFO/CLNREVSTAT,INFO/CLNDN \ input.vcf.gz \ -o annotated.vcf.gz
| Case | Status | Duration (ms) | Turns | Tokens | Tool calls | ||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Without | With | Δ | Without | With | Δ | Without | With | Δ | Without | With | Δ | ||
case-13 | fail→fail | — | — | — | — | — | — | — | — | — | — | — | — |
case-15 | fail→fail | — | — | — | — | — | — | — | — | — | — | — | — |
case-19 | fail→pass | — | — | — | — | — | — | — | — | — | — | — | — |
case-21 | fail→fail | — | — | — | — | — | — | — | — | — | — | — | — |
case-22 | fail→fail | — | — | — | — | — | — | — | — | — | — | — | — |
case-11 | fail→fail | — | — | — | — | — | — | — | — | — | — | — | — |
case-04 | fail→pass | — | — | — | — | — | — | — | — | — | — | — | — |
case-10 | fail→fail | — | — | — | — | — | — | — | — | — | — | — | — |
case-08 | fail→fail | — | — | — | — | — | — | — | — | — | — | — | — |
case-07 | fail→fail | — | — | — | — | — | — | — | — | — | — | — | — |
case-06 | fail→fail | — | — | — | — | — | — | — | — | — | — | — | — |
case-20 | fail→fail | — | — | — | — | — | — | — | — | — | — | — | — |
case-12 | fail→fail | — | — | — | — | — | — | — | — | — | — | — | — |
case-17 | fail→fail | — | — | — | — | — | — | — | — | — | — | — | — |
case-14 | fail→fail | — | — | — | — | — | — | — | — | — | — | — | — |
case-01 | fail→pass | — | — | — | — | — | — | — | — | — | — | — | — |
case-05 | fail→fail | — | — | — | — | — | — | — | — | — | — | — | — |
case-09 | fail→pass | — | — | — | — | — | — | — | — | — | — | — | — |
case-18 | fail→fail | — | — | — | — | — | — | — | — | — | — | — | — |
case-16 | fail→fail | — | — | — | — | — | — | — | — | — | — | — | — |
case-03 | fail→pass | — | — | — | — | — | — | — | — | — | — | — | — |
case-02 | fail→fail | — | — | — | — | — | — | — | — | — | — | — | — |
DecimalAI ran this skill against gemini-3.6-flash twice over the same eval suite — once with the skill loaded and once without — and compared the two runs case by case. 22 cases were attempted. The headline lift of +23 percentage points is the difference between those two pass rates over the 22 comparable cases.
The per-case answers from this run were removed by the retention sweep, so the case table below shows the verdicts without the text either arm produced. The counts above were recorded at the time and are unaffected. Answers are now kept for 180 days.
Other measured skills in the registry, with their headline benchmark lift.