Sentence Similarity
sentence-transformers
Safetensors
xlm-roberta
feature-extraction
dense
Generated from Trainer
dataset_size:400000
loss:MultipleNegativesRankingLoss
Eval Results (legacy)
text-embeddings-inference
Instructions to use nexusmed-ai/adr_bge_m3_embedding with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- sentence-transformers
How to use nexusmed-ai/adr_bge_m3_embedding with sentence-transformers:
from sentence_transformers import SentenceTransformer model = SentenceTransformer("nexusmed-ai/adr_bge_m3_embedding") sentences = [ "{\"patient\":\"{\"age\": \"55\", \"age_cod\": \"yr\", \"gndr_cod\": \"f\", \"wt\": \"71.7\", \"wt_cod\": \"kg\"}\",\"treatment\":\"{\"drugname\": \"seroquel\", \"route\": \"oral\", \"dose\": \"200 mg tablet nan\"}; {\"drugname\": \"seroquel\", \"route\": \"oral\", \"dose\": \"generic\"}; {\"drugname\": \"seroquel\", \"route\": \"oral\", \"dose\": \"75 mg tablet qd\"}; {\"drugname\": \"seroquel\", \"route\": \"oral\", \"dose\": \"brand seroquel 75 mg with generic of seroquel 25 mg\"}; {\"drugname\": \"lamictal\", \"route\": \"oral\", \"dose\": \"nan\"}\",\"indi_pt\":\"sleep disorder; sleep disorder; sleep disorder; sleep disorder; sleep disorder\"}", "{\"pt\": \"pneumonia; transient ischaemic attack\", \"uni_code\": \"HO\"}", "{\"pt\": \"anxiety; drug ineffective; drug withdrawal syndrome; hyperhidrosis; insomnia; off label use; paraesthesia; paraesthesia oral; peripheral coldness\", \"uni_code\": \"NA\"}", "{\"pt\": \"hypotension; syncope\", \"uni_code\": \"HO\"}" ] embeddings = model.encode(sentences) similarities = model.similarity(embeddings, embeddings) print(similarities.shape) # [4, 4] - Notebooks
- Google Colab
- Kaggle
Welcome to the community
The community tab is the place to discuss and collaborate with the HF community!