Downloads · 30 days
10
53% of all-time downloads
MittyN/m2m100_418M_en_fa_slang
m2m100_418M_en_fa_slang is a translation model from MittyN. Use it when you need text moved from one language to another. It is set up for transformers.
This model is based on the M2M100 418M Facebook model and trained with approximately one million and 600 thousand pairs of English text with Persian human translation. The training data consists of colloquial conversa…
Downloads · 30 days
10
53% of all-time downloads
All-time downloads
19
Public
Repo size
2.5 MB
Likes
0
Public
Click a slice to open those files.
.json3.8 MB · 61%
From the Hugging Face model README
This model is based on the M2M100 418M Facebook model and trained with approximately one million and 600 thousand pairs of English text with Persian human translation. The training data consists of colloquial conversations, resulting in fluent and colloquial translations. This model is designed to facilitate the translation of informal English conversations to Persian.
config.json includes the specifications below:
The model's performance was evaluated using the sacrebleu metric on a separate test dataset. The results are as follows:
from transformers import M2M100ForConditionalGeneration, M2M100Tokenizer
model_name = "MittyN/convo_en_to_fa"
model = M2M100ForConditionalGeneration.from_pretrained(model_name)
tokenizer = M2M100Tokenizer.from_pretrained(model_name)
# English text to translate
english_text = "Last night's party was lit!"
# Tokenize and translate
input_ids = tokenizer.encode(english_text, return_tensors="pt")
translated_ids = model.generate(input_ids)
translated_text = tokenizer.decode(translated_ids[0])
print(translated_text) # Output: "مهمونی دیشب عالی بود!"
You can further fine-tune this model on specific downstream tasks or domains by using Hugging Face's Transformers library. Refer to the official documentation for guidance on fine-tuning procedures and techniques.
⚠️ Caution: This model has been trained on colloquial and informal conversational data, aiming to produce translations that closely resemble the vernacular language used by people. While it generally generates accurate and fluent translations, it is important to be aware that it has the possibility of producing words or phrases that some individuals may find objectionable or inappropriate.
Please exercise caution and responsibility when using this model, especially in situations where communication with others is involved. The generated translations should be carefully reviewed and edited to ensure they align with the intended context and comply with social norms and guidelines.
The developer and contributors of this model cannot be held responsible for any potential misuse or unintended consequences resulting from the use of the model. It is the user's responsibility to review and refine the generated translations to ensure they meet their specific requirements, conform to acceptable standards, and are suitable for the target audience.
We strongly recommend that users exercise due diligence and employ human judgment to validate and modify the model's outputs before disseminating them in public or sensitive settings. It is essential to consider cultural, linguistic, and ethical factors to ensure respectful and appropriate communication.
For any questions, suggestions, or issues related to this model, please feel free to reach out to the model developer at [email protected]. This model is released under the open-source license, allowing researchers and developers to use it for their projects and experiments.