Mt5 Multilingual XLSum
基於XL-Sum數據集45種語言微調的mT5模型,用於多語言摘要生成任務
下載量 73.34k
發布時間 : 3/2/2022
模型概述
該模型是基於mT5架構的多語言摘要生成模型,支持45種語言的文本摘要任務,在XL-Sum數據集上進行了微調。
模型特點
多語言支持
支持45種語言的摘要生成任務
高性能
在XL-Sum測試集上ROUGE-1得分達到36.5002
基於mT5架構
採用mT5預訓練模型架構,適合多語言任務
模型能力
文本摘要生成
多語言處理
長文本理解
使用案例
新聞摘要
新聞文章摘要
將長篇新聞文章自動生成為簡潔摘要
生成準確反映原文內容的簡短摘要
內容管理
社交媒體內容摘要
為社交媒體平臺生成內容摘要
幫助用戶快速理解長內容
🚀 mT5-multilingual-XLSum
本項目包含在 XL - Sum 數據集的45種語言上微調的mT5檢查點。有關微調的詳細信息和腳本,請參閱論文和官方倉庫。
🚀 快速開始
環境要求
本模型在 transformers
庫(版本4.11.0.dev0)中進行了測試。
代碼示例
import re
from transformers import AutoTokenizer, AutoModelForSeq2SeqLM
WHITESPACE_HANDLER = lambda k: re.sub('\s+', ' ', re.sub('\n+', ' ', k.strip()))
article_text = """Videos that say approved vaccines are dangerous and cause autism, cancer or infertility are among those that will be taken down, the company said. The policy includes the termination of accounts of anti-vaccine influencers. Tech giants have been criticised for not doing more to counter false health information on their sites. In July, US President Joe Biden said social media platforms were largely responsible for people's scepticism in getting vaccinated by spreading misinformation, and appealed for them to address the issue. YouTube, which is owned by Google, said 130,000 videos were removed from its platform since last year, when it implemented a ban on content spreading misinformation about Covid vaccines. In a blog post, the company said it had seen false claims about Covid jabs "spill over into misinformation about vaccines in general". The new policy covers long-approved vaccines, such as those against measles or hepatitis B. "We're expanding our medical misinformation policies on YouTube with new guidelines on currently administered vaccines that are approved and confirmed to be safe and effective by local health authorities and the WHO," the post said, referring to the World Health Organization."""
model_name = "csebuetnlp/mT5_multilingual_XLSum"
tokenizer = AutoTokenizer.from_pretrained(model_name)
model = AutoModelForSeq2SeqLM.from_pretrained(model_name)
input_ids = tokenizer(
[WHITESPACE_HANDLER(article_text)],
return_tensors="pt",
padding="max_length",
truncation=True,
max_length=512
)["input_ids"]
output_ids = model.generate(
input_ids=input_ids,
max_length=84,
no_repeat_ngram_size=2,
num_beams=4
)[0]
summary = tokenizer.decode(
output_ids,
skip_special_tokens=True,
clean_up_tokenization_spaces=False
)
print(summary)
✨ 主要特性
- 多語言支持:該模型在XL - Sum數據集的45種語言上進行了微調,支持多種語言的文本摘要任務。
- 高性能表現:在多個語言的測試集上取得了較好的ROUGE指標成績。
📚 詳細文檔
模型信息
屬性 | 詳情 |
---|---|
模型名稱 | csebuetnlp/mT5_multilingual_XLSum |
模型類型 | 多語言摘要模型 |
訓練數據集 | XL - Sum |
評估指標 | ROUGE - 1、ROUGE - 2、ROUGE - L、ROUGE - LSUM、loss、gen_len |
基準測試
在XL - Sum測試集上的得分如下:
語言 | ROUGE - 1 / ROUGE - 2 / ROUGE - L |
---|---|
阿姆哈拉語 | 20.0485 / 7.4111 / 18.0753 |
阿拉伯語 | 34.9107 / 14.7937 / 29.1623 |
阿塞拜疆語 | 21.4227 / 9.5214 / 19.3331 |
孟加拉語 | 29.5653 / 12.1095 / 25.1315 |
緬甸語 | 15.9626 / 5.1477 / 14.1819 |
中文(簡體) | 39.4071 / 17.7913 / 33.406 |
中文(繁體) | 37.1866 / 17.1432 / 31.6184 |
英語 | 37.601 / 15.1536 / 29.8817 |
法語 | 35.3398 / 16.1739 / 28.2041 |
古吉拉特語 | 21.9619 / 7.7417 / 19.86 |
豪薩語 | 39.4375 / 17.6786 / 31.6667 |
印地語 | 38.5882 / 16.8802 / 32.0132 |
伊博語 | 31.6148 / 10.1605 / 24.5309 |
印尼語 | 37.0049 / 17.0181 / 30.7561 |
日語 | 48.1544 / 23.8482 / 37.3636 |
基隆迪語 | 31.9907 / 14.3685 / 25.8305 |
韓語 | 23.6745 / 11.4478 / 22.3619 |
吉爾吉斯語 | 18.3751 / 7.9608 / 16.5033 |
馬拉地語 | 22.0141 / 9.5439 / 19.9208 |
尼泊爾語 | 26.6547 / 10.2479 / 24.2847 |
奧羅莫語 | 18.7025 / 6.1694 / 16.1862 |
普什圖語 | 38.4743 / 15.5475 / 31.9065 |
波斯語 | 36.9425 / 16.1934 / 30.0701 |
皮欽語 | 37.9574 / 15.1234 / 29.872 |
葡萄牙語 | 37.1676 / 15.9022 / 28.5586 |
旁遮普語 | 30.6973 / 12.2058 / 25.515 |
俄語 | 32.2164 / 13.6386 / 26.1689 |
蘇格蘭蓋爾語 | 29.0231 / 10.9893 / 22.8814 |
塞爾維亞語(西里爾文) | 23.7841 / 7.9816 / 20.1379 |
塞爾維亞語(拉丁字母) | 21.6443 / 6.6573 / 18.2336 |
僧伽羅語 | 27.2901 / 13.3815 / 23.4699 |
索馬里語 | 31.5563 / 11.5818 / 24.2232 |
西班牙語 | 31.5071 / 11.8767 / 24.0746 |
斯瓦希里語 | 37.6673 / 17.8534 / 30.9146 |
泰米爾語 | 24.3326 / 11.0553 / 22.0741 |
泰盧固語 | 19.8571 / 7.0337 / 17.6101 |
泰語 | 37.3951 / 17.275 / 28.8796 |
提格雷尼亞語 | 25.321 / 8.0157 / 21.1729 |
土耳其語 | 32.9304 / 15.5709 / 29.2622 |
烏克蘭語 | 23.9908 / 10.1431 / 20.9199 |
烏爾都語 | 39.5579 / 18.3733 / 32.8442 |
烏茲別克語 | 16.8281 / 6.3406 / 15.4055 |
越南語 | 32.8826 / 16.2247 / 26.0844 |
威爾士語 | 32.6599 / 11.596 / 26.1164 |
約魯巴語 | 31.6595 / 11.6599 / 25.0898 |
📄 許可證
本模型使用的許可證為 cc - by - nc - sa - 4.0
。
📝 引用
如果您使用了此模型,請引用以下論文:
@inproceedings{hasan-etal-2021-xl,
title = "{XL}-Sum: Large-Scale Multilingual Abstractive Summarization for 44 Languages",
author = "Hasan, Tahmid and
Bhattacharjee, Abhik and
Islam, Md. Saiful and
Mubasshir, Kazi and
Li, Yuan-Fang and
Kang, Yong-Bin and
Rahman, M. Sohel and
Shahriyar, Rifat",
booktitle = "Findings of the Association for Computational Linguistics: ACL-IJCNLP 2021",
month = aug,
year = "2021",
address = "Online",
publisher = "Association for Computational Linguistics",
url = "https://aclanthology.org/2021.findings-acl.413",
pages = "4693--4703",
}
Bart Large Cnn
MIT
基於英語語料預訓練的BART模型,專門針對CNN每日郵報數據集進行微調,適用於文本摘要任務
文本生成 英語
B
facebook
3.8M
1,364
Parrot Paraphraser On T5
Parrot是一個基於T5的釋義框架,專為加速訓練自然語言理解(NLU)模型而設計,通過生成高質量釋義實現數據增強。
文本生成
Transformers

P
prithivida
910.07k
152
Distilbart Cnn 12 6
Apache-2.0
DistilBART是BART模型的蒸餾版本,專門針對文本摘要任務進行了優化,在保持較高性能的同時顯著提升了推理速度。
文本生成 英語
D
sshleifer
783.96k
278
T5 Base Summarization Claim Extractor
基於T5架構的模型,專門用於從摘要文本中提取原子聲明,是摘要事實性評估流程的關鍵組件。
文本生成
Transformers 英語

T
Babelscape
666.36k
9
Unieval Sum
UniEval是一個統一的多維評估器,用於自然語言生成任務的自動評估,支持多個可解釋維度的評估。
文本生成
Transformers

U
MingZhong
318.08k
3
Pegasus Paraphrase
Apache-2.0
基於PEGASUS架構微調的文本複述模型,能夠生成語義相同但表達不同的句子。
文本生成
Transformers 英語

P
tuner007
209.03k
185
T5 Base Korean Summarization
這是一個基於T5架構的韓語文本摘要模型,專為韓語文本摘要任務設計,通過微調paust/pko-t5-base模型在多個韓語數據集上訓練而成。
文本生成
Transformers 韓語

T
eenzeenee
148.32k
25
Pegasus Xsum
PEGASUS是一種基於Transformer的預訓練模型,專門用於抽象文本摘要任務。
文本生成 英語
P
google
144.72k
198
Bart Large Cnn Samsum
MIT
基於BART-large架構的對話摘要模型,專為SAMSum語料庫微調,適用於生成對話摘要。
文本生成
Transformers 英語

B
philschmid
141.28k
258
Kobart Summarization
MIT
基於KoBART架構的韓語文本摘要模型,能夠生成韓語新聞文章的簡潔摘要。
文本生成
Transformers 韓語

K
gogamza
119.18k
12
精選推薦AI模型
Llama 3 Typhoon V1.5x 8b Instruct
專為泰語設計的80億參數指令模型,性能媲美GPT-3.5-turbo,優化了應用場景、檢索增強生成、受限生成和推理任務
大型語言模型
Transformers 支持多種語言

L
scb10x
3,269
16
Cadet Tiny
Openrail
Cadet-Tiny是一個基於SODA數據集訓練的超小型對話模型,專為邊緣設備推理設計,體積僅為Cosmo-3B模型的2%左右。
對話系統
Transformers 英語

C
ToddGoldfarb
2,691
6
Roberta Base Chinese Extractive Qa
基於RoBERTa架構的中文抽取式問答模型,適用於從給定文本中提取答案的任務。
問答系統 中文
R
uer
2,694
98