mpt-7b-8k-instruct / hf_t5.py
irenedea's picture
LLM-foundry update March 26, 2024 23:50:31
2cc518e 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