How to Use gnomAD gene variation search in opencode
Returns observed DNA changes in a gene with population frequencies and consequence annotations. Use it to build a shortlist of rare, missense, or predicted loss-of-function alleles before inspecting individual sites.
Prompts to try with gnomAD gene variation search in opencode
Copy an example into opencode, or ask in your own words.
Use gnomAD gene variation search to find CFTR missense alleles with frequencies below 0.001, then write their returned annotations and counts to a CSV in this project.
Use gnomAD gene variation search for PCSK9 to collect high-confidence predicted loss-of-function alleles and build a table for the project's target research notebook.
Use gnomAD gene variation search for BRCA1 to retrieve synonymous alleles with frequencies above 0.001 and save their positions, consequences, and returned frequencies as a research fixture.
Use gnomAD gene variation search to look this up and give me the result as a table. Save the result in ./assets.
Pull the latest numbers from gnomAD gene variation search and tell me what changed since last week.
How to set up gnomAD gene variation search in opencode
Pick the way that suits you. Each takes about two minutes.
Use Spiral's MCP server
- Add the server
Leave out --global to add Spiral to the current project only. No header and no client ID or secret: opencode registers itself with Spiral.
opencode mcp add spiral --global --url https://api.spiral.ai/mcp
- Sign in
Your browser opens. Sign in to Spiral, pick the organization and click Authorize, then return to the terminal. No API key. Inside opencode, /mcps starts the same sign-in.
opencode mcp auth spiral
- Check it
Spiral shows as connected.
opencode mcp list
Use the Spiral skill
- Send opencode this message
Your agent reads Spiral's skill and sets itself up.
set up https://spiral.ai/SKILL.md
- Sign in or paste a key
Approve Spiral in the browser, or give the agent a key from the console.
Use the Spiral CLI
- Install and sign in
Installs the Spiral CLI, signs you in and adds its skill to your coding agents.
npx -y spiral-cli@latest init
Call the Spiral API
- Create an API key
In the console, under API keys.
- Run gnomAD gene variation search
One request; the result comes back by polling or a webhook.
curl https://api.spiral.ai/v1/runs \ -H "Authorization: Bearer $SPIRAL_API_KEY" \ -H "Content-Type: application/json" \ -H "Idempotency-Key: $(uuidgen)" \ -d '{ "provider": "alexandria", "model": "gnomad-broadinstitute-org/variants/search", "input": { "gene": "<gene>" } }'
Then paste one of the prompts above: opencode finds gnomAD gene variation search on Spiral, shows the price and runs it.
gnomAD gene variation search providers and prices
Spiral runs gnomAD gene variation search through Alexandria. Open a card for today's price, with every fee included.
$0.00873 per call.
Settings you can ask for
Ask opencode for any of these in your prompt.
| Setting | Allowed values | Default | Description |
|---|---|---|---|
| Sort | position or af_desc | position | position (genomic order) or af_desc (most common first). |
| Limit | 1 to 100 | 25 | Variants per page. |
| Max af | 0 to 1 | Keep variants with at most this allele frequency. | |
| Min af | 0 to 1 | Keep variants with at least this allele frequency. | |
| Offset | 0 to 150000 | 0 | Matching variants to skip. |
| Dataset | gnomad_r4, gnomad_r3, or gnomad_r2_1 | gnomad_r4 (v4.1, 730,947 exomes and 76,215 genomes, GRCh38; the default), gnomad_r3 (v3.1.2, 76,156 genomes, GRCh38) or gnomad_r2_1 (v2.1.1, 125,748 exomes and 15,708 genomes, GRCh37). Defaults to the dataset of a pasted browser URL, else gnomad_r4. | |
| Loftee hc only | on or off | Keep only LOFTEE high-confidence pLoF variants. |
Every API field of Population allele frequencies and gene constraint (Broad Institute) · Search is on its tool page: open its card above.
What can you do with gnomAD gene variation search in opencode?
Build a gene review table that joins gnomAD population counts to the project's research candidates. Keep genetic ancestry breakdowns and exome versus genome evidence available for inspection alongside each selected allele.
Build a rare-allele research shortlist
Survey CFTR for rare coding changes, then inspect individual sites for population frequencies and homozygote counts before selecting candidates for further research.
Review predicted loss-of-function evidence
Find predicted loss-of-function alleles in PCSK9 and examine their population counts. Keep the confidence annotations beside the frequency evidence when preparing a target research brief.
Check ancestry-specific enrichment
Start with observed changes in HBB, then compare genetic ancestry frequencies for selected alleles. Identify cases where an overall frequency hides a much higher frequency in one ancestry group.
Prepare a functional assay panel
Find missense alleles in BRCA1 within a chosen frequency range, then inspect population and homozygote counts for the proposed assay candidates.
Refresh a gene evidence report
Rerun a SCN2A search after a gnomAD release change and revisit selected allele frequencies. Report changes in the research shortlist separately from changes in population counts.
Investigate conflicting population evidence
Review a gene's observed alleles, then inspect selected sites for differences between exome and genome frequencies. Highlight discordance before combining the evidence in a research report.
More on gnomAD gene variation search and opencode
Overview
gnomAD gene variation search in other agents
Questions about gnomAD gene variation search in opencode
Can opencode use gnomAD gene variation search?
Yes. Add Spiral to opencode as an MCP server, and opencode can find and run gnomAD gene variation search like any built-in tool.
How much does gnomAD gene variation search cost in opencode?
$0.00873 per call. You pay from your Spiral balance as you go, with no subscription, and a failed run is not charged. Your opencode plan is separate.
Do I need an Alexandria account to use gnomAD gene variation search in opencode?
No. Spiral runs gnomAD gene variation search on its own Alexandria account. You sign in to Spiral once and never paste a key.
How long does it take to set up gnomAD gene variation search in opencode?
About two minutes: add the server, then sign in, then check it.
Does opencode wait while gnomAD gene variation search runs?
gnomAD gene variation search runs in the background. opencode starts the run, checks on it and gives you the json when it's ready.
How large is the gnomAD reference?
The v4 reference contains 730,947 exomes and 76,215 genomes on GRCh38. These are aggregate research data from contributing sequencing projects.
Are the ancestry frequencies representative of everyone?
gnomAD reports frequencies by inferred genetic ancestry group, but representation is uneven. The proportion of European ancestry samples is higher in v4 than in earlier releases, partly because of UK Biobank inclusion.
Can annotations change between gnomAD releases?
Yes. In v4.1.1, gnomAD changed LOFTEE's GERP distance threshold to 0.0 and reannotated predicted loss-of-function confidence, so a release change can alter a shortlist even without a new population count.
Does a missing count mean an allele was never observed?
A No data flag means no defined genotypes were available for that sequencing data type. AC0 has a different meaning: the allele count became zero after low-quality genotypes were removed.
Why can exome and genome frequencies disagree?
gnomAD explicitly tests for frequency differences between those datasets. Its v4.1 discordance warning uses a contingency-table or CMH test p-value below 0.0001.
Start using gnomAD gene variation search in opencode
One Spiral account for every tool your agent needs. No subscription; you pay per run.
Paste this into opencode:
set up https://spiral.ai/SKILL.md


