
Redis Add
CertifiedAdd an element to a Redis vector set
Redis Add
Add an element to a Redis vector set
Runs VADD to attach an embedding to an element id inside a Redis vector set, creating the set on first use. See the Redis vector set documentation for details.
type: io.kestra.plugin.redis.vector.AddExamples
Add an embedding vector to a Redis vector set.
id: store_embedding
namespace: company.team
inputs:
- id: embedding
type: ARRAY
itemType: FLOAT
tasks:
- id: add_vector
type: io.kestra.plugin.redis.vector.Add
url: "redis://:{{ secret('REDIS_PASSWORD') }}@{{ secret('REDIS_HOST') }}:6379"
key: "doc_embeddings"
element: "doc_42"
vector: "{{ inputs.embedding }}"
Properties
element *string
Element id
Unique identifier of the member the vector is attached to inside the vector set.
key *string
Vector set key
Rendered before calling VADD. The vector set is created automatically the first time an element is added.
url *string
Redis connection string
vector *array
Vector
The embedding to store, as a list of numbers. All elements added to a given vector set must share the same dimensionality unless reduceDim is used.
assets
Assets this task consumes as inputs or produces as outputs, for lineage tracking and the asset graph (Enterprise Edition). A flow declaring this property on a task is rejected in the open-source edition.
io.kestra.core.models.assets.AssetsDeclaration
IGNOREFAILWARNAsset failure behavior
Behavior applied to the task state when a declared asset fails to render, emit, or be persisted (e.g. a lock conflict): FAIL escalates it to FAILED, WARN (default) warns it if it would otherwise succeed, IGNORE leaves the state untouched.
Whether to auto-register assets referenced dynamically at runtime that are not statically declared in inputs or outputs.
The assets consumed as inputs.
io.kestra.core.models.assets.AssetIdentifier
1The assets produced as outputs.
io.kestra.plugin.ee.assets.Dataset
1150{}1150io.kestra.plugin.ee.assets.File
1150{}1150io.kestra.plugin.ee.assets.Table
1150{}1150io.kestra.plugin.ee.assets.VM
1150{}1150io.kestra.core.models.assets.External
1150{}1150io.kestra.core.models.assets.Custom
11501Custom asset type
{}1150attributes object
Attributes
Arbitrary JSON object attached to the element, as key-value pairs. Serialized and stored alongside the vector, it can later be referenced in a Similarity task's filter expression.
checkAndSet booleanstring
Check and set
Maps to the VADD CAS option. When true, performs the insertion as a check-and-set operation to reduce contention under concurrent writes.
explorationFactor integerstring
Exploration factor
Maps to the VADD EF option. Controls the search effort used while inserting the new node into the underlying HNSW graph; higher values improve insertion quality at the cost of speed. When left unset, the property is omitted from the VADD call and Redis applies its own default.
maxNodes integerstring
Max connections per node
Maps to the VADD M option. Maximum number of connections each node of the underlying HNSW graph can have; higher values improve recall at the cost of memory. When left unset, the property is omitted from the VADD call and Redis applies its own default.
quantization string
NO_QUANTIZATIONBINARYQ8Quantization type
Maps to the VADD quantization option: NO_QUANTIZATION (full-precision floats), BINARY (1-bit per component), or Q8 (8-bit integers). When left unset, the property is omitted from the VADD call and Redis applies its own default (Q8).
reduceDim integerstring
Reduce dimensionality
Maps to the VADD REDUCE option. When set, the vector is randomly projected down to this many dimensions before being stored, trading precision for reduced memory usage. Must be less than vector's dimensionality. When left unset, the property is omitted from the VADD call and the vector is stored at its original dimensionality.
Outputs
added boolean
Whether the element was added
Raw VADD reply: true only when the element id did not previously exist in the vector set. False means the element already existed, whether or not its vector or attributes were changed by this call.