Skip to content
Back to search

comfyui-skill-openclaw

Run registered ComfyUI workflows through the fast comfyui-skill CLI, and use the official local Comfy MCP for live template, node, model, validation, and orchestration capabilities. **Use this Skill when:** (1) The user requests to "generate an image", "draw a picture", or "execute a ComfyUI workflow". (2) The user has specific stylistic, character, or scene requirements for image generation. (3) The user asks you to import, register, sync, or configure saved ComfyUI workflows for later reuse.

Safety scan

A static text scan, not a guarantee. Select the badge to see what was scanned and every finding.

Checked today

Check it deeper on your machine

Its scripts were only partly scanned.

As a Claude Code plugin, install it and then ask Claude Code:

/plugin marketplace add keithmackay/mackayi/plugin install scanskillsafety@mackayiDo a deep scan of https://github.com/HuangYuChuh/ComfyUI_Skills_OpenClaw with scanskillsafety

Or from a terminal, clone it and run it:

git clone https://github.com/keithmackay/scanskillsafety-skill ~/.claude/skills/scanskillsafetynode ~/.claude/skills/scanskillsafety/cli.cjs --deep 'https://github.com/HuangYuChuh/ComfyUI_Skills_OpenClaw'

It checks the exact commit: every file, its packages against OSV (api.osv.dev), how it compares with this page's scan (findsafeskills.com receives the repository's address), and, if you agree, Claude reading every file with your own Claude subscription. It never runs the code.

Badge for your README
findsafeskills safety rating

Markdown

[![findsafeskills safety rating](/api/listings/huangyuchuh--comfyui-skills-openclaw/badge.svg)](/listings/huangyuchuh--comfyui-skills-openclaw)

HTML

<a href="/listings/huangyuchuh--comfyui-skills-openclaw"><img src="/api/listings/huangyuchuh--comfyui-skills-openclaw/badge.svg" alt="findsafeskills safety rating" /></a>

Install

i

Install instructions from the README

As written by the repo's author. findsafeskills has not verified these steps.

Get ComfyUI Skills running in a few minutes.

Before you start, make sure you have:

- Python 3.10+ - A running ComfyUI server - An exported workflow in ComfyUI API format if you want to test execution right away

1. Clone the project

Choose the directory that matches your agent environment.

<details> <summary><strong>For OpenClaw</strong></summary>

cd ~/.openclaw/workspace/skills
git clone https://github.com/HuangYuChuh/ComfyUI_Skills_OpenClaw.git comfyui-skill-openclaw
cd comfyui-skill-openclaw

</details>

<details> <summary><strong>For Claude Code</strong></summary>

cd ~/.claude/skills
git clone https://github.com/HuangYuChuh/ComfyUI_Skills_OpenClaw.git comfyui-skill
cd comfyui-skill

</details>

<details> <summary><strong>For Codex</strong></summary>

cd ~/.codex/skills
git clone https://github.com/HuangYuChuh/ComfyUI_Skills_OpenClaw.git comfyui-skill
cd comfyui-skill

</details>

<details> <summary><strong>For Hermes Agent</strong></summary>

cd ~/.hermes/skills/creative
git clone https://github.com/HuangYuChuh/ComfyUI_Skills_OpenClaw.git comfyui-skill-openclaw
cd comfyui-skill-openclaw

Or install via Hermes CLI (once the PR is merged):

hermes skills install comfyui-skill-openclaw

</details>

2. Create your local config

cp config.example.json config.json

3. Install the CLI

pipx install comfyui-skill-cli

Or:

pip install comfyui-skill-cli

If you already have the CLI installed, upgrade it with:

# If you installed it with pipx
pipx upgrade comfyui-skill-cli

# If you installed it with pip
python3 -m pip install -U comfyui-skill-cli

4. Verify the setup

comfyui-skill server status
comfyui-skill list

5. Import and run your first workflow

comfyui-skill workflow import /absolute/path/to/my-workflow.json
comfyui-skill deps check local/my-workflow
comfyui-skill run local/my-workflow --args '{"prompt": "a white cat"}'

For manual CLI imports, the recommended approach is to pass the workflow JSON as an absolute path. That avoids path ambiguity and keeps the storage model simple.

For example:

comfyui-skill workflow import /Users/yourname/Downloads/my-workflow.json

After import, the CLI stores the normalized workflow and schema under `data/<server_id>/<workflow_id>/`, for example `data/local/my-workflow/workflow.json` and `data/local/my-workflow/schema.json`.

This is also the formal layout used by the Web UI and by Agent/OpenClaw-driven imports:

data/<server_id>/<workflow_id>/
  workflow.json
  schema.json
  history/

At this point, the CLI will read your local `config.json`, discover available workflows, and execute them through your ComfyUI server.

If you prefer a visual setup and testing flow, see the [Web UI](#web-ui) section below.

What was scanned

The files the safety scan read, as written by the repository's author and shown as plain text. Lines with a finding are marked.

SKILL.md · Manifest · 213 lines

View this file on GitHub (read at the repository's current version: the scan did not record which commit it read)

This file has changed since it was scanned, so this is not exactly the text that was scanned, and no line is marked. The findings are listed with the safety scan above.

  1. ---
  2. name: comfyui-skill-openclaw
  3. description: |
  4. Run registered ComfyUI workflows through the fast comfyui-skill CLI, and use the official
  5. local Comfy MCP for live template, node, model, validation, and orchestration capabilities.
  6. **Use this Skill when:**
  7. (1) The user requests to "generate an image", "draw a picture", or "execute a ComfyUI workflow".
  8. (2) The user has specific stylistic, character, or scene requirements for image generation.
  9. (3) The user asks you to import, register, sync, or configure saved ComfyUI workflows for later reuse.
  10. license: Apache-2.0
  11. metadata:
  12. version: "1.1.0"
  13. platforms: [macos, linux, windows]
  14. prerequisites:
  15. commands: ["comfyui-skill"]
  16. env_vars: []
  17. requires:
  18. bins: ["comfyui-skill"]
  19. cliHelp: "comfyui-skill --help"
  20. hermes:
  21. tags: [image-generation, comfyui, ai-art, workflow, stable-diffusion, flux]
  22. related_skills: []
  23. ---
  24. # ComfyUI Agent SKILL
  25. > **Prerequisites**: Install the CLI: `pip install -U comfyui-skill-cli`. The official local Comfy MCP is optional and should be connected using the [official guide](https://docs.comfy.org/agent-tools/mcp#local-comfy-mcp-connection) when MCP capabilities are needed. All shell commands must run from this project's root directory (where this `SKILL.md` is located).
  26. >
  27. > [!IMPORTANT]
  28. > **Directory Sensitivity**: The CLI reads `config.json` and `data/` from the current directory.
  29. > You **MUST** `cd` into the project root before running any command.
  30. > **Symptom**: `list` returns `[]` or `server status` reports not found → you are in the wrong directory.
  31. ## Quick Decision
  32. - A matching registered workflow exists → use the **CLI Execution Flow (Step 1-4)**. This is the default for repeated, batch, and latency-sensitive work.
  33. - The request has no matching workflow, or requires live template/model/node discovery → use the **official local Comfy MCP**.
  34. - The user supplies a raw workflow that needs real environment validation → use MCP `validate_workflow`; use CLI `run --validate` for a registered workflow.
  35. - The user asks to install nodes, download models, restart, update, or switch versions → use MCP only after explaining the effect and getting confirmation.
  36. - User says "generate image / draw a picture" → first inspect registered workflows; if none fit, discover a current MCP template instead of guessing a model name.
  37. - User says "import workflow / add workflow" → `comfyui-skill --json workflow import <path>`
  38. - User says "img2img / use this image" → first `comfyui-skill --json upload <image>`, then execute
  39. - User says "inpainting / mask this area" → `comfyui-skill --json upload <mask> --mask`, then execute
  40. - User says "show previous results" → `comfyui-skill --json history list <id>`
  41. - User says "what failed / check job status" → `comfyui-skill --json jobs list --status failed`
  42. - User says "which server has more VRAM" → `comfyui-skill --json server stats --all`
  43. - User says "what nodes are available" → use MCP `nodes` for live ecosystem discovery; use `comfyui-skill --json nodes list` when only the CLI inventory is needed.
  44. - User says "dry run / test without executing" → `comfyui-skill --json run <id> --validate`
  45. - User says "open management UI" → `python3 ./ui/open_ui.py`
  46. ## Core Concepts
  47. - **Skill ID**: `<server_id>/<workflow_id>` (e.g., `local/txt2img`). If server is omitted, the default server is used.
  48. - **Schema**: Each workflow has a `schema.json` that maps business parameter names (e.g., `prompt`, `seed`) to internal ComfyUI node fields. Never expose node IDs to the user.
  49. - **Server**: One or more ComfyUI instances configured in `config.json`. Check health with `server status`.
  50. - **Two interfaces, one Skill**: CLI is the efficient execution path for known workflows. Official MCP is the adaptive path for discovering and orchestrating the current ComfyUI ecosystem. They share the same business intent and must not submit the same job twice.
  51. ## Official Local Comfy MCP
  52. When the Agent host exposes the official Comfy MCP tools, call those tools directly. Start every MCP flow with `server_info` and use the live tool schemas instead of assuming parameters or tool availability.
  53. When the host does not expose MCP tools but can run shell commands, use the included stdio bridge:
  54. ```bash
  55. python ./scripts/comfy_mcp.py probe
  56. python ./scripts/comfy_mcp.py tools
  57. python ./scripts/comfy_mcp.py call search_templates --arguments '{"query":"background removal"}'
  58. ```
  59. The bridge reads `mcp_command`, `mcp_args`, `mcp_python`, `mcp_cwd`, and `mcp_env` from the selected server in `config.json`. `probe` and `tools` are read-only. A `call` has the side effects of the named official tool.
  60. Read [references/comfy-mcp.md](./references/comfy-mcp.md) when the request needs MCP discovery, raw-workflow validation, template adaptation, job management, installation, lifecycle control, or partner models.
  61. Routing invariants:
  62. - Prefer CLI for a known `<server_id>/<workflow_id>`; MCP is not a mandatory extra hop.
  63. - Prefer MCP when the answer depends on the currently installed templates, nodes, models, hardware, or official tool contract.
  64. - For long MCP runs: `run_workflow(wait=false)` or `run_template(wait=false)` -> `job(action="wait"|"status")` -> `fetch_outputs`.
  65. - Once either path returns a `prompt_id`, continue polling that path. Never fall back by submitting again.
  66. - Never set `confirm_spend=true` without the user's explicit approval for that paid call.
  67. ## Command Reference
  68. | Command | Purpose |
  69. |---------|---------|
  70. | `comfyui-skill --json server status` | Check if ComfyUI server is online |
  71. | `comfyui-skill --json server stats` | Show VRAM, RAM, GPU, versions (`--all` for multi-server) |
  72. | `comfyui-skill --json list` | List all available workflows and parameters |
  73. | `comfyui-skill --json info <id>` | Show workflow details and parameter schema |
  74. | `comfyui-skill --json submit <id> --args '{...}'` | Submit a workflow (non-blocking) |
  75. | `comfyui-skill --json status <prompt_id>` | Check execution status |
  76. | `comfyui-skill --json run <id> --args '{...}'` | Execute a workflow (blocking, real-time streaming) |
  77. | `comfyui-skill --json run <id> --validate` | Validate workflow without executing |
  78. | `comfyui-skill --json upload <path>` | Upload image to ComfyUI (for img2img workflows) |
  79. | `comfyui-skill --json upload <path> --mask` | Upload mask image (for inpainting workflows) |
  80. | `comfyui-skill --json nodes list` | List all available ComfyUI nodes |
  81. | `comfyui-skill --json jobs list` | List server-side job history (`--status failed` to filter) |
  82. | `comfyui-skill --json deps check <id>` | Check missing dependencies |
  83. | `comfyui-skill --json deps install <id> --repos '[...]'` | Install missing custom nodes |
  84. | `comfyui-skill --json workflow import <path>` | Import workflow (auto-detect, warns about deprecated nodes) |
  85. | `comfyui-skill --json history list <id>` | List execution history for a workflow |
  86. ---
  87. ## Execution Flow
  88. ### Step 1: Query Available Workflows
  89. ```bash
  90. comfyui-skill --json list
  91. ```
  92. Returns a JSON array of all enabled workflows with their parameters.
  93. - `required: true` parameters → **ask the user** if not provided.
  94. - `required: false` parameters → infer from context (e.g., `seed` = random number), or omit.
  95. - Never expose node IDs; only use business parameter names (e.g., prompt, style).
  96. - If multiple workflows match, pick the most relevant one or list candidates.
  97. ### Step 2: Parameter Assembly
  98. Assemble parameters into a JSON string. Example:
  99. ```
  100. {"prompt": "A beautiful landscape, high quality, masterpiece", "seed": 40128491}
  101. ```
  102. If critical parameters are missing, ask the user (e.g., "What visual style would you like?").
  103. ### Step 3: Pre-flight Dependency Check
  104. **Always** run before first execution of a workflow:
  105. ```bash
  106. comfyui-skill --json deps check <server_id>/<workflow_id>
  107. ```
  108. - If `is_ready` is `true` → proceed to Step 4.
  109. - If `is_ready` is `false`:
  110. 1. Present missing nodes and models to the user.
  111. 2. If user agrees to install, run:
  112. ```bash
  113. comfyui-skill --json deps install <id> --repos '["https://github.com/repo1"]'
  114. ```
  115. Use `source_repo` URLs from the check report as `--repos` values.
  116. 3. If `needs_restart` is `true`, inform the user to restart ComfyUI, then re-check.
  117. 4. Missing models must be downloaded manually — tell the user which folder to place them in (e.g., `checkpoints`).
  118. ### Step 4: Execute the Workflow
  119. > **Note**: JSON args must be wrapped in single quotes to prevent bash from parsing double quotes.
  120. Choose the execution mode based on your environment:
  121. #### Interactive mode: `submit` + `status` (recommended for chat)
  122. **Step 4a — Submit:**
  123. ```bash
  124. comfyui-skill --json submit <id> --args '{"prompt": "..."}'
  125. ```
  126. Returns: `{"status": "submitted", "prompt_id": "..."}`. Tell the user generation has started.
  127. **Step 4b — Poll:**
  128. ```bash
  129. comfyui-skill --json status <prompt_id>
  130. ```
  131. Status values: `queued` (with `position`) → `running` → `success` (with `outputs`) or `error`.
  132. **Polling pattern — critical for real-time feedback:**
  133. Each `status` call must be a **separate tool invocation** (a separate bash command). Do NOT write a shell loop. The correct pattern is:
  134. 1. Run `status` as a standalone bash command.
  135. 2. Read the returned JSON.
  136. 3. If `queued` or `running`: **send a text message to the user** with progress, then run `status` again.
  137. 4. If `success`: proceed to Step 5.
  138. 5. If `error`: report the error.
  139. #### Non-interactive mode: one-shot blocking (for scripts/CI)
  140. ```bash
  141. comfyui-skill --json run <id> --args '{"prompt": "..."}'
  142. ```
  143. Blocks until finished. Returns the same result format as `status` with `success`.
  144. ### Step 5: Present Results
  145. On success, the result contains an `outputs` array with file references (`filename`, `subfolder`, `type`).
  146. Use your native capabilities to present the files to the user (e.g., image preview, file path).
  147. ---
  148. ## Workflow Import
  149. When the user wants to add new workflows (not execute existing ones):
  150. ```bash
  151. comfyui-skill --json workflow import <json_path>
  152. ```
  153. - Supports both API format and editor format (auto-detected, auto-converted).
  154. - Automatically generates `schema.json` with smart parameter extraction.
  155. - After import, check dependencies before first execution.
  156. For bulk import from ComfyUI server or local folders, see [`references/workflow-import.md`](./references/workflow-import.md).
  157. ## Troubleshooting
  158. 1. **ComfyUI Offline**: Run `comfyui-skill --json server status`. If offline, ask the user to start ComfyUI.
  159. 2. **Workflow Not Found**: Run `comfyui-skill --json list` to see available workflows. If missing, the user needs to import it first.
  160. 3. **Parameter Format Error**: Ensure `--args` is valid JSON wrapped in single quotes.
  161. 4. **Cloud Node Unauthorized**: Workflow uses cloud API nodes (Kling, Sora, etc.). Guide user to: (1) Generate an API Key at https://platform.comfy.org, (2) Open Web UI → Server Settings → fill in "ComfyUI API Key".
README.md · README · 459 lines

View this file on GitHub (read at the repository's current version: the scan did not record which commit it read)

This file has changed since it was scanned, so this is not exactly the text that was scanned, and no line is marked. The findings are listed with the safety scan above.

  1. <div align="center">
  2. <img src="./asset/banner.png" alt="ComfyUI Skills Banner">
  3. <h1>ComfyUI Skills for OpenClaw</h1>
  4. <p><strong>Agent-friendly ComfyUI workflow skills for OpenClaw, Hermes Agent, Codex, Claude Code, and other agents.</strong></p>
  5. <p>
  6. Use this project to turn ComfyUI workflows into callable skills with an agent-friendly CLI as the primary interface,
  7. plus a visual Web UI for easier configuration and testing.
  8. </p>
  9. <p>
  10. <a href="https://huangyuchuh.github.io/ComfyUI_Skills_OpenClaw/"><img src="https://img.shields.io/badge/docs-GitHub_Pages-4F46E5?style=flat&logo=gitbook&logoColor=white" alt="Docs"></a>
  11. <a href="https://github.com/HuangYuChuh/ComfyUI_Skills_OpenClaw/blob/main/LICENSE"><img src="https://img.shields.io/github/license/HuangYuChuh/ComfyUI_Skills_OpenClaw?style=flat&color=10B981&logo=data%3Aimage/svg%2Bxml%3Bbase64%2CPHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAyNCAyNCIgZmlsbD0ibm9uZSIgc3Ryb2tlPSJ3aGl0ZSIgc3Ryb2tlLXdpZHRoPSIyIiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiPjxwYXRoIGQ9Im0xNiAxNiAzLTggMyA4Yy0uODcuNjUtMS45MiAxLTMgMXMtMi4xMy0uMzUtMy0xWiIvPjxwYXRoIGQ9Im0yIDE2IDMtOCAzIDhjLS44Ny42NS0xLjkyIDEtMyAxcy0yLjEzLS4zNS0zLTFaIi8%2BPHBhdGggZD0iTTcgMjFoMTAiLz48cGF0aCBkPSJNMTIgM3YxOCIvPjxwYXRoIGQ9Ik0zIDdoMmMyIDAgNS0xIDctMiAyIDEgNSAyIDcgMmgyIi8%2BPC9zdmc%2B" alt="License"></a>
  12. <a href="https://github.com/HuangYuChuh/ComfyUI_Skills_OpenClaw/stargazers"><img src="https://img.shields.io/github/stars/HuangYuChuh/ComfyUI_Skills_OpenClaw?style=flat&color=EAB308&logo=github" alt="GitHub stars"></a>
  13. <a href="https://github.com/HuangYuChuh/ComfyUI_Skills_OpenClaw/network/members"><img src="https://img.shields.io/github/forks/HuangYuChuh/ComfyUI_Skills_OpenClaw?style=flat&color=F97316&logo=github" alt="GitHub forks"></a>
  14. <a href="https://www.python.org/"><img src="https://img.shields.io/static/v1?label=Python&message=3.10%2B&color=3B82F6&style=flat&logo=python&logoColor=white" alt="Python 3.10+"></a>
  15. <a href="https://github.com/NousResearch/hermes-agent"><img src="https://img.shields.io/static/v1?label=Hermes%20Agent&message=compatible&color=8B5CF6&style=flat&logo=data%3Aimage/svg%2Bxml%3Bbase64%2CPHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAyNCAyNCIgZmlsbD0ibm9uZSIgc3Ryb2tlPSJ3aGl0ZSIgc3Ryb2tlLXdpZHRoPSIyIj48cGF0aCBkPSJNMTIgMmExMCAxMCAwIDEgMCAwIDIwIDEwIDEwIDAgMCAwIDAtMjBaIi8%2BPHBhdGggZD0iTTggMTRzMS41IDIgNCAyczQtMiA0LTIiLz48L3N2Zz4%3D&logoColor=white" alt="Hermes Agent Compatible"></a>
  16. <a href="https://agentskills.io"><img src="https://img.shields.io/static/v1?label=agentskills.io&message=standard&color=06B6D4&style=flat" alt="agentskills.io standard"></a>
  17. </p>
  18. <p>
  19. <a href="https://www.bilibili.com/video/BV1a6cUzVEE6/">🎬 Demo Video</a> ·
  20. <a href="https://huangyuchuh.github.io/ComfyUI_Skills_OpenClaw/">📘 Docs</a> ·
  21. <a href="#quick-start">🧭 Quick Start</a> ·
  22. <a href="#cli">⌨️ CLI</a> ·
  23. <a href="#web-ui">🖥️ Web UI</a> ·
  24. <a href="#multi-server-management">🛰️ Multi-Server</a>
  25. </p>
  26. <p>
  27. <strong>English</strong> ·
  28. <a href="./README.zh-CN.md">简体中文</a> ·
  29. <a href="./README.zh-TW.md">繁體中文</a> ·
  30. <a href="./README.ja.md">日本語</a> ·
  31. <a href="./README.ko.md">한국어</a> ·
  32. <a href="./README.es.md">Español</a>
  33. </p>
  34. </div>
  35. ---
  36. ## Overview
  37. ComfyUI Skills for OpenClaw is an agent-friendly bridge that turns ComfyUI workflows into callable skills for AI agents.
  38. Instead of asking an agent to manipulate raw ComfyUI graphs, this project gives each workflow a clean, controlled interface through a CLI and schema-based parameter mapping. It works with OpenClaw, Hermes Agent, Codex, Claude Code, and any agent that can run shell commands. Compatible with the [agentskills.io](https://agentskills.io) open standard.
  39. Use it when you want to import existing ComfyUI workflows, expose only the parameters that matter, run them from chat or agent tasks, and manage everything through one consistent workflow layer.
  40. | Best for | What you get |
  41. |----------|--------------|
  42. | OpenClaw, Codex, Claude Code, and Hermes Agent users | A ComfyUI workflow layer that agents can call safely |
  43. | Existing ComfyUI workflow owners | A clean way to reuse exported workflows without exposing the full graph |
  44. | Multi-machine setups | One namespace for local and remote ComfyUI servers |
  45. | Users who want visual setup and testing | An optional Web UI for configuring, previewing, and validating workflows before agents use them |
  46. ## Features
  47. | Capability | Why it matters |
  48. |------------|----------------|
  49. | **Agent-friendly CLI** | Designed for agents, not just humans. It provides a cleaner and more reliable interface than working directly with raw ComfyUI graphs or lower-level ComfyUI interaction patterns. |
  50. | **Schema-based parameter mapping** | Expose only the fields you want the agent to control, with clear aliases, types, and descriptions. |
  51. | **ComfyUI workflow import** | Import workflow JSON files, auto-detect formats, and generate the mapping layer needed for agent use. |
  52. | **Multi-server routing** | Manage local and remote ComfyUI servers under one namespace and route jobs to the right machine. |
  53. | **Dependency management** | Check missing nodes and models before execution and install supported dependencies through the CLI. |
  54. | **Official local Comfy MCP** | Use the official runtime interface for live template, node, and model discovery, raw-workflow validation, and advanced orchestration while keeping CLI execution fast. |
  55. | **Optional Web UI** | A visual layer for configuration and testing. It does not replace the CLI, and agent-facing actions still map to the same CLI workflow. |
  56. ## CLI And Official Local Comfy MCP
  57. This Skill treats CLI and MCP as two tools for different jobs, not as replacements for each other:
  58. - Use `comfyui-skill` for registered workflows, repeated execution, batch jobs, uploads, and history.
  59. - Use the official local Comfy MCP when the Agent needs to discover current templates, nodes, or models, validate a raw workflow, adapt a template, or manage the local ComfyUI lifecycle.
  60. If the Agent host already exposes the official MCP tools, the Skill calls them directly. A shell-only host can use the included bridge:
  61. ```bash
  62. python ./scripts/comfy_mcp.py probe
  63. python ./scripts/comfy_mcp.py call search_templates --arguments '{"query":"upscale"}'
  64. ```
  65. See [Official Local Comfy MCP Integration](https://huangyuchuh.github.io/ComfyUI_Skills_OpenClaw/comfy-mcp-application-layer/) for setup, routing, and safety boundaries.
  66. <a id="quick-start"></a>
  67. ## Quick Start
  68. Get ComfyUI Skills running in a few minutes.
  69. Before you start, make sure you have:
  70. - Python 3.10+
  71. - A running ComfyUI server
  72. - An exported workflow in ComfyUI API format if you want to test execution right away
  73. ### 1. Clone the project
  74. Choose the directory that matches your agent environment.
  75. <details>
  76. <summary><strong>For OpenClaw</strong></summary>
  77. ```bash
  78. cd ~/.openclaw/workspace/skills
  79. git clone https://github.com/HuangYuChuh/ComfyUI_Skills_OpenClaw.git comfyui-skill-openclaw
  80. cd comfyui-skill-openclaw
  81. ```
  82. </details>
  83. <details>
  84. <summary><strong>For Claude Code</strong></summary>
  85. ```bash
  86. cd ~/.claude/skills
  87. git clone https://github.com/HuangYuChuh/ComfyUI_Skills_OpenClaw.git comfyui-skill
  88. cd comfyui-skill
  89. ```
  90. </details>
  91. <details>
  92. <summary><strong>For Codex</strong></summary>
  93. ```bash
  94. cd ~/.codex/skills
  95. git clone https://github.com/HuangYuChuh/ComfyUI_Skills_OpenClaw.git comfyui-skill
  96. cd comfyui-skill
  97. ```
  98. </details>
  99. <details>
  100. <summary><strong>For Hermes Agent</strong></summary>
  101. ```bash
  102. cd ~/.hermes/skills/creative
  103. git clone https://github.com/HuangYuChuh/ComfyUI_Skills_OpenClaw.git comfyui-skill-openclaw
  104. cd comfyui-skill-openclaw
  105. ```
  106. Or install via Hermes CLI (once the PR is merged):
  107. ```bash
  108. hermes skills install comfyui-skill-openclaw
  109. ```
  110. </details>
  111. ### 2. Create your local config
  112. ```bash
  113. cp config.example.json config.json
  114. ```
  115. ### 3. Install the CLI
  116. ```bash
  117. pipx install comfyui-skill-cli
  118. ```
  119. Or:
  120. ```bash
  121. pip install comfyui-skill-cli
  122. ```
  123. If you already have the CLI installed, upgrade it with:
  124. ```bash
  125. # If you installed it with pipx
  126. pipx upgrade comfyui-skill-cli
  127. # If you installed it with pip
  128. python3 -m pip install -U comfyui-skill-cli
  129. ```
  130. ### 4. Verify the setup
  131. ```bash
  132. comfyui-skill server status
  133. comfyui-skill list
  134. ```
  135. ### 5. Import and run your first workflow
  136. ```bash
  137. comfyui-skill workflow import /absolute/path/to/my-workflow.json
  138. comfyui-skill deps check local/my-workflow
  139. comfyui-skill run local/my-workflow --args '{"prompt": "a white cat"}'
  140. ```
  141. For manual CLI imports, the recommended approach is to pass the workflow JSON as an absolute path. That avoids path ambiguity and keeps the storage model simple.
  142. For example:
  143. ```bash
  144. comfyui-skill workflow import /Users/yourname/Downloads/my-workflow.json
  145. ```
  146. After import, the CLI stores the normalized workflow and schema under `data/<server_id>/<workflow_id>/`, for example `data/local/my-workflow/workflow.json` and `data/local/my-workflow/schema.json`.
  147. This is also the formal layout used by the Web UI and by Agent/OpenClaw-driven imports:
  148. ```bash
  149. data/<server_id>/<workflow_id>/
  150. workflow.json
  151. schema.json
  152. history/
  153. ```
  154. At this point, the CLI will read your local `config.json`, discover available workflows, and execute them through your ComfyUI server.
  155. If you prefer a visual setup and testing flow, see the [Web UI](#web-ui) section below.
  156. ## Setup Options
  157. Choose the path that matches how you want to use the project.
  158. ### OpenClaw
  159. Use this path if you want OpenClaw to discover and execute ComfyUI workflows as skills.
  160. - Clone the repository into `~/.openclaw/workspace/skills`
  161. - Install `comfyui-skill-cli`
  162. - Configure `config.json`
  163. - Import workflows and expose agent-safe parameters
  164. ### Codex or Claude Code
  165. Use this path if you want coding agents to call ComfyUI workflows through shell commands.
  166. - Clone the repository into your agent skills directory
  167. - Install the CLI
  168. - Verify with `comfyui-skill list`
  169. - Execute workflows with structured `--args`
  170. ### Web UI
  171. Use this path if you want a visual interface for configuration, inspection, and testing. See the [Web UI](#web-ui) section below for launch instructions and details.
  172. ### Manual Setup
  173. Use this path if you want direct control over `config.json`, `workflow.json`, and `schema.json`.
  174. <details>
  175. <summary><strong>Expand for manual config file setup</strong></summary>
  176. #### 1) Edit `config.json`
  177. ```jsonc
  178. {
  179. "servers": [
  180. {
  181. "id": "local",
  182. "name": "Local",
  183. "url": "http://127.0.0.1:8188",
  184. "enabled": true,
  185. "output_dir": "./outputs"
  186. }
  187. ],
  188. "default_server": "local"
  189. }
  190. ```
  191. #### 2) Place workflow files
  192. ```text
  193. data/local/my-workflow/
  194. workflow.json # ComfyUI API-format export
  195. schema.json # Parameter mapping
  196. ```
  197. #### 3) Write `schema.json`
  198. ```jsonc
  199. {
  200. "description": "My workflow",
  201. "enabled": true,
  202. "parameters": {
  203. "prompt": {
  204. "node_id": 10,
  205. "field": "prompt",
  206. "required": true,
  207. "type": "string",
  208. "description": "Prompt text"
  209. }
  210. }
  211. }
  212. ```
  213. </details>
  214. <a id="cli"></a>
  215. ## Common Commands
  216. Beyond the commands shown in [Quick Start](#quick-start), here are additional operations you may need:
  217. ### Inspect a workflow
  218. ```bash
  219. comfyui-skill info local/txt2img
  220. ```
  221. ### Submit a workflow asynchronously
  222. ```bash
  223. comfyui-skill submit local/txt2img --args '{"prompt": "a white cat"}'
  224. comfyui-skill status <prompt_id>
  225. ```
  226. ### Manage servers
  227. ```bash
  228. comfyui-skill server list
  229. comfyui-skill server add --id remote --url http://10.0.0.1:8188
  230. ```
  231. For the full CLI reference, run `comfyui-skill --help` or see [ComfyUI Skill CLI](https://github.com/HuangYuChuh/ComfyUI_Skill_CLI).
  232. ## Workflow Requirements
  233. To work reliably with this project, each workflow should meet these requirements.
  234. - The workflow must be exported from ComfyUI in API format.
  235. - The workflow should include an output node such as `Save Image`.
  236. - The workflow needs a `schema.json` mapping so the agent can work with a clean parameter interface.
  237. - The target ComfyUI server must have the required custom nodes and models installed.
  238. If you use `comfyui-skill workflow import`, the CLI can help generate the required mapping and check dependencies before execution.
  239. <a id="multi-server-management"></a>
  240. ## Multi-Server Management
  241. This project is designed to work with more than one ComfyUI server.
  242. You can keep multiple local or remote ComfyUI instances under one configuration and route workflows by namespace. This is useful when different machines serve different purposes, such as lightweight local testing, larger GPU jobs, or model-specific environments.
  243. Examples:
  244. ```bash
  245. comfyui-skill server add --id local --url http://127.0.0.1:8188
  246. comfyui-skill server add --id remote-a100 --url http://10.0.0.20:8188
  247. comfyui-skill server list
  248. ```
  249. Workflows are addressed with the format:
  250. ```text
  251. <server_id>/<workflow_id>
  252. ```
  253. For example:
  254. ```text
  255. local/txt2img
  256. remote-a100/sdxl-base
  257. ```
  258. Both servers and workflows support enable and disable switches, so agents only see workflows that are currently available.
  259. You can also move settings between machines with:
  260. ```bash
  261. comfyui-skill config export --output ./backup.json
  262. comfyui-skill config import ./backup.json --dry-run
  263. comfyui-skill config import ./backup.json
  264. ```
  265. <a id="web-ui"></a>
  266. ## Web UI
  267. A local web interface is available for visual configuration and testing. It is optional, and it exists to make setup, inspection, and validation easier. The skill itself is still designed for agents to use through the CLI.
  268. ### Launch
  269. ```bash
  270. ./ui/run_ui.sh # macOS/Linux
  271. # or: ui\run_ui.bat # Windows
  272. ```
  273. The launch scripts create a project `.venv` when needed and install UI dependencies into that virtual environment. No global Web UI dependency install is required.
  274. Visit `http://localhost:18189`.
  275. ### What you can do in the Web UI
  276. - Upload workflows exported from ComfyUI
  277. - Configure parameter mappings with a visual editor
  278. - Manage multiple servers and workflows in one place
  279. - Search, reorder, and inspect workflow definitions
  280. - Test and validate workflow configuration before handing it off to agents
  281. - Use the interface in English, Simplified Chinese, or Traditional Chinese
  282. Everything the Web UI configures maps back to the same underlying CLI-driven workflow. It is a visual companion for setup and testing, not a separate execution model.
  283. Frontend source lives in a [separate repository](https://github.com/HuangYuChuh/ComfyUI_Skills_OpenClaw-frontend).
  284. ## Common Issues
  285. ### HTTP 400 on `/prompt`
  286. The workflow payload or one of the injected parameter values is invalid.
  287. Check:
  288. - Whether the workflow was exported in API format
  289. - Whether the schema mapping points to the correct node and field
  290. - Whether the provided argument types match the schema
  291. ### No images returned
  292. The workflow may be missing a valid output node such as `Save Image`.
  293. ### Connection failed
  294. Check that:
  295. - The ComfyUI server is running
  296. - The server URL in `config.json` is correct
  297. - The selected server is enabled
  298. ### Missing nodes or models
  299. Run:
  300. ```bash
  301. comfyui-skill deps check <workflow_id>
  302. ```
  303. Then install supported dependencies if needed.
  304. ## Changelog
  305. Recent highlights:
  306. - **v0.4.0**: Migrated to [CLI-first architecture](https://github.com/HuangYuChuh/ComfyUI_Skill_CLI) — all workflow operations (`run`, `submit`, `status`, `import`, `deps`) now go through a standalone CLI tool; legacy Python scripts have been removed.
  307. - **v0.3.1**: Added ComfyUI API Key support for cloud API nodes such as Kling, Sora, and Nano Banana.
  308. - **v0.3.0**: Added dependency check and install, non-blocking `submit` and `status`, image upload, import preview, and execution history.
  309. See [CHANGELOG.md](./CHANGELOG.md) for the full release history.
  310. ## Contributing
  311. Contributions are welcome! Please read [CONTRIBUTING.md](./CONTRIBUTING.md) before submitting a PR.
  312. ## Resources
  313. - [English README](./README.md)
  314. - [简体中文 README](./README.zh-CN.md)
  315. - [繁體中文 README](./README.zh-TW.md)
  316. - [日本語 README](./README.ja.md)
  317. - [한국어 README](./README.ko.md)
  318. - [Español README](./README.es.md)
  319. - [ComfyUI Skill CLI](https://github.com/HuangYuChuh/ComfyUI_Skill_CLI)
  320. - [Frontend Repository](https://github.com/HuangYuChuh/ComfyUI_Skills_OpenClaw-frontend)
  321. - [Hermes Agent](https://github.com/NousResearch/hermes-agent) — compatible AI agent platform
  322. - [agentskills.io](https://agentskills.io) — open skill format standard

Ratings and comments

Sign in to rate this skill.

Sign in

Free to use. If it’s helped, pass it on.