File size: 983 Bytes
c0bc093 53273bf e83a4f3 53273bf 47678cf 53273bf |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 |
---
pipeline_tag: sentence-similarity
language: en
license: apache-2.0
tags:
- sentence-transformers
- feature-extraction
- sentence-similarity
- transformers
---
# hku-nlp/instructor-base
This is a general embedding model: It maps sentences & paragraphs to a 768 dimensional dense vector space.
The model was trained on diverse tasks.
It takes customized instructions and text inputs, and generates task-specific embeddings for general purposes, e.g., information retrieval, classification, clustering, etc.
```
git clone https://github.com/HKUNLP/instructor-embedding
cd sentence-transformers
pip install -e .
```
Then you can use the model like this:
```python
from sentence_transformers import SentenceTransformer
sentence = "3D ActionSLAM: wearable person tracking in multi-floor environments"
instruction = "Represent the Science title; Input:"
model = SentenceTransformer('hku-nlp/instructor-base')
embeddings = model.encode([[instruction,sentence,0]])
print(embeddings)
``` |