Property 'namedVectorizer' does not exist on type...
Adding options to the vectorizerConfig also throws ts errors:
Argument of type '{ model: string; dimensions: number; }' is not assignable to parameter of type 'string'.
Collection creation using the above code also throws this ts error:
Argument of type '{ name: string; vectorizer: any[]; generative: ModuleConfig<"generative-openai", GenerativeOpenAIConfig | undefined>; }' is not assignable to parameter of type 'CollectionConfigCreate<undefined, string>'.
Server Setup Information
Weaviate Server Version: 1.24.12
Deployment Method: Weaviate Cloud
Client Language and Version: Typescript v3 (3.0.0-rc.1)
You can provide the model by adding additional properties to text2Vec, like this (see docs):
await client.collections.create({
name: collectionName,
vectorizers: weaviate.configure.vectorizer.text2VecOpenAI(
"default",
{
model: 'text-embedding-3-large',
dimensions: 1024, //Parameter only applicable for `v3` model family and newer
}
),
})
You can find more info in the provider-dedicated docs, here is the page for the OpenAI integration
Btw. if you use models that have only one option for number of dimensions, i.e. ada-002, then you don’t need to specify the dimensions.