The Edge API
To work with a Qdrant Edge Shard, use the Python Bindings for Qdrant Edge package or the qdrant-edge Rust crate. Both expose an EdgeShard type with methods to manage data, query it, and restore snapshots.
For task-oriented introductions, refer to the Quickstart and the Data Synchronization Patterns.
Reference
| Page | What it covers |
|---|---|
| Shard Lifecycle | Creating, loading, inspecting, flushing, and closing an Edge Shard, and reading its metadata with info |
| Configuration | EdgeConfig, dense and sparse vector parameters, optimizer settings and optimize, and WAL options |
| Updating Data | The update method and the full set of update operations |
| Reading Data | query, scroll, grouping, retrieve, count, and facet |
| Snapshots | Unpacking snapshots, reading manifests, and applying snapshots to a shard |
Language Differences
The Python bindings and the Rust crate cover the same core surface, but they are not identical. Each method notes the languages it is available in. The most significant differences are:
- Rust exposes
query_groupsandsearch_matrix, which have no Python equivalent. Both require theEdgeShardReadtrait in scope. - Rust closes a shard by dropping it, while Python has an explicit
closemethod. - WAL options and the configuration setters are Rust only.
- Python’s
EdgeConfigalways requiresvectorsorsparse_vectors, so adjusting a tunable parameter on an existing shard means redeclaring its vectors. Rust can build a configuration that sets only tunables. - Applying a snapshot updates the shard in place in Python, but returns a new shard in Rust.
More Examples
The Qdrant GitHub repository contains examples of using the Qdrant Edge API in Python and Rust.