Sentence Similarity
PEFT
Safetensors
sentence-transformers
English
medical
cardiology
embeddings
domain-adaptation
lora
Instructions to use richardyoung/CardioEmbed-MPNet-base with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- PEFT
How to use richardyoung/CardioEmbed-MPNet-base with PEFT:
from peft import PeftModel from transformers import AutoModel base_model = AutoModel.from_pretrained("sentence-transformers/all-mpnet-base-v2") model = PeftModel.from_pretrained(base_model, "richardyoung/CardioEmbed-MPNet-base") - sentence-transformers
How to use richardyoung/CardioEmbed-MPNet-base with sentence-transformers:
from sentence_transformers import SentenceTransformer model = SentenceTransformer("richardyoung/CardioEmbed-MPNet-base") sentences = [ "That is a happy person", "That is a happy dog", "That is a very happy person", "Today is a sunny day" ] embeddings = model.encode(sentences) similarities = model.similarity(embeddings, embeddings) print(similarities.shape) # [4, 4] - Notebooks
- Google Colab
- Kaggle
Download adapter_config.json from richardyoung/CardioEmbed-MPNet-base: direct link, hf CLI and curl.
- Browser
- Download file 1 kB
-
https://huggingface.co/richardyoung/CardioEmbed-MPNet-base/resolve/main/adapter_config.json
- Command line
-
hf download hf://richardyoung/CardioEmbed-MPNet-base/adapter_config.json
-
curl -L -o adapter_config.json https://huggingface.co/richardyoung/CardioEmbed-MPNet-base/resolve/main/adapter_config.json
1 kB
| { | |
| "alora_invocation_tokens": null, | |
| "alpha_pattern": {}, | |
| "arrow_config": null, | |
| "auto_mapping": null, | |
| "base_model_name_or_path": "sentence-transformers/all-mpnet-base-v2", | |
| "bias": "none", | |
| "corda_config": null, | |
| "ensure_weight_tying": false, | |
| "eva_config": null, | |
| "exclude_modules": null, | |
| "fan_in_fan_out": false, | |
| "inference_mode": true, | |
| "init_lora_weights": true, | |
| "layer_replication": null, | |
| "layers_pattern": null, | |
| "layers_to_transform": null, | |
| "loftq_config": {}, | |
| "lora_alpha": 32, | |
| "lora_bias": false, | |
| "lora_dropout": 0.1, | |
| "megatron_config": null, | |
| "megatron_core": "megatron.core", | |
| "modules_to_save": null, | |
| "peft_type": "LORA", | |
| "peft_version": "0.18.0", | |
| "qalora_group_size": 16, | |
| "r": 16, | |
| "rank_pattern": {}, | |
| "revision": null, | |
| "target_modules": [ | |
| "q", | |
| "k", | |
| "v" | |
| ], | |
| "target_parameters": null, | |
| "task_type": "FEATURE_EXTRACTION", | |
| "trainable_token_indices": null, | |
| "use_dora": false, | |
| "use_qalora": false, | |
| "use_rslora": false | |
| } |