diff --git a/backend/open_webui/retrieval/utils.py b/backend/open_webui/retrieval/utils.py index 772f37fbec..c83c2d1207 100644 --- a/backend/open_webui/retrieval/utils.py +++ b/backend/open_webui/retrieval/utils.py @@ -795,7 +795,9 @@ def get_embedding_function( return await asyncio.to_thread( ( lambda query, prefix=None: embedding_function.encode( - query, **({"prompt": prefix} if prefix else {}) + query, + batch_size=int(embedding_batch_size), + **({"prompt": prefix} if prefix else {}), ).tolist() ), query, diff --git a/src/lib/components/admin/Settings/Documents.svelte b/src/lib/components/admin/Settings/Documents.svelte index dfed23dc45..650ce8b055 100644 --- a/src/lib/components/admin/Settings/Documents.svelte +++ b/src/lib/components/admin/Settings/Documents.svelte @@ -950,24 +950,24 @@ - {#if RAG_EMBEDDING_ENGINE === 'ollama' || RAG_EMBEDDING_ENGINE === 'openai' || RAG_EMBEDDING_ENGINE === 'azure_openai'} -
-
- {$i18n.t('Embedding Batch Size')} -
- -
- -
+
+
+ {$i18n.t('Embedding Batch Size')}
+
+ +
+
+ + {#if RAG_EMBEDDING_ENGINE === 'ollama' || RAG_EMBEDDING_ENGINE === 'openai' || RAG_EMBEDDING_ENGINE === 'azure_openai'}