class_docstr: Class for Hugging Face causal Seq2Seq generation models.
  
  Attributes:
      model_path: path to HF model
      tokenizer_path: path to HF tokenizer
      name: string identifier for the model. Lowercase letters and numbers.
          No spaces/special characters except dashes.
      description: String description of the model.
      tasks: List of supported task strings
      details: Dictionary of additional details about the model
      model_class: Class used to initialise model
      tokenizer_class: Class used to initialise tokenizer
      device: Device for model. Defaults to "cuda" if available.
class_docstr_tok: ["Class","for","Hugging","Face","causal","Seq2Seq","generation","models",".","Attributes",":","model_path",":","path","to","HF","model","tokenizer_path",":","path","to","HF","tokenizer","name",":","string","identifier","for","the","model",".","Lowercase","letters","and","numbers",".","No","spaces\/special","characters","except","dashes",".","description",":","String","description","of","the","model",".","tasks",":","List","of","supported","task","strings","details",":","Dictionary","of","additional","details","about","the","model","model_class",":","Class","used","to","initialise","model","tokenizer_class",":","Class","used","to","initialise","tokenizer","device",":","Device","for","model",".","Defaults","to","``","cuda","''","if","available","."]
code: def encode_input(self, text, max_length=128):
      tokens = self.tokenizer(
          text,
          truncation=True,
          max_length=max_length,
          padding="max_length",
          return_tensors="pt",
      )
      return {
          "input_ids": tokens.input_ids[0],
          "attention_mask": tokens.attention_mask[0],
      }
  
file_path: backprop/backprop/models/hf_seq2seq_tg_model/model.py
imports: import torch
  from typing import List, Dict
  from transformers import AutoModelForSeq2SeqLM, AutoTokenizer
  from backprop.models import HFTextGenerationModel
label_desc: Use image node_id 6 for calling the HFSeq2SeqTGModel obj's underlying member method code with example usage: obj.encode_input(text, max_length) and returns: dict