eta.discourse.parse_utt_str

parse_utt_str(str)[source]

Parse an utterance string into a word string and affect.

Parameters:

str (str) – A string representing an utterance, potentially prefixed by an emotion tag, e.g., [happy] or [sad].

Returns:

  • affect (str) – The affect/emotion of the utterance.

  • words (str) – The word string of the utterance.