(self, inText)
| 447 | print("Done computing accuracy") |
| 448 | |
| 449 | def processPunctuation(self, inText): |
| 450 | outText = inText |
| 451 | for p in self.punct: |
| 452 | if (p + " " in inText or " " + p in inText) or ( |
| 453 | re.search(self.commaStrip, inText) != None |
| 454 | ): |
| 455 | outText = outText.replace(p, "") |
| 456 | else: |
| 457 | outText = outText.replace(p, " ") |
| 458 | outText = self.periodStrip.sub("", outText, re.UNICODE) |
| 459 | return outText |
| 460 | |
| 461 | def processDigitArticle(self, inText): |
| 462 | outText = [] |
no outgoing calls