## 欢迎使用`wechatgpt`智能机器人,Let's Chat with ChatGPT 如果觉得不错,请麻烦点个`Star`,非常感谢。(最新己经添加了docker部署的方式)
## 仓库地址 https://github.com/houko/wechatgpt ## 准备运行环境 ``` go mod tidy cp config/config.yaml.example local/config.yaml ``` ## 修改你的token 打开 [openai](https://beta.openai.com/account/api-keys) 并注册一个账号, 生成一个apiKey并把apiKey放到`local/config.yaml` 的token下,请看如下示例: 大陆用户注册`openai`请参考 [注册ChatGPT详细指南](https://sms-activate.org/cn/info/ChatGPT) ``` chatgpt: keyword: 小莫 token: sk-pKHZD1fLYqXDjjsdsdsdUvIODTT3ssjdfadsJC2gTuqqhTum ``` ## 运行App ``` go run main.go ``` ## `Docker` 方式运行`wechatgpt` 同时启动微信和telegram,微信登陆的地址请查看运行日志 ``` # apple silicon 如果不加触发关键字的话默认为: chatgpt docker run -d --name="wechatgpt" -e apiKey="你的chatgpt apiKey" -e wechat="触发关键字" telegram="你的telegram token" xiaomoinfo/wechatgpt:latest # linux amd64 如果不加触发关键字的话默认为: chatgpt docker run -d --name="wechatgpt" -e apiKey="你的chatgpt apiKey" telegram="你的telegram token" -e wechat="触发关键字" xiaomoinfo/wechatgpt-amd64:latest ``` 如果只想运行微信智能机器人的话运行下面这段代码,微信登陆的地址请查看运行日志 ``` # apple silicon 如果不加触发关键字的话默认为: chatgpt docker run -d --name wechatgpt -e apiKey="你的chatgpt apiKey" -e wechat="触发关键字" xiaomoinfo/wechatgpt:latest # linux amd64 如果不加触发关键字的话默认为: chatgpt docker run -d --name wechatgpt -e apiKey="你的chatgpt apiKey" -e wechat="触发关键字" xiaomoinfo/wechatgpt-amd64:latest ```