SentenceTransformer based on sentence-transformers/paraphrase-multilingual-MiniLM-L12-v2
This is a sentence-transformers model finetuned from sentence-transformers/paraphrase-multilingual-MiniLM-L12-v2 on the statictable-triplets-all dataset. It maps sentences & paragraphs to a 384-dimensional dense vector space and can be used for semantic textual similarity, semantic search, paraphrase mining, text classification, clustering, and more.
Model Details
Model Description
Model Sources
Full Model Architecture
SentenceTransformer(
(0): Transformer({'max_seq_length': 128, 'do_lower_case': False}) with Transformer model: BertModel
(1): Pooling({'word_embedding_dimension': 384, 'pooling_mode_cls_token': False, 'pooling_mode_mean_tokens': True, 'pooling_mode_max_tokens': False, 'pooling_mode_mean_sqrt_len_tokens': False, 'pooling_mode_weightedmean_tokens': False, 'pooling_mode_lasttoken': False, 'include_prompt': True})
)
Usage
Direct Usage (Sentence Transformers)
First install the Sentence Transformers library:
pip install -U sentence-transformers
Then you can load this model and run inference.
from sentence_transformers import SentenceTransformer
model = SentenceTransformer("yahyaabd/paraphrase-multilingual-miniLM-L12-v2-mnrl-beir")
sentences = [
'Bagaimana tren ekspor teh Indonesia ke berbagai negara tahun 2008?',
'Ekspor Teh Menurut Negara Tujuan Utama, 2000-2015',
'Luas Kawasan Hutan dan Kawasan Konservasi Perairan Indonesia Berdasarkan Surat Keputusan Menteri Lingkungan Hidup dan Kehutanan, 2017-2022',
]
embeddings = model.encode(sentences)
print(embeddings.shape)
similarities = model.similarity(embeddings, embeddings)
print(similarities.shape)
Evaluation
Metrics
Information Retrieval
| Metric |
Value |
| cosine_accuracy@1 |
0.3648 |
| cosine_accuracy@5 |
0.6319 |
| cosine_accuracy@10 |
0.7199 |
| cosine_precision@1 |
0.3648 |
| cosine_precision@5 |
0.159 |
| cosine_precision@10 |
0.1088 |
| cosine_recall@1 |
0.2757 |
| cosine_recall@5 |
0.4928 |
| cosine_recall@10 |
0.5744 |
| cosine_ndcg@1 |
0.3648 |
| cosine_ndcg@5 |
0.4404 |
| cosine_ndcg@10 |
0.4644 |
| cosine_mrr@1 |
0.3648 |
| cosine_mrr@5 |
0.4639 |
| cosine_mrr@10 |
0.4758 |
| cosine_map@1 |
0.3648 |
| cosine_map@5 |
0.3868 |
| cosine_map@10 |
0.3942 |
Training Details
Training Dataset
statictable-triplets-all
Evaluation Dataset
statictable-triplets-all
Training Logs
| Epoch |
Step |
bps-statictable-ir_cosine_ndcg@10 |
| 0 |
0 |
0.4644 |
Framework Versions
- Python: 3.11.11
- Sentence Transformers: 3.4.1
- Transformers: 4.48.3
- PyTorch: 2.6.0+cu124
- Accelerate: 1.3.0
- Datasets: 3.4.1
- Tokenizers: 0.21.1
Citation
BibTeX
Sentence Transformers
@inproceedings{reimers-2019-sentence-bert,
title = "Sentence-BERT: Sentence Embeddings using Siamese BERT-Networks",
author = "Reimers, Nils and Gurevych, Iryna",
booktitle = "Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing",
month = "11",
year = "2019",
publisher = "Association for Computational Linguistics",
url = "https://arxiv.org/abs/1908.10084",
}
MultipleNegativesRankingLoss
@misc{henderson2017efficient,
title={Efficient Natural Language Response Suggestion for Smart Reply},
author={Matthew Henderson and Rami Al-Rfou and Brian Strope and Yun-hsuan Sung and Laszlo Lukacs and Ruiqi Guo and Sanjiv Kumar and Balint Miklos and Ray Kurzweil},
year={2017},
eprint={1705.00652},
archivePrefix={arXiv},
primaryClass={cs.CL}
}