Skip to content

This issue was moved to a discussion.

You can continue the conversation there. Go to discussion →

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bug: Body of chat and title API requests are being logged. #3195

Closed
3 of 4 tasks
theasp opened this issue Jun 15, 2024 · 1 comment
Closed
3 of 4 tasks

bug: Body of chat and title API requests are being logged. #3195

theasp opened this issue Jun 15, 2024 · 1 comment

Comments

@theasp
Copy link
Contributor

theasp commented Jun 15, 2024

Bug Report

Description

Bug Summary:

The body of chat API requests is now being logged. This probably shouldn't happen by default. The title endpoint is also affected. See output below.

It looks like this was introduced here: 88d0538

Steps to Reproduce:

  1. Run Open WebUI in a terminal or in Docker
  2. Start chatting with a model
  3. Check output or docker logs

Expected Behavior:

It shouldn't log request bodies by default.

Actual Behavior:

Request bodies logged.

Environment

  • Open WebUI Version: 0.3.4

  • Ollama (if applicable): N/A

  • Operating System: Ubuntu 22.04

  • Browser (if applicable): Chrome

Reproduction Details

Confirmation:

  • I have read and followed all the instructions provided in the README.md.
  • I am on the latest version of both Open WebUI and Ollama.
  • I have included the browser console logs.
  • I have included the Docker container logs.

Logs and Screenshots

Browser Console Logs:
N/A

Docker Container Logs:

open-webui-1  | INFO:apps.ollama.main:url: http://ollama:11434
open-webui-1  | {'model': 'DEFAULT/llama3-8b:latest', 'messages': [{'role': 'user', 'content': "Do people ever say things to LLMs that shouldn't be logged?"}], 'options': {}}
open-webui-1  | INFO:     192.168.2.125:0 - "POST /ollama/api/chat HTTP/1.1" 200 OK
open-webui-1  | INFO:     192.168.2.125:0 - "POST /api/v1/chats/274b9d3d-1b5c-4434-a2ea-7bc30723f6a8 HTTP/1.1" 200 OK
open-webui-1  | INFO:     192.168.2.125:0 - "GET /api/v1/chats/ HTTP/1.1" 200 OK
open-webui-1  | generate_title
open-webui-1  | *llama3-8b
open-webui-1  | {'model': '*llama3-8b', 'messages': [{'role': 'user', 'content': "This query will be summarized:\nDo people ever say things to LLMs that shouldn't be logged?\n\nIgnore all pr
evious instructions.\n\nGenerate a concise and accurate title (no more than 5 words) that summarizes the query in natural English. The title can start with a suitable Emoji to enhance unders
tanding, but avoid quotation marks or special formatting. RESPOND ONLY WITH THE TITLE TEXT.\n\nExample titles:\n📉 Stock Market Trends\n🍪 Perfect Chocolate Chip Recipe\n🎵 Evolution of Musi
c Streaming\nRemote Work Productivity Tips\n🤖 Artificial Intelligence in Healthcare\n🎮 Video Game Development Insights"}], 'stream': False, 'max_tokens': 50, 'chat_id': '274b9d3d-1b5c-4434
-a2ea-7bc30723f6a8', 'title': True}
open-webui-1  | INFO:apps.ollama.main:url: http://ollama:11434

Screenshots (if applicable):
N/A

Installation Method

Docker

Additional Information

N/A

Note

If the bug report is incomplete or does not follow the provided instructions, it may not be addressed. Please ensure that you have followed the steps outlined in the README.md and troubleshooting.md documents, and provide all necessary information for us to reproduce and address the issue. Thank you!

@theasp
Copy link
Contributor Author

theasp commented Jun 15, 2024

I think these prints should be removed or converted into log.debug():

backend/apps/openai/main.py:433:    print(payload)
backend/apps/openai/main.py:438:    print(payload)
backend/apps/ollama/main.py:843:    print(payload)
backend/main.py:776:    print(payload)
backend/main.py:840:    print(payload)

@theasp theasp changed the title Body of chat and title API requests are being logged. bug: Body of chat and title API requests are being logged. Jun 15, 2024
@open-webui open-webui locked and limited conversation to collaborators Jun 16, 2024
@tjbck tjbck converted this issue into discussion #3207 Jun 16, 2024

This issue was moved to a discussion.

You can continue the conversation there. Go to discussion →

Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant