ikechan8370 / chatgpt-plugin

云崽系机器人的智能聊天插件
https://www.yunzai.chat/
GNU General Public License v3.0
1.01k stars 105 forks source link

必应模式问答会导致机器人重启 #265

Closed fsqhn closed 1 year ago

fsqhn commented 1 year ago

昨天试了下就这是这样了,今天重新获取了token但还是这样。 云仔跑在阿里云服务器的,用docker部署的。 错误代码直接贴下面了。` yunzai-bot | [YzBot][09:16:11.078][INFO] succeed to send: [Private(641968394)] [回复]Bing Token设置成功 yunzai-bot | [YzBot][09:16:11.391][INFO] bing token 有效

yunzai-bot | [YzBot][09:17:03.153][INFO] recv from: [Group: 八重堂高级编辑会议(是个群号,我手动删了), Member: 山上的小丘(这里是我q号,我手动删了)] #bing 原神里草元素与雷元素会发生什么反 应? yunzai-bot | [YzBot][09:17:03.346][MARK] [chatgpt][bing][八重堂高级编辑会议(山上的小丘)] #bing 原神里草元素与雷元素会发生什么反应? yunzai-bot | [YzBot][09:17:03.668][INFO] succeed to send: [Group(是个群号,我手动删了)] [回复@山上的小丘]我正在思考如何回复你,请稍等 yunzai-bot | [YzBot][09:17:03.669][INFO] chatgpt prompt: 原神里草元素与雷元素会发生什么反应? yunzai-bot | [YzBot][09:17:03.669][INFO] { yunzai-bot | previousConversation: { yunzai-bot | sender: { yunzai-bot | user_id: (这里是我q号,我手动删了), yunzai-bot | nickname: '山上的小丘', yunzai-bot | card: '山上的小丘', yunzai-bot | sex: 'male', yunzai-bot | age: 9, yunzai-bot | area: '阿鲁巴', yunzai-bot | level: 1, yunzai-bot | role: 'owner', yunzai-bot | title: '' yunzai-bot | }, yunzai-bot | ctime: '2023-03-22T01:17:03.669Z', yunzai-bot | utime: '2023-03-22T01:17:03.669Z', yunzai-bot | num: 0, yunzai-bot | conversation: {} yunzai-bot | } yunzai-bot | } yunzai-bot | [YzBot][09:17:03.670][MARK] { yunzai-bot | conversation: { yunzai-bot | conversationId: undefined, yunzai-bot | parentMessageId: undefined, yunzai-bot | clientId: undefined, yunzai-bot | invocationId: undefined, yunzai-bot | conversationSignature: undefined yunzai-bot | } yunzai-bot | } yunzai-bot | [YzBot][09:17:03.670][MARK] using bing mode yunzai-bot | { yunzai-bot | conversationId: '51D|BingProd|D7BFA02960663FE69650F75EDDC680C46E1390BB01B91C1D94114729AED283E1', yunzai-bot | clientId: '914798152805556', yunzai-bot | conversationSignature: '9HBCs+YlCfjQ46TxY5Wnrve8fJKwxBoUIa1O+w4APgM=', yunzai-bot | result: { value: 'Success', message: null } yunzai-bot | } yunzai-bot | performing handshake yunzai-bot | handshake established yunzai-bot | {"arguments":[{"source":"cib","optionsSets":["nlu_direct_response_filter","deepleo","disable_emoji_spoken_text","responsible_ai_policy_235","enablemm","harmonyv3","dtappid","cricinfo","cricinfov2","dv3sugg"],"sliceIds":["222dtappid","225cricinfo","224locals0"],"traceId":"bf3b32384d4ae40543daaf466835a91e","isStartOfSession":true,"message":{"author":"user","inputMethod":"Keyboard","text":"原神里草元素与雷元素会发生什么反应?","messageType":"Chat"},"conversationSignature":"9HBCs+YlCfjQ46TxY5Wnrve8fJKwxBoUIa1O+w4APgM=","participant":{"id":"914798152805556"},"conversationId":"51D|BingProd|D7BFA02960663FE69650F75EDDC680C46E1390BB01B91C1D94114729AED283E1"}],"invocationId":"0","target":"chat","type":4} yunzai-bot | [{"type":1,"target":"update","arguments":[{"requestId":"2d885bcc-68e6-4640-ae8d-8a2bdf8632b8","throttling":{"maxNumUserMessagesInConversation":15,"numUserMessagesInConversation":1}}]}] yunzai-bot | file:///app/Yunzai-Bot/node_modules/.pnpm/@waylaidwanderer+chatgpt-api@1.25.6/node_modules/@waylaidwanderer/chatgpt-api/src/BingAIClient.js:235 yunzai-bot | if (messages[0]?.author !== 'bot') { yunzai-bot | ^ yunzai-bot | yunzai-bot | TypeError: Cannot read properties of undefined (reading '0') yunzai-bot | at WebSocket. (file:///app/Yunzai-Bot/node_modules/.pnpm/@waylaidwanderer+chatgpt-api@1.25.6/node_modules/@waylaidwanderer/chatgpt-api/src/BingAIClient.js:235:37) yunzai-bot | at WebSocket.emit (node:events:525:35) yunzai-bot | at Receiver.receiverOnMessage (/app/Yunzai-Bot/node_modules/.pnpm/ws@8.12.1/node_modules/ws/lib/websocket.js:1180:20) yunzai-bot | at Receiver.emit (node:events:513:28) yunzai-bot | at Receiver.dataMessage (/app/Yunzai-Bot/node_modules/.pnpm/ws@8.12.1/node_modules/ws/lib/receiver.js:541:14) yunzai-bot | at Receiver.getData (/app/Yunzai-Bot/node_modules/.pnpm/ws@8.12.1/node_modules/ws/lib/receiver.js:459:17) yunzai-bot | at Receiver.startLoop (/app/Yunzai-Bot/node_modules/.pnpm/ws@8.12.1/node_modules/ws/lib/receiver.js:158:22) yunzai-bot | at Receiver._write (/app/Yunzai-Bot/node_modules/.pnpm/ws@8.12.1/node_modules/ws/lib/receiver.js:84:10) yunzai-bot | at writeOrBuffer (node:internal/streams/writable:392:12) yunzai-bot | at _write (node:internal/streams/writable:333:10) yunzai-bot | yunzai-bot | Node.js v18.14.1 yunzai-bot exited with code 1` 然后跑到这里就重启了。

waylaidwanderer commented 1 year ago

The maintainer needs to update to the latest version of my package :)

ikechan8370 commented 1 year ago

你需要更新你的依赖版本,package.json我已经更新了。执行pnpm i重新安装就行了