class_docstr: Generates target sentence/ids using a base model.
  
  It generates target sentence/ids for a model (a pretrained transformer model or a function).
class_docstr_tok: ["Generates","target","sentence\/ids","using","a","base","model",".","It","generates","target","sentence\/ids","for","a","model","(","a","pretrained","transformer","model","or","a","function",")","."]
code: def save(self, out_file):
      super().save(out_file)
  
      # Increment the version number when the encoding changes!
      with Serializer(
          out_file, "shap.models.TextGeneration", version=0
      ) as s:
          s.save("tokenizer", self.tokenizer)
          s.save("device", self.device)
  
file_path: shap/shap/models/_text_generation.py
imports: import numpy
  from .._serializable import Deserializer, Serializer
  from ..utils import safe_isinstance
  from ._model import Model
label_desc: Use image node_id 6 for calling the TextGeneration obj's underlying member method code with example usage: obj.save(out_file) without return types