Skip to content
Back to skills

Open Source Video Gen Skill Cursor Image Gen

ASecurity

Generate or edit bitmap images by launching a local Cursor Agent (cursor-grok-4.6-high) and using Cursor GenerateImage, then saving files to an exact folder. Use when the running agent has no native image tool, or the user explicitly requests Cursor, for photos, illustrations, icons, banners, mockups, turnarounds, or reference-guided images, including 文生图, 图生图, 多参考图, and 改图. Do not use when the current agent already has a working image-generation tool, unless the user asks for Cursor. Do not ...

  • 5 stars
  • 0 votes
  • 0 copies
  • 0 views
  • Added November 7, 2026
ai-agentsbashnodeapi

Works with

  • cursor
  • api

Security analysis

A100/100

Pro scans all 6 files and shows the line behind each finding

Scanned November 7, 2026

npx -y skills add Wanfeng1028/muse --skill open-source-video-gen-skill-cursor-image-gen --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Open Source Video Gen Skill Cursor Image Gen?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Open Source Video Gen Skill Cursor Image Gen
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/wanfeng1028-open-source-video-gen-skill-cursor-image-gen/badge)](https://www.skillsdirectory.com/skills/wanfeng1028-open-source-video-gen-skill-cursor-image-gen)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: cursor-image-gen
description: >-
  Generate or edit bitmap images by launching a local Cursor Agent (cursor-grok-4.6-high)
  and using Cursor GenerateImage, then saving files to an exact folder. Use when the
  running agent has no native image tool, or the user explicitly requests Cursor, for
  photos, illustrations, icons, banners, mockups, turnarounds, or reference-guided
  images, including 文生图, 图生图, 多参考图, and 改图. Do not use when the current
  agent already has a working image-generation tool, unless the user asks for Cursor.
  Do not use for SVG/vector/code-native assets or a different image-generation provider.
---

# Cursor Image Gen

Launch a headless Cursor Agent and save bitmaps to a user-chosen directory. Do not call `$imagegen`, `image_gen`, or the OpenAI Images API.

## Skill path

```bash
export ZCODE_HOME="${ZCODE_HOME:-$HOME/.zcode}"
export CURSOR_IMG="$ZCODE_HOME/skills/cursor-image-gen/scripts/generate_with_cursor.mjs"
```

The wrapper needs network and write access to `--output-dir`. In a sandboxed ZCode task, request permission before running it.

Do not invoke PATH `agent`; that binary may be Grok. The wrapper resolves `cursor-agent`.

## Routing

| Intent | How to call |
|---|---|
| New image, no file | `--prompt` only (text2img) |
| Guide from one image | `--reference FILE` (img2img) |
| Several refs (style, face, layout) | repeat `--reference`; optional matching `--reference-role` |
| Edit an existing image | `--mode edit` and/or `--keep` / `--change`; edit target is the first `--reference` |
| Same prompt, several variants | `--n N` |
| Many different assets | `--jobs jobs.json` |
| Independent multi-image set | Launch one wrapper invocation per image concurrently; reuse verified references when applicable |

## Scheduling: sequential vs parallel

Decide automatically from the dependency graph instead of always using one mode:

- Generate one image at a time when there is only one requested asset, when each image depends on the previous result, or when the next prompt must be chosen after inspecting the previous output. This is the normal serial workflow.
- If a reference, identity, style, or layout image must be created first, generate and verify that reference serially. After it exists, launch independent downstream image jobs concurrently when they share the reference but do not depend on one another. Reusing the same local reference file across concurrent jobs is supported.
- For true parallel generation, use one `generate_with_cursor.mjs` invocation per output with a unique filename and start those invocations concurrently through the available execution tools. Do not put all independent jobs into one sequential loop.
- `--jobs` runs several assets through one Cursor Agent invocation, and `--n` makes several `GenerateImage` calls for one prompt. Both are batch mechanisms; neither should be described as guaranteed process-level parallelism. Use separate concurrent wrapper invocations when the user asks for simultaneous multi-image generation.
- Keep dependent edits, reference creation, inspection, and any retry that needs a prior result serial. After a parallel batch finishes, verify every returned file independently and report partial failures clearly.

Need exact pixels, a mask, true transparent PNG, seed, or ControlNet? Read [references/limits.md](references/limits.md), tell the user Cursor cannot do it, and stop. Do not silently switch to `$imagegen`.

Mode details and inner-prompt rules: [references/modes.md](references/modes.md).

## Commands

Text to image:

```bash
node "$CURSOR_IMG" \
  --prompt "a paper-cut red panda, warm studio lighting" \
  --output-dir "/absolute/path/to/output" \
  --filename "red-panda.png" \
  --aspect-ratio 1:1
```

Image to image / edit:

```bash
node "$CURSOR_IMG" \
  --prompt "keep the subject, replace the background with a misty forest" \
  --output-dir "/absolute/path/to/output" \
  --filename "forest-edit.png" \
  --reference "/absolute/path/to/source.png" \
  --mode edit \
  --keep "subject, clothing, face" \
  --change "background only"
```

Multi-reference:

```bash
node "$CURSOR_IMG" \
  --prompt "same person as identity ref, composition matching the layout ref, white background turnaround" \
  --output-dir "/absolute/path/to/output" \
  --filename "character-turnaround.png" \
  --aspect-ratio 16:9 \
  --reference "/absolute/path/to/face.png" \
  --reference-role identity \
  --reference "/absolute/path/to/layout.png" \
  --reference-role composition
```

Batch:

```bash
node "$CURSOR_IMG" \
  --jobs "/absolute/path/to/jobs.json" \
  --output-dir "/absolute/path/to/output"
```

`--aspect-ratio` must be `1:1`, `4:3`, `3:4`, `16:9`, or `9:16`. Optional: `--transparent`, `--avoid "..."`, `--n N`, `--overwrite` (only with explicit user approval). The default Cursor model is `cursor-grok-4.6-high`; pass `--model` only when intentionally overriding it.

## Verify

Treat exit code 0 and JSON `ok: true` as success. Return every absolute path in `outputs`. Inspect the files before telling the user they look right.

Setup only:

```bash
node "$CURSOR_IMG" --doctor
node "$CURSOR_IMG" --help
```

If `--doctor` reports `logged_in: false`, ask the user to run `cursor-agent login` (or set `CURSOR_API_KEY`). Do not fall back to `$imagegen`.

Files in this skill

  • LICENSE1.2 KB
  • SKILL.md5.2 KB
  • agents/openai.yaml222 B
  • references/limits.md1.3 KB
  • references/modes.md2.6 KB
  • scripts/generate_with_cursor.mjs19.6 KB

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.