Sentence Splitter Module

SentenceSplitter is a module that allows for the separation of a text into sentences by considering Turkish non-breaking prefixes. The module provides the “split_sentences()” method, which takes in a text as input and returns a list of sentences by considering Turkish non-breaking prefixes.

  • Improved Sentence Segmentation: SentenceSplitter module provides accurate sentence segmentation by considering Turkish non-breaking prefixes, which ensures that the resulting sentences are grammatically and semantically correct.

  • Easy to Use: The module provides a single method “split_sentences()” which takes input text and return list of sentences which makes it easy to use

  • Language Specific: SentenceSplitter module is designed specifically for Turkish language which makes it more accurate and efficient in comparison to general sentence segmentation tools.

SentenceSplitter Class ~ Split Sentences Method

class mintlemon.sentence_splitter.sentence_splitter.SentenceSplitter[source]

SentenceSplitter is a class used for splitting a text into sentences by considering Turkish non-breaking prefixes

split_sentences(text: str)List[str]

Split the given text into sentences by considering Turkish non-breaking prefixes.

split_sentences(text: str) List[str][source]

Split the given text into sentences by considering Turkish non-breaking prefixes.

textstr

The input text to be split into sentences.

sentenceslist

A list of sentences

>>> from mintlemon import SentenceSplitter
>>> splitter = SentenceSplitter()
>>> text = "Bu cümle bir örnektir. Bu cümle de bir örnektir!"
>>> splitter.split_sentences(text)
Output: ["Bu cümle bir örnektir.", "Bu cümle de bir örnektir!"]