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
Hybrid Search
Combine vector and keyword search:Complete Example
Best Practices
- Use Weaviate Cloud for production: Managed solution
- Enable persistence: Configure data persistence in Docker
- Leverage hybrid search: Combine vector and keyword search
- Define proper schema: Plan properties and data types
- Use GraphQL for complex queries: Direct access to Weaviate’s API