[PR #8576] [CLOSED] feat: User Feedback UI for Admins #22251

Closed
opened 2026-04-20 04:01:04 -05:00 by GiteaMirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/open-webui/open-webui/pull/8576
Author: @Vojtech-Siler
Created: 1/15/2025
Status: Closed

Base: devHead: better-user-feedback


📝 Commits (3)

  • 7541575 Implement admin UI for user feedback
  • cff8bfd Optimize N+1 Query, Fix User load with Feedbacks
  • 5f58543 Fix to evaluations.py

📊 Changes

10 files changed (+375 additions, -64 deletions)

View changed files

backend/open_webui/migrations/versions/790ecce592df_add_chat_id_to_feedback.py (+30 -0)
backend/open_webui/migrations/versions/96dcb0b3212f_migrate_chat_id_in_feedback.py (+50 -0)
backend/open_webui/migrations/versions/e56c262570d7_make_chat_id_in_feedback_required.py (+42 -0)
📝 backend/open_webui/models/feedbacks.py (+48 -2)
📝 backend/open_webui/routers/evaluations.py (+12 -4)
📝 src/lib/apis/evaluations/index.ts (+31 -0)
📝 src/lib/components/admin/Evaluations/Feedbacks.svelte (+23 -1)
📝 src/lib/components/chat/Messages.svelte (+5 -0)
📝 src/lib/components/chat/Messages/Message.svelte (+119 -56)
📝 src/routes/s/[id]/+page.svelte (+15 -1)

📄 Description

Changelog Entry

Description

  • This feature was added because the Feedback functionality does not allow administrators to see user feedbacks. They could see that a model somehow won or lost, but could not collect the specific information.
  • This feature allows admins to go to the specific chats from the Feedbacks section in the Admin Panel using a new column with the chat title in it, and see the highlited messages that have user feedback on them. These messages are highlited by a border (green for positive, red for negative feedback), a badge, and have the necessary feedback information under them, including the rating, reason and comment. This allows admins to receive straight forward feedback they can work on and improve the particular models if needed.
  • This feedback is added into the /s/ page used for sharing read-only chats, it is only fetched if the current user is an administrator, and has a URL property to make sure the feedback doesn't automatically appear when sharing chats outside of the Feedbacks section.
  • The PR includes 3 new migrations - one to add the new column chat_id to feedback (I know it's already in the meta property, however meta being a JSON, I could not find a way to filter feedbacks from the DB using that), one to migrate the chat_id information from meta to the new column for already existing feedbacks, and one for making the chat_id column required. This has been split into 3 migrations due to safety, because of a previous experience of a migration not being able to add a column and populate it all in one migration.
  • The flow is as follows: In the Evaluations/Feedbacks section in the Admin Panel, the chat title where the feedback occured is shown. When clicked, the chat is shown using the /s/ sharing page, all feedbacks for that particular chat id are fetched if the user is admin, the URL property showFeedback is added, and it is determined for each message if it has feedback or not. If it does, style and additional info are added to it.

Added

  • Required chat_id column to the feedback table in DB
  • Methods in DB, routing and evaluation index.ts to fetch feedbacks for a particulat chat id
  • New column in the Feedbacks section with clickable chat titles
  • Feedback visualization for admins when clicked through the Feedbacks section, highlighting messages with feedback and showing necessary information about the feedback

Changed

  • /s/ chat sharing page to include feedbacks, if clicked from the Feedbacks section (using a URL parameter) and only if user is admin
  • feedback db model, added chat_id column populated from the meta property

Deprecated

Removed

Fixed

Security

Breaking Changes


Additional Information

  • The screenshots and a video bellow show how the feature looks and how it works.

Screenshots or Videos

image
image

https://github.com/user-attachments/assets/7c86a40c-f707-48e0-ac04-fd0a82637a7a


🔄 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/8576 **Author:** [@Vojtech-Siler](https://github.com/Vojtech-Siler) **Created:** 1/15/2025 **Status:** ❌ Closed **Base:** `dev` ← **Head:** `better-user-feedback` --- ### 📝 Commits (3) - [`7541575`](https://github.com/open-webui/open-webui/commit/75415756007ae476aae838ace2a004672b1d3691) Implement admin UI for user feedback - [`cff8bfd`](https://github.com/open-webui/open-webui/commit/cff8bfd1ad3c723a4e4c10b68e8d41357c185a1f) Optimize N+1 Query, Fix User load with Feedbacks - [`5f58543`](https://github.com/open-webui/open-webui/commit/5f5854387e3beace9fb13bd80477220677451c6f) Fix to evaluations.py ### 📊 Changes **10 files changed** (+375 additions, -64 deletions) <details> <summary>View changed files</summary> ➕ `backend/open_webui/migrations/versions/790ecce592df_add_chat_id_to_feedback.py` (+30 -0) ➕ `backend/open_webui/migrations/versions/96dcb0b3212f_migrate_chat_id_in_feedback.py` (+50 -0) ➕ `backend/open_webui/migrations/versions/e56c262570d7_make_chat_id_in_feedback_required.py` (+42 -0) 📝 `backend/open_webui/models/feedbacks.py` (+48 -2) 📝 `backend/open_webui/routers/evaluations.py` (+12 -4) 📝 `src/lib/apis/evaluations/index.ts` (+31 -0) 📝 `src/lib/components/admin/Evaluations/Feedbacks.svelte` (+23 -1) 📝 `src/lib/components/chat/Messages.svelte` (+5 -0) 📝 `src/lib/components/chat/Messages/Message.svelte` (+119 -56) 📝 `src/routes/s/[id]/+page.svelte` (+15 -1) </details> ### 📄 Description # Changelog Entry ### Description - This feature was added because the Feedback functionality does not allow administrators to see user feedbacks. They could see that a model somehow won or lost, but could not collect the specific information. - This feature allows admins to go to the specific chats from the Feedbacks section in the Admin Panel using a new column with the chat title in it, and see the highlited messages that have user feedback on them. These messages are highlited by a border (green for positive, red for negative feedback), a badge, and have the necessary feedback information under them, including the rating, reason and comment. This allows admins to receive straight forward feedback they can work on and improve the particular models if needed. - This feedback is added into the /s/ page used for sharing read-only chats, it is only fetched if the current user is an administrator, and has a URL property to make sure the feedback doesn't automatically appear when sharing chats outside of the Feedbacks section. - The PR includes 3 new migrations - one to add the new column chat_id to feedback (I know it's already in the meta property, however meta being a JSON, I could not find a way to filter feedbacks from the DB using that), one to migrate the chat_id information from meta to the new column for already existing feedbacks, and one for making the chat_id column required. This has been split into 3 migrations due to safety, because of a previous experience of a migration not being able to add a column and populate it all in one migration. - The flow is as follows: In the Evaluations/Feedbacks section in the Admin Panel, the chat title where the feedback occured is shown. When clicked, the chat is shown using the /s/ sharing page, all feedbacks for that particular chat id are fetched if the user is admin, the URL property showFeedback is added, and it is determined for each message if it has feedback or not. If it does, style and additional info are added to it. ### Added - Required chat_id column to the feedback table in DB - Methods in DB, routing and evaluation index.ts to fetch feedbacks for a particulat chat id - New column in the Feedbacks section with clickable chat titles - Feedback visualization for admins when clicked through the Feedbacks section, highlighting messages with feedback and showing necessary information about the feedback ### Changed - /s/ chat sharing page to include feedbacks, if clicked from the Feedbacks section (using a URL parameter) and only if user is admin - feedback db model, added chat_id column populated from the meta property ### Deprecated ### Removed ### Fixed ### Security ### Breaking Changes --- ### Additional Information - The screenshots and a video bellow show how the feature looks and how it works. ### Screenshots or Videos ![image](https://github.com/user-attachments/assets/b61137e1-8b0c-4b13-8c2e-8289e54c795a) ![image](https://github.com/user-attachments/assets/20b6cb1b-67a0-4618-b9e4-4733ca9fbc05) https://github.com/user-attachments/assets/7c86a40c-f707-48e0-ac04-fd0a82637a7a --- <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-20 04:01:04 -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#22251