class_docstr: Message-level mutators.
  
  Message-level mutators have a function applied per-utterance. They are ideal
  for transformations of data which don't create any new conversations or
  turns, but only apply simple text-transformations.
  
  Examples include:
  
  * Shuffling words in context
  * Adding a special token based on a non-text field
  * Replacing words with synonyms or other simple augmentations
docstr: Apply the mutator to a series of messages.
  
  Not meant to be called directly by a user.
docstr_tok: ["Apply","the","mutator","to","a","series","of","messages",".","Not","meant","to","be","called","directly","by","a","user","."]
code: def __call__(self, messages: Iterable[Message]) -> Iterator[Message]:
      """
      Apply the mutator to a series of messages.
  
      Not meant to be called directly by a user.
      """
      for message in messages:
          if message.is_padding():
              yield message
              continue
          message, episode_done = self._pop_episode_done(message)
          message = self.message_mutation(message)
          if "episode_done" in message:
              raise ValueError(
                  "MessageMutators should not modify episode_done."
              )
          message["episode_done"] = episode_done
          yield message
  
imports: from __future__ import annotations
  import abc
  import importlib
  import pkgutil
  from typing import Optional, Iterable, Tuple, List, Iterator, Callable, Type
  import parlai.mutators
  from parlai.core.params import ParlaiParser
  from parlai.core.opt import Opt
  from parlai.core.message import Message
label_desc: Use image node_id 2 for calling the MessageMutator obj's underlying member method code with example usage: obj.__call__(messages) without return types