Technical Overview
t5‑small is the 60‑million‑parameter checkpoint of Google’s Text‑to‑Text Transfer Transformer (T5). Unlike classification‑only models such as BERT, T5 reframes every natural‑language task as a text‑to‑text problem: the input is a plain string and the output is another string. This unified formulation lets a single model be applied to translation, summarisation, question answering, sentiment analysis, and even regression by predicting the string representation of a number.
Key features & capabilities include:
- Multilingual support for English, French, Romanian, German and a broader multilingual token set.
- Ready‑to‑use pipelines for
translation,summarisation,text2text‑generation, andquestion‑answering. - Compatibility with PyTorch, TensorFlow, JAX, ONNX, Rust, and the Hugging Face Transformers library.
- Lightweight enough for edge‑device inference while retaining the benefits of the full T5 family.
Architecture highlights:
- Encoder‑decoder transformer with 6 layers each (12 total).
- Model dimension
d_model=512, feed‑forward dimensionffn_dim=2048, and 8 attention heads. - Spans a shared vocabulary of 32 k SentencePiece tokens, enabling seamless switching between languages.
- Trained with a denoising objective (span‑masking) on the C4 corpus plus a mixture of supervised tasks (GLUE, SuperGLUE, translation, summarisation, etc.).
Intended use cases revolve around any scenario where you need to transform one piece of text into another: machine translation (e.g., EN↔FR), abstractive summarisation of articles, data‑to‑text generation, and rapid prototyping of downstream NLP pipelines without swapping models.