[GH-ISSUE #14105] issue: Chat title generation fails due to overwritten message variable (KeyError: 'model') #55808

Closed
opened 2026-05-05 18:05:25 -05:00 by GiteaMirror · 1 comment
Owner

Originally created by @ericklima-ca on GitHub (May 20, 2025).
Original GitHub issue: https://github.com/open-webui/open-webui/issues/14105

Check Existing Issues

  • I have searched the existing issues and discussions.
  • I am using the latest version of Open WebUI.

Installation Method

Other

Open WebUI Version

v0.6.10

Ollama Version (if applicable)

No response

Operating System

Windows 11

Browser (if applicable)

No response

Confirmation

  • I have read and followed all instructions in README.md.
  • I am using the latest version of both Open WebUI and Ollama.
  • I have included the browser console logs.
  • I have included the Docker container logs.
  • I have listed steps to reproduce the bug in detail.

Expected Behavior

The chat should generate a meaningful title using the LLM model associated with the initial message, based on the content and role. For example, instead of showing "New Chat", it should display something contextually relevant like "Help with API Integration".

Actual Behavior

Chat title generation fails consistently. All chats are labeled "New Chat", regardless of their content. Console and backend logs show a KeyError: 'model', indicating that the model information is not found at runtime.

Steps to Reproduce

  1. Start a new chat with any message.
  2. Let the assistant respond.
  3. Open the browser console or backend logs.
  4. Observe that no title is generated.
  5. Check logs and see: KeyError: 'model'.

Logs & Screenshots

File "/app/backend/open_webui/utils/middleware.py", line 1005, in background_tasks_handler
"model": message["model"],
└ {'role': 'assistant', 'content': 'Olá! Como posso ajudar?'}
KeyError: 'model'

Additional Information

No response

Originally created by @ericklima-ca on GitHub (May 20, 2025). Original GitHub issue: https://github.com/open-webui/open-webui/issues/14105 ### Check Existing Issues - [x] I have searched the existing issues and discussions. - [x] I am using the latest version of Open WebUI. ### Installation Method Other ### Open WebUI Version v0.6.10 ### Ollama Version (if applicable) _No response_ ### Operating System Windows 11 ### Browser (if applicable) _No response_ ### Confirmation - [x] I have read and followed all instructions in `README.md`. - [x] I am using the latest version of **both** Open WebUI and Ollama. - [x] I have included the browser console logs. - [x] I have included the Docker container logs. - [x] I have listed steps to reproduce the bug in detail. ### Expected Behavior The chat should generate a meaningful title using the LLM model associated with the initial message, based on the content and role. For example, instead of showing "New Chat", it should display something contextually relevant like "Help with API Integration". ### Actual Behavior Chat title generation fails consistently. All chats are labeled "New Chat", regardless of their content. Console and backend logs show a KeyError: 'model', indicating that the model information is not found at runtime. ### Steps to Reproduce 1. Start a new chat with any message. 2. Let the assistant respond. 3. Open the browser console or backend logs. 4. Observe that no title is generated. 5. Check logs and see: `KeyError: 'model'`. ### Logs & Screenshots File "/app/backend/open_webui/utils/middleware.py", line 1005, in background_tasks_handler "model": message["model"], └ {'role': 'assistant', 'content': 'Olá! Como posso ajudar?'} KeyError: 'model' ### Additional Information _No response_
GiteaMirror added the bug label 2026-05-05 18:05:25 -05:00
Author
Owner

@tjbck commented on GitHub (May 20, 2025):

Should be addressed with e3e7eb96f6

<!-- gh-comment-id:2895678089 --> @tjbck commented on GitHub (May 20, 2025): Should be addressed with e3e7eb96f6ee0336bed1bdc8ac066baab1297e1c
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/open-webui#55808