Update README.md
Browse files
README.md
CHANGED
@@ -55,7 +55,7 @@ kao i korpus [PDRS 1.0](https://www.clarin.si/repository/xmlui/handle/11356/1752
|
|
55 |
|
56 |
```python
|
57 |
>>> from transformers import pipeline
|
58 |
-
>>>
|
59 |
>>> unmasker("Kada bi čovek znao gde će pasti on bi<mask>.")
|
60 |
```
|
61 |
|
@@ -84,8 +84,8 @@ kao i korpus [PDRS 1.0](https://www.clarin.si/repository/xmlui/handle/11356/1752
|
|
84 |
>>> vektor_x = model(input_ids=tensor_x).hidden_states[-1].squeeze()
|
85 |
>>> vektor_y = model(input_ids=tensor_y).hidden_states[-1].squeeze()
|
86 |
>>> vektor_z = model(input_ids=tensor_z).hidden_states[-1].squeeze()
|
87 |
-
>>>
|
88 |
-
>>>
|
89 |
```
|
90 |
|
91 |
```
|
|
|
55 |
|
56 |
```python
|
57 |
>>> from transformers import pipeline
|
58 |
+
>>> unmasker = pipeline('fill-mask', model='jerteh/jerteh-81')
|
59 |
>>> unmasker("Kada bi čovek znao gde će pasti on bi<mask>.")
|
60 |
```
|
61 |
|
|
|
84 |
>>> vektor_x = model(input_ids=tensor_x).hidden_states[-1].squeeze()
|
85 |
>>> vektor_y = model(input_ids=tensor_y).hidden_states[-1].squeeze()
|
86 |
>>> vektor_z = model(input_ids=tensor_z).hidden_states[-1].squeeze()
|
87 |
+
>>> print(spatial.distance.cosine(vektor_x, vektor_y))
|
88 |
+
>>> print(spatial.distance.cosine(vektor_x, vektor_z))
|
89 |
```
|
90 |
|
91 |
```
|