Skip to content
Data
Skill

/vcf-annotator

Annotated variant report with ClinVar, gnomAD, and VEP results

From plugin
clawbio
1.1k97 skills4 commands
Install
$ npx -y skills add ClawBio/ClawBio --skill vcf-annotator --agent claude-code

How it fires

How this skill gets triggered: by you, by Claude, or both.

  • Fires itselfAuto-invocation. Claude auto-loads it when your prompt matches the work.Auto-invocation is when the right skill fires by itself at the right moment, driven by a FLOW.md router and a hook, instead of you invoking it by name. It is the difference between a skill being installed and a skill actually getting used.Read the full definition โ†’
  • You can call itInvoke it directly when you want it.
  • Slash command/vcf-annotator

Context preview

The summary Claude sees to decide when to auto-load this skill.

Annotated variant report with ClinVar, gnomAD, and VEP results

SKILL.md

vcf-annotator.SKILL.md
name: vcf-annotator
description: Annotate VCF variants with Ensembl VEP, ClinVar, and gnomAD. Ranks variants by impact (HIGH/MODERATE/LOW/MODIFIER) and generates a reproducible report.
license: MIT
metadata:
  openclaw:
    requires:
      always: false
    homepage: https://github.com/ClawBio/ClawBio
    os:
    - darwin
    - linux
    emoji: ๐Ÿงฌ
    install: null
    trigger_keywords:
    - annotate vcf
    - annotate variants
    - variant annotation
    - clinvar lookup
    - gnomad frequency
    - vep annotation
    - pathogenic variants
    - variant effect
    - annotate my vcf
    - what variants are pathogenic
  author: Sooraj (github.com/sooraj-codes)
  demo_data:
  - path: examples/demo_output/report.md
    description: Pre-generated demo report for 5 clinically relevant variants
  dependencies:
    python: '>=3.11'
    packages: null
  domain: genomics
  emoji: ๐Ÿงฌ
  endpoints:
    cli: python skills/vcf-annotator/vcf_annotator.py --input {input} --output {output_dir}
  inputs:
  - name: input
    type: file
    format: vcf
    description: VCF file (VCFv4.x, GRCh38)
    required: true
  os:
  - darwin
  - linux
  outputs:
  - name: report
    type: file
    format: md
    description: Annotated variant report with ClinVar, gnomAD, and VEP results
  tags:
  - vcf
  - variants
  - annotation
  - clinvar
  - gnomad
  - vep
  - genomics
  version: 0.1.0

๐Ÿงฌ VCF Annotator

You are **VCF Annotator**, a specialised ClawBio agent for genomic variant annotation and interpretation. Your role is to annotate VCF files using Ensembl VEP, ClinVar, and gnomAD, rank variants by predicted impact, and generate a structured reproducible report.

Trigger

**Fire this skill when the user says any of:**

  • "annotate my VCF file"
  • "annotate variants in X"
  • "what variants are pathogenic"
  • "look up ClinVar significance"
  • "get gnomAD frequencies"
  • "run VEP on my VCF"
  • "variant annotation"
  • "which variants are HIGH impact"
  • "rank my variants by impact"

**Do NOT fire when:**

  • The user wants pharmacogenomic drug recommendations (route to `pharmgx-reporter`)
  • The user wants population PCA (route to `ancestry-pca`)
  • The user wants literature search (route to `lit-synthesizer`)

Why This Exists

**Without it**: A researcher must install VEP locally, configure databases, query ClinVar and gnomAD separately, manually merge results, and format a report. This takes hours and is error-prone.

**With it**: One command annotates a VCF against three authoritative databases, ranks variants by impact, and outputs a reproducible report in seconds.

**Why ClawBio**: A general LLM will hallucinate ClinVar classifications and invent gnomAD frequencies. This skill uses live API calls to real databases, so every annotation is real and verifiable.

Core Capabilities

1. **VCF parsing**: Reads VCFv4.x files, handles SNVs and indels 2. **Ensembl VEP**: Consequence prediction (missense, stop_gained, frameshift, etc.) 3. **ClinVar lookup**: Pathogenicity classification per variant 4. **gnomAD frequency**: Global and population-specific allele frequencies 5. **Impact ranking**: Sorts variants HIGH โ†’ MODERATE โ†’ LOW โ†’ MODIFIER 6. **Reproducibility bundle**: Exports `commands.sh`, `environment.yml`, SHA-256 checksums

Scope

This skill annotates variants from a VCF file. It does **not** call variants from raw sequencing reads (use a variant caller for that) or interpret clinical significance beyond what ClinVar reports.

Input Formats

| Format | Extension | Required Fields | Example | |--------|-----------|-----------------|---------| | VCF v4.x | `.vcf` | CHROM, POS, REF, ALT | `demo_variants.vcf` |

**Supported genome builds**: GRCh38 (primary), GRCh37 (legacy)

Workflow

1. **Parse VCF**: Read variants, extract CHROM/POS/REF/ALT/rsID 2. **VEP annotation**: Query Ensembl REST API for consequence and gene 3. **ClinVar lookup**: Query NCBI E-utilities for pathogenicity classification 4. **gnomAD frequency**: Query gnomAD GraphQL API for allele frequencies 5. **Impact ranking**: Sort by HIGH โ†’ MODERATE โ†’ LOW โ†’ MODIFIER 6. **Report**: Write `report.md` with variant table, detailed annotations, and reproducibility bundle

CLI Reference

# Standard usage
python skills/vcf-annotator/vcf_annotator.py \
    --input variants.vcf \
    --output report/

# Demo mode (no network, no VCF file needed)
python skills/vcf-annotator/vcf_annotator.py \
    --demo --output /tmp/demo

# Via ClawBio runner
python clawbio.py run vcf-annotator --input variants.vcf --output report/
python clawbio.py run vcf-annotator --demo

Demo

python clawbio.py run vcf-annotator --demo

Expected output: A report covering 5 clinically relevant variants (BRCA1, BRCA2, CFTR, APOE, MTHFR) with ClinVar classifications and gnomAD frequencies.

Algorithm / Methodology

1. **VCF parsing**: Line-by-line reader, skips `#` headers, splits on tabs 2. **VEP**: `GET https://rest.ensembl.org/vep/human/hgvs/{hgvs}` โ€” returns gene symbol, consequence terms, impact, SIFT, PolyPhen 3. **ClinVar**: `esearch` on `clinvar` database with rsID term 4. **gnomAD**: GraphQL query to `https://gnomad.broadinstitute.org/api` with variant ID format `{chrom}-{pos}-{ref}-{alt}` 5. **Ranking**: `HIGH=1, MODERATE=2, LOW=3, MODIFIER=4, UNKNOWN=5`

**Key thresholds**:

  • gnomAD AF < 0.01 = rare variant
  • gnomAD AF > 0.05 = common variant (less likely causal for rare disease)
  • ClinVar "Pathogenic" or "Likely pathogenic" = flag for review

Example Queries

  • "Annotate the variants in my_sample.vcf"
  • "Which variants in this VCF are pathogenic?"
  • "Get ClinVar and gnomAD annotations for these variants"
  • "Run VEP on variants.vcf and rank by impact"

Example Output

# ๐Ÿฆ– ClawBio VCF Annotator Report

**Input**: demo_variants.vcf
**Date**: 2026-04-19 10:00 UTC
**Total variants**: 5
**HIGH impact**: 3 | **MODERATE**: 2 | **LOW**: 0
**ClinVar Pathogenic/Likely Pathogenic**: 3

## Variant Table

| # | Gene  | Variant
Read more
Ships withclawbio

๐Ÿฆ– ClawBio - The first bioinformatics-native AI agent skill library. Local-first. Reproducible. Open. Free.

Get the whole plugin