---
base_model: allenai/specter2_base
library_name: sentence-transformers
pipeline_tag: sentence-similarity
tags:
- sentence-transformers
- sentence-similarity
- feature-extraction
- generated_from_trainer
- dataset_size:8705
- loss:MultipleNegativesRankingLoss
widget:
- source_sentence: Vaccine Administration in High-Risk Groups
sentences:
- '[V+: strategies improving vaccination coverage among children with chronic diseases]. '
- 'Medical writer welcomes advice on working with medical writers. '
- 'Vaccination management. '
- source_sentence: Eosinophil recruitment and STAT6 signalling pathway in nematode
infections
sentences:
- 'The roles of eotaxin and the STAT6 signalling pathway in eosinophil recruitment
and host resistance to the nematodes Nippostrongylus brasiliensis and Heligmosomoides
bakeri. '
- 'ABO blood groups from Palamau, Bihar, India. '
- 'Both stat5a and stat5b are required for antigen-induced eosinophil and T-cell
recruitment into the tissue. '
- source_sentence: Constitutional Medicine Status
sentences:
- '[Present status of constitutional medicine]. '
- 'Convergence of submodality-specific input onto neurons in primary somatosensory
cortex. '
- 'The link between health and wellbeing and constitutional recognition. '
- source_sentence: Telehealth challenges
sentences:
- '[Technological transformations and evolution of the medical practice: current
status, issues and perspectives for the development of telemedicine]. '
- 'The untapped potential of Telehealth. '
- 'Enhanced chartreusin solubility by hydroxybenzoate hydrotropy. '
- source_sentence: Kawasaki disease immunoprophylaxis
sentences:
- '[Effect of immunoglobulin in the prevention of coronary artery aneurysms in Kawasaki
disease]. '
- 'Management of Kawasaki disease. '
- 'IgA anti-epidermal transglutaminase antibodies in dermatitis herpetiformis and
pediatric celiac disease. '
---
# SentenceTransformer based on allenai/specter2_base
This is a [sentence-transformers](https://www.SBERT.net) model finetuned from [allenai/specter2_base](https://huggingface.co./allenai/specter2_base) on the json 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:** [allenai/specter2_base](https://huggingface.co./allenai/specter2_base)
- **Maximum Sequence Length:** 512 tokens
- **Output Dimensionality:** 768 tokens
- **Similarity Function:** Cosine Similarity
- **Training Dataset:**
- json
### 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: BertModel
(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("sentence_transformers_model_id")
# Run inference
sentences = [
'Kawasaki disease immunoprophylaxis',
'[Effect of immunoglobulin in the prevention of coronary artery aneurysms in Kawasaki disease]. ',
'Management of Kawasaki disease. ',
]
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]
```
## Training Details
### Training Dataset
#### json
* Dataset: json
* Size: 8,705 training samples
* Columns: anchor
, positive
, and negative
* Approximate statistics based on the first 1000 samples:
| | anchor | positive | negative |
|:--------|:--------------------------------------------------------------------------------|:----------------------------------------------------------------------------------|:----------------------------------------------------------------------------------|
| type | string | string | string |
| details |
Telehealth challenges
| [Technological transformations and evolution of the medical practice: current status, issues and perspectives for the development of telemedicine].
| The untapped potential of Telehealth.
|
| Racial disparities in mental health treatment
| Relationships between stigma, depression, and treatment in white and African American primary care patients.
| Mental Health Care Disparities Now and in the Future.
|
| Iatrogenic hyperkalemia in elderly patients with cardiovascular disease
| Iatrogenic hyperkalemia as a serious problem in therapy of cardiovascular diseases in elderly patients.
| The cardiovascular implications of hypokalemia.
|
* Loss: [MultipleNegativesRankingLoss
](https://sbert.net/docs/package_reference/sentence_transformer/losses.html#multiplenegativesrankingloss) with these parameters:
```json
{
"scale": 20.0,
"similarity_fct": "cos_sim"
}
```
### Training Hyperparameters
#### Non-Default Hyperparameters
- `per_device_train_batch_size`: 32
- `per_device_eval_batch_size`: 32
- `learning_rate`: 2e-05
- `num_train_epochs`: 1
- `lr_scheduler_type`: cosine_with_restarts
- `warmup_ratio`: 0.1
- `bf16`: True
- `batch_sampler`: no_duplicates
#### All Hyperparameters