diff --git a/backend/open_webui/config.py b/backend/open_webui/config.py index 67632b18b..bd822d06d 100644 --- a/backend/open_webui/config.py +++ b/backend/open_webui/config.py @@ -1062,6 +1062,10 @@ USER_PERMISSIONS_CHAT_EDIT = ( os.environ.get("USER_PERMISSIONS_CHAT_EDIT", "True").lower() == "true" ) +USER_PERMISSIONS_CHAT_MULTIPLE_MODELS = ( + os.environ.get("USER_PERMISSIONS_CHAT_MULTIPLE_MODELS", "True").lower() == "true" +) + USER_PERMISSIONS_CHAT_TEMPORARY = ( os.environ.get("USER_PERMISSIONS_CHAT_TEMPORARY", "True").lower() == "true" ) @@ -1071,6 +1075,7 @@ USER_PERMISSIONS_CHAT_TEMPORARY_ENFORCED = ( == "true" ) + USER_PERMISSIONS_FEATURES_DIRECT_TOOL_SERVERS = ( os.environ.get("USER_PERMISSIONS_FEATURES_DIRECT_TOOL_SERVERS", "False").lower() == "true" @@ -1109,6 +1114,7 @@ DEFAULT_USER_PERMISSIONS = { "file_upload": USER_PERMISSIONS_CHAT_FILE_UPLOAD, "delete": USER_PERMISSIONS_CHAT_DELETE, "edit": USER_PERMISSIONS_CHAT_EDIT, + "multiple_models": USER_PERMISSIONS_CHAT_MULTIPLE_MODELS, "temporary": USER_PERMISSIONS_CHAT_TEMPORARY, "temporary_enforced": USER_PERMISSIONS_CHAT_TEMPORARY_ENFORCED, }, diff --git a/backend/open_webui/routers/users.py b/backend/open_webui/routers/users.py index d1046bced..781676567 100644 --- a/backend/open_webui/routers/users.py +++ b/backend/open_webui/routers/users.py @@ -88,6 +88,7 @@ class ChatPermissions(BaseModel): file_upload: bool = True delete: bool = True edit: bool = True + multiple_models: bool = True temporary: bool = True temporary_enforced: bool = False diff --git a/src/lib/components/admin/Users/Groups.svelte b/src/lib/components/admin/Users/Groups.svelte index e287feb1d..5c37badfd 100644 --- a/src/lib/components/admin/Users/Groups.svelte +++ b/src/lib/components/admin/Users/Groups.svelte @@ -63,6 +63,7 @@ file_upload: true, delete: true, edit: true, + multiple_models: true, temporary: true, temporary_enforced: false }, diff --git a/src/lib/components/admin/Users/Groups/Permissions.svelte b/src/lib/components/admin/Users/Groups/Permissions.svelte index 5dac0de94..3b722c432 100644 --- a/src/lib/components/admin/Users/Groups/Permissions.svelte +++ b/src/lib/components/admin/Users/Groups/Permissions.svelte @@ -24,6 +24,7 @@ delete: true, edit: true, file_upload: true, + multiple_models: true, temporary: true, temporary_enforced: false }, @@ -272,6 +273,14 @@ +
+
+ {$i18n.t('Allow Multiple Models in Chat')} +
+ + +
+
{$i18n.t('Allow Temporary Chat')} diff --git a/src/lib/components/chat/ModelSelector.svelte b/src/lib/components/chat/ModelSelector.svelte index 62629cad2..9c57a15ba 100644 --- a/src/lib/components/chat/ModelSelector.svelte +++ b/src/lib/components/chat/ModelSelector.svelte @@ -54,58 +54,60 @@
- {#if selectedModelIdx === 0} -
- - - -
- {:else} -
- - + +
+ {:else} +
+ + - -
+ + + + + + + {/if} {/if} {/each}