Get Gene Homologs
ensembl_get_homologyFind orthologs and/or paralogs of a gene across species. Returns each homolog's stable ID, species, homology type (ortholog_one2one, ortholog_one2many, paralog_many2many, etc.), percId and percPos (percent identical and positive positions, over the target protein's length), and taxonomy level. Essential for cross-species research — for example, "what is the mouse equivalent of human TP53?" or "how conserved is BRCA2 across mammals?". Provide either symbol + species or a stable gene ID. Target species can be filtered to a single species or left open to return all available homologs. Homologs keep Ensembl's own order, which starts with the closest relatives, and are returned max_results at a time (default 25); totalCount reports every homolog, and when more follow, nextOffset is the offset for the next page. A target_species outside the comparison Ensembl runs for the source species is answered from Ensembl's pan-taxonomic comparison when that comparison holds both species. Includes targetProteinId when available for ensembl_get_sequence with type="protein". targetSymbol is best-effort: a secondary gene lookup shares ten seconds across the returned rows and the remaining call deadline; missing names never remove homologs.
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": "ensembl_get_homology"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| id | No | Ensembl stable gene ID (e.g. ENSG00000139618). A version suffix (ENSG00000139618.17) is accepted and dropped before the query. Use ensembl_lookup_gene to get the stable ID from a symbol. Cannot be combined with symbol. | |
| type | No | Type of homologs to return. orthologues: genes related by speciation (cross-species equivalents). paralogues: genes related by duplication (within or across species). all: both orthologs and paralogs. | orthologues |
| offset | No | 0-based position in Ensembl's homolog order where the returned page starts. Default 0. Pass nextOffset from a previous response to fetch the following page; an offset at or past totalCount returns no homologs. | |
| symbol | No | Gene symbol in the source species (e.g. BRCA2, TP53). Species defaults to homo_sapiens; set species for other organisms. Cannot be combined with id. | |
| species | No | Source species (the species the query gene belongs to) in Ensembl internal format. Default is homo_sapiens. Use ensembl_list_species with nameContains (a genus or common name, e.g. mouse) to find valid values. | homo_sapiens |
| max_results | No | Maximum number of homologs to return, counted from offset. Default 25. Broad orthology queries (e.g. BRCA2 across all species) can return 150+ homologs. Set to 0 to return every homolog from offset to the end, uncapped. totalCount always reports the full number available before offset and this cap. | |
| target_species | No | Filter to homologs in a single target species (e.g. mus_musculus for mouse). Omit to return homologs across all available species. Use ensembl_list_species with nameContains (a genus or common name) to find valid values. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| cap | No | The max_results limit applied to this page. | |
| error | No | Present when the call failed. Absent on success. | |
| shown | No | Number of homologs returned on this page. | |
| notice | No | Guidance when the homologs come from Ensembl's pan-taxonomic comparison, no homologs are found, the offset is past the end, more homologs follow this page, or symbol enrichment is incomplete. | |
| queryId | No | The resolved Ensembl gene ID used for the homology query. | |
| homologs | No | Homologous genes for the query gene, in Ensembl's order: at most max_results entries starting at offset. | |
| queryType | No | The homology type queried (orthologues, paralogues, or all). | |
| truncated | No | True when more homologs follow this page; request nextOffset to continue. | |
| nextOffset | No | Offset of the first homolog after this page — pass it as offset to fetch the next page. Present only when more homologs follow. | |
| totalCount | No | Total number of homologs available before offset and the max_results cap. Exceeds the returned homologs count when the list was paged. | |
| querySpecies | No | The source species used for the query. |