Add new SentenceTransformer model
Browse files- 1_Pooling/config.json +10 -0
- README.md +451 -0
- config.json +58 -0
- config_sentence_transformers.json +10 -0
- model.safetensors +3 -0
- modules.json +20 -0
- sentence_bert_config.json +4 -0
- special_tokens_map.json +37 -0
- tokenizer.json +0 -0
- tokenizer_config.json +56 -0
- vocab.txt +0 -0
1_Pooling/config.json
ADDED
@@ -0,0 +1,10 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"word_embedding_dimension": 768,
|
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,451 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
---
|
2 |
+
tags:
|
3 |
+
- sentence-transformers
|
4 |
+
- sentence-similarity
|
5 |
+
- feature-extraction
|
6 |
+
- generated_from_trainer
|
7 |
+
- dataset_size:2382
|
8 |
+
- loss:MultipleNegativesRankingLoss
|
9 |
+
base_model: nomic-ai/nomic-embed-text-v1
|
10 |
+
widget:
|
11 |
+
- source_sentence: Collect the details that are associated with product '- Com espessura
|
12 |
+
constante de' '- 0,04 m', with quantity 1900, unit M2
|
13 |
+
sentences:
|
14 |
+
- 'Item Description: UNKNOWN PRODUCT, priced at 949.00 EUR, Origin: National'
|
15 |
+
- 'Product: UNKNOWN PRODUCT, Estimated Value: 514.00 EUR'
|
16 |
+
- "Details for 'MacBook Pro 14\" Processador M2/3 16GB/18GB RAM | SSD 512GB | Teclado\
|
17 |
+
\ Es-Es', with quantity 1, unit UN:\n - LOTE 31\n - Price: 656.00 EUR"
|
18 |
+
- source_sentence: Collect the details that are associated with Lot 14 product ''
|
19 |
+
'Monitor de Sinais Vitais ', with quantity 2, unit Subcontracting Unit
|
20 |
+
sentences:
|
21 |
+
- "Details for 'Monitor de Sinais Vitais ', with quantity 2, unit Subcontracting\
|
22 |
+
\ Unit:\n - LOTE 60\n - Price: 564.00 EUR"
|
23 |
+
- "Details for UNKNOWN PRODUCT:\n - LOTE 90\n - Price: 658.00 EUR"
|
24 |
+
- 'Item Description: UNKNOWN PRODUCT, priced at 90.00 EUR, Origin: National'
|
25 |
+
- source_sentence: Collect the details that are associated with product '' '2202000270
|
26 |
+
- FIO SUT. AC. POLIGLIC. ABS. RÁPIDA 4/0 MULTIF AG. CILIND. 17 MM 1/2 C (UNID)',
|
27 |
+
with quantity 288, unit UN
|
28 |
+
sentences:
|
29 |
+
- 'Item Description: ''2202000270 - FIO SUT. AC. POLIGLIC. ABS. RÁPIDA 4/0 MULTIF
|
30 |
+
AG. CILIND. 17 MM 1/2 C (UNID)'', with quantity 288, unit UN, priced at 66.00
|
31 |
+
EUR, Origin: National'
|
32 |
+
- 'Product: ''2202000285 - FIO SUT. POLIPROPI. NÃO ABS. 4/0 MONOF. AG. LANC. 16
|
33 |
+
MM 3/8 (UNID)'', with quantity 468, unit UN, Estimated Value: 619.00 EUR'
|
34 |
+
- 'Item Description: ''Carro transporte de roupa limpa/roupa suja'', with quantity
|
35 |
+
1, unit Subcontracting Unit, priced at 574.00 EUR, Origin: National'
|
36 |
+
- source_sentence: Collect the details that are associated with product '' '2202000006
|
37 |
+
- FIO SUT. SEDA NÃO ABS. 0 MULTIF. SEM AGULHA (CART.)', with quantity 72, unit
|
38 |
+
UN
|
39 |
+
sentences:
|
40 |
+
- 'Item Description: ''2202000309 - FIO SUT. ABS. MÉDIO PRAZO 2/0 MONOF. BARBADO,
|
41 |
+
C/ AG. CILIND. 30MM 1/2C, 23CM (CART.)'', with quantity 24, unit UN, priced at
|
42 |
+
206.00 EUR, Origin: National'
|
43 |
+
- "Details for '2202000006 - FIO SUT. SEDA NÃO ABS. 0 MULTIF. SEM AGULHA (CART.)',\
|
44 |
+
\ with quantity 72, unit UN:\n - LOTE 82\n - Price: 854.00 EUR"
|
45 |
+
- 'LOTE 10
|
46 |
+
|
47 |
+
Description: ''Mesas apoio (anestesia e circulante)'', with quantity 4, unit Subcontracting
|
48 |
+
Unit
|
49 |
+
|
50 |
+
Price: 117.00 EUR'
|
51 |
+
- source_sentence: Collect the details that are associated with product '' '2202000251
|
52 |
+
- FIO SUT. ABS. LONGA 1 MONOF. AG. CILIND. 48 MM 1/2C 90CM (CART.)', with quantity
|
53 |
+
144, unit UN
|
54 |
+
sentences:
|
55 |
+
- "Details for UNKNOWN PRODUCT:\n - LOTE 34\n - Price: 477.00 EUR"
|
56 |
+
- "Details for '2202000251 - FIO SUT. ABS. LONGA 1 MONOF. AG. CILIND. 48 MM 1/2C\
|
57 |
+
\ 90CM (CART.)', with quantity 144, unit UN:\n - LOTE 73\n - Price: 644.00 EUR"
|
58 |
+
- 'Item Description: ''Mesas de Mayo'', with quantity 2, unit Subcontracting Unit,
|
59 |
+
priced at 651.00 EUR, Origin: National'
|
60 |
+
pipeline_tag: sentence-similarity
|
61 |
+
library_name: sentence-transformers
|
62 |
+
metrics:
|
63 |
+
- pearson_cosine
|
64 |
+
- spearman_cosine
|
65 |
+
model-index:
|
66 |
+
- name: SentenceTransformer based on nomic-ai/nomic-embed-text-v1
|
67 |
+
results:
|
68 |
+
- task:
|
69 |
+
type: semantic-similarity
|
70 |
+
name: Semantic Similarity
|
71 |
+
dataset:
|
72 |
+
name: Unknown
|
73 |
+
type: unknown
|
74 |
+
metrics:
|
75 |
+
- type: pearson_cosine
|
76 |
+
value: .nan
|
77 |
+
name: Pearson Cosine
|
78 |
+
- type: spearman_cosine
|
79 |
+
value: .nan
|
80 |
+
name: Spearman Cosine
|
81 |
+
---
|
82 |
+
|
83 |
+
# SentenceTransformer based on nomic-ai/nomic-embed-text-v1
|
84 |
+
|
85 |
+
This is a [sentence-transformers](https://www.SBERT.net) model finetuned from [nomic-ai/nomic-embed-text-v1](https://huggingface.co/nomic-ai/nomic-embed-text-v1). It maps sentences & paragraphs to a 768-dimensional dense vector space and can be used for semantic textual similarity, semantic search, paraphrase mining, text classification, clustering, and more.
|
86 |
+
|
87 |
+
## Model Details
|
88 |
+
|
89 |
+
### Model Description
|
90 |
+
- **Model Type:** Sentence Transformer
|
91 |
+
- **Base model:** [nomic-ai/nomic-embed-text-v1](https://huggingface.co/nomic-ai/nomic-embed-text-v1) <!-- at revision 720244025c1a7e15661a174c63cce63c8218e52b -->
|
92 |
+
- **Maximum Sequence Length:** 8192 tokens
|
93 |
+
- **Output Dimensionality:** 768 dimensions
|
94 |
+
- **Similarity Function:** Cosine Similarity
|
95 |
+
<!-- - **Training Dataset:** Unknown -->
|
96 |
+
<!-- - **Language:** Unknown -->
|
97 |
+
<!-- - **License:** Unknown -->
|
98 |
+
|
99 |
+
### Model Sources
|
100 |
+
|
101 |
+
- **Documentation:** [Sentence Transformers Documentation](https://sbert.net)
|
102 |
+
- **Repository:** [Sentence Transformers on GitHub](https://github.com/UKPLab/sentence-transformers)
|
103 |
+
- **Hugging Face:** [Sentence Transformers on Hugging Face](https://huggingface.co/models?library=sentence-transformers)
|
104 |
+
|
105 |
+
### Full Model Architecture
|
106 |
+
|
107 |
+
```
|
108 |
+
SentenceTransformer(
|
109 |
+
(0): Transformer({'max_seq_length': 8192, 'do_lower_case': False}) with Transformer model: NomicBertModel
|
110 |
+
(1): Pooling({'word_embedding_dimension': 768, '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})
|
111 |
+
(2): Normalize()
|
112 |
+
)
|
113 |
+
```
|
114 |
+
|
115 |
+
## Usage
|
116 |
+
|
117 |
+
### Direct Usage (Sentence Transformers)
|
118 |
+
|
119 |
+
First install the Sentence Transformers library:
|
120 |
+
|
121 |
+
```bash
|
122 |
+
pip install -U sentence-transformers
|
123 |
+
```
|
124 |
+
|
125 |
+
Then you can load this model and run inference.
|
126 |
+
```python
|
127 |
+
from sentence_transformers import SentenceTransformer
|
128 |
+
|
129 |
+
# Download from the 🤗 Hub
|
130 |
+
model = SentenceTransformer("ptpedroVortal/nomic_vortal_v3.4")
|
131 |
+
# Run inference
|
132 |
+
sentences = [
|
133 |
+
"Collect the details that are associated with product '' '2202000251 - FIO SUT. ABS. LONGA 1 MONOF. AG. CILIND. 48 MM 1/2C 90CM (CART.)', with quantity 144, unit UN",
|
134 |
+
"Details for '2202000251 - FIO SUT. ABS. LONGA 1 MONOF. AG. CILIND. 48 MM 1/2C 90CM (CART.)', with quantity 144, unit UN:\n - LOTE 73\n - Price: 644.00 EUR",
|
135 |
+
"Item Description: 'Mesas de Mayo', with quantity 2, unit Subcontracting Unit, priced at 651.00 EUR, Origin: National",
|
136 |
+
]
|
137 |
+
embeddings = model.encode(sentences)
|
138 |
+
print(embeddings.shape)
|
139 |
+
# [3, 768]
|
140 |
+
|
141 |
+
# Get the similarity scores for the embeddings
|
142 |
+
similarities = model.similarity(embeddings, embeddings)
|
143 |
+
print(similarities.shape)
|
144 |
+
# [3, 3]
|
145 |
+
```
|
146 |
+
|
147 |
+
<!--
|
148 |
+
### Direct Usage (Transformers)
|
149 |
+
|
150 |
+
<details><summary>Click to see the direct usage in Transformers</summary>
|
151 |
+
|
152 |
+
</details>
|
153 |
+
-->
|
154 |
+
|
155 |
+
<!--
|
156 |
+
### Downstream Usage (Sentence Transformers)
|
157 |
+
|
158 |
+
You can finetune this model on your own dataset.
|
159 |
+
|
160 |
+
<details><summary>Click to expand</summary>
|
161 |
+
|
162 |
+
</details>
|
163 |
+
-->
|
164 |
+
|
165 |
+
<!--
|
166 |
+
### Out-of-Scope Use
|
167 |
+
|
168 |
+
*List how the model may foreseeably be misused and address what users ought not to do with the model.*
|
169 |
+
-->
|
170 |
+
|
171 |
+
## Evaluation
|
172 |
+
|
173 |
+
### Metrics
|
174 |
+
|
175 |
+
#### Semantic Similarity
|
176 |
+
|
177 |
+
* Evaluated with <code>__main__.CustomEvaluator</code>
|
178 |
+
|
179 |
+
| Metric | Value |
|
180 |
+
|:--------------------|:--------|
|
181 |
+
| pearson_cosine | nan |
|
182 |
+
| **spearman_cosine** | **nan** |
|
183 |
+
|
184 |
+
<!--
|
185 |
+
## Bias, Risks and Limitations
|
186 |
+
|
187 |
+
*What are the known or foreseeable issues stemming from this model? You could also flag here known failure cases or weaknesses of the model.*
|
188 |
+
-->
|
189 |
+
|
190 |
+
<!--
|
191 |
+
### Recommendations
|
192 |
+
|
193 |
+
*What are recommendations with respect to the foreseeable issues? For example, filtering explicit content.*
|
194 |
+
-->
|
195 |
+
|
196 |
+
## Training Details
|
197 |
+
|
198 |
+
### Training Dataset
|
199 |
+
|
200 |
+
#### Unnamed Dataset
|
201 |
+
|
202 |
+
|
203 |
+
* Size: 2,382 training samples
|
204 |
+
* Columns: <code>query</code>, <code>correct_node</code>, and <code>score</code>
|
205 |
+
* Approximate statistics based on the first 1000 samples:
|
206 |
+
| | query | correct_node | score |
|
207 |
+
|:--------|:-----------------------------------------------------------------------------------|:-------------------------------------------------------------------------------------|:-----------------------------|
|
208 |
+
| type | string | string | int |
|
209 |
+
| details | <ul><li>min: 15 tokens</li><li>mean: 56.3 tokens</li><li>max: 154 tokens</li></ul> | <ul><li>min: 15 tokens</li><li>mean: 49.65 tokens</li><li>max: 1729 tokens</li></ul> | <ul><li>1: 100.00%</li></ul> |
|
210 |
+
* Samples:
|
211 |
+
| query | correct_node | score |
|
212 |
+
|:---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|:----------------------------------------------------------------------------------------------------------------------------------------------------------------------------|:---------------|
|
213 |
+
| <code>Collect the details that are associated with product '' '2202000275 - FIO SUT. POLIAMIDA NÃO ABS. 2/0 MONOF AG. CILIND. 30MM 1/2 LOOP (UNID)', with quantity 216, unit UN</code> | <code>LOTE 98<br>Description: '2202000275 - FIO SUT. POLIAMIDA NÃO ABS. 2/0 MONOF AG. CILIND. 30MM 1/2 LOOP (UNID)', with quantity 216, unit UN<br>Price: 940.00 EUR</code> | <code>1</code> |
|
214 |
+
| <code>Collect the details that are associated with product '' '2202000294 - FIO SUT. AC. POLIGLIC. ABS. 2/0 MULTIF SEM AGULHA PRÉ CORTADO (UNID)', with quantity 324, unit UN</code> | <code>Product: '2202000294 - FIO SUT. AC. POLIGLIC. ABS. 2/0 MULTIF SEM AGULHA PRÉ CORTADO (UNID)', with quantity 324, unit UN, Estimated Value: 696.00 EUR</code> | <code>1</code> |
|
215 |
+
| <code>Collect the details that are associated with Lot 4 product '' 'Mesas de Mayo', with quantity 2, unit Subcontracting Unit</code> | <code>LOTE 44<br>Description: 'Mesas de Mayo', with quantity 2, unit Subcontracting Unit<br>Price: 542.00 EUR</code> | <code>1</code> |
|
216 |
+
* Loss: [<code>MultipleNegativesRankingLoss</code>](https://sbert.net/docs/package_reference/sentence_transformer/losses.html#multiplenegativesrankingloss) with these parameters:
|
217 |
+
```json
|
218 |
+
{
|
219 |
+
"scale": 20.0,
|
220 |
+
"similarity_fct": "cos_sim"
|
221 |
+
}
|
222 |
+
```
|
223 |
+
|
224 |
+
### Evaluation Dataset
|
225 |
+
|
226 |
+
#### Unnamed Dataset
|
227 |
+
|
228 |
+
|
229 |
+
* Size: 297 evaluation samples
|
230 |
+
* Columns: <code>query</code>, <code>correct_node</code>, and <code>score</code>
|
231 |
+
* Approximate statistics based on the first 297 samples:
|
232 |
+
| | query | correct_node | score |
|
233 |
+
|:--------|:------------------------------------------------------------------------------------|:------------------------------------------------------------------------------------|:-----------------------------|
|
234 |
+
| type | string | string | int |
|
235 |
+
| details | <ul><li>min: 15 tokens</li><li>mean: 55.37 tokens</li><li>max: 154 tokens</li></ul> | <ul><li>min: 15 tokens</li><li>mean: 46.58 tokens</li><li>max: 435 tokens</li></ul> | <ul><li>1: 100.00%</li></ul> |
|
236 |
+
* Samples:
|
237 |
+
| query | correct_node | score |
|
238 |
+
|:-------------------------------------------------------------------------------------------------------------------------------------------------------|:---------------------------------------------------------------------------------------------------------------------------------------------------|:---------------|
|
239 |
+
| <code>Collect the details that are associated with Lot 7 product '' 'Carro transporte de roupa suja', with quantity 1, unit Subcontracting Unit</code> | <code>Item Description: 'Carro transporte de roupa suja', with quantity 1, unit Subcontracting Unit, priced at 628.00 EUR, Origin: National</code> | <code>1</code> |
|
240 |
+
| <code>Collect the details that are associated with Lot 10 product '' 'Mesas para cirurgia', with quantity 2, unit Subcontracting Unit</code> | <code>Details for 'Mesas para cirurgia', with quantity 2, unit Subcontracting Unit:<br> - LOTE 83<br> - Price: 940.00 EUR</code> | <code>1</code> |
|
241 |
+
| <code>Collect the details that are associated with Lot 1 product '' 'PAINEL MULTIPLO ALERGENOS RESPIRATORIOS ', with quantity 1152, unit UND</code> | <code>Product: 'PAINEL MULTIPLO ALERGENOS RESPIRATORIOS ', with quantity 1152, unit UND, Estimated Value: 714.00 EUR</code> | <code>1</code> |
|
242 |
+
* Loss: [<code>MultipleNegativesRankingLoss</code>](https://sbert.net/docs/package_reference/sentence_transformer/losses.html#multiplenegativesrankingloss) with these parameters:
|
243 |
+
```json
|
244 |
+
{
|
245 |
+
"scale": 20.0,
|
246 |
+
"similarity_fct": "cos_sim"
|
247 |
+
}
|
248 |
+
```
|
249 |
+
|
250 |
+
### Training Hyperparameters
|
251 |
+
#### Non-Default Hyperparameters
|
252 |
+
|
253 |
+
- `eval_strategy`: steps
|
254 |
+
- `per_device_train_batch_size`: 16
|
255 |
+
- `per_device_eval_batch_size`: 16
|
256 |
+
- `num_train_epochs`: 10
|
257 |
+
- `warmup_ratio`: 0.1
|
258 |
+
- `bf16`: True
|
259 |
+
- `load_best_model_at_end`: True
|
260 |
+
- `batch_sampler`: no_duplicates
|
261 |
+
|
262 |
+
#### All Hyperparameters
|
263 |
+
<details><summary>Click to expand</summary>
|
264 |
+
|
265 |
+
- `overwrite_output_dir`: False
|
266 |
+
- `do_predict`: False
|
267 |
+
- `eval_strategy`: steps
|
268 |
+
- `prediction_loss_only`: True
|
269 |
+
- `per_device_train_batch_size`: 16
|
270 |
+
- `per_device_eval_batch_size`: 16
|
271 |
+
- `per_gpu_train_batch_size`: None
|
272 |
+
- `per_gpu_eval_batch_size`: None
|
273 |
+
- `gradient_accumulation_steps`: 1
|
274 |
+
- `eval_accumulation_steps`: None
|
275 |
+
- `torch_empty_cache_steps`: None
|
276 |
+
- `learning_rate`: 5e-05
|
277 |
+
- `weight_decay`: 0.0
|
278 |
+
- `adam_beta1`: 0.9
|
279 |
+
- `adam_beta2`: 0.999
|
280 |
+
- `adam_epsilon`: 1e-08
|
281 |
+
- `max_grad_norm`: 1.0
|
282 |
+
- `num_train_epochs`: 10
|
283 |
+
- `max_steps`: -1
|
284 |
+
- `lr_scheduler_type`: linear
|
285 |
+
- `lr_scheduler_kwargs`: {}
|
286 |
+
- `warmup_ratio`: 0.1
|
287 |
+
- `warmup_steps`: 0
|
288 |
+
- `log_level`: passive
|
289 |
+
- `log_level_replica`: warning
|
290 |
+
- `log_on_each_node`: True
|
291 |
+
- `logging_nan_inf_filter`: True
|
292 |
+
- `save_safetensors`: True
|
293 |
+
- `save_on_each_node`: False
|
294 |
+
- `save_only_model`: False
|
295 |
+
- `restore_callback_states_from_checkpoint`: False
|
296 |
+
- `no_cuda`: False
|
297 |
+
- `use_cpu`: False
|
298 |
+
- `use_mps_device`: False
|
299 |
+
- `seed`: 42
|
300 |
+
- `data_seed`: None
|
301 |
+
- `jit_mode_eval`: False
|
302 |
+
- `use_ipex`: False
|
303 |
+
- `bf16`: True
|
304 |
+
- `fp16`: False
|
305 |
+
- `fp16_opt_level`: O1
|
306 |
+
- `half_precision_backend`: auto
|
307 |
+
- `bf16_full_eval`: False
|
308 |
+
- `fp16_full_eval`: False
|
309 |
+
- `tf32`: None
|
310 |
+
- `local_rank`: 0
|
311 |
+
- `ddp_backend`: None
|
312 |
+
- `tpu_num_cores`: None
|
313 |
+
- `tpu_metrics_debug`: False
|
314 |
+
- `debug`: []
|
315 |
+
- `dataloader_drop_last`: False
|
316 |
+
- `dataloader_num_workers`: 0
|
317 |
+
- `dataloader_prefetch_factor`: None
|
318 |
+
- `past_index`: -1
|
319 |
+
- `disable_tqdm`: False
|
320 |
+
- `remove_unused_columns`: True
|
321 |
+
- `label_names`: None
|
322 |
+
- `load_best_model_at_end`: True
|
323 |
+
- `ignore_data_skip`: False
|
324 |
+
- `fsdp`: []
|
325 |
+
- `fsdp_min_num_params`: 0
|
326 |
+
- `fsdp_config`: {'min_num_params': 0, 'xla': False, 'xla_fsdp_v2': False, 'xla_fsdp_grad_ckpt': False}
|
327 |
+
- `fsdp_transformer_layer_cls_to_wrap`: None
|
328 |
+
- `accelerator_config`: {'split_batches': False, 'dispatch_batches': None, 'even_batches': True, 'use_seedable_sampler': True, 'non_blocking': False, 'gradient_accumulation_kwargs': None}
|
329 |
+
- `deepspeed`: None
|
330 |
+
- `label_smoothing_factor`: 0.0
|
331 |
+
- `optim`: adamw_torch
|
332 |
+
- `optim_args`: None
|
333 |
+
- `adafactor`: False
|
334 |
+
- `group_by_length`: False
|
335 |
+
- `length_column_name`: length
|
336 |
+
- `ddp_find_unused_parameters`: None
|
337 |
+
- `ddp_bucket_cap_mb`: None
|
338 |
+
- `ddp_broadcast_buffers`: False
|
339 |
+
- `dataloader_pin_memory`: True
|
340 |
+
- `dataloader_persistent_workers`: False
|
341 |
+
- `skip_memory_metrics`: True
|
342 |
+
- `use_legacy_prediction_loop`: False
|
343 |
+
- `push_to_hub`: False
|
344 |
+
- `resume_from_checkpoint`: None
|
345 |
+
- `hub_model_id`: None
|
346 |
+
- `hub_strategy`: every_save
|
347 |
+
- `hub_private_repo`: False
|
348 |
+
- `hub_always_push`: False
|
349 |
+
- `gradient_checkpointing`: False
|
350 |
+
- `gradient_checkpointing_kwargs`: None
|
351 |
+
- `include_inputs_for_metrics`: False
|
352 |
+
- `include_for_metrics`: []
|
353 |
+
- `eval_do_concat_batches`: True
|
354 |
+
- `fp16_backend`: auto
|
355 |
+
- `push_to_hub_model_id`: None
|
356 |
+
- `push_to_hub_organization`: None
|
357 |
+
- `mp_parameters`:
|
358 |
+
- `auto_find_batch_size`: False
|
359 |
+
- `full_determinism`: False
|
360 |
+
- `torchdynamo`: None
|
361 |
+
- `ray_scope`: last
|
362 |
+
- `ddp_timeout`: 1800
|
363 |
+
- `torch_compile`: False
|
364 |
+
- `torch_compile_backend`: None
|
365 |
+
- `torch_compile_mode`: None
|
366 |
+
- `dispatch_batches`: None
|
367 |
+
- `split_batches`: None
|
368 |
+
- `include_tokens_per_second`: False
|
369 |
+
- `include_num_input_tokens_seen`: False
|
370 |
+
- `neftune_noise_alpha`: None
|
371 |
+
- `optim_target_modules`: None
|
372 |
+
- `batch_eval_metrics`: False
|
373 |
+
- `eval_on_start`: False
|
374 |
+
- `use_liger_kernel`: False
|
375 |
+
- `eval_use_gather_object`: False
|
376 |
+
- `average_tokens_across_devices`: False
|
377 |
+
- `prompts`: None
|
378 |
+
- `batch_sampler`: no_duplicates
|
379 |
+
- `multi_dataset_batch_sampler`: proportional
|
380 |
+
|
381 |
+
</details>
|
382 |
+
|
383 |
+
### Training Logs
|
384 |
+
| Epoch | Step | Training Loss | Validation Loss | spearman_cosine |
|
385 |
+
|:----------:|:-------:|:-------------:|:---------------:|:---------------:|
|
386 |
+
| 0.6711 | 100 | 0.6485 | 0.4410 | nan |
|
387 |
+
| 1.3356 | 200 | 0.5026 | 0.4399 | nan |
|
388 |
+
| **2.0067** | **300** | **0.491** | **0.4175** | **nan** |
|
389 |
+
| 2.6711 | 400 | 0.442 | 0.4409 | nan |
|
390 |
+
| 3.3356 | 500 | 0.3999 | 0.4421 | nan |
|
391 |
+
| 4.0067 | 600 | 0.367 | 0.6182 | nan |
|
392 |
+
| 4.6711 | 700 | 0.3743 | 0.6104 | nan |
|
393 |
+
| 5.3356 | 800 | 0.1972 | 0.6115 | nan |
|
394 |
+
|
395 |
+
* The bold row denotes the saved checkpoint.
|
396 |
+
|
397 |
+
### Framework Versions
|
398 |
+
- Python: 3.10.14
|
399 |
+
- Sentence Transformers: 3.3.1
|
400 |
+
- Transformers: 4.47.0.dev0
|
401 |
+
- PyTorch: 2.5.1+cu121
|
402 |
+
- Accelerate: 1.1.1
|
403 |
+
- Datasets: 3.1.0
|
404 |
+
- Tokenizers: 0.20.4
|
405 |
+
|
406 |
+
## Citation
|
407 |
+
|
408 |
+
### BibTeX
|
409 |
+
|
410 |
+
#### Sentence Transformers
|
411 |
+
```bibtex
|
412 |
+
@inproceedings{reimers-2019-sentence-bert,
|
413 |
+
title = "Sentence-BERT: Sentence Embeddings using Siamese BERT-Networks",
|
414 |
+
author = "Reimers, Nils and Gurevych, Iryna",
|
415 |
+
booktitle = "Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing",
|
416 |
+
month = "11",
|
417 |
+
year = "2019",
|
418 |
+
publisher = "Association for Computational Linguistics",
|
419 |
+
url = "https://arxiv.org/abs/1908.10084",
|
420 |
+
}
|
421 |
+
```
|
422 |
+
|
423 |
+
#### MultipleNegativesRankingLoss
|
424 |
+
```bibtex
|
425 |
+
@misc{henderson2017efficient,
|
426 |
+
title={Efficient Natural Language Response Suggestion for Smart Reply},
|
427 |
+
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},
|
428 |
+
year={2017},
|
429 |
+
eprint={1705.00652},
|
430 |
+
archivePrefix={arXiv},
|
431 |
+
primaryClass={cs.CL}
|
432 |
+
}
|
433 |
+
```
|
434 |
+
|
435 |
+
<!--
|
436 |
+
## Glossary
|
437 |
+
|
438 |
+
*Clearly define terms in order to be accessible across audiences.*
|
439 |
+
-->
|
440 |
+
|
441 |
+
<!--
|
442 |
+
## Model Card Authors
|
443 |
+
|
444 |
+
*Lists the people who create the model card, providing recognition and accountability for the detailed work that goes into its construction.*
|
445 |
+
-->
|
446 |
+
|
447 |
+
<!--
|
448 |
+
## Model Card Contact
|
449 |
+
|
450 |
+
*Provides a way for people who have updates to the Model Card, suggestions, or questions, to contact the Model Card authors.*
|
451 |
+
-->
|
config.json
ADDED
@@ -0,0 +1,58 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"_name_or_path": "nomic-ai/nomic-embed-text-v1",
|
3 |
+
"activation_function": "swiglu",
|
4 |
+
"architectures": [
|
5 |
+
"NomicBertModel"
|
6 |
+
],
|
7 |
+
"attn_pdrop": 0.0,
|
8 |
+
"auto_map": {
|
9 |
+
"AutoConfig": "nomic-ai/nomic-bert-2048--configuration_hf_nomic_bert.NomicBertConfig",
|
10 |
+
"AutoModel": "nomic-ai/nomic-bert-2048--modeling_hf_nomic_bert.NomicBertModel",
|
11 |
+
"AutoModelForMaskedLM": "nomic-ai/nomic-bert-2048--modeling_hf_nomic_bert.NomicBertForPreTraining"
|
12 |
+
},
|
13 |
+
"bos_token_id": null,
|
14 |
+
"causal": false,
|
15 |
+
"dense_seq_output": true,
|
16 |
+
"embd_pdrop": 0.0,
|
17 |
+
"eos_token_id": null,
|
18 |
+
"fused_bias_fc": true,
|
19 |
+
"fused_dropout_add_ln": true,
|
20 |
+
"initializer_range": 0.02,
|
21 |
+
"layer_norm_epsilon": 1e-12,
|
22 |
+
"max_trained_positions": 2048,
|
23 |
+
"mlp_fc1_bias": false,
|
24 |
+
"mlp_fc2_bias": false,
|
25 |
+
"model_type": "nomic_bert",
|
26 |
+
"n_embd": 768,
|
27 |
+
"n_head": 12,
|
28 |
+
"n_inner": 3072,
|
29 |
+
"n_layer": 12,
|
30 |
+
"n_positions": 8192,
|
31 |
+
"pad_vocab_size_multiple": 64,
|
32 |
+
"parallel_block": false,
|
33 |
+
"parallel_block_tied_norm": false,
|
34 |
+
"prenorm": false,
|
35 |
+
"qkv_proj_bias": false,
|
36 |
+
"reorder_and_upcast_attn": false,
|
37 |
+
"resid_pdrop": 0.0,
|
38 |
+
"rotary_emb_base": 1000,
|
39 |
+
"rotary_emb_fraction": 1.0,
|
40 |
+
"rotary_emb_interleaved": false,
|
41 |
+
"rotary_emb_scale_base": null,
|
42 |
+
"rotary_scaling_factor": 2,
|
43 |
+
"scale_attn_by_inverse_layer_idx": false,
|
44 |
+
"scale_attn_weights": true,
|
45 |
+
"summary_activation": null,
|
46 |
+
"summary_first_dropout": 0.1,
|
47 |
+
"summary_proj_to_labels": true,
|
48 |
+
"summary_type": "cls_index",
|
49 |
+
"summary_use_proj": true,
|
50 |
+
"torch_dtype": "float32",
|
51 |
+
"transformers_version": "4.47.0.dev0",
|
52 |
+
"type_vocab_size": 2,
|
53 |
+
"use_cache": true,
|
54 |
+
"use_flash_attn": true,
|
55 |
+
"use_rms_norm": false,
|
56 |
+
"use_xentropy": true,
|
57 |
+
"vocab_size": 30528
|
58 |
+
}
|
config_sentence_transformers.json
ADDED
@@ -0,0 +1,10 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"__version__": {
|
3 |
+
"sentence_transformers": "3.3.1",
|
4 |
+
"transformers": "4.47.0.dev0",
|
5 |
+
"pytorch": "2.5.1+cu121"
|
6 |
+
},
|
7 |
+
"prompts": {},
|
8 |
+
"default_prompt_name": null,
|
9 |
+
"similarity_fn_name": "cosine"
|
10 |
+
}
|
model.safetensors
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:e5366ce602da11718a8048449afbaf0d41c0a37c7957b964ec5b7a5d36ad4b91
|
3 |
+
size 546938168
|
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": 8192,
|
3 |
+
"do_lower_case": false
|
4 |
+
}
|
special_tokens_map.json
ADDED
@@ -0,0 +1,37 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"cls_token": {
|
3 |
+
"content": "[CLS]",
|
4 |
+
"lstrip": false,
|
5 |
+
"normalized": false,
|
6 |
+
"rstrip": false,
|
7 |
+
"single_word": false
|
8 |
+
},
|
9 |
+
"mask_token": {
|
10 |
+
"content": "[MASK]",
|
11 |
+
"lstrip": false,
|
12 |
+
"normalized": false,
|
13 |
+
"rstrip": false,
|
14 |
+
"single_word": false
|
15 |
+
},
|
16 |
+
"pad_token": {
|
17 |
+
"content": "[PAD]",
|
18 |
+
"lstrip": false,
|
19 |
+
"normalized": false,
|
20 |
+
"rstrip": false,
|
21 |
+
"single_word": false
|
22 |
+
},
|
23 |
+
"sep_token": {
|
24 |
+
"content": "[SEP]",
|
25 |
+
"lstrip": false,
|
26 |
+
"normalized": false,
|
27 |
+
"rstrip": false,
|
28 |
+
"single_word": false
|
29 |
+
},
|
30 |
+
"unk_token": {
|
31 |
+
"content": "[UNK]",
|
32 |
+
"lstrip": false,
|
33 |
+
"normalized": false,
|
34 |
+
"rstrip": false,
|
35 |
+
"single_word": false
|
36 |
+
}
|
37 |
+
}
|
tokenizer.json
ADDED
The diff for this file is too large to render.
See raw diff
|
|
tokenizer_config.json
ADDED
@@ -0,0 +1,56 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"added_tokens_decoder": {
|
3 |
+
"0": {
|
4 |
+
"content": "[PAD]",
|
5 |
+
"lstrip": false,
|
6 |
+
"normalized": false,
|
7 |
+
"rstrip": false,
|
8 |
+
"single_word": false,
|
9 |
+
"special": true
|
10 |
+
},
|
11 |
+
"100": {
|
12 |
+
"content": "[UNK]",
|
13 |
+
"lstrip": false,
|
14 |
+
"normalized": false,
|
15 |
+
"rstrip": false,
|
16 |
+
"single_word": false,
|
17 |
+
"special": true
|
18 |
+
},
|
19 |
+
"101": {
|
20 |
+
"content": "[CLS]",
|
21 |
+
"lstrip": false,
|
22 |
+
"normalized": false,
|
23 |
+
"rstrip": false,
|
24 |
+
"single_word": false,
|
25 |
+
"special": true
|
26 |
+
},
|
27 |
+
"102": {
|
28 |
+
"content": "[SEP]",
|
29 |
+
"lstrip": false,
|
30 |
+
"normalized": false,
|
31 |
+
"rstrip": false,
|
32 |
+
"single_word": false,
|
33 |
+
"special": true
|
34 |
+
},
|
35 |
+
"103": {
|
36 |
+
"content": "[MASK]",
|
37 |
+
"lstrip": false,
|
38 |
+
"normalized": false,
|
39 |
+
"rstrip": false,
|
40 |
+
"single_word": false,
|
41 |
+
"special": true
|
42 |
+
}
|
43 |
+
},
|
44 |
+
"clean_up_tokenization_spaces": true,
|
45 |
+
"cls_token": "[CLS]",
|
46 |
+
"do_lower_case": true,
|
47 |
+
"extra_special_tokens": {},
|
48 |
+
"mask_token": "[MASK]",
|
49 |
+
"model_max_length": 8192,
|
50 |
+
"pad_token": "[PAD]",
|
51 |
+
"sep_token": "[SEP]",
|
52 |
+
"strip_accents": null,
|
53 |
+
"tokenize_chinese_chars": true,
|
54 |
+
"tokenizer_class": "BertTokenizer",
|
55 |
+
"unk_token": "[UNK]"
|
56 |
+
}
|
vocab.txt
ADDED
The diff for this file is too large to render.
See raw diff
|
|