Model Background

This model, XL-DURel, is trained on ordinal WiC data and it is optimized using AnglE Loss (Li & Li, 2023).

For more details, see our paper: XL-DURel: Finetuning Sentence Transformers for Ordinal Word-in-Context Classification

Reproducing Results

To reproduce the results presented in the XL-DURel paper, please follow the instructions in our GitHub repository:XL-DURel Reproduction Instructions

Usage

Using this model becomes easy when you have sentence-transformers installed:

pip install -U sentence-transformers

Then you can use the model like this:

from sentence_transformers import SentenceTransformer
sentences = ["This is an example sentence", "Each sentence is converted"]

model = SentenceTransformer("sachinn1/xl-durel")
embeddings = model.encode(sentences)
print(embeddings)

Training

The model was trained with the parameters:

DataLoader:

torch.utils.data.dataloader.DataLoader of length 9369 with parameters:

{'batch_size': 32, 'sampler': 'torch.utils.data.sampler.RandomSampler', 'batch_sampler': 'torch.utils.data.sampler.BatchSampler'}

Loss:

sentence_transformers.losses.AnglELoss.AnglELoss with parameters:

{'scale': 20.0, 'similarity_fct': 'pairwise_angle_sim'}

Parameters of the fit()-Method:

{
    "epochs": 10,
    "evaluation_steps": 2342,
    "evaluator": "WordTransformer.EmbeddingSimilarityEvaluator.EmbeddingSimilarityEvaluator",
    "max_grad_norm": 1,
    "optimizer_class": "<class 'transformers.optimization.AdamW'>",
    "optimizer_params": {
        "lr": 1e-05
    },
    "scheduler": "WarmupLinear",
    "steps_per_epoch": null,
    "warmup_steps": 9369,
    "weight_decay": 0.0
}

Citing & Authors

@misc{yadav2025xldurelfinetuningsentencetransformers,
      title={XL-DURel: Finetuning Sentence Transformers for Ordinal Word-in-Context Classification}, 
      author={Sachin Yadav and Dominik Schlechtweg},
      year={2025},
      eprint={2507.14578},
      archivePrefix={arXiv},
      primaryClass={cs.CL},
      url={https://arxiv.org/abs/2507.14578}, 
}
Downloads last month
7
Safetensors
Model size
0.6B params
Tensor type
F32
·
Inference Providers NEW
This model isn't deployed by any Inference Provider. 🙋 Ask for provider support

Papers for sachinn1/xl-durel