wechat-auto-reply-ai
微信关键词自动回复 + AI 智能回复工具,支持好友/群聊监听、关键词规则、AI 回复和网页控制接口。
A Windows Python tool that watches your WeChat desktop app and automatically replies to messages using keyword rules or an AI service, with a local web dashboard to control and monitor it.
This is a Python tool that runs on Windows and automates replies to incoming WeChat messages on a personal WeChat account. WeChat is a widely used messaging app in China. The tool works by keeping the WeChat desktop client open and watching for new messages from contacts or group chats that you configure it to monitor.
When a message arrives, the tool checks it against a list of keyword rules you define. If the message contains a matching keyword, it sends back the preset reply for that rule. If no keyword matches, it can fall back to an AI service: you supply an API address, a key, and a model name from any service that uses the same format as OpenAI's API, and the tool calls that service to generate a reply based on the conversation context, including recent message history and the current time.
For group chats, there are extra controls. You can tell the tool to only reply when someone mentions you by name, restrict replies to messages from specific senders, or set the AI to judge for itself whether a reply is appropriate rather than responding to every message. A cooldown setting lets you cap how often the tool replies to any single contact or group, which helps avoid looking like a bot or triggering account restrictions.
The tool includes a small built-in web interface accessible on your local machine, where you can start or stop the auto-reply function, view live logs of what messages were received and what replies were sent, and check for errors.
Setup requires Python 3.13, a specific older version of WeChat for Windows, and the wxauto Python library. The WeChat window must stay visible on screen at all times; minimizing it breaks the automation. The README notes that automating a personal WeChat account carries some account suspension risk and recommends testing with a secondary account.
Where it fits
- Auto-reply to WeChat messages from specific contacts using keyword-triggered preset responses.
- Connect any OpenAI-compatible AI API to generate context-aware replies in WeChat group chats.
- Set cooldown limits and mention-only rules so a WeChat bot replies selectively without looking suspicious.