AI - Vector Context Add
Type identifier:
ai:vectorContext:addCategory: AI Operations
Description
The AI - Vector Context Add node stores text embeddings in a vector context, enabling later semantic search operations. It automatically computes embeddings and indexes them with optional labels for filtering.
Input Handles
Handle | Type | Description |
|---|---|---|
| control | Triggers the add operation. |
|
| The text content to embed and store. |
|
| Unique identifier for this embedding. |
|
| Dynamic handles for label values. |
Output Handles
Handle | Type | Description |
|---|---|---|
| control | Triggered when the embedding is successfully stored. |
| control | Triggered when the operation fails. |
Configuration Options
Option | Type | Default | Description |
|---|---|---|---|
Labels |
|
| Label keys for categorising embeddings. |
Behaviour
- Receives text content and unique ID
- Computes embedding vector for the content
- Resolves label values from dynamic handles
Stores the content in the vector context with:
- The original text content
- The unique ID
- Label key-value pairs
- Triggers success or error control flow
Labels
Labels enable filtered vector queries:
- Each configured label creates a dynamic input handle
- Label values are stored alongside embeddings
- Queries can filter by label values
ID Handling
The ID uniquely identifies each embedding:
- Duplicate IDs update existing embeddings
Embedding Model
Uses OpenAI text-embedding-ada-002 (1536 dimensions) for embedding computation. For the canonical model list, see AI - Model Reference — Compute Embedding Models.
Examples
Store Document Chunks
Configuration:
- Labels:
["documentId", "chunkIndex"]
Flow:
- Text - Recursive Split chunks a document
- List - Map iterates chunks
- AI - Vector Context Add stores each chunk
For each chunk:
content: The chunk textid:<documentId>-<chunkIndex>documentId: Source document IDchunkIndex: Position in document
Store Categorised Content
Configuration:
- Labels:
["category", "source"]
Use case: Build a knowledge base with categorised entries for filtered retrieval.
Update Existing Content
Providing an existing ID updates the embedding:
- New embedding computed
- Previous embedding replaced
- Labels updated