Metadata-Version: 2.1
Name: WordTransformer
Version: 0.0.3
Summary: WiC Pretrained Model for Cross-Lingual LEXical sEMantic changE
Author-email: Pierluigi Cassotti <p@x.com>
Requires-Python: >=3.8
Description-Content-Type: text/markdown
Requires-Dist: sentence-transformers ==2.3.0
Requires-Dist: huggingface-hub >=0.26.2
Requires-Dist: torch >=2.5.1
Requires-Dist: tqdm >=4.66.6
Requires-Dist: transformers >=4.46.1
Requires-Dist: numpy >=2.1.2

# XL-LEXEME
WiC Pretrained Model for Cross-Lingual LEXical sEMantic changE
(https://aclanthology.org/2023.acl-short.135.pdf)

Install the library:
```
git clone git@github.com:pierluigic/xl-lexeme.git
cd xl-lexeme
pip3 install .
```

Load the model (the model is available in the Hugging Face Model Hub https://huggingface.co/pierluigic/xl-lexeme):
```python
from WordTransformer import WordTransformer,InputExample

model = WordTransformer('pierluigic/xl-lexeme')

examples = InputExample(texts="the quick fox jumps over the lazy dog", positions=[10,13])
fox_embedding = model.encode(examples) #The embedding of the target word "fox"
```


<b> Citation </b>

```
@inproceedings{cassotti-etal-2023-xl,
    title = "{XL}-{LEXEME}: {W}i{C} Pretrained Model for Cross-Lingual {LEX}ical s{EM}antic chang{E}",
    author = "Cassotti, Pierluigi  and
      Siciliani, Lucia  and
      DeGemmis, Marco  and
      Semeraro, Giovanni  and
      Basile, Pierpaolo",
    booktitle = "Proceedings of the 61st Annual Meeting of the Association for Computational Linguistics (Volume 2: Short Papers)",
    month = jul,
    year = "2023",
    address = "Toronto, Canada",
    publisher = "Association for Computational Linguistics",
    url = "https://aclanthology.org/2023.acl-short.135",
    pages = "1577--1585"
}
```
