code: def _fix_missing_period(line):
      """
      Adds a period to a line that is missing a period.
      """
      dm_single_close_quote = "\u2019"
      dm_double_close_quote = "\u201d"
      END_TOKENS = [
          ".",
          "!",
          "?",
          "...",
          "'",
          "`",
          '"',
          dm_single_close_quote,
          dm_double_close_quote,
          ")",
      ]  # acceptable ways to end a sentence
      if "@highlight" in line or line == "" or line[-1] in END_TOKENS:
          return line
      return line + "."
  
file_path: ParlAI/parlai/tasks/cnn_dm/agents.py
imports: from parlai.core.teachers import DialogTeacher
  from parlai.utils.io import PathManager
  from .build import build
  import os
  import unicodedata
label_desc: Use image node_id 1 for calling a global function with example usage: _fix_missing_period(line) and returns: unknown, line