---
base_model: BAAI/bge-m3
datasets: []
language: []
library_name: sentence-transformers
metrics:
- cosine_accuracy
- dot_accuracy
- manhattan_accuracy
- euclidean_accuracy
- max_accuracy
pipeline_tag: sentence-similarity
tags:
- sentence-transformers
- sentence-similarity
- feature-extraction
- generated_from_trainer
- dataset_size:39836
- loss:MultipleNegativesRankingLoss
widget:
- source_sentence: Seorang pria bertopi biru dan rompi keselamatan oranye berdiri
di persimpangan sambil memegang bendera.
sentences:
- Sekelompok orang menaiki eskalator, banyak dari mereka memegang payung.
- Seseorang berpakaian agar mudah terlihat.
- Seorang pria mengenakan topi keras oranye berdiri di persimpangan jalan.
- source_sentence: Dua anjing saling memandang di luar.
sentences:
- Ada dua anjing di luar.
- Empat anjing saling memandang di dalam.
- Seorang pria di luar gedung bata merah dengan kereta belanja, sepeda, dan lain-lain.
- source_sentence: Pria itu berdiri.
sentences:
- Seorang pria dan wanita duduk bersama di meja.
- Orang-orang di pasar petani luar ruangan.
- Seorang pria di kota di luar gedung berdiri di tangga.
- source_sentence: Seorang pria sedang tidur.
sentences:
- Seorang pria berselimut sedang tertidur di trotoar.
- Manusia ditutupi spons beraneka warna.
- Seorang pria tunawisma tertidur di trotoar.
- source_sentence: Orang-orang ada di luar.
sentences:
- Seorang pria berbaju kotak-kotak dan sandal putih sedang tertidur sambil membaca
koran.
- Orang-orang berjalan di luar dan mengenakan warna gelap.
- Sekelompok orang sedang makan di sebuah restoran dengan mural seorang wanita sedang
berbelanja di belakang mereka.
model-index:
- name: SentenceTransformer based on BAAI/bge-m3
results:
- task:
type: triplet
name: Triplet
dataset:
name: model evaluation
type: model-evaluation
metrics:
- type: cosine_accuracy
value: 0.9636322566071832
name: Cosine Accuracy
- type: dot_accuracy
value: 0.03636774339281681
name: Dot Accuracy
- type: manhattan_accuracy
value: 0.9625028235825616
name: Manhattan Accuracy
- type: euclidean_accuracy
value: 0.9636322566071832
name: Euclidean Accuracy
- type: max_accuracy
value: 0.9636322566071832
name: Max Accuracy
---
# SentenceTransformer based on BAAI/bge-m3
This is a [sentence-transformers](https://www.SBERT.net) model finetuned from [BAAI/bge-m3](https://huggingface.co/BAAI/bge-m3). It maps sentences & paragraphs to a 1024-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 Type:** Sentence Transformer
- **Base model:** [BAAI/bge-m3](https://huggingface.co/BAAI/bge-m3)
- **Maximum Sequence Length:** 8192 tokens
- **Output Dimensionality:** 1024 tokens
- **Similarity Function:** Cosine Similarity
### Model Sources
- **Documentation:** [Sentence Transformers Documentation](https://sbert.net)
- **Repository:** [Sentence Transformers on GitHub](https://github.com/UKPLab/sentence-transformers)
- **Hugging Face:** [Sentence Transformers on Hugging Face](https://huggingface.co/models?library=sentence-transformers)
### Full Model Architecture
```
SentenceTransformer(
(0): Transformer({'max_seq_length': 8192, 'do_lower_case': False}) with Transformer model: XLMRobertaModel
(1): Pooling({'word_embedding_dimension': 1024, 'pooling_mode_cls_token': True, 'pooling_mode_mean_tokens': False, 'pooling_mode_max_tokens': False, 'pooling_mode_mean_sqrt_len_tokens': False, 'pooling_mode_weightedmean_tokens': False, 'pooling_mode_lasttoken': False, 'include_prompt': True})
(2): Normalize()
)
```
## Usage
### Direct Usage (Sentence Transformers)
First install the Sentence Transformers library:
```bash
pip install -U sentence-transformers
```
Then you can load this model and run inference.
```python
from sentence_transformers import SentenceTransformer
# Download from the 🤗 Hub
model = SentenceTransformer("MarcoAland/Indo-bge-m3")
# Run inference
sentences = [
'Orang-orang ada di luar.',
'Orang-orang berjalan di luar dan mengenakan warna gelap.',
'Sekelompok orang sedang makan di sebuah restoran dengan mural seorang wanita sedang berbelanja di belakang mereka.',
]
embeddings = model.encode(sentences)
print(embeddings.shape)
# [3, 1024]
# Get the similarity scores for the embeddings
similarities = model.similarity(embeddings, embeddings)
print(similarities.shape)
# [3, 3]
```
## Evaluation
### Metrics
#### Triplet
* Dataset: `model-evaluation`
* Evaluated with [TripletEvaluator
](https://sbert.net/docs/package_reference/sentence_transformer/evaluation.html#sentence_transformers.evaluation.TripletEvaluator)
| Metric | Value |
|:-------------------|:-----------|
| cosine_accuracy | 0.9636 |
| dot_accuracy | 0.0364 |
| manhattan_accuracy | 0.9625 |
| euclidean_accuracy | 0.9636 |
| **max_accuracy** | **0.9636** |
## Training Details
### Training Dataset
#### Unnamed Dataset
* Size: 39,836 training samples
* Columns: anchor
, positive
, and negative
* Approximate statistics based on the first 1000 samples:
| | anchor | positive | negative |
|:--------|:---------------------------------------------------------------------------------|:----------------------------------------------------------------------------------|:----------------------------------------------------------------------------------|
| type | string | string | string |
| details |
Seseorang sedang tidur.
| Seorang pemuda tidur siang di jendela sebuah bisnis di pinggir jalan.
| Seseorang duduk di kursi yang digantung dengan rantai di taman hiburan.
|
| Seekor anjing sedang berlari.
| Seekor anjing abu-abu berlari di sepanjang rumput hijau.
| Seekor anjing coklat sedang menatap anjing coklat dan putih yang sedang tidur.
|
| Seorang bayi menangis.
| Seorang bayi menangis di tempat tidur bayi.
| Seorang bayi berbaring telentang dan tersenyum.
|
* Loss: [MultipleNegativesRankingLoss
](https://sbert.net/docs/package_reference/sentence_transformer/losses.html#multiplenegativesrankingloss) with these parameters:
```json
{
"scale": 20.0,
"similarity_fct": "cos_sim"
}
```
### Evaluation Dataset
#### Unnamed Dataset
* Size: 4,427 evaluation samples
* Columns: anchor
, positive
, and negative
* Approximate statistics based on the first 1000 samples:
| | anchor | positive | negative |
|:--------|:---------------------------------------------------------------------------------|:----------------------------------------------------------------------------------|:----------------------------------------------------------------------------------|
| type | string | string | string |
| details | Seorang pria sedang tidur.
| Seorang pria tidur di rumput di taman.
| Seorang pria membaca koran di samping mobil.
|
| Seorang pria sedang membaca buku.
| Seorang pria tua duduk di luar sambil membaca buku.
| Seorang pria berbaju pelangi berhenti untuk melihat kotak surat.
|
| Anjing coklat melangkah di air.
| Anjing coklat berjalan di air saat dia basah kuyup
| Anjing coklat sedang tidur di samping air
|
* Loss: [MultipleNegativesRankingLoss
](https://sbert.net/docs/package_reference/sentence_transformer/losses.html#multiplenegativesrankingloss) with these parameters:
```json
{
"scale": 20.0,
"similarity_fct": "cos_sim"
}
```
### Training Hyperparameters
#### Non-Default Hyperparameters
- `eval_strategy`: steps
- `per_device_train_batch_size`: 4
- `per_device_eval_batch_size`: 4
- `max_steps`: 500
- `warmup_ratio`: 0.1
- `batch_sampler`: no_duplicates
#### All Hyperparameters