Skip to content

Add image_edit tool for Codex image editing - #29958

Closed
MaxMa04 wants to merge 1 commit into
NousResearch:mainfrom
MaxMa04:feat/image-edit-tool
Closed

Add image_edit tool for Codex image editing#29958
MaxMa04 wants to merge 1 commit into
NousResearch:mainfrom
MaxMa04:feat/image-edit-tool

Conversation

@MaxMa04

@MaxMa04 MaxMa04 commented May 21, 2026

Copy link
Copy Markdown

Summary

  • add a first-class image_edit tool alongside image_generate
  • route edit requests through plugin image providers with image_url, optional mask_url, and action=edit
  • extend the OpenAI Codex image provider to send GPT Image 2 edit requests via Responses image_generation with input_image
  • support local input images by converting them to data URLs before dispatch
  • document image editing and add tests for schema/request-shape/mask forwarding

Closes #29956

Tests

  • python -m pytest tests/plugins/image_gen/test_openai_codex_provider.py tests/tools/test_image_generation.py tests/agent/test_image_gen_registry.py -q -o 'addopts='

@alt-glitch alt-glitch added type/feature New feature or request comp/tools Tool registry, model_tools, toolsets comp/plugins Plugin system and bundled plugins tool/vision Vision analysis and image generation provider/openai OpenAI / Codex Responses API P3 Low — cosmetic, nice to have labels May 21, 2026
@janeza2

janeza2 commented Jun 18, 2026

Copy link
Copy Markdown

we need this

@teknium1

Copy link
Copy Markdown
Contributor

Thanks for the Codex image-editing implementation.

Automated hermes-sweeper review found that the requested capability is now implemented on main through the unified image-generation interface:

  • tools/image_generation_tool.py:1175 exposes image_url and reference_image_urls on image_generate and routes source-image requests to editing.
  • plugins/image_gen/openai-codex/__init__.py:460 advertises Codex image-input support; :525 normalizes source images before the Responses request is made.
  • ecffd290a (feat(image-gen): support Codex image inputs) and 460235d58 are on current main and shipped in v2026.7.7.
  • The linked feat(image-gen): support Codex image inputs #55828 discussion records the maintainer confirmation that Codex OAuth image-to-image/reference editing was merged via feat(image-gen): support Codex image inputs (salvage #55828) #57017.

The current design deliberately keeps this as one image_generate surface rather than adding a second model-facing tool, so this PR is redundant.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

comp/plugins Plugin system and bundled plugins comp/tools Tool registry, model_tools, toolsets P3 Low — cosmetic, nice to have provider/openai OpenAI / Codex Responses API sweeper:implemented-on-main Sweeper: behavior already present on current main tool/vision Vision analysis and image generation type/feature New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Expose image editing as first-class Hermes tool

4 participants