๐ฆWeaviate
Weaviate:
We recommend this database when you have a more large usecase. You would have to deploy weaviate separately and connect it to our stack to use the running weaviate instance.
We recommend running weaviate without any vectorizer module so that the embedding component is utilized for creating embeddings from your documents.
Installation
Prerequisites:
Here the docker-compose configurations:
This is a sample docker-compose file for installing weaviate without any vectorizer modules.
version: "3.4"
services:
weaviate:
image: semitechnologies/weaviate:1.20.1
ports:
- 8080:8080
restart: on-failure:0
environment:
QUERY_DEFAULTS_LIMIT: 25
AUTHENTICATION_ANONYMOUS_ACCESS_ENABLED: "true"
PERSISTENCE_DATA_PATH: "/var/lib/weaviate"
DEFAULT_VECTORIZER_MODULE: "none"
CLUSTER_HOSTNAME: "node1"
volumes:
- weaviate_db:/var/lib/weaviate
volumes:
weaviate_db:This docker compose file uses sentence transformers for embedding for more embeddings and other options refer this doc.
Supported Arguments:
Supported Search Methods:
similarity_search
Search Options:
k : The top k elements for searching
max_marginal_relevance_search
Search Options
k: Number of Documents to return. Defaults to 4.
fetch_k: Number of Documents to fetch to pass to MMR algorithm.
lambda_mult: Number between 0 and 1 that determines the degree of diversity among the results with 0 corresponding to maximum diversity and 1 to minimum diversity. Defaults to 0.5.
Usage
A Vectordb definitely needs a embedding function and you connect these two components through a stack.
You can also use different search_methods and search options when trying out more complicated usecases
Note: Weaviate expects class_name in PascalCase otherwise it might lead to weird index not found errors.
Last updated