---
language:
- en
license: apache-2.0
tags:
- sentence-transformers
- sentence-similarity
- feature-extraction
- generated_from_trainer
- dataset_size:649352
- loss:MultipleNegativesRankingLoss
base_model: BAAI/bge-large-en-v1.5
widget:
- source_sentence: 'dataCollection.studyDesignSummary: Plan detailing how data will
be collected from patient cohorts.'
sentences:
- 'dataset.primary_site: The primary body site studied in this dataset.'
- 'dataset.research_design: A summary of the goals of the research or a general
description of the research''s relationship to a clinical application.'
- 'subject.taxon_id: NCBI identifier for classification of organisms.'
- source_sentence: 'discoveryAction.CohortSet: A title or description of the discoveryAction;
used to identify it in publications and databases.'
sentences:
- 'surgery_procedure_diagnosis_code.SurgeryTime: SurgeryTime'
- 'mass_spec_assay.chromatography_type: '
- 'study.full_name: The full name for the project.'
- source_sentence: 'ExperimentDesignTemplate.researcher: Identifies the entity responsible
for creating and sharing data in the ExperimentDesignTemplate.'
sentences:
- 'subject.ofloxacin_res_phenotype: '
- 'dataset.data_contributor: The name of the organization or individual that the
contributed dataset belongs to.'
- 'payer_plan_period.site_id: The care site ID.'
- source_sentence: 'experiment_data.PatientDatabaseEntry: Number of basepairs of genome
sequenced.'
sentences:
- 'exam.updt: Last update of AHS exam index record'
- 'study.study_setup: Category'
- 'subject.genome_length: Number of basepairs of genome sequenced.'
- source_sentence: 'StudyDesign.studyDescription: Free-text overview of data provided
for research purposes.'
sentences:
- 'sleep_test_file.bucket_path: '
- 'subject.age_at_index_gt89: Indicates whether the subject''s age at the time of
the study was greater than 89 years.'
- 'dataset.data_description: Brief description of the data being provided for this
experiment.'
pipeline_tag: sentence-similarity
library_name: sentence-transformers
---
# Base trained on appropriate relationships between similar biomedical variables
This is a [sentence-transformers](https://www.SBERT.net) model finetuned from [BAAI/bge-large-en-v1.5](https://huggingface.co/BAAI/bge-large-en-v1.5) on the csv dataset. It maps sentences & paragraphs to a 1024-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:** [BAAI/bge-large-en-v1.5](https://huggingface.co/BAAI/bge-large-en-v1.5)
- **Maximum Sequence Length:** 512 tokens
- **Output Dimensionality:** 1024 dimensions
- **Similarity Function:** Cosine Similarity
- **Training Dataset:**
- csv
- **Language:** en
- **License:** apache-2.0
### 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': True}) with Transformer model: BertModel
(1): Pooling({'word_embedding_dimension': 1024, '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()
)
```
## 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 = [
'StudyDesign.studyDescription: Free-text overview of data provided for research purposes.',
'dataset.data_description: Brief description of the data being provided for this experiment.',
"subject.age_at_index_gt89: Indicates whether the subject's age at the time of the study was greater than 89 years.",
]
embeddings = model.encode(sentences)
print(embeddings.shape)
# [3, 1024]
# Get the similarity scores for the embeddings
similarities = model.similarity(embeddings, embeddings)
print(similarities.shape)
# [3, 3]
```
## Training Details
### Training Dataset
#### csv
* Dataset: csv
* Size: 649,352 training samples
* Columns: anchor and positive
* Approximate statistics based on the first 1000 samples:
| | anchor | positive |
|:--------|:-----------------------------------------------------------------------------------|:-----------------------------------------------------------------------------------|
| type | string | string |
| details |
FluorophoreCouplingRatio.assay_protocol_doi: Description of a standardized flow cytometry assay procedure. | flow_cytometry_assay.protocol_doi: |
| FluorophoreCouplingRatio.cell_quality_check: Assay quality assurance measures. | flow_cytometry_assay.quality_control_measures: |
| FluorophoreCouplingRatio.AssaySpec: Represents a record of any updates made to the flow cytometry assay template. | flow_cytometry_assay.provenance: |
* Loss: [MultipleNegativesRankingLoss](https://sbert.net/docs/package_reference/sentence_transformer/losses.html#multiplenegativesrankingloss) with these parameters:
```json
{
"scale": 20.0,
"similarity_fct": "cos_sim"
}
```
### Evaluation Dataset
#### csv
* Dataset: csv
* Size: 81,496 evaluation samples
* Columns: anchor and positive
* Approximate statistics based on the first 1000 samples:
| | anchor | positive |
|:--------|:------------------------------------------------------------------------------------|:-----------------------------------------------------------------------------------|
| type | string | string |
| details | treatment.cancerTreatmentTime: Comprehensive plan for healthcare services; including treatment and medication management. | treatment.treatment_span: |
| DiscoveryPlan.StudyObjective: Main disease type description provides a concise summary of the primary disease being investigated in this dataset. | dataset.disease_type: The primary type of disease studied in this dataset; if applicable. |
| DiscoveryPlan.StudyObjective: Main disease type description provides a concise summary of the primary disease being investigated in this dataset. | dataset.disease_type: The primary type of disease studied in this dataset; if applicable. |
* 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
- `eval_strategy`: steps
- `per_device_train_batch_size`: 16
- `per_device_eval_batch_size`: 16
- `num_train_epochs`: 1
- `warmup_ratio`: 0.1
- `fp16`: True
- `batch_sampler`: no_duplicates
#### All Hyperparameters