botchan
botchan copied to clipboard
基于微信测试号的ChatBot,对接OpenAI API
根据用户的微信号tousername关联一个上下文json记录,用户可以输入一个/clear删除之前对话并重新生成新的对话?虽然有点浪费token,但是会更有用?
比如自己写了一个server,不是OpenAI的接口,用来给定查询返回回答。
如图所示,在环境配置上,已经将流式输出打开。 但经过反复测试,依旧不是流式输出,而是等待了许久后,才一口气给出全部答案。  另外,感谢作者提供了这么好的产品!方糖YYDS!!!
/help正常返回 但是提问api2d,后台是有回复的,但是没有显示到公众号上。  
我是windows版nodejs v16环境, url是用 https://github.com/songquanpeng/one-api 部署的。已经测试了url+key可链接可用 开始配置DEFAULT_API_URL的最后有/ 就会报下面错误  Error: ChatGPT error 404: {"error":{"message":"Invalid URL (GET /v1/chat/complet ions)","type":"invalid_request_error","param":"","code":""}} at fetchSSE (C:\ws\nodejs-botchan\node_modules\api2d\cjs\fetchSSE.js:16:23) at processTicksAndRejections (node:internal/process/task_queues:96:5) at async C:\ws\nodejs-botchan\node_modules\api2d\cjs\index.js:155:38 { statusCode: 404,...
太酷啦!!
好方便! 就是每次要用都得去公众号里找一下。。。。