
t5
Language764 ops60.5M params
The text-to-text encoder-decoder, traced here alongside its protein-language offshoots.
Language · 1,140 operations Checked
Click or tap a spot to read it up close. Scroll or drag inside the diagram to move through it. Zoom with + and − or Ctrl and scroll. Press 0 for the whole graph. Swipe inside the diagram to move through it. Use + and − to zoom.
The file opened in a new tab. Use your browser's Save command there to keep it.
The diagram is a drawing of a TorchLens trace of the source code. It contains no code or weights.
About this model's family
T5 is the unified text-to-text Transformer from the paper Exploring the Limits of Transfer Learning with a Unified Text-to-Text Transformer, and it rests on one idea: convert every text-based language problem into a text-to-text format. The paper is as much a study as a model, systematically comparing pre-training objectives, architectures, unlabeled data sets, transfer approaches and other factors across dozens of language understanding tasks. Combining those insights with scale and the new Colossal Clean Crawled Corpus, the authors report state-of-the-art results on many benchmarks covering summarization, question answering and text classification. They released the data set, pre-trained models and code.
The family as traced here reaches well beyond text: the ProstT5 member is a protein language model which can translate between protein sequence and structure. It is based on ProtT5-XL-U50, a T5 model trained on encoding protein sequences using span corruption applied on billions of protein sequences. Its authors encode protein structures as token sequences using the 3Di alphabet introduced by the 3D-alignment method Foldseek. They built a non-redundant dataset from AlphaFoldDB and fine-tuned the existing protein language model ProtT5 to translate between 3Di and amino acid sequences. The direction of the translation is indicated by two special tokens. To avoid clashes with amino-acid tokens, 3Di tokens were cast to lower-case, since the two alphabets are otherwise identical.
For feature extraction, the ProstT5 model card recommends using only the encoder in half-precision together with batching. Generating embeddings for the human proteome with that encoder takes around 35 minutes, about 0.1 seconds per protein, on a single RTX A6000 GPU with 48 GB of memory. Translation is comparatively slow, 0.6 to 2.5 seconds per protein, because decoding must generate left to right, token by token.
Key idea. T5 recasts every NLP task as text-to-text through a single unified framework, and uses that framing to systematically compare pre-training objectives, architectures, data sets and transfer approaches at scale.
AI-written summary, based on the paper and checked automatically against it; not reviewed by a person. Corrections welcome.
@misc{raffel2023exploringlimitstransferlearning,
title={Exploring the Limits of Transfer Learning with a Unified Text-to-Text Transformer},
author={Colin Raffel and Noam Shazeer and Adam Roberts and Katherine Lee and Sharan Narang and Michael Matena and Yanqi Zhou and Wei Li and Peter J. Liu},
year={2023},
eprint={1910.10683},
archivePrefix={arXiv},
primaryClass={cs.LG},
url={https://arxiv.org/abs/1910.10683},
}