Search human variants (TogoVar)
togovar_search_variantSearch human genome variants by population frequency, clinical significance, consequence, gene, disease, or genomic region, and optionally return aggregate counts.
Instructions
Search TogoVar for human genome variants with population frequencies.
TogoVar integrates allele frequencies from gnomAD, ToMMo (Japanese), NCBN, GEM-J, JGA, BioBank Japan, and JoGo, plus ClinVar + MGeND clinical significance and SIFT/PolyPhen/AlphaMissense predictions — data with no SPARQL counterpart elsewhere in TogoMCP.
All filters are optional and combined with AND. Supply zero filters to browse; but scope tightly — the database holds ~1.2 billion variants.
COUNTS: total is the size of the whole REST backend (1,229,026,068 on
2026-10-09) and is constant across queries; filtered is the count matching
your filters. TogoMCP's togovar SPARQL graph is now about the same size
(1,227,614,941), but the two are not the same set, so do not expect a REST
count and a SPARQL COUNT to agree to the last variant.
PAGING: an INTEGER offset is capped at offset + limit <= 10,000 (HTTP 400
beyond). To page further, use keys: every full page (as many rows as limit)
returns next_offset, the [chromosome, position, reference, alternate] key of
its last row. Pass it back unchanged as offset with the same filters to get the
rows strictly after it, sorted by position — no 10,000 cap. A page shorter than
limit is the last one and carries no next_offset.
STATISTICS SCOPE (stat=True): all facets are scoped to the filtered set and
count VARIANTS, but a variant can fall under several values. type counts
each variant once (sums to filtered); dataset once per cohort;
consequence once per consequence term on any of its transcripts;
significance once per classification label in any of its records (any
condition or submitter). So each value is <= filtered, but consequence/
significance SUMS exceed it, and adding labels (P + LP) double-counts
variants that carry both. See statistics_caveats for the per-facet rule.
ROUND-TRIP TO SPARQL: use variant_iri — it is the subject IRI in the
togovar SPARQL graph and is present on every row except one with a very
long allele. Do NOT gate on tgv_id: most variants have none (it is null),
and they are in SPARQL all the same. About 0.1% of REST variants have no
SPARQL node, so an empty result for one IRI is possible and is not an error.
TWO-STEP WORKFLOW for gene/disease filters:
1. search_gene("ALDH2") -> hgnc_id -> pass as gene_hgnc_id.
2. search_disease("breast cancer") -> mondo_id -> pass as disease_id.
Tool call template
This tool declares no required parameters. Add optional parameters from the input schema as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {},
"name": "togovar_search_variant"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| stat | No | If True, also return match counts (`total`, `filtered`) and the aggregate breakdown (counts by dataset, type, consequence, significance). REQUIRED to get a count — e.g. "how many variants match". Left False by default because computing the aggregation is the slow part of the query; use stat=False when you only need rows. See STATISTICS SCOPE above — every facet is scoped to the filtered set, but they count at different granularities, so only `type` sums to `filtered`. | |
| stop | No | Region end, 1-based inclusive. REQUIRES `chromosome`. Pair with `start`; mutually exclusive with `position`. | |
| limit | No | Max variant rows to return, in [0, 1000]. Default 100. | |
| start | No | Region start, 1-based inclusive. REQUIRES `chromosome`. Pair with `stop`; mutually exclusive with `position`. | |
| offset | No | Rows to skip (int, offset + limit <= 10,000), OR the `next_offset` array [chromosome, position, reference, alternate] from the previous page, which pages past 10,000. | |
| tgv_id | No | TogoVar variant ID(s), e.g. "tgv16331". | |
| dataset | No | Frequency panel for a frequency filter, e.g. "gnomad_genomes", "gnomad_exomes", "tommo", "tommo_jsv1", "ncbn", "gem_j_wga", "jga_wes", "jga_snp", "bbj1k", "bbj2k", "jogo". Sub-populations allowed (e.g. "gnomad_genomes.eas", "ncbn.jpn", "jga_wgs.jgad000758"). Two names that look valid match nothing: the bare "bbj_riken" is rejected (use "bbj1k"/"bbj2k"), and a filter on the bare "jga_wgs" returns 0 variants although rows report it — filter on "jga_wgs.jgad000758" or "jga_wgs.jgad000868" instead (verified 2026-10-09). | |
| position | No | Single 1-based site (mutually exclusive with start/stop). | |
| chromosome | No | "1"-"22", "X", "Y", "MT". Required for a positional filter. | |
| disease_id | No | MONDO ID(s) (e.g. "MONDO_0007254") or MedGen CUI(s) from `search_disease`. | |
| consequence | No | SO consequence term or label, e.g. "missense_variant", "stop_gained", "frameshift_variant". | |
| gene_hgnc_id | No | HGNC ID (integer) from `search_gene` (NOT a symbol). | |
| variant_type | No | "SNV", "INS", "DEL", "INDEL" (delins) or "MNV" (substitution), any case, or the SO accession (e.g. "SO_0001483"). | |
| max_frequency | No | Maximum allele frequency in [0, 1], applied to the cohort named by `dataset`. E.g. dataset='tommo', max_frequency=0.01 for rare-in-Japan. | |
| min_frequency | No | Minimum allele frequency in [0, 1], applied to the cohort named by `dataset` — set `dataset` too, or the bound has no panel to apply to. | |
| disease_source | No | Restrict disease link source(s): "clinvar", "mgend". | |
| include_transcripts | No | If True, add a `transcripts` list to each row with the per-transcript VEP annotation the REST backend already carries: transcript/gene IDs, SO consequence(+labels), HGVS c/p/g, and per-transcript SIFT/PolyPhen/AlphaMissense. Default False — a variant in a transcript-dense locus (e.g. BRCA1) can carry 400+ transcript annotations, which would dominate the response. Note this means HGVS and per-transcript predictions do NOT require a SPARQL round-trip. | |
| significance_source | No | Restrict significance source(s): "clinvar", "mgend". | |
| include_full_alleles | No | If True, return full REF/ALT sequences even for large structural variants. Default False summarizes alleles over ~50 bp as "<head>…(<n> bp)" to keep the response inline-readable; `ref_length`/`alt_length` always give the true lengths. | |
| clinical_significance | No | e.g. "pathogenic", "likely_pathogenic", "benign", "uncertain_significance", "risk_factor". |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |