code: def add_text(self, tag, text, global_step=None):
          
          self._file_writer.add_summary(text_summary(tag, text), global_step)
          if tag not in self._text_tags:
              self._text_tags.append(tag)
              extension_dir = self.get_logdir() + '/plugins/tensorboard_text/'
              if not os.path.exists(extension_dir):
                  os.makedirs(extension_dir)
              with open(extension_dir + 'tensors.json', 'w') as fp:
                  json.dump(self._text_tags, fp)
docs: Add text data to the event file.
  
          Parameters
          ----------
              tag : str
                  Name for the `text`.
              text : str
                  Text to be saved to the event file.
              global_step : int
                  Global step value to record.