/sd-webui-infotext-example

This is an example of how to read and write Infotext / PNG Info when developing an extension for Stable Diffusion web UI

Primary LanguagePython

sd-webui-infotext-example

this is an extension for developers it serves no purpose for the end user

this is an example of how to read and write infotext when developing an extension for Stable Diffusion web UI.

Infotext aka PNG Info, the purpose of which is to allow an image to be re-creatable by saving the generation parameters in the images itself.

Webui provides an interface to read and write infotext, but its usage is not well documented.

This is an example in the form of extension with inline documentation on how to read and write infotext.

Three examples are provided basic advance and selectable script.

Read the basic first then the advanced or selectable scripts example or if applicable.

basic example should work for simple extensions.

advance example is for extensions with lost of info to write and would prefer to write it in a more structured way.

selectable script example is for selectable dropdown scripts, it demonstrates how to allow automatically switch to the script.