Implement sentence detection in CorpusEditor