英文

特立尼达英式克里奥尔语到英语的翻译器

该模型使用了T5-base预训练模型。它经过微调,用于将特立尼达英式克里奥尔语翻译成英语。随着更多数据的编制,该模型将定期更新。要了解加勒比英式克里奥尔语的更多信息,请查看库 Caribe

与Transformers一起使用

from transformers import AutoTokenizer, AutoModelForSeq2SeqLM
tokenizer = AutoTokenizer.from_pretrained("KES/TEC-English")

model = AutoModelForSeq2SeqLM.from_pretrained("KES/TEC-English")
text = "Dem men doh kno wat dey doing wid d money"
inputs = tokenizer("tec:"+text, truncation=True, return_tensors='pt')

output = model.generate(inputs['input_ids'], num_beams=4, max_length=512, early_stopping=True)
translation=tokenizer.batch_decode(output, skip_special_tokens=True)
print("".join(translation)) #translation: These men do not know what they are doing with the money.