ChatGPT-on-WeChat (CoW) is an open-source framework designed to integrate large language models into the communication tools your team already uses. The project supports platforms such as WeChat Official Accounts, WeCom, Feishu, and DingTalk. It is compatible with a wide array of models, including GPT-3.5, GPT-4o, Claude, Gemini, and ChatGLM, as well as leading Chinese models like Kimi, Wenxin Yiyan, Xunfei Spark, and Tongyi Qianwen. CoW processes text, voice, and images seamlessly. Furthermore, its support for plugins and file uploads allows you to build custom knowledge bases, enabling the bot to browse the web or execute system commands.
CoW is built for flexibility, allowing you to deploy the bot wherever your users are active. The codebase adapts to WeChat Official Accounts, WeCom apps, Feishu, and DingTalk with minimal configuration.
On the model side, the system supports industry leaders like the GPT-4o and GPT-4.1 series, Claude, and Gemini, alongside the full Chinese AI ecosystem. The April 2025 update (Version 1.7.5) introduced support for Deepseek models, Tencent Cloud voice services, and expanded API access via ModelScope and Gitee-AI.
Voice. CoW features native voice message recognition. The bot can process audio input and respond via text or synthesized speech. Supported engines include Azure, Baidu, Google, and OpenAI (Whisper/TTS).
Images. Users can generate images from text prompts or ask the bot to describe the contents of an uploaded picture. It also supports photo restoration through img2img workflows. You can choose from several backends, including Dall-E-3, Stable Diffusion, Replicate, and Midjourney.
The plugin architecture is what truly extends CoW’s capabilities. You can switch bot personalities mid-conversation, host text-based games, or implement automated sensitive-word filtering. The bot can also summarize chat logs and documents to answer specific follow-up questions. Additional tools include web search functionality and ModelScope API integration.
By uploading files to a knowledge base, you can transform CoW into a specialized agent. This allows it to function as a digital twin, a private customer service representative, or an intelligent community assistant, all powered through the LinkAI interface.
1. Accounts and Keys
The default configuration uses the OpenAI API, which requires a valid account and API key. If you prefer to avoid proxy configurations or network hurdles, the LinkAI interface offers a streamlined alternative, providing access to multiple models and features through a single gateway.
2. Operating System and Python
The project is compatible with Linux, macOS, and Windows. Ensure Python is installed; while versions 3.7.1 through 3.9.X are supported, Python 3.8 is recommended for the best stability. Users deploying via Docker or Railway do not need to configure a local Python environment.
3. Installation
Clone the repository to your local machine:git clone https://github.com/zhayujie/chatgpt-on-wechat
(Use a mirror URL if your connection to GitHub is unstable.) Navigate into the project directory.
Install the core dependencies:pip3 install -r requirements.txt
For those using plugins, install the optional requirements:pip3 install -r requirements-optional.txt
Generate your configuration file by copying config-template.json to a new file named config.json. This file contains all your primary settings.
Model and API
Specify the model name, OpenAI API key, and base URL. If you are using LinkAI, fill in the specific LinkAI fields instead.
Chat Triggers and Replies
Define the prefixes that trigger the bot in private messages or group threads. You can also specify which groups allow auto-replies and which should remain ignored.
Voice and Image Settings
Toggle voice recognition features and enable them for group chats if desired. You can also set a specific trigger word for image generation tasks.
General Settings
Adjust the context memory length, define the bot’s personality description, and configure automated subscription messages as needed.
Local Execution
Run python3 app.py (or python app.py on Windows) from the project root. Scan the generated QR code with your mobile device to log in.
Server Deployment
To keep the bot running after you disconnect from your session, use nohup to run the process in the background. Once the QR code is scanned, the session remains active. The scripts folder provides helper utilities for starting and stopping the service.
Docker
Use the provided docker-compose.yml file. After editing your configuration, launch the container using the docker-compose up command. Monitor the logs to access the login QR code.
Railway
While Railway offers a one-click deployment option, it is currently less reliable for free-tier accounts. A VPS or Docker-based deployment is generally recommended for consistent uptime.
Sunshine Streaming Host Specs: What Hardware You Actually Need
Dianman VPN: Free Trial, Unlimited Data & Zero Throttling
TradingAgents-MCP: A 15-Agent AI Framework for Real-Time Stock Analysis
How to Install Open Notebook: A Guide for Docker and Source Setup
SE-Agent: Self-Evolving AI Agent Tops SWE-bench Verified
FossFLOW: Offline-Ready Isometric Diagram Builder for the Browser
PandaWiki Setup Guide: Building an AI-Powered Knowledge Base
12306-mcp: Query China Train Tickets via MCP Server and LLMs
Agent-MCP: Building Multi-Agent Systems with the Model Context Protocol
ALLinSSL: Automated SSL Certificate Lifecycle Management
Motionity: Free Online Animation Editor with Keyframes and Masks
Turn eBooks & PDFs into Audio with Abogen – Fast TTS Tool