update example
Browse files
README.md
CHANGED
|
@@ -123,20 +123,24 @@ import comet_early_exit
|
|
| 123 |
model = comet_early_exit.load_from_checkpoint(comet_early_exit.download_model("zouharvi/COMET-partial"))
|
| 124 |
data = [
|
| 125 |
{
|
| 126 |
-
"src": "
|
| 127 |
-
"mt": "Ich
|
| 128 |
},
|
| 129 |
{
|
| 130 |
-
"src": "
|
| 131 |
-
"mt": "
|
| 132 |
},
|
| 133 |
{
|
| 134 |
-
"src": "
|
| 135 |
-
"mt": "
|
| 136 |
},
|
| 137 |
{
|
| 138 |
-
"src": "
|
| 139 |
-
"mt": "
|
|
|
|
|
|
|
|
|
|
|
|
|
| 140 |
}
|
| 141 |
]
|
| 142 |
model_output = model.predict(data, batch_size=8, gpus=1)
|
|
@@ -144,7 +148,7 @@ print("scores", model_output["scores"])
|
|
| 144 |
```
|
| 145 |
Outputs (formatted):
|
| 146 |
```
|
| 147 |
-
scores 89.
|
| 148 |
```
|
| 149 |
|
| 150 |
This model is based on the work [Early-Exit and Instant Confidence Translation Quality Estimation](http://arxiv.org/abs/2502.14429) which can be cited as:
|
|
|
|
| 123 |
model = comet_early_exit.load_from_checkpoint(comet_early_exit.download_model("zouharvi/COMET-partial"))
|
| 124 |
data = [
|
| 125 |
{
|
| 126 |
+
"src": "I want to receive my food in 10 to 15 minutes.",
|
| 127 |
+
"mt": "Ich werde",
|
| 128 |
},
|
| 129 |
{
|
| 130 |
+
"src": "I want to receive my food in 10 to 15 minutes.",
|
| 131 |
+
"mt": "Ich möchte",
|
| 132 |
},
|
| 133 |
{
|
| 134 |
+
"src": "I want to receive my food in 10 to 15 minutes.",
|
| 135 |
+
"mt": "Ich möchte mein Essen in",
|
| 136 |
},
|
| 137 |
{
|
| 138 |
+
"src": "I want to receive my food in 10 to 15 minutes.",
|
| 139 |
+
"mt": "Ich möchte mein Essen in 10 bis 15 Minuten erhalten.",
|
| 140 |
+
},
|
| 141 |
+
{
|
| 142 |
+
"src": "I want to receive my food in 10 to 15 minutes.",
|
| 143 |
+
"mt": "Ich möchte mein Essen in 10 bis 15 Minuten bekommen.",
|
| 144 |
}
|
| 145 |
]
|
| 146 |
model_output = model.predict(data, batch_size=8, gpus=1)
|
|
|
|
| 148 |
```
|
| 149 |
Outputs (formatted):
|
| 150 |
```
|
| 151 |
+
scores 89.26 89.45 89.51 89.48 89.66
|
| 152 |
```
|
| 153 |
|
| 154 |
This model is based on the work [Early-Exit and Instant Confidence Translation Quality Estimation](http://arxiv.org/abs/2502.14429) which can be cited as:
|