Skip to content

Add conversational image editing and attachment improvements - #137

Merged
artcc merged 1 commit into
developfrom
feature/issue-135
Oct 2, 2026
Merged

artcc merged 1 commit into
developfrom
feature/issue-135

Conversation

@artcc

@artcc artcc commented Oct 2, 2026

Copy link
Copy Markdown
Owner

Summary

Related to #135.

  • Add edit_image so a tool-capable chat model can edit a selected image from the conversation using the configured dedicated image specialist and /images/edits.
  • Add attachment thumbnails and previews, ordered multi-image selection from Photos, and an Attach Again action on conversation images.
  • Scope asynchronous attachment and drag-and-drop preparation to the active conversation, preserving selection order and discarding stale results after navigation, cancellation, or a data reset.
  • Share one durable image-operation attempt per user turn across generation and editing, including cancellation before transcript delivery, regeneration, legacy transcripts, backups, and branching.
  • Serialize historical assistant images as user-side visual context for OpenAI-compatible Chat Completions, preserving tool-call/result ordering and the stored conversation.
  • Add focused regression coverage and update specifications, localized strings, the changelog, and English/Spanish TestFlight notes.

How editing works

With a compatible dedicated image model selected under Image and Vision → Image Generation, the chat can resolve an earlier image by its attachment UUID and send the actual image plus the requested change to /images/edits. For example: generate a cat, then ask to change the background while keeping the same cat. Reattachment is optional when referring to an image already in the conversation; Attach Again lets the user select one explicitly.

Editing targets one image per request. The principal must support tool calling and lack native image generation; the selected dedicated image specialist must advertise vision and its provider must support image editing. Failed edits do not fall back to text-only generation.

Verification

  • The maintainer manually tested generation followed by an edit of the same image and confirmed the flow worked.
  • During implementation, the iOS simulator app and test products compiled successfully.
  • The macOS app compiled successfully; only the expected entitlement warnings from disabling code signing remained.
  • git diff --check passed during implementation.
  • Regression tests cover request serialization, tool availability and shared attempt limits, cancellation/restoration, attachment lifecycle, drag-and-drop context changes, reattachment, and backup references. The final test sources were compiled but not executed.

Scope

This PR focuses on single-image conversational editing and attachment UX. Clipboard image paste, multi-image reference editing, and delegated editing through chat-based image specialists are outside this change.

- Add `edit_image` tool support for compatible vision image models
- Preserve image generation and editing attempt state across restore and regenerate flows
- Support ordered multi-image photo library selection and attachment previews
- Reuse conversation images as new pending attachments without persisting duplicates
- Scope pending drag-and-drop and photo loads to the active conversation
- Update chat and repository tests for image history, reattachment, and tool definitions
- Refresh changelog and TestFlight notes for the new image workflows
@artcc
artcc merged commit 54da9c8 into develop Oct 2, 2026
2 checks passed
@artcc
artcc deleted the feature/issue-135 branch October 2, 2026 05:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant