logitorch.utilities.discourse_delimiter¶
Attributes¶
Classes¶
A class that provides methods to split a passage into educational units (EDUs) based on explicit connectives and punctuation delimiters. |
Module Contents¶
- class logitorch.utilities.discourse_delimiter.DiscourseDelimiter[source]¶
A class that provides methods to split a passage into educational units (EDUs) based on explicit connectives and punctuation delimiters.
- split_edu(passage: str) str[source]¶
Splits the passage into educational units (EDUs) by replacing explicit connectives with “<CONNECTIVE>” and punctuation delimiters with “<PUNCT>”.
- Args:
passage (str): The passage to be split into EDUs.
- Returns:
str: The passage with explicit connectives and punctuation delimiters replaced by “<CONNECTIVE>” and “<PUNCT>” respectively.
- split_explicit_connectives(passage: str) List[str][source]¶
Splits the passage into segments based on explicit connectives.
- Args:
passage (str): The passage to be split.
- Returns:
List[str]: A list of segments split based on explicit connectives.