class_docstr: Transforms an affirmative sentence into a negative sentence, or vice versa.
  Each sample generate one transformed sample at most.
class_docstr_tok: ["Transforms","an","affirmative","sentence","into","a","negative","sentence",",","or","vice","versa",".","Each","sample","generate","one","transformed","sample","at","most","."]
code: def _add_sample(self, field, tokens, root_id, sample):
      if tokens[root_id].lower() in [
          "is",
          "was",
          "were",
          "am",
          "are",
          "'s",
          "'re",
          "'m",
      ]:
          add_sample = sample.insert_field_before_index(
              field, root_id + 1, "not"
          )
          return add_sample
  
      if tokens[root_id].lower() in ["being"]:
          add_sample = sample.insert_field_before_index(
              field, root_id, "not"
          )
          return add_sample
  
      if tokens[root_id].lower() in [
          "do",
          "does",
          "did",
          "can",
          "have",
          "will",
          "could",
          "would",
          "could",
          "should",
      ]:
          add_sample = sample.insert_field_before_index(
              field, root_id + 1, "not"
          )
          return add_sample
      else:
          token_pos = self.processor.get_pos(tokens[root_id])
          trans_sent = []
          if token_pos[0][1] in [
              "VB",
              "VBP",
              "VBZ",
              "VBG",
              "VBD",
              "VBN",
              "NNS",
              "NN",
          ]:
              if token_pos[0][1] in ["VB", "VBP", "VBG"]:
                  neg_word = ["do", "not"]
              if token_pos[0][1] in ["VBD", "VBN"]:
                  neg_word = ["did", "not"]
              else:
                  neg_word = ["does", "not"]
              add_sample = sample
  
              for i, word in enumerate(neg_word):
                  add_sample = add_sample.insert_field_before_index(
                      field, root_id + i, word
                  )
              return add_sample
  
          return trans_sent
  
file_path: textflint/textflint/generation/transformation/UT/reverse_neg.py
imports: from ..transformation import Transformation
label_desc: Use image node_id 9 for calling the ReverseNeg obj's underlying member method code with example usage: obj._add_sample(field, tokens, root_id, sample) and returns: add_sample, add_sample, add_sample, trans_sent, add_sample