--- base_model: bobox/DeBERTa-small-ST-v1-test-step3 datasets: [] language: [] library_name: sentence-transformers metrics: - pearson_cosine - spearman_cosine - pearson_manhattan - spearman_manhattan - pearson_euclidean - spearman_euclidean - pearson_dot - spearman_dot - pearson_max - spearman_max pipeline_tag: sentence-similarity tags: - sentence-transformers - sentence-similarity - feature-extraction - generated_from_trainer - dataset_size:120849 - loss:CachedGISTEmbedLoss widget: - source_sentence: '"Today I lost those who for 24 years I called...my family," said Enes Kanter of the Oklahoma City Thunder. Turkish President Recep Tayyip Erdogan blames Mr Gulen for inciting a failed coup last month and is seeking the cleric''s extradition to Turkey. Mr Gulen, who has a large following, denies being involved in the coup. Kanter''s father, Mehmet, disowned his son in a letter published on Monday by Sabah, a pro-government newspaper. Mehmet Kanter wrote his son had been "hypnotised" by the Gulen movement. "With a feeling of shame I apologise to our president and the Turkish people for having such a son," the letter said. Q&A on the Gulen movement Mr Gulen is regarded by followers as a spiritual leader and sometimes described as Turkey''s second most powerful man. Enes Kanter has been a vocal supporter of Mr Gulen on Twitter. The movement - known in Turkey as Hizmet, or service - runs schools all over Turkey and around the world, including in Turkic former Soviet republics, Muslim countries such as Pakistan and Western nations including Romania and the US, where it runs more than 100 schools. In May 2016, the Turkish government formally declared the Gulen movement a terrorist organisation. After the failed coup, suspected Gulen supporters in Turkey were purged in a wave of arrests. Western nations have been critical of the government''s response to the coup. US officials have said they will extradite Mr Gulen only if Turkey provides evidence.' sentences: - 'The Thinker | Rodin Museum H. 189 cm ; W. 98 cm ; D. 140 cm S.2838 When conceived in 1880 in its original size (approx. 70 cm) as the crowning element of The Gates of Hell , seated on the tympanum , The Thinker was entitled The Poet. He represented Dante, author of the Divine Comedy which had inspired The Gates, leaning forward to observe the circles of Hell, while meditating on his work. The Thinker was therefore initially both a being with a tortured body, almost a damned soul, and a free-thinking man, determined to transcend his suffering through poetry. The pose of this figure owes much to Carpeaux’s Ugolino (1861) and to the seated portrait of Lorenzo de’ Medici carved by Michelangelo (1526-31).   While remaining in place on the monumental Gates of Hell, The Thinker was exhibited individually in 1888 and thus became an independent work. Enlarged in 1904, its colossal version proved even more popular: this image of a man lost in thought, but whose powerful body suggests a great capacity for action, has became one of the most celebrated sculptures ever known. Numerous casts exist worldwide, including the one now in the gardens of the Musée Rodin, a gift to the City of Paris installed outside the Panthéon in 1906, and another in the gardens of Rodin’s house in Meudon, on the tomb of the sculptor and his wife. George Bernard Shaw in the Pose of "The Thinker" Rodin, the Monument to Victor Hugo and The Thinker Rodin''s "Thinker" in Dr Linde''s Garden in Lübeck' - An American basketball player has cut ties with his Turkish family over his support for Pennsylvania-based preacher Fethullah Gulen. - Police are investigating a death at a bus stop in Fife. - source_sentence: Two adorable birds perched on a piece of bamboo. sentences: - Two birds are sitting perched on a tree limb - A young boy with a spoon looking at a birthday cupcake. - As part of his attempt to turn the Austrian right , Dessaix ordered a battalion to move along the Aire stream near Tairier and Crache . - source_sentence: how do venom snake keepers make money? sentences: - "The USDA regulates who can buy and sell snake venom. It is very important to\ \ learn about these regulations so that you can operate properly. On average,\ \ snake milkers make around $2,500 per month, but snake venom is an expensive\ \ market. One gram of certain types of snake venom can sell for $2,000.If you\ \ are crazy enough to capture, milk, and breed snakes, please take the precaution\ \ to wear protective clothing and always have antivenom close at hand.nake milkers\ \ have an insane job. They â\x80\x9Cmilkâ\x80\x9D snakes for their venom. This\ \ means that every single day, a snake milker handles deadly, venomous snakes.\ \ Itâ\x80\x99s a hands on job where you put your fingers millimeters away from\ \ the sharp, fangs of asps, vipers, cobras, corals, mambas, kraits, and rattlesnakes." - a greenhouse is used to protect plants by keeping them warm - Nashville Mayor Megan Barry has said her 22-year-old son died of what appeared to be a drug overdose, according to a family statement. - source_sentence: Adult bees include workers, a queen and what other type? sentences: - "matter vibrating can cause sound. Thus, sound is a wave in air . \n matter vibrating\ \ can cause a wave in air" - His references in electronic music are Todd Terry , Armand Van Helden , Roger Sanchez , Tiesto and the Epic Sax Guy. - 'Look at the honeybees in Figure below . Honeybees live in colonies that may consist of thousands of individual bees. Generally, there are three types of adult bees in a colony: workers, a queen, and drones.' - source_sentence: can an object have constant non zero velocity and changing acceleration? sentences: - when an animal sheds its fur , its fur becomes less dense - Acceleration is defined as the time derivative of the velocity; if the velocity is unchanging the acceleration is zero. Velocity is a vector, speed is a scalar magnitude of the vector. If the velocity vector changes direction you can have constant speed (not velocity) with a non-zero acceleration. - Acne treatment is individual and customized to the type of acne you have. On average, mild acne responds in 1-2 months, moderate acne responds in 2-4 months and severe acne can take 4-6 months to clear, granted that the most effective measures can be used. model-index: - name: SentenceTransformer based on bobox/DeBERTa-small-ST-v1-test-step3 results: - task: type: semantic-similarity name: Semantic Similarity dataset: name: sts test type: sts-test metrics: - type: pearson_cosine value: 0.8832622086480311 name: Pearson Cosine - type: spearman_cosine value: 0.9087605087305455 name: Spearman Cosine - type: pearson_manhattan value: 0.9115546986654615 name: Pearson Manhattan - type: spearman_manhattan value: 0.9084107328715103 name: Spearman Manhattan - type: pearson_euclidean value: 0.9107566690862425 name: Pearson Euclidean - type: spearman_euclidean value: 0.9073999361304628 name: Spearman Euclidean - type: pearson_dot value: 0.8697582354953435 name: Pearson Dot - type: spearman_dot value: 0.8760767382321666 name: Spearman Dot - type: pearson_max value: 0.9115546986654615 name: Pearson Max - type: spearman_max value: 0.9087605087305455 name: Spearman Max --- # SentenceTransformer based on bobox/DeBERTa-small-ST-v1-test-step3 This is a [sentence-transformers](https://www.SBERT.net) model finetuned from [bobox/DeBERTa-small-ST-v1-test-step3](https://huggingface.co/bobox/DeBERTa-small-ST-v1-test-step3) on the bobox/enhanced_nli-50_k dataset. 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. ## Model Details ### Model Description - **Model Type:** Sentence Transformer - **Base model:** [bobox/DeBERTa-small-ST-v1-test-step3](https://huggingface.co/bobox/DeBERTa-small-ST-v1-test-step3) - **Maximum Sequence Length:** 512 tokens - **Output Dimensionality:** 768 tokens - **Similarity Function:** Cosine Similarity - **Training Dataset:** - bobox/enhanced_nli-50_k ### Model Sources - **Documentation:** [Sentence Transformers Documentation](https://sbert.net) - **Repository:** [Sentence Transformers on GitHub](https://github.com/UKPLab/sentence-transformers) - **Hugging Face:** [Sentence Transformers on Hugging Face](https://huggingface.co/models?library=sentence-transformers) ### Full Model Architecture ``` SentenceTransformer( (0): Transformer({'max_seq_length': 512, 'do_lower_case': False}) with Transformer model: DebertaV2Model (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}) ) ``` ## Usage ### Direct Usage (Sentence Transformers) First install the Sentence Transformers library: ```bash pip install -U sentence-transformers ``` Then you can load this model and run inference. ```python from sentence_transformers import SentenceTransformer # Download from the 🤗 Hub model = SentenceTransformer("bobox/DeBERTa-small-ST-v1-test-UnifiedDatasets-checkpoints-tmp") # Run inference sentences = [ 'can an object have constant non zero velocity and changing acceleration?', 'Acceleration is defined as the time derivative of the velocity; if the velocity is unchanging the acceleration is zero. Velocity is a vector, speed is a scalar magnitude of the vector. If the velocity vector changes direction you can have constant speed (not velocity) with a non-zero acceleration.', 'Acne treatment is individual and customized to the type of acne you have. On average, mild acne responds in 1-2 months, moderate acne responds in 2-4 months and severe acne can take 4-6 months to clear, granted that the most effective measures can be used.', ] embeddings = model.encode(sentences) print(embeddings.shape) # [3, 768] # Get the similarity scores for the embeddings similarities = model.similarity(embeddings, embeddings) print(similarities.shape) # [3, 3] ``` ## Evaluation ### Metrics #### Semantic Similarity * Dataset: `sts-test` * Evaluated with [EmbeddingSimilarityEvaluator](https://sbert.net/docs/package_reference/sentence_transformer/evaluation.html#sentence_transformers.evaluation.EmbeddingSimilarityEvaluator) | Metric | Value | |:--------------------|:-----------| | pearson_cosine | 0.8833 | | **spearman_cosine** | **0.9088** | | pearson_manhattan | 0.9116 | | spearman_manhattan | 0.9084 | | pearson_euclidean | 0.9108 | | spearman_euclidean | 0.9074 | | pearson_dot | 0.8698 | | spearman_dot | 0.8761 | | pearson_max | 0.9116 | | spearman_max | 0.9088 | ## Training Details ### Training Dataset #### bobox/enhanced_nli-50_k * Dataset: bobox/enhanced_nli-50_k * Size: 120,849 training samples * Columns: sentence1 and sentence2 * Approximate statistics based on the first 1000 samples: | | sentence1 | sentence2 | |:--------|:-----------------------------------------------------------------------------------|:-----------------------------------------------------------------------------------| | type | string | string | | details | | | * Samples: | sentence1 | sentence2 | |:---------------------------------------------------------------------------------|:-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| | A lady working in a kitchen with several different types of dishes. | A woman is cooking and cleaning in her kitchen. | | can you renew your licence online sa? | You can renew your licence online for as long as your photo is valid. Renew your driver's licence online with a mySA GOV account. With a mySA GOV account, you can access a legally compliant digital licence through the mySA GOV app. | | how can coconut oil lower cholesterol | It has been shown that lauric acid increases the good HDL cholesterol in the blood to help improve cholesterol ratio levels. Coconut oil lowers cholesterol by promoting its conversion to pregnenolone, a molecule that is a precursor to many of the hormones our bodies need. Coconut can help restore normal thyroid function. When the thyroid does not function optimally, it can contribute to higher levels of bad cholesterol. | * Loss: [CachedGISTEmbedLoss](https://sbert.net/docs/package_reference/sentence_transformer/losses.html#cachedgistembedloss) with these parameters: ```json {'guide': SentenceTransformer( (0): Transformer({'max_seq_length': 512, 'do_lower_case': False}) with Transformer model: BertModel (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}) (2): Normalize() ), 'temperature': 0.025} ``` ### Evaluation Dataset #### bobox/enhanced_nli-50_k * Dataset: bobox/enhanced_nli-50_k * Size: 3,052 evaluation samples * Columns: sentence1 and sentence2 * Approximate statistics based on the first 1000 samples: | | sentence1 | sentence2 | |:--------|:-----------------------------------------------------------------------------------|:----------------------------------------------------------------------------------| | type | string | string | | details | | | * Samples: | sentence1 | sentence2 | |:----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|:---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| | The body was found in the River Avon in Bath, Avon and Somerset Police said.
Officers said although formal identification had not yet taken place, Henry Burke's family had been told.
Earlier officers said they were looking for Mr Burke, who was last seen leaving a nightclub in George Street late on Thursday.
A force spokesman said the death was being treated as unexplained and inquiries were continuing.
Mr Burke's girlfriend, Em Comley, earlier said he had been texting her "throughout the night" but then the messages suddenly stopped just after midnight.
| A man's body has been found in a river after search and rescue teams were called in to try and find a missing 19-year-old student. | | what happens when the president of united states is impeached? | Parliament votes on the proposal by secret ballot, and if two thirds of all representatives agree, the president is impeached. Once impeached, the president's powers are suspended, and the Constitutional Court decides whether or not the President should be removed from office. | | What can feed at more than one trophic level? | Many consumers feed at more than one trophic level.. Nuts are also consumed by deer, turkey, foxes, wood ducks and squirrels.
wood ducks can feed at more than one trophic level
| * Loss: [CachedGISTEmbedLoss](https://sbert.net/docs/package_reference/sentence_transformer/losses.html#cachedgistembedloss) with these parameters: ```json {'guide': SentenceTransformer( (0): Transformer({'max_seq_length': 512, 'do_lower_case': False}) with Transformer model: BertModel (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}) (2): Normalize() ), 'temperature': 0.025} ``` ### Training Hyperparameters #### Non-Default Hyperparameters - `eval_strategy`: steps - `per_device_train_batch_size`: 960 - `per_device_eval_batch_size`: 128 - `learning_rate`: 3.5e-05 - `weight_decay`: 0.0001 - `num_train_epochs`: 2 - `lr_scheduler_type`: cosine_with_min_lr - `lr_scheduler_kwargs`: {'num_cycles': 0.5, 'min_lr': 5.833333333333333e-06} - `warmup_ratio`: 0.25 - `save_safetensors`: False - `fp16`: True - `push_to_hub`: True - `hub_model_id`: bobox/DeBERTa-small-ST-v1-test-UnifiedDatasets-checkpoints-tmp - `hub_strategy`: all_checkpoints - `batch_sampler`: no_duplicates #### All Hyperparameters
Click to expand - `overwrite_output_dir`: False - `do_predict`: False - `eval_strategy`: steps - `prediction_loss_only`: True - `per_device_train_batch_size`: 960 - `per_device_eval_batch_size`: 128 - `per_gpu_train_batch_size`: None - `per_gpu_eval_batch_size`: None - `gradient_accumulation_steps`: 1 - `eval_accumulation_steps`: None - `torch_empty_cache_steps`: None - `learning_rate`: 3.5e-05 - `weight_decay`: 0.0001 - `adam_beta1`: 0.9 - `adam_beta2`: 0.999 - `adam_epsilon`: 1e-08 - `max_grad_norm`: 1.0 - `num_train_epochs`: 2 - `max_steps`: -1 - `lr_scheduler_type`: cosine_with_min_lr - `lr_scheduler_kwargs`: {'num_cycles': 0.5, 'min_lr': 5.833333333333333e-06} - `warmup_ratio`: 0.25 - `warmup_steps`: 0 - `log_level`: passive - `log_level_replica`: warning - `log_on_each_node`: True - `logging_nan_inf_filter`: True - `save_safetensors`: False - `save_on_each_node`: False - `save_only_model`: False - `restore_callback_states_from_checkpoint`: False - `no_cuda`: False - `use_cpu`: False - `use_mps_device`: False - `seed`: 42 - `data_seed`: None - `jit_mode_eval`: False - `use_ipex`: False - `bf16`: False - `fp16`: True - `fp16_opt_level`: O1 - `half_precision_backend`: auto - `bf16_full_eval`: False - `fp16_full_eval`: False - `tf32`: None - `local_rank`: 0 - `ddp_backend`: None - `tpu_num_cores`: None - `tpu_metrics_debug`: False - `debug`: [] - `dataloader_drop_last`: False - `dataloader_num_workers`: 0 - `dataloader_prefetch_factor`: None - `past_index`: -1 - `disable_tqdm`: False - `remove_unused_columns`: True - `label_names`: None - `load_best_model_at_end`: False - `ignore_data_skip`: False - `fsdp`: [] - `fsdp_min_num_params`: 0 - `fsdp_config`: {'min_num_params': 0, 'xla': False, 'xla_fsdp_v2': False, 'xla_fsdp_grad_ckpt': False} - `fsdp_transformer_layer_cls_to_wrap`: None - `accelerator_config`: {'split_batches': False, 'dispatch_batches': None, 'even_batches': True, 'use_seedable_sampler': True, 'non_blocking': False, 'gradient_accumulation_kwargs': None} - `deepspeed`: None - `label_smoothing_factor`: 0.0 - `optim`: adamw_torch - `optim_args`: None - `adafactor`: False - `group_by_length`: False - `length_column_name`: length - `ddp_find_unused_parameters`: None - `ddp_bucket_cap_mb`: None - `ddp_broadcast_buffers`: False - `dataloader_pin_memory`: True - `dataloader_persistent_workers`: False - `skip_memory_metrics`: True - `use_legacy_prediction_loop`: False - `push_to_hub`: True - `resume_from_checkpoint`: None - `hub_model_id`: bobox/DeBERTa-small-ST-v1-test-UnifiedDatasets-checkpoints-tmp - `hub_strategy`: all_checkpoints - `hub_private_repo`: False - `hub_always_push`: False - `gradient_checkpointing`: False - `gradient_checkpointing_kwargs`: None - `include_inputs_for_metrics`: False - `eval_do_concat_batches`: True - `fp16_backend`: auto - `push_to_hub_model_id`: None - `push_to_hub_organization`: None - `mp_parameters`: - `auto_find_batch_size`: False - `full_determinism`: False - `torchdynamo`: None - `ray_scope`: last - `ddp_timeout`: 1800 - `torch_compile`: False - `torch_compile_backend`: None - `torch_compile_mode`: None - `dispatch_batches`: None - `split_batches`: None - `include_tokens_per_second`: False - `include_num_input_tokens_seen`: False - `neftune_noise_alpha`: None - `optim_target_modules`: None - `batch_eval_metrics`: False - `eval_on_start`: False - `eval_use_gather_object`: False - `batch_sampler`: no_duplicates - `multi_dataset_batch_sampler`: proportional
### Training Logs | Epoch | Step | Training Loss | loss | sts-test_spearman_cosine | |:------:|:----:|:-------------:|:------:|:------------------------:| | 0.0079 | 1 | 0.404 | - | - | | 0.0159 | 2 | 0.3185 | - | - | | 0.0238 | 3 | 0.2821 | - | - | | 0.0317 | 4 | 0.4036 | - | - | | 0.0397 | 5 | 0.3442 | 0.1253 | 0.9078 | | 0.0476 | 6 | 0.4145 | - | - | | 0.0556 | 7 | 0.4224 | - | - | | 0.0635 | 8 | 0.4048 | - | - | | 0.0714 | 9 | 0.3899 | - | - | | 0.0794 | 10 | 0.4127 | 0.1237 | 0.9079 | | 0.0873 | 11 | 0.3496 | - | - | | 0.0952 | 12 | 0.3731 | - | - | | 0.1032 | 13 | 0.3929 | - | - | | 0.1111 | 14 | 0.2957 | - | - | | 0.1190 | 15 | 0.3324 | 0.1206 | 0.9083 | | 0.1270 | 16 | 0.3341 | - | - | | 0.1349 | 17 | 0.3466 | - | - | | 0.1429 | 18 | 0.3558 | - | - | | 0.1508 | 19 | 0.2634 | - | - | | 0.1587 | 20 | 0.3095 | 0.1156 | 0.9088 | | 0.1667 | 21 | 0.2973 | - | - | | 0.1746 | 22 | 0.2884 | - | - | | 0.1825 | 23 | 0.3697 | - | - | | 0.1905 | 24 | 0.2683 | - | - | | 0.1984 | 25 | 0.3026 | 0.1096 | 0.9088 | | 0.2063 | 26 | 0.2441 | - | - | ### Framework Versions - Python: 3.10.14 - Sentence Transformers: 3.0.1 - Transformers: 4.44.0 - PyTorch: 2.4.0 - Accelerate: 0.33.0 - Datasets: 2.21.0 - Tokenizers: 0.19.1 ## Citation ### BibTeX #### Sentence Transformers ```bibtex @inproceedings{reimers-2019-sentence-bert, title = "Sentence-BERT: Sentence Embeddings using Siamese BERT-Networks", author = "Reimers, Nils and Gurevych, Iryna", booktitle = "Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing", month = "11", year = "2019", publisher = "Association for Computational Linguistics", url = "https://arxiv.org/abs/1908.10084", } ```