mirror of
https://github.com/Pasta-Devs/Marinara-Engine.git
synced 2026-12-03 19:00:50 +07:00
[PR #970] [MERGED] feat(image-gen): add Draw Things HTTP API support #4862
Labels
No labels
android
bug
bugfix
ci
client
code freeze pause
container
dependencies
docs
documentation
duplicate
enhancement
feature
feature
feature
feature-creep
fixed-in-refactor
fixed-in-staging
good first issue
help wanted
in-pr
in-pr
needs-codeowner-decision
normal-scope
old-codebase
old-codebase
pull-request
qol
question
refactor
regression
revisit later
roadmap
scope-risk
scope-risk
server
server
shared
soup
upstream
windows
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
Pasta-Devs/Marinara-Engine#4862
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/Pasta-Devs/Marinara-Engine/pull/970
Author: @etherious1804
Created: 5/18/2026
Status: ✅ Merged
Merged: 5/20/2026
Merged by: @cha1latte
Base:
staging← Head:feat/drawthings-support📝 Commits (1)
4639a2cfeat(image-gen): add Draw Things HTTP API support📊 Changes
5 files changed (+112 additions, -28 deletions)
View changed files
📝
README.md(+1 -1)📝
docs/CONFIGURATION.md(+1 -1)📝
docs/FAQ.md(+1 -1)📝
packages/server/src/services/image/image-generation.ts(+87 -21)📝
packages/shared/src/constants/image-generation-defaults.ts(+22 -4)📄 Description
Linked issue
Closes #969
Why this change
drawthingsprovider to the AUTOMATIC1111 dispatch case, but Draw Things' HTTP server diverges from A1111 enough that the path silently fails today: requests sendingcfg_scalereturnHTTP 200 {"images": []}(full generation cycle, no image), filling the connection editor's Model field causesHTTP 422because Draw Things rejectsoverride_settings, and the sampler dropdown only overlaps on five names with Draw Things' actual sampler set. Out-of-the-box Draw Things connections look configured but generate nothing.automatic1111dispatch.What changed
packages/server/src/services/image/image-generation.ts:serviceHintthrough togenerateAutomatic1111and branches onserviceHint === "drawthings".guidance_scale(notcfg_scale) andbatch_count(notn_iter/batch_size); dropsoverride_settings,scheduler,restore_faceswhich Draw Things 422s on.sharp(already a server dep, same load pattern assprites.routes.ts) and resizes img2img init images to match requestwidth/heightexactly, since Draw Things does not auto-resize like A1111/Forge does. Falls back to the original image ifsharpis unavailable.import { logger }referenced at line 1430 — pre-existing bug that prevented the file from compiling.packages/shared/src/constants/image-generation-defaults.ts:SD_WEBUI_SAMPLER_OPTIONSwith 16 Draw Things-specific samplers (UniPC AYS,DPM++ SDE Substep/Trailing/AYS,TCD,TCD Trailing,LCM,PLMS, etc.) labeled(Draw Things)so AUTOMATIC1111/Forge users can avoid them.README.md,docs/FAQ.md,docs/CONFIGURATION.md: adds Draw Things to the supported-image-providers list and to the SSRF-allowed local image backends section.drawthings.Validation
What I ran locally (prose, for reviewer reference)
Tested end-to-end on macOS / Apple M5 against Draw Things 1.20260430.0 driving the Anima 1.0 model (Qwen-Image architecture) on `127.0.0.1:7861`:
Manual verification a reviewer should still do (these are the cases I did not exercise):
Docs and release impact
README provider list, FAQ image-generation entry, and CONFIGURATION's local-URL opt-ins section all add Draw Things alongside the existing self-hosted backends. No CHANGELOG or version bump in this PR. (Docs boxes left unchecked per the same AI-Generated PR rule above — verification of docs accuracy belongs to the human reviewer.)
UI evidence (if applicable)
No new UI surface — the only client-visible change is the expanded sampler dropdown in the existing connection editor (text-only addition).
Note on the OpenRouter changes from the earlier revision
Per reviewer feedback, the OpenRouter response-parsing improvements that were bundled into the original revision of this PR have been split out into a separate PR (#1027, linked to issue #1026) so this one stays scoped to Draw Things only.
🤖 Generated with Claude Code
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.