anapnoe / stable-diffusion-webui-ux

Stable Diffusion web UI UX
GNU Affero General Public License v3.0
978 stars 59 forks source link

[Feature Request]: text2img / img2img Presets #83

Open Neverdusk opened 1 year ago

Neverdusk commented 1 year ago

Is there an existing issue for this?

What would your feature do ?

I think a "Presets" feature for text2img and img2img would be incredibly useful, especially for people like me, who have relatively consistent workflows. Essentially, they would be like Styles, except instead of just applying to a prompt, a Preset would save / load all of your text2img / img2img settings, including prompt, negative, resolution, hires fix, CFG, samplers, and steps.

A new icon could be added next to the Styles icon for saving a Preset, as well as another icon for loading it. Upon loading a text2img, all text2img boxes will be replaced with the values from the preset. And ideally img2img could support its own separate presets.

As for my reason, I do a lot of work with generating characters / landscapes. I've found that I have certain favorite setups and I end up pasting in PNG info for "Read Generation Parameters" every time I open up the UI. Sometimes, when I want to switch between different setups, I'll end up doing this multiple times a setting. Presets would just allow this process to be a lot more convenient and built-in, similar to Styles.

While this might be reaching, if Presets could also hold extension information, like ControlNet settings, that would be even better.

Screenshot 2023-04-24 140519

Proposed workflow

For Loading

  1. Go to text2img
  2. Press Load Preset icon
  3. Select Preset from dropdown
  4. See all settings change in text2img to match the preset

For Saving

  1. Go to text2img
  2. Press Save Preset icon
  3. Name Preset
  4. A new Preset is created with the current text2img settings

Ideally, img2img would have a matching workflow as well, and its own presets.

Additional information

No response

anapnoe commented 1 year ago

a workaround until some more people vote for this you can drop any image with metadata in the render output area and it will load its settings and display a preview of the image if in txt2img tab you can have folders with your style presets that you drag and drop directly to render output views txt2img, img2img and extras

Neverdusk commented 1 year ago

Thanks for the workaround! I tried this, but I noticed that it seems to lock the seed of the Dynamic Prompts extension. So instead of matching the seed to each new image, it stays the same as the dropped-in input image. This seems to persist even after I change the seed back to -1, until I restart the UI entirely. This issue seems to be unique to drag-dropping images to load their settings, since Read Generation hasn't caused that to happen for me.

On a slightly related note, Presets would potentially also allow for wildcards to be saved. Since image metadata only saves the resolved wildcard (so "curly hair" instead of the "hair" wildcard), you can't easily get the original wildcard unless you've saved it separately, which is what I tend to do. Whereas a Preset would allow you to save the original prompt with wildcards in place.

bobcate commented 9 months ago

Bumping for a suggestion/request. If you are not going to implement your own preset functionality, maybe you can provide support for existing preset extensions. Three of said extensions: Preset-Utils (Shows up under Scripts drop-down menu, but it's menu doesn't open) Config-Presets (Doesn't show up in the UI at all, or maybe I couldn't find it) Model-Preset-Manager (A new button appears on the left side menu, under the txt2img/img2img buttons, but the page it opens is empty)