[PR #11526] [MERGED] Exlude images from embeddings #38384

Closed
opened 2026-04-25 11:25:58 -05:00 by GiteaMirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/open-webui/open-webui/pull/11526
Author: @rragundez
Created: 3/11/2025
Status: Merged
Merged: 3/11/2025
Merged by: @tjbck

Base: devHead: exlude-images-from-embeddings


📝 Commits (1)

  • ac321f4 Add check if images and avoid trying to calculate embeddings

📊 Changes

1 file changed (+1 additions, -1 deletions)

View changed files

📝 backend/open_webui/routers/files.py (+1 -1)

📄 Description

Generated mages are now treated with the same flow as normal files, which allows to back them out via the DB process.
Unfortunately during the upload_file function it does the DB backup but also the embedding of files. Since images do not contain any text and there are no parsers defined for images, the process fails then trying to embed them.

This PR adds a filter to check if the uploaded files are images, and if they are do not try to calculate embeddings.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/open-webui/open-webui/pull/11526 **Author:** [@rragundez](https://github.com/rragundez) **Created:** 3/11/2025 **Status:** ✅ Merged **Merged:** 3/11/2025 **Merged by:** [@tjbck](https://github.com/tjbck) **Base:** `dev` ← **Head:** `exlude-images-from-embeddings` --- ### 📝 Commits (1) - [`ac321f4`](https://github.com/open-webui/open-webui/commit/ac321f4b6485726a864b7a345ad96ec0a88ed5bd) Add check if images and avoid trying to calculate embeddings ### 📊 Changes **1 file changed** (+1 additions, -1 deletions) <details> <summary>View changed files</summary> 📝 `backend/open_webui/routers/files.py` (+1 -1) </details> ### 📄 Description Generated mages are now treated with the same flow as normal files, which allows to back them out via the DB process. Unfortunately during the upload_file function it does the DB backup but also the embedding of files. Since images do not contain any text and there are no parsers defined for images, the process fails then trying to embed them. This PR adds a filter to check if the uploaded files are images, and if they are do not try to calculate embeddings. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
GiteaMirror added the pull-request label 2026-04-25 11:25:58 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/open-webui#38384