Skip to content

Latest commit

 

History

History

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 

README.md

Milvus Tutorial with Feast

This tutorial demonstrates how to use Milvus as a vector database backend for Feast. You'll learn how to set up Milvus, create embeddings, store them in Feast, and perform similarity searches.

Prerequisites

  • Python 3.10+
  • Docker (for running Milvus)
  • Feast installed (pip install 'feast[milvus]')

Setup

  1. Start Milvus containers with Docker Compose:
docker compose up -d

This will start three containers:

  • milvus-standalone: The Milvus server
  • milvus-etcd: For metadata storage
  • milvus-minio: For object storage
  1. Wait until all containers are healthy (this may take a minute or two):
docker ps

Project Structure

milvus_tutorial/
├── README.md
├── feature_store.yaml    # Feast configuration
├── docker-compose.yml    # Docker Compose configuration for Milvus
├── data/                 # Data directory
│   └── sample_data.parquet  # Sample data with embeddings (generated by the script)
└── milvus_example.py     # Example script

Tutorial Steps

  1. Configure Feast with Milvus
  2. Generate sample data with embeddings
  3. Define feature views
  4. Register and apply feature definitions
  5. Perform vector similarity search

Run the complete example:

python milvus_example.py

How It Works

This tutorial demonstrates:

  • Setting up Milvus as a vector database
  • Configuring Feast to use Milvus as the online store
  • Generating embeddings for text data
  • Storing embeddings in Feast feature views
  • Performing vector similarity searches using Feast's retrieval API

Milvus is a powerful vector database designed for efficient similarity searches, making it an excellent choice for applications like semantic search and recommendation systems.