question_generation
question_generation copied to clipboard
Use datasets instead of nlp. And add requirements.txt.
Nlp hasn't been updated in a long time and conflicts with the latest dill. So I replaced nlp with datasets. Now it can preprocess the data correctly.
Thanks @ZZZZkp for that fix. However, the question_generation.ipynb file still does not work, returning the next message:
`ValueError Traceback (most recent call last)
1 frames
/content/question_generation/pipelines.py in _prepare_inputs_for_qg_from_answers_hl(self, sents, answers)
140 answer_text = answer_text.strip()
141
--> 142 ans_start_idx = sent.index(answer_text)
143
144 sent = f"{sent[:ans_start_idx]}
ValueError: substring not found`
Do you have any remedy here?