Views
No views yet
bge-m3-ml-tr-specialized is a Sentence Transformer model optimized for scientific and technical machine learning texts in Turkish. Based on BAAI/bge-m3, the model has been fine-tuned for tasks such as sentence similarity, semantic search, conceptual matching, and meaning-based classification.1SentenceTransformer(
2 (0): Transformer({'max_seq_length': 8192, 'architecture': 'XLMRobertaModel'})
3 (1): Pooling({'word_embedding_dimension': 1024, 'pooling_mode_cls_token': True})
4 (2): Normalize()
5)pip install -U sentence-transformers1from sentence_transformers import SentenceTransformer
2
3model = SentenceTransformer("dogukanvzr/bge-m3-ml-tr-specialized")
4
5sentences = [
6 "Accuracy refers to how close a model's predictions are to the actual values.",
7 "Model accuracy indicates how well the predictions align with true labels.",
8 "Feature engineering plays a critical role in machine learning pipelines."
9]
10
11embeddings = model.encode(sentences)
12
13from sklearn.metrics.pairwise import cosine_similarity
14scores = cosine_similarity([embeddings[0]], embeddings[1:])
15print(scores)ml-paraphrase-trsentence_0, sentence_1, label (float between 0.0–1.0 indicating similarity)CosineSimilarityLoss (internally uses MSELoss)| Epoch | Step | Average Loss |
|---|---|---|
| 0.5 | 500 | 0.0338 |
| 1.0 | 1000 | 0.0188 |
| 1.5 | 1500 | 0.0147 |
| 2.0 | 2000 | 0.0127 |
| 2.5 | 2500 | 0.0105 |
1s1 = "Machine learning algorithms learn from past data to make future predictions."
2s2 = "The model performs inference based on learned patterns."
3s3 = "The size of the dataset can affect the generalization capacity of the model."
4
5embs = model.encode([s1, s2, s3])
6from sklearn.metrics.pairwise import cosine_similarity
7sim = cosine_similarity([embs[0]], embs[1:])
8print(sim)1@inproceedings{reimers-2019-sentence-bert,
2 title = "Sentence-BERT: Sentence Embeddings using Siamese BERT-Networks",
3 author = "Reimers, Nils and Gurevych, Iryna",
4 booktitle = "Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing",
5 month = "11",
6 year = "2019",
7 publisher = "Association for Computational Linguistics",
8 url = "https://arxiv.org/abs/1908.10084",
9}ml-paraphrase-tr