Vectorizer Modules and Auto-Embedding
Learn how Weaviate's vectorizer modules automatically turn your data objects into vectors at import time, and how to configure them per class and property.
Vectorizer Modules and Auto-Embedding is a free Vector Databases: Pinecone, Weaviate & pgvector lesson on CoddyKit — lesson 4 of 4. You can read the complete lesson below for free — then practise it hands-on in the browser with a built-in code editor and a 24/7 AI tutor. It is part of the Vector Databases: Pinecone, Weaviate & pgvector learning path, one of 4 lessons in the course, and your progress syncs across the web and the CoddyKit app.
Who Creates the Vectors?
Vector search needs every object to have a vector. You can compute embeddings yourself, or let Weaviate do it via a vectorizer module that embeds objects automatically on import.
What Is a Vectorizer Module?
A vectorizer is a pluggable module (e.g. text2vec-openai, text2vec-cohere, text2vec-huggingface) that Weaviate calls to convert text into vectors. You choose it when defining a class.
Configuring a Vectorizer
The vectorizer is set in the class schema.
class_def = {
'class': 'Article',
'vectorizer': 'text2vec-openai',
'properties': [
{'name': 'title', 'dataType': ['text']},
{'name': 'body', 'dataType': ['text']}
]
}
print(class_def['vectorizer'])Auto-Embedding on Import
With a vectorizer set, you import plain objects and Weaviate embeds them for you. No need to call an embedding API yourself.
- Send object properties
- Module generates the vector
- Object stored with its vector
Choosing Which Properties to Embed
Not every property should influence the vector. You can skip properties (like IDs or timestamps) so only meaningful text contributes to the embedding.
prop = {
'name': 'sku',
'dataType': ['text'],
'moduleConfig': {'text2vec-openai': {'skip': True}}
}
print('skip embedding:', prop['moduleConfig']['text2vec-openai']['skip'])Including Property Names
By default Weaviate can prepend the property name to its value before embedding. Disabling 'vectorizePropertyName' keeps the vector focused on content rather than field labels.
Bring Your Own Vectors
You can also set vectorizer to 'none' and supply precomputed vectors at import. Useful when you already run a custom embedding pipeline or need a model Weaviate does not host.
Module Configuration
Each vectorizer accepts options in moduleConfig, such as the model name or dimensions. Set them at the class level to control how embeddings are produced.
module_config = {
'text2vec-openai': {'model': 'text-embedding-3-small', 'type': 'text'}
}
print(module_config['text2vec-openai']['model'])Consistency at Query Time
The same vectorizer embeds your query so it lives in the same space as stored objects. This is why mixing models or changing the vectorizer after import breaks search consistency.
Auto vs Manual Trade-offs
When to use each:
- Auto-embedding — simplest, less code, Weaviate manages calls
- Manual vectors — full control, custom models, batch pre-processing
Putting It Together
Pick a vectorizer per class, skip irrelevant properties, configure the model, and let Weaviate auto-embed on import. Or set 'none' to bring your own vectors. Keep the vectorizer consistent between import and query.
Quick Check
Test your understanding of vectorizers.
Recap
You learned that Weaviate vectorizer modules auto-embed objects on import. Configure the module per class, skip non-meaningful properties, set the model in moduleConfig, or use 'none' to bring your own vectors. Keep the vectorizer consistent between import and query for valid search.
Frequently asked questions
Is the “Vectorizer Modules and Auto-Embedding” lesson free?
Yes — the full text of “Vectorizer Modules and Auto-Embedding” is free to read here on the web, and the Vector Databases: Pinecone, Weaviate & pgvector course includes 4 lessons in total. To practise it interactively (a built-in code editor and a 24/7 AI tutor) and unlock the rest of the Vector Databases: Pinecone, Weaviate & pgvector course, upgrade to CoddyKit PRO.
What will I learn in “Vectorizer Modules and Auto-Embedding”?
Learn how Weaviate's vectorizer modules automatically turn your data objects into vectors at import time, and how to configure them per class and property. You practise Vector Databases: Pinecone, Weaviate & pgvector with hands-on code you run directly in the browser, and a 24/7 AI tutor answers your questions as you work through the lesson.
Do I need any experience to start Vector Databases: Pinecone, Weaviate & pgvector?
No prior experience is required. Vector Databases: Pinecone, Weaviate & pgvector on CoddyKit is structured for beginners through advanced learners; this is — lesson 4 of 4, so you can start here or from the beginning and move at your own pace.
How long does the “Vectorizer Modules and Auto-Embedding” lesson take?
Most CoddyKit lessons take about 5–10 minutes. Each one is bite-sized and interactive, so you make steady progress and pick up exactly where you left off across the web and the app.
Can I write and run code in this Vector Databases: Pinecone, Weaviate & pgvector lesson?
Yes. Every Vector Databases: Pinecone, Weaviate & pgvector lesson includes a built-in code editor, so you write and run real code right in your browser and get instant AI feedback — no local setup required.
All lessons in this course
- Weaviate Schema Definition
- Importing Data Objects
- Weaviate GraphQL Queries
- Vectorizer Modules and Auto-Embedding