Omartificial-Intelligence-Space
commited on
Commit
•
371ff09
1
Parent(s):
2f7a59f
Add new SentenceTransformer model.
Browse files- .gitattributes +1 -0
- 1_Pooling/config.json +10 -0
- README.md +739 -0
- config.json +26 -0
- config_sentence_transformers.json +10 -0
- model.safetensors +3 -0
- modules.json +20 -0
- sentence_bert_config.json +4 -0
- sentencepiece.bpe.model +3 -0
- special_tokens_map.json +51 -0
- tokenizer.json +3 -0
- tokenizer_config.json +55 -0
.gitattributes
CHANGED
@@ -33,3 +33,4 @@ saved_model/**/* filter=lfs diff=lfs merge=lfs -text
|
|
33 |
*.zip filter=lfs diff=lfs merge=lfs -text
|
34 |
*.zst filter=lfs diff=lfs merge=lfs -text
|
35 |
*tfevents* filter=lfs diff=lfs merge=lfs -text
|
|
|
|
33 |
*.zip filter=lfs diff=lfs merge=lfs -text
|
34 |
*.zst filter=lfs diff=lfs merge=lfs -text
|
35 |
*tfevents* filter=lfs diff=lfs merge=lfs -text
|
36 |
+
tokenizer.json filter=lfs diff=lfs merge=lfs -text
|
1_Pooling/config.json
ADDED
@@ -0,0 +1,10 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"word_embedding_dimension": 384,
|
3 |
+
"pooling_mode_cls_token": false,
|
4 |
+
"pooling_mode_mean_tokens": true,
|
5 |
+
"pooling_mode_max_tokens": false,
|
6 |
+
"pooling_mode_mean_sqrt_len_tokens": false,
|
7 |
+
"pooling_mode_weightedmean_tokens": false,
|
8 |
+
"pooling_mode_lasttoken": false,
|
9 |
+
"include_prompt": true
|
10 |
+
}
|
README.md
ADDED
@@ -0,0 +1,739 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
---
|
2 |
+
language: []
|
3 |
+
library_name: sentence-transformers
|
4 |
+
tags:
|
5 |
+
- sentence-transformers
|
6 |
+
- sentence-similarity
|
7 |
+
- feature-extraction
|
8 |
+
- generated_from_trainer
|
9 |
+
- dataset_size:557850
|
10 |
+
- loss:MatryoshkaLoss
|
11 |
+
- loss:MultipleNegativesRankingLoss
|
12 |
+
base_model: intfloat/multilingual-e5-small
|
13 |
+
datasets: []
|
14 |
+
metrics:
|
15 |
+
- pearson_cosine
|
16 |
+
- spearman_cosine
|
17 |
+
- pearson_manhattan
|
18 |
+
- spearman_manhattan
|
19 |
+
- pearson_euclidean
|
20 |
+
- spearman_euclidean
|
21 |
+
- pearson_dot
|
22 |
+
- spearman_dot
|
23 |
+
- pearson_max
|
24 |
+
- spearman_max
|
25 |
+
widget:
|
26 |
+
- source_sentence: ذكر متوازن بعناية يقف على قدم واحدة بالقرب من منطقة شاطئ المحيط
|
27 |
+
النظيفة
|
28 |
+
sentences:
|
29 |
+
- رجل يقدم عرضاً
|
30 |
+
- هناك رجل بالخارج قرب الشاطئ
|
31 |
+
- رجل يجلس على أريكه
|
32 |
+
- source_sentence: رجل يقفز إلى سريره القذر
|
33 |
+
sentences:
|
34 |
+
- السرير قذر.
|
35 |
+
- رجل يضحك أثناء غسيل الملابس
|
36 |
+
- الرجل على القمر
|
37 |
+
- source_sentence: الفتيات بالخارج
|
38 |
+
sentences:
|
39 |
+
- امرأة تلف الخيط إلى كرات بجانب كومة من الكرات
|
40 |
+
- فتيان يركبان في جولة متعة
|
41 |
+
- ثلاث فتيات يقفون سوية في غرفة واحدة تستمع وواحدة تكتب على الحائط والثالثة تتحدث
|
42 |
+
إليهن
|
43 |
+
- source_sentence: الرجل يرتدي قميصاً أزرق.
|
44 |
+
sentences:
|
45 |
+
- رجل يرتدي قميصاً أزرق يميل إلى الجدار بجانب الطريق مع شاحنة زرقاء وسيارة حمراء
|
46 |
+
مع الماء في الخلفية.
|
47 |
+
- كتاب القصص مفتوح
|
48 |
+
- رجل يرتدي قميص أسود يعزف على الجيتار.
|
49 |
+
- source_sentence: يجلس شاب ذو شعر أشقر على الحائط يقرأ جريدة بينما تمر امرأة وفتاة
|
50 |
+
شابة.
|
51 |
+
sentences:
|
52 |
+
- ذكر شاب ينظر إلى جريدة بينما تمر إمرأتان بجانبه
|
53 |
+
- رجل يستلقي على وجهه على مقعد في الحديقة.
|
54 |
+
- الشاب نائم بينما الأم تقود ابنتها إلى الحديقة
|
55 |
+
pipeline_tag: sentence-similarity
|
56 |
+
model-index:
|
57 |
+
- name: SentenceTransformer based on intfloat/multilingual-e5-small
|
58 |
+
results:
|
59 |
+
- task:
|
60 |
+
type: semantic-similarity
|
61 |
+
name: Semantic Similarity
|
62 |
+
dataset:
|
63 |
+
name: sts test 384
|
64 |
+
type: sts-test-384
|
65 |
+
metrics:
|
66 |
+
- type: pearson_cosine
|
67 |
+
value: 0.7883137447514015
|
68 |
+
name: Pearson Cosine
|
69 |
+
- type: spearman_cosine
|
70 |
+
value: 0.7971624317482785
|
71 |
+
name: Spearman Cosine
|
72 |
+
- type: pearson_manhattan
|
73 |
+
value: 0.7845904338398069
|
74 |
+
name: Pearson Manhattan
|
75 |
+
- type: spearman_manhattan
|
76 |
+
value: 0.7939541836133244
|
77 |
+
name: Spearman Manhattan
|
78 |
+
- type: pearson_euclidean
|
79 |
+
value: 0.7882887522003604
|
80 |
+
name: Pearson Euclidean
|
81 |
+
- type: spearman_euclidean
|
82 |
+
value: 0.7971601260546269
|
83 |
+
name: Spearman Euclidean
|
84 |
+
- type: pearson_dot
|
85 |
+
value: 0.7883137483129774
|
86 |
+
name: Pearson Dot
|
87 |
+
- type: spearman_dot
|
88 |
+
value: 0.7971605875966696
|
89 |
+
name: Spearman Dot
|
90 |
+
- type: pearson_max
|
91 |
+
value: 0.7883137483129774
|
92 |
+
name: Pearson Max
|
93 |
+
- type: spearman_max
|
94 |
+
value: 0.7971624317482785
|
95 |
+
name: Spearman Max
|
96 |
+
- task:
|
97 |
+
type: semantic-similarity
|
98 |
+
name: Semantic Similarity
|
99 |
+
dataset:
|
100 |
+
name: sts test 256
|
101 |
+
type: sts-test-256
|
102 |
+
metrics:
|
103 |
+
- type: pearson_cosine
|
104 |
+
value: 0.7851969391652749
|
105 |
+
name: Pearson Cosine
|
106 |
+
- type: spearman_cosine
|
107 |
+
value: 0.7968026743946358
|
108 |
+
name: Spearman Cosine
|
109 |
+
- type: pearson_manhattan
|
110 |
+
value: 0.7852783784725356
|
111 |
+
name: Pearson Manhattan
|
112 |
+
- type: spearman_manhattan
|
113 |
+
value: 0.7935883492889713
|
114 |
+
name: Spearman Manhattan
|
115 |
+
- type: pearson_euclidean
|
116 |
+
value: 0.7882018230746569
|
117 |
+
name: Pearson Euclidean
|
118 |
+
- type: spearman_euclidean
|
119 |
+
value: 0.7963116553267949
|
120 |
+
name: Spearman Euclidean
|
121 |
+
- type: pearson_dot
|
122 |
+
value: 0.7786421988393841
|
123 |
+
name: Pearson Dot
|
124 |
+
- type: spearman_dot
|
125 |
+
value: 0.7867782644180616
|
126 |
+
name: Spearman Dot
|
127 |
+
- type: pearson_max
|
128 |
+
value: 0.7882018230746569
|
129 |
+
name: Pearson Max
|
130 |
+
- type: spearman_max
|
131 |
+
value: 0.7968026743946358
|
132 |
+
name: Spearman Max
|
133 |
+
- task:
|
134 |
+
type: semantic-similarity
|
135 |
+
name: Semantic Similarity
|
136 |
+
dataset:
|
137 |
+
name: sts test 128
|
138 |
+
type: sts-test-128
|
139 |
+
metrics:
|
140 |
+
- type: pearson_cosine
|
141 |
+
value: 0.7754967709350954
|
142 |
+
name: Pearson Cosine
|
143 |
+
- type: spearman_cosine
|
144 |
+
value: 0.7933453885370457
|
145 |
+
name: Spearman Cosine
|
146 |
+
- type: pearson_manhattan
|
147 |
+
value: 0.7832834632297865
|
148 |
+
name: Pearson Manhattan
|
149 |
+
- type: spearman_manhattan
|
150 |
+
value: 0.7907589269176767
|
151 |
+
name: Spearman Manhattan
|
152 |
+
- type: pearson_euclidean
|
153 |
+
value: 0.7867583047946054
|
154 |
+
name: Pearson Euclidean
|
155 |
+
- type: spearman_euclidean
|
156 |
+
value: 0.7935816990844704
|
157 |
+
name: Spearman Euclidean
|
158 |
+
- type: pearson_dot
|
159 |
+
value: 0.7317253736607925
|
160 |
+
name: Pearson Dot
|
161 |
+
- type: spearman_dot
|
162 |
+
value: 0.7335574962775742
|
163 |
+
name: Spearman Dot
|
164 |
+
- type: pearson_max
|
165 |
+
value: 0.7867583047946054
|
166 |
+
name: Pearson Max
|
167 |
+
- type: spearman_max
|
168 |
+
value: 0.7935816990844704
|
169 |
+
name: Spearman Max
|
170 |
+
- task:
|
171 |
+
type: semantic-similarity
|
172 |
+
name: Semantic Similarity
|
173 |
+
dataset:
|
174 |
+
name: sts test 64
|
175 |
+
type: sts-test-64
|
176 |
+
metrics:
|
177 |
+
- type: pearson_cosine
|
178 |
+
value: 0.7625204599039478
|
179 |
+
name: Pearson Cosine
|
180 |
+
- type: spearman_cosine
|
181 |
+
value: 0.7837078735068292
|
182 |
+
name: Spearman Cosine
|
183 |
+
- type: pearson_manhattan
|
184 |
+
value: 0.7752889433866854
|
185 |
+
name: Pearson Manhattan
|
186 |
+
- type: spearman_manhattan
|
187 |
+
value: 0.7790888579029828
|
188 |
+
name: Spearman Manhattan
|
189 |
+
- type: pearson_euclidean
|
190 |
+
value: 0.777961287133872
|
191 |
+
name: Pearson Euclidean
|
192 |
+
- type: spearman_euclidean
|
193 |
+
value: 0.7815940757356076
|
194 |
+
name: Spearman Euclidean
|
195 |
+
- type: pearson_dot
|
196 |
+
value: 0.6685094830550401
|
197 |
+
name: Pearson Dot
|
198 |
+
- type: spearman_dot
|
199 |
+
value: 0.6621206899696827
|
200 |
+
name: Spearman Dot
|
201 |
+
- type: pearson_max
|
202 |
+
value: 0.777961287133872
|
203 |
+
name: Pearson Max
|
204 |
+
- type: spearman_max
|
205 |
+
value: 0.7837078735068292
|
206 |
+
name: Spearman Max
|
207 |
+
---
|
208 |
+
|
209 |
+
# SentenceTransformer based on intfloat/multilingual-e5-small
|
210 |
+
|
211 |
+
This is a [sentence-transformers](https://www.SBERT.net) model finetuned from [intfloat/multilingual-e5-small](https://huggingface.co/intfloat/multilingual-e5-small) on the Omartificial-Intelligence-Space/arabic-n_li-triplet 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.
|
212 |
+
|
213 |
+
## Model Details
|
214 |
+
|
215 |
+
### Model Description
|
216 |
+
- **Model Type:** Sentence Transformer
|
217 |
+
- **Base model:** [intfloat/multilingual-e5-small](https://huggingface.co/intfloat/multilingual-e5-small) <!-- at revision 0a68dcd3dad5b4962a78daa930087728292b241d -->
|
218 |
+
- **Maximum Sequence Length:** 512 tokens
|
219 |
+
- **Output Dimensionality:** 384 tokens
|
220 |
+
- **Similarity Function:** Cosine Similarity
|
221 |
+
- **Training Dataset:**
|
222 |
+
- Omartificial-Intelligence-Space/arabic-n_li-triplet
|
223 |
+
<!-- - **Language:** Unknown -->
|
224 |
+
<!-- - **License:** Unknown -->
|
225 |
+
|
226 |
+
### Model Sources
|
227 |
+
|
228 |
+
- **Documentation:** [Sentence Transformers Documentation](https://sbert.net)
|
229 |
+
- **Repository:** [Sentence Transformers on GitHub](https://github.com/UKPLab/sentence-transformers)
|
230 |
+
- **Hugging Face:** [Sentence Transformers on Hugging Face](https://huggingface.co/models?library=sentence-transformers)
|
231 |
+
|
232 |
+
### Full Model Architecture
|
233 |
+
|
234 |
+
```
|
235 |
+
SentenceTransformer(
|
236 |
+
(0): Transformer({'max_seq_length': 512, 'do_lower_case': False}) with Transformer model: BertModel
|
237 |
+
(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})
|
238 |
+
(2): Normalize()
|
239 |
+
)
|
240 |
+
```
|
241 |
+
|
242 |
+
## Usage
|
243 |
+
|
244 |
+
### Direct Usage (Sentence Transformers)
|
245 |
+
|
246 |
+
First install the Sentence Transformers library:
|
247 |
+
|
248 |
+
```bash
|
249 |
+
pip install -U sentence-transformers
|
250 |
+
```
|
251 |
+
|
252 |
+
Then you can load this model and run inference.
|
253 |
+
```python
|
254 |
+
from sentence_transformers import SentenceTransformer
|
255 |
+
|
256 |
+
# Download from the 🤗 Hub
|
257 |
+
model = SentenceTransformer("Omartificial-Intelligence-Space/E5-Matro")
|
258 |
+
# Run inference
|
259 |
+
sentences = [
|
260 |
+
'يجلس شاب ذو شعر أشقر على الحائط يقرأ جريدة بينما تمر امرأة وفتاة شابة.',
|
261 |
+
'ذكر شاب ينظر إلى جريدة بينما تمر إمرأتان بجانبه',
|
262 |
+
'الشاب نائم بينما الأم تقود ابنتها إلى الحديقة',
|
263 |
+
]
|
264 |
+
embeddings = model.encode(sentences)
|
265 |
+
print(embeddings.shape)
|
266 |
+
# [3, 384]
|
267 |
+
|
268 |
+
# Get the similarity scores for the embeddings
|
269 |
+
similarities = model.similarity(embeddings, embeddings)
|
270 |
+
print(similarities.shape)
|
271 |
+
# [3, 3]
|
272 |
+
```
|
273 |
+
|
274 |
+
<!--
|
275 |
+
### Direct Usage (Transformers)
|
276 |
+
|
277 |
+
<details><summary>Click to see the direct usage in Transformers</summary>
|
278 |
+
|
279 |
+
</details>
|
280 |
+
-->
|
281 |
+
|
282 |
+
<!--
|
283 |
+
### Downstream Usage (Sentence Transformers)
|
284 |
+
|
285 |
+
You can finetune this model on your own dataset.
|
286 |
+
|
287 |
+
<details><summary>Click to expand</summary>
|
288 |
+
|
289 |
+
</details>
|
290 |
+
-->
|
291 |
+
|
292 |
+
<!--
|
293 |
+
### Out-of-Scope Use
|
294 |
+
|
295 |
+
*List how the model may foreseeably be misused and address what users ought not to do with the model.*
|
296 |
+
-->
|
297 |
+
|
298 |
+
## Evaluation
|
299 |
+
|
300 |
+
### Metrics
|
301 |
+
|
302 |
+
#### Semantic Similarity
|
303 |
+
* Dataset: `sts-test-384`
|
304 |
+
* Evaluated with [<code>EmbeddingSimilarityEvaluator</code>](https://sbert.net/docs/package_reference/sentence_transformer/evaluation.html#sentence_transformers.evaluation.EmbeddingSimilarityEvaluator)
|
305 |
+
|
306 |
+
| Metric | Value |
|
307 |
+
|:--------------------|:-----------|
|
308 |
+
| pearson_cosine | 0.7883 |
|
309 |
+
| **spearman_cosine** | **0.7972** |
|
310 |
+
| pearson_manhattan | 0.7846 |
|
311 |
+
| spearman_manhattan | 0.794 |
|
312 |
+
| pearson_euclidean | 0.7883 |
|
313 |
+
| spearman_euclidean | 0.7972 |
|
314 |
+
| pearson_dot | 0.7883 |
|
315 |
+
| spearman_dot | 0.7972 |
|
316 |
+
| pearson_max | 0.7883 |
|
317 |
+
| spearman_max | 0.7972 |
|
318 |
+
|
319 |
+
#### Semantic Similarity
|
320 |
+
* Dataset: `sts-test-256`
|
321 |
+
* Evaluated with [<code>EmbeddingSimilarityEvaluator</code>](https://sbert.net/docs/package_reference/sentence_transformer/evaluation.html#sentence_transformers.evaluation.EmbeddingSimilarityEvaluator)
|
322 |
+
|
323 |
+
| Metric | Value |
|
324 |
+
|:--------------------|:-----------|
|
325 |
+
| pearson_cosine | 0.7852 |
|
326 |
+
| **spearman_cosine** | **0.7968** |
|
327 |
+
| pearson_manhattan | 0.7853 |
|
328 |
+
| spearman_manhattan | 0.7936 |
|
329 |
+
| pearson_euclidean | 0.7882 |
|
330 |
+
| spearman_euclidean | 0.7963 |
|
331 |
+
| pearson_dot | 0.7786 |
|
332 |
+
| spearman_dot | 0.7868 |
|
333 |
+
| pearson_max | 0.7882 |
|
334 |
+
| spearman_max | 0.7968 |
|
335 |
+
|
336 |
+
#### Semantic Similarity
|
337 |
+
* Dataset: `sts-test-128`
|
338 |
+
* Evaluated with [<code>EmbeddingSimilarityEvaluator</code>](https://sbert.net/docs/package_reference/sentence_transformer/evaluation.html#sentence_transformers.evaluation.EmbeddingSimilarityEvaluator)
|
339 |
+
|
340 |
+
| Metric | Value |
|
341 |
+
|:--------------------|:-----------|
|
342 |
+
| pearson_cosine | 0.7755 |
|
343 |
+
| **spearman_cosine** | **0.7933** |
|
344 |
+
| pearson_manhattan | 0.7833 |
|
345 |
+
| spearman_manhattan | 0.7908 |
|
346 |
+
| pearson_euclidean | 0.7868 |
|
347 |
+
| spearman_euclidean | 0.7936 |
|
348 |
+
| pearson_dot | 0.7317 |
|
349 |
+
| spearman_dot | 0.7336 |
|
350 |
+
| pearson_max | 0.7868 |
|
351 |
+
| spearman_max | 0.7936 |
|
352 |
+
|
353 |
+
#### Semantic Similarity
|
354 |
+
* Dataset: `sts-test-64`
|
355 |
+
* Evaluated with [<code>EmbeddingSimilarityEvaluator</code>](https://sbert.net/docs/package_reference/sentence_transformer/evaluation.html#sentence_transformers.evaluation.EmbeddingSimilarityEvaluator)
|
356 |
+
|
357 |
+
| Metric | Value |
|
358 |
+
|:--------------------|:-----------|
|
359 |
+
| pearson_cosine | 0.7625 |
|
360 |
+
| **spearman_cosine** | **0.7837** |
|
361 |
+
| pearson_manhattan | 0.7753 |
|
362 |
+
| spearman_manhattan | 0.7791 |
|
363 |
+
| pearson_euclidean | 0.778 |
|
364 |
+
| spearman_euclidean | 0.7816 |
|
365 |
+
| pearson_dot | 0.6685 |
|
366 |
+
| spearman_dot | 0.6621 |
|
367 |
+
| pearson_max | 0.778 |
|
368 |
+
| spearman_max | 0.7837 |
|
369 |
+
|
370 |
+
<!--
|
371 |
+
## Bias, Risks and Limitations
|
372 |
+
|
373 |
+
*What are the known or foreseeable issues stemming from this model? You could also flag here known failure cases or weaknesses of the model.*
|
374 |
+
-->
|
375 |
+
|
376 |
+
<!--
|
377 |
+
### Recommendations
|
378 |
+
|
379 |
+
*What are recommendations with respect to the foreseeable issues? For example, filtering explicit content.*
|
380 |
+
-->
|
381 |
+
|
382 |
+
## Training Details
|
383 |
+
|
384 |
+
### Training Dataset
|
385 |
+
|
386 |
+
#### Omartificial-Intelligence-Space/arabic-n_li-triplet
|
387 |
+
|
388 |
+
* Dataset: Omartificial-Intelligence-Space/arabic-n_li-triplet
|
389 |
+
* Size: 557,850 training samples
|
390 |
+
* Columns: <code>anchor</code>, <code>positive</code>, and <code>negative</code>
|
391 |
+
* Approximate statistics based on the first 1000 samples:
|
392 |
+
| | anchor | positive | negative |
|
393 |
+
|:--------|:----------------------------------------------------------------------------------|:----------------------------------------------------------------------------------|:----------------------------------------------------------------------------------|
|
394 |
+
| type | string | string | string |
|
395 |
+
| details | <ul><li>min: 5 tokens</li><li>mean: 10.33 tokens</li><li>max: 52 tokens</li></ul> | <ul><li>min: 5 tokens</li><li>mean: 13.21 tokens</li><li>max: 49 tokens</li></ul> | <ul><li>min: 5 tokens</li><li>mean: 15.32 tokens</li><li>max: 53 tokens</li></ul> |
|
396 |
+
* Samples:
|
397 |
+
| anchor | positive | negative |
|
398 |
+
|:------------------------------------------------------------|:--------------------------------------------|:------------------------------------|
|
399 |
+
| <code>شخص على حصان يقفز فوق طائرة معطلة</code> | <code>شخص في الهواء الطلق، على حصان.</code> | <code>شخص في مطعم، يطلب عجة.</code> |
|
400 |
+
| <code>أطفال يبتسمون و يلوحون للكاميرا</code> | <code>هناك أطفال حاضرون</code> | <code>الاطفال يتجهمون</code> |
|
401 |
+
| <code>صبي يقفز على لوح التزلج في منتصف الجسر الأحمر.</code> | <code>الفتى يقوم بخدعة التزلج</code> | <code>الصبي يتزلج على الرصيف</code> |
|
402 |
+
* Loss: [<code>MatryoshkaLoss</code>](https://sbert.net/docs/package_reference/sentence_transformer/losses.html#matryoshkaloss) with these parameters:
|
403 |
+
```json
|
404 |
+
{
|
405 |
+
"loss": "MultipleNegativesRankingLoss",
|
406 |
+
"matryoshka_dims": [
|
407 |
+
384,
|
408 |
+
256,
|
409 |
+
128,
|
410 |
+
64
|
411 |
+
],
|
412 |
+
"matryoshka_weights": [
|
413 |
+
1,
|
414 |
+
1,
|
415 |
+
1,
|
416 |
+
1
|
417 |
+
],
|
418 |
+
"n_dims_per_step": -1
|
419 |
+
}
|
420 |
+
```
|
421 |
+
|
422 |
+
### Evaluation Dataset
|
423 |
+
|
424 |
+
#### Omartificial-Intelligence-Space/arabic-n_li-triplet
|
425 |
+
|
426 |
+
* Dataset: Omartificial-Intelligence-Space/arabic-n_li-triplet
|
427 |
+
* Size: 6,584 evaluation samples
|
428 |
+
* Columns: <code>anchor</code>, <code>positive</code>, and <code>negative</code>
|
429 |
+
* Approximate statistics based on the first 1000 samples:
|
430 |
+
| | anchor | positive | negative |
|
431 |
+
|:--------|:-----------------------------------------------------------------------------------|:----------------------------------------------------------------------------------|:---------------------------------------------------------------------------------|
|
432 |
+
| type | string | string | string |
|
433 |
+
| details | <ul><li>min: 5 tokens</li><li>mean: 21.86 tokens</li><li>max: 105 tokens</li></ul> | <ul><li>min: 4 tokens</li><li>mean: 10.22 tokens</li><li>max: 49 tokens</li></ul> | <ul><li>min: 4 tokens</li><li>mean: 11.2 tokens</li><li>max: 33 tokens</li></ul> |
|
434 |
+
* Samples:
|
435 |
+
| anchor | positive | negative |
|
436 |
+
|:-----------------------------------------------------------------------------------------------------------------------------------------------------|:-------------------------------------------------------|:---------------------------------------------------|
|
437 |
+
| <code>امرأتان يتعانقان بينما يحملان حزمة</code> | <code>إمرأتان يحملان حزمة</code> | <code>الرجال يتشاجرون خارج مطعم</code> |
|
438 |
+
| <code>طفلين صغيرين يرتديان قميصاً أزرق، أحدهما يرتدي الرقم 9 والآخر يرتدي الرقم 2 يقفان على خطوات خشبية في الحمام ويغسلان أيديهما في المغسلة.</code> | <code>طفلين يرتديان قميصاً مرقماً يغسلون أيديهم</code> | <code>طفلين يرتديان سترة يذهبان إلى المدرسة</code> |
|
439 |
+
| <code>رجل يبيع الدونات لعميل خلال معرض عالمي أقيم في مدينة أنجليس</code> | <code>رجل يبيع الدونات لعميل</code> | <code>امرأة تشرب قهوتها في مقهى صغير</code> |
|
440 |
+
* Loss: [<code>MatryoshkaLoss</code>](https://sbert.net/docs/package_reference/sentence_transformer/losses.html#matryoshkaloss) with these parameters:
|
441 |
+
```json
|
442 |
+
{
|
443 |
+
"loss": "MultipleNegativesRankingLoss",
|
444 |
+
"matryoshka_dims": [
|
445 |
+
384,
|
446 |
+
256,
|
447 |
+
128,
|
448 |
+
64
|
449 |
+
],
|
450 |
+
"matryoshka_weights": [
|
451 |
+
1,
|
452 |
+
1,
|
453 |
+
1,
|
454 |
+
1
|
455 |
+
],
|
456 |
+
"n_dims_per_step": -1
|
457 |
+
}
|
458 |
+
```
|
459 |
+
|
460 |
+
### Training Hyperparameters
|
461 |
+
#### Non-Default Hyperparameters
|
462 |
+
|
463 |
+
- `per_device_train_batch_size`: 32
|
464 |
+
- `per_device_eval_batch_size`: 32
|
465 |
+
- `warmup_ratio`: 0.1
|
466 |
+
- `fp16`: True
|
467 |
+
- `batch_sampler`: no_duplicates
|
468 |
+
|
469 |
+
#### All Hyperparameters
|
470 |
+
<details><summary>Click to expand</summary>
|
471 |
+
|
472 |
+
- `overwrite_output_dir`: False
|
473 |
+
- `do_predict`: False
|
474 |
+
- `prediction_loss_only`: True
|
475 |
+
- `per_device_train_batch_size`: 32
|
476 |
+
- `per_device_eval_batch_size`: 32
|
477 |
+
- `per_gpu_train_batch_size`: None
|
478 |
+
- `per_gpu_eval_batch_size`: None
|
479 |
+
- `gradient_accumulation_steps`: 1
|
480 |
+
- `eval_accumulation_steps`: None
|
481 |
+
- `learning_rate`: 5e-05
|
482 |
+
- `weight_decay`: 0.0
|
483 |
+
- `adam_beta1`: 0.9
|
484 |
+
- `adam_beta2`: 0.999
|
485 |
+
- `adam_epsilon`: 1e-08
|
486 |
+
- `max_grad_norm`: 1.0
|
487 |
+
- `num_train_epochs`: 3
|
488 |
+
- `max_steps`: -1
|
489 |
+
- `lr_scheduler_type`: linear
|
490 |
+
- `lr_scheduler_kwargs`: {}
|
491 |
+
- `warmup_ratio`: 0.1
|
492 |
+
- `warmup_steps`: 0
|
493 |
+
- `log_level`: passive
|
494 |
+
- `log_level_replica`: warning
|
495 |
+
- `log_on_each_node`: True
|
496 |
+
- `logging_nan_inf_filter`: True
|
497 |
+
- `save_safetensors`: True
|
498 |
+
- `save_on_each_node`: False
|
499 |
+
- `save_only_model`: False
|
500 |
+
- `no_cuda`: False
|
501 |
+
- `use_cpu`: False
|
502 |
+
- `use_mps_device`: False
|
503 |
+
- `seed`: 42
|
504 |
+
- `data_seed`: None
|
505 |
+
- `jit_mode_eval`: False
|
506 |
+
- `use_ipex`: False
|
507 |
+
- `bf16`: False
|
508 |
+
- `fp16`: True
|
509 |
+
- `fp16_opt_level`: O1
|
510 |
+
- `half_precision_backend`: auto
|
511 |
+
- `bf16_full_eval`: False
|
512 |
+
- `fp16_full_eval`: False
|
513 |
+
- `tf32`: None
|
514 |
+
- `local_rank`: 0
|
515 |
+
- `ddp_backend`: None
|
516 |
+
- `tpu_num_cores`: None
|
517 |
+
- `tpu_metrics_debug`: False
|
518 |
+
- `debug`: []
|
519 |
+
- `dataloader_drop_last`: False
|
520 |
+
- `dataloader_num_workers`: 0
|
521 |
+
- `dataloader_prefetch_factor`: None
|
522 |
+
- `past_index`: -1
|
523 |
+
- `disable_tqdm`: False
|
524 |
+
- `remove_unused_columns`: True
|
525 |
+
- `label_names`: None
|
526 |
+
- `load_best_model_at_end`: False
|
527 |
+
- `ignore_data_skip`: False
|
528 |
+
- `fsdp`: []
|
529 |
+
- `fsdp_min_num_params`: 0
|
530 |
+
- `fsdp_config`: {'min_num_params': 0, 'xla': False, 'xla_fsdp_v2': False, 'xla_fsdp_grad_ckpt': False}
|
531 |
+
- `fsdp_transformer_layer_cls_to_wrap`: None
|
532 |
+
- `accelerator_config`: {'split_batches': False, 'dispatch_batches': None, 'even_batches': True, 'use_seedable_sampler': True, 'gradient_accumulation_kwargs': None}
|
533 |
+
- `deepspeed`: None
|
534 |
+
- `label_smoothing_factor`: 0.0
|
535 |
+
- `optim`: adamw_torch
|
536 |
+
- `optim_args`: None
|
537 |
+
- `adafactor`: False
|
538 |
+
- `group_by_length`: False
|
539 |
+
- `length_column_name`: length
|
540 |
+
- `ddp_find_unused_parameters`: None
|
541 |
+
- `ddp_bucket_cap_mb`: None
|
542 |
+
- `ddp_broadcast_buffers`: False
|
543 |
+
- `dataloader_pin_memory`: True
|
544 |
+
- `dataloader_persistent_workers`: False
|
545 |
+
- `skip_memory_metrics`: True
|
546 |
+
- `use_legacy_prediction_loop`: False
|
547 |
+
- `push_to_hub`: False
|
548 |
+
- `resume_from_checkpoint`: None
|
549 |
+
- `hub_model_id`: None
|
550 |
+
- `hub_strategy`: every_save
|
551 |
+
- `hub_private_repo`: False
|
552 |
+
- `hub_always_push`: False
|
553 |
+
- `gradient_checkpointing`: False
|
554 |
+
- `gradient_checkpointing_kwargs`: None
|
555 |
+
- `include_inputs_for_metrics`: False
|
556 |
+
- `eval_do_concat_batches`: True
|
557 |
+
- `fp16_backend`: auto
|
558 |
+
- `push_to_hub_model_id`: None
|
559 |
+
- `push_to_hub_organization`: None
|
560 |
+
- `mp_parameters`:
|
561 |
+
- `auto_find_batch_size`: False
|
562 |
+
- `full_determinism`: False
|
563 |
+
- `torchdynamo`: None
|
564 |
+
- `ray_scope`: last
|
565 |
+
- `ddp_timeout`: 1800
|
566 |
+
- `torch_compile`: False
|
567 |
+
- `torch_compile_backend`: None
|
568 |
+
- `torch_compile_mode`: None
|
569 |
+
- `dispatch_batches`: None
|
570 |
+
- `split_batches`: None
|
571 |
+
- `include_tokens_per_second`: False
|
572 |
+
- `include_num_input_tokens_seen`: False
|
573 |
+
- `neftune_noise_alpha`: None
|
574 |
+
- `optim_target_modules`: None
|
575 |
+
- `batch_sampler`: no_duplicates
|
576 |
+
- `multi_dataset_batch_sampler`: proportional
|
577 |
+
|
578 |
+
</details>
|
579 |
+
|
580 |
+
### Training Logs
|
581 |
+
| Epoch | Step | Training Loss | sts-test-128_spearman_cosine | sts-test-256_spearman_cosine | sts-test-384_spearman_cosine | sts-test-64_spearman_cosine |
|
582 |
+
|:------:|:-----:|:-------------:|:----------------------------:|:----------------------------:|:----------------------------:|:---------------------------:|
|
583 |
+
| 0.0344 | 200 | 13.1208 | - | - | - | - |
|
584 |
+
| 0.0688 | 400 | 9.1894 | - | - | - | - |
|
585 |
+
| 0.1033 | 600 | 8.0222 | - | - | - | - |
|
586 |
+
| 0.1377 | 800 | 7.2405 | - | - | - | - |
|
587 |
+
| 0.1721 | 1000 | 7.1622 | - | - | - | - |
|
588 |
+
| 0.2065 | 1200 | 6.4282 | - | - | - | - |
|
589 |
+
| 0.2409 | 1400 | 6.0936 | - | - | - | - |
|
590 |
+
| 0.2753 | 1600 | 5.99 | - | - | - | - |
|
591 |
+
| 0.3098 | 1800 | 5.6939 | - | - | - | - |
|
592 |
+
| 0.3442 | 2000 | 5.694 | - | - | - | - |
|
593 |
+
| 0.3786 | 2200 | 5.2366 | - | - | - | - |
|
594 |
+
| 0.4130 | 2400 | 5.2994 | - | - | - | - |
|
595 |
+
| 0.4474 | 2600 | 5.2079 | - | - | - | - |
|
596 |
+
| 0.4818 | 2800 | 5.0532 | - | - | - | - |
|
597 |
+
| 0.5163 | 3000 | 4.9978 | - | - | - | - |
|
598 |
+
| 0.5507 | 3200 | 5.1764 | - | - | - | - |
|
599 |
+
| 0.5851 | 3400 | 5.1315 | - | - | - | - |
|
600 |
+
| 0.6195 | 3600 | 5.0198 | - | - | - | - |
|
601 |
+
| 0.6539 | 3800 | 5.0308 | - | - | - | - |
|
602 |
+
| 0.6883 | 4000 | 5.1631 | - | - | - | - |
|
603 |
+
| 0.7228 | 4200 | 4.7916 | - | - | - | - |
|
604 |
+
| 0.7572 | 4400 | 4.363 | - | - | - | - |
|
605 |
+
| 0.7916 | 4600 | 3.2357 | - | - | - | - |
|
606 |
+
| 0.8260 | 4800 | 2.9915 | - | - | - | - |
|
607 |
+
| 0.8604 | 5000 | 2.8143 | - | - | - | - |
|
608 |
+
| 0.8949 | 5200 | 2.6125 | - | - | - | - |
|
609 |
+
| 0.9293 | 5400 | 2.5493 | - | - | - | - |
|
610 |
+
| 0.9637 | 5600 | 2.4991 | - | - | - | - |
|
611 |
+
| 0.9981 | 5800 | 2.163 | - | - | - | - |
|
612 |
+
| 1.0325 | 6000 | 0.0 | - | - | - | - |
|
613 |
+
| 1.0669 | 6200 | 0.0 | - | - | - | - |
|
614 |
+
| 1.1014 | 6400 | 0.0 | - | - | - | - |
|
615 |
+
| 1.1358 | 6600 | 0.0 | - | - | - | - |
|
616 |
+
| 1.1702 | 6800 | 0.0 | - | - | - | - |
|
617 |
+
| 1.2046 | 7000 | 0.0 | - | - | - | - |
|
618 |
+
| 1.2390 | 7200 | 0.0 | - | - | - | - |
|
619 |
+
| 1.2734 | 7400 | 0.0 | - | - | - | - |
|
620 |
+
| 1.3079 | 7600 | 0.0 | - | - | - | - |
|
621 |
+
| 1.3423 | 7800 | 0.0 | - | - | - | - |
|
622 |
+
| 1.3767 | 8000 | 0.0 | - | - | - | - |
|
623 |
+
| 1.4111 | 8200 | 0.0037 | - | - | - | - |
|
624 |
+
| 1.4455 | 8400 | 0.0372 | - | - | - | - |
|
625 |
+
| 1.4800 | 8600 | 0.0221 | - | - | - | - |
|
626 |
+
| 1.0229 | 8800 | 4.3738 | - | - | - | - |
|
627 |
+
| 1.0573 | 9000 | 6.338 | - | - | - | - |
|
628 |
+
| 1.0917 | 9200 | 6.2223 | - | - | - | - |
|
629 |
+
| 1.1261 | 9400 | 5.8673 | - | - | - | - |
|
630 |
+
| 1.1606 | 9600 | 5.5907 | - | - | - | - |
|
631 |
+
| 1.1950 | 9800 | 5.0307 | - | - | - | - |
|
632 |
+
| 1.2294 | 10000 | 4.9193 | - | - | - | - |
|
633 |
+
| 1.2638 | 10200 | 4.8798 | - | - | - | - |
|
634 |
+
| 1.2982 | 10400 | 4.401 | - | - | - | - |
|
635 |
+
| 1.3326 | 10600 | 4.2705 | - | - | - | - |
|
636 |
+
| 1.3671 | 10800 | 4.3023 | - | - | - | - |
|
637 |
+
| 1.4015 | 11000 | 4.1344 | - | - | - | - |
|
638 |
+
| 1.4359 | 11200 | 4.0464 | - | - | - | - |
|
639 |
+
| 1.4703 | 11400 | 4.0115 | - | - | - | - |
|
640 |
+
| 1.5047 | 11600 | 3.9206 | - | - | - | - |
|
641 |
+
| 1.5391 | 11800 | 4.0106 | - | - | - | - |
|
642 |
+
| 1.5736 | 12000 | 4.1365 | - | - | - | - |
|
643 |
+
| 1.6080 | 12200 | 4.0401 | - | - | - | - |
|
644 |
+
| 1.6424 | 12400 | 4.0602 | - | - | - | - |
|
645 |
+
| 1.6768 | 12600 | 4.076 | - | - | - | - |
|
646 |
+
| 1.7112 | 12800 | 3.97 | - | - | - | - |
|
647 |
+
| 1.7457 | 13000 | 3.7905 | - | - | - | - |
|
648 |
+
| 1.7801 | 13200 | 2.414 | - | - | - | - |
|
649 |
+
| 1.8145 | 13400 | 2.1811 | - | - | - | - |
|
650 |
+
| 1.8489 | 13600 | 2.1183 | - | - | - | - |
|
651 |
+
| 1.8833 | 13800 | 2.0578 | - | - | - | - |
|
652 |
+
| 1.9177 | 14000 | 2.0173 | - | - | - | - |
|
653 |
+
| 1.9522 | 14200 | 2.0093 | - | - | - | - |
|
654 |
+
| 1.9866 | 14400 | 1.9467 | - | - | - | - |
|
655 |
+
| 2.0210 | 14600 | 0.4674 | - | - | - | - |
|
656 |
+
| 2.0554 | 14800 | 0.0 | - | - | - | - |
|
657 |
+
| 2.0898 | 15000 | 0.0 | - | - | - | - |
|
658 |
+
| 2.1242 | 15200 | 0.0 | - | - | - | - |
|
659 |
+
| 2.1587 | 15400 | 0.0 | - | - | - | - |
|
660 |
+
| 2.1931 | 15600 | 0.0 | - | - | - | - |
|
661 |
+
| 2.2275 | 15800 | 0.0 | - | - | - | - |
|
662 |
+
| 2.2619 | 16000 | 0.0 | - | - | - | - |
|
663 |
+
| 2.2963 | 16200 | 0.0 | - | - | - | - |
|
664 |
+
| 2.3308 | 16400 | 0.0 | - | - | - | - |
|
665 |
+
| 2.3652 | 16600 | 0.0 | - | - | - | - |
|
666 |
+
| 2.3996 | 16800 | 0.0 | - | - | - | - |
|
667 |
+
| 2.4340 | 17000 | 0.0 | - | - | - | - |
|
668 |
+
| 2.4684 | 17200 | 0.0256 | - | - | - | - |
|
669 |
+
| 2.0114 | 17400 | 2.4155 | - | - | - | - |
|
670 |
+
| 2.0170 | 17433 | - | 0.7933 | 0.7968 | 0.7972 | 0.7837 |
|
671 |
+
|
672 |
+
|
673 |
+
### Framework Versions
|
674 |
+
- Python: 3.9.18
|
675 |
+
- Sentence Transformers: 3.0.1
|
676 |
+
- Transformers: 4.40.0
|
677 |
+
- PyTorch: 2.2.2+cu121
|
678 |
+
- Accelerate: 0.26.1
|
679 |
+
- Datasets: 2.19.0
|
680 |
+
- Tokenizers: 0.19.1
|
681 |
+
|
682 |
+
## Citation
|
683 |
+
|
684 |
+
### BibTeX
|
685 |
+
|
686 |
+
#### Sentence Transformers
|
687 |
+
```bibtex
|
688 |
+
@inproceedings{reimers-2019-sentence-bert,
|
689 |
+
title = "Sentence-BERT: Sentence Embeddings using Siamese BERT-Networks",
|
690 |
+
author = "Reimers, Nils and Gurevych, Iryna",
|
691 |
+
booktitle = "Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing",
|
692 |
+
month = "11",
|
693 |
+
year = "2019",
|
694 |
+
publisher = "Association for Computational Linguistics",
|
695 |
+
url = "https://arxiv.org/abs/1908.10084",
|
696 |
+
}
|
697 |
+
```
|
698 |
+
|
699 |
+
#### MatryoshkaLoss
|
700 |
+
```bibtex
|
701 |
+
@misc{kusupati2024matryoshka,
|
702 |
+
title={Matryoshka Representation Learning},
|
703 |
+
author={Aditya Kusupati and Gantavya Bhatt and Aniket Rege and Matthew Wallingford and Aditya Sinha and Vivek Ramanujan and William Howard-Snyder and Kaifeng Chen and Sham Kakade and Prateek Jain and Ali Farhadi},
|
704 |
+
year={2024},
|
705 |
+
eprint={2205.13147},
|
706 |
+
archivePrefix={arXiv},
|
707 |
+
primaryClass={cs.LG}
|
708 |
+
}
|
709 |
+
```
|
710 |
+
|
711 |
+
#### MultipleNegativesRankingLoss
|
712 |
+
```bibtex
|
713 |
+
@misc{henderson2017efficient,
|
714 |
+
title={Efficient Natural Language Response Suggestion for Smart Reply},
|
715 |
+
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},
|
716 |
+
year={2017},
|
717 |
+
eprint={1705.00652},
|
718 |
+
archivePrefix={arXiv},
|
719 |
+
primaryClass={cs.CL}
|
720 |
+
}
|
721 |
+
```
|
722 |
+
|
723 |
+
<!--
|
724 |
+
## Glossary
|
725 |
+
|
726 |
+
*Clearly define terms in order to be accessible across audiences.*
|
727 |
+
-->
|
728 |
+
|
729 |
+
<!--
|
730 |
+
## Model Card Authors
|
731 |
+
|
732 |
+
*Lists the people who create the model card, providing recognition and accountability for the detailed work that goes into its construction.*
|
733 |
+
-->
|
734 |
+
|
735 |
+
<!--
|
736 |
+
## Model Card Contact
|
737 |
+
|
738 |
+
*Provides a way for people who have updates to the Model Card, suggestions, or questions, to contact the Model Card authors.*
|
739 |
+
-->
|
config.json
ADDED
@@ -0,0 +1,26 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"_name_or_path": "intfloat/multilingual-e5-small",
|
3 |
+
"architectures": [
|
4 |
+
"BertModel"
|
5 |
+
],
|
6 |
+
"attention_probs_dropout_prob": 0.1,
|
7 |
+
"classifier_dropout": null,
|
8 |
+
"hidden_act": "gelu",
|
9 |
+
"hidden_dropout_prob": 0.1,
|
10 |
+
"hidden_size": 384,
|
11 |
+
"initializer_range": 0.02,
|
12 |
+
"intermediate_size": 1536,
|
13 |
+
"layer_norm_eps": 1e-12,
|
14 |
+
"max_position_embeddings": 512,
|
15 |
+
"model_type": "bert",
|
16 |
+
"num_attention_heads": 12,
|
17 |
+
"num_hidden_layers": 12,
|
18 |
+
"pad_token_id": 0,
|
19 |
+
"position_embedding_type": "absolute",
|
20 |
+
"tokenizer_class": "XLMRobertaTokenizer",
|
21 |
+
"torch_dtype": "float32",
|
22 |
+
"transformers_version": "4.40.0",
|
23 |
+
"type_vocab_size": 2,
|
24 |
+
"use_cache": true,
|
25 |
+
"vocab_size": 250037
|
26 |
+
}
|
config_sentence_transformers.json
ADDED
@@ -0,0 +1,10 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"__version__": {
|
3 |
+
"sentence_transformers": "3.0.1",
|
4 |
+
"transformers": "4.40.0",
|
5 |
+
"pytorch": "2.2.2+cu121"
|
6 |
+
},
|
7 |
+
"prompts": {},
|
8 |
+
"default_prompt_name": null,
|
9 |
+
"similarity_fn_name": null
|
10 |
+
}
|
model.safetensors
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:5fb3953ddeabff81ffe731bc0d2efc85427653853b4ef19aba90dbfb3bd9c3d0
|
3 |
+
size 470637416
|
modules.json
ADDED
@@ -0,0 +1,20 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
[
|
2 |
+
{
|
3 |
+
"idx": 0,
|
4 |
+
"name": "0",
|
5 |
+
"path": "",
|
6 |
+
"type": "sentence_transformers.models.Transformer"
|
7 |
+
},
|
8 |
+
{
|
9 |
+
"idx": 1,
|
10 |
+
"name": "1",
|
11 |
+
"path": "1_Pooling",
|
12 |
+
"type": "sentence_transformers.models.Pooling"
|
13 |
+
},
|
14 |
+
{
|
15 |
+
"idx": 2,
|
16 |
+
"name": "2",
|
17 |
+
"path": "2_Normalize",
|
18 |
+
"type": "sentence_transformers.models.Normalize"
|
19 |
+
}
|
20 |
+
]
|
sentence_bert_config.json
ADDED
@@ -0,0 +1,4 @@
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"max_seq_length": 512,
|
3 |
+
"do_lower_case": false
|
4 |
+
}
|
sentencepiece.bpe.model
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:cfc8146abe2a0488e9e2a0c56de7952f7c11ab059eca145a0a727afce0db2865
|
3 |
+
size 5069051
|
special_tokens_map.json
ADDED
@@ -0,0 +1,51 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"bos_token": {
|
3 |
+
"content": "<s>",
|
4 |
+
"lstrip": false,
|
5 |
+
"normalized": false,
|
6 |
+
"rstrip": false,
|
7 |
+
"single_word": false
|
8 |
+
},
|
9 |
+
"cls_token": {
|
10 |
+
"content": "<s>",
|
11 |
+
"lstrip": false,
|
12 |
+
"normalized": false,
|
13 |
+
"rstrip": false,
|
14 |
+
"single_word": false
|
15 |
+
},
|
16 |
+
"eos_token": {
|
17 |
+
"content": "</s>",
|
18 |
+
"lstrip": false,
|
19 |
+
"normalized": false,
|
20 |
+
"rstrip": false,
|
21 |
+
"single_word": false
|
22 |
+
},
|
23 |
+
"mask_token": {
|
24 |
+
"content": "<mask>",
|
25 |
+
"lstrip": false,
|
26 |
+
"normalized": false,
|
27 |
+
"rstrip": false,
|
28 |
+
"single_word": false
|
29 |
+
},
|
30 |
+
"pad_token": {
|
31 |
+
"content": "<pad>",
|
32 |
+
"lstrip": false,
|
33 |
+
"normalized": false,
|
34 |
+
"rstrip": false,
|
35 |
+
"single_word": false
|
36 |
+
},
|
37 |
+
"sep_token": {
|
38 |
+
"content": "</s>",
|
39 |
+
"lstrip": false,
|
40 |
+
"normalized": false,
|
41 |
+
"rstrip": false,
|
42 |
+
"single_word": false
|
43 |
+
},
|
44 |
+
"unk_token": {
|
45 |
+
"content": "<unk>",
|
46 |
+
"lstrip": false,
|
47 |
+
"normalized": false,
|
48 |
+
"rstrip": false,
|
49 |
+
"single_word": false
|
50 |
+
}
|
51 |
+
}
|
tokenizer.json
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:ef04f2b385d1514f500e779207ace0f53e30895ce37563179e29f4022d28ca38
|
3 |
+
size 17083053
|
tokenizer_config.json
ADDED
@@ -0,0 +1,55 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"added_tokens_decoder": {
|
3 |
+
"0": {
|
4 |
+
"content": "<s>",
|
5 |
+
"lstrip": false,
|
6 |
+
"normalized": false,
|
7 |
+
"rstrip": false,
|
8 |
+
"single_word": false,
|
9 |
+
"special": true
|
10 |
+
},
|
11 |
+
"1": {
|
12 |
+
"content": "<pad>",
|
13 |
+
"lstrip": false,
|
14 |
+
"normalized": false,
|
15 |
+
"rstrip": false,
|
16 |
+
"single_word": false,
|
17 |
+
"special": true
|
18 |
+
},
|
19 |
+
"2": {
|
20 |
+
"content": "</s>",
|
21 |
+
"lstrip": false,
|
22 |
+
"normalized": false,
|
23 |
+
"rstrip": false,
|
24 |
+
"single_word": false,
|
25 |
+
"special": true
|
26 |
+
},
|
27 |
+
"3": {
|
28 |
+
"content": "<unk>",
|
29 |
+
"lstrip": false,
|
30 |
+
"normalized": false,
|
31 |
+
"rstrip": false,
|
32 |
+
"single_word": false,
|
33 |
+
"special": true
|
34 |
+
},
|
35 |
+
"250001": {
|
36 |
+
"content": "<mask>",
|
37 |
+
"lstrip": false,
|
38 |
+
"normalized": false,
|
39 |
+
"rstrip": false,
|
40 |
+
"single_word": false,
|
41 |
+
"special": true
|
42 |
+
}
|
43 |
+
},
|
44 |
+
"bos_token": "<s>",
|
45 |
+
"clean_up_tokenization_spaces": true,
|
46 |
+
"cls_token": "<s>",
|
47 |
+
"eos_token": "</s>",
|
48 |
+
"mask_token": "<mask>",
|
49 |
+
"model_max_length": 512,
|
50 |
+
"pad_token": "<pad>",
|
51 |
+
"sep_token": "</s>",
|
52 |
+
"sp_model_kwargs": {},
|
53 |
+
"tokenizer_class": "XLMRobertaTokenizer",
|
54 |
+
"unk_token": "<unk>"
|
55 |
+
}
|