DEDUPED Hot AI repos. Real use cases. What people build. Get the Monday 5

How to revise an existing image without losing prior edits with GPT Image Skill

Edit a picture you already have, or refine the last result, while keeping references attached.

Short answer: Place the source image inside the project, or use an explicit filesystem path or @path reference to it; then ask for the change in Codex with $gpt-image Change the sky to dusk and keep the layout, using @path/to/source.png as the edit target; For a follow-up change to the result you just made, reuse the last returned PATH as the new edit target and reattach every reference you still need. All steps.

  • Content
  • Intermediate
  • 30 minutes
  • From the README
  • Codex
  • Claude Code

Who it is forA designer or product team member who has an existing image, such as a mockup or character sheet, and needs targeted changes in the same project.

The problemEach generation call is ephemeral, so a revision built from the original source silently discards earlier edits.

The outcomeAn edited PNG saved alongside the earlier output, with the edit chain kept intact.

What you need first

  • A ChatGPT or Codex plan that permits image generation (the README says Codex image generation is not available on the Free plan)
  • Node.js 22 or newer
  • Git, for installing from GitHub
  • Codex CLI signed in with ChatGPT, or a host that provides subscription-native image_gen

Steps

  1. Place the source image inside the project, or use an explicit filesystem path or @path reference to it.
  2. Ask for the change in Codex with $gpt-image Change the sky to dusk and keep the layout, using @path/to/source.png as the edit target. (inferred, check the README)
  3. For a follow-up change to the result you just made, reuse the last returned PATH as the new edit target and reattach every reference you still need.
  4. Compare the new PNG with the previous one and confirm only the requested part changed.

Prompt for your agent

Using the GPT Image Skill in <repo path>, edit <existing image path> with the change <requested change> and keep the rest of the layout. Expect a new PNG in /generated-images and a PATH=... line. Verify that the previous output was the edit target for any follow-up request.

Caveat. A pasted image in chat is not automatically passed to the nested Codex process, so the source must be a readable file path inside the project.

Use this in your AI agent

Ask your agent

Using the Deduped MCP, get the setup steps for GENEXIS-AI/gpt-image-skill and "Revise an existing image without losing prior edits"

Add Deduped to Claude Code once

claude mcp add --transport http deduped https://dedupedai.com/mcp

Cursor, ChatGPT, others

Share: X LinkedIn Hacker News Email Copy link

Third-party repos we don't own. AI-written use cases can be wrong. Disclaimer