Downloads · 30 days
9
0% of all-time downloads
Aminrhmni/PersianAutomaticPunctuation
PersianAutomaticPunctuation is a machine learning model from Aminrhmni. Use it for the machine learning task on the model card, and read the license before you ship it in a product. It is set up for transformers. The card lists the license as mit.
This model is intended for non-commercial use only. If you wish to use it commercially, please refer to this LinkedIn address.
Downloads · 30 days
9
0% of all-time downloads
All-time downloads
2.1K
Public
Parameters
582M
4.7 GB on disk
Likes
0
Public
Click a slice to open those files.
.bin2.3 GB · 50%
From the Hugging Face model README
***This model is intended for non-commercial use only. If you wish to use it commercially, please refer to this LinkedIn address.
https://www.linkedin.com/in/amin-rahmani-41417b121/
"Viravirast" is an editor based on transformer algorithms. By visiting Viravirast.com, you can use a Persian semantic and structural text editor.
***Use this code in order to get the complete and correct sentence
from transformers import ( T5Tokenizer, MT5ForConditionalGeneration, Text2TextGenerationPipeline, )
path = ""
pipe = Text2TextGenerationPipeline( model=MT5ForConditionalGeneration.from_pretrained(path), tokenizer=T5Tokenizer.from_pretrained(path), )
sentence = "ویراویراست یک نرم افزار ویرایش متن ساختاری و معنایی زبان فارسی است چیزی شبیه به گرامرلی در زبان انگلیسی"
#res = pipe(sentence, max_length=100, num_beams=4
res = pipe(sentence, max_length=100)
print(res[0]['generated_text'])
n_epochs = 4
train_batch_size = 8
eval_batch_size = 4
lr = 5e-4
Training_Loss=0.00550
Validation_Loss=0.052046