đ Model Card for Gemma-2b-mt-Hindi-Fintuned
This is a fine - tuned multilingual transformer model optimized for English - to - Hindi translation, leveraging the GEMMA architecture for accurate and efficient results.
đ Quick Start
Use the code below to get started with the model:
from transformers import AutoTokenizer, AutoModelForCausalLM
tokenizer = AutoTokenizer.from_pretrained("Satwik11/gemma-2b-mt-Hindi-Fintuned")
model = AutoModelForCausalLM.from_pretrained("Satwik11/gemma-2b-mt-Hindi-Fintuned")
def generate_translation(prompt, max_length=90):
inputs = tokenizer(prompt, return_tensors='pt')
outputs = model.generate(**inputs, max_length=max_length)
translated_text = tokenizer.decode(outputs[0], skip_special_tokens=True)
return translated_text
test_sentences = [
"Today is August 19.The maximum temperature is 70 degrees Fahrenheit"
]
for sentence in test_sentences:
prompt = f"Translate the following English text to Hindi: {sentence}"
translation = generate_translation(prompt)
print(translation)
⨠Features
Direct Use
This model can be directly used for translating English text to Hindi. It is suitable for various applications such as:
- Localization of content
- Cross - lingual communication
- Educational tools for language learning
- Multilingual content creation
Downstream Use
The model can be integrated into larger systems or applications that require English to Hindi translation capabilities, such as:
- Machine translation services
- Multilingual chatbots
- Content management systems for multilingual websites
đ§ Technical Details
Model Description
This model is a fine - tuned version of the GEMMA 2B multilingual transformer, specifically optimized for translating text from English to Hindi. It leverages the capabilities of the original GEMMA architecture to provide accurate and efficient translations.
Property |
Details |
Model Name |
Gemma - 2b - mt - Hindi - Fintuned |
Model Type |
Language Translation Model |
Base Model |
Gemma - 2b |
Task |
English to Hindi Translation |
Framework |
Transformers |
Training Data
The model was fine - tuned on the cfilt/iitb - english - hindi dataset, which contains English - Hindi sentence pairs. For more details about the dataset, refer to the dataset card on Hugging Face.
đ License
This model is licensed under the Apache - 2.0 license.
â ī¸ Important Note
- The model may struggle with idiomatic expressions or culturally specific content.
- There might be potential biases in the training data that could affect translation quality.
- The model's performance on specialized or technical content may vary.
- It may have limitations in handling complex grammatical structures or maintaining context in longer texts.
đĄ Usage Tip
- It's recommended to use the model in conjunction with human translators for high - stakes or nuanced translations.
- Regular evaluation and fine - tuning with diverse and representative data can help mitigate biases and improve performance.
đ Documentation
For more information, please contact the model creators through the Hugging Face model repository: https://www.linkedin.com/in/satwik-sinha/