agentleFS
hybridindiehybridindie/comfyui_mcp/skills/gen/SKILL.md

gen

Skill2 starsChanged 5 days agoMITView on GitHub

Generate an image with ComfyUI from a text prompt

4 other projects use a version of this.

Adopted by

Most recently taken up by

The file

We split this skill into the rules it gives an agent

3 rules. 0 are common, 0 are distinctive, and 3 are very specific to this project.

  • 0

    Common

    Most of the 3 edited versions we read keep these.

  • 0

    Distinctive

    This author's own choices. Worth a look.

  • 3

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    Select a model: If the user specified a model name, use it.

    line 23
  2. Very specific:

    Generate the image: Call comfyui_generate_image with the parsed parameters and wait=True so we block until completion.

    line 25
  3. Very specific:

    If generation fails, check comfyui_get_queue to see if ComfyUI is busy or stuck.

    line 33

“Common” is measured: kept by at least 6 in 10 of the 3 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Generate Image

Generate an image using ComfyUI based on the user's prompt "$ARGUMENTS".

Steps

  1. Parse the prompt. Extract any explicit parameters (dimensions, steps, cfg, model name) from the user's request. Reject and ask for clarification only in these specific cases:

    • The prompt is empty or whitespace-only
    • The prompt is a question or meta-request rather than a scene description (e.g., "what can you do?", "how does this work?")
    • The user passed a parameter outside its valid range (steps < 1, cfg < 0, width/height not divisible by 8)

    Otherwise, apply these defaults for the listed parameters (and only these) when not specified:

    • width: 512, height: 512
    • steps: 20
    • cfg: 7.0
    • negative_prompt: "bad quality, blurry"
  2. Select a model. If the user specified a model name, use it. Otherwise, call comfyui_list_models with folder "checkpoints", pick one from the returned items, and ask the user to confirm before proceeding (offer to swap if they want a different one).
  3. Generate the image. Call comfyui_generate_image with the parsed parameters and wait=True so we block until completion.
  4. Fetch the result. The response is a dict envelope with keys status (expect "completed"), prompt_id, outputs, elapsed_seconds, and optionally warnings. outputs is a list of {node_id, filename, subfolder} entries — read the first entry's filename and subfolder and call comfyui_get_image with those. (Tip: pass preview_format="webp" and preview_quality=80 to comfyui_get_image for a thumbnail instead of the full PNG — much cheaper context.)
  5. Present the result. Show the image and a summary of the generation parameters used (prompt, model, dimensions, steps, cfg).

Notes

  • If generation fails, check comfyui_get_queue to see if ComfyUI is busy or stuck.
  • For img2img, ControlNet, or other advanced workflows, use /comfy:workflow instead.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.