When creating a tenant for a class, can I specify a different vectorizer for it? Because the vectorizers used under multi-tenancy may be different.
Hi @user3 !
You can’t. ![]()
You first create the collection, specifying the vectorizer, then you add the tenant that will follow whatever the specifications you set for that collection.
There is a new feature in 1.24+ called named vectors, that you can have different vectors per object, but that would result in all you tenants having all the named vectors you define.
I suggest you open a new feature request:
I believe a feature that would allow you to optionally select named vector per tenant would be interesting and solve your requirement ![]()
Thanks!
Should the named vector be specified when creating the collection? But if I have a new tenant that is created after creating the collection, can he modify the vector config settings?
Second question: Can different vectorizers be specified for the same attribute?
Hi!
Yes, if you are using named vectors, you need to create them during the class creation:
when you do that, you can specify different vectorizers for different attributes (or the same, answering question 2).
For example:
# Define a new schema
collection = client.collections.create(
name="Named_Vector_Jeopardy_Collection",
description="Jeopardy game show questions",
vectorizer_config=[
wvc.config.Configure.NamedVectors.text2vec_cohere(
name="jeopardy_questions_vector",
source_properties=["question"],
vectorize_collection_name=False,
),
wvc.config.Configure.NamedVectors.text2vec_openai(
name="jeopardy_answers_vector",
source_properties=["answer"],
vectorize_collection_name=False,
),
],
properties=[
wvc.config.Property(name="category", data_type=wvc.config.DataType.TEXT),
wvc.config.Property(name="question", data_type=wvc.config.DataType.TEXT),
wvc.config.Property(name="answer", data_type=wvc.config.DataType.TEXT),
],
)
as source_properties you can specify for example [“answer”, “question”], ending up with a named vector based on those two properties, regardless if they are being used by another named vector.
Let me know if this helps ![]()
It looked different than I expected. ![]()
hi @user3 !
What were you expecting?
I believe this is a very flexible approach, as it allows you to mix and match the named vectors with the fields you want.
I would love to “pick your brain” on that ![]()