in 1_synthetic-qa-generation/reasoningplaning/evolve.py [0:0]
def runQuestionOnly(self):
self.createSeedPrompts()
self.createPrompts()
list_q = []
for k in self.final_prompts:
list_q.append(
{
"idx": self.final_prompts[k]["idx"],
"preidx": self.final_prompts[k]["preidx"],
self.column_names: k,
GRND_TRUTH_COL: self.final_prompts[k][GRND_TRUTH_COL]
# 'input': self.final_prompts[k],
}
)
del self.final_prompts
output_file = f"{self.seed_data.replace('.jsonl', '').replace('.json', '')}.%s.json" % str(uuid.uuid4())[:4]
processed_count = 0
for question in list_q:
if self.shouldProcessQuestion(question):
collected_data = self.processQuestion(question)
self.saveQuestionData(collected_data, question['idx'], output_file)
processed_count += 1
else:
logger.info(f"Skipping question: {question[self.column_names]}")
# Log summary
logger.info(
f"Total questions processed by genPrm: {processed_count}/{len(list_q)} inf file>> {output_file}"
)