docs: def unescape_single_character(match):
      """
      Unescape a single escape sequence found by regular expression.
  
      :param match: Regular expression match object
      :rtype: str
      :raises: ValueError if the escape sequence is invalid
      """
      try:
          return DECODE_MAP[match.group(0)]
      except KeyError:
          value = match.group(0)
          if value == '\\':
              raise ValueError("Unterminated escape sequence encountered")
  
          raise ValueError(
              "Unrecognized escape sequence encountered: {}".format(value))