Update README.md
Browse files
README.md
CHANGED
|
@@ -8,643 +8,282 @@ tags:
|
|
| 8 |
- loss:MultipleNegativesRankingLoss
|
| 9 |
base_model: Shuu12121/CodeModernBERT-Owl-3.0
|
| 10 |
widget:
|
| 11 |
-
- source_sentence:
|
|
|
|
| 12 |
|
| 13 |
-
@return Returns the value of the attribute, or 0, if it hasn'
|
| 14 |
-
JSF file.
|
| 15 |
sentences:
|
| 16 |
-
-
|
| 17 |
-
|
| 18 |
-
|
| 19 |
-
|
| 20 |
-
|
| 21 |
-
|
| 22 |
-
|
| 23 |
-
|
| 24 |
-
|
| 25 |
-
|
| 26 |
-
|
| 27 |
-
|
| 28 |
-
|
| 29 |
-
|
| 30 |
-
|
| 31 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 32 |
|
| 33 |
@param date
|
| 34 |
-
|
| 35 |
The Date-object to get the minutes.
|
| 36 |
-
|
| 37 |
-
@return The minutes from the Date-object.'
|
| 38 |
sentences:
|
| 39 |
-
- "public static int getMinutes(final Date date)\n\t{\n\t\tfinal Calendar calendar\
|
| 40 |
-
|
| 41 |
-
|
| 42 |
-
|
| 43 |
-
|
| 44 |
-
|
| 45 |
-
|
| 46 |
-
|
| 47 |
-
|
| 48 |
-
|
| 49 |
-
|
| 50 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 51 |
sentences:
|
| 52 |
-
-
|
| 53 |
-
|
| 54 |
-
|
| 55 |
-
|
| 56 |
-
|
| 57 |
-
|
| 58 |
-
|
| 59 |
-
|
| 60 |
-
|
| 61 |
-
|
| 62 |
-
|
| 63 |
-
|
| 64 |
-
|
| 65 |
-
|
| 66 |
-
|
| 67 |
-
|
| 68 |
-
|
| 69 |
-
|
| 70 |
-
|
| 71 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 72 |
sentences:
|
| 73 |
-
-
|
| 74 |
-
|
| 75 |
-
|
| 76 |
-
|
| 77 |
-
|
| 78 |
-
|
| 79 |
-
|
| 80 |
-
|
| 81 |
-
|
| 82 |
-
|
| 83 |
-
|
| 84 |
-
|
| 85 |
-
|
| 86 |
-
|
| 87 |
-
|
| 88 |
-
|
| 89 |
-
|
| 90 |
-
|
| 91 |
-
|
| 92 |
-
|
| 93 |
-
|
| 94 |
-
|
| 95 |
-
|
| 96 |
-
|
| 97 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 98 |
- source_sentence: get test root
|
| 99 |
sentences:
|
| 100 |
-
-
|
| 101 |
-
|
| 102 |
-
|
| 103 |
-
|
| 104 |
-
|
| 105 |
-
|
| 106 |
-
|
| 107 |
-
|
| 108 |
-
|
| 109 |
-
|
| 110 |
-
|
| 111 |
-
|
| 112 |
-
|
| 113 |
-
|
| 114 |
-
|
| 115 |
-
|
| 116 |
-
|
| 117 |
-
|
| 118 |
-
|
| 119 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 120 |
pipeline_tag: sentence-similarity
|
| 121 |
library_name: sentence-transformers
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 122 |
---
|
| 123 |
|
| 124 |
-
#
|
| 125 |
-
|
| 126 |
-
This is a [sentence-transformers](https://www.SBERT.net) model finetuned from [Shuu12121/CodeModernBERT-Owl-3.0](https://huggingface.co/Shuu12121/CodeModernBERT-Owl-3.0). 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.
|
| 127 |
|
| 128 |
-
|
| 129 |
|
| 130 |
-
|
| 131 |
-
- **Model Type:** Sentence Transformer
|
| 132 |
-
- **Base model:** [Shuu12121/CodeModernBERT-Owl-3.0](https://huggingface.co/Shuu12121/CodeModernBERT-Owl-3.0) <!-- at revision a6beebbd776ae122f34f875dfa731557a1f70d8f -->
|
| 133 |
-
- **Maximum Sequence Length:** 1024 tokens
|
| 134 |
-
- **Output Dimensionality:** 768 dimensions
|
| 135 |
-
- **Similarity Function:** Cosine Similarity
|
| 136 |
-
<!-- - **Training Dataset:** Unknown -->
|
| 137 |
-
<!-- - **Language:** Unknown -->
|
| 138 |
-
<!-- - **License:** Unknown -->
|
| 139 |
|
| 140 |
-
|
| 141 |
-
|
| 142 |
-
- **Documentation:** [Sentence Transformers Documentation](https://sbert.net)
|
| 143 |
-
- **Repository:** [Sentence Transformers on GitHub](https://github.com/UKPLab/sentence-transformers)
|
| 144 |
-
- **Hugging Face:** [Sentence Transformers on Hugging Face](https://huggingface.co/models?library=sentence-transformers)
|
| 145 |
-
|
| 146 |
-
### Full Model Architecture
|
| 147 |
|
| 148 |
-
|
| 149 |
-
SentenceTransformer(
|
| 150 |
-
(0): Transformer({'max_seq_length': 1024, 'do_lower_case': False}) with Transformer model: ModernBertModel
|
| 151 |
-
(1): Pooling({'word_embedding_dimension': 768, '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})
|
| 152 |
-
)
|
| 153 |
-
```
|
| 154 |
|
| 155 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 156 |
|
| 157 |
-
|
| 158 |
|
| 159 |
-
|
| 160 |
|
| 161 |
-
|
| 162 |
-
pip install -U sentence-transformers
|
| 163 |
-
```
|
| 164 |
|
| 165 |
-
|
| 166 |
-
|
| 167 |
-
|
| 168 |
-
|
| 169 |
-
|
| 170 |
-
|
| 171 |
-
|
| 172 |
-
|
| 173 |
-
|
| 174 |
-
|
| 175 |
-
'protected Object parseKeyElement(Element keyEle, BeanDefinition bd, String defaultKeyTypeName) {\n NodeList nl = keyEle.getChildNodes();\n Element subElement = null;\n for (int i = 0; i < nl.getLength(); i++) {\n Node node = nl.item(i);\n if (node instanceof Element) {\n // Child element is what we\'re looking for.\n if (subElement != null)\n error("<key> element must not contain more than one value sub-element", keyEle);\n else subElement = (Element) node;\n }\n }\n return parsePropertySubElement(subElement, bd, defaultKeyTypeName);\n }',
|
| 176 |
-
]
|
| 177 |
-
embeddings = model.encode(sentences)
|
| 178 |
-
print(embeddings.shape)
|
| 179 |
-
# [3, 768]
|
| 180 |
-
|
| 181 |
-
# Get the similarity scores for the embeddings
|
| 182 |
-
similarities = model.similarity(embeddings, embeddings)
|
| 183 |
-
print(similarities.shape)
|
| 184 |
-
# [3, 3]
|
| 185 |
-
```
|
| 186 |
|
| 187 |
-
<!--
|
| 188 |
-
### Direct Usage (Transformers)
|
| 189 |
-
|
| 190 |
-
<details><summary>Click to see the direct usage in Transformers</summary>
|
| 191 |
|
| 192 |
</details>
|
| 193 |
-
-->
|
| 194 |
|
| 195 |
-
|
| 196 |
-
### Downstream Usage (Sentence Transformers)
|
| 197 |
|
| 198 |
-
|
| 199 |
|
| 200 |
-
|
| 201 |
|
| 202 |
-
|
| 203 |
-
|
| 204 |
-
|
| 205 |
-
<!--
|
| 206 |
-
### Out-of-Scope Use
|
| 207 |
-
|
| 208 |
-
*List how the model may foreseeably be misused and address what users ought not to do with the model.*
|
| 209 |
-
-->
|
| 210 |
-
|
| 211 |
-
<!--
|
| 212 |
-
## Bias, Risks and Limitations
|
| 213 |
-
|
| 214 |
-
*What are the known or foreseeable issues stemming from this model? You could also flag here known failure cases or weaknesses of the model.*
|
| 215 |
-
-->
|
| 216 |
-
|
| 217 |
-
<!--
|
| 218 |
-
### Recommendations
|
| 219 |
-
|
| 220 |
-
*What are recommendations with respect to the foreseeable issues? For example, filtering explicit content.*
|
| 221 |
-
-->
|
| 222 |
-
|
| 223 |
-
## Training Details
|
| 224 |
-
|
| 225 |
-
### Training Dataset
|
| 226 |
-
|
| 227 |
-
#### Unnamed Dataset
|
| 228 |
-
|
| 229 |
-
* Size: 7,059,200 training samples
|
| 230 |
-
* Columns: <code>sentence_0</code>, <code>sentence_1</code>, and <code>label</code>
|
| 231 |
-
* Approximate statistics based on the first 1000 samples:
|
| 232 |
-
| | sentence_0 | sentence_1 | label |
|
| 233 |
-
|:--------|:-----------------------------------------------------------------------------------|:--------------------------------------------------------------------------------------|:--------------------------------------------------------------|
|
| 234 |
-
| type | string | string | float |
|
| 235 |
-
| details | <ul><li>min: 3 tokens</li><li>mean: 51.42 tokens</li><li>max: 974 tokens</li></ul> | <ul><li>min: 29 tokens</li><li>mean: 162.71 tokens</li><li>max: 1024 tokens</li></ul> | <ul><li>min: 1.0</li><li>mean: 1.0</li><li>max: 1.0</li></ul> |
|
| 236 |
-
* Samples:
|
| 237 |
-
| sentence_0 | sentence_1 | label |
|
| 238 |
-
|:---------------------------------------------------------------------------------------|:----------------------------------------------------------------------------------------------------------------------------------------------------------|:-----------------|
|
| 239 |
-
| <code>// SetDefaultVersionId sets the DefaultVersionId field's value.</code> | <code>func (s *Policy) SetDefaultVersionId(v string) *Policy {<br> s.DefaultVersionId = &v<br> return s<br>}</code> | <code>1.0</code> |
|
| 240 |
-
| <code>// SetNextPageToken sets the NextPageToken field's value.</code> | <code>func (s *ListBudgetsForResourceOutput) SetNextPageToken(v string) *ListBudgetsForResourceOutput {<br> s.NextPageToken = &v<br> return s<br>}</code> | <code>1.0</code> |
|
| 241 |
-
| <code>// SetHealthyThresholdCount sets the HealthyThresholdCount field's value.</code> | <code>func (s *TargetGroup) SetHealthyThresholdCount(v int64) *TargetGroup {<br> s.HealthyThresholdCount = &v<br> return s<br>}</code> | <code>1.0</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 |
-
- `per_device_train_batch_size`: 200
|
| 254 |
-
- `per_device_eval_batch_size`: 200
|
| 255 |
-
- `fp16`: True
|
| 256 |
-
- `multi_dataset_batch_sampler`: round_robin
|
| 257 |
-
|
| 258 |
-
#### All Hyperparameters
|
| 259 |
-
<details><summary>Click to expand</summary>
|
| 260 |
-
|
| 261 |
-
- `overwrite_output_dir`: False
|
| 262 |
-
- `do_predict`: False
|
| 263 |
-
- `eval_strategy`: no
|
| 264 |
-
- `prediction_loss_only`: True
|
| 265 |
-
- `per_device_train_batch_size`: 200
|
| 266 |
-
- `per_device_eval_batch_size`: 200
|
| 267 |
-
- `per_gpu_train_batch_size`: None
|
| 268 |
-
- `per_gpu_eval_batch_size`: None
|
| 269 |
-
- `gradient_accumulation_steps`: 1
|
| 270 |
-
- `eval_accumulation_steps`: None
|
| 271 |
-
- `torch_empty_cache_steps`: None
|
| 272 |
-
- `learning_rate`: 5e-05
|
| 273 |
-
- `weight_decay`: 0.0
|
| 274 |
-
- `adam_beta1`: 0.9
|
| 275 |
-
- `adam_beta2`: 0.999
|
| 276 |
-
- `adam_epsilon`: 1e-08
|
| 277 |
-
- `max_grad_norm`: 1
|
| 278 |
-
- `num_train_epochs`: 3
|
| 279 |
-
- `max_steps`: -1
|
| 280 |
-
- `lr_scheduler_type`: linear
|
| 281 |
-
- `lr_scheduler_kwargs`: {}
|
| 282 |
-
- `warmup_ratio`: 0.0
|
| 283 |
-
- `warmup_steps`: 0
|
| 284 |
-
- `log_level`: passive
|
| 285 |
-
- `log_level_replica`: warning
|
| 286 |
-
- `log_on_each_node`: True
|
| 287 |
-
- `logging_nan_inf_filter`: True
|
| 288 |
-
- `save_safetensors`: True
|
| 289 |
-
- `save_on_each_node`: False
|
| 290 |
-
- `save_only_model`: False
|
| 291 |
-
- `restore_callback_states_from_checkpoint`: False
|
| 292 |
-
- `no_cuda`: False
|
| 293 |
-
- `use_cpu`: False
|
| 294 |
-
- `use_mps_device`: False
|
| 295 |
-
- `seed`: 42
|
| 296 |
-
- `data_seed`: None
|
| 297 |
-
- `jit_mode_eval`: False
|
| 298 |
-
- `use_ipex`: False
|
| 299 |
-
- `bf16`: False
|
| 300 |
-
- `fp16`: True
|
| 301 |
-
- `fp16_opt_level`: O1
|
| 302 |
-
- `half_precision_backend`: auto
|
| 303 |
-
- `bf16_full_eval`: False
|
| 304 |
-
- `fp16_full_eval`: False
|
| 305 |
-
- `tf32`: None
|
| 306 |
-
- `local_rank`: 0
|
| 307 |
-
- `ddp_backend`: None
|
| 308 |
-
- `tpu_num_cores`: None
|
| 309 |
-
- `tpu_metrics_debug`: False
|
| 310 |
-
- `debug`: []
|
| 311 |
-
- `dataloader_drop_last`: False
|
| 312 |
-
- `dataloader_num_workers`: 0
|
| 313 |
-
- `dataloader_prefetch_factor`: None
|
| 314 |
-
- `past_index`: -1
|
| 315 |
-
- `disable_tqdm`: False
|
| 316 |
-
- `remove_unused_columns`: True
|
| 317 |
-
- `label_names`: None
|
| 318 |
-
- `load_best_model_at_end`: False
|
| 319 |
-
- `ignore_data_skip`: False
|
| 320 |
-
- `fsdp`: []
|
| 321 |
-
- `fsdp_min_num_params`: 0
|
| 322 |
-
- `fsdp_config`: {'min_num_params': 0, 'xla': False, 'xla_fsdp_v2': False, 'xla_fsdp_grad_ckpt': False}
|
| 323 |
-
- `fsdp_transformer_layer_cls_to_wrap`: None
|
| 324 |
-
- `accelerator_config`: {'split_batches': False, 'dispatch_batches': None, 'even_batches': True, 'use_seedable_sampler': True, 'non_blocking': False, 'gradient_accumulation_kwargs': None}
|
| 325 |
-
- `deepspeed`: None
|
| 326 |
-
- `label_smoothing_factor`: 0.0
|
| 327 |
-
- `optim`: adamw_torch
|
| 328 |
-
- `optim_args`: None
|
| 329 |
-
- `adafactor`: False
|
| 330 |
-
- `group_by_length`: False
|
| 331 |
-
- `length_column_name`: length
|
| 332 |
-
- `ddp_find_unused_parameters`: None
|
| 333 |
-
- `ddp_bucket_cap_mb`: None
|
| 334 |
-
- `ddp_broadcast_buffers`: False
|
| 335 |
-
- `dataloader_pin_memory`: True
|
| 336 |
-
- `dataloader_persistent_workers`: False
|
| 337 |
-
- `skip_memory_metrics`: True
|
| 338 |
-
- `use_legacy_prediction_loop`: False
|
| 339 |
-
- `push_to_hub`: False
|
| 340 |
-
- `resume_from_checkpoint`: None
|
| 341 |
-
- `hub_model_id`: None
|
| 342 |
-
- `hub_strategy`: every_save
|
| 343 |
-
- `hub_private_repo`: None
|
| 344 |
-
- `hub_always_push`: False
|
| 345 |
-
- `gradient_checkpointing`: False
|
| 346 |
-
- `gradient_checkpointing_kwargs`: None
|
| 347 |
-
- `include_inputs_for_metrics`: False
|
| 348 |
-
- `include_for_metrics`: []
|
| 349 |
-
- `eval_do_concat_batches`: True
|
| 350 |
-
- `fp16_backend`: auto
|
| 351 |
-
- `push_to_hub_model_id`: None
|
| 352 |
-
- `push_to_hub_organization`: None
|
| 353 |
-
- `mp_parameters`:
|
| 354 |
-
- `auto_find_batch_size`: False
|
| 355 |
-
- `full_determinism`: False
|
| 356 |
-
- `torchdynamo`: None
|
| 357 |
-
- `ray_scope`: last
|
| 358 |
-
- `ddp_timeout`: 1800
|
| 359 |
-
- `torch_compile`: False
|
| 360 |
-
- `torch_compile_backend`: None
|
| 361 |
-
- `torch_compile_mode`: None
|
| 362 |
-
- `include_tokens_per_second`: False
|
| 363 |
-
- `include_num_input_tokens_seen`: False
|
| 364 |
-
- `neftune_noise_alpha`: None
|
| 365 |
-
- `optim_target_modules`: None
|
| 366 |
-
- `batch_eval_metrics`: False
|
| 367 |
-
- `eval_on_start`: False
|
| 368 |
-
- `use_liger_kernel`: False
|
| 369 |
-
- `eval_use_gather_object`: False
|
| 370 |
-
- `average_tokens_across_devices`: False
|
| 371 |
-
- `prompts`: None
|
| 372 |
-
- `batch_sampler`: batch_sampler
|
| 373 |
-
- `multi_dataset_batch_sampler`: round_robin
|
| 374 |
|
| 375 |
-
|
| 376 |
|
| 377 |
-
|
| 378 |
-
|
| 379 |
-
|
| 380 |
-
|
| 381 |
-
|
| 382 |
-
| 0.0142 | 500 | 1.1661 |
|
| 383 |
-
| 0.0283 | 1000 | 0.1176 |
|
| 384 |
-
| 0.0425 | 1500 | 0.1096 |
|
| 385 |
-
| 0.0567 | 2000 | 0.1013 |
|
| 386 |
-
| 0.0708 | 2500 | 0.0967 |
|
| 387 |
-
| 0.0850 | 3000 | 0.0912 |
|
| 388 |
-
| 0.0992 | 3500 | 0.0886 |
|
| 389 |
-
| 0.1133 | 4000 | 0.0799 |
|
| 390 |
-
| 0.1275 | 4500 | 0.0776 |
|
| 391 |
-
| 0.1417 | 5000 | 0.0757 |
|
| 392 |
-
| 0.1558 | 5500 | 0.0751 |
|
| 393 |
-
| 0.1700 | 6000 | 0.0714 |
|
| 394 |
-
| 0.1842 | 6500 | 0.0703 |
|
| 395 |
-
| 0.1983 | 7000 | 0.0667 |
|
| 396 |
-
| 0.2125 | 7500 | 0.0674 |
|
| 397 |
-
| 0.2267 | 8000 | 0.0625 |
|
| 398 |
-
| 0.2408 | 8500 | 0.0598 |
|
| 399 |
-
| 0.2550 | 9000 | 0.0597 |
|
| 400 |
-
| 0.2692 | 9500 | 0.0585 |
|
| 401 |
-
| 0.2833 | 10000 | 0.0568 |
|
| 402 |
-
| 0.2975 | 10500 | 0.055 |
|
| 403 |
-
| 0.3117 | 11000 | 0.0554 |
|
| 404 |
-
| 0.3258 | 11500 | 0.0529 |
|
| 405 |
-
| 0.3400 | 12000 | 0.0516 |
|
| 406 |
-
| 0.3541 | 12500 | 0.0506 |
|
| 407 |
-
| 0.3683 | 13000 | 0.05 |
|
| 408 |
-
| 0.3825 | 13500 | 0.0484 |
|
| 409 |
-
| 0.3966 | 14000 | 0.0472 |
|
| 410 |
-
| 0.4108 | 14500 | 0.0468 |
|
| 411 |
-
| 0.4250 | 15000 | 0.045 |
|
| 412 |
-
| 0.4391 | 15500 | 0.046 |
|
| 413 |
-
| 0.4533 | 16000 | 0.0452 |
|
| 414 |
-
| 0.4675 | 16500 | 0.0428 |
|
| 415 |
-
| 0.4816 | 17000 | 0.0424 |
|
| 416 |
-
| 0.4958 | 17500 | 0.04 |
|
| 417 |
-
| 0.5100 | 18000 | 0.0402 |
|
| 418 |
-
| 0.5241 | 18500 | 0.0391 |
|
| 419 |
-
| 0.5383 | 19000 | 0.0389 |
|
| 420 |
-
| 0.5525 | 19500 | 0.0385 |
|
| 421 |
-
| 0.5666 | 20000 | 0.0357 |
|
| 422 |
-
| 0.5808 | 20500 | 0.0362 |
|
| 423 |
-
| 0.5950 | 21000 | 0.0369 |
|
| 424 |
-
| 0.6091 | 21500 | 0.0372 |
|
| 425 |
-
| 0.6233 | 22000 | 0.0351 |
|
| 426 |
-
| 0.6375 | 22500 | 0.034 |
|
| 427 |
-
| 0.6516 | 23000 | 0.0364 |
|
| 428 |
-
| 0.6658 | 23500 | 0.033 |
|
| 429 |
-
| 0.6800 | 24000 | 0.0336 |
|
| 430 |
-
| 0.6941 | 24500 | 0.0302 |
|
| 431 |
-
| 0.7083 | 25000 | 0.0309 |
|
| 432 |
-
| 0.7225 | 25500 | 0.0306 |
|
| 433 |
-
| 0.7366 | 26000 | 0.0316 |
|
| 434 |
-
| 0.7508 | 26500 | 0.0306 |
|
| 435 |
-
| 0.7650 | 27000 | 0.0307 |
|
| 436 |
-
| 0.7791 | 27500 | 0.0303 |
|
| 437 |
-
| 0.7933 | 28000 | 0.028 |
|
| 438 |
-
| 0.8075 | 28500 | 0.0289 |
|
| 439 |
-
| 0.8216 | 29000 | 0.0297 |
|
| 440 |
-
| 0.8358 | 29500 | 0.0281 |
|
| 441 |
-
| 0.8500 | 30000 | 0.029 |
|
| 442 |
-
| 0.8641 | 30500 | 0.027 |
|
| 443 |
-
| 0.8783 | 31000 | 0.0282 |
|
| 444 |
-
| 0.8925 | 31500 | 0.0264 |
|
| 445 |
-
| 0.9066 | 32000 | 0.027 |
|
| 446 |
-
| 0.9208 | 32500 | 0.0259 |
|
| 447 |
-
| 0.9350 | 33000 | 0.0272 |
|
| 448 |
-
| 0.9491 | 33500 | 0.0275 |
|
| 449 |
-
| 0.9633 | 34000 | 0.0244 |
|
| 450 |
-
| 0.9774 | 34500 | 0.0254 |
|
| 451 |
-
| 0.9916 | 35000 | 0.0261 |
|
| 452 |
-
| 1.0058 | 35500 | 0.0189 |
|
| 453 |
-
| 1.0199 | 36000 | 0.0118 |
|
| 454 |
-
| 1.0341 | 36500 | 0.012 |
|
| 455 |
-
| 1.0483 | 37000 | 0.0118 |
|
| 456 |
-
| 1.0624 | 37500 | 0.0109 |
|
| 457 |
-
| 1.0766 | 38000 | 0.0123 |
|
| 458 |
-
| 1.0908 | 38500 | 0.0122 |
|
| 459 |
-
| 1.1049 | 39000 | 0.0122 |
|
| 460 |
-
| 1.1191 | 39500 | 0.0123 |
|
| 461 |
-
| 1.1333 | 40000 | 0.0117 |
|
| 462 |
-
| 1.1474 | 40500 | 0.0115 |
|
| 463 |
-
| 1.1616 | 41000 | 0.0122 |
|
| 464 |
-
| 1.1758 | 41500 | 0.0117 |
|
| 465 |
-
| 1.1899 | 42000 | 0.0119 |
|
| 466 |
-
| 1.2041 | 42500 | 0.0112 |
|
| 467 |
-
| 1.2183 | 43000 | 0.0122 |
|
| 468 |
-
| 1.2324 | 43500 | 0.0116 |
|
| 469 |
-
| 1.2466 | 44000 | 0.0107 |
|
| 470 |
-
| 1.2608 | 44500 | 0.0126 |
|
| 471 |
-
| 1.2749 | 45000 | 0.0114 |
|
| 472 |
-
| 1.2891 | 45500 | 0.011 |
|
| 473 |
-
| 1.3033 | 46000 | 0.0116 |
|
| 474 |
-
| 1.3174 | 46500 | 0.0114 |
|
| 475 |
-
| 1.3316 | 47000 | 0.0111 |
|
| 476 |
-
| 1.3458 | 47500 | 0.0112 |
|
| 477 |
-
| 1.3599 | 48000 | 0.0112 |
|
| 478 |
-
| 1.3741 | 48500 | 0.0115 |
|
| 479 |
-
| 1.3883 | 49000 | 0.0104 |
|
| 480 |
-
| 1.4024 | 49500 | 0.0109 |
|
| 481 |
-
| 1.4166 | 50000 | 0.0113 |
|
| 482 |
-
| 1.4308 | 50500 | 0.0115 |
|
| 483 |
-
| 1.4449 | 51000 | 0.0103 |
|
| 484 |
-
| 1.4591 | 51500 | 0.0114 |
|
| 485 |
-
| 1.4733 | 52000 | 0.0104 |
|
| 486 |
-
| 1.4874 | 52500 | 0.0106 |
|
| 487 |
-
| 1.5016 | 53000 | 0.0103 |
|
| 488 |
-
| 1.5158 | 53500 | 0.0102 |
|
| 489 |
-
| 1.5299 | 54000 | 0.0101 |
|
| 490 |
-
| 1.5441 | 54500 | 0.0104 |
|
| 491 |
-
| 1.5583 | 55000 | 0.011 |
|
| 492 |
-
| 1.5724 | 55500 | 0.0107 |
|
| 493 |
-
| 1.5866 | 56000 | 0.0097 |
|
| 494 |
-
| 1.6007 | 56500 | 0.0099 |
|
| 495 |
-
| 1.6149 | 57000 | 0.0102 |
|
| 496 |
-
| 1.6291 | 57500 | 0.0098 |
|
| 497 |
-
| 1.6432 | 58000 | 0.01 |
|
| 498 |
-
| 1.6574 | 58500 | 0.0096 |
|
| 499 |
-
| 1.6716 | 59000 | 0.0099 |
|
| 500 |
-
| 1.6857 | 59500 | 0.0103 |
|
| 501 |
-
| 1.6999 | 60000 | 0.0098 |
|
| 502 |
-
| 1.7141 | 60500 | 0.0097 |
|
| 503 |
-
| 1.7282 | 61000 | 0.0094 |
|
| 504 |
-
| 1.7424 | 61500 | 0.0093 |
|
| 505 |
-
| 1.7566 | 62000 | 0.0102 |
|
| 506 |
-
| 1.7707 | 62500 | 0.0099 |
|
| 507 |
-
| 1.7849 | 63000 | 0.0098 |
|
| 508 |
-
| 1.7991 | 63500 | 0.009 |
|
| 509 |
-
| 1.8132 | 64000 | 0.0097 |
|
| 510 |
-
| 1.8274 | 64500 | 0.009 |
|
| 511 |
-
| 1.8416 | 65000 | 0.0093 |
|
| 512 |
-
| 1.8557 | 65500 | 0.0092 |
|
| 513 |
-
| 1.8699 | 66000 | 0.0095 |
|
| 514 |
-
| 1.8841 | 66500 | 0.0093 |
|
| 515 |
-
| 1.8982 | 67000 | 0.0094 |
|
| 516 |
-
| 1.9124 | 67500 | 0.0089 |
|
| 517 |
-
| 1.9266 | 68000 | 0.0091 |
|
| 518 |
-
| 1.9407 | 68500 | 0.0089 |
|
| 519 |
-
| 1.9549 | 69000 | 0.0084 |
|
| 520 |
-
| 1.9691 | 69500 | 0.0087 |
|
| 521 |
-
| 1.9832 | 70000 | 0.0094 |
|
| 522 |
-
| 1.9974 | 70500 | 0.0085 |
|
| 523 |
-
| 2.0116 | 71000 | 0.0049 |
|
| 524 |
-
| 2.0257 | 71500 | 0.0041 |
|
| 525 |
-
| 2.0399 | 72000 | 0.0039 |
|
| 526 |
-
| 2.0541 | 72500 | 0.0038 |
|
| 527 |
-
| 2.0682 | 73000 | 0.004 |
|
| 528 |
-
| 2.0824 | 73500 | 0.0039 |
|
| 529 |
-
| 2.0966 | 74000 | 0.0038 |
|
| 530 |
-
| 2.1107 | 74500 | 0.0041 |
|
| 531 |
-
| 2.1249 | 75000 | 0.0037 |
|
| 532 |
-
| 2.1391 | 75500 | 0.0038 |
|
| 533 |
-
| 2.1532 | 76000 | 0.0041 |
|
| 534 |
-
| 2.1674 | 76500 | 0.0036 |
|
| 535 |
-
| 2.1816 | 77000 | 0.0039 |
|
| 536 |
-
| 2.1957 | 77500 | 0.0039 |
|
| 537 |
-
| 2.2099 | 78000 | 0.0038 |
|
| 538 |
-
| 2.2240 | 78500 | 0.0038 |
|
| 539 |
-
| 2.2382 | 79000 | 0.0037 |
|
| 540 |
-
| 2.2524 | 79500 | 0.0037 |
|
| 541 |
-
| 2.2665 | 80000 | 0.0036 |
|
| 542 |
-
| 2.2807 | 80500 | 0.0038 |
|
| 543 |
-
| 2.2949 | 81000 | 0.0037 |
|
| 544 |
-
| 2.3090 | 81500 | 0.0036 |
|
| 545 |
-
| 2.3232 | 82000 | 0.0036 |
|
| 546 |
-
| 2.3374 | 82500 | 0.0038 |
|
| 547 |
-
| 2.3515 | 83000 | 0.0037 |
|
| 548 |
-
| 2.3657 | 83500 | 0.0037 |
|
| 549 |
-
| 2.3799 | 84000 | 0.0038 |
|
| 550 |
-
| 2.3940 | 84500 | 0.0037 |
|
| 551 |
-
| 2.4082 | 85000 | 0.0036 |
|
| 552 |
-
| 2.4224 | 85500 | 0.0034 |
|
| 553 |
-
| 2.4365 | 86000 | 0.0035 |
|
| 554 |
-
| 2.4507 | 86500 | 0.0033 |
|
| 555 |
-
| 2.4649 | 87000 | 0.0036 |
|
| 556 |
-
| 2.4790 | 87500 | 0.0035 |
|
| 557 |
-
| 2.4932 | 88000 | 0.0034 |
|
| 558 |
-
| 2.5074 | 88500 | 0.0034 |
|
| 559 |
-
| 2.5215 | 89000 | 0.0034 |
|
| 560 |
-
| 2.5357 | 89500 | 0.0031 |
|
| 561 |
-
| 2.5499 | 90000 | 0.0033 |
|
| 562 |
-
| 2.5640 | 90500 | 0.0033 |
|
| 563 |
-
| 2.5782 | 91000 | 0.0035 |
|
| 564 |
-
| 2.5924 | 91500 | 0.0033 |
|
| 565 |
-
| 2.6065 | 92000 | 0.0032 |
|
| 566 |
-
| 2.6207 | 92500 | 0.0034 |
|
| 567 |
-
| 2.6349 | 93000 | 0.0031 |
|
| 568 |
-
| 2.6490 | 93500 | 0.0032 |
|
| 569 |
-
| 2.6632 | 94000 | 0.0032 |
|
| 570 |
-
| 2.6774 | 94500 | 0.0033 |
|
| 571 |
-
| 2.6915 | 95000 | 0.0032 |
|
| 572 |
-
| 2.7057 | 95500 | 0.003 |
|
| 573 |
-
| 2.7199 | 96000 | 0.0032 |
|
| 574 |
-
| 2.7340 | 96500 | 0.0032 |
|
| 575 |
-
| 2.7482 | 97000 | 0.003 |
|
| 576 |
-
| 2.7624 | 97500 | 0.0032 |
|
| 577 |
-
| 2.7765 | 98000 | 0.0033 |
|
| 578 |
-
| 2.7907 | 98500 | 0.003 |
|
| 579 |
-
| 2.8049 | 99000 | 0.003 |
|
| 580 |
-
| 2.8190 | 99500 | 0.0031 |
|
| 581 |
-
| 2.8332 | 100000 | 0.0031 |
|
| 582 |
-
| 2.8473 | 100500 | 0.003 |
|
| 583 |
-
| 2.8615 | 101000 | 0.003 |
|
| 584 |
-
| 2.8757 | 101500 | 0.003 |
|
| 585 |
-
| 2.8898 | 102000 | 0.003 |
|
| 586 |
-
| 2.9040 | 102500 | 0.003 |
|
| 587 |
-
| 2.9182 | 103000 | 0.003 |
|
| 588 |
-
| 2.9323 | 103500 | 0.003 |
|
| 589 |
-
| 2.9465 | 104000 | 0.0033 |
|
| 590 |
-
| 2.9607 | 104500 | 0.0029 |
|
| 591 |
-
| 2.9748 | 105000 | 0.003 |
|
| 592 |
-
| 2.9890 | 105500 | 0.0028 |
|
| 593 |
|
| 594 |
-
|
|
|
|
| 595 |
|
| 596 |
-
|
| 597 |
-
|
| 598 |
-
- Sentence Transformers: 4.1.0
|
| 599 |
-
- Transformers: 4.52.4
|
| 600 |
-
- PyTorch: 2.6.0+cu124
|
| 601 |
-
- Accelerate: 1.7.0
|
| 602 |
-
- Datasets: 3.6.0
|
| 603 |
-
- Tokenizers: 0.21.1
|
| 604 |
-
|
| 605 |
-
## Citation
|
| 606 |
-
|
| 607 |
-
### BibTeX
|
| 608 |
-
|
| 609 |
-
#### Sentence Transformers
|
| 610 |
-
```bibtex
|
| 611 |
-
@inproceedings{reimers-2019-sentence-bert,
|
| 612 |
-
title = "Sentence-BERT: Sentence Embeddings using Siamese BERT-Networks",
|
| 613 |
-
author = "Reimers, Nils and Gurevych, Iryna",
|
| 614 |
-
booktitle = "Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing",
|
| 615 |
-
month = "11",
|
| 616 |
-
year = "2019",
|
| 617 |
-
publisher = "Association for Computational Linguistics",
|
| 618 |
-
url = "https://arxiv.org/abs/1908.10084",
|
| 619 |
-
}
|
| 620 |
```
|
| 621 |
|
| 622 |
-
|
| 623 |
-
```bibtex
|
| 624 |
-
@misc{henderson2017efficient,
|
| 625 |
-
title={Efficient Natural Language Response Suggestion for Smart Reply},
|
| 626 |
-
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},
|
| 627 |
-
year={2017},
|
| 628 |
-
eprint={1705.00652},
|
| 629 |
-
archivePrefix={arXiv},
|
| 630 |
-
primaryClass={cs.CL}
|
| 631 |
-
}
|
| 632 |
-
```
|
| 633 |
|
| 634 |
-
|
| 635 |
-
## Glossary
|
| 636 |
|
| 637 |
-
*
|
| 638 |
-
|
| 639 |
|
| 640 |
-
|
| 641 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 642 |
|
| 643 |
-
|
| 644 |
-
-->
|
| 645 |
|
| 646 |
-
|
| 647 |
-
## Model Card Contact
|
| 648 |
|
| 649 |
-
|
| 650 |
-
-->
|
|
|
|
| 8 |
- loss:MultipleNegativesRankingLoss
|
| 9 |
base_model: Shuu12121/CodeModernBERT-Owl-3.0
|
| 10 |
widget:
|
| 11 |
+
- source_sentence: >-
|
| 12 |
+
The maximum value of the slider. (default 0) <P>
|
| 13 |
|
| 14 |
+
@return Returns the value of the attribute, or 0, if it hasn't been set by
|
| 15 |
+
the JSF file.
|
| 16 |
sentences:
|
| 17 |
+
- |-
|
| 18 |
+
@Override
|
| 19 |
+
public UpdateSmsChannelResult updateSmsChannel(UpdateSmsChannelRequest request) {
|
| 20 |
+
request = beforeClientExecution(request);
|
| 21 |
+
return executeUpdateSmsChannel(request);
|
| 22 |
+
}
|
| 23 |
+
- |-
|
| 24 |
+
async function isValidOrigin(origin, sourceOrigin) {
|
| 25 |
+
// This will fetch the caches from https://cdn.ampproject.org/caches.json the first time it's
|
| 26 |
+
// called. Subsequent calls will receive a cached version.
|
| 27 |
+
const officialCacheList = await caches.list();
|
| 28 |
+
// Calculate the cache specific origin
|
| 29 |
+
const cacheSubdomain = `https://${await createCacheSubdomain(sourceOrigin)}.`;
|
| 30 |
+
// Check all caches listed on ampproject.org
|
| 31 |
+
for (const cache of officialCacheList) {
|
| 32 |
+
const cachedOrigin = cacheSubdomain + cache.cacheDomain;
|
| 33 |
+
if (origin === cachedOrigin) {
|
| 34 |
+
return true;
|
| 35 |
+
}
|
| 36 |
+
}
|
| 37 |
+
return false;
|
| 38 |
+
}
|
| 39 |
+
- "public java.lang.Object getMin() {\n\t\treturn (java.lang.Object) getStateHelper().eval(PropertyKeys.min, 0);\n\t}"
|
| 40 |
+
- source_sentence: |-
|
| 41 |
+
The Method from the Date.getMinutes is deprecated. This is a helper-Method.
|
| 42 |
|
| 43 |
@param date
|
|
|
|
| 44 |
The Date-object to get the minutes.
|
| 45 |
+
@return The minutes from the Date-object.
|
|
|
|
| 46 |
sentences:
|
| 47 |
+
- "public static int getMinutes(final Date date)\n\t{\n\t\tfinal Calendar calendar = Calendar.getInstance();\n\t\tcalendar.setTime(date);\n\t\treturn calendar.get(Calendar.MINUTE);\n\t}"
|
| 48 |
+
- "func (opts BeeOptions) Bind(name string, dst interface{}) error {\n\tv := opts.Value(name)\n\tif v == nil {\n\t\treturn errors.New(\"Option with name \" + name + \" not found\")\n\t}\n\n\treturn ConvertValue(v, dst)\n}"
|
| 49 |
+
- >-
|
| 50 |
+
public function createFor(Customer $customer, array $options = [], array
|
| 51 |
+
$filters = [])
|
| 52 |
+
{
|
| 53 |
+
$this->parentId = $customer->id;
|
| 54 |
+
|
| 55 |
+
return parent::rest_create($options, $filters);
|
| 56 |
+
}
|
| 57 |
+
- source_sentence: |-
|
| 58 |
+
Return a list of all dates from 11/12/2015 to the present.
|
| 59 |
+
|
| 60 |
+
Args:
|
| 61 |
+
boo: if true, list contains Numbers (20151230); if false, list contains Strings ("2015-12-30")
|
| 62 |
+
Returns:
|
| 63 |
+
list of either Numbers or Strings
|
| 64 |
sentences:
|
| 65 |
+
- |-
|
| 66 |
+
def all_days(boo):
|
| 67 |
+
|
| 68 |
+
earliest = datetime.strptime(('2015-11-12').replace('-', ' '), '%Y %m %d')
|
| 69 |
+
latest = datetime.strptime(datetime.today().date().isoformat().replace('-', ' '), '%Y %m %d')
|
| 70 |
+
num_days = (latest - earliest).days + 1
|
| 71 |
+
all_days = [latest - timedelta(days=x) for x in range(num_days)]
|
| 72 |
+
all_days.reverse()
|
| 73 |
+
|
| 74 |
+
output = []
|
| 75 |
+
|
| 76 |
+
if boo:
|
| 77 |
+
# Return as Integer, yyyymmdd
|
| 78 |
+
for d in all_days:
|
| 79 |
+
output.append(int(str(d).replace('-', '')[:8]))
|
| 80 |
+
else:
|
| 81 |
+
# Return as String, yyyy-mm-dd
|
| 82 |
+
for d in all_days:
|
| 83 |
+
output.append(str(d)[:10])
|
| 84 |
+
return output
|
| 85 |
+
- "public void setColSize3(Integer newColSize3) {\n\t\tInteger oldColSize3 = colSize3;\n\t\tcolSize3 = newColSize3;\n\t\tif (eNotificationRequired())\n\t\t\teNotify(new ENotificationImpl(this, Notification.SET, AfplibPackage.COLOR_SPECIFICATION__COL_SIZE3, oldColSize3, colSize3));\n\t}"
|
| 86 |
+
- >-
|
| 87 |
+
public function
|
| 88 |
+
deleteCompanyBusinessUnitStoreAddress(CompanyBusinessUnitStoreAddressTransfer
|
| 89 |
+
$companyBusinessUnitStoreAddressTransfer): void
|
| 90 |
+
{
|
| 91 |
+
$this->getFactory()
|
| 92 |
+
->createFosCompanyBusinessUnitStoreAddressQuery()
|
| 93 |
+
->findOneByIdCompanyBusinessUnitStoreAddress($companyBusinessUnitStoreAddressTransfer->getIdCompanyBusinessUnitStoreAddress())
|
| 94 |
+
->delete();
|
| 95 |
+
}
|
| 96 |
+
- source_sentence: |-
|
| 97 |
+
Returns array of basket oxarticle objects
|
| 98 |
+
|
| 99 |
+
@return array
|
| 100 |
sentences:
|
| 101 |
+
- |-
|
| 102 |
+
public function visit(NodeVisitorInterface $visitor)
|
| 103 |
+
{
|
| 104 |
+
foreach ($this->children as $child)
|
| 105 |
+
{
|
| 106 |
+
$child->visit($visitor);
|
| 107 |
+
}
|
| 108 |
+
}
|
| 109 |
+
- "func GetColDefaultValue(ctx sessionctx.Context, col *model.ColumnInfo) (types.Datum, error) {\n\treturn getColDefaultValue(ctx, col, col.GetDefaultValue())\n}"
|
| 110 |
+
- |-
|
| 111 |
+
public function getBasketArticles()
|
| 112 |
+
{
|
| 113 |
+
$aBasketArticles = [];
|
| 114 |
+
/** @var \oxBasketItem $oBasketItem */
|
| 115 |
+
foreach ($this->_aBasketContents as $sItemKey => $oBasketItem) {
|
| 116 |
+
try {
|
| 117 |
+
$oProduct = $oBasketItem->getArticle(true);
|
| 118 |
+
|
| 119 |
+
if (\OxidEsales\Eshop\Core\Registry::getConfig()->getConfigParam('bl_perfLoadSelectLists')) {
|
| 120 |
+
// marking chosen select list
|
| 121 |
+
$aSelList = $oBasketItem->getSelList();
|
| 122 |
+
if (is_array($aSelList) && ($aSelectlist = $oProduct->getSelectLists($sItemKey))) {
|
| 123 |
+
reset($aSelList);
|
| 124 |
+
foreach ($aSelList as $conkey => $iSel) {
|
| 125 |
+
$aSelectlist[$conkey][$iSel]->selected = 1;
|
| 126 |
+
}
|
| 127 |
+
$oProduct->setSelectlist($aSelectlist);
|
| 128 |
+
}
|
| 129 |
+
}
|
| 130 |
+
} catch (\OxidEsales\Eshop\Core\Exception\NoArticleException $oEx) {
|
| 131 |
+
\OxidEsales\Eshop\Core\Registry::getUtilsView()->addErrorToDisplay($oEx);
|
| 132 |
+
$this->removeItem($sItemKey);
|
| 133 |
+
$this->calculateBasket(true);
|
| 134 |
+
continue;
|
| 135 |
+
} catch (\OxidEsales\Eshop\Core\Exception\ArticleInputException $oEx) {
|
| 136 |
+
\OxidEsales\Eshop\Core\Registry::getUtilsView()->addErrorToDisplay($oEx);
|
| 137 |
+
$this->removeItem($sItemKey);
|
| 138 |
+
$this->calculateBasket(true);
|
| 139 |
+
continue;
|
| 140 |
+
}
|
| 141 |
+
|
| 142 |
+
$aBasketArticles[$sItemKey] = $oProduct;
|
| 143 |
+
}
|
| 144 |
+
|
| 145 |
+
return $aBasketArticles;
|
| 146 |
+
}
|
| 147 |
- source_sentence: get test root
|
| 148 |
sentences:
|
| 149 |
+
- |-
|
| 150 |
+
@CheckReturnValue
|
| 151 |
+
@SchedulerSupport(SchedulerSupport.NONE)
|
| 152 |
+
public final Maybe<T> doOnDispose(Action onDispose) {
|
| 153 |
+
return RxJavaPlugins.onAssembly(new MaybePeek<T>(this,
|
| 154 |
+
Functions.emptyConsumer(), // onSubscribe
|
| 155 |
+
Functions.emptyConsumer(), // onSuccess
|
| 156 |
+
Functions.emptyConsumer(), // onError
|
| 157 |
+
Functions.EMPTY_ACTION, // onComplete
|
| 158 |
+
Functions.EMPTY_ACTION, // (onSuccess | onError | onComplete) after
|
| 159 |
+
ObjectHelper.requireNonNull(onDispose, "onDispose is null")
|
| 160 |
+
));
|
| 161 |
+
}
|
| 162 |
+
- >-
|
| 163 |
+
protected Object parseKeyElement(Element keyEle, BeanDefinition bd, String
|
| 164 |
+
defaultKeyTypeName) {
|
| 165 |
+
NodeList nl = keyEle.getChildNodes();
|
| 166 |
+
Element subElement = null;
|
| 167 |
+
for (int i = 0; i < nl.getLength(); i++) {
|
| 168 |
+
Node node = nl.item(i);
|
| 169 |
+
if (node instanceof Element) {
|
| 170 |
+
// Child element is what we're looking for.
|
| 171 |
+
if (subElement != null)
|
| 172 |
+
error("<key> element must not contain more than one value sub-element", keyEle);
|
| 173 |
+
else subElement = (Element) node;
|
| 174 |
+
}
|
| 175 |
+
}
|
| 176 |
+
return parsePropertySubElement(subElement, bd, defaultKeyTypeName);
|
| 177 |
+
}
|
| 178 |
+
- |-
|
| 179 |
+
function getRootPath(){
|
| 180 |
+
var rootPath = path.resolve('.');
|
| 181 |
+
while(rootPath){
|
| 182 |
+
if(fs.existsSync(rootPath + '/config.json')){
|
| 183 |
+
break;
|
| 184 |
+
}
|
| 185 |
+
rootPath = rootPath.substring(0, rootPath.lastIndexOf(path.sep));
|
| 186 |
+
}
|
| 187 |
+
return rootPath;
|
| 188 |
+
}
|
| 189 |
pipeline_tag: sentence-similarity
|
| 190 |
library_name: sentence-transformers
|
| 191 |
+
datasets:
|
| 192 |
+
- code-search-net/code_search_net
|
| 193 |
+
- Shuu12121/python-codesearch-dedupe-filtered-v4
|
| 194 |
+
- Shuu12121/javascript-codesearch-dedupe-filtered-v4
|
| 195 |
+
- Shuu12121/java-codesearch-dedupe-filtered-v4
|
| 196 |
+
- Shuu12121/typescript-codesearch-dedupe-filtered-v4
|
| 197 |
+
- Shuu12121/php-codesearch-dedupe-filtered-v4
|
| 198 |
+
- Shuu12121/go-codesearch-dedupe-filtered-v4
|
| 199 |
+
- Shuu12121/ruby-codesearch-dedupe-filtered-v4
|
| 200 |
+
- Shuu12121/rust-codesearch-dedupe-filtered-v4
|
| 201 |
+
license: apache-2.0
|
| 202 |
+
language:
|
| 203 |
+
- en
|
| 204 |
---
|
| 205 |
|
| 206 |
+
# 🦉 CodeModernBERT‑Owl 3.0 SentenceTransformer
|
|
|
|
|
|
|
| 207 |
|
| 208 |
+
多言語・長文コードを対象としたエンコーダ **CodeModernBERT‑Owl 3.0** をベースに Sentence Transformer(STS)形式で微調整したモデルです。1024 token までのソースコード/自然言語を 768 次元の密ベクトルに写像し、コード検索・類似度計算・クラスタリングなど幅広い下流タスクに活用できます。
|
| 209 |
|
| 210 |
+
> A multilingual, long‑context SentenceTransformer fine‑tuned from **CodeModernBERT‑Owl 3.0**. It encodes code and natural‑language snippets (≤ 1024 tokens) into 768‑dimensional vectors for semantic search, similarity, clustering, and more.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 211 |
|
| 212 |
+
---
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 213 |
|
| 214 |
+
## 🔥 ハイライト / Highlights
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 215 |
|
| 216 |
+
| ⚙️ 仕様 | 値 |
|
| 217 |
+
| ------------ | ------------------------------------------------------------------------------------------- |
|
| 218 |
+
| **最大シーケンス長** | 1024 tokens |
|
| 219 |
+
| **埋め込み次元** | 768 d │ Cosine Similarity |
|
| 220 |
+
| **プーリング** | CLS トークン(`pooling_mode_cls_token = True`) |
|
| 221 |
+
| **学習データ** | 7,059,200 正例ペア(CodeSearchNet + 自作データセット) |
|
| 222 |
+
| **ロス関数** | MultipleNegativesRankingLoss (`scale = 20.0`) |
|
| 223 |
+
| **学習エポック** | 3 epochs (@ batch size 200, fp16) |
|
| 224 |
+
| **基盤モデル** | [Shuu12121/CodeModernBERT‑Owl 3.0](https://huggingface.co/Shuu12121/CodeModernBERT-Owl-3.0) |
|
| 225 |
|
| 226 |
+
---
|
| 227 |
|
| 228 |
+
## 📊 評価結果 / Evaluation
|
| 229 |
|
| 230 |
+
### MTEB CodeSearchNet (CSN) ―
|
|
|
|
|
|
|
| 231 |
|
| 232 |
+
| Metric | COIR Version | CSN |
|
| 233 |
+
| ------------------------- | :---------: | :--------: |
|
| 234 |
+
| **Main Score (NDCG\@10)** | **0.8023** | **0.8928** |
|
| 235 |
+
| NDCG\@1 | 0.7175 | 0.8125 |
|
| 236 |
+
| NDCG\@3 | 0.7795 | 0.8798 |
|
| 237 |
+
| NDCG\@5 | 0.7917 | 0.8879 |
|
| 238 |
+
| NDCG\@20 | 0.8085 | 0.8950 |
|
| 239 |
+
| MAP\@10 | 0.7759 | 0.8707 |
|
| 240 |
+
| Recall\@10 | 0.8839 | 0.9593 |
|
| 241 |
+
| MRR\@10 | 0.7759 | 0.8707 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 242 |
|
|
|
|
|
|
|
|
|
|
|
|
|
| 243 |
|
| 244 |
</details>
|
|
|
|
| 245 |
|
| 246 |
+
どちらも公式スコアに提出しているCodeSearch-ModernBERT-Crow-Plusと同等以上の成績を残しています.
|
|
|
|
| 247 |
|
| 248 |
+
---
|
| 249 |
|
| 250 |
+
## 🚀 使い方 / Quick Start
|
| 251 |
|
| 252 |
+
```python
|
| 253 |
+
from sentence_transformers import SentenceTransformer, util
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 254 |
|
| 255 |
+
model = SentenceTransformer("Shuu12121/CodeModernBERT-Owl-3.0-ST")
|
| 256 |
|
| 257 |
+
queries = ["get test root"]
|
| 258 |
+
docs = [
|
| 259 |
+
"function getRootPath(){ … }",
|
| 260 |
+
"protected Object parseKeyElement(Element keyEle, …)",
|
| 261 |
+
]
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 262 |
|
| 263 |
+
q_emb = model.encode(queries, normalize_embeddings=True)
|
| 264 |
+
d_emb = model.encode(docs, normalize_embeddings=True)
|
| 265 |
|
| 266 |
+
scores = util.cos_sim(q_emb, d_emb)
|
| 267 |
+
print(scores)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 268 |
```
|
| 269 |
|
| 270 |
+
---
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 271 |
|
| 272 |
+
## 🛠️ ファインチューニング / Fine‑tuning
|
|
|
|
| 273 |
|
| 274 |
+
* **ロス関数**: `MultipleNegativesRankingLoss` はミニバッチ内のネガティブを暗黙的に構成するため大規模ペア生成が不要。
|
| 275 |
+
* **ハイパーパラメータ** (主要):
|
| 276 |
|
| 277 |
+
```yaml
|
| 278 |
+
learning_rate: 5e‑5
|
| 279 |
+
per_device_train_batch_size: 200
|
| 280 |
+
fp16: true
|
| 281 |
+
warmup_ratio: 0.0
|
| 282 |
+
max_grad_norm: 1.0
|
| 283 |
+
```
|
| 284 |
|
| 285 |
+
---
|
|
|
|
| 286 |
|
| 287 |
+
## ⚖️ ライセンス / License
|
|
|
|
| 288 |
|
| 289 |
+
Apache 2.0
|
|
|