Skills knods
Build and modify Knods visual AI workflows using either the OpenClaw Gateway polling protocol or the Knods headless flows API. Use for Knods polling payloads with fields like messageId/message/history, or for direct flow discovery/execution tasks like listing flows, reading input schemas, starting runs, polling status, cancelling runs, and retrieving outputs programmatically.
git clone https://github.com/openclaw/skills
T=$(mktemp -d) && git clone --depth=1 https://github.com/openclaw/skills "$T" && mkdir -p ~/.claude/skills && cp -r "$T/skills/alesys/knods" ~/.claude/skills/openclaw-skills-knods && rm -rf "$T"
T=$(mktemp -d) && git clone --depth=1 https://github.com/openclaw/skills "$T" && mkdir -p ~/.openclaw/skills && cp -r "$T/skills/alesys/knods" ~/.openclaw/skills/openclaw-skills-knods && rm -rf "$T"
skills/alesys/knods/SKILL.mdKnods
Overview
Handle two Knods modes:
- Interactive canvas chat via the polling gateway
- Headless flow execution via the REST API
Use the polling bridge for Knods Iris/chat payloads. Use the headless API when the task is to discover a flow, inspect inputs, run it, wait, cancel, or fetch outputs programmatically.
Mode Selection
- Use polling gateway mode when input arrives as a Knods chat envelope with
,messageId
, andmessage
, and the response must stream back with optionalhistory
.[KNODS_ACTION]...[/KNODS_ACTION] - Use headless API mode when the user wants to:
- list flows
- search flows by name/description
- inspect a flow's input schema
- start a run
- poll until completion
- cancel a run
- retrieve outputs programmatically
Workflow
A. Polling Gateway Flow
- Parse incoming payload fields.
- Treat
as the primary request.message - Use
for continuity.history - On first turn in a conversation, expect prepended context in
describing node types and action rules. Always prefer the node catalog from this context over the defaults below.message - Use
to map all response chunks to the correct message.messageId
- Choose whether to emit a canvas action block.
- Use
for single-node additions.addNode - Use
for multi-node workflows or any request requiring edges.addFlow - If the user only asks a question, respond with normal text and no action block.
- Build strict action JSON.
- Wrap each action exactly as:
[KNODS_ACTION]{"action":"addNode","nodeType":"FluxImage"}[/KNODS_ACTION][KNODS_ACTION]{"action":"addFlow","nodes":[...],"edges":[...]}[/KNODS_ACTION]
- Use
(not"nodeType"
) in node objects. Do NOT include"type"
orposition
fields — Knods handles layout automatically.data - For
, ensure every edgeaddFlow
andsource
references an existing node id.target - Always end flows with an
node.Output - Never connect two generator nodes directly; route through
.Output - Use stable node IDs (for example
,n1
,n2
) so follow-up edits are easy.n3 - Avoid unknown keys in action JSON.
- Stream response back to Knods.
- Send assistant text as delta chunks to
for the same/respond
.messageId - Send
when complete.{"messageId":"...","done":true} - Keep first chunk quick to avoid timeout perception.
B. Headless API Flow
- Discover candidate flows.
- Run:
python3 {baseDir}/scripts/knods_headless.py list- or
python3 {baseDir}/scripts/knods_headless.py resolve --query "<text>"
- Inspect the selected flow.
- Run:
python3 {baseDir}/scripts/knods_headless.py get --flow-id "<flowId>"
- Read
and preserve everyinputs
exactly.nodeId
- Start a run.
- Build
as JSON array withinputs
,nodeId
, andcontent
.type - Run:
python3 {baseDir}/scripts/knods_headless.py run --flow-id "<flowId>" --inputs-json '[...]'
- Poll until terminal state.
- Prefer:
python3 {baseDir}/scripts/knods_headless.py wait --run-id "<runId>"
- Or use:
python3 {baseDir}/scripts/knods_headless.py run-wait --flow-id "<flowId>" --inputs-json '[...]'
- Handle result.
- On
, readcompletedoutputs - On
, surfacefailed
anderror.message
if presenterror.nodeId - On timeout, optionally cancel the run
Output Rules
- Return normal assistant text; do not wrap the full reply in a custom envelope.
- Include
inline only when a canvas mutation is intended.[KNODS_ACTION]...[/KNODS_ACTION] - Do not mention internal polling URLs/tokens in user-facing text.
- Keep action JSON valid and compact.
Node Catalog
IMPORTANT: Every generator node listed below has a built-in prompt textarea. Do NOT add a DocumentPanel before a single generator — just connect the generator directly to an Output. Only use DocumentPanel when one shared prompt feeds multiple generators in parallel.
When the first message includes a node catalog context, always use that list over these defaults. The context catalog is always more up-to-date.
Text Generators (output: text)
All text generators accept text + image input and have a built-in prompt textarea.
— OpenAI models. Best all-rounder.ChatGPT
— Anthropic models. Great for reasoning and creative writing.Claude
Image Generators (output: image)
All image generators have a built-in prompt textarea and accept optional image input for image-to-image editing.
— OpenAI. Best at following complex instructions and text rendering.GPTImage
— FLUX by Black Forest Labs. Industry-leading quality for portraits and artistic styles. Fast.FluxImage
— Google Gemini. Great for photorealistic images and concept art.ImagePrompt
— Lightning-fast (<2 seconds). Best for rapid prototyping.ZImageTurbo
— Alibaba Qwen. Strong at anime, illustrations, and Asian-inspired aesthetics.QwenImage
— ByteDance. Dreamy, surreal compositions. Good at text rendering in images.Seedream
— xAI. Text-to-image and image editing.GrokImage
Video Generators (output: video)
All video generators below have a built-in prompt textarea and support both text-to-video and image-to-video (connect an ImagePanel for image-to-video).
— Google Veo 3.1. Cinematic video up to 8s with native audio. Best overall quality.Veo3FalAI
— OpenAI Sora 2. Realistic motion and physics, up to 12s.Sora2Video
— Kling 2.6 Surreal Engine. Cinematic with audio, up to 10s.Kling26Video
— Kling 3.0. Latest generation, Standard/Pro quality, up to 10s.KlingO3Video
— Wan 2.6. Multi-shot videos, 720p/1080p, up to 15s.Wan26Video
— LTX-2 Pro. High-fidelity cinematic with synchronized audio.LTXVideo
— xAI. Video with native audio.GrokVideo
Special Video Node
— Character animation. REQUIRES two inputs: a VIDEO (motion reference) + an IMAGE (character to animate). Does NOT have a text prompt. Only use when user wants to animate a character image using motion from another video.WanAnimateVideo
Input/Container Nodes
— Upload or paste an image. Output: image. Use when user wants to provide a reference image or a starting frame for image-to-video.ImagePanel
— Editable text container. Output: text. Use ONLY when one shared prompt feeds multiple generators in parallel.DocumentPanel
— Displays generated results (text, image, video). REQUIRED at the end of every flow.Output
Flow Design Rules
- Every generator has a built-in prompt textarea. Never prepend a DocumentPanel to a single generator.
- Use DocumentPanel only for one shared prompt feeding multiple generators in parallel.
- Use ImagePanel when user wants to provide a reference image, a starting frame for video, or an image input for WanAnimateVideo.
- Always end flows with an Output node.
- Never connect two generators directly. Route through an Output node if chaining.
- Flows go left to right: inputs → generators → Output.
- Use EXACT PascalCase node names from the catalog. Do NOT invent node names.
- WanAnimateVideo is the only node that requires a video input. Only suggest it when the user specifically wants to animate a character image using motion from a video.
- Add
only when user intent clearly implies parameters.initialData - Build the smallest flow that satisfies the request.
Flow Examples
Single image generator (most common):
FluxImage → Output
Image from reference photo:
ImagePanel → GPTImage → Output
One prompt feeding two image generators:
DocumentPanel → FluxImage → Output DocumentPanel → GPTImage → Output
Text-to-video:
Veo3FalAI → Output
Image-to-video (animate a still image):
ImagePanel → Veo3FalAI → Output
Character animation from video motion (WanAnimateVideo needs both video + image):
ImagePanel → WanAnimateVideo → Output [video source] → WanAnimateVideo
Text generation:
ChatGPT → Output
Gateway Behavior Constraints
- Poll interval target: about 1-2 seconds.
- Message claim timeout: about 2 minutes.
- Always preserve
across all chunk posts for a turn.messageId - Gateway auth uses
token via query parametergw_...
; never require Supabase JWT in this flow.token
Runtime Operations
When running a persistent poller service/process:
- Support either configuration style:
already includesKNODS_BASE_URL/updates?token=...- or
points to connection base and token is supplied separately (KNODS_BASE_URL
)KNODS_GATEWAY_TOKEN
- Derive
from the same connection root as/respond
./updates - Log handled
values and transport errors for debugging.messageId
For headless API operations:
- Prefer
+KNODS_API_BASE_URLKNODS_API_KEY
should look likeKNODS_API_BASE_URLhttps://<instance>/api/v1
must haveKNODS_API_KEY
andknods:readknods:run- If the API base URL is omitted, the packaged client can derive it from the same host as
KNODS_BASE_URL
Packaged Runtime (required)
This skill ships the runtime bridge and installer:
scripts/knods_iris_bridge.pyscripts/knods_headless.pyscripts/install_local.sh
Install/deploy from the skill folder:
bash /home/rolf/.openclaw/skills/knods/scripts/install_local.sh
The installer deploys:
~/.openclaw/scripts/knods_iris_bridge.py~/.config/systemd/user/knods-iris-bridge.service
Then runs:
systemctl --user daemon-reloadsystemctl --user enable --now knods-iris-bridge.service
Environment Variables
Set these in
~/.openclaw/.env:
- Required for polling gateway mode:
KNODS_BASE_URL
- Required when
does not already includeKNODS_BASE_URL
:?token=...KNODS_GATEWAY_TOKEN
- Required for headless API mode:
KNODS_API_KEY
- Preferred for headless API mode:
KNODS_API_BASE_URL
- Optional:
(default:OPENCLAW_AGENT_ID
)iris
(default:OPENCLAW_BIN
onopenclaw
)PATH
Service Operations
- Status:
systemctl --user status knods-iris-bridge.service
- Restart:
systemctl --user restart knods-iris-bridge.service
- Logs:
journalctl --user -u knods-iris-bridge.service -f
Config Change Lifecycle (required)
After changing gateway URL/token env values, restart the running bridge process so it reloads config.
- Generic service form:
systemctl --user restart <knods-bridge-service>
- Generic process form:
- stop old process
- start poller again with updated env
Do not assume env changes are picked up live without restart.
Reference
- Read
for canonical polling endpoints, payload schemas, and action examples.references/protocol.md - Read
for the direct run/list/poll/cancel flow execution API.references/headless-api.md