/ Модель

Характеристики

Контекст
512 токенов
Параметры
1,5 млрд
Лицензия
Apache 2.0
Архитектура
t5 · dense
Базовая модель
t5-xl-lm-adapt
Библиотека
transformers
Опубликована
19 ноя 2026

t5_xl-xsum

СуммаризацияТекст → текст3 профессии
35скачиваний за 30 дней0лайковвеса обновлены19 ноя 2026

Описание модели

Составлено на русском по карточке модели и метаданным Hugging Face

Англоязычная модель T5 для создания кратких резюме новостных статей и экспериментов по дистилляции.

Англоязычная модель суммаризации yoshitomo-matsubara/t5_xl-xsum, созданная на основе google/t5-xl-lm-adapt и дообученная с полным обновлением параметров на датасете XSum с помощью torchdistill. Это encoder-decoder модель семейства T5 с архитектурой T5ForConditionalGeneration; в метаданных указано 1,5 млрд параметров. В исходном описании базовая модель названа T5 v1.1 XL с 3 млрд параметров, поэтому размер базовой модели и опубликованной версии различается.

Модель предназначена для создания кратких однофразовых резюме англоязычных новостных статей, а также как учитель для экспериментов по дистилляции знаний в модели T5 меньшего размера. На вход подаётся текст с префиксом «summarize: »; при обучении использовались последовательности до 1024 токенов, а генерация оценивалась с ограничением до 64 новых токенов. В README приведены оценки ROUGE на validation и test выборках XSum.

Модель обучалась на новостях BBC на английском языке. Резюме могут добавлять факты, которых нет в статье; качество на других языках и доменах не оценивалось, а проверка ограничена ROUGE без метрик фактической согласованности или оценки людьми. Лицензия — Apache-2.0.

Сценарии применения

  • создание однофразового резюме англоязычной новости
  • сжатие англоязычных статей BBC до краткого пересказа
  • подготовка модели-учителя для дистилляции в компактные модели T5
  • оценка качества суммаризации на датасете XSum

Ограничения

Модель может включать в резюме факты, отсутствующие в исходной статье; проверка качества ограничена ROUGE на XSum, а перенос на другие языки и области не оценивался. На обучении входы длиннее 1024 токенов обрезались, а целевые резюме ограничивались 64 токенами.

Публичные бенчмарки

Результаты из открытых лидербордов в сравнении с лидерами каталога

Публичных оценок пока нет

В подключённых источниках результатов этой модели не нашлось. Отсутствие оценки не значит, что модель хуже: её могли просто не проверять.

Источники: Hugging Face Leaderboards, Hugging Face Eval Results, Open LLM v2, MTEB, timm, Open ASR, EvalPlus

Бенчмарки пользователейпока нет

Никто ещё не опубликовал тест этой модели. Соберите бенчмарк из своих задач — результат появится здесь рядом с другими моделями теста

  1. Добавьте модель в бенчмарк

    Вместе с другими моделями категории «Текст» — сравнение идёт внутри одной категории.

  2. Опишите свои задачи

    Напишите запросы, при необходимости приложите файлы и эталонные ответы.

  3. Запустите и опубликуйте

    Модели ответят на каждую задачу, судья оценит ответы по шкале 0–100.

Для каких профессий подходит3

Разделы каталога профессий, в задачах которых используется эта модель

Все профессии

Карточка модели

README от автора на Hugging Face, как он его опубликовал

Открыть на Hugging Face

t5_xl-xsum

google/t5-xl-lm-adapt (LM-adapted T5 v1.1 xl) fully fine-tuned on XSum with torchdistill.

It reproduces the supervised fine-tuning stage of GKD (Agarwal et al., ICLR 2024, Appendix A.2). It is the supervised fine-tuned teacher for the T5 knowledge distillation (KD) experiments, where T5-small, T5-base and T5-large students are distilled from it: every KD config loads this checkpoint (run name t5_xl_fsdp2) as the teacher.

Model details

Base modelgoogle/t5-xl-lm-adapt (3B parameters, T5 v1.1 encoder-decoder, 24 encoder + 24 decoder layers)
Fine-tuningFull-parameter supervised fine-tuning, cross-entropy on the reference summaries
Training dataEdinburghNLP/xsum, first 99% of the train split
LanguageEnglish
Lengths used in traininginput up to 1,024 tokens, summary up to 64 tokens
Input formatsummarize: <document>
Weightsmodel.safetensors, float32
LicenseApache 2.0 (see License)

Usage

The model was trained on inputs prefixed with summarize: and evaluated with greedy decoding of up to 64 new tokens. Pass both explicitly: the bundled generation_config.json sets no length, so generate would otherwise stop at the library default of 20 tokens, and the tokenizer's model_max_length (512) is shorter than the 1,024 input tokens used in training.

from transformers import AutoModelForSeq2SeqLM, AutoTokenizer

model_id = 'yoshitomo-matsubara/t5_xl-xsum'
tokenizer = AutoTokenizer.from_pretrained(model_id)
model = AutoModelForSeq2SeqLM.from_pretrained(model_id, dtype='bfloat16', device_map='auto')

document = 'The full text of a news article ...'
inputs = tokenizer(
    f'summarize: {document}', max_length=1024, truncation=True, return_tensors='pt'
).to(model.device)
outputs = model.generate(**inputs, max_new_tokens=64, do_sample=False, num_beams=1)
print(tokenizer.decode(outputs[0], skip_special_tokens=True))

For batches, pass a list of inputs with padding=True. Unlike a decoder-only model, T5 needs no left padding: the padded encoder positions are masked out, and the decoder starts from its own start token.

Use bf16 or fp32. T5 overflows in fp16.

Training data and split

EdinburghNLP/xsum has train (204,045 examples), validation (11,332) and test (11,334) splits. They are used as follows, with the datasets split syntax:

SplitUse
train[:99%]Training
train[99%:]"Monitor" split: perplexity after each epoch, for monitoring only
validationReported ROUGE (the paper's reporting split)
testReported ROUGE

The paper reports the validation split and selects no checkpoint, so this run keeps the last checkpoint (ckpt_selection: 'last'). Neither reported split, nor the monitor split, is used for any decision. The training run did not pin a dataset revision.

Each example maps the document field, prefixed with summarize: (the T5 convention; the paper does not state its input format), to the summary field as the target.

Training procedure

The paper fine-tunes T5-XL for 8,000 steps and gives no other SFT hyperparameters, so the run reuses those of its distillation runs (Table A.1: Adafactor, batch size 32, input/output length 1024/64, learning rate per Appendix A.3), with warmup and cooldown at the same proportions of the run (5% and the last 25%).

Dropout is the one deviation: T5 v1.1's default 0.1 instead of Table A.1's 0.0. With 0.0, plain fine-tuning overfits (T5-base: monitor perplexity 5.2 after epoch 1, 52 after epoch 8) and falls short of the paper's ROUGE-2.

HyperparameterValue
Steps8,000 optimizer steps (2 epochs, the last one partial)
OptimizerAdafactor (scale_parameter=False, relative_step=False, warmup_init=False), lr 3e-4
ScheduleWarmup-stable-decay: linear warmup over 400 steps, constant, linear decay to 0 over the last 2,000 steps
Batch size4 per device x 2 devices x gradient accumulation 4 = 32
Dropout0.1
Gradient clippingnone
Gradient checkpointingyes
Precisionfp32 master weights, bf16 autocast
Hardware2x 24 GB GPUs, FSDP2 (T5Block auto-wrap, reshard after forward, full state dict), gradient checkpointing, bf16 mixed precision
Training time~16 h 55 min for the first epoch, ~22 h 21 min in total
Seed42

The full torchdistill config, CLI arguments and per-step metrics are in logs/: config.yaml, args.json, metrics.json and trackio/summary.csv.

The run used the config under its earlier name, t5_xl_fsdp2.yaml, which is the name recorded in logs/ (config header, args.json, run name t5_xl_fsdp2). In torchdistill it is now configs/sample/xsum/fine_tuning/t5_xl.yaml, so reproduce the run with:

CUDA_VISIBLE_DEVICES=0,1 uv run accelerate launch --num_processes 2 --mixed_precision bf16 \
  --use_fsdp --fsdp_version 2 --fsdp_reshard_after_forward true \
  --fsdp_auto_wrap_policy TRANSFORMER_BASED_WRAP --fsdp_transformer_layer_cls_to_wrap T5Block \
  --fsdp_state_dict_type FULL_STATE_DICT --fsdp_cpu_ram_efficient_loading false \
  examples/hf_transformers/summarization.py \
  --config configs/sample/xsum/fine_tuning/t5_xl.yaml \
  --run_log log/xsum/fine_tuning/t5_xl.txt \
  --seed 42

FP32 weights and gradients of ~3B parameters alone take ~24 GB, so the run shards them over two GPUs. It uses FSDP2 rather than FSDP1 because FSDP1 shows the optimizer every parameter as a flattened 1D shard, so Adafactor never factors its second moments and clips each update by the RMS of a shard instead of the whole tensor. FSDP2 keeps parameter shapes, and torchdistill's DTensor-aware HFAdafactor then behaves as on a single device, as for the students. CPU-RAM-efficient loading is turned off (--fsdp_cpu_ram_efficient_loading false); with FSDP1 it hung on T5's shared embeddings.

This is the best of the three XL fine-tuning runs (one seed each, same recipe otherwise):

XL runDropoutValidation / test ROUGE-2
FSDP1 (unfactored Adafactor)0.021.15 / 21.06
FSDP1 (unfactored Adafactor)0.121.34 / 21.24
FSDP2 (released)0.121.37 / 21.40

The differences are within plausible seed noise.

Evaluation

ROUGE F-measure (x100) of greedy decoding (up to 64 new tokens) on the released, last checkpoint:

SplitROUGE-1ROUGE-2ROUGE-L
Validation (11,332)44.8921.3736.79
Test (11,334)44.8221.4036.72

The paper reports a ROUGE-2 of 22 on the validation split after this stage. Both splits are held out from training and were not used to select the checkpoint. The scores come from the 2-process distributed evaluation of the training run.

Perplexity over the summary tokens of the monitor split, measured after each epoch:

EpochMonitor perplexity
13.9807
2 (released)3.8002

The monitor perplexity was lowest at the final epoch.

Limitations

  • XSum's reference summaries often contain information that is not in the article, and models fine-tuned on it are known to hallucinate such content (Maynez et al., 2020). Summaries may be fluent but unfaithful.
  • Trained on English BBC news articles; quality on other domains and languages is not measured.
  • Inputs longer than 1,024 tokens were truncated in training; summaries are single sentences of up to 64 tokens.
  • No downstream evaluation beyond ROUGE on XSum (e.g. factual-consistency metrics or human evaluation) has been run.
  • Intended for research, in particular as a reference point for knowledge-distillation experiments.
  • About 0.6 ROUGE-2 below the paper's teacher (22). Neither dropout nor the optimizer variant closed the gap; the paper's figure is rounded, and its SFT learning rate and schedule for XL are not stated.

License

The weights are released under the Apache License 2.0 (LICENSE).

This model is a modification of google/t5-xl-lm-adapt by Google, which is licensed under the Apache License 2.0. The modification is full-parameter fine-tuning on the data described above.

The training data, XSum, consists of BBC articles collected by Narayan et al. (2018) for research and carries no explicit license on the Hugging Face Hub. Users are responsible for making sure their use of the model is consistent with the terms of the underlying data.

Citation

If you use this model, please cite torchdistill, as well as GKD, T5 and XSum:

@inproceedings{matsubara2021torchdistill,
  title={torchdistill: A Modular, Configuration-Driven Framework for Knowledge Distillation},
  author={Matsubara, Yoshitomo},
  booktitle={International Workshop on Reproducible Research in Pattern Recognition},
  pages={24--44},
  year={2021},
  organization={Springer}
}

@inproceedings{matsubara2023torchdistill,
  title={{torchdistill Meets Hugging Face Libraries for Reproducible, Coding-Free Deep Learning Studies: A Case Study on NLP}},
  author={Matsubara, Yoshitomo},
  booktitle={Proceedings of the 3rd Workshop for Natural Language Processing Open Source Software (NLP-OSS 2023)},
  publisher={Empirical Methods in Natural Language Processing},
  pages={153--164},
  year={2023}
}

@inproceedings{agarwal2024onpolicy,
  title={On-Policy Distillation of Language Models: Learning from Self-Generated Mistakes},
  author={Rishabh Agarwal and Nino Vieillard and Yongchao Zhou and Piotr Stanczyk and Sabela Ramos Garea and Matthieu Geist and Olivier Bachem},
  booktitle={The Twelfth International Conference on Learning Representations},
  year={2024}
}

@article{raffel2020t5,
  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},
  journal={Journal of Machine Learning Research},
  volume={21},
  number={140},
  pages={1--67},
  year={2020}
}

@inproceedings{lester2021power,
  title={The Power of Scale for Parameter-Efficient Prompt Tuning},
  author={Brian Lester and Rami Al-Rfou and Noah Constant},
  booktitle={Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing},
  pages={3045--3059},
  year={2021}
}

@inproceedings{narayan2018xsum,
  title={Don't Give Me the Details, Just the Summary! Topic-Aware Convolutional Neural Networks for Extreme Summarization},
  author={Shashi Narayan and Shay B. Cohen and Mirella Lapata},
  booktitle={Proceedings of the 2018 Conference on Empirical Methods in Natural Language Processing},
  pages={1797--1807},
  year={2018}
}

Как запустить

На своей GPU в ailist. Цена — по текущим предложениям провайдеров

GPU в ailist

Универсальный рантайм · transformers

Можно запустить

Подбираем GPU…

Класс архитектуры
T5ForConditionalGeneration
Ревизия весов
8c1c875

0 моделей