2025-11-12 11:15:40 +08:00
2025-11-06 14:46:12 +08:00
ext
2025-08-04 16:58:41 +08:00
gr
2025-11-06 14:18:51 +08:00
2025-11-03 11:27:28 +08:00
2025-11-03 11:27:28 +08:00
mdl
2025-07-28 14:33:14 +08:00
2025-11-12 11:15:40 +08:00
2025-11-12 11:15:40 +08:00
gr
2025-11-06 14:18:51 +08:00
2025-10-28 11:12:30 +08:00
2025-10-28 11:10:33 +08:00
2025-08-06 18:22:23 +08:00
2025-07-26 14:31:21 +08:00
2025-07-28 10:21:55 +08:00
2025-10-29 16:12:25 +08:00
bnb
2025-10-28 18:09:41 +08:00
2025-09-18 11:22:12 +08:00
2025-08-13 18:10:57 +08:00
2025-08-06 12:19:44 +08:00
2025-07-26 14:52:42 +08:00
2025-11-11 12:17:53 +08:00

Stable Diffusion WebUI Forge - Neo

[ Classic | Neo ]

UI

Stable Diffusion WebUI Forge is a platform on top of the original Stable Diffusion WebUI by AUTOMATIC1111, to make development easier, optimize resource management, speed up inference, and study experimental features.
The name "Forge" is inspired by "Minecraft Forge". This project aims to become the Forge of Stable Diffusion WebUI.

- lllyasviel
(paraphrased)


"Neo" mainly serves as an continuation for the "latest" version of Forge, which was built on Gradio 4.40.0 before lllyasviel became too busy... Additionally, this fork is focused on optimization and usability, with the main goal of being the lightest WebUI without any bloatwares.

Tip

How to Install


Features [Oct. 29]

Most base features of the original Automatic1111 Webui should still function

New Features

  • Support Wan 2.2
    • txt2img, img2img, txt2vid, img2vid
    • use Refiner to achieve High Noise / Low Noise switching
      • enable Refiner in Settings/Refiner

Important

To export a video, you need to have FFmpeg installed

Note

Since the layers between Qwen-Image and Qwen-Image-Edit are exactly the same, to be properly detected as an Edit model, the model needs to include "qwen" and "edit" in its path, either the file name or folder name.

Note

Since the layers between Flux-Dev, Flux-Krea, and Flux-Kontext are exactly the same, to be properly detected as a Kontext model, the model needs to include "kontext" in its path, either the file name or folder name.

  • Support Multi-Image Inputs for Qwen-Image-Edit and Flux-Kontext
  • Support Nunchaku (SVDQ) Models
    • flux-dev, flux-krea, flux-kontext, qwen-image, qwen-image-edit, t5
  • Support Lumina-Image-2.0
    • Neta-Lumina, NetaYume-Lumina
  • Support Chroma
  • Rewrite Preset System
    • now actually remembers the checkpoint/module selection for each preset
  • Support uv package manager
    • requires manually installing uv
    • drastically speed up installation
    • see Commandline
  • Support SageAttention, FlashAttention, and fast fp16_accumulation
  • Implement RescaleCFG
    • reduce burnt colors; mainly for v-pred checkpoints
    • enable in Settings/UI Alternatives
  • Implement MaHiRo
    • alternative CFG calculation; improve prompt adherence
    • enable in Settings/UI Alternatives
  • Implement Epsilon Scaling
    • enable in Settings/Stable Diffusion
  • Support loading upscalers in half precision
    • speed up; reduce quality
    • enable in Settings/Upscaling
  • Support running tile composition on GPU
    • enable in Settings/Upscaling
  • Update spandrel
    • support new Upscaler architectures
  • Add pillow-heif package
    • support .avif and .heif images

Removed Features

  • SD2
  • SD3
  • Forge Spaces
  • Hypernetworks
  • CLIP Interrogator
  • Deepbooru Interrogator
  • Textual Inversion Training
  • Most built-in Extensions
  • Some built-in Scripts
  • Some Samplers
  • Sampler in RadioGroup
  • Unix .sh launch scripts
    • You can still use this WebUI by simply copying a launch script from other working WebUI

Optimizations

  • No longer git clone any repository on fresh install
  • Fix memory leak when switching checkpoints
  • Remove unused cmd_args
  • Remove unused args_parser
  • Remove unused shared_options
  • Remove legacy codes
  • Fix some typos
  • Remove redundant upscaler codes
    • put every upscaler inside the ESRGAN folder
  • Improve ForgeCanvas
    • hotkeys
    • brush adjustments
    • customization
    • deobfuscate
  • Optimize upscaler logics
  • Optimize certain operations in Spandrel
  • Improve memory management
  • Improve color correction
  • Update the implementation for uni_pc and LCM samplers
  • Revamp settings
    • improve formatting
    • update descriptions
  • Check for Extension updates in parallel
  • Move embeddings folder into models folder
  • Disable Refiner by default
    • enable again in Settings/Refiner
  • Lint & Format
  • Update Pillow
    • faster image processing
  • Update protobuf
    • faster insightface loading
  • Update to latest PyTorch
    • torch==2.8.0+cu128
    • xformers==0.0.32

Note

If your GPU does not support the latest PyTorch, manually install older version of PyTorch

  • No longer install open-clip twice
  • Update some packages to newer versions
  • Update recommended Python to 3.11.9
  • many more... ™️

Commandline

These flags can be added after the set COMMANDLINE_ARGS= line in the webui-user.bat (separate each flag with space)

A1111 built-in

  • --xformers: Install the xformers package to speed up generation
  • --port: Specify a server port to use
    • defaults to 7860
  • --api: Enable API access

  • Once you have successfully launched the WebUI, you can add the following flags to bypass some validation steps in order to improve the Startup time
    • --skip-prepare-environment
    • --skip-install
    • --skip-python-version-check
    • --skip-torch-cuda-test
    • --skip-version-check

Important

Remove them if you are installing an Extension, as those also block Extension from installing requirements

by. Forge

  • For RTX 30 and above, you can add the following flags to slightly increase the performance; but in rare occurrences, they may cause OutOfMemory errors or even crash the WebUI; and in certain configurations, they may even lower the speed instead

    • --cuda-malloc
    • --cuda-stream
    • --pin-shared-memory
  • --forge-ref-a1111-home: Point to an Automatic1111 installation to load its models folders

    • i.e. Stable-diffusion, text_encoder

by. Neo

  • --uv: Replace the python -m pip calls with uv pip to massively speed up package installation
  • --uv-symlink: Same as above; but additionally pass --link-mode symlink to the commands
    • significantly reduces installation size (~7 GB to ~100 MB)

Important

Using symlink means it will directly access the packages from the cache folders; refrain from clearing the cache when setting this option

  • --forge-ref-comfy-home: Point to an ComfyUI installation to load its models folders

    • i.e. diffusion_models, clip
  • --model-ref: Points to a central models folder that contains all your models

    • said folder should contain subfolders like Stable-diffusion, Lora, VAE, ESRGAN, etc.

Important

This simply replaces the models folder, rather than adding on top of it

  • --sage: Install the sageattention package to speed up generation
    • will also attempt to install triton automatically

Note

For RTX 50 users, you may need to manually install sageattention 2 instead

  • --flash: Install the flash_attn package to speed up generation
  • --fast-fp16: Enable the allow_fp16_accumulation option
    • requires PyTorch 2.7.0 +
with SageAttention 2
  • --sage2-function: Select the function used by SageAttention 2

    • options:
      • auto (default)
      • fp16_triton
      • fp16_cuda
      • fp8_cuda
  • If you are getting NaN errors, try:

--sage2-function fp16_cuda --sage-quant-gran per_warp --sage-accum-dtype fp16+fp32

Installation

  1. Install git

  2. Clone the Repo

    git clone https://github.com/Haoming02/sd-webui-forge-classic sd-webui-forge-neo --branch neo
    
  3. Setup Python

Recommended Method
  • Install uv
  • Set up venv
    cd sd-webui-forge-neo
    uv venv venv --python 3.11 --seed
    
  • Add the --uv flag to webui-user.bat
Standard Method
  1. (Optional) Configure Commandline
  2. Launch the WebUI via webui-user.bat
  3. During the first launch, it will automatically install all the requirements
  4. Once the installation is finished, the WebUI will start in a browser automatically

Install sageattention 2

Expand
  1. Ensure the WebUI can properly launch already, by following the installation steps first

  2. Open the console in the WebUI directory

    cd sd-webui-forge-neo
    
  3. Start the virtual environment

    venv\scripts\activate
    
  4. Create a new folder

    mkdir repo
    cd repo
    
  5. Clone the repo

    git clone https://github.com/thu-ml/SageAttention
    cd SageAttention
    
  6. Install the library

    pip install -e . --no-build-isolation
    
    • If you installed uv, use uv pip install instead
    • The installation takes a few minutes

Alternatively

for Windows

pip install sageattention...win_amd64.whl
  • If you installed uv, use uv pip install instead
  • Important: Download the correct .whl for your PyTorch version

Install older PyTorch

Expand
  1. Navigate to the WebUI directory
  2. Edit the webui-user.bat file
  3. Add a new line to specify an older version:
set TORCH_COMMAND=pip install torch==2.1.2 torchvision==0.16.2 --extra-index-url https://download.pytorch.org/whl/cu121

Install FFmpeg

Expand

for Windows

  1. Download the FFmpeg .7z
  2. Extract the contents to a folder of choice
  3. Add the bin folder within to the system PATH
    • Edit the System Environment Variables > Environment Variables > Path
  4. Verify the installation by entering ffmpeg in a command prompt

Attention

Important

The --xformers and --sage args are only responsible for installing the packages, not whether its respective attention is used (this also means you can remove them once the packages are successfully installed)

Forge Neo tries to import the packages and automatically choose the first available attention function in the following order:

  1. SageAttention
  2. FlashAttention
  3. xformers
  4. PyTorch
  5. Basic

Tip

To skip a specific attention, add the respective disable arg such as --disable-sage

Note

The VAE only checks for xformers, so --xformers is still recommended even if you already have --sage

In my experience, the speed of each attention function for SDXL is ranked in the following order:

  • SageAttentionFlashAttention > xformers > PyTorch >> Basic

Note

SageAttention is based on quantization, so its quality might be slightly worse than others

Important

When using SageAttention 2, both positive prompts and negative prompts are required; omitting negative prompts can cause NaN issues


Issues & Requests

  • Issues about removed features will simply be ignored
  • Issues regarding installation will be ignored if it's obviously user-error
  • Non-Windows platforms will not be supported, as I cannot verify nor maintain them

Special thanks to AUTOMATIC1111, lllyasviel, and comfyanonymous, kijai, city96,
along with the rest of the contributors,
for their invaluable efforts in the open-source image generation community

S
Description
table Diffusion WebUI Forge
Readme
145 MiB
Languages
Python 94.2%
JavaScript 1.9%
Cuda 1.7%
C++ 0.9%
CSS 0.6%
Other 0.6%