Open AileenAugustus opened 1 year ago
提交 issue 前,请先确认:
表现 接入的是telegram 2023-06-27 14:50:45.654 | DEBUG | middlewares.concurrentlock:handle_request:40 - [Concurrent] 排队中,前面还有 0 个人! 2023-06-27 14:50:45.656 | DEBUG | middlewares.concurrentlock:handle_request:42 - [Concurrent] 排到了! 2023-06-27 14:50:45.657 | DEBUG | middlewares.timeout:create_timeout_task:55 - [Timeout] 开始计时…… 2023-06-27 14:50:45.659 | DEBUG | adapter.chatgpt.api:ask:94 - 清理 token,历史记录遗忘后使用 token 数:3118 2023-06-27 14:50:45.662 | DEBUG | adapter.chatgpt.api:ask:94 - 清理 token,历史记录遗忘后使用 token 数:2877 2023-06-27 14:51:17.461 | DEBUG | middlewares.timeout:on_respond:40 - [Timeout] 取消计时…… 2023-06-27 14:51:17.468 | DEBUG | middlewares.timeout:create_timeout_task:58 - [Timeout] 等待过久,发送提示 在这之后发送消息就不能被接受到了
运行环境:
复现步骤 描述你是如何触发这个 BUG 的 聊天聊着聊着就会触发
预期行为 用户收到报错消息,可以继续聊天,但是现在不能继续聊天也没有收到报错。
其他内容 config文件是这样的: [telegram]
bot_token = ""
manager_chat = [openai]
api_endpoint = "https://api.openai.com/v1" [[openai.accounts]] api_key = "sk-" model="gpt-3.5-turbo"
[openai.gpt3_params] temperature = 1 max_tokens = 4000 top_p = 1.0 presence_penalty = 0.0 frequency_penalty = 0.0 min_tokens = 1000
[presets]
command = "加载预设 (\w+)"
[presets.keywords]
"聊天" = "presets/issue402.txt" "猫娘" = "presets/catgirl.txt"
[response] buffer_delay = 0
max_queue_size = 15 queue_full = "【人数过多,稍后再试】" queued_notice_size = 3 queued_notice = "【消息已收到,前方还有{queue_size}人】" timeout = 30.0 timeout_format = "【思考中……】" max_timeout = 600 cancel_wait_too_long = "【请求超时】" reset = "【会话已重置】" rollback_success = "【已回滚至上一条对话】" rollback_fail = "【回滚失败,没有更早的记录】" mode = "text"
error_format = "【出现故障】" error_network_failure = "【网络故障】" error_server_overloaded = "【服务器压力过大,请稍后体验】"
error_session_authenciate_failed = "【登陆失败】" error_request_too_many = "【请求过多,请稍后再试】"
placeholder = "【倾听,感受,思考。】"
请问是什么原因呢?
配置文件可以设置最大的等待时间,默认是10分钟。超过那个时间就会报错。
报错之后就再也不接受消息了,会一直卡住。
提交 issue 前,请先确认:
表现
接入的是telegram 2023-06-27 14:50:45.654 | DEBUG | middlewares.concurrentlock:handle_request:40 - [Concurrent] 排队中,前面还有 0 个人! 2023-06-27 14:50:45.656 | DEBUG | middlewares.concurrentlock:handle_request:42 - [Concurrent] 排到了! 2023-06-27 14:50:45.657 | DEBUG | middlewares.timeout:create_timeout_task:55 - [Timeout] 开始计时…… 2023-06-27 14:50:45.659 | DEBUG | adapter.chatgpt.api:ask:94 - 清理 token,历史记录遗忘后使用 token 数:3118 2023-06-27 14:50:45.662 | DEBUG | adapter.chatgpt.api:ask:94 - 清理 token,历史记录遗忘后使用 token 数:2877 2023-06-27 14:51:17.461 | DEBUG | middlewares.timeout:on_respond:40 - [Timeout] 取消计时…… 2023-06-27 14:51:17.468 | DEBUG | middlewares.timeout:create_timeout_task:58 - [Timeout] 等待过久,发送提示 在这之后发送消息就不能被接受到了
运行环境:
复现步骤
描述你是如何触发这个 BUG 的 聊天聊着聊着就会触发
预期行为
用户收到报错消息,可以继续聊天,但是现在不能继续聊天也没有收到报错。
其他内容
config文件是这样的: [telegram]
这个 token 是找 BotFather 要的
bot_token = ""
管理员的 chat id
manager_chat = [openai]
这里填写你在 OpenAI 官网获取的 API Key
api_endpoint = "https://api.openai.com/v1" [[openai.accounts]] api_key = "sk-" model="gpt-3.5-turbo"
[openai.gpt3_params] temperature = 1 max_tokens = 4000 top_p = 1.0 presence_penalty = 0.0 frequency_penalty = 0.0 min_tokens = 1000
[presets]
切换预设的命令: 加载预设 猫娘
command = "加载预设 (\w+)"
[presets.keywords]
预设关键词 <-> 实际文件
"聊天" = "presets/issue402.txt" "猫娘" = "presets/catgirl.txt"
[response] buffer_delay = 0
max_queue_size = 15 queue_full = "【人数过多,稍后再试】" queued_notice_size = 3 queued_notice = "【消息已收到,前方还有{queue_size}人】" timeout = 30.0 timeout_format = "【思考中……】" max_timeout = 600 cancel_wait_too_long = "【请求超时】" reset = "【会话已重置】" rollback_success = "【已回滚至上一条对话】" rollback_fail = "【回滚失败,没有更早的记录】" mode = "text"
error_format = "【出现故障】" error_network_failure = "【网络故障】" error_server_overloaded = "【服务器压力过大,请稍后体验】"
error_session_authenciate_failed = "【登陆失败】" error_request_too_many = "【请求过多,请稍后再试】"
placeholder = "【倾听,感受,思考。】"
请问是什么原因呢?