comfyui-skill-cli 0.2.6__tar.gz → 0.2.7__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- comfyui_skill_cli-0.2.7/PKG-INFO +325 -0
- comfyui_skill_cli-0.2.7/README.md +294 -0
- comfyui_skill_cli-0.2.7/comfyui_skill_cli.egg-info/PKG-INFO +325 -0
- {comfyui_skill_cli-0.2.6 → comfyui_skill_cli-0.2.7}/comfyui_skill_cli.egg-info/SOURCES.txt +7 -0
- comfyui_skill_cli-0.2.7/comfyui_skill_cli.egg-info/requires.txt +7 -0
- {comfyui_skill_cli-0.2.6 → comfyui_skill_cli-0.2.7}/comfyui_skills_cli/client.py +136 -4
- {comfyui_skill_cli-0.2.6 → comfyui_skill_cli-0.2.7}/comfyui_skills_cli/commands/cancel.py +1 -0
- {comfyui_skill_cli-0.2.6 → comfyui_skill_cli-0.2.7}/comfyui_skills_cli/commands/free.py +1 -0
- comfyui_skill_cli-0.2.7/comfyui_skills_cli/commands/history.py +208 -0
- comfyui_skill_cli-0.2.7/comfyui_skills_cli/commands/logs.py +33 -0
- {comfyui_skill_cli-0.2.6 → comfyui_skill_cli-0.2.7}/comfyui_skills_cli/commands/models.py +5 -19
- comfyui_skill_cli-0.2.7/comfyui_skills_cli/commands/nodes.py +168 -0
- {comfyui_skill_cli-0.2.6 → comfyui_skill_cli-0.2.7}/comfyui_skills_cli/commands/queue.py +7 -21
- {comfyui_skill_cli-0.2.6 → comfyui_skill_cli-0.2.7}/comfyui_skills_cli/commands/run.py +150 -12
- {comfyui_skill_cli-0.2.6 → comfyui_skill_cli-0.2.7}/comfyui_skills_cli/commands/server.py +61 -0
- comfyui_skill_cli-0.2.7/comfyui_skills_cli/commands/templates.py +48 -0
- {comfyui_skill_cli-0.2.6 → comfyui_skill_cli-0.2.7}/comfyui_skills_cli/commands/upload.py +11 -2
- {comfyui_skill_cli-0.2.6 → comfyui_skill_cli-0.2.7}/comfyui_skills_cli/commands/workflow.py +51 -6
- {comfyui_skill_cli-0.2.6 → comfyui_skill_cli-0.2.7}/comfyui_skills_cli/config.py +6 -1
- comfyui_skill_cli-0.2.7/comfyui_skills_cli/error_hints.py +100 -0
- {comfyui_skill_cli-0.2.6 → comfyui_skill_cli-0.2.7}/comfyui_skills_cli/main.py +5 -2
- {comfyui_skill_cli-0.2.6 → comfyui_skill_cli-0.2.7}/comfyui_skills_cli/storage.py +25 -5
- comfyui_skill_cli-0.2.7/comfyui_skills_cli/utils.py +26 -0
- {comfyui_skill_cli-0.2.6 → comfyui_skill_cli-0.2.7}/pyproject.toml +5 -1
- {comfyui_skill_cli-0.2.6 → comfyui_skill_cli-0.2.7}/tests/test_client_new_apis.py +49 -0
- comfyui_skill_cli-0.2.7/tests/test_nodes_and_ws.py +203 -0
- comfyui_skill_cli-0.2.7/tests/test_partial_execution.py +56 -0
- comfyui_skill_cli-0.2.7/tests/test_server_stats.py +90 -0
- comfyui_skill_cli-0.2.6/PKG-INFO +0 -229
- comfyui_skill_cli-0.2.6/README.md +0 -201
- comfyui_skill_cli-0.2.6/comfyui_skill_cli.egg-info/PKG-INFO +0 -229
- comfyui_skill_cli-0.2.6/comfyui_skill_cli.egg-info/requires.txt +0 -3
- comfyui_skill_cli-0.2.6/comfyui_skills_cli/commands/history.py +0 -96
- comfyui_skill_cli-0.2.6/comfyui_skills_cli/error_hints.py +0 -43
- {comfyui_skill_cli-0.2.6 → comfyui_skill_cli-0.2.7}/LICENSE +0 -0
- {comfyui_skill_cli-0.2.6 → comfyui_skill_cli-0.2.7}/comfyui_skill_cli.egg-info/dependency_links.txt +0 -0
- {comfyui_skill_cli-0.2.6 → comfyui_skill_cli-0.2.7}/comfyui_skill_cli.egg-info/entry_points.txt +0 -0
- {comfyui_skill_cli-0.2.6 → comfyui_skill_cli-0.2.7}/comfyui_skill_cli.egg-info/top_level.txt +0 -0
- {comfyui_skill_cli-0.2.6 → comfyui_skill_cli-0.2.7}/comfyui_skills_cli/__init__.py +0 -0
- {comfyui_skill_cli-0.2.6 → comfyui_skill_cli-0.2.7}/comfyui_skills_cli/__main__.py +0 -0
- {comfyui_skill_cli-0.2.6 → comfyui_skill_cli-0.2.7}/comfyui_skills_cli/commands/__init__.py +0 -0
- {comfyui_skill_cli-0.2.6 → comfyui_skill_cli-0.2.7}/comfyui_skills_cli/commands/config.py +0 -0
- {comfyui_skill_cli-0.2.6 → comfyui_skill_cli-0.2.7}/comfyui_skills_cli/commands/deps.py +0 -0
- {comfyui_skill_cli-0.2.6 → comfyui_skill_cli-0.2.7}/comfyui_skills_cli/commands/skill.py +0 -0
- {comfyui_skill_cli-0.2.6 → comfyui_skill_cli-0.2.7}/comfyui_skills_cli/output.py +0 -0
- {comfyui_skill_cli-0.2.6 → comfyui_skill_cli-0.2.7}/comfyui_skills_cli/update_check.py +0 -0
- {comfyui_skill_cli-0.2.6 → comfyui_skill_cli-0.2.7}/setup.cfg +0 -0
- {comfyui_skill_cli-0.2.6 → comfyui_skill_cli-0.2.7}/tests/test_update_check.py +0 -0
|
@@ -0,0 +1,325 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: comfyui-skill-cli
|
|
3
|
+
Version: 0.2.7
|
|
4
|
+
Summary: ComfyUI Skill CLI — Agent-friendly workflow management
|
|
5
|
+
Author: HuangYuChuh
|
|
6
|
+
License-Expression: MIT
|
|
7
|
+
Project-URL: Homepage, https://github.com/HuangYuChuh/ComfyUI_Skill_CLI
|
|
8
|
+
Project-URL: Repository, https://github.com/HuangYuChuh/ComfyUI_Skill_CLI
|
|
9
|
+
Project-URL: Issues, https://github.com/HuangYuChuh/ComfyUI_Skill_CLI/issues
|
|
10
|
+
Keywords: comfyui,cli,agent,skill,workflow,ai,image-generation
|
|
11
|
+
Classifier: Development Status :: 3 - Alpha
|
|
12
|
+
Classifier: Environment :: Console
|
|
13
|
+
Classifier: Intended Audience :: Developers
|
|
14
|
+
Classifier: Programming Language :: Python :: 3
|
|
15
|
+
Classifier: Programming Language :: Python :: 3.10
|
|
16
|
+
Classifier: Programming Language :: Python :: 3.11
|
|
17
|
+
Classifier: Programming Language :: Python :: 3.12
|
|
18
|
+
Classifier: Programming Language :: Python :: 3.13
|
|
19
|
+
Classifier: Topic :: Software Development :: Libraries
|
|
20
|
+
Classifier: Topic :: Multimedia :: Graphics
|
|
21
|
+
Requires-Python: >=3.10
|
|
22
|
+
Description-Content-Type: text/markdown
|
|
23
|
+
License-File: LICENSE
|
|
24
|
+
Requires-Dist: typer>=0.9
|
|
25
|
+
Requires-Dist: rich>=13.0
|
|
26
|
+
Requires-Dist: requests>=2.28
|
|
27
|
+
Requires-Dist: websocket-client>=1.0
|
|
28
|
+
Provides-Extra: streaming
|
|
29
|
+
Requires-Dist: websocket-client>=1.0; extra == "streaming"
|
|
30
|
+
Dynamic: license-file
|
|
31
|
+
|
|
32
|
+
<div align="center">
|
|
33
|
+
|
|
34
|
+
<h1>ComfyUI Skill CLI</h1>
|
|
35
|
+
|
|
36
|
+
<p><strong>Agent-friendly command-line tool for managing and executing ComfyUI workflow skills.</strong></p>
|
|
37
|
+
|
|
38
|
+
<p>
|
|
39
|
+
Any AI agent that can run shell commands (Claude Code, Codex, OpenClaw, etc.) can use ComfyUI through this CLI.
|
|
40
|
+
</p>
|
|
41
|
+
|
|
42
|
+
<p>
|
|
43
|
+
<a href="https://pypi.org/project/comfyui-skill-cli/"><img src="https://img.shields.io/pypi/v/comfyui-skill-cli?style=flat&color=4F46E5&logo=pypi&logoColor=white" alt="PyPI"></a>
|
|
44
|
+
<a href="https://github.com/HuangYuChuh/ComfyUI_Skill_CLI/blob/main/LICENSE"><img src="https://img.shields.io/github/license/HuangYuChuh/ComfyUI_Skill_CLI?style=flat&color=10B981" alt="License"></a>
|
|
45
|
+
<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>
|
|
46
|
+
<a href="https://github.com/HuangYuChuh/ComfyUI_Skill_CLI/stargazers"><img src="https://img.shields.io/github/stars/HuangYuChuh/ComfyUI_Skill_CLI?style=flat&color=EAB308&logo=github" alt="GitHub stars"></a>
|
|
47
|
+
</p>
|
|
48
|
+
|
|
49
|
+
<p>
|
|
50
|
+
<a href="#install">Install</a> ·
|
|
51
|
+
<a href="#quick-start">Quick Start</a> ·
|
|
52
|
+
<a href="#commands">Commands</a> ·
|
|
53
|
+
<a href="#for-ai-agents">For AI Agents</a>
|
|
54
|
+
</p>
|
|
55
|
+
|
|
56
|
+
<p>
|
|
57
|
+
<strong>English</strong> ·
|
|
58
|
+
<a href="./README.zh.md">简体中文</a> ·
|
|
59
|
+
<a href="./README.zh-TW.md">繁體中文</a> ·
|
|
60
|
+
<a href="./README.ja.md">日本語</a>
|
|
61
|
+
</p>
|
|
62
|
+
|
|
63
|
+
</div>
|
|
64
|
+
|
|
65
|
+
---
|
|
66
|
+
|
|
67
|
+
## Why comfyui-skill?
|
|
68
|
+
|
|
69
|
+
| Capability | Why it matters |
|
|
70
|
+
|------------|----------------|
|
|
71
|
+
| **Agent-native** | Structured JSON output, pipe-friendly, designed for AI agents to call |
|
|
72
|
+
| **Zero config** | Reads `config.json` and `data/` from the current directory, no setup needed |
|
|
73
|
+
| **Full lifecycle** | Discover, import, execute, cancel, manage workflows and dependencies in one tool |
|
|
74
|
+
| **Multi-server** | Manage multiple ComfyUI instances, route jobs to different hardware |
|
|
75
|
+
| **Model discovery** | Inspect model folders and available model names directly from the target server |
|
|
76
|
+
| **Workflow fleet management** | Import, enable, disable, delete, and migrate multiple workflows across machines |
|
|
77
|
+
| **Error guidance** | Common failures (OOM, unauthorized, missing models) return actionable hints |
|
|
78
|
+
|
|
79
|
+
<a id="install"></a>
|
|
80
|
+
## Install
|
|
81
|
+
|
|
82
|
+
```bash
|
|
83
|
+
pipx install comfyui-skill-cli
|
|
84
|
+
```
|
|
85
|
+
|
|
86
|
+
Or with pip:
|
|
87
|
+
|
|
88
|
+
```bash
|
|
89
|
+
pip install comfyui-skill-cli
|
|
90
|
+
```
|
|
91
|
+
|
|
92
|
+
### Update
|
|
93
|
+
|
|
94
|
+
```bash
|
|
95
|
+
pipx upgrade comfyui-skill-cli
|
|
96
|
+
```
|
|
97
|
+
|
|
98
|
+
### Development Mode
|
|
99
|
+
|
|
100
|
+
```bash
|
|
101
|
+
git clone https://github.com/HuangYuChuh/ComfyUI_Skill_CLI.git
|
|
102
|
+
cd ComfyUI_Skill_CLI
|
|
103
|
+
pipx install -e .
|
|
104
|
+
```
|
|
105
|
+
|
|
106
|
+
<a id="quick-start"></a>
|
|
107
|
+
## Quick Start
|
|
108
|
+
|
|
109
|
+
```bash
|
|
110
|
+
# 1. Go to your ComfyUI Skills project directory
|
|
111
|
+
cd /path/to/your-skills-project
|
|
112
|
+
|
|
113
|
+
# 2. Check server status
|
|
114
|
+
comfyui-skill server status
|
|
115
|
+
|
|
116
|
+
# 3. List available workflows
|
|
117
|
+
comfyui-skill list
|
|
118
|
+
|
|
119
|
+
# 4. Execute a workflow
|
|
120
|
+
comfyui-skill run local/txt2img --args '{"prompt": "a white cat"}'
|
|
121
|
+
```
|
|
122
|
+
|
|
123
|
+
Every command supports `--json` for structured output.
|
|
124
|
+
|
|
125
|
+
## ID Convention
|
|
126
|
+
|
|
127
|
+
Workflows are addressed as `<server_id>/<workflow_id>`:
|
|
128
|
+
|
|
129
|
+
```bash
|
|
130
|
+
comfyui-skill run local/txt2img # explicit server
|
|
131
|
+
comfyui-skill run txt2img # uses default server
|
|
132
|
+
comfyui-skill run txt2img -s my_server # override with --server flag
|
|
133
|
+
```
|
|
134
|
+
|
|
135
|
+
<a id="commands"></a>
|
|
136
|
+
## Commands
|
|
137
|
+
|
|
138
|
+
### Workflow Discovery & Execution
|
|
139
|
+
|
|
140
|
+
| Command | Description |
|
|
141
|
+
|---------|-------------|
|
|
142
|
+
| `comfyui-skill list` | List all available workflows with parameters |
|
|
143
|
+
| `comfyui-skill info <id>` | Show workflow details and parameter schema |
|
|
144
|
+
| `comfyui-skill run <id> --args '{...}'` | Execute a workflow (blocking, real-time WebSocket streaming) |
|
|
145
|
+
| `comfyui-skill run <id> --validate` | Validate workflow without executing |
|
|
146
|
+
| `comfyui-skill submit <id> --args '{...}'` | Submit a workflow (non-blocking) |
|
|
147
|
+
| `comfyui-skill status <prompt_id>` | Check execution status and show discovered results |
|
|
148
|
+
| `comfyui-skill cancel <prompt_id>` | Cancel a running or queued job |
|
|
149
|
+
| `comfyui-skill upload <file>` | Upload a file to ComfyUI for use in workflows |
|
|
150
|
+
| `comfyui-skill upload <file> --mask` | Upload a mask image for inpainting workflows |
|
|
151
|
+
| `comfyui-skill upload --from-output <prompt_id>` | Chain a previous run's output as input for the next workflow |
|
|
152
|
+
|
|
153
|
+
### Queue & Resource Management
|
|
154
|
+
|
|
155
|
+
| Command | Description |
|
|
156
|
+
|---------|-------------|
|
|
157
|
+
| `comfyui-skill queue list` | Show running and pending jobs |
|
|
158
|
+
| `comfyui-skill queue clear` | Clear all pending jobs |
|
|
159
|
+
| `comfyui-skill queue delete <prompt_id>...` | Remove specific jobs from queue |
|
|
160
|
+
| `comfyui-skill free` | Release GPU memory and unload models |
|
|
161
|
+
| `comfyui-skill free --models` | Unload models only |
|
|
162
|
+
| `comfyui-skill free --memory` | Free cached memory only |
|
|
163
|
+
|
|
164
|
+
### Node & Model Discovery
|
|
165
|
+
|
|
166
|
+
| Command | Description |
|
|
167
|
+
|---------|-------------|
|
|
168
|
+
| `comfyui-skill nodes list` | List all available ComfyUI nodes by category |
|
|
169
|
+
| `comfyui-skill nodes info <class>` | Show node input/output schema |
|
|
170
|
+
| `comfyui-skill nodes search <query>` | Search nodes by name or category |
|
|
171
|
+
| `comfyui-skill models list` | List all available model folders |
|
|
172
|
+
| `comfyui-skill models list <folder>` | List models in a specific folder (e.g., `checkpoints`, `loras`) |
|
|
173
|
+
|
|
174
|
+
### Workflow Management
|
|
175
|
+
|
|
176
|
+
| Command | Description |
|
|
177
|
+
|---------|-------------|
|
|
178
|
+
| `comfyui-skill workflow import <path>` | Import workflow (auto-detect format, auto-generate schema) |
|
|
179
|
+
| `comfyui-skill workflow import --from-server` | Import one or more workflows from ComfyUI server userdata |
|
|
180
|
+
| `comfyui-skill workflow enable <id>` | Enable a workflow |
|
|
181
|
+
| `comfyui-skill workflow disable <id>` | Disable a workflow |
|
|
182
|
+
| `comfyui-skill workflow delete <id>` | Delete a workflow |
|
|
183
|
+
|
|
184
|
+
### Server Management
|
|
185
|
+
|
|
186
|
+
| Command | Description |
|
|
187
|
+
|---------|-------------|
|
|
188
|
+
| `comfyui-skill server list` | List all configured servers |
|
|
189
|
+
| `comfyui-skill server status` | Check if ComfyUI server is online |
|
|
190
|
+
| `comfyui-skill server stats` | Show VRAM, RAM, GPU info (`--all` for multi-server) |
|
|
191
|
+
| `comfyui-skill server add --id <id> --url <url>` | Add a new server |
|
|
192
|
+
| `comfyui-skill server enable/disable <id>` | Toggle server availability |
|
|
193
|
+
| `comfyui-skill server remove <id>` | Remove a server |
|
|
194
|
+
|
|
195
|
+
### Dependency Management
|
|
196
|
+
|
|
197
|
+
| Command | Description |
|
|
198
|
+
|---------|-------------|
|
|
199
|
+
| `comfyui-skill deps check <id>` | Check missing custom nodes and models |
|
|
200
|
+
| `comfyui-skill deps install <id> --all` | Auto-detect and install all missing deps |
|
|
201
|
+
| `comfyui-skill deps install <id> --repos '[...]'` | Install specific custom nodes |
|
|
202
|
+
| `comfyui-skill deps install <id> --models` | Install missing models via Manager |
|
|
203
|
+
|
|
204
|
+
### Configuration & History
|
|
205
|
+
|
|
206
|
+
| Command | Description |
|
|
207
|
+
|---------|-------------|
|
|
208
|
+
| `comfyui-skill config export --output <path>` | Export config and workflows as bundle |
|
|
209
|
+
| `comfyui-skill config import <path>` | Import config bundle (supports `--dry-run`) |
|
|
210
|
+
| `comfyui-skill history list <id>` | List execution history |
|
|
211
|
+
| `comfyui-skill history show <id> <run_id>` | Show details of a specific run |
|
|
212
|
+
| `comfyui-skill jobs list` | List server-side job history (`--status` to filter) |
|
|
213
|
+
| `comfyui-skill jobs show <prompt_id>` | Show details of a specific job |
|
|
214
|
+
| `comfyui-skill logs show` | Show recent ComfyUI server logs |
|
|
215
|
+
| `comfyui-skill templates list` | List workflow templates from custom nodes |
|
|
216
|
+
| `comfyui-skill templates subgraphs` | List reusable subgraph components |
|
|
217
|
+
|
|
218
|
+
### Global Options
|
|
219
|
+
|
|
220
|
+
| Option | Description |
|
|
221
|
+
|--------|-------------|
|
|
222
|
+
| `--json, -j` | Force JSON output |
|
|
223
|
+
| `--output-format` | Output format: `text`, `json`, `stream-json` |
|
|
224
|
+
| `--server, -s` | Specify server ID |
|
|
225
|
+
| `--dir, -d` | Specify data directory (default: current directory) |
|
|
226
|
+
| `--verbose, -v` | Verbose output |
|
|
227
|
+
| `--no-update-check` | Skip automatic CLI update check |
|
|
228
|
+
|
|
229
|
+
### Output Modes
|
|
230
|
+
|
|
231
|
+
| Mode | When | Format |
|
|
232
|
+
|------|------|--------|
|
|
233
|
+
| Text | TTY terminal | Rich tables and progress bars |
|
|
234
|
+
| JSON | Pipe or `--json` | Single JSON result |
|
|
235
|
+
| Stream JSON | `--output-format stream-json` | NDJSON events in real time |
|
|
236
|
+
| Errors | Always | stderr |
|
|
237
|
+
|
|
238
|
+
## Common Management Tasks
|
|
239
|
+
|
|
240
|
+
### Inspect models on a server
|
|
241
|
+
|
|
242
|
+
```bash
|
|
243
|
+
comfyui-skill models list
|
|
244
|
+
comfyui-skill models list checkpoints
|
|
245
|
+
comfyui-skill models list loras
|
|
246
|
+
```
|
|
247
|
+
|
|
248
|
+
Use this when you need to confirm model names before wiring them into a workflow or schema.
|
|
249
|
+
|
|
250
|
+
### Manage multiple workflows
|
|
251
|
+
|
|
252
|
+
```bash
|
|
253
|
+
# Preview workflows available in ComfyUI server userdata
|
|
254
|
+
comfyui-skill workflow import --from-server --preview
|
|
255
|
+
|
|
256
|
+
# Import matching workflows from the server
|
|
257
|
+
comfyui-skill workflow import --from-server --name sdxl
|
|
258
|
+
|
|
259
|
+
# Temporarily disable or re-enable a workflow
|
|
260
|
+
comfyui-skill workflow disable local/old-flow
|
|
261
|
+
comfyui-skill workflow enable local/old-flow
|
|
262
|
+
|
|
263
|
+
# Remove a workflow you no longer want to expose
|
|
264
|
+
comfyui-skill workflow delete local/old-flow
|
|
265
|
+
```
|
|
266
|
+
|
|
267
|
+
### Move workflow bundles between machines
|
|
268
|
+
|
|
269
|
+
```bash
|
|
270
|
+
comfyui-skill config export --output ./bundle.json --portable-only
|
|
271
|
+
comfyui-skill config import ./bundle.json --dry-run
|
|
272
|
+
comfyui-skill config import ./bundle.json --apply-environment
|
|
273
|
+
```
|
|
274
|
+
|
|
275
|
+
Use this when you want to migrate many workflows at once instead of re-importing them manually.
|
|
276
|
+
|
|
277
|
+
### Check models and dependencies before running
|
|
278
|
+
|
|
279
|
+
```bash
|
|
280
|
+
comfyui-skill deps check local/txt2img
|
|
281
|
+
comfyui-skill deps install local/txt2img --models
|
|
282
|
+
comfyui-skill deps install local/txt2img --all
|
|
283
|
+
```
|
|
284
|
+
|
|
285
|
+
<a id="for-ai-agents"></a>
|
|
286
|
+
## For AI Agents
|
|
287
|
+
|
|
288
|
+
This CLI is designed to be called from `SKILL.md` definitions. A typical agent workflow:
|
|
289
|
+
|
|
290
|
+
```bash
|
|
291
|
+
comfyui-skill server status --json # 1. verify server
|
|
292
|
+
comfyui-skill list --json # 2. discover workflows
|
|
293
|
+
comfyui-skill info local/txt2img --json # 3. check parameters
|
|
294
|
+
comfyui-skill run local/txt2img --args '{...}' --json # 4. execute
|
|
295
|
+
```
|
|
296
|
+
|
|
297
|
+
### Workflow chaining (multi-step pipelines)
|
|
298
|
+
|
|
299
|
+
```bash
|
|
300
|
+
# Run first workflow
|
|
301
|
+
comfyui-skill run local/txt2img --args '{"prompt": "a cat"}' --json
|
|
302
|
+
|
|
303
|
+
# Chain output into next workflow
|
|
304
|
+
comfyui-skill upload --from-output <prompt_id> --json
|
|
305
|
+
comfyui-skill run local/upscale --args '{"image": "<uploaded_name>"}' --json
|
|
306
|
+
```
|
|
307
|
+
|
|
308
|
+
### Import and validate
|
|
309
|
+
|
|
310
|
+
```bash
|
|
311
|
+
comfyui-skill workflow import ./workflow.json --check-deps --json
|
|
312
|
+
comfyui-skill deps install local/my-workflow --all --json
|
|
313
|
+
```
|
|
314
|
+
|
|
315
|
+
## Contributing
|
|
316
|
+
|
|
317
|
+
Contributions are welcome! Please read the [Contributing Guide](https://github.com/HuangYuChuh/ComfyUI_Skills_OpenClaw/blob/main/CONTRIBUTING.md) in the main repository for design principles and PR workflow.
|
|
318
|
+
|
|
319
|
+
## Resources
|
|
320
|
+
|
|
321
|
+
- [ComfyUI Skills OpenClaw](https://github.com/HuangYuChuh/ComfyUI_Skills_OpenClaw) — Main skills repository
|
|
322
|
+
- [ComfyUI](https://github.com/comfyanonymous/ComfyUI) — The backend this CLI orchestrates
|
|
323
|
+
- [Typer](https://typer.tiangolo.com/) — CLI framework used by this project
|
|
324
|
+
|
|
325
|
+
Built with [Typer](https://typer.tiangolo.com/), the same framework as [comfy-cli](https://github.com/Comfy-Org/comfy-cli). Designed to be integrated as a `comfy skills` subcommand in the future.
|
|
@@ -0,0 +1,294 @@
|
|
|
1
|
+
<div align="center">
|
|
2
|
+
|
|
3
|
+
<h1>ComfyUI Skill CLI</h1>
|
|
4
|
+
|
|
5
|
+
<p><strong>Agent-friendly command-line tool for managing and executing ComfyUI workflow skills.</strong></p>
|
|
6
|
+
|
|
7
|
+
<p>
|
|
8
|
+
Any AI agent that can run shell commands (Claude Code, Codex, OpenClaw, etc.) can use ComfyUI through this CLI.
|
|
9
|
+
</p>
|
|
10
|
+
|
|
11
|
+
<p>
|
|
12
|
+
<a href="https://pypi.org/project/comfyui-skill-cli/"><img src="https://img.shields.io/pypi/v/comfyui-skill-cli?style=flat&color=4F46E5&logo=pypi&logoColor=white" alt="PyPI"></a>
|
|
13
|
+
<a href="https://github.com/HuangYuChuh/ComfyUI_Skill_CLI/blob/main/LICENSE"><img src="https://img.shields.io/github/license/HuangYuChuh/ComfyUI_Skill_CLI?style=flat&color=10B981" alt="License"></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/HuangYuChuh/ComfyUI_Skill_CLI/stargazers"><img src="https://img.shields.io/github/stars/HuangYuChuh/ComfyUI_Skill_CLI?style=flat&color=EAB308&logo=github" alt="GitHub stars"></a>
|
|
16
|
+
</p>
|
|
17
|
+
|
|
18
|
+
<p>
|
|
19
|
+
<a href="#install">Install</a> ·
|
|
20
|
+
<a href="#quick-start">Quick Start</a> ·
|
|
21
|
+
<a href="#commands">Commands</a> ·
|
|
22
|
+
<a href="#for-ai-agents">For AI Agents</a>
|
|
23
|
+
</p>
|
|
24
|
+
|
|
25
|
+
<p>
|
|
26
|
+
<strong>English</strong> ·
|
|
27
|
+
<a href="./README.zh.md">简体中文</a> ·
|
|
28
|
+
<a href="./README.zh-TW.md">繁體中文</a> ·
|
|
29
|
+
<a href="./README.ja.md">日本語</a>
|
|
30
|
+
</p>
|
|
31
|
+
|
|
32
|
+
</div>
|
|
33
|
+
|
|
34
|
+
---
|
|
35
|
+
|
|
36
|
+
## Why comfyui-skill?
|
|
37
|
+
|
|
38
|
+
| Capability | Why it matters |
|
|
39
|
+
|------------|----------------|
|
|
40
|
+
| **Agent-native** | Structured JSON output, pipe-friendly, designed for AI agents to call |
|
|
41
|
+
| **Zero config** | Reads `config.json` and `data/` from the current directory, no setup needed |
|
|
42
|
+
| **Full lifecycle** | Discover, import, execute, cancel, manage workflows and dependencies in one tool |
|
|
43
|
+
| **Multi-server** | Manage multiple ComfyUI instances, route jobs to different hardware |
|
|
44
|
+
| **Model discovery** | Inspect model folders and available model names directly from the target server |
|
|
45
|
+
| **Workflow fleet management** | Import, enable, disable, delete, and migrate multiple workflows across machines |
|
|
46
|
+
| **Error guidance** | Common failures (OOM, unauthorized, missing models) return actionable hints |
|
|
47
|
+
|
|
48
|
+
<a id="install"></a>
|
|
49
|
+
## Install
|
|
50
|
+
|
|
51
|
+
```bash
|
|
52
|
+
pipx install comfyui-skill-cli
|
|
53
|
+
```
|
|
54
|
+
|
|
55
|
+
Or with pip:
|
|
56
|
+
|
|
57
|
+
```bash
|
|
58
|
+
pip install comfyui-skill-cli
|
|
59
|
+
```
|
|
60
|
+
|
|
61
|
+
### Update
|
|
62
|
+
|
|
63
|
+
```bash
|
|
64
|
+
pipx upgrade comfyui-skill-cli
|
|
65
|
+
```
|
|
66
|
+
|
|
67
|
+
### Development Mode
|
|
68
|
+
|
|
69
|
+
```bash
|
|
70
|
+
git clone https://github.com/HuangYuChuh/ComfyUI_Skill_CLI.git
|
|
71
|
+
cd ComfyUI_Skill_CLI
|
|
72
|
+
pipx install -e .
|
|
73
|
+
```
|
|
74
|
+
|
|
75
|
+
<a id="quick-start"></a>
|
|
76
|
+
## Quick Start
|
|
77
|
+
|
|
78
|
+
```bash
|
|
79
|
+
# 1. Go to your ComfyUI Skills project directory
|
|
80
|
+
cd /path/to/your-skills-project
|
|
81
|
+
|
|
82
|
+
# 2. Check server status
|
|
83
|
+
comfyui-skill server status
|
|
84
|
+
|
|
85
|
+
# 3. List available workflows
|
|
86
|
+
comfyui-skill list
|
|
87
|
+
|
|
88
|
+
# 4. Execute a workflow
|
|
89
|
+
comfyui-skill run local/txt2img --args '{"prompt": "a white cat"}'
|
|
90
|
+
```
|
|
91
|
+
|
|
92
|
+
Every command supports `--json` for structured output.
|
|
93
|
+
|
|
94
|
+
## ID Convention
|
|
95
|
+
|
|
96
|
+
Workflows are addressed as `<server_id>/<workflow_id>`:
|
|
97
|
+
|
|
98
|
+
```bash
|
|
99
|
+
comfyui-skill run local/txt2img # explicit server
|
|
100
|
+
comfyui-skill run txt2img # uses default server
|
|
101
|
+
comfyui-skill run txt2img -s my_server # override with --server flag
|
|
102
|
+
```
|
|
103
|
+
|
|
104
|
+
<a id="commands"></a>
|
|
105
|
+
## Commands
|
|
106
|
+
|
|
107
|
+
### Workflow Discovery & Execution
|
|
108
|
+
|
|
109
|
+
| Command | Description |
|
|
110
|
+
|---------|-------------|
|
|
111
|
+
| `comfyui-skill list` | List all available workflows with parameters |
|
|
112
|
+
| `comfyui-skill info <id>` | Show workflow details and parameter schema |
|
|
113
|
+
| `comfyui-skill run <id> --args '{...}'` | Execute a workflow (blocking, real-time WebSocket streaming) |
|
|
114
|
+
| `comfyui-skill run <id> --validate` | Validate workflow without executing |
|
|
115
|
+
| `comfyui-skill submit <id> --args '{...}'` | Submit a workflow (non-blocking) |
|
|
116
|
+
| `comfyui-skill status <prompt_id>` | Check execution status and show discovered results |
|
|
117
|
+
| `comfyui-skill cancel <prompt_id>` | Cancel a running or queued job |
|
|
118
|
+
| `comfyui-skill upload <file>` | Upload a file to ComfyUI for use in workflows |
|
|
119
|
+
| `comfyui-skill upload <file> --mask` | Upload a mask image for inpainting workflows |
|
|
120
|
+
| `comfyui-skill upload --from-output <prompt_id>` | Chain a previous run's output as input for the next workflow |
|
|
121
|
+
|
|
122
|
+
### Queue & Resource Management
|
|
123
|
+
|
|
124
|
+
| Command | Description |
|
|
125
|
+
|---------|-------------|
|
|
126
|
+
| `comfyui-skill queue list` | Show running and pending jobs |
|
|
127
|
+
| `comfyui-skill queue clear` | Clear all pending jobs |
|
|
128
|
+
| `comfyui-skill queue delete <prompt_id>...` | Remove specific jobs from queue |
|
|
129
|
+
| `comfyui-skill free` | Release GPU memory and unload models |
|
|
130
|
+
| `comfyui-skill free --models` | Unload models only |
|
|
131
|
+
| `comfyui-skill free --memory` | Free cached memory only |
|
|
132
|
+
|
|
133
|
+
### Node & Model Discovery
|
|
134
|
+
|
|
135
|
+
| Command | Description |
|
|
136
|
+
|---------|-------------|
|
|
137
|
+
| `comfyui-skill nodes list` | List all available ComfyUI nodes by category |
|
|
138
|
+
| `comfyui-skill nodes info <class>` | Show node input/output schema |
|
|
139
|
+
| `comfyui-skill nodes search <query>` | Search nodes by name or category |
|
|
140
|
+
| `comfyui-skill models list` | List all available model folders |
|
|
141
|
+
| `comfyui-skill models list <folder>` | List models in a specific folder (e.g., `checkpoints`, `loras`) |
|
|
142
|
+
|
|
143
|
+
### Workflow Management
|
|
144
|
+
|
|
145
|
+
| Command | Description |
|
|
146
|
+
|---------|-------------|
|
|
147
|
+
| `comfyui-skill workflow import <path>` | Import workflow (auto-detect format, auto-generate schema) |
|
|
148
|
+
| `comfyui-skill workflow import --from-server` | Import one or more workflows from ComfyUI server userdata |
|
|
149
|
+
| `comfyui-skill workflow enable <id>` | Enable a workflow |
|
|
150
|
+
| `comfyui-skill workflow disable <id>` | Disable a workflow |
|
|
151
|
+
| `comfyui-skill workflow delete <id>` | Delete a workflow |
|
|
152
|
+
|
|
153
|
+
### Server Management
|
|
154
|
+
|
|
155
|
+
| Command | Description |
|
|
156
|
+
|---------|-------------|
|
|
157
|
+
| `comfyui-skill server list` | List all configured servers |
|
|
158
|
+
| `comfyui-skill server status` | Check if ComfyUI server is online |
|
|
159
|
+
| `comfyui-skill server stats` | Show VRAM, RAM, GPU info (`--all` for multi-server) |
|
|
160
|
+
| `comfyui-skill server add --id <id> --url <url>` | Add a new server |
|
|
161
|
+
| `comfyui-skill server enable/disable <id>` | Toggle server availability |
|
|
162
|
+
| `comfyui-skill server remove <id>` | Remove a server |
|
|
163
|
+
|
|
164
|
+
### Dependency Management
|
|
165
|
+
|
|
166
|
+
| Command | Description |
|
|
167
|
+
|---------|-------------|
|
|
168
|
+
| `comfyui-skill deps check <id>` | Check missing custom nodes and models |
|
|
169
|
+
| `comfyui-skill deps install <id> --all` | Auto-detect and install all missing deps |
|
|
170
|
+
| `comfyui-skill deps install <id> --repos '[...]'` | Install specific custom nodes |
|
|
171
|
+
| `comfyui-skill deps install <id> --models` | Install missing models via Manager |
|
|
172
|
+
|
|
173
|
+
### Configuration & History
|
|
174
|
+
|
|
175
|
+
| Command | Description |
|
|
176
|
+
|---------|-------------|
|
|
177
|
+
| `comfyui-skill config export --output <path>` | Export config and workflows as bundle |
|
|
178
|
+
| `comfyui-skill config import <path>` | Import config bundle (supports `--dry-run`) |
|
|
179
|
+
| `comfyui-skill history list <id>` | List execution history |
|
|
180
|
+
| `comfyui-skill history show <id> <run_id>` | Show details of a specific run |
|
|
181
|
+
| `comfyui-skill jobs list` | List server-side job history (`--status` to filter) |
|
|
182
|
+
| `comfyui-skill jobs show <prompt_id>` | Show details of a specific job |
|
|
183
|
+
| `comfyui-skill logs show` | Show recent ComfyUI server logs |
|
|
184
|
+
| `comfyui-skill templates list` | List workflow templates from custom nodes |
|
|
185
|
+
| `comfyui-skill templates subgraphs` | List reusable subgraph components |
|
|
186
|
+
|
|
187
|
+
### Global Options
|
|
188
|
+
|
|
189
|
+
| Option | Description |
|
|
190
|
+
|--------|-------------|
|
|
191
|
+
| `--json, -j` | Force JSON output |
|
|
192
|
+
| `--output-format` | Output format: `text`, `json`, `stream-json` |
|
|
193
|
+
| `--server, -s` | Specify server ID |
|
|
194
|
+
| `--dir, -d` | Specify data directory (default: current directory) |
|
|
195
|
+
| `--verbose, -v` | Verbose output |
|
|
196
|
+
| `--no-update-check` | Skip automatic CLI update check |
|
|
197
|
+
|
|
198
|
+
### Output Modes
|
|
199
|
+
|
|
200
|
+
| Mode | When | Format |
|
|
201
|
+
|------|------|--------|
|
|
202
|
+
| Text | TTY terminal | Rich tables and progress bars |
|
|
203
|
+
| JSON | Pipe or `--json` | Single JSON result |
|
|
204
|
+
| Stream JSON | `--output-format stream-json` | NDJSON events in real time |
|
|
205
|
+
| Errors | Always | stderr |
|
|
206
|
+
|
|
207
|
+
## Common Management Tasks
|
|
208
|
+
|
|
209
|
+
### Inspect models on a server
|
|
210
|
+
|
|
211
|
+
```bash
|
|
212
|
+
comfyui-skill models list
|
|
213
|
+
comfyui-skill models list checkpoints
|
|
214
|
+
comfyui-skill models list loras
|
|
215
|
+
```
|
|
216
|
+
|
|
217
|
+
Use this when you need to confirm model names before wiring them into a workflow or schema.
|
|
218
|
+
|
|
219
|
+
### Manage multiple workflows
|
|
220
|
+
|
|
221
|
+
```bash
|
|
222
|
+
# Preview workflows available in ComfyUI server userdata
|
|
223
|
+
comfyui-skill workflow import --from-server --preview
|
|
224
|
+
|
|
225
|
+
# Import matching workflows from the server
|
|
226
|
+
comfyui-skill workflow import --from-server --name sdxl
|
|
227
|
+
|
|
228
|
+
# Temporarily disable or re-enable a workflow
|
|
229
|
+
comfyui-skill workflow disable local/old-flow
|
|
230
|
+
comfyui-skill workflow enable local/old-flow
|
|
231
|
+
|
|
232
|
+
# Remove a workflow you no longer want to expose
|
|
233
|
+
comfyui-skill workflow delete local/old-flow
|
|
234
|
+
```
|
|
235
|
+
|
|
236
|
+
### Move workflow bundles between machines
|
|
237
|
+
|
|
238
|
+
```bash
|
|
239
|
+
comfyui-skill config export --output ./bundle.json --portable-only
|
|
240
|
+
comfyui-skill config import ./bundle.json --dry-run
|
|
241
|
+
comfyui-skill config import ./bundle.json --apply-environment
|
|
242
|
+
```
|
|
243
|
+
|
|
244
|
+
Use this when you want to migrate many workflows at once instead of re-importing them manually.
|
|
245
|
+
|
|
246
|
+
### Check models and dependencies before running
|
|
247
|
+
|
|
248
|
+
```bash
|
|
249
|
+
comfyui-skill deps check local/txt2img
|
|
250
|
+
comfyui-skill deps install local/txt2img --models
|
|
251
|
+
comfyui-skill deps install local/txt2img --all
|
|
252
|
+
```
|
|
253
|
+
|
|
254
|
+
<a id="for-ai-agents"></a>
|
|
255
|
+
## For AI Agents
|
|
256
|
+
|
|
257
|
+
This CLI is designed to be called from `SKILL.md` definitions. A typical agent workflow:
|
|
258
|
+
|
|
259
|
+
```bash
|
|
260
|
+
comfyui-skill server status --json # 1. verify server
|
|
261
|
+
comfyui-skill list --json # 2. discover workflows
|
|
262
|
+
comfyui-skill info local/txt2img --json # 3. check parameters
|
|
263
|
+
comfyui-skill run local/txt2img --args '{...}' --json # 4. execute
|
|
264
|
+
```
|
|
265
|
+
|
|
266
|
+
### Workflow chaining (multi-step pipelines)
|
|
267
|
+
|
|
268
|
+
```bash
|
|
269
|
+
# Run first workflow
|
|
270
|
+
comfyui-skill run local/txt2img --args '{"prompt": "a cat"}' --json
|
|
271
|
+
|
|
272
|
+
# Chain output into next workflow
|
|
273
|
+
comfyui-skill upload --from-output <prompt_id> --json
|
|
274
|
+
comfyui-skill run local/upscale --args '{"image": "<uploaded_name>"}' --json
|
|
275
|
+
```
|
|
276
|
+
|
|
277
|
+
### Import and validate
|
|
278
|
+
|
|
279
|
+
```bash
|
|
280
|
+
comfyui-skill workflow import ./workflow.json --check-deps --json
|
|
281
|
+
comfyui-skill deps install local/my-workflow --all --json
|
|
282
|
+
```
|
|
283
|
+
|
|
284
|
+
## Contributing
|
|
285
|
+
|
|
286
|
+
Contributions are welcome! Please read the [Contributing Guide](https://github.com/HuangYuChuh/ComfyUI_Skills_OpenClaw/blob/main/CONTRIBUTING.md) in the main repository for design principles and PR workflow.
|
|
287
|
+
|
|
288
|
+
## Resources
|
|
289
|
+
|
|
290
|
+
- [ComfyUI Skills OpenClaw](https://github.com/HuangYuChuh/ComfyUI_Skills_OpenClaw) — Main skills repository
|
|
291
|
+
- [ComfyUI](https://github.com/comfyanonymous/ComfyUI) — The backend this CLI orchestrates
|
|
292
|
+
- [Typer](https://typer.tiangolo.com/) — CLI framework used by this project
|
|
293
|
+
|
|
294
|
+
Built with [Typer](https://typer.tiangolo.com/), the same framework as [comfy-cli](https://github.com/Comfy-Org/comfy-cli). Designed to be integrated as a `comfy skills` subcommand in the future.
|