provide example code
Browse files
README.md
CHANGED
@@ -19,8 +19,23 @@ pinned: false
|
|
19 |
|
20 |
## How to Use
|
21 |
*Give general statement of how to use the metric*
|
|
|
|
|
22 |
|
23 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
24 |
|
25 |
### Inputs
|
26 |
*List all input arguments in the format below*
|
|
|
19 |
|
20 |
## How to Use
|
21 |
*Give general statement of how to use the metric*
|
22 |
+
```python
|
23 |
+
import evaluate
|
24 |
|
25 |
+
jer = evaluate.load('bdsaglam/jer')
|
26 |
+
|
27 |
+
predictions = [
|
28 |
+
["Baris | play | tennis", "Deniz | travel | London"],
|
29 |
+
["Erdem | like | pasta", "Sena | watch | movie"],
|
30 |
+
]
|
31 |
+
|
32 |
+
references = [
|
33 |
+
["Baris | play | tennis"],
|
34 |
+
["Sena | watch | movie", "Ayhan | grow | tomato"]
|
35 |
+
]
|
36 |
+
|
37 |
+
jer.compute(predictions=predictions, references=references)
|
38 |
+
```
|
39 |
|
40 |
### Inputs
|
41 |
*List all input arguments in the format below*
|