* docs(edge): add "Modify the Vector Schema" step to quickstart Documents the new Edge 0.7 API for adding and removing named vector fields on an existing shard without recreating it, with Python and Rust snippets. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com> * docs(edge): mention quantization support in quickstart Adds a note after the EdgeConfig snippet that Edge supports all four quantization methods (Scalar, Product, Binary, TurboQuant), with a link to the quantization guide. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com> * docs(edge): add On-Device BM25 page for Edge 0.7 New guide covering the built-in BM25 sparse embedder: configuring a sparse vector shard, creating a Bm25/EdgeBm25 embedder, embedding and upserting documents, and querying. Includes Python and Rust snippets. Also adds the page to the Edge index navigation table. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com> * docs(edge): add WAL segment size configuration to quickstart Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com> * Upgrade code snippets to Edge 0.7.2 * Review feedback --------- Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
2.7 KiB
title, short_description, description, weight, partition
| title | short_description | description | weight | partition |
|---|---|---|---|---|
| On-Device Embeddings | Generate text and image embeddings on-device by pairing FastEmbed with Qdrant Edge for fully offline vector search. | Pair FastEmbed with Qdrant Edge to generate text and image embeddings on-device, enabling fully offline vector search with cached local models. | 15 | develop |
On-Device Embeddings with Qdrant Edge and FastEmbed
When using Python, you can use the FastEmbed library to generate embeddings for use with Qdrant Edge. FastEmbed provides multimodal models that run efficiently on edge devices to generate vector embeddings from text and images.
Provision the Device
Assuming the devices on which you will run Qdrant Edge have intermittent or no internet connectivity, you need to provision them with the necessary dependencies and model files ahead of time. First, install FastEmbed and the Qdrant Edge Python bindings:
pip install fastembed qdrant-edge-py
Next, download the embedding models and save them locally on the device. Instantiate instances of ImageEmbedding and TextEmbedding, setting the cache_dir parameter to a local directory:
{{< code-snippet path="/documentation/headless/snippets/edge/fastembed/" block="download-models" >}}
The models will be downloaded and cached in the specified MODELS_DIR directory, from where you can use them to generate embeddings.
Generate Image Embeddings
First, initialize an Edge Shard as described in the Qdrant Edge Quickstart Guide.
Details
{{< code-snippet path="/documentation/headless/snippets/edge/fastembed/" block="initialize-edge-shard" >}}
Assuming you have an image file temp.jpg, you can generate an embedding for it using FastEmbed's ImageEmbedding class and then store it in the Edge Shard:
{{< code-snippet path="/documentation/headless/snippets/edge/fastembed/" block="embed-and-store-image" >}}
Note the use of cache_dir=MODELS_DIR and local_files_only=True to load the image embedding model from the local directory where it was previously downloaded.
Generate Text Embeddings
At query time, you can generate text embeddings using FastEmbed's TextEmbedding class. For example, to query the Edge Shard:
{{< code-snippet path="/documentation/headless/snippets/edge/fastembed/" block="query-with-text-embedding" >}}
Again, using cache_dir=MODELS_DIR and local_files_only=True ensures the text embedding model is loaded from the local directory.