Skip to main content

Overview

Weaviate is an open-source vector database with built-in vectorization, hybrid search, and GraphQL API support.

Installation

Basic Usage

Constructor Options

string
default:"http://localhost:8080"
Weaviate server URL
string
required
Name of the Weaviate class (collection)
string
API key for Weaviate Cloud

Running Weaviate

Docker

Weaviate Cloud

Sign up at Weaviate Cloud and use the provided URL:

Schema Configuration

Querying

Basic Query

Metadata Filtering

Combine vector and keyword search:

Complete Example

Best Practices

  1. Use Weaviate Cloud for production: Managed solution
  2. Enable persistence: Configure data persistence in Docker
  3. Leverage hybrid search: Combine vector and keyword search
  4. Define proper schema: Plan properties and data types
  5. Use GraphQL for complex queries: Direct access to Weaviate’s API

See Also