This is a fine-tuned version of Multilingual Bart (610M) trained on German in particular on the public dataset Falko-MERLIN for Grammatical Error Correction. from transformers import MBartForConditionalGeneration, MBart50TokenizerFast model = MBartForConditionalGeneration.from_pretrained(«MRNH/mbart-german-grammar-corrector») tokenizer = MBart50TokenizerFast.frompretrained(«MRNH/mbart-german-grammar-corrector», srclang=»deDE», tgtlang=»deDE») input = tokenizer(«I was here yesterday to studying»,texttarget=»I was here yesterday to study», return_tensors=’pt’) output = model.generate(input[«inputids»],attentionmask=input[«attentionm
Модальности:
Генерация текста
Задача: Генерация текста
Автор: MRNH
Теги: mbart, text2text-generation, grammatical error correction, GEC, german, de, endpoints_compatible
Лайков: 3 | Загрузок: 697
Описание основано на материалах HuggingFace. Перевод выполнен автоматически.