diff --git a/backend/open_webui/apps/rag/main.py b/backend/open_webui/apps/rag/main.py index 4efa1d81c..7b476c056 100644 --- a/backend/open_webui/apps/rag/main.py +++ b/backend/open_webui/apps/rag/main.py @@ -1112,7 +1112,9 @@ def store_docs_in_vector_db( app.state.config.RAG_EMBEDDING_OPENAI_BATCH_SIZE, ) - embedding_texts = list(map(lambda x: x.replace("\n", " "), texts)) + embedding_texts = embedding_function( + list(map(lambda x: x.replace("\n", " "), texts)) + ) VECTOR_DB_CLIENT.insert( collection_name=collection_name,