class_docstr: T5 translation model.
  
  TranslationWrapper class has input_specs compatible with the corresponding
  dataset, but its init args are not supported by the front-end system, thus
  we set up a layer of init args on top to work with the front-end.
class_docstr_tok: ["T5","translation","model",".","TranslationWrapper","class","has","input_specs","compatible","with","the","corresponding","dataset",",","but","its","init","args","are","not","supported","by","the","front-end","system",",","thus","we","set","up","a","layer","of","init","args","on","top","to","work","with","the","front-end","."]
code: def init_spec(cls) -> lit_types.Spec:
      return {
          "model_name_or_path": lit_types.String(
              default=_DEFAULT_MODEL_PATH,
              required=False,
          ),
          **T5ModelConfig.init_spec(),
      }
  
imports: import re
  import attr
  from lit_nlp.api import model
  from lit_nlp.api import types
  from lit_nlp.examples.models import model_utils
  from lit_nlp.lib import file_cache
  from lit_nlp.lib import utils
  import tensorflow
  import tensorflow_text
  import transformers
  from rouge_score import rouge_scorer
label_desc: Use image node_id 2 for calling the T5Translation obj's underlying member method code with example usage: obj.init_spec(cls) and returns: dict