Skip to content

Commit

Permalink
ReRanker and ModernBert in example
Browse files Browse the repository at this point in the history
  • Loading branch information
sonam-pankaj95 committed Jan 5, 2025
1 parent ff46704 commit 7d458ce
Showing 1 changed file with 20 additions and 2 deletions.
22 changes: 20 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -94,9 +94,11 @@ Vector Streaming enables you to process and generate embeddings for files and st
➡️Faster execution. <br />
➡️Memory Management: Rust enforces memory management simultaneously, preventing memory leaks and crashes that can plague other languages <br />
➡️True multithreading <br />
➡️Running language models or embedding models locally and efficiently <br />
➡️Running embedding models locally and efficiently <br />
➡️Candle allows inferences on CUDA-enabled GPUs right out of the box. <br />
➡️Decrease the memory usage of EmbedAnything.
➡️Decrease the memory usage of EmbedAnything. <br/>
➡️Supports range of models, Dense, Sparse, Late-interaction, ReRanker, ModernBert.



# ⭐ Supported Models
Expand Down Expand Up @@ -147,6 +149,19 @@ model = EmbeddingModel.from_pretrained_onnx(
```
model: ColpaliModel = ColpaliModel.from_pretrained_onnx("starlight-ai/colpali-v1.2-merged-onnx", None)
```
### ModernBERT
```
model = EmbeddingModel.from_pretrained_onnx(
WhichModel.Bert, ONNXModel.ModernBERTBase, dtype = Dtype.Q4F16
)
```

### ReRankers
```
reranker = Reranker.from_pretrained("jinaai/jina-reranker-v1-turbo-en", dtype=Dtype.F16)
results: list[RerankerResult] = reranker.rerank(["What is the capital of France?"], ["France is a country in Europe.", "Paris is the capital of France."], 2)
```

## For Semantic Chunking

Expand Down Expand Up @@ -275,6 +290,9 @@ This document provides guidelines and best practices to help you to contribute e

One of the aims of EmbedAnything is to allow AI engineers to easily use state of the art embedding models on typical files and documents. A lot has already been accomplished here and these are the formats that we support right now and a few more have to be done. <br />

### Adding Fine-tuning
One of the major goals of this year is to add finetuning these models on your data. Like a simple sentence transformer does.

### 🖼️ Modalities and Source

We’re excited to share that we've expanded our platform to support multiple modalities, including:
Expand Down

0 comments on commit 7d458ce

Please sign in to comment.