Milvus search integration setup
Milvus is a high-performance, distributed vector database that is designed to manage large-scale datasets. It supports real-time search and handles multiple concurrent users efficiently, making it ideal for AI-powered applications.
You can configure only one search integration per environment in IBM® watsonx™ Assistant. If you switch to another integration type, such as IBM Watson® Discovery, Elasticsearch, or a custom service, the existing configuration is overwritten.
Prerequisites for connecting Milvus to an assistant
Before you connect Milvus to your assistant, you must complete the following steps:
1. Create required accounts
To begin using IBM watsonx services for Milvus integration, you must create accounts for both watsonx.data and watsonx.ai platforms:
2. Set up Milvus in watsonx.data
To enable vector search capabilities within your assistant, you must deploy and configure Milvus in your watsonx.data environment.
3. Configure Milvus in watsonx.ai
After you set up Milvus in watsonx.data, you must configure its integration within watsonx.ai to enable vector-based retrieval and enhance your assistant’s capabilities.
Procedure to connect Milvus to an assistant
This procedure explains how to integrate Milvus as a search provider in watsonx Assistant. The integration involves three IBM platforms:
- IBM® watsonx™ Assistant – Configure and manage the search integration.
- watsonx.data – Provision and manage the Milvus vector database instance.
- IBM watsonx.ai – Create and manage collections (data sources) for vector search.
Selecting Milvus as a search integration in watsonx Assistant
After you create a watsonx Assistant instance, you can add Milvus as the search integration by using one of the following procedures:
Option 1: From the Integrations page:
- Go to Home > Integrations.
- Scroll to the Extensions section.
- In the Search tile, click Add to open the Set up a new search integration window.
- Select Milvus to open the Connect your search provider window.
Option 2: From the Environments page:
- Go to Home > Environments.
- In the Resolution methods section, locate the Extensions section.
- Click Add in the Search tile to open the Set up a new search integration window.
- Select Milvus to open the Connect your search provider window.
Option 3: From the Conversational Search node:
- On the Home page, scroll to the Assistant architecture section.
- In the Conversational search node, click Add to open the Set up a new search integration window.
If Milvus is already added, the Open button is displayed instead of Add. To configure a custom service in the Draft or Live assistant environment, click Open.

Setting Up Milvus in watsonx.data
After you select Milvus as the search integration, you can connect your assistant to your Milvus instance in watsonx.data.
To learn how to create a Milvus instance, see the Prerequisites for Milvus integration.
Use the Connect Milvus option to link your assistant to the Milvus service in watsonx.data.
Required Connection Details

In the Connect your search provider section, enter the following details:
- GRPC host and GRPC port - Retrieve these values from your Milvus instance. For instructions, see Connection details.
Authentication options
Choose one of the following authentication methods:
-
Basic Authentication
Provide your username and password. -
watsonx.data API Key
Enter your API key. -
None
No authentication details are required.
For more information about credentials, see Getting credentials.
Updating your Milvus authentication credentials
IBM watsonx.data version 2.3 introduces changes to Milvus authentication. To avoid service disruptions, update your Milvus connection settings by 10 December 2025.
Step 1: Locate your new Milvus username
Your new Milvus username follows this format:
ibmlhapikey_<your watsonx.data username>
Examples
| watsonx.data username | Milvus username |
|---|---|
abc@ibm.com |
ibmlhapikey_abc@ibm.com |
serviceid-abcdef-123456 |
ibmlhapikey_serviceid-abcdef-123456 |
If you do not know your watsonx.data username:
- Go to Infrastructure manager in the watsonx.data console.
- Select your Milvus service to view the Details page.
- Click the Access control tab.
- Locate your watsonx.data username in the first column of the table.
Step 2: Update your Milvus connection in watsonx Assistant
Update your Milvus credentials for each assistant that uses a Milvus as a source:
-
Go to Home > Integrations.
-
In the Extensions section, click Open on the Search tile.
-
If prompted, choose the environment to update. Repeat for each environment (For example, Draft and Live).
-
Select Milvus.
-
Record your current connection settings for reference.
-
Go to the Instance tab and click Update.
-
Enter the following connection information:
- GRPC Host and GRPC Port.
- Username: Use your new Milvus username from Step 1.
- Password: Use your existing password or API key.
- If you are using a watsonx.data API key, enter it as the password.
-
Click Next.
-
Click Save and then click Close.
-
Return to the search tile and click Open.
-
Select the same environment that you chose in Step 2.
-
Click Milvus.
-
Go to the Conversational Search section.
-
Reenter the settings that you recorded in step 5.
-
Click Save, then Close.
-
Use the assistant chat window to confirm Milvus search results are working correctly.
Ingesting data into the Milvus through watsonx.ai
To use Milvus with your assistant, first collect your data in watsonx.data, then ingest it into the Milvus vector database.
In the Milvus setup window of your assistant, click Next to proceed to the Select data source step. Provide the following details:
- In Database, select your preferred database.
- In Choose collection, select the collection that you want to use. For more information, see Prerequisites for Milvus integration.
- In Choose index, select the index that is associated with your collection.
- In Choose embedding_model_id, select the embedding model that matches the one used to create your index.
Learn more about embedding models.
The selected model must match the model that is used during index creation. {: note}
Configuring the result content
After you connect Milvus by selecting the data source, you can configure how the search response displays in the Milvus window of your assistant.
In the Configure result content section of Select data source, map the following fields from your Milvus collection:
-
Title: Use a title, name, or similar field. It appears as the search result title. If not set, search results are not displayed in Facebook or Slack integrations.
-
Body: Use an abstract, summary, or highlight field. It appears as the search result description. If not set, search results are not displayed in Facebook or Slack integrations.
-
URL: Add any footer content to display at the end of the search result.
Enabling conversational search in Milvus
After you configure the result content, click Next to access the Conversational Search section (optional).
Conversational search is available only in the Plus and Enterprise plans of watsonx Assistant.
To activate conversational search, toggle Conversational Search to On.
Defining filter expression
To filter Milvus search results, expand the Advanced Milvus settings section and define a Filter string.
Tuning your conversational search
You can customize how your assistant responds when search results are returned, missing, or when connectivity issues occur.
You can tune your conversational search’s tendency to say “I don’t know" and the generated response length.
Use the following tabs to configure messages:
| Tab | Scenario | Example message |
|---|---|---|
| Message | Search results are returned | I found this information that might be helpful: |
| No results found | No search results are found | I searched my knowledge base for information that might address your query, but did not find anything useful to share. |
| Connectivity issue | The search might not be completed | I might have helpful information, but I'm unable to search my knowledge base. |
If you skip this step, default messages will be used. To update Milvus instance credentials, go to the Instance tab, change the authentication type or credentials, and click Save. To update the Milvus URL, click Update to restart setup from Step 1.
Click Save and then Close to complete the setup.
Filtering expression examples
Use the following examples to define filter expressions:
Contains
title like "%action%"
Returns results where the title contains action.
Doesn't contain
not (title like "%action%")
Excludes results where the title contains action.
Equal
"Understand your most and least successful actions"
Returns results with an exact title match.
Doesn't Equal
"Understand your most and least successful actions"
Excludes results with the exact title.
Nested filter expression
(title like "%action%") and (url in ["www.url1.com", "www.url2.com"])
Returns results where the title contains "action" and the URL matches one of the specified values.
Configuring your assistant to use Milvus
After you set up Milvus, configure your assistant to use it when no action matches.
Testing Milvus integration
You can test Milvus search integration by using:
- Actions preview
- Preview page
- Preview link
Conversational search must be turned On to see proper results.
Example
User query: What is an action?
If conversational search is enabled, the assistant returns a text-based reply from the best results in your knowledge base.
