code: def prepare_to_generate(self, data_dir, tmp_dir):
      
      self.get_or_create_vocab(data_dir, tmp_dir)
      self.train_text_filepaths(tmp_dir)
      self.dev_text_filepaths(tmp_dir)
docs: Make sure that the data is prepared and the vocab is generated.