mpt-30b-instruct / hf_t5.py
irenedea's picture
LLM-foundry update March 26, 2024 23:50:31
ef9200f verified
raw
history blame
398 Bytes
"""Implements a Hugging Face T5 wrapped inside a :class:`.ComposerModel`."""
from __future__ import annotations
from typing import Mapping
from transformers import AutoConfig, PreTrainedTokenizerBase, T5ForConditionalGeneration
from .hf_fsdp import hf_get_init_device
from .model_wrapper import HuggingFaceModelWithFSDP
from .utils import init_empty_weights
from .warnings import experimental_class