[PR #22067] [CLOSED] feat: Add ModelsLab as image generation engine #26459

Closed
opened 2026-04-20 06:30:20 -05:00 by GiteaMirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/open-webui/open-webui/pull/22067
Author: @adhikjoshi
Created: 3/1/2026
Status: Closed

Base: mainHead: feat/modelslab-image-engine


📝 Commits (1)

  • a41aa73 feat: Add ModelsLab as image generation engine

📊 Changes

3 files changed (+118 additions, -0 deletions)

View changed files

📝 backend/open_webui/config.py (+6 -0)
📝 backend/open_webui/routers/images.py (+90 -0)
📝 src/lib/components/admin/Settings/Images.svelte (+22 -0)

📄 Description

contributor license agreement

Summary

Adds ModelsLab (https://modelslab.com) as a new image generation engine in Open WebUI, following the existing Gemini engine pattern.

ModelsLab is an AI generation API providing access to Flux, SDXL, Stable Diffusion 3.5, and 100+ community models.

Changes

  • backend/open_webui/config.py: Adds IMAGES_MODELSLAB_API_KEY PersistentConfig (env var support)
  • backend/open_webui/routers/images.py: get_image_model(), get_models(), ImagesConfig, GET+UPDATE /config, image_generations() with async polling
  • src/lib/components/admin/Settings/Images.svelte: Engine dropdown + API key config section

API details

Setup

  1. Admin > Settings > Images
  2. Set engine to ModelsLab
  3. Enter IMAGES_MODELSLAB_API_KEY
  4. Select model and generate

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/open-webui/open-webui/pull/22067 **Author:** [@adhikjoshi](https://github.com/adhikjoshi) **Created:** 3/1/2026 **Status:** ❌ Closed **Base:** `main` ← **Head:** `feat/modelslab-image-engine` --- ### 📝 Commits (1) - [`a41aa73`](https://github.com/open-webui/open-webui/commit/a41aa733b2ebdf50b0dfcb2008786787111ed52c) feat: Add ModelsLab as image generation engine ### 📊 Changes **3 files changed** (+118 additions, -0 deletions) <details> <summary>View changed files</summary> 📝 `backend/open_webui/config.py` (+6 -0) 📝 `backend/open_webui/routers/images.py` (+90 -0) 📝 `src/lib/components/admin/Settings/Images.svelte` (+22 -0) </details> ### 📄 Description contributor license agreement ## Summary Adds **ModelsLab** (https://modelslab.com) as a new image generation engine in Open WebUI, following the existing Gemini engine pattern. ModelsLab is an AI generation API providing access to Flux, SDXL, Stable Diffusion 3.5, and 100+ community models. ## Changes - **backend/open_webui/config.py**: Adds IMAGES_MODELSLAB_API_KEY PersistentConfig (env var support) - **backend/open_webui/routers/images.py**: get_image_model(), get_models(), ImagesConfig, GET+UPDATE /config, image_generations() with async polling - **src/lib/components/admin/Settings/Images.svelte**: Engine dropdown + API key config section ## API details - Auth: key-in-body (IMAGES_MODELSLAB_API_KEY env var) - Endpoint: POST https://modelslab.com/api/v6/images/text2img - Async polling: status=processing -> poll /images/fetch/{id} every 5s (up to 300s) - Models: Flux, Flux Pro, SDXL, SD 3.5, Realistic Vision, JuggernautXL - Docs: https://docs.modelslab.com ## Setup 1. Admin > Settings > Images 2. Set engine to ModelsLab 3. Enter IMAGES_MODELSLAB_API_KEY 4. Select model and generate --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
GiteaMirror added the pull-request label 2026-04-20 06:30:20 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/open-webui#26459