Cli Anything Comfyui

hkuds/cli-anything/skills/cli-anything-comfyui

作者 hkuds34f519533bc1无许可证51K 个星标收录于 2026年10月8日更新于 2026年10月8日仓库2周前更新

Command-line interface for ComfyUI - AI image generation workflow management via ComfyUI REST API. Designed for AI agents and power users who need to queue workflows, manage models, download generated images, and monitor the generation queue without a GUI.

仅含说明Design & Creative
AI 生成的概览

用于通过 ComfyUI REST API 管理 ComfyUI 图像生成工作流、模型、队列和生成图像的命令行界面。

功能
该技能介绍了一个通过 REST API 与运行中的 ComfyUI 服务器通信的命令行界面。它涵盖工作流的列出、加载与校验,提交提示任务,查看队列状态与执行历史,中断或清空队列,发现 checkpoint、LoRA、VAE 和 ControlNet 模型,以及列出或下载生成的图像。它还能显示服务器统计信息和服务器信息,并提供人类可读输出和面向程序化使用的 JSON 模式。
适用场景
当你需要在没有图形界面的情况下操作 ComfyUI 时使用,例如提交工作流、监控生成进度、查看可用模型和节点类型,或下载已生成的图像。它适合希望以可脚本化、可解析 JSON 的方式访问本地 ComfyUI 实例的智能体和高阶用户。
运行要求
需要 Python 3.10 或更高版本,以及一个运行在 并可通过网络访问的 ComfyUI 安装。该 CLI 通过 pip 以 cli-anything-comfyui 包的形式安装。该技能不附带脚本,仅为说明文档。

cli-anything-comfyui

AI image generation workflow management via the ComfyUI REST API. Designed for AI agents and power users who need to queue workflows, manage models, download generated images, and monitor the generation queue without a GUI.

Installation

This CLI is installed as part of the cli-anything-comfyui package:

bash
pip install cli-anything-comfyui

Prerequisites:

Usage

Basic Commands

bash
# Show helpcli-anything-comfyui --help
# Start interactive REPL modecli-anything-comfyui repl
# Check server statscli-anything-comfyui system stats
# Run with JSON output (for agent consumption)cli-anything-comfyui --json system stats

REPL Mode

Start an interactive session for exploratory use:

bash
cli-anything-comfyui repl# Enter commands interactively with tab-completion and history

Command Groups

Workflow

Workflow management commands.

CommandDescription
listList saved workflows
loadLoad a workflow from a JSON file
validateValidate a workflow JSON against the ComfyUI node graph

Queue

Generation queue management.

CommandDescription
promptQueue a workflow for execution
statusShow current queue status (running and pending)
clearClear the generation queue
historyShow prompt execution history
interruptInterrupt the currently running generation

Models

Model discovery commands.

CommandDescription
checkpointsList available checkpoint models
lorasList available LoRA models
vaesList available VAE models
controlnetsList available ControlNet models
node-infoShow detailed info for a specific node type
list-nodesList all available node types

Images

Generated image management.

CommandDescription
listList generated images on the server
downloadDownload a specific generated image
download-allDownload all images from a prompt execution

System

Server status and information.

CommandDescription
statsShow ComfyUI system statistics (GPU, CPU, memory)
infoShow ComfyUI server info and extensions

Examples

Check System Status

bash
# Server statscli-anything-comfyui system stats
# Server infocli-anything-comfyui system info

Discover Available Models

bash
# List checkpointscli-anything-comfyui models checkpoints
# List LoRAscli-anything-comfyui models loras
# List all node typescli-anything-comfyui models list-nodes

Queue and Monitor Generation

bash
# Queue a workflowcli-anything-comfyui queue prompt --workflow my_workflow.json
# Check queue statuscli-anything-comfyui queue status
# View execution historycli-anything-comfyui --json queue history

Download Generated Images

bash
# List generated imagescli-anything-comfyui images list
# Download a specific imagecli-anything-comfyui images download --filename ComfyUI_00001_.png --output ./out.png
# Download all images from a promptcli-anything-comfyui images download-all --prompt-id <id> --output-dir ./outputs

Output Formats

All commands support dual output modes:

  • Human-readable (default): Tables, colors, formatted text
  • Machine-readable (--json flag): Structured JSON for agent consumption
bash
# Human outputcli-anything-comfyui system stats
# JSON output for agentscli-anything-comfyui --json system stats

For AI Agents

When using this CLI programmatically:

  1. Always use --json flag for parseable output
  2. Check return codes - 0 for success, non-zero for errors
  3. Parse stderr for error messages on failure
  4. Use absolute paths for all file operations
  5. Verify ComfyUI is running with system stats before other commands

More Information

  • Full documentation: See README.md in the package
  • Test coverage: See TEST.md in the package
  • Methodology: See HARNESS.md in the cli-anything-plugin

Version

1.0.0

来源与署名

来源:hkuds/cli-anything位于skills/cli-anything-comfyui提交34f5195

许可证: 无许可证

内容归原作者所有。SourceWeft 从公开仓库中收录这些内容。

举报或申请下架