Skip to content

feat: plugin-registered image models for native image_generate (async providers) #60144

Open

Description

@MercuryOoO
  • I have verified this feature I'm about to request hasn't been suggested before.

Describe the enhancement you want to request

Native image_generate (2.2.x, experimental.image_generate) only works with type: "image" models from the provider catalog. Providers with a different image API cannot be used: ModelScope, for example, uses an async submit → poll → result flow and cannot be expressed as a catalog image model.

Today the only option is a custom tool plugin. We maintain one, but it has to reimplement progress, polling, notifications, output files and display; the native image tool, job lifecycle and completion notifications cannot be reused.

Proposal: let plugins register an image model/provider for the native tool — model metadata (providerID/modelID, capabilities, variants) plus a generate handler that may return an async job or stream. image_generate keeps owning its schema, permissions, job lifecycle, completion notification, output path and image rendering.

This is an extension point, not a request for the core team to maintain more image providers.

Related: #37713 (image generation domain; the design notes that async job protocols differ across providers), #51802 (plugin provider registration currently does not execute).

Benefit: users can connect free or self-hosted image APIs (ModelScope, ComfyUI, etc.) and still get native progress, notifications and preview.

Activity

  1. opencodejr commented on Oct 29, 2026

    @opencodejr
    Contributor

    Thanks for the detailed proposal, @MercuryOoO! To restate it: you'd like plugins to be able to register an image model with their own generate handler, which may be an async job or a stream. The native image_generate tool would then handle the schema, permissions, job lifecycle, completion notice, output path and preview for providers like ModelScope or ComfyUI.

    Today image_generate only takes image models from the provider catalog, which it loads through the model's package, and the plugin API has no hook for supplying a generate handler. So this would need a new plugin API extension point; a standalone plugin can't do it. Maintainers will consider it.

    Related:

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions