@@ -226,9 +226,8 @@ def run(self, data_file: Union[Optional[Path], Optional[str]] = None, show_statu
226226 )
227227 if metabolism :
228228 # create metabolism node and edge to tax_id
229- # use `biolink equivalent` for 'category' and
230- # for 'predicate', `biolink equivalent` from properties
231- category = metabolism .get ("biolink_equivalent" , METABOLISM_CATEGORY )
229+ # use biolink_equivalent URL from METPO tree traversal or fallback to default
230+ category = metabolism .get ("inferred_category" , METABOLISM_CATEGORY )
232231 predicate_biolink = metabolism .get ("predicate_biolink_equivalent" , "" )
233232 # fallback: if no biolink equivalent use `biolink:has_phenotype`
234233 if predicate_biolink :
@@ -267,9 +266,8 @@ def run(self, data_file: Union[Optional[Path], Optional[str]] = None, show_statu
267266 # print(f"Pathway: {pathway}, METPO mapping: {metpo_mapping}")
268267 if metpo_mapping :
269268 # create pathway node and edge to tax_id
270- # use `biolink equivalent` for 'category' and
271- # for 'predicate', `biolink equivalent` from properties
272- category = metpo_mapping .get ("biolink_equivalent" , PATHWAY_CATEGORY )
269+ # use biolink_equivalent URL from METPO tree traversal or fallback to default
270+ category = metpo_mapping .get ("inferred_category" , PATHWAY_CATEGORY )
273271 predicate_biolink = metpo_mapping .get (
274272 "predicate_biolink_equivalent" , ""
275273 )
@@ -365,10 +363,9 @@ def run(self, data_file: Union[Optional[Path], Optional[str]] = None, show_statu
365363 # print(f"Substrate: {substrate}, METPO mapping: {metpo_mapping}")
366364 if metpo_mapping :
367365 # create carbon substrate node and edge to tax_id
368- # use `biolink equivalent` for 'category' and
369- # for 'predicate', `biolink equivalent` from properties
366+ # use biolink_equivalent URL from METPO tree traversal or fallback to default
370367 category = metpo_mapping .get (
371- "biolink_equivalent " , CARBON_SUBSTRATE_CATEGORY
368+ "inferred_category " , CARBON_SUBSTRATE_CATEGORY
372369 )
373370 predicate_biolink = metpo_mapping .get (
374371 "predicate_biolink_equivalent" , ""
@@ -462,9 +459,8 @@ def run(self, data_file: Union[Optional[Path], Optional[str]] = None, show_statu
462459 # print(f"Cell shape: {cell_shape}, METPO mapping: {metpo_mapping}")
463460 if metpo_mapping :
464461 # create cell shape node and edge to tax_id
465- # use `biolink equivalent` for 'category' and
466- # for 'predicate', `biolink equivalent` from properties
467- category = metpo_mapping .get ("biolink_equivalent" , PHENOTYPIC_CATEGORY )
462+ # use biolink_equivalent URL from METPO tree traversal or fallback to default
463+ category = metpo_mapping .get ("inferred_category" , PHENOTYPIC_CATEGORY )
468464 predicate_biolink = metpo_mapping .get (
469465 "predicate_biolink_equivalent" , ""
470466 )
0 commit comments