code: def format_text(text: str, lower: bool = True) -> str:
      """
      Space punctuation and lowercase text.
  
      :param text:
          text to lowercase
      :param lower:
          whether to lowercase or not
  
      :return text:
          return formatted text.
      """
      if lower:
          text = text.lower()
      for punc in PUNCTUATION_LST:
          text = text.replace(punc[1], punc[0])
  
      return text
  
file_path: ParlAI/parlai/tasks/genderation_bias/utils.py
imports: from collections import deque
  import random
  from parlai.core.loader import load_teacher_module
  from parlai.core.message import Message
  from parlai.core.opt import Opt
  from typing import List, Tuple
label_desc: Use image node_id 1 for calling a global function with example usage: format_text(text, lower) and returns: text