summaryrefslogtreecommitdiff
path: root/candle-transformers/src/models/nvembed_v2/mod.rs
diff options
context:
space:
mode:
Diffstat (limited to 'candle-transformers/src/models/nvembed_v2/mod.rs')
-rw-r--r--candle-transformers/src/models/nvembed_v2/mod.rs18
1 files changed, 18 insertions, 0 deletions
diff --git a/candle-transformers/src/models/nvembed_v2/mod.rs b/candle-transformers/src/models/nvembed_v2/mod.rs
new file mode 100644
index 00000000..8a8f7007
--- /dev/null
+++ b/candle-transformers/src/models/nvembed_v2/mod.rs
@@ -0,0 +1,18 @@
+//! NV-Embed-v2
+//!
+//! NV-Embed-v2 is a text embedding model that combines a Mistral decoder with a latent attention mechanism to produce high-quality text embeddings.
+//!
+//! This implementation is based on the [paper](https://arxiv.org/pdf/2405.17428) and [weights](https://huggingface.co/nvidia/NV-Embed-v2)
+//!
+//! # Query-Passage Retrieval Example
+//! ```bash
+//! cargo run --example nvembed_v2 --release
+//! ```
+//!
+//! # Sentence Embedding Example
+//! ```bash
+//! cargo run --example nvembed_v2 --release -- --prompt "Here is a test sentence"
+//! ```
+
+pub mod embedding;
+pub mod model;