biothings / biothings_explorer

TRAPI service for BioThings Explorer
https://api.bte.ncats.io
Apache License 2.0
8 stars 9 forks source link

Update to Biolink 2.1.0 #207

Closed colleenXu closed 2 years ago

colleenXu commented 3 years ago

Translator has a compliance deadline of July 1st for "Biolink 2.0.2" for KPs/ARAs.

I'm not sure of all the code that needs to be changed, but this update probably involve changes to:


What does an update mean?

colleenXu commented 3 years ago

PRs to merge to move to v2.1.0:

[EDIT: 7/29 for biolink-model module fix]

BTE JS tool code updates (branch biolink_v2.1 for all):

After code in BTE JS tools is updated/deployed:

Merge these PRs for registry files or contact Ryan Roper (multiomics provider) to merge PRs. All on branches named biolink_v2.1

colleenXu commented 3 years ago

@newgene @andrewsu check how BTE is loading the biolink model (which yaml).

If it's loading something older/cached, we will want it to get the latest biolink model yaml off of master when we do the update to v2.0.

andrewsu commented 3 years ago

@colleenXu I think you're right. In https://github.com/biothings/bte_trapi_query_graph_handler/blob/main/src/biolink.js#L9, looks like Biolink model is being loaded from this cached version https://github.com/biothings/bte_trapi_query_graph_handler/blob/main/src/biolink.json.

colleenXu commented 3 years ago

[UPDATE: this bug is fixed; there's another bug now...]

The Architecture call confirmed that we should move to v2.1.0.


@newgene to review BTE code to see where else we need to update. Notes for Chunlei below:

I encountered this error after:

The error messages I get are below:

[nodemon] starting `node src/server.js`
  bte:biothings-explorer-trapi:EdgeReverse BioLink-model class is initiated. +0ms
/Users/jay/Desktop/bte-trapi-workspace/packages/biolink-model/built/object/entity_object.js:22
            this._id_prefixes = [...['UMLS'], ...idPrefixes];
                                                 ^

TypeError: idPrefixes is not iterable
    at Entity.set id_prefixes [as id_prefixes] (/Users/jay/Desktop/bte-trapi-workspace/packages/biolink-model/built/object/entity_object.js:22:50)
    at new Entity (/Users/jay/Desktop/bte-trapi-workspace/packages/biolink-model/built/object/entity_object.js:11:26)
    at BioLinkClassTree.addNewObjectToTree (/Users/jay/Desktop/bte-trapi-workspace/packages/biolink-model/built/tree/class_tree.js:18:53)
    at /Users/jay/Desktop/bte-trapi-workspace/packages/biolink-model/built/tree/base_tree.js:31:63
    at Array.map (<anonymous>)
    at BioLinkClassTree.construct (/Users/jay/Desktop/bte-trapi-workspace/packages/biolink-model/built/tree/base_tree.js:31:44)
    at BioLink.loadSync (/Users/jay/Desktop/bte-trapi-workspace/packages/biolink-model/built/index.js:28:34)
    at new BioLinkModel (/Users/jay/Desktop/bte-trapi-workspace/packages/@biothings-explorer/query_graph_handler/built/biolink.js:10:26)
    at Object.<anonymous> (/Users/jay/Desktop/bte-trapi-workspace/packages/@biothings-explorer/query_graph_handler/built/biolink.js:40:30)
    at Module._compile (internal/modules/cjs/loader.js:1063:30)


After discussion with @andrewsu, We want to map operations with ambiguous IDs (like MESH/UMLS) to SmallMolecule for now - even when that isn't always the most "accurate" semantic class for those IDs. This allows queries with SmallMolecule or ChemicalEntity to use those operations. [note: SEMMED api updates will use the new Biolink model version - see Sander for details]


See the deadline tracker here (probably need to be registered in ncats translator google permissions).

colleenXu commented 2 years ago

All PRs are merged; this update should be basically complete.

However, there may still be some tests/examples/README/saved-example-jsons that could be updated...

colleenXu commented 2 years ago

Closing issue:

I have reviewed tests/examples/README/saved-example-jsons in all the bte-trapi-workspace repos.

Note: