Welcome to wechat-chatgpt

Features

- Use ChatGPT on WeChat with wechaty and Official API
- Add conversation support
- Support command setting
Interact with WeChat and ChatGPT:
- Add Dockerfile, deployable with docker
- Support deployment using docker compose
- Support Railway and Fly.io deployment
Deployment and configuration options:
Usage

- Use with Railway(PaaS, Free, Stable, Recommended)

- Use with Fly.io(Paas, Free, Recommended)
- Use with docker(Self-hosted, Stable, Recommended)
- Use with docker compose(Self-hosted, Stable, Recommended)
- Use with nodejs(Self-hosted)
Use with Railway
- Click the Railway button to go to the Railway deployment page
- Click the
Deploy Now
button to enter the Railway deployment page
- Fill in the repository name and
OPENAI_API_KEY
(need to link GitHub account)
- Click the
Deploy
button
- Click the
View Logs
button and wait for the deployment to complete
Use with Fly.io
- Install flyctl
- Clone the project and enter the project directory
- Create a new app
- Configure the environment variables
- Deploy the app
Use with docker
Use with docker compose
Use with nodejs
Environment Variables

name | default | example | description |
API | ㅤ | API endpoint of ChatGPT | |
OPENAI_API_KEY | 123456789 | sk-XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX | |
MODEL | gpt-3.5-turbo | ㅤ | ID of the model to use. Currently, only gpt-3.5-turbo and gpt-3.5-turbo-0301 are supported. |
TEMPERATURE | 0.6 | ㅤ | What sampling temperature to use, between 0 and 2. Higher values like 0.8 will make the output more random, while lower values like 0.2 will make it more focused and deterministic. |
CHAT_TRIGGER_RULE | ㅤ | ㅤ | Private chat triggering rules. |
DISABLE_GROUP_MESSAGE | true | ㅤ | Prohibited to use ChatGPT in group chat. |
CHAT_PRIVATE_TRIGGER_KEYWORD | ㅤ | ㅤ | Keyword to trigger ChatGPT reply in WeChat private chat |
BLOCK_WORDS | "VPN" | "WORD1,WORD2,WORD3" | Chat blocker words, (works for both private and group chats, Use, Split) |
CHATGPT_BLOCK_WORDS | "VPN" | "WORD1,WORD2,WORD3" | The blocked words returned by ChatGPT(works for both private and group chats, Use, Split) |
Using Custom ChatGPT API
Commands

Contributor

Contributing

Contributions, issues and feature requests are welcome!
Feel free to check issues page.
Show your support
Give a

if this project helped you!