Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 0 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
skills/zenmux-context/references/zenmux-doc
.DS_Store
skills/zenmux-feedback/references/zenmux-doc
skills/zenmux-image-generation/prompts/*
!skills/zenmux-image-generation/prompts/.gitkeep
skills/zenmux-image-generation/output/*
!skills/zenmux-image-generation/output/.gitkeep
skills/zenmux-image-generation/.venv/
Expand Down
3 changes: 2 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -133,8 +133,9 @@ skills/ # Skills directory
awesome-gpt-image-2.md # YouMind-OpenLab/awesome-gpt-image-2 README (~2700 prompts)
awesome-nano-banana-pro-prompts.md # YouMind-OpenLab/awesome-nano-banana-pro-prompts README
zenmux-image-api.md
prompts/ # User-confirmed optimized prompts (git-ignored)
output/ # Generated images (git-ignored)
# Optimized prompts are saved per-project under
# <project-dir>/.context/prompts/zenmux-image-generation/, not in the skill.
Comment on lines 136 to +138
zenmux-codex-pets/ # ZenMux Codex APP pets installer skill
SKILL.md # Skill definition
scripts/
Expand Down
25 changes: 20 additions & 5 deletions skills/zenmux-image-generation/SKILL.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,14 @@ request, pick a suitable ZenMux model, rewrite the prompt so it plays to that
model's strengths, get the user's sign-off, then call the API and save the
results into this skill's `output/` folder by default.

**Optimized prompts are saved into the user's project, not into the skill.**
Each run's prompt file goes to
`<project-dir>/.context/prompts/zenmux-image-generation/`, where `<project-dir>`
is the current working directory (the user's project root). This keeps the
prompt history alongside the project that requested the images. The directory is
Comment on lines +24 to +28
created automatically when you write the first prompt file (the Write tool makes
parent directories).

**Default behaviour:** if the user does not specify a model, use
`openai/gpt-image-2`. Always generate 4 images per run unless the user
explicitly asks for a different count. The scripts default to
Expand Down Expand Up @@ -323,12 +331,19 @@ Example prompt fragment for a 2-image edit:

## Step 5 — Save the optimized prompt and ask for confirmation

Save the optimized prompt to:
Save the optimized prompt under the **current project's** `.context` directory:

```
skills/zenmux-image-generation/prompts/<YYYYMMDD-HHMMSS>-<short-slug>.md
.context/prompts/zenmux-image-generation/<YYYYMMDD-HHMMSS>-<short-slug>.md
```

This path is relative to the project directory (your current working
directory) — **not** to the skill folder. For example, if the user is working
in `/Users/me/myapp`, the prompt file lands at
`/Users/me/myapp/.context/prompts/zenmux-image-generation/20260620-153512-poster.md`.
Use the Write tool to create it; it makes the parent directories for you, so you
don't need a separate `mkdir`.

Use this exact format — the metadata header is for humans, the body after the
`---` separator is what the script sends to the API:

Expand Down Expand Up @@ -370,7 +385,7 @@ Once the user confirms, run:
uv run --project skills/zenmux-image-generation python \
skills/zenmux-image-generation/scripts/generate_openai.py \
--model "<model>" \
--prompt-file "skills/zenmux-image-generation/prompts/<file>.md" \
--prompt-file ".context/prompts/zenmux-image-generation/<file>.md" \
--n 4 \
--size "<size>" \
--quality "<quality>"
Expand All @@ -383,7 +398,7 @@ for an OpenAI image model, use the Gemini / Vertex AI-compatible script:
uv run --project skills/zenmux-image-generation python \
skills/zenmux-image-generation/scripts/generate_gemini.py \
--model "<model>" \
--prompt-file "skills/zenmux-image-generation/prompts/<file>.md" \
--prompt-file ".context/prompts/zenmux-image-generation/<file>.md" \
--n 4 \
--size "<size>" \
--quality "<quality>"
Expand All @@ -402,7 +417,7 @@ URL — the script handles all of them. Example for a 2-image edit:
uv run --project skills/zenmux-image-generation python \
skills/zenmux-image-generation/scripts/generate_openai.py \
--model "openai/gpt-image-2" \
--prompt-file "skills/zenmux-image-generation/prompts/<file>.md" \
--prompt-file ".context/prompts/zenmux-image-generation/<file>.md" \
--n 4 --size "1024x1536" --quality "high" \
--reference-image "/Users/me/Pictures/woman.png" \
--reference-image "https://example.com/jacket.jpg"
Expand Down
Empty file.