Enhance SwarmUI settings by adding a scheduler property and updating the client to send clip stop at layer instead of clip skip. Added tests to verify the new behavior.
This commit is contained in:
@@ -90,9 +90,15 @@ internal sealed class SwarmUiClient
|
||||
body["sampler"] = settings.Sampler;
|
||||
}
|
||||
|
||||
if (!string.IsNullOrWhiteSpace(settings.Scheduler))
|
||||
{
|
||||
body["scheduler"] = settings.Scheduler;
|
||||
}
|
||||
|
||||
if (settings.ClipSkip > 0)
|
||||
{
|
||||
body["clipskip"] = settings.ClipSkip;
|
||||
// SwarmUI "CLIP Stop At Layer" — clip skip N is layer -N from the end.
|
||||
body["clipstopatlayer"] = -settings.ClipSkip;
|
||||
}
|
||||
|
||||
using var content = new StringContent(JsonSerializer.Serialize(body), Encoding.UTF8, "application/json");
|
||||
|
||||
Reference in New Issue
Block a user