mirror of
https://github.com/open-webui/open-webui.git
synced 2026-07-18 10:48:00 -05:00
[PR #15178] [CLOSED] Feat/add docker model runner support #62602
Reference in New Issue
Block a user
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/open-webui/open-webui/pull/15178
Author: @rw4lll
Created: 6/20/2025
Status: ❌ Closed
Base:
dev← Head:feat/add-docker-model-runner-support📝 Commits (7)
dd33818Add Docker Model Runner backend17c677aadding Docker Model Runner backendd1534f0Simplify DMR_BASE_URL logic4ae2fdarollback redundant changeb1be5b6Adjust DMR_BASE_URL0f70e87fixes and improvementsf5b1ae4Support DMR in the admin area📊 Changes
16 files changed (+1659 additions, -7 deletions)
View changed files
📝
.env.example(+3 -0)📝
README.md(+19 -1)📝
backend/open_webui/config.py(+23 -0)📝
backend/open_webui/env.py(+1 -0)📝
backend/open_webui/main.py(+18 -0)➕
backend/open_webui/routers/docker_model_runner.py(+748 -0)📝
backend/open_webui/utils/chat.py(+11 -0)📝
backend/open_webui/utils/models.py(+14 -4)📝
docker-compose.yaml(+2 -0)➕
src/lib/apis/dmr/index.ts(+455 -0)📝
src/lib/components/AddConnectionModal.svelte(+21 -1)📝
src/lib/components/admin/Settings/Connections.svelte(+97 -1)➕
src/lib/components/admin/Settings/Connections/DMRConnection.svelte(+86 -0)➕
src/lib/components/admin/Settings/Connections/ManageDMRModal.svelte(+45 -0)➕
src/lib/components/admin/Settings/Models/Manage/ManageDMR.svelte(+115 -0)📝
src/lib/constants.ts(+1 -0)📄 Description
Changelog Entry
Description
Added Docker Model Runner (DMR) integration to Open WebUI, enabling local AI model hosting through Docker backend with full chat completion, text generation, and model management capabilities. This implementation follows established patterns from Ollama and OpenAI providers while maintaining DMR-specific characteristics for single-server, local-only operation.
Added
Backend DMR Router (
backend/open_webui/routers/docker_model_runner.py) to implement DMR-specific endpointsDMR Configuration Integration (
backend/open_webui/config.py): Added persistent configuration for DMR settingsENABLE_DMR_API: Toggle DMR functionalityDMR_BASE_URL: DMR server URL configurationDMR_API_CONFIGS: DMR API configuration storageModel Integration (
backend/open_webui/utils/models.py): Integrated DMR models into the global model loading systemChat Integration (
backend/open_webui/utils/chat.py): Added DMR chat completion routingFrontend DMR API Module (
src/lib/apis/dmr/index.ts)Frontend UI Components:
DMRConnection.svelte: Connection management componentManageDMRModal.svelte: Modal wrapper for DMR managementManageDMR.svelte: DMR model browser (read-only)Admin Settings Integration (
src/lib/components/admin/Settings/Connections.svelte): Added DMR configuration sectionConstants Integration (
src/lib/constants.ts): AddedDMR_API_BASE_URLconstantLogging Integration (
backend/open_webui/env.py): Added"DMR"to log sources for proper logging configurationChanged
Router Integration (
backend/open_webui/main.py): Added DMR router inclusion with/dmrprefixModel Loading System: Include DMR models alongside OpenAI and Ollama models
Chat Completion System: Extended to route DMR model requests to appropriate backend
Admin Settings UI: Enhanced connections panel to include DMR configuration management
Error Handling: Implemented consistent
"DMR:"prefix for all DMR-related error messagesDeprecated
None
Removed
None
Fixed
None
Security
None
Breaking Changes
None: This is a new feature addition that doesn't break existing functionality
Additional Information
Screenshots or Videos
Contributor License Agreement
By submitting this pull request, I confirm that I have read and fully agree to the Contributor License Agreement (CLA), and I am providing my contributions under its terms.
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.