Preset
Preset is a collection of predefined parameters used for quickly generating an image with a specific style or set of parameters. These predefined configuration files are located in the preset
directory, with each file corresponding to a preset.
Using them is simple, you just need to specify the preset
parameter when passing the arguments. For example:
import requests
url = "http://127.0.0.1:7866/v1/engine/generate"
params = {
"preset": "anime",
"prompt": "a dog playing with a ball"
}
response = requests.post(url, json=params)

For instance, let's switch to using the sai
preset:
import requests
url = "http://127.0.0.1:7866/v1/engine/generate"
params = {
"preset": "sai",
"prompt": "a dog playing with a ball"
}
response = requests.post(url, json=params)

Last modified: 03 八月 2024