Views
No views yet
transformers library. Below is an example of how to load and use the model:1from transformers import AutoTokenizer, AutoModelForCausalLM
2
3# Load the tokenizer and model
4tokenizer = AutoTokenizer.from_pretrained("bajpaideeksha/hinglish-translation")
5model = AutoModelForCausalLM.from_pretrained("bajpaideeksha/hinglish-translation")
6
7# Input text
8input_text = "Did you prepone the meeting?"
9
10# Tokenize input
11inputs = tokenizer(input_text, return_tensors="pt")
12
13# Generate output
14outputs = model.generate(**inputs, max_length=50)
15
16# Decode and print the output
17print(tokenizer.decode(outputs[0], skip_special_tokens=True))
18
19
20**Training Details
21
22Dataset
23The model was fine-tuned on a custom dataset of 3080 English-Hinglish sentence pairs. The dataset includes colloquial phrases, humor, and regional variations.
24
25Training Parameters
26Base model: GPT-2
27
28Fine-tuning method: LoRA (Low-Rank Adaptation)
29
30Epochs: 5
31
32Batch size: 2
33
34Learning rate: 2e-5
35
36FP16 mixed precision: Enabled
37
38Hardware
39GPU: NVIDIA T4 (Google Colab)
40
41Training time: ~1 hour
42
43Limitations
44Small Dataset: The model is trained on a relatively small dataset (3080 rows), so it may not generalize well to all types of sentences.
45
46Complex Sentences: The model may struggle with complex or highly technical sentences.
47
48Regional Variations: While the model handles some regional variations, it may not capture all dialects of Hinglish.
49
50Humor and Context: The model may not always understand humor or context perfectly.
51
52Ethical Considerations
53Bias: The model may inherit biases present in the training data. Use with caution in sensitive applications.
54
55Misuse: The model should not be used for generating harmful, offensive, or misleading content.
56
57License
58This model is licensed under the MIT License. See the LICENSE file for more details.
59
60
61Thank you for using the Hinglish Translation Model! 😊
62
63