"languages other than English (`en`)")
elif self.clean:
if hasattr(self.language_module, "Cleaner"):
text = self.language_module.Cleaner(text, self.language_module,
doc_type=self.doc_type).clean()
else:
text = Cleaner(text, self.language_module, doc_type=self.doc_type).clean()
processor = Processor(text, lang=self.language_module, char_span=self.char_span)
segments = processor.process()
After Change
raise ValueError("char_span functionality not supported for "
"languages other than English (`en`)")
elif self.clean:
text = self.cleaner(text).clean()
segments = self.processor(text).process()
return segments