Downloads · 30 days
6
12% of all-time downloads
praveen-hugs/bge-mnrl-finetuned
bge-mnrl-finetuned is a sentence similarity model from praveen-hugs. Use it when you need a score for how close two texts are. It is set up for sentence-transformers.
This is a sentence-transformers model finetuned from BAAI/bge-base-en-v1.5. It maps sentences & paragraphs to a 768-dimensional dense vector space and can be used for retrieval.
Downloads · 30 days
6
12% of all-time downloads
All-time downloads
50
Public
Parameters
109M
438 MB on disk
Likes
0
Public
Click a slice to open those files.
.safetensors438 MB · 100%
From the Hugging Face model README
This is a sentence-transformers model finetuned from BAAI/bge-base-en-v1.5. It maps sentences & paragraphs to a 768-dimensional dense vector space and can be used for retrieval.
SentenceTransformer(
(0): Transformer({'transformer_task': 'feature-extraction', 'modality_config': {'text': {'method': 'forward', 'method_output_name': 'last_hidden_state'}}, 'module_output_name': 'token_embeddings', 'architecture': 'BertModel'})
(1): Pooling({'embedding_dimension': 768, 'pooling_mode': 'cls', 'include_prompt': True})
(2): Normalize({})
)
First install the Sentence Transformers library:
pip install -U sentence-transformers
Then you can load this model and run inference.
from sentence_transformers import SentenceTransformer
# Download from the 🤗 Hub
model = SentenceTransformer("sentence_transformers_model_id")
# Run inference
sentences = [
'Represent this sentence for searching relevant passages: How does the reliance on cloud communication systems change with the increase in remote workforces due to the pandemic?',
'The full extent of the impact of the COVID-19 pandemic on our business, operations and financial results will depend on numerous evolving factors that we may not be able to accurately predict, including those set forth under the section entitled "Risk Factors." In an effort to contain COVID-19 or slow its spread, governments around the world have enacted various measures, including orders to close non-essential businesses, isolate residents to their homes, and practice social distancing. To protect the health and safety of our employees, our workforce has spent significant time working from home and travel has been curtailed for our employees as well as our customers. Small and medium-sized customers have been particularly impacted by the COVID-19 pandemic. We have also experienced significant increases in usage by existing customers as our customers’ workforces are required to work from home in response to the COVID-19 pandemic accelerating trends we have seen in distributed workforces increasingly relying on cloud communication systems like ours. While we anticipate that the global health crisis caused by COVID-19 and the measures enacted to slow its spread will negatively impact business activity across the globe, it is not clear what its potential effects will be on our business, including the effects on our customers, suppliers or vendors, or on our financial results.\nCOMPONENTS OF RESULTS OF OPERATIONS\nService Revenue\nService revenue consists of communication services subscriptions, platform usage revenue, and related fees from our UCaaS, CCaaS, and CPaaS offerings. We plan to continue driving our business to increase service revenue through a combination of increased sales and marketing efforts, geographic expansion of our customer base outside the United States, innovation in product and technology, and through strategic acquisitions of technologies and businesses.\nOther Revenue\nOther revenue consists of revenues from professional services, primarily in support of deployment of our solutions and/or platform, and revenues from sales and rentals of IP telephones in conjunction with our cloud telephony service. Other revenue is dependent on the number of customers who choose to purchase or rent an IP telephone in conjunction with our service instead of using the solution on their cell phone, computer or other compatible device, and/or choose to engage our services for implementation and deployment of our cloud services.\nCost of Service Revenue',
'We record deferred taxes based on differences between the financial statement basis and tax basis of assets and liabilities and available tax loss and credit carryforwards. In evaluating our ability to utilize our deferred tax assets, we consider available evidence, both positive and negative, in determining future taxable income on a jurisdiction-by-jurisdiction basis. We record a valuation allowance against deferred tax assets if, based on the weight of the evidence, it is more likely than not that some portion or all of the deferred tax assets will not be realized. A significant item of objective negative evidence considered was the historical three-year cumulative pretax loss reached in fiscal 2018. We continue to remain in a cumulative pretax loss position, and therefore, continued to maintain a full valuation allowance against our U.S., U.K., and Singapore deferred tax assets.\nLiquidity and Capital Resources\nAs of March 31, 2021, we had $152.9 million of cash and cash equivalents and short-term investments. In addition, we had $8.6 million in restricted cash in support of letters of credit securing leases for office facilities in California and New York. During fiscal 2021, $10.4 million previously held in escrow for our acquisition of Wavecell was released.\nAs of March 31, 2020, we had $170.9 million of cash and cash equivalents and short-term investments. In addition, we had $19.0 million in restricted cash, of which $8.6 million was in support of letters of credit securing leases for office facilities in California and New York and $10.4 million was held in escrow for our acquisition of Wavecell, pursuant to the terms of the acquisition agreement.',
]
embeddings = model.encode(sentences)
print(embeddings.shape)
# [3, 768]
# Get the similarity scores for the embeddings
similarities = model.similarity(embeddings, embeddings)
print(similarities)
# tensor([[ 1.0000, 0.5362, -0.0206],
# [ 0.5362, 1.0000, -0.0907],
# [-0.0206, -0.0907, 1.0000]])
<!--
### Direct Usage (Transformers)
<details><summary>Click to see the direct usage in Transformers</summary>
</details>
-->
<!--
### Downstream Usage (Sentence Transformers)
You can finetune this model on your own dataset.
<details><summary>Click to expand</summary>
</details>
-->
<!--
### Out-of-Scope Use
*List how the model may foreseeably be misused and address what users ought not to do with the model.*
-->
| Metric | Value |
|---|---|
| cosine_accuracy@1 | 0.4435 |
| cosine_accuracy@3 | 0.6532 |
| cosine_accuracy@5 | 0.7316 |
| cosine_accuracy@10 | 0.8306 |
| cosine_precision@1 | 0.4435 |
| cosine_precision@3 | 0.2177 |
| cosine_precision@5 | 0.1463 |
| cosine_precision@10 | 0.0831 |
| cosine_recall@1 | 0.4435 |
| cosine_recall@3 | 0.6532 |
| cosine_recall@5 | 0.7316 |
| cosine_recall@10 | 0.8306 |
| cosine_ndcg@10 | 0.6319 |
| cosine_mrr@10 | 0.569 |
| cosine_map@100 | 0.5766 |
| sentence_0 | sentence_1 | |
|---|---|---|
| type | string | string |
| details | <ul><li>min: 20 tokens</li><li>mean: 29.8 tokens</li><li>max: 57 tokens</li></ul> | <ul><li>min: 15 tokens</li><li>mean: 403.25 tokens</li><li>max: 482 tokens</li></ul> |
| sentence_0 | sentence_1 |
|---|---|
| <code>Represent this sentence for searching relevant passages: What was the electrical load estimated at for the mining operation as of December 31, 2020?</code> | <code>The Company owned approximately 669 and 649 Antminer S17 Pro Bitcoin miners located in LaFayette, GA as of December 31, 2020 and April 15, 2021, respectively. All miners were purchased from Bitmaintech Pte. Ltd., a Singapore limited company (“Bitmain”), and are collectively rated at approximately 30 Ph/s in computing power. Bitmain has acknowledged manufacturing defects, combined with inadequate repair facilities, rendering approximately one half of our miners in need of repair or replacement. The Company’s miners are housed in three modified shipping containers. The Company’s current electrical load is estimated at under 1.0 MW. The entire facility, including the land, two 2500 KVA 3-phase transformers, the mining containers, and miners, are owned by MGT. As the Company is presently using only a portion of the built-out available electrical load, it is exploring ways to grow and maintain its current operations including but not limited to further equipment sales, leasing space to othe...</code> |
| <code>Represent this sentence for searching relevant passages: What is the accumulated deficit reported as of December 31, 2020, that raises doubt about the ability to continue operations?</code> | <code>The Company may raise additional capital, either through debt or equity financings, in order to achieve its business plan objectives. Management believes that it can be successful in obtaining additional capital; however, no assurance can be provided that the Company will be able to do so. There is no assurance, moreover, that any funds raised will be sufficient to enable the Company to attain profitable operations or continue as a going concern. To the extent that the Company is unsuccessful, the Company may need to curtail its operations and implement a plan to extend payables or reduce overhead until sufficient additional capital is raised to support further operations. The Company may also attempt to obtain funds through entering into arrangements with collaborative partners or others that may require the Company to relinquish rights to certain of our technologies or products that the Company would not otherwise relinquish. There can be no assurance that any such plan will be succe...</code> |
| <code>Represent this sentence for searching relevant passages: What risks are associated with the development and acceptance of digital currencies that may impact operational results?</code> | <code>The Company may raise additional capital, either through debt or equity financings, in order to achieve its business plan objectives. Management believes that it can be successful in obtaining additional capital; however, no assurance can be provided that the Company will be able to do so. There is no assurance, moreover, that any funds raised will be sufficient to enable the Company to attain profitable operations or continue as a going concern. To the extent that the Company is unsuccessful, the Company may need to curtail its operations and implement a plan to extend payables or reduce overhead until sufficient additional capital is raised to support further operations. The Company may also attempt to obtain funds through entering into arrangements with collaborative partners or others that may require the Company to relinquish rights to certain of our technologies or products that the Company would not otherwise relinquish. There can be no assurance that any such plan will be succe...</code> |
{
"scale": 20.0,
"similarity_fct": "cos_sim",
"gather_across_devices": false,
"directions": [
"query_to_doc"
],
"partition_mode": "joint",
"hardness_mode": null,
"hardness_strength": 0.0
}
per_device_train_batch_size: 32per_device_eval_batch_size: 32num_train_epochs: 2multi_dataset_batch_sampler: round_robindo_predict: Falseprediction_loss_only: Trueper_device_train_batch_size: 32per_device_eval_batch_size: 32gradient_accumulation_steps: 1eval_accumulation_steps: Nonetorch_empty_cache_steps: Nonelearning_rate: 5e-05weight_decay: 0.0adam_beta1: 0.9adam_beta2: 0.999adam_epsilon: 1e-08max_grad_norm: 1num_train_epochs: 2max_steps: -1lr_scheduler_type: linearlr_scheduler_kwargs: Nonewarmup_ratio: Nonewarmup_steps: 0log_level: passivelog_level_replica: warninglog_on_each_node: Truelogging_nan_inf_filter: Trueenable_jit_checkpoint: Falsesave_on_each_node: Falsesave_only_model: Falserestore_callback_states_from_checkpoint: Falseuse_cpu: Falseseed: 42data_seed: Nonebf16: Falsefp16: Falsebf16_full_eval: Falsefp16_full_eval: Falsetf32: Nonelocal_rank: -1ddp_backend: Nonedebug: []dataloader_drop_last: Falsedataloader_num_workers: 0dataloader_prefetch_factor: Nonedisable_tqdm: Falseremove_unused_columns: Truelabel_names: Noneload_best_model_at_end: Falseignore_data_skip: Falsefsdp: []fsdp_config: {'min_num_params': 0, 'xla': False, 'xla_fsdp_v2': False, 'xla_fsdp_grad_ckpt': False}accelerator_config: {'split_batches': False, 'dispatch_batches': None, 'even_batches': True, 'use_seedable_sampler': True, 'non_blocking': False, 'gradient_accumulation_kwargs': None}parallelism_config: Nonedeepspeed: Nonelabel_smoothing_factor: 0.0optim: adamw_torch_fusedoptim_args: Nonegroup_by_length: Falselength_column_name: lengthproject: huggingfacetrackio_space_id: trackioddp_find_unused_parameters: Noneddp_bucket_cap_mb: Noneddp_broadcast_buffers: Falsedataloader_pin_memory: Truedataloader_persistent_workers: Falseskip_memory_metrics: Truepush_to_hub: Falseresume_from_checkpoint: Nonehub_model_id: Nonehub_strategy: every_savehub_private_repo: Nonehub_always_push: Falsehub_revision: Nonegradient_checkpointing: Falsegradient_checkpointing_kwargs: Noneinclude_for_metrics: []eval_do_concat_batches: Trueauto_find_batch_size: Falsefull_determinism: Falseddp_timeout: 1800torch_compile: Falsetorch_compile_backend: Nonetorch_compile_mode: Noneinclude_num_input_tokens_seen: noneftune_noise_alpha: Noneoptim_target_modules: Nonebatch_eval_metrics: Falseeval_on_start: Falseuse_liger_kernel: Falseliger_kernel_config: Noneeval_use_gather_object: Falseaverage_tokens_across_devices: Trueuse_cache: Falseprompts: Nonebatch_sampler: batch_samplermulti_dataset_batch_sampler: round_robinrouter_mapping: {}learning_rate_mapping: {}| Epoch | Step | cosine_ndcg@10 |
|---|---|---|
| 1.0 | 215 | 0.6144 |
| 2.0 | 430 | 0.6319 |
@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",
}
@misc{oord2019representationlearningcontrastivepredictive,
title={Representation Learning with Contrastive Predictive Coding},
author={Aaron van den Oord and Yazhe Li and Oriol Vinyals},
year={2019},
eprint={1807.03748},
archivePrefix={arXiv},
primaryClass={cs.LG},
url={https://arxiv.org/abs/1807.03748},
}
<!--
## Glossary
*Clearly define terms in order to be accessible across audiences.*
-->
<!--
## Model Card Authors
*Lists the people who create the model card, providing recognition and accountability for the detailed work that goes into its construction.*
-->
<!--
## Model Card Contact
*Provides a way for people who have updates to the Model Card, suggestions, or questions, to contact the Model Card authors.*
-->