A local WeChat group assistant built with Wechaty, DeepSeek, and APIMart. It keeps recent room messages in memory, summarizes them with DeepSeek, generates a poster with APIMart, and sends the poster back to the group when triggered.
- Keeps message history in RAM and drops messages older than 24 hours.
- Tracks each room by
roomId, so multiple groups do not share memory. - Supports text, image, link, emoticon, video, audio, attachment, and mini program message counts.
- Generates a structured JSON analysis first, then turns it into an image prompt.
- Preserves messages that arrive while a poster is being generated, so they can be included in the next summary.
- macOS
- Node.js 18 or newer
- A DeepSeek API key
- An APIMart API key
- A WeChat account that can log in through the configured Wechaty puppet
npm install
cp .env.example .envEdit .env and fill in:
DEEPSEEK_API_KEY=your_deepseek_api_key_here
APIMART_API_KEY=your_apimart_api_key_hereOptional settings are also documented in .env.example, including the trigger word and APIMart polling limits.
npm startScan the QR code printed in the terminal with WeChat. In a group chat, send the trigger word configured by WECHAT_SUMMARY_TRIGGER; the default is:
#到点了兄弟
npm run checkThis runs syntax checks and the Node test suite.
- API keys are loaded from environment variables or
.env; do not commit real keys. wechaty-puppet-wechat4ucan be sensitive to WeChat account state and WeChat Web availability. If login fails, first verify the account can use the Web WeChat flow required by the puppet.