vimalinx/bio-agent / .claude/skills/vcf-query
vcf-query
UnverifiedUse when extracting and formatting specific fields from compressed VCF files, querying variants by region, or generating custom tabular output with genotype and INFO data.
vcf-query
Quick Start
- Command:
vcf-query [OPTIONS] file.vcf.gz - Local executable:
/home/vimalinx/miniforge3/envs/bio/bin/vcf-query - Full reference: See
references/help.md
When To Use This Tool
- Extract selected VCF fields into a custom tabular report.
- Loop over per-sample genotype fields with bracket expressions.
- Run quick region-restricted queries on an indexed
.vcf.gz. - Keep using it only if you already depend on the vcftools Perl utility; for new workflows, prefer
bcftools query.
Common Patterns
# 1) Extract core variant fields plus depth
vcf-query \
file.vcf.gz \
-f '%CHROM\t%POS\t%REF\t%ALT\t%INFO/DP\n'
# 2) Emit per-sample genotype information
vcf-query \
file.vcf.gz \
-f '%CHROM:%POS[\t%SAMPLE=%GT]\n'
# 3) Restrict output to a region
vcf-query \
file.vcf.gz \
-r 1:1000-2000 \
-f '%CHROM\t%POS\t%FILTER\n'
Recommended Workflow
- Start by listing available columns with
-lif the file provenance is unclear. - Build the output format string deliberately with
%INFO/TAG,%GT,%SAMPLE, and bracket loops when sample iteration is needed. - Restrict to a genomic interval with
-ronly when the file is properly indexed. - Redirect output to a file or pipe it into downstream table-processing tools.
Guardrails
- Input files are expected to be compressed VCFs, and region queries require tabix indexing.
- This script is explicitly marked upstream as not being supported in the future; prefer
bcftools queryfor durable pipelines. - The default format string already loops over samples, so be explicit with
-fif you want predictable output. -c/--columnscan take either a comma-separated list or a file of one column name per line.
Related skills
| Skill | Stars | Updated | Works with | Status | Install |
|---|---|---|---|---|---|
| slack-gif-creatoranthropics/skillsKnowledge and utilities for creating animated GIFs optimized for Slack. Provides constraints, validation tools, and animation concepts. Use when users request animated GIFs for Slack like "make me a GIF of X doing Y for Slack." | Stars: 196k | Updated | Claude CodeCodex | Verified | Install |
| ponytailDietrichGebert/ponytailLazy senior dev mode for any coding task: the smallest change that fully solves it, and a reply a busy human understands in one read. | Stars: 192k | Updated | Claude CodeCodex | Verified | Install |
| ponytail-debtDietrichGebert/ponytailHarvest every shortcut: comment into one debt ledger, so deferrals get tracked instead of forgotten. One-shot report. | Stars: 192k | Updated | Claude CodeCodex | Verified | Install |
| ponytail-debtDietrichGebert/ponytailList every `shortcut:` comment (and older `ponytail:` ones) as a debt ledger. One-shot report, changes nothing. Use for "ponytail debt", "what did ponytail defer", "list the shortcuts", /ponytail-debt. | Stars: 192k | Updated | Claude CodeCodex | Verified | Install |