Skip to main content
Version: v2

AUTOMATIC1111 (Local)

Connect to a local instance of the AUTOMATIC1111 Stable Diffusion Web UI. This gives you full control over models and generation parameters.

  • Setup Requirements:
    • The A1111 server must be running. It must be started with the --api flag to enable the API.
    • CORS (Cross-Origin Resource Sharing) must be enabled. The easiest way is to start the server with the --cors-allow-origins="*" flag.
    • In this app, enter the full URL of the server (e.g., http://127.0.0.1:7860) into the A1111 > API Endpoint field.
    • For Forge-based variants, see the Troubleshooting section below.
  • Settings (JSON):
    • You can provide a JSON object with preferred default parameters (sampler, steps, etc.). These will be merged with prompts generated by the Storyteller AI.

Speed-up Example (LCM): Below is an example parameter configuration for accelerating image generation using LCM (Latent Consistency Models).

{
"steps": 8,
"cfg_scale": 2,
"sampler_name": "LCM",
"scheduler": "Normal",
"prompt": "masterpiece, best quality, highres <lora:LCMTurboMix_LCM_Sampler:1>",
"negative_prompt": "worst quality, low quality, twins"
}

Troubleshooting​

Local Server Not Working​

Try pressing the Test Connection button to diagnose. "Blocked by CORS" is the most common issue. Ensure the server is started with the correct flags (e.g., --cors-allow-origins="*" for A1111) and that the endpoint URL in this app is correct.

API Calls Fail with Stable Diffusion WebUI Forge​

With Stable Diffusion WebUI Forge and its derivatives, browser security features may block connections when calling a local HTTP API from an HTTPS website (such as this app). To resolve this, you need to modify the modules/initialize_util.py file in your Forge installation directory to add specific middleware. For detailed steps and code, please refer to this fix commit. This means deleting the last two lines (including the final blank line) and replacing them with four lines (including the comment). Since this is Python code, be careful not to change the indentation (the number of leading spaces on each line).