AI/TLDR

Weaviate

Open-source vector database with built-in hybrid search and RAG

Overview

Weaviate is an open-source, cloud-native vector database that stores both your objects and their vector embeddings. It lets you run semantic search over large collections, and combines vector similarity with keyword (BM25) filtering, retrieval-augmented generation (RAG), and reranking in a single query interface.

It is aimed at developers building search and AI features such as RAG systems, semantic and image search, recommendation engines, chatbots, and content classification. You can have Weaviate generate embeddings at import time using integrated model providers like OpenAI, Cohere, and HuggingFace, or import your own pre-computed vectors.

As a vector database, it sits between your application and your model provider: it indexes embeddings for fast retrieval and adds production features such as multi-tenancy, replication, and RBAC authorization. Client libraries are available for Python, JavaScript/TypeScript, Java, Go, and C#/.NET, plus REST, gRPC, and GraphQL APIs.

What it does

  • Stores objects and their vectors together for semantic search at scale, with the core engine written in Go
  • Automatic vectorization at import using integrated model providers (OpenAI, Cohere, HuggingFace, Google, and others), or bring your own pre-computed embeddings
  • Hybrid search that combines vector similarity with keyword (BM25) search, image search, and filtering in one API call
  • Built-in generative search (RAG) and reranking for Q&A systems, chatbots, and summarizers
  • Production features including multi-tenancy, replication, and RBAC authorization
  • Client libraries for Python, JavaScript/TypeScript, Java, Go, and C#/.NET, plus REST, gRPC, and GraphQL APIs

Getting started

You can run Weaviate locally with Docker alongside a lightweight embedding model, then connect with the Python client to insert data and run a semantic search.

Start Weaviate with Docker Compose

Create a docker-compose.yml that runs Weaviate plus a local embedding model that vectorizes objects during import.

yamlyaml
services:
  weaviate:
    image: cr.weaviate.io/semitechnologies/weaviate:1.36.0
    ports:
      - "8080:8080"
      - "50051:50051"
    environment:
      ENABLE_MODULES: text2vec-model2vec
      MODEL2VEC_INFERENCE_API: http://text2vec-model2vec:8080

  # A lightweight embedding model that will generate vectors from objects during import
  text2vec-model2vec:
    image: cr.weaviate.io/semitechnologies/model2vec-inference:minishlab-potion-base-32M

Bring up the services

Start Weaviate and the embedding service in the background.

bashbash
docker compose up -d

Install the Python client

Install the official Python client (other client libraries are also available).

bashbash
pip install -U weaviate-client

Create a collection and run a search

Connect to your local instance, create a collection with a vectorizer, insert objects, and run a semantic (near-text) query.

pythonpython
import weaviate
from weaviate.classes.config import Configure, DataType, Property

# Connect to Weaviate
client = weaviate.connect_to_local()

# Create a collection
client.collections.create(
    name="Article",
    properties=[Property(name="content", data_type=DataType.TEXT)],
    vector_config=Configure.Vectors.text2vec_model2vec(),  # Use a vectorizer to generate embeddings during import
    # vector_config=Configure.Vectors.self_provided()  # If you want to import your own pre-generated embeddings
)

# Insert objects and generate embeddings
articles = client.collections.get("Article")
articles.data.insert_many(
    [
        {"content": "Vector databases enable semantic search"},
        {"content": "Machine learning models generate embeddings"},
        {"content": "Weaviate supports hybrid search capabilities"},
    ]
)

# Perform semantic search
results = articles.query.near_text(query="Search objects by meaning", limit=1)
print(results.objects[0])

client.close()

Commands and code are distilled from the project's own documentation — always check the official repo for the latest.

When to use it

  • Power a retrieval-augmented generation (RAG) pipeline that feeds relevant documents to an LLM-based chatbot or Q&A system
  • Add semantic or image search to an app so results match meaning rather than exact keywords
  • Build a recommendation engine over product, article, or media embeddings
  • Combine vector similarity with keyword (BM25) filtering for hybrid search across structured and unstructured data

How Weaviate compares

Weaviate alongside other open-source vector databases tools AI/TLDR tracks, ranked by GitHub stars.

ToolStarsWhat it does
Supabase★ 105kManaged Postgres backend whose Vector toolkit (pgvector) stores, indexes, and queries embeddings next to transactional data.
Redis Cloud★ 75kFully-managed Redis with built-in vector search, offering low-latency similarity and hybrid queries over any embeddings.
Milvus★ 44.9kA distributed vector database for storing and searching billions of embeddings at scale, with multiple index types and Kubernetes-native deployment.
FAISS★ 40.4kA library from Meta for efficient similarity search and clustering of dense vectors, with both exact and approximate indexes.
Qdrant★ 32.5kA Rust-based vector search engine that stores embeddings with rich payload filtering for semantic search and recommendation systems.
Chroma★ 28.5kA developer-focused vector database designed for quickly building retrieval and RAG features with a simple Python and JavaScript API.
pgvector★ 21.8kA PostgreSQL extension that adds a vector data type and similarity search so you can store and query embeddings inside an existing Postgres database.
Weaviate★ 16.4kOpen-source vector database with built-in hybrid search and RAG