Browse Source

fix: bypass webloader

Co-Authored-By: WilliamGates <3852641+williamgateszhao@users.noreply.github.com>
Timothy Jaeryang Baek 1 week ago
parent
commit
f3cae94028
1 changed files with 4 additions and 0 deletions
  1. 4 0
      backend/open_webui/routers/retrieval.py

+ 4 - 0
backend/open_webui/routers/retrieval.py

@@ -1867,6 +1867,10 @@ async def process_web_search(
 
     try:
         if request.app.state.config.BYPASS_WEB_SEARCH_WEB_LOADER:
+            search_results = [
+                item for result in search_results for item in result if result
+            ]
+
             docs = [
                 Document(
                     page_content=result.snippet,