-
Notifications
You must be signed in to change notification settings - Fork 332
REST API
Dowon edited this page Mar 5, 2024
·
6 revisions
{
"prompt": "masterpiece, 1girl, <lora:march7th:1>",
"sampler_name": "Euler",
"alwayson_scripts": {
"ADetailer": {
"args": [
true,
false,
{
"ad_model": "face_yolov8n.pt",
"ad_model_classes": "",
"ad_prompt": "",
"ad_negative_prompt": "",
"ad_confidence": 0.3,
"ad_mask_k_largest": 0,
"ad_mask_min_ratio": 0.0,
"ad_mask_max_ratio": 1.0,
"ad_dilate_erode": 32,
"ad_x_offset": 0,
"ad_y_offset": 0,
"ad_mask_merge_invert": "None",
"ad_mask_blur": 4,
"ad_denoising_strength": 0.4,
"ad_inpaint_only_masked": true,
"ad_inpaint_only_masked_padding": 0,
"ad_use_inpaint_width_height": false,
"ad_inpaint_width": 512,
"ad_inpaint_height": 512,
"ad_use_steps": true,
"ad_steps": 28,
"ad_use_cfg_scale": false,
"ad_cfg_scale": 7.0,
"ad_use_checkpoint": false,
"ad_checkpoint": "Use same checkpoint",
"ad_use_vae": false,
"ad_vae": "Use same VAE",
"ad_use_sampler": false,
"ad_sampler": "DPM++ 2M Karras",
"ad_use_noise_multiplier": false,
"ad_noise_multiplier": 1.0,
"ad_use_clip_skip": false,
"ad_clip_skip": 1,
"ad_restore_face": false,
"ad_controlnet_model": "None",
"ad_controlnet_module": "None",
"ad_controlnet_weight": 1.0,
"ad_controlnet_guidance_start": 0.0,
"ad_controlnet_guidance_end": 1.0
}
]
}
}
}
The first true
(ad_enable) is not required. In this case, ad_enable will be true
.
The second false
is skip_img2img, which is used with img2img and can be omitted in the API call.
{
"prompt": "masterpiece, 1girl, <lora:march7th:1>",
"sampler_name": "Euler",
"alwayson_scripts": {
"ADetailer": {
"args": [
{
"ad_model": "face_yolov8n.pt"
}
]
}
}
}
All omitted arguments will have default values. Note that the default value for ad_model
is "None"
.
Default means adetailer's default, not user's default.
{
"prompt": "masterpiece, 1girl, <lora:march7th:1>",
"sampler_name": "Euler",
"alwayson_scripts": {
"ADetailer": {
"args": [
{
"ad_model": "person_yolov8s-seg.pt"
},
{
"ad_model": "person_yolov8s-seg.pt"
},
{
"ad_model": "person_yolov8s-seg.pt"
},
{
"ad_model": "person_yolov8s-seg.pt"
},
{
"ad_model": "person_yolov8s-seg.pt"
},
{
"ad_model": "person_yolov8s-seg.pt"
},
{
"ad_model": "person_yolov8s-seg.pt"
},
{
"ad_model": "face_yolov8n.pt"
}
]
}
}
}
You can send as many models as you want. However, requests that exceed the max models set in the settings tab can cause errors.