Sentence Similarity
sentence-transformers
Safetensors
xlm-roberta
datadreamer
datadreamer-0.46.0
Synthetic
feature-extraction
text-embeddings-inference
Instructions to use fineinstructions/instruction_template_retrieval_embedding with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- sentence-transformers
How to use fineinstructions/instruction_template_retrieval_embedding with sentence-transformers:
from sentence_transformers import SentenceTransformer model = SentenceTransformer("fineinstructions/instruction_template_retrieval_embedding") 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
Update README.md
Browse files
README.md
CHANGED
|
@@ -15,6 +15,16 @@ pipeline_tag: sentence-similarity
|
|
| 15 |
|
| 16 |
Given a document, this retrieval embedding model helps retrieve instruction templates from [FineTemplates](https://huggingface.co/datasets/fineinstructions/finetemplates) relevant to various chunks / sections of the document.
|
| 17 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 18 |
## Example Usage
|
| 19 |
|
| 20 |
```python3
|
|
|
|
| 15 |
|
| 16 |
Given a document, this retrieval embedding model helps retrieve instruction templates from [FineTemplates](https://huggingface.co/datasets/fineinstructions/finetemplates) relevant to various chunks / sections of the document.
|
| 17 |
|
| 18 |
+
## Requirements
|
| 19 |
+
```
|
| 20 |
+
datasets
|
| 21 |
+
faiss
|
| 22 |
+
huggingface_hub
|
| 23 |
+
numpy
|
| 24 |
+
pandas
|
| 25 |
+
sentence_transformers
|
| 26 |
+
```
|
| 27 |
+
|
| 28 |
## Example Usage
|
| 29 |
|
| 30 |
```python3
|