Skip to main content
  1. Blogs/

Qdrant Function Guide

·3 mins· loading · loading · · · Draft
Morethan
Qdrant
Morethan
Author
Morethan
Computer, Physic & AI
Table of Contents
Technical Miscellany - This article is part of a series.
Part 6: This Article
A detailed overview of Qdrant vector database’s core functionalities to help developers design better database solutions in practice. 😋

Introduction
#

Retrieval-Augmented Generation (RAG) based on vector databases is widely used in production. A vector database primarily stores vectors, enabling precise similarity-based queries through vector operations, a foundational capability in various applications.

Among many vector database providers such as Weaviate, Qdrant, Milvus, and Chroma, we will focus exclusively on Qdrant, referencing the official Qdrant documentation (2025-03).

Basic Data Types
#

Qdrant defines specific data abstractions to handle vector data effectively:

Point
#

The fundamental unit of storage in a vector database. Typically, a point contains a vector and an optional payload with additional metadata:

Point = Vector + Payload

{
    "id": 129,
    "vector": [0.1, 0.2, 0.3, 0.4],
    "payload": {"color": "red"}
}

Qdrant supports several vector types:

Type Description
Dense vectors Standard vectors generated by most embedding models.
Sparse vectors Variable-length vectors with few non-zero elements; useful for token matching and collaborative filtering.
Multi vectors Matrices composed of multiple dense vectors; each point may have different vector counts but identical dimensions.
Named vectors A mix of the above types, allowing various vector types within a single point.

Payload
#

Additional metadata stored with vectors using JSON syntax:

{
    "name": "jacket",
    "colors": ["red", "blue"],
    "count": 10,
    "price": 11.99,
    "locations": [{"lon": 52.5200, "lat": 13.4050}],
    "reviews": [
        {"user": "alice", "score": 4},
        {"user": "bob", "score": 5}
    ]
}

Payloads enhance semantic similarity searches by enabling additional logical filtering conditions.

Collection
#

A group of points. Collections allow you to define:

  1. Similarity algorithms between points
  2. Vector dimensions
  3. Optimizer settings
  4. HNSW algorithm parameters
  5. Write-Ahead Log (WAL) configurations
  6. Quantization settings

Common Operations
#

The essential operations for using vector databases:

Search #

Primarily refers to similarity search, leveraging the concept that objects with higher similarity are closer in vector space. Qdrant supports various similarity algorithms:

  • Dot product
  • Cosine similarity
  • Euclidean distance
  • Manhattan distance
Vectors are normalized when stored, making dot product and cosine similarity equivalent in Qdrant.

Qdrant provides a comprehensive Search API, enabling:

  1. Basic searches with a vector or specifying a named vector.
  2. Control over search algorithms, including exact matching (slower but precise).
  3. Result filtering based on payload tags or similarity thresholds.
  4. Limiting search results (limit).
  5. Batch searches for multiple vectors.
  6. Grouping search results (group_size).
  7. Query planning for optimized performance based on heuristic evaluations.
When using both group_size and limit, the limit parameter indicates the number of groups.

Sparse vectors and dense vectors differ notably in search behavior:

Aspect Sparse Vectors Dense Vectors
Similarity method Defaults to dot product, no need to specify You can specify supported algorithms
Search approach Only exact search HNSW for approximate searching
Search results Only vectors sharing common non-zero elements Top limit vectors as specified

Explore
#

Filtering
#

Advanced Operations
#

Hybrid Queries
#

Optimizer
#

Storage
#

Indexing
#

Snapshots
#

References
#

Technical Miscellany - This article is part of a series.
Part 6: This Article

Related

Neo4j Basics
··5 mins· loading · loading
Morethan
Neo4j
Hugo Blog Setup
·3 mins· loading · loading
Morethan
Hugo Blog
MySQL Basics
··6 mins· loading · loading
Morethan
MySQL