diff --git a/backend/apps/rag/main.py b/backend/apps/rag/main.py index ec9e0a8b..f24b6b90 100644 --- a/backend/apps/rag/main.py +++ b/backend/apps/rag/main.py @@ -388,7 +388,9 @@ def scan_docs_dir(user=Depends(get_admin_user)): collection_name = calculate_sha256(f)[:63] f.close() - loader, known_type = get_loader(filename, file_content_type, str(path)) + loader, known_type = get_loader( + filename, file_content_type[0], str(path) + ) data = loader.load() result = store_data_in_vector_db(data, collection_name)