biothings / biothings_explorer

TRAPI service for BioThings Explorer
https://explorer.biothings.io
Apache License 2.0
10 stars 11 forks source link

annotate MonarchAPI endpoints for "diseases/phenotypes associated with orthologs of a gene" #566

Closed andrewsu closed 1 year ago

andrewsu commented 1 year ago

We previously explored in https://github.com/biothings/BioThings_Explorer_TRAPI/issues/237 the possibility of incorporating model organism data into TRAPI queries by adding one explicit edge from a human gene to an ortholog, and another explicit edge from that ortholog to other entities (like related diseases and/or phenotypes). That route proved cumbersome, because people generally did not know that they could/should explicitly add those edges to their query.

We could revisit that strategy by adding new templates to our creative mode implementation. Alternatively, we could utilize the Monarch API endpoint that goes directly from a gene to the diseases and phenotypes related to orthologs of that gene.

https://api.monarchinitiative.org/api/bioentity/gene/NCBIGene%3A695/ortholog/phenotypes?rows=100&facet=false&unselect_evidence=false&exclude_automatic_assertions=false&fetch_objects=false&use_compact_associations=false&direct=false&direct_taxon=false https://api.monarchinitiative.org/api/bioentity/gene/NCBIGene%3A695/ortholog/diseases?rows=100&facet=false&unselect_evidence=false&exclude_automatic_assertions=false&fetch_objects=false&use_compact_associations=false&direct=false&direct_taxon=false

NOTE: the "diseases" endpoint appears to not be returning results for any gene at the moment.

Annotating these Monarch API endpoints would give BTE direct edges between human genes and phenotypes/diseases which will simplify the incorporation of model organism data into BTE. (Care must be taken in the modeling of the predicate and evidence.)

colleenXu commented 1 year ago

Added operations for both of these endpoints:

The operations use the "related_to" predicate and the gene-homolog-intermediates are recorded in the edge-attributes. This perhaps isn't ideal / completely "biolink-model" compliant though.

I refreshed Biolink/Monarch API's registration, and BTE has automatically ingested these changes. So the examples below now work.

Note that these operations are one-way; there doesn't seem to be corresponding disease->gene and phenotype->gene endpoints. I also couldn't get the same kind of info from querying the disease->gene, disease->model, and phenotype->gene endpoints.


Example for human-gene -> disease through non-human-gene ortholog ``` { "message": { "query_graph": { "nodes": { "n0": { "categories": ["biolink:Gene"], "ids": ["HGNC:9508"] }, "n1": { "categories": ["biolink:Disease"] } }, "edges": { "e01": { "subject": "n0", "object": "n1" } } } } } ```
Will get an edge to `MONDO:0006559` (hidradenitis suppurativa) through this new x-bte operation ``` "417589ff315b0fa93b5f7239197c681b": { "predicate": "biolink:related_to", "subject": "NCBIGene:5663", "object": "MONDO:0006559", "attributes": [ { "attribute_type_id": "biolink:primary_knowledge_source", "value": [ "infores:monarchinitiative" ], "value_type_id": "biolink:InformationResource" }, { "attribute_type_id": "biolink:aggregator_knowledge_source", "value": [ "infores:biothings-explorer", "infores:biolink-api" ], "value_type_id": "biolink:InformationResource" }, { "attribute_type_id": "biolink:publications", "value": [ "PMID:19029536" ] }, { "attribute_type_id": "homologous_gene_model_id", "value": [ "WormBase:WBGene00004769", "WormBase:WBGene00001985" ] }, { "attribute_type_id": "homologous_gene_model_name", "value": [ "sel-12", "hop-1" ] }, { "attribute_type_id": "monarch_source_database", "value": [ "https://archive.monarchinitiative.org/#wormbase" ] }, { "attribute_type_id": "biolink:original_predicate", "value": [ "has role in modeling" ] } ] }, ```
Example for human-gene -> phenotype through non-human-gene ortholog ``` { "message": { "query_graph": { "nodes": { "n0": { "categories": ["biolink:Gene"], "ids": ["HGNC:8548"] }, "n1": { "categories": ["biolink:PhenotypicFeature"] } }, "edges": { "e01": { "subject": "n0", "object": "n1" } } } } } ```
Will get an edge to `HP:0003540` (Impaired platelet aggregation) through this new x-bte operation ``` "120483b256a36ca96a36824bef8cab65": { "predicate": "biolink:related_to", "subject": "NCBIGene:5034", "object": "HP:0003540", "attributes": [ { "attribute_type_id": "biolink:primary_knowledge_source", "value": [ "infores:monarchinitiative" ], "value_type_id": "biolink:InformationResource" }, { "attribute_type_id": "biolink:aggregator_knowledge_source", "value": [ "infores:biothings-explorer", "infores:biolink-api" ], "value_type_id": "biolink:InformationResource" }, { "attribute_type_id": "biolink:publications", "value": [ "PMID:26529254" ] }, { "attribute_type_id": "homologous_gene_model_id", "value": [ "MGI:97464" ] }, { "attribute_type_id": "homologous_gene_model_name", "value": [ "P4hb" ] }, { "attribute_type_id": "monarch_source_database", "value": [ "https://archive.monarchinitiative.org/#mgislim" ] }, { "attribute_type_id": "biolink:original_predicate", "value": [ "has phenotype" ] } ] }, ```
andrewsu commented 1 year ago

Note that Kevin Schaper added some additional info in this thread https://ncatstranslator.slack.com/archives/C014B3JAX36/p1678312101989449?thread_ts=1678308576.260219&cid=C014B3JAX36. Based on that, I don't think we can easily incorporate the reverse direction in the near term. So unless this issue is being held open for a different reason, I think we should close it as "complete enough for now".

colleenXu commented 1 year ago

Okay. Sounds like they are working on a replacement for the current biolink-api...so in the future, we may want to look into that.