Install any skill in seconds. Free to start, no credit card required.
Get Started Free →justin-spec-dev/chatgpt-image-gen
Generate an image with ChatGPT (GPT image generation) in the user's logged-in ego lite browser and save the file into the current project directory.
Passed 10 of 17 test cases with the skill, and 5 of 17 without it.
and 6 more in the full report
8 fixed5 passed either way7 still failing2 broke
Tokens, turns and time describe resource use, not a dollar price.
One of 8 test cases the skill fixed. Same model, same prompt, with and without the skill.
The image script failed twice consecutively with exit code 1 and status `internal_error` indicating `element not found` on the composer input field. What section of the generation script JS code should be checked and updated for updated DOM selectors?
| Checked | Without skill | With skill |
|---|---|---|
| Identifies the SEL block at the top of the JS script to update selectors. | Missed | Passed |
The instructions your model reads when the skill loads.
Generate image(s) from a text description with ChatGPT via ego-browser, download them, and save them into the project. The whole happy path is one bundled script; this skill mainly covers how to call it, how to handle login, and how to finish up cleanly.
ego-browser on PATH (if ego-browser: command not found, read the ego-browser skill's references/install.md first).The installed ego lite runtime preloads the helper API the bundled scripts use: useOrCreateTaskSpace, openOrReuseTab, handOffTaskSpace, takeOverTaskSpace, listTaskSpaces, fillInput, click, js, wait, pageInfo, captureScreenshot, cliLog, completeTaskSpace — not the taskSpace / task.page / page.* facades some ego-browser docs describe. Both currently coexist, but these scripts intentionally target the helper API, so run them as-is instead of rewriting them against another API. Also: wait(...) and openOrReuseTab's timeout are in seconds, cliLog(...) is the output channel, and the embedded node runtime does not inherit shell environment variables (pass data via files, like the script does, or interpolate into the heredoc).
Decide the output path. Save into the current working directory by default (the user said "保存到项目目录"). Derive a concise filename from the image description in the user's language, e.g. 西安旅游攻略图.png for "帮我生成一张西安旅游攻略图". If the user gave a name or directory, use that. Default extension .png (ChatGPT usually returns PNG, but may return JPEG/WebP — the script corrects the extension to the real format, see Notes).
Run the generator (takes 1–5 minutes; image generation is slow — set the Bash timeout to 420s to cover the script's worst case):
bash <this-skill-dir>/scripts/gen-image.sh "<image description>" "<absolute output path>"
# or, to save the whole grid instead of just the largest image:
bash <this-skill-dir>/scripts/gen-image.sh --all "<image description>" "<absolute output path>"
# or, to recover/grab images from an existing conversation (no new prompt):
bash <this-skill-dir>/scripts/gen-image.sh [--all] --resume "<conversation url>" "<absolute output path>"
It reuses the task space chatgpt image generation, opens a fresh ChatGPT chat, sends the description, polls until the image(s) appear, downloads them with the page's session cookies, and writes the file(s). Runs are serialized by a lock: if another run is already active the script exits immediately with {"status":"busy", ...}. The final line of output is always a JSON status — including on failure — so read it before deciding what to do.
Handle the exit code:
0 with {"status":"ok", ...} — path (single image) or paths (with --all) lists the saved file(s). Continue to step 4.2 (bad_arguments) — the invocation was wrong (missing/extra args, unknown option). Fix the command; no browser run happened.1 (busy) — another gen-image.sh run holds the lock. Wait for it to finish, then retry.42 (login_required) — hand the browser to the user so they can log in:
bash <this-skill-dir>/scripts/login.sh handoff
The JSON has done: true when the handoff succeeded. Then tell the user to log into ChatGPT in the ego lite window and say when done. Only after they confirm, take control back with:
bash <this-skill-dir>/scripts/login.sh takeover
test cases passed, vs 5 / 17 without
More skills from the same source and nearby in the registry, with their headline benchmark lift.