MCPcopy Create free account
hub / github.com/FlyingFeather/DEA-SQL / step_question_classification

Method step_question_classification

gen_sql.py:293–307  ·  view source on GitHub ↗
(self, input_dict, mode)

Source from the content-addressed store, hash-verified

291 return input_dict
292
293 def step_question_classification(self, input_dict, mode):
294 query = input_dict["query"]
295 sc_results = self.get_question_type(query, input_dict["table_info"])
296 self.question_type = sc_results[0]["question_type"]
297 input_dict["question_type"] = self.question_type
298
299 # The effect is not good and I haven’t used it yet.
300 input_dict["new_aggr_type"] = self.aggregation_type
301
302 if mode == "debug":
303 print("---------------The question type is identified as---------------------")
304 print(sc_results)
305 print(self.question_type)
306
307 return input_dict
308
309 def step_get_fewshots(self, input_dict, pre_sql, mode):
310 query = input_dict["query"]

Callers 1

mainMethod · 0.95

Calls 1

get_question_typeMethod · 0.95

Tested by

no test coverage detected