如图,一般进行大概七八条对话就会报错403,用的自建的newapi,没有调用日志,webui的docker日志如下:
INFO [open_webui.apps.openai.main] get_all_models()
ERROR [open_webui.apps.openai.main] 403, message='Attempt to decode JSON with unexpected mimetype: text/html', url='https://ramapi.rr.nu/v1/chat/completions'
ERROR [open_webui.apps.openai.main] 403, message='Forbidden', url='https://ramapi.rr.nu/v1/chat/completions'
Traceback (most recent call last):
File "/app/backend/open_webui/apps/openai/main.py", line 634, in generate_chat_completion
r.raise_for_status()
File "/usr/local/lib/python3.11/site-packages/aiohttp/client_reqrep.py", line 1157, in raise_for_status
raise ClientResponseError(
aiohttp.client_exceptions.ClientResponseError: 403, message='Forbidden', url='https://ramapi.rr.nu/v1/chat/completions'
INFO: 50.114.155.56:0 - "POST /api/chat/completions HTTP/1.1" 403 Forbidden
INFO: 50.114.155.56:0 - "POST /api/v1/chats/d81e7e26-4318-4b5d-b10f-2e1adecf8c23 HTTP/1.1" 200 OK
INFO: 50.114.155.56:0 - "GET /api/v1/chats/?page=1 HTTP/1.1" 200 OK
INFO: 50.114.155.56:0 - "POST /api/chat/completed HTTP/1.1" 200 OK
INFO: 50.114.155.56:0 - "POST /api/v1/chats/d81e7e26-4318-4b5d-b10f-2e1adecf8c23 HTTP/1.1" 200 OK
INFO: 50.114.155.56:0 - "GET /api/v1/chats/?page=1 HTTP/1.1" 200 OK
INFO: 50.114.155.56:0 - "GET /api/v1/chats/?page=1 HTTP/1.1" 200 OK
换模型也一样报错
这时候只能新开对话,上下文全部丢失