@@ -127,7 +127,8 @@ def _check_query_input(self):
127127
128128 # Use TRAPI Reasoner Validator to validate the query
129129 try :
130- validate_trapi (self ._json_data , "Query" )
130+ # For now, bypass the TRAPI validation because reasoner_validator doesn't work with TRAPI 1.5
131+ # validate_trapi(self._json_data, "Query")
131132 self .log ('Query passed reasoner validator' )
132133 except ValidationError as err :
133134 self ._valid_query = False
@@ -258,6 +259,9 @@ def _interpret_query(self):
258259 if not input_check [0 ]:
259260 return input_check
260261
262+ # Check if bypass_cache is desired
263+ self ._bypass_cache = self ._json_data .get ('bypass_cache' , False )
264+
261265 # Get options that don't fit into query_graph structure from query_options
262266 self ._query_options = self ._json_data .get ('query_options' )
263267 if self ._query_options is None :
@@ -942,7 +946,8 @@ def operate(self):
942946 domain_id = domain_id ,
943947 concept_class_id = concept_class_id ,
944948 ln_ratio_sign = self ._association_direction ,
945- confidence = self ._confidence_interval )
949+ confidence = self ._confidence_interval ,
950+ bypass = self ._bypass_cache )
946951 if json_results :
947952 new_cohd_results .extend (json_results ['results' ])
948953 else :
@@ -951,7 +956,8 @@ def operate(self):
951956 json_results = query_cohd_mysql .query_trapi (concept_id_1 = concept_1_omop_id , concept_id_2 = None ,
952957 dataset_id = self ._dataset_id , domain_id = None ,
953958 ln_ratio_sign = self ._association_direction ,
954- confidence = self ._confidence_interval )
959+ confidence = self ._confidence_interval ,
960+ bypass = self ._bypass_cache )
955961 if json_results :
956962 new_cohd_results .extend (json_results ['results' ])
957963
@@ -961,7 +967,8 @@ def operate(self):
961967 json_results = query_cohd_mysql .query_trapi (concept_id_1 = concept_1_omop_id ,
962968 concept_id_2 = concept_2_id ,
963969 dataset_id = self ._dataset_id , domain_id = None ,
964- confidence = self ._confidence_interval )
970+ confidence = self ._confidence_interval ,
971+ bypass = self ._bypass_cache )
965972 if json_results :
966973 new_cohd_results .extend (json_results ['results' ])
967974
0 commit comments