| conf | ||
| lib | ||
| .gitignore | ||
| bot.py | ||
| comfyui-discord.sh | ||
| README.md | ||
comfyui-discord
A simplified interface to ComfyUI through Discord
Quick Start
-
Run
comfyui-discord.shto createsettings.json -
Modify
settings.json, e.g.{ "token": "Your Discord bot's token here" "api_url": "http://127.0.0.1:8188", ... }...where
tokenis set to your Discord bot's token andapi_urlis the address to your running & accessible ComfyUI web interface. -
Set a channel's topic to
example-workflow -
Run
comfyui-discord.sh -
Send a message in that channel, e.g.
steps25 cfg8 width512 height480 > a bowl of fruit on a wooden desk -red, strawberry, red apple, raspberry, metal x4 -
Observe the bot's response with attachment
Explanation
The message above is broken into a several compontents:
steps- 25cfg- 8width- 512height- 480positive: "a bowl of fruit on a wooden desk"negative: "red, strawberry, red apple, raspberry, metal"repeat_n_times: 4
...and is passed to ComfyUI by loading example-workflow.json and making text replacements, e.g.
__STEPS__with25__POSITIVE__witha bowl of fruit on a wooden desk
The example-workflow_settings.json file can be used to provide default values that are left unspecified in the user's message. For example, keys width and height can be set in example-workflow_settings.json and used for direct replacements of __WIDTH__ and __HEIGHT__ in the API workflow JSON body.