modelzoo.transformers.data_processing.scripts.chunk_preprocessing.data_reader.find_last_paragraph_or_sentence_end#
- modelzoo.transformers.data_processing.scripts.chunk_preprocessing.data_reader.find_last_paragraph_or_sentence_end(buffer: str) int [source]#
Find the last end of a paragraph (denoted by ‘
‘) or a sentence in the buffer.
- Args:
buffer (str): The text buffer.
- Returns:
int: The position of the last end of the paragraph or sentence.