Generate Embeddings
Converts text into high-dimensional vector embeddings.
Turns one text into an embedding vector through an embedding-capable provider record. Partial: on success it leaves through out, which is not a declared port.
Embeddings capture the semantic meaning of text as a list of numbers (vectors). These vectors are essential for semantic search, clustering, and RAG (Retrieval Augmented Generation) workflows.
Use Cases:
- Semantic Search: Preparing data for vector database storage.
- Clustering: Grouping similar support tickets.
- Classification: Feeding downstream ML models.
How it works
- Takes the text from the upstream payload:
$json.input, else$json.text. ThrowsMissing 'input'when neither is set. - Sends one embedding request through the backend with
llm_provider_id. - Returns
{ embeddings, raw }with no port, so the engine routes it toout.embeddingsis the single vector (array of numbers), ornullif the backend answer had none.
In a workflow
The node as it appears in a workflow file (draft_nodes[]), and the envelope of a successful run.
{
"node_id": "node-embed-chunk",
"label": "Embed chunk",
"operator_slug": "ai.embed",
"operator_version": "1.0.0",
"config": {
"llm_provider_id": "wf-llm-provider-xxxx",
"timeout_ms": 30000
}
}{
"ok": true,
"data": {
"embeddings": [
0.0123,
-0.0456,
0.0789,
0.0012
],
"raw": null
},
"port": "out"
}Configuration
-
llm_provider_idstring Required -
The `id` of a `LlmProviderModel` record configured for embeddings (e.g. `wf-llm-provider-*`). The orchestrator delegates to the backend endpoint `POST /cognitive-infrastructure/cognitive-assets/llm-provider/invoke` (operation: embedding). Embedding is sync-only — streaming does not apply. Managed in the webapp at `/cognitive-assets/llm-provider/*`.
-
timeout_msinteger Optional -
Maximum time to wait for the embedding call to complete. Default 30000.
Its configuration shows the shared execution settings, but this node does not apply retries (retryOnFail, maxTries) yet. continueOnFail is not applied by any node.
Behaviour in the code
What the implementation does with these keys beyond what the schema says.
-
input - Cannot be set on the node: the runtime replaces any configured
inputwith the upstream payload. Shape the previous node's output so that$json.inputor$json.textholds the string, e.g. withdata.transform. -
timeout_ms - Passed to the client but not applied to the HTTP request; the platform's default request timeout governs.
-
execution - Declared but ignored: neither the worker nor the engine reads
retryOnFail,maxTries,waitBetweenTries,continueOnFail,alwaysOutputDataortimeout_msfrom this block.
Output ports
success default Declared but never emitted. On success the engine follows out; an edge drawn from success never fires. The data shown is what out carries.
{
"embeddings": [
0.0123,
-0.0456,
0.0789,
0.0012
],
"raw": null
}error No text was found, the input was not a string or the embedding call failed.
{
"error": "Missing 'input'"
}In expressions
What a later node can read from this node's output with $("Generate Embeddings").item.json.<path> (write your node's label instead of Generate Embeddings). Editor marks the paths the workflow editor suggests under Previous Nodes (the output contract); Worker marks the paths the worker really returns through success, from the output shown in Ports.
| Expression | Editor | Worker |
|---|---|---|
$("Generate Embeddings").item.json.embeddingsVector(s) representing the input text. | ||
$("Generate Embeddings").item.json.raw | — |
— Worker: The worker returns it but the editor does not suggest it: write it by hand. Keys inside objects can depend on your data or configuration (for example one key per label).
Errors
| Message | Port | Cause and fix |
|---|---|---|
Missing 'input' | error | The upstream payload has neither input nor text. A value configured on the node is not used (see config). |
LlmInvocationClientService.invokeEmbedding: input (string) is required. | error | The text is not a string, for example an array of strings. Only one string per run is supported; use flow.split for lists. |
[AiEmbed] Missing 'llm_provider_id' in node config (LlmProviderModel.id, e.g. 'wf-llm-provider-*'). The legacy 'model_id' alias is no longer supported — update the node config to use 'llm_provider_id'. | error | llm_provider_id is empty or not a string. Pick a provider record with embedding capability. |
LLM Invocation Error (embedding): <backend message> | error | The backend rejected the call (unknown provider record, provider without embeddings, provider error). An HTTP failure shows LLM Invocation Error (embedding): empty response from backend (<transport error>). |
Input contract
-
inputstring | array Required -
Text string or array of strings to embed.
Output contract
-
embeddingsarray<number> Optional -
Vector(s) representing the input text.
Contracts (JSON Schema)
The definition exactly as the orchestrator declares it. All is the whole *.definition.js; compare it with the sections above to spot differences between the documentation and the schema. Use it to validate a node before you publish.
{
"slug": "ai.embed",
"name": "Generate Embeddings",
"category": "ai",
"version": "1.0.0",
"description": "Converts text into high-dimensional vector embeddings.\n\n Embeddings capture the semantic meaning of text as a list of numbers (vectors). These vectors are essential for semantic search, clustering, and RAG (Retrieval Augmented Generation) workflows.\n\n **Use Cases:**\n - **Semantic Search:** Preparing data for vector database storage.\n - **Clustering:** Grouping similar support tickets.\n - **Classification:** Feeding downstream ML models.",
"capabilities": [
"llm",
"embeddings",
"vector",
"nlp"
],
"config_schema": {
"type": "object",
"required": [
"llm_provider_id"
],
"properties": {
"llm_provider_id": {
"type": "string",
"title": "LLM Provider (Embedding)",
"description": "The `id` of a `LlmProviderModel` record configured for embeddings (e.g. `wf-llm-provider-*`). The orchestrator delegates to the backend endpoint `POST /cognitive-infrastructure/cognitive-assets/llm-provider/invoke` (operation: embedding). Embedding is sync-only — streaming does not apply. Managed in the webapp at `/cognitive-assets/llm-provider/*`.",
"x-ui-widget": "llm-provider-picker",
"x-llm-provider-capabilities": [
"embedding"
]
},
"timeout_ms": {
"type": "integer",
"title": "Timeout (ms)",
"description": "Maximum time to wait for the embedding call to complete. Default 30000.",
"minimum": 1000
},
"execution": {
"type": "object",
"title": "Execution Settings",
"properties": {
"alwaysOutputData": {
"type": "boolean",
"title": "Always Output Data",
"description": "Always output data, even on error (if configured).",
"default": false
},
"retryOnFail": {
"type": "boolean",
"title": "Retry On Fail",
"description": "Retry the execution if it fails.",
"default": false
},
"maxTries": {
"type": "integer",
"title": "Max Retries",
"description": "Number of retries.",
"default": 3,
"displayOptions": {
"show": {
"retryOnFail": [
true
]
}
}
},
"waitBetweenTries": {
"type": "integer",
"title": "Wait Between Retries (ms)",
"default": 1000,
"displayOptions": {
"show": {
"retryOnFail": [
true
]
}
}
},
"continueOnFail": {
"type": "boolean",
"title": "Continue On Fail",
"description": "Do not crash workflow on error.",
"default": false
},
"timeout_ms": {
"type": "integer",
"title": "Timeout (ms)",
"description": "Max execution time for this node before it is killed, in milliseconds. Honored by long-running operators (e.g. OCR/extraction, inline code). Default 300000 (5 min).",
"default": 300000
}
}
}
}
},
"input_contract_schema": {
"type": "object",
"properties": {
"input": {
"type": [
"string",
"array"
],
"description": "Text string or array of strings to embed."
}
},
"required": [
"input"
]
},
"output_contract_schema": {
"type": "object",
"properties": {
"embeddings": {
"type": "array",
"items": {
"type": "number"
},
"description": "Vector(s) representing the input text."
}
}
},
"ports": [
{
"port_id": "success",
"label": "Success",
"is_default": true,
"description": "Embeddings generated."
},
{
"port_id": "error",
"label": "Error"
}
],
"execution_mode": "async",
"tags": [
"ai",
"vector",
"embedding"
],
"is_stateful": false,
"publisher": {
"identity": "org_sommatic_ai",
"profile": {
"name": "Sommatic AI",
"verified": true,
"url": "https://me.veripass.com/sommatic",
"logo_url": null
}
}
}{
"type": "object",
"required": [
"llm_provider_id"
],
"properties": {
"llm_provider_id": {
"type": "string",
"title": "LLM Provider (Embedding)",
"description": "The `id` of a `LlmProviderModel` record configured for embeddings (e.g. `wf-llm-provider-*`). The orchestrator delegates to the backend endpoint `POST /cognitive-infrastructure/cognitive-assets/llm-provider/invoke` (operation: embedding). Embedding is sync-only — streaming does not apply. Managed in the webapp at `/cognitive-assets/llm-provider/*`.",
"x-ui-widget": "llm-provider-picker",
"x-llm-provider-capabilities": [
"embedding"
]
},
"timeout_ms": {
"type": "integer",
"title": "Timeout (ms)",
"description": "Maximum time to wait for the embedding call to complete. Default 30000.",
"minimum": 1000
},
"execution": {
"type": "object",
"title": "Execution Settings",
"properties": {
"alwaysOutputData": {
"type": "boolean",
"title": "Always Output Data",
"description": "Always output data, even on error (if configured).",
"default": false
},
"retryOnFail": {
"type": "boolean",
"title": "Retry On Fail",
"description": "Retry the execution if it fails.",
"default": false
},
"maxTries": {
"type": "integer",
"title": "Max Retries",
"description": "Number of retries.",
"default": 3,
"displayOptions": {
"show": {
"retryOnFail": [
true
]
}
}
},
"waitBetweenTries": {
"type": "integer",
"title": "Wait Between Retries (ms)",
"default": 1000,
"displayOptions": {
"show": {
"retryOnFail": [
true
]
}
}
},
"continueOnFail": {
"type": "boolean",
"title": "Continue On Fail",
"description": "Do not crash workflow on error.",
"default": false
},
"timeout_ms": {
"type": "integer",
"title": "Timeout (ms)",
"description": "Max execution time for this node before it is killed, in milliseconds. Honored by long-running operators (e.g. OCR/extraction, inline code). Default 300000 (5 min).",
"default": 300000
}
}
}
}
}{
"type": "object",
"properties": {
"input": {
"type": [
"string",
"array"
],
"description": "Text string or array of strings to embed."
}
},
"required": [
"input"
]
}{
"type": "object",
"properties": {
"embeddings": {
"type": "array",
"items": {
"type": "number"
},
"description": "Vector(s) representing the input text."
}
}
}[
{
"port_id": "success",
"label": "Success",
"is_default": true,
"description": "Embeddings generated."
},
{
"port_id": "error",
"label": "Error"
}
]Execution
- Execution
async- Stateful
- No
- Retries (
retryOnFail) - No
- Capabilities
llmembeddingsvectornlp- Tags
aivectorembedding
Notes and limits
- Known defect: the success path returns no port, so the engine uses
out, which the node does not declare. Do not chain nodes after its success path until it is fixed. - The input contract allows an array, but only a single string works; the output is one vector, not a list of vectors.
- Embeddings are always synchronous;
invocation_modedoes not apply.rawis the provider's raw response when the backend returns it. - No automatic retries: the engine does not honour
execution.retryOnFail,maxTriesorwaitBetweenTriesfor this node; a failed call goes straight toerror.
Reviewed against the orchestrator code · 31e874b · 2026-11-26