Get started with the Qdrant integrations

Qdrant logo

Qdrant is an open-source vector similarity search engine that efficiently stores, indexes, and searches large-scale vector data. It's commonly used in machine learning, artificial intelligence, and data science applications. The Aspire Qdrant integration enables you to connect to existing Qdrant servers or create new servers from Aspire with the qdrant/qdrant container image.

In this introduction, you'll see how to install and use the Aspire Qdrant integrations in a simple configuration. If you already have this knowledge, see Qdrant Hosting integration for full reference details.

Note

To follow this guide, you must have created an Aspire solution to work with. To learn how to do that, see Build your first Aspire app.

Set up hosting integration

To begin, install the Aspire Qdrant Hosting integration in your Aspire AppHost project. This integration allows you to create and manage Qdrant vector database instances from your Aspire hosting projects:

Install the NuGet package
dotnet add package Aspire.Hosting.Qdrant

Next, in the AppHost project, create instances of Qdrant server resources, then pass the server to the consuming client projects:

Tip

This is the simplest implementation of Qdrant resources in the AppHost. There are many more options you can choose from to address your requirements. For full details, see Qdrant Hosting integration.

Tip

The qdrant/qdrant container image includes a web UI that you can use to explore your vectors and administer the database. To access this tool, start your Aspire solution and then, in the Aspire dashboard, select the endpoint for the Qdrant resource. In your browser's address bar, append /dashboard and press Enter.

Use the integration in client projects

Now that the hosting integration is ready, the next step is to install and configure the client integration in any projects that need to use it.

Set up client projects

Use injected Qdrant properties

In the AppHost, when you used the WithReference method to pass a Qdrant resource to a consuming client project, Aspire injects several configuration properties that you can use in the consuming project.

Aspire exposes each property as an environment variable named [RESOURCE]_[PROPERTY]. For instance, the Uri property of a resource called qdrant becomes QDRANT_URI.

Tip

The full set of properties that Aspire injects depends on the Qdrant resource configuration. For more information, see Properties of the Qdrant resources.

Use Qdrant resources in client code

Next steps

Now that you have an Aspire app with Qdrant integrations up and running, you can use the following reference documents to learn how to configure and interact with the Qdrant resources:

<LinkCard Title="Understand the Qdrant hosting integration"

<LinkCard Title="Understand the Qdrant client integration"