(self, doc)
| 103 | return doc["problems"][-1] |
| 104 | |
| 105 | def doc_to_text(self, doc): |
| 106 | text = "Article: " + doc["article"] + "\n\n" |
| 107 | for problem in doc["problems"][:-1]: |
| 108 | if problem["question"][-6:] == " _ .": |
| 109 | text += ( |
| 110 | problem["question"][-5:] + self.get_answer_option(problem) + "\n" |
| 111 | ) |
| 112 | else: |
| 113 | question = "Question: " + problem["question"] + "\n" |
| 114 | answer = "Answer: " + self.get_answer_option(problem) + "\n" |
| 115 | text += question + answer |
| 116 | text += self.last_problem(doc)["question"] |
| 117 | return text |
| 118 | |
| 119 | def should_decontaminate(self): |
| 120 | return True |
nothing calls this directly
no test coverage detected