Prikshit7766
commited on
Update README.md
Browse files
README.md
CHANGED
@@ -1,59 +1,72 @@
|
|
1 |
-
|
2 |
-
|
3 |
-
|
4 |
-
|
5 |
-
|
6 |
-
|
7 |
-
|
8 |
-
|
9 |
-
|
10 |
-
-
|
11 |
-
|
12 |
-
|
13 |
-
|
14 |
-
|
15 |
-
|
16 |
-
|
17 |
-
|
18 |
-
|
19 |
-
|
20 |
-
|
21 |
-
|
22 |
-
|
23 |
-
|
24 |
-
|
25 |
-
- Training
|
26 |
-
|
27 |
-
|
28 |
-
|
29 |
-
|
30 |
-
|
31 |
-
|
32 |
-
|
33 |
-
|
34 |
-
|
35 |
-
|
36 |
-
|
37 |
-
|
38 |
-
|
39 |
-
|
40 |
-
|
41 |
-
|
42 |
-
|
43 |
-
|
44 |
-
|
45 |
-
|
46 |
-
|
47 |
-
|
48 |
-
|
49 |
-
|
50 |
-
|
51 |
-
|
52 |
-
|
53 |
-
|
54 |
-
|
55 |
-
|
56 |
-
|
57 |
-
|
58 |
-
|
59 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
---
|
2 |
+
datasets:
|
3 |
+
- Helsinki-NLP/kde4
|
4 |
+
language:
|
5 |
+
- en
|
6 |
+
- fr
|
7 |
+
metrics:
|
8 |
+
- sacrebleu
|
9 |
+
base_model:
|
10 |
+
- Helsinki-NLP/opus-mt-en-fr
|
11 |
+
pipeline_tag: translation
|
12 |
+
library_name: transformers
|
13 |
+
---
|
14 |
+
# Marian Fine-tuned English-French Translation Model
|
15 |
+
|
16 |
+
## Model Description
|
17 |
+
|
18 |
+
This model is a fine-tuned version of `Helsinki-NLP/opus-mt-en-fr`, specifically trained for English to French translation. The base model was further trained on the `KDE4` dataset to improve translation quality for technical and software-related content.
|
19 |
+
|
20 |
+
## Model Training Details
|
21 |
+
|
22 |
+
### Training Dataset
|
23 |
+
- **Dataset**: KDE4 Dataset (English-French parallel corpus)
|
24 |
+
- **Split Distribution**:
|
25 |
+
- Training set: 189,155 examples (90%)
|
26 |
+
- Test set: 21,018 examples (10%)
|
27 |
+
|
28 |
+
### Training Configuration
|
29 |
+
- **Base Model**: Helsinki-NLP/opus-mt-en-fr
|
30 |
+
- **Training Arguments**:
|
31 |
+
- Learning rate: 2e-5
|
32 |
+
- Batch size: 32 (training), 64 (evaluation)
|
33 |
+
- Number of epochs: 10
|
34 |
+
- Weight decay: 0.01
|
35 |
+
- FP16 training enabled
|
36 |
+
- Evaluation strategy: Before and after training
|
37 |
+
- Checkpoint saving: Every epoch (maximum 3 saved)
|
38 |
+
- Training device: GPU with mixed precision (fp16)
|
39 |
+
|
40 |
+
## Model Results
|
41 |
+
|
42 |
+
### Evaluation Metrics
|
43 |
+
|
44 |
+
The model was evaluated using the BLEU score. The evaluation results before and after training are summarized in the table below:
|
45 |
+
|
46 |
+
| **Stage** | **Eval Loss** | **BLEU Score** |
|
47 |
+
|--------------------|---------------|----------------|
|
48 |
+
| **Before Training** | 1.700 | 38.97 |
|
49 |
+
| **After Training** | 0.796 | 54.96 |
|
50 |
+
|
51 |
+
|
52 |
+
### Training Loss
|
53 |
+
|
54 |
+
The training loss decreased over the epochs, indicating that the model was learning effectively. The final training loss was approximately 0.710.
|
55 |
+
|
56 |
+
|
57 |
+
## Model Usage
|
58 |
+
|
59 |
+
|
60 |
+
```python
|
61 |
+
from transformers import pipeline
|
62 |
+
|
63 |
+
model_checkpoint = "Prikshit7766/marian-finetuned-kde4-en-to-fr"
|
64 |
+
translator = pipeline("translation", model=model_checkpoint)
|
65 |
+
translator("Default to expanded threads")
|
66 |
+
```
|
67 |
+
|
68 |
+
### Example Output
|
69 |
+
|
70 |
+
```plaintext
|
71 |
+
[{'translation_text': 'Par défaut, développer les fils de discussion'}]
|
72 |
+
```
|