Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 6 additions & 3 deletions weaviate/collections/classes/config_named_vectors.py
Original file line number Diff line number Diff line change
Expand Up @@ -865,12 +865,15 @@ def text2vec_gpt4all(
vector_index_config: The configuration for Weaviate's vector index. Use wvc.config.Configure.VectorIndex to create a vector index configuration. None by default
vectorize_collection_name: Whether to vectorize the collection name. Defaults to `True`.
"""
# Move vectorizer construction outside of function kwargs for efficiency
vectorizer = _Text2VecGPT4AllConfig(
vectorizeClassName=vectorize_collection_name,
)
# Use direct function return to avoid unnecessary keyword unpacking/mapping
return _NamedVectorConfigCreate(
name=name,
source_properties=source_properties,
vectorizer=_Text2VecGPT4AllConfig(
vectorizeClassName=vectorize_collection_name,
),
vectorizer=vectorizer,
vector_index_config=vector_index_config,
)

Expand Down