aoptk.text_utils ================ .. py:module:: aoptk.text_utils Functions --------- .. autoapisummary:: aoptk.text_utils.ends aoptk.text_utils.endswith_digit aoptk.text_utils.end_of_span aoptk.text_utils.contains_any Module Contents --------------- .. py:function:: ends(text: str) -> bool Check if text ends with sentence-ending punctuation. :param text: The text to check. :type text: str :param sentence_terminators: List of sentence terminators. :type sentence_terminators: list[str] | None .. py:function:: endswith_digit(text: str) -> bool Check if text ends with a digit. :param text: The text to check. :type text: str .. py:function:: end_of_span(text: str) -> bool Check text whether it is the end of a span. :param text: Text to check :type text: str :returns: True if text has common delimiter or ends with a digit. :rtype: bool .. py:function:: contains_any(text: str, substrs: list[str]) -> bool Check if text looks like formatting artifacts. :param text: The text to check. :type text: str :param substrs: substrings to match. :type substrs: list[str] | None