mirror of
https://github.com/zhayujie/chatgpt-on-wechat.git
synced 2026-07-20 21:57:14 +08:00
feat: docs update
This commit is contained in:
@@ -1,93 +0,0 @@
|
||||
---
|
||||
title: Architecture
|
||||
description: CowAgent 2.0 system architecture and core design
|
||||
---
|
||||
|
||||
# Architecture
|
||||
|
||||
CowAgent 2.0 is a comprehensive upgrade from a simple chatbot to an AI super assistant, built on an Agent architecture with autonomous thinking, task planning, long-term memory, and skill extension capabilities.
|
||||
|
||||
## System Architecture
|
||||
|
||||
```
|
||||
┌──────────────────────────────────────────────────────┐
|
||||
│ Channels │
|
||||
│ Web │ Feishu │ DingTalk │ WeCom │ WeChat MP │
|
||||
└───────────────────────┬──────────────────────────────┘
|
||||
│
|
||||
┌───────────────────────▼──────────────────────────────┐
|
||||
│ Agent Core │
|
||||
│ ┌─────────────┐ ┌──────────┐ ┌───────────────────┐ │
|
||||
│ │ Task Planner│ │ Memory │ │ Skills Engine │ │
|
||||
│ └──────┬──────┘ └────┬─────┘ └────────┬──────────┘ │
|
||||
│ │ │ │ │
|
||||
│ ┌──────▼─────────────▼────────────────▼──────────┐ │
|
||||
│ │ Tools │ │
|
||||
│ │ File R/W │ Bash │ Browser │ Scheduler │ ... │ │
|
||||
│ └────────────────────────────────────────────────┘ │
|
||||
└───────────────────────┬──────────────────────────────┘
|
||||
│
|
||||
┌───────────────────────▼──────────────────────────────┐
|
||||
│ Models │
|
||||
│ OpenAI │ Claude │ Gemini │ MiniMax │ GLM │ ... │
|
||||
└──────────────────────────────────────────────────────┘
|
||||
```
|
||||
|
||||
### Core Modules
|
||||
|
||||
| Module | Description |
|
||||
| --- | --- |
|
||||
| **Channels** | Message channel layer for receiving and sending messages, supporting Web, Feishu, DingTalk, WeCom, WeChat Official Accounts, etc. |
|
||||
| **Agent Core** | The intelligent agent engine, including task planning, memory system, and skills engine |
|
||||
| **Tools** | Tool layer through which the Agent accesses OS resources, with 10+ built-in tools |
|
||||
| **Models** | Model layer supporting unified access to major domestic and international LLMs |
|
||||
|
||||
## Agent Mode
|
||||
|
||||
When Agent mode is enabled, CowAgent operates as an autonomous intelligent agent with the following workflow:
|
||||
|
||||
1. **Receive Message** - Receives user input through a channel
|
||||
2. **Understand Intent** - Analyzes task requirements and context
|
||||
3. **Plan Task** - Breaks complex tasks into multiple steps
|
||||
4. **Call Tools** - Selects appropriate tools to execute each step
|
||||
5. **Update Memory** - Stores important information in long-term memory
|
||||
6. **Return Result** - Sends execution results back to the user
|
||||
|
||||
## Workspace
|
||||
|
||||
The Agent workspace defaults to `~/cow`, storing system prompts, memory files, skill files, etc.:
|
||||
|
||||
```
|
||||
~/cow/
|
||||
├── system.md # Agent system prompt
|
||||
├── user.md # User profile
|
||||
├── memory/ # Long-term memory storage
|
||||
│ ├── core.md # Core memory
|
||||
│ └── daily/ # Daily memory
|
||||
├── skills/ # Custom skills
|
||||
│ ├── skill-1/
|
||||
│ └── skill-2/
|
||||
└── .env # Secret keys for skills
|
||||
```
|
||||
|
||||
## Core Configuration
|
||||
|
||||
Configure Agent mode parameters in `config.json`:
|
||||
|
||||
```json
|
||||
{
|
||||
"agent": true,
|
||||
"agent_workspace": "~/cow",
|
||||
"agent_max_context_tokens": 40000,
|
||||
"agent_max_context_turns": 30,
|
||||
"agent_max_steps": 15
|
||||
}
|
||||
```
|
||||
|
||||
| Parameter | Description | Default |
|
||||
| --- | --- | --- |
|
||||
| `agent` | Enable Agent mode | `true` |
|
||||
| `agent_workspace` | Workspace path | `~/cow` |
|
||||
| `agent_max_context_tokens` | Maximum context tokens | `40000` |
|
||||
| `agent_max_context_turns` | Maximum context conversation turns | `30` |
|
||||
| `agent_max_steps` | Maximum tool call steps per task | `15` |
|
||||
@@ -1,23 +1,21 @@
|
||||
---
|
||||
title: DingTalk
|
||||
description: Integrate CowAgent with DingTalk
|
||||
description: Integrate CowAgent into DingTalk application
|
||||
---
|
||||
|
||||
# DingTalk
|
||||
Integrate CowAgent into DingTalk by creating an intelligent robot app on the DingTalk Open Platform.
|
||||
|
||||
Create a smart bot application on the DingTalk Open Platform to integrate CowAgent.
|
||||
## 1. Create App
|
||||
|
||||
## 1. Create an App
|
||||
|
||||
1. Go to [DingTalk Developer Console](https://open-dev.dingtalk.com/fe/app#/corp/app), click **Create App**, and fill in the information
|
||||
2. Add the **Bot** capability
|
||||
3. Configure bot info and click **Publish**
|
||||
1. Go to [DingTalk Developer Console](https://open-dev.dingtalk.com/fe/app#/corp/app), click **Create App**, fill in app information
|
||||
2. Click **Add App Capability**, select **Robot** capability and add
|
||||
3. Configure robot information and click **Publish**
|
||||
|
||||
## 2. Project Configuration
|
||||
|
||||
1. Get `Client ID` and `Client Secret` from **Credentials & Basic Info**
|
||||
|
||||
2. Add to `config.json`:
|
||||
2. Fill in `config.json`:
|
||||
|
||||
```json
|
||||
{
|
||||
@@ -33,8 +31,8 @@ Create a smart bot application on the DingTalk Open Platform to integrate CowAge
|
||||
pip3 install dingtalk_stream
|
||||
```
|
||||
|
||||
4. After starting the project, go to **Event Subscription** in the DingTalk console, click **Verify Connection** — it should show "Connection successful"
|
||||
4. After starting the project, go to DingTalk Developer Console **Event Subscription**, click **Connection verified, verify channel**. When "Connection successful" is displayed, configuration is complete
|
||||
|
||||
## 3. Usage
|
||||
|
||||
Chat with the bot privately or add it to a group chat to start a conversation.
|
||||
Chat privately with the robot or add it to an enterprise group to start a conversation.
|
||||
|
||||
@@ -1,25 +1,23 @@
|
||||
---
|
||||
title: Feishu (Lark)
|
||||
description: Integrate CowAgent with Feishu
|
||||
description: Integrate CowAgent into Feishu application
|
||||
---
|
||||
|
||||
# Feishu (Lark)
|
||||
Integrate CowAgent into Feishu by creating a custom app. Supports WebSocket (recommended, no public IP required) and Webhook event receiving modes.
|
||||
|
||||
Integrate CowAgent into Feishu by creating a custom app. Supports WebSocket (recommended) and Webhook event modes.
|
||||
## 1. Create Enterprise Custom App
|
||||
|
||||
## 1. Create a Custom App
|
||||
### 1.1 Create App
|
||||
|
||||
### Create the App
|
||||
Go to [Feishu Developer Platform](https://open.feishu.cn/app/), click **Create Enterprise Custom App**, fill in the required information and create.
|
||||
|
||||
Go to [Feishu Open Platform](https://open.feishu.cn/app/), click **Create Custom App**, and fill in the required information.
|
||||
### 1.2 Add Bot Capability
|
||||
|
||||
### Add Bot Capability
|
||||
In **Add App Capabilities**, add **Bot** capability to the app.
|
||||
|
||||
In the **Add App Capabilities** menu, add the **Bot** capability.
|
||||
### 1.3 Configure App Permissions
|
||||
|
||||
### Configure Permissions
|
||||
|
||||
Go to **Permission Management**, paste the following permissions, select all, and enable them:
|
||||
Click **Permission Management**, paste the following permission string, select all and enable in batch:
|
||||
|
||||
```
|
||||
im:message,im:message.group_at_msg,im:message.group_at_msg:readonly,im:message.p2p_msg,im:message.p2p_msg:readonly,im:message:send_as_bot,im:resource
|
||||
@@ -27,11 +25,11 @@ im:message,im:message.group_at_msg,im:message.group_at_msg:readonly,im:message.p
|
||||
|
||||
## 2. Project Configuration
|
||||
|
||||
Get `App ID` and `App Secret` from **Credentials & Basic Info**, then add to `config.json`:
|
||||
Get `App ID` and `App Secret` from **Credentials & Basic Info**, then fill in `config.json`:
|
||||
|
||||
<Tabs>
|
||||
<Tab title="WebSocket (Recommended)">
|
||||
No public IP required:
|
||||
<Tab title="WebSocket Mode (Recommended)">
|
||||
No public IP required. Configuration:
|
||||
|
||||
```json
|
||||
{
|
||||
@@ -44,8 +42,8 @@ Get `App ID` and `App Secret` from **Credentials & Basic Info**, then add to `co
|
||||
|
||||
Install dependency: `pip3 install lark-oapi`
|
||||
</Tab>
|
||||
<Tab title="Webhook">
|
||||
Requires public IP:
|
||||
<Tab title="Webhook Mode">
|
||||
Requires public IP. Configuration:
|
||||
|
||||
```json
|
||||
{
|
||||
@@ -62,8 +60,8 @@ Get `App ID` and `App Secret` from **Credentials & Basic Info**, then add to `co
|
||||
|
||||
## 3. Configure Event Subscription
|
||||
|
||||
1. After starting the project, go to **Events & Callbacks** on the Feishu Open Platform, select **Long Connection** mode, and save
|
||||
2. Click **Add Event**, search for "Receive Message", select "Receive Message v2.0", and confirm
|
||||
3. Go to **Version Management & Release**, create a new version, and submit for release approval
|
||||
1. After starting the project, go to Feishu Developer Platform **Events & Callbacks**, select **Long Connection** and save
|
||||
2. Click **Add Event**, search for "Receive Message", select "Receive Message v2.0", confirm and add
|
||||
3. Click **Version Management & Release**, create a version and apply for production release. After approval, you can use it
|
||||
|
||||
Once approved, search for the bot name in Feishu to start chatting.
|
||||
Search for the bot name in Feishu to start chatting.
|
||||
|
||||
@@ -1,11 +1,9 @@
|
||||
---
|
||||
title: Web
|
||||
description: Use CowAgent through the Web interface
|
||||
description: Use CowAgent through the web interface
|
||||
---
|
||||
|
||||
# Web
|
||||
|
||||
Web is the default channel for CowAgent. A Web console starts automatically on launch, allowing you to chat with the Agent through your browser.
|
||||
Web is CowAgent's default channel. The web console starts automatically after launch, allowing you to chat with the Agent through a browser.
|
||||
|
||||
## Configuration
|
||||
|
||||
@@ -19,7 +17,7 @@ Web is the default channel for CowAgent. A Web console starts automatically on l
|
||||
| Parameter | Description | Default |
|
||||
| --- | --- | --- |
|
||||
| `channel_type` | Set to `web` | `web` |
|
||||
| `web_port` | Web service listening port | `9899` |
|
||||
| `web_port` | Web service listen port | `9899` |
|
||||
|
||||
## Usage
|
||||
|
||||
@@ -29,5 +27,5 @@ After starting the project, visit:
|
||||
- Server: `http://<server-ip>:9899/chat`
|
||||
|
||||
<Note>
|
||||
Ensure your server firewall and security group allow access to the configured port.
|
||||
Ensure the server firewall and security group allow the corresponding port.
|
||||
</Note>
|
||||
|
||||
@@ -3,14 +3,12 @@ title: WeChat Official Account
|
||||
description: Integrate CowAgent with WeChat Official Accounts
|
||||
---
|
||||
|
||||
# WeChat Official Account
|
||||
|
||||
CowAgent supports both personal subscription accounts and enterprise service accounts.
|
||||
|
||||
| Type | Requirements | Features |
|
||||
| --- | --- | --- |
|
||||
| **Personal Subscription** | Available to individuals | Users must send a message to retrieve replies |
|
||||
| **Enterprise Service** | Enterprise registration with verified customer service API | Can proactively push replies to users |
|
||||
| **Enterprise Service** | Enterprise with verified customer service API | Can proactively push replies to users |
|
||||
|
||||
<Note>
|
||||
Official Accounts only support server and Docker deployment. Install extended dependencies: `pip3 install -r requirements-optional.txt`
|
||||
@@ -18,8 +16,6 @@ CowAgent supports both personal subscription accounts and enterprise service acc
|
||||
|
||||
## Personal Subscription Account
|
||||
|
||||
Add the following to `config.json`:
|
||||
|
||||
```json
|
||||
{
|
||||
"channel_type": "wechatmp",
|
||||
@@ -36,15 +32,15 @@ Add the following to `config.json`:
|
||||
1. Get parameters from [WeChat Official Account Platform](https://mp.weixin.qq.com/) under **Settings & Development → Basic Configuration → Server Configuration**
|
||||
2. Enable developer secret and add server IP to the whitelist
|
||||
3. Start the program (listens on port 80)
|
||||
4. In the official account console, **enable server configuration** with URL format `http://{HOST}/wx`
|
||||
4. Enable server configuration with URL format `http://{HOST}/wx`
|
||||
|
||||
## Enterprise Service Account
|
||||
|
||||
The setup is largely identical to the subscription account, with these differences:
|
||||
Same setup with these differences:
|
||||
|
||||
1. Register an enterprise service account and complete WeChat verification, ensure **Customer Service API** permission is granted
|
||||
1. Register an enterprise service account with verified **Customer Service API** permission
|
||||
2. Set `"channel_type": "wechatmp_service"` in `config.json`
|
||||
3. Replies can be proactively pushed to users without them having to manually retrieve them
|
||||
3. Replies can be proactively pushed to users
|
||||
|
||||
```json
|
||||
{
|
||||
|
||||
@@ -1,31 +1,31 @@
|
||||
---
|
||||
title: WeCom
|
||||
description: Integrate CowAgent with WeCom (WeChat Work) custom app
|
||||
description: Integrate CowAgent into WeCom enterprise app
|
||||
---
|
||||
|
||||
# WeCom (WeChat Work)
|
||||
|
||||
Integrate CowAgent through a WeCom custom application for internal team messaging.
|
||||
Integrate CowAgent into WeCom through a custom enterprise app, supporting one-on-one chat for internal employees.
|
||||
|
||||
<Note>
|
||||
WeCom only supports Docker deployment or server-based Python deployment, not local running mode.
|
||||
WeCom only supports Docker deployment or server Python deployment. Local run mode is not supported.
|
||||
</Note>
|
||||
|
||||
## 1. Prerequisites
|
||||
|
||||
- A server with a public IP
|
||||
- A WeCom account (individuals can register but cannot be verified)
|
||||
- For verified WeCom accounts, a domain registered to the same entity
|
||||
Required resources:
|
||||
|
||||
## 2. Create a WeCom App
|
||||
1. A server with public IP
|
||||
2. A registered WeCom account (individual registration is possible, but cannot be certified)
|
||||
3. Certified WeCom requires a domain with corresponding entity filing
|
||||
|
||||
1. In the [WeCom Admin Console](https://work.weixin.qq.com/wework_admin/frame#profile), go to **My Enterprise** to get the **Corp ID**
|
||||
2. Go to **App Management**, create a new app, and note the `AgentId` and `Secret`
|
||||
3. Click **Set API Receive**, configure the app interface:
|
||||
- URL format: `http://ip:port/wxcomapp` (verified enterprises need a registered domain)
|
||||
- Generate and save the `Token` and `EncodingAESKey`
|
||||
## 2. Create WeCom App
|
||||
|
||||
## 3. Configuration and Startup
|
||||
1. Get **Corp ID** from **My Enterprise** in [WeCom Admin Console](https://work.weixin.qq.com/wework_admin/frame#profile)
|
||||
2. Switch to **Application Management**, click Create Application, record `AgentId` and `Secret`
|
||||
3. Click **Set API Reception**, configure application interface:
|
||||
- URL format: `http://ip:port/wxcomapp` (certified enterprises must use filed domain)
|
||||
- Generate random `Token` and `EncodingAESKey` and save
|
||||
|
||||
## 3. Configuration and Run
|
||||
|
||||
```json
|
||||
{
|
||||
@@ -41,19 +41,19 @@ Integrate CowAgent through a WeCom custom application for internal team messagin
|
||||
|
||||
| Parameter | Description |
|
||||
| --- | --- |
|
||||
| `wechatcom_corp_id` | Enterprise Corp ID |
|
||||
| `wechatcomapp_token` | Token from API receive config |
|
||||
| `wechatcom_corp_id` | Corp ID |
|
||||
| `wechatcomapp_token` | Token from API reception config |
|
||||
| `wechatcomapp_secret` | App Secret |
|
||||
| `wechatcomapp_agent_id` | App AgentId |
|
||||
| `wechatcomapp_aes_key` | EncodingAESKey from API receive config |
|
||||
| `wechatcomapp_port` | Listening port, default 9898 |
|
||||
| `wechatcomapp_aes_key` | EncodingAESKey from API reception config |
|
||||
| `wechatcomapp_port` | Listen port, default 9898 |
|
||||
|
||||
After starting the program, save the **message server configuration** in the WeCom console, then add the server IP to **Trusted IPs**.
|
||||
After starting the program, return to WeCom Admin Console to save **Message Server Configuration**, and add the server IP to **Enterprise Trusted IPs**.
|
||||
|
||||
<Warning>
|
||||
If configuration fails: 1. Ensure the firewall and security group allow the port; 2. Verify all parameters match; 3. Verified enterprises need a registered domain.
|
||||
If configuration fails: 1. Ensure firewall and security group allow the port; 2. Verify all parameters are consistent; 3. Certified enterprises must configure a filed domain.
|
||||
</Warning>
|
||||
|
||||
## 4. Usage
|
||||
|
||||
Search for the app name in WeCom to start chatting. To allow external WeChat users, share the invitation QR code from **My Enterprise → WeChat Plugin**.
|
||||
Search for the app name in WeCom to start chatting. To allow external WeChat users, share the invite QR code from **My Enterprise → WeChat Plugin**.
|
||||
|
||||
@@ -1,101 +0,0 @@
|
||||
---
|
||||
title: Configuration
|
||||
description: CowAgent configuration file reference
|
||||
---
|
||||
|
||||
# Configuration
|
||||
|
||||
The config template is located at `config-template.json` in the project root. Copy it to create the active `config.json`:
|
||||
|
||||
```bash
|
||||
cp config-template.json config.json
|
||||
```
|
||||
|
||||
## Core Settings
|
||||
|
||||
```json
|
||||
{
|
||||
"channel_type": "web",
|
||||
"model": "MiniMax-M2.5",
|
||||
"agent": true,
|
||||
"agent_workspace": "~/cow",
|
||||
"agent_max_context_tokens": 40000,
|
||||
"agent_max_context_turns": 30,
|
||||
"agent_max_steps": 15
|
||||
}
|
||||
```
|
||||
|
||||
| Parameter | Description | Default |
|
||||
| --- | --- | --- |
|
||||
| `channel_type` | Channel type | `web` |
|
||||
| `model` | Model name | `MiniMax-M2.5` |
|
||||
| `agent` | Enable Agent mode | `true` |
|
||||
| `agent_workspace` | Agent workspace path | `~/cow` |
|
||||
| `agent_max_context_tokens` | Maximum context tokens | `40000` |
|
||||
| `agent_max_context_turns` | Maximum context conversation turns | `30` |
|
||||
| `agent_max_steps` | Maximum tool call steps per task | `15` |
|
||||
|
||||
## Model API Keys
|
||||
|
||||
Fill in the API key for your chosen model:
|
||||
|
||||
```json
|
||||
{
|
||||
"minimax_api_key": "",
|
||||
"zhipu_ai_api_key": "",
|
||||
"moonshot_api_key": "",
|
||||
"ark_api_key": "",
|
||||
"dashscope_api_key": "",
|
||||
"claude_api_key": "",
|
||||
"gemini_api_key": "",
|
||||
"open_ai_api_key": ""
|
||||
}
|
||||
```
|
||||
|
||||
See [Models](/en/models) for detailed model configuration.
|
||||
|
||||
## Voice Settings
|
||||
|
||||
```json
|
||||
{
|
||||
"speech_recognition": false,
|
||||
"group_speech_recognition": false,
|
||||
"voice_reply_voice": false
|
||||
}
|
||||
```
|
||||
|
||||
| Parameter | Description |
|
||||
| --- | --- |
|
||||
| `speech_recognition` | Enable private chat voice recognition |
|
||||
| `group_speech_recognition` | Enable group chat voice recognition |
|
||||
| `voice_reply_voice` | Reply to voice messages with voice |
|
||||
|
||||
## LinkAI Settings
|
||||
|
||||
```json
|
||||
{
|
||||
"use_linkai": false,
|
||||
"linkai_api_key": "",
|
||||
"linkai_app_code": ""
|
||||
}
|
||||
```
|
||||
|
||||
| Parameter | Description |
|
||||
| --- | --- |
|
||||
| `use_linkai` | Enable LinkAI integration |
|
||||
| `linkai_api_key` | LinkAI API Key, create at [console](https://link-ai.tech/console/interface) |
|
||||
| `linkai_app_code` | LinkAI app or workflow code |
|
||||
|
||||
## Proxy Settings
|
||||
|
||||
If you need a network proxy:
|
||||
|
||||
```json
|
||||
{
|
||||
"proxy": "127.0.0.1:7890"
|
||||
}
|
||||
```
|
||||
|
||||
<Tip>
|
||||
For all configuration options, see the [`config.py`](https://github.com/zhayujie/chatgpt-on-wechat/blob/master/config.py) file in the project.
|
||||
</Tip>
|
||||
113
docs/en/guide/manual-install.mdx
Normal file
113
docs/en/guide/manual-install.mdx
Normal file
@@ -0,0 +1,113 @@
|
||||
---
|
||||
title: Manual Install
|
||||
description: Deploy CowAgent manually (source code / Docker)
|
||||
---
|
||||
|
||||
## Source Code Deployment
|
||||
|
||||
### 1. Clone the project
|
||||
|
||||
```bash
|
||||
git clone https://github.com/zhayujie/chatgpt-on-wechat
|
||||
cd chatgpt-on-wechat/
|
||||
```
|
||||
|
||||
<Tip>
|
||||
For network issues, use the mirror: https://gitee.com/zhayujie/chatgpt-on-wechat
|
||||
</Tip>
|
||||
|
||||
### 2. Install dependencies
|
||||
|
||||
Core dependencies (required):
|
||||
|
||||
```bash
|
||||
pip3 install -r requirements.txt
|
||||
```
|
||||
|
||||
Optional dependencies (recommended):
|
||||
|
||||
```bash
|
||||
pip3 install -r requirements-optional.txt
|
||||
```
|
||||
|
||||
### 3. Configure
|
||||
|
||||
Copy the config template and edit:
|
||||
|
||||
```bash
|
||||
cp config-template.json config.json
|
||||
```
|
||||
|
||||
Fill in model API keys, channel type, and other settings in `config.json`. See the [model docs](/en/models/index) for details.
|
||||
|
||||
### 4. Run
|
||||
|
||||
**Local run:**
|
||||
|
||||
```bash
|
||||
python3 app.py
|
||||
```
|
||||
|
||||
By default, the Web service starts. Access `http://localhost:9899/chat` to chat.
|
||||
|
||||
**Background run on server:**
|
||||
|
||||
```bash
|
||||
nohup python3 app.py & tail -f nohup.out
|
||||
```
|
||||
|
||||
## Docker Deployment
|
||||
|
||||
Docker deployment does not require cloning source code or installing dependencies. For Agent mode, source deployment is recommended for broader system access.
|
||||
|
||||
<Note>
|
||||
Requires [Docker](https://docs.docker.com/engine/install/) and docker-compose.
|
||||
</Note>
|
||||
|
||||
**1. Download config**
|
||||
|
||||
```bash
|
||||
wget https://cdn.link-ai.tech/code/cow/docker-compose.yml
|
||||
```
|
||||
|
||||
Edit `docker-compose.yml` with your configuration.
|
||||
|
||||
**2. Start container**
|
||||
|
||||
```bash
|
||||
sudo docker compose up -d
|
||||
```
|
||||
|
||||
**3. View logs**
|
||||
|
||||
```bash
|
||||
sudo docker logs -f chatgpt-on-wechat
|
||||
```
|
||||
|
||||
## Core Configuration
|
||||
|
||||
```json
|
||||
{
|
||||
"channel_type": "web",
|
||||
"model": "MiniMax-M2.5",
|
||||
"agent": true,
|
||||
"agent_workspace": "~/cow",
|
||||
"agent_max_context_tokens": 40000,
|
||||
"agent_max_context_turns": 30,
|
||||
"agent_max_steps": 15
|
||||
}
|
||||
```
|
||||
|
||||
| Parameter | Description | Default |
|
||||
| --- | --- | --- |
|
||||
| `channel_type` | Channel type | `web` |
|
||||
| `model` | Model name | `MiniMax-M2.5` |
|
||||
| `agent` | Enable Agent mode | `true` |
|
||||
| `agent_workspace` | Agent workspace path | `~/cow` |
|
||||
| `agent_max_context_tokens` | Max context tokens | `40000` |
|
||||
| `agent_max_context_turns` | Max context turns | `30` |
|
||||
| `agent_max_steps` | Max decision steps per task | `15` |
|
||||
|
||||
<Tip>
|
||||
Full configuration options are in the project [`config.py`](https://github.com/zhayujie/chatgpt-on-wechat/blob/master/config.py).
|
||||
</Tip>
|
||||
39
docs/en/guide/quick-start.mdx
Normal file
39
docs/en/guide/quick-start.mdx
Normal file
@@ -0,0 +1,39 @@
|
||||
---
|
||||
title: One-click Install
|
||||
description: One-click install and manage CowAgent with scripts
|
||||
---
|
||||
|
||||
The project provides scripts for one-click install, configuration, startup, and management. Script-based deployment is recommended for quick setup.
|
||||
|
||||
Supports Linux, macOS, and Windows. Requires Python 3.7-3.12 (3.9 recommended).
|
||||
|
||||
## Install Command
|
||||
|
||||
```bash
|
||||
bash <(curl -sS https://cdn.link-ai.tech/code/cow/run.sh)
|
||||
```
|
||||
|
||||
The script automatically performs these steps:
|
||||
|
||||
1. Check Python environment (requires Python 3.7+)
|
||||
2. Install required tools (git, curl, etc.)
|
||||
3. Clone project to `~/chatgpt-on-wechat`
|
||||
4. Install Python dependencies
|
||||
5. Guided configuration for AI model and channel
|
||||
6. Start service
|
||||
|
||||
By default, the Web service starts after installation. Access `http://localhost:9899/chat` to begin chatting.
|
||||
|
||||
## Management Commands
|
||||
|
||||
After installation, use these commands to manage the service:
|
||||
|
||||
| Command | Description |
|
||||
| --- | --- |
|
||||
| `./run.sh start` | Start service |
|
||||
| `./run.sh stop` | Stop service |
|
||||
| `./run.sh restart` | Restart service |
|
||||
| `./run.sh status` | Check run status |
|
||||
| `./run.sh logs` | View real-time logs |
|
||||
| `./run.sh config` | Reconfigure |
|
||||
| `./run.sh update` | Update project code |
|
||||
@@ -1,64 +0,0 @@
|
||||
---
|
||||
title: Introduction
|
||||
description: CowAgent - AI Super Assistant powered by LLMs
|
||||
---
|
||||
|
||||
# CowAgent
|
||||
|
||||
**CowAgent** is an AI super assistant powered by large language models, capable of autonomous thinking and task planning, operating computers and external resources, creating and executing Skills, with long-term memory that grows with you.
|
||||
|
||||
CowAgent supports flexible switching between multiple models, handles multimodal messages including text, voice, images, and files, and can be integrated into web, Feishu (Lark), DingTalk, WeCom, and WeChat Official Accounts for 24/7 operation on your personal computer or server.
|
||||
|
||||
## Core Capabilities
|
||||
|
||||
<CardGroup cols={2}>
|
||||
<Card title="Complex Task Planning" icon="brain">
|
||||
Understands complex tasks and autonomously plans execution, continuously thinking and calling tools until the goal is achieved. Supports accessing files, terminals, browsers, scheduled tasks, and other system resources.
|
||||
</Card>
|
||||
<Card title="Long-term Memory" icon="database">
|
||||
Automatically persists conversation memory to local files and databases, including core memory and daily memory, with keyword and vector search support.
|
||||
</Card>
|
||||
<Card title="Skills System" icon="puzzle-piece">
|
||||
Implements a Skills creation and execution engine with multiple built-in skills, and supports custom skill development through natural language conversations.
|
||||
</Card>
|
||||
<Card title="Multimodal Messages" icon="image">
|
||||
Supports parsing, processing, generating, and sending multiple message types including text, images, voice, and files.
|
||||
</Card>
|
||||
<Card title="Multiple Models" icon="microchip">
|
||||
Supports OpenAI, Claude, Gemini, DeepSeek, MiniMax, GLM, Qwen, Kimi, Doubao, and other major model providers.
|
||||
</Card>
|
||||
<Card title="Multi-platform Deployment" icon="server">
|
||||
Runs on local computers or servers, integrable with web, Feishu, DingTalk, WeChat Official Accounts, and WeCom.
|
||||
</Card>
|
||||
</CardGroup>
|
||||
|
||||
## Quick Experience
|
||||
|
||||
Run the following command in your terminal to install, configure, and start CowAgent with one click:
|
||||
|
||||
```bash
|
||||
bash <(curl -sS https://cdn.link-ai.tech/code/cow/run.sh)
|
||||
```
|
||||
|
||||
After running, a Web service starts by default. Visit `http://localhost:9899/chat` to start chatting.
|
||||
|
||||
<CardGroup cols={2}>
|
||||
<Card title="Quick Start" icon="rocket" href="/en/quick-start">
|
||||
View the complete installation and setup guide
|
||||
</Card>
|
||||
<Card title="Architecture" icon="sitemap" href="/en/architecture">
|
||||
Learn about the CowAgent system architecture
|
||||
</Card>
|
||||
</CardGroup>
|
||||
|
||||
## Disclaimer
|
||||
|
||||
1. This project follows the [MIT License](https://github.com/zhayujie/chatgpt-on-wechat/blob/master/LICENSE) and is primarily for technical research and learning.
|
||||
2. Token usage in Agent mode is higher than regular chat mode. Please choose models based on both effectiveness and cost. The Agent has access to the operating system — please choose deployment environments carefully.
|
||||
3. The CowAgent project focuses on open-source technology development and will not participate in, authorize, or issue any cryptocurrency.
|
||||
|
||||
## Community
|
||||
|
||||
Join the open-source community by adding the assistant on WeChat:
|
||||
|
||||
<img width="140" src="https://img-1317903499.cos.ap-guangzhou.myqcloud.com/docs/open-community.png" />
|
||||
71
docs/en/intro/architecture.mdx
Normal file
71
docs/en/intro/architecture.mdx
Normal file
@@ -0,0 +1,71 @@
|
||||
---
|
||||
title: Architecture
|
||||
description: CowAgent 2.0 system architecture and core design
|
||||
---
|
||||
|
||||
CowAgent 2.0 has evolved from a simple chatbot into a super intelligent assistant with Agent architecture, featuring autonomous thinking, task planning, long-term memory, and skill extensibility.
|
||||
|
||||
## System Architecture
|
||||
|
||||
CowAgent's architecture consists of the following core modules:
|
||||
|
||||
<img src="https://cdn.link-ai.tech/doc/68ef7b212c6f791e0e74314b912149f9-sz_5847990.png" alt="CowAgent Architecture" />
|
||||
|
||||
### Core Modules
|
||||
|
||||
| Module | Description |
|
||||
| --- | --- |
|
||||
| **Channels** | Message channel layer for receiving and sending messages. Supports Web, Feishu, DingTalk, WeCom, WeChat Official Account, and more |
|
||||
| **Agent Core** | Agent engine including task planning, memory system, and skills engine |
|
||||
| **Tools** | Tool layer for Agent to access OS resources. 10+ built-in tools |
|
||||
| **Models** | Model layer with unified access to mainstream LLMs |
|
||||
|
||||
## Agent Mode Workflow
|
||||
|
||||
When Agent mode is enabled, CowAgent runs as an autonomous agent with the following workflow:
|
||||
|
||||
1. **Receive Message** — Receive user input through channels
|
||||
2. **Understand Intent** — Analyze task requirements and context
|
||||
3. **Plan Task** — Break complex tasks into multiple steps
|
||||
4. **Invoke Tools** — Select and execute appropriate tools for each step
|
||||
5. **Update Memory** — Store important information in long-term memory
|
||||
6. **Return Result** — Send execution results back to the user
|
||||
|
||||
## Workspace Directory Structure
|
||||
|
||||
The Agent workspace is located at `~/cow` by default and stores system prompts, memory files, and skill files:
|
||||
|
||||
```
|
||||
~/cow/
|
||||
├── system.md # Agent system prompt
|
||||
├── user.md # User profile
|
||||
├── memory/ # Long-term memory storage
|
||||
│ ├── core.md # Core memory
|
||||
│ └── daily/ # Daily memory
|
||||
├── skills/ # Custom skills
|
||||
│ ├── skill-1/
|
||||
│ └── skill-2/
|
||||
└── .env # Secret keys for skills
|
||||
```
|
||||
|
||||
## Core Configuration
|
||||
|
||||
Configure Agent mode parameters in `config.json`:
|
||||
|
||||
```json
|
||||
{
|
||||
"agent": true,
|
||||
"agent_workspace": "~/cow",
|
||||
"agent_max_context_tokens": 40000,
|
||||
"agent_max_context_turns": 30,
|
||||
"agent_max_steps": 15
|
||||
}
|
||||
```
|
||||
|
||||
| Parameter | Description | Default |
|
||||
| --- | --- | --- |
|
||||
| `agent` | Enable Agent mode | `true` |
|
||||
| `agent_workspace` | Workspace path | `~/cow` |
|
||||
| `agent_max_context_tokens` | Max context tokens | `40000` |
|
||||
| `agent_max_context_turns` | Max context turns | `30` |
|
||||
| `agent_max_steps` | Max decision steps per task | `15` |
|
||||
105
docs/en/intro/features.mdx
Normal file
105
docs/en/intro/features.mdx
Normal file
@@ -0,0 +1,105 @@
|
||||
---
|
||||
title: Features
|
||||
description: CowAgent long-term memory, task planning, and skills system in detail
|
||||
---
|
||||
|
||||
## 1. Long-term Memory
|
||||
|
||||
The memory system enables the Agent to remember important information over time. The Agent proactively stores information when users share preferences, decisions, or key facts, and automatically extracts summaries when conversations reach a certain length. Memory is divided into core memory and daily memory, with hybrid retrieval supporting both keyword search and vector search.
|
||||
|
||||
On first launch, the Agent proactively asks the user for key information and records it in the workspace (default `~/cow`) — including agent settings, user identity, and memory files.
|
||||
|
||||
In subsequent long-term conversations, the Agent intelligently stores or retrieves memory as needed, continuously updating its own settings, user preferences, and memory files, summarizing experiences and lessons learned — truly achieving autonomous thinking and continuous growth.
|
||||
|
||||
<Frame>
|
||||
<img src="https://cdn.link-ai.tech/doc/20260203000455.png" width="800" />
|
||||
</Frame>
|
||||
|
||||
## 2. Task Planning and Tool Use
|
||||
|
||||
Tools are the core of how the Agent accesses operating system resources. The Agent intelligently selects and invokes tools based on task requirements, performing file read/write, command execution, scheduled tasks, and more. Built-in tools are implemented in the project's `agent/tools/` directory.
|
||||
|
||||
**Key tools:** file read/write/edit, Bash terminal, file send, scheduler, memory search, web search, environment config, and more.
|
||||
|
||||
### 2.1 Terminal and File Access
|
||||
|
||||
Access to the OS terminal and file system is the most fundamental and core capability. Many other tools and skills build on top of this. Users can interact with the Agent from a mobile device to operate resources on their personal computer or server:
|
||||
|
||||
<Frame>
|
||||
<img src="https://cdn.link-ai.tech/doc/20260202181130.png" width="800" />
|
||||
</Frame>
|
||||
|
||||
### 2.2 Programming Capability
|
||||
|
||||
Combining programming and system access, the Agent can execute the complete **Vibecoding workflow** — from information search, asset generation, coding, testing, deployment, Nginx configuration, to publishing — all triggered by a single command from your phone:
|
||||
|
||||
<Frame>
|
||||
<img src="https://cdn.link-ai.tech/doc/20260203121008.png" width="800" />
|
||||
</Frame>
|
||||
|
||||
### 2.3 Scheduled Tasks
|
||||
|
||||
The `scheduler` tool enables dynamic scheduled tasks, supporting **one-time tasks, fixed intervals, and Cron expressions**. Tasks can be triggered as either a **fixed message send** or an **Agent dynamic task** execution:
|
||||
|
||||
<Frame>
|
||||
<img src="https://cdn.link-ai.tech/doc/20260202195402.png" width="800" />
|
||||
</Frame>
|
||||
|
||||
### 2.4 Environment Variable Management
|
||||
|
||||
Secrets required by skills are stored in an environment variable file, managed by the `env_config` tool. You can update secrets through conversation, with built-in security protection and desensitization:
|
||||
|
||||
<Frame>
|
||||
<img src="https://cdn.link-ai.tech/doc/20260202234939.png" width="800" />
|
||||
</Frame>
|
||||
|
||||
## 3. Skills System
|
||||
|
||||
The Skills system provides infinite extensibility for the Agent. Each Skill consists of a description file, execution scripts (optional), and resources (optional), describing how to complete specific types of tasks. Skills allow the Agent to follow instructions for complex workflows, invoke tools, or integrate third-party systems.
|
||||
|
||||
- **Built-in skills:** Located in the project's `skills/` directory, including skill creator, image recognition, LinkAI agent, web fetch, and more. Built-in skills are automatically enabled based on dependency conditions (API keys, system commands, etc.).
|
||||
- **Custom skills:** Created by users through conversation, stored in the workspace (`~/cow/skills/`), capable of implementing any complex business process or third-party integration.
|
||||
|
||||
### 3.1 Creating Skills
|
||||
|
||||
The `skill-creator` skill enables rapid skill creation through conversation. You can ask the Agent to codify a workflow as a skill, or send any API documentation and examples for the Agent to complete the integration directly:
|
||||
|
||||
<Frame>
|
||||
<img src="https://cdn.link-ai.tech/doc/20260202202247.png" width="800" />
|
||||
</Frame>
|
||||
|
||||
### 3.2 Web Search and Image Recognition
|
||||
|
||||
- **Web search:** Built-in `web_search` tool, supports multiple search engines. Configure `BOCHA_API_KEY` or `LINKAI_API_KEY` to enable.
|
||||
- **Image recognition:** Built-in `openai-image-vision` skill, supports `gpt-4.1-mini`, `gpt-4.1`, and other models. Requires `OPENAI_API_KEY`.
|
||||
|
||||
<Frame>
|
||||
<img src="https://cdn.link-ai.tech/doc/20260202213219.png" width="800" />
|
||||
</Frame>
|
||||
|
||||
### 3.3 Third-party Knowledge Bases and Plugins
|
||||
|
||||
The `linkai-agent` skill makes all agents on [LinkAI](https://link-ai.tech/) available as Skills for the Agent, enabling multi-agent decision making.
|
||||
|
||||
Configuration: set `LINKAI_API_KEY` via `env_config`, then add agent descriptions in `skills/linkai-agent/config.json`:
|
||||
|
||||
```json
|
||||
{
|
||||
"apps": [
|
||||
{
|
||||
"app_code": "G7z6vKwp",
|
||||
"app_name": "LinkAI Customer Support",
|
||||
"app_description": "Select only when the user needs help with LinkAI platform questions"
|
||||
},
|
||||
{
|
||||
"app_code": "SFY5x7JR",
|
||||
"app_name": "Content Creator",
|
||||
"app_description": "Use only when the user needs to create images or videos"
|
||||
}
|
||||
]
|
||||
}
|
||||
```
|
||||
|
||||
<Frame>
|
||||
<img src="https://cdn.link-ai.tech/doc/20260202234350.png" width="750" />
|
||||
</Frame>
|
||||
68
docs/en/intro/index.mdx
Normal file
68
docs/en/intro/index.mdx
Normal file
@@ -0,0 +1,68 @@
|
||||
---
|
||||
title: Introduction
|
||||
description: CowAgent - AI Super Assistant powered by LLMs
|
||||
---
|
||||
|
||||
<img src="https://cdn.link-ai.tech/doc/78c5dd674e2c828642ecc0406669fed7.png" alt="CowAgent" width="600px"/>
|
||||
|
||||
**CowAgent** is an AI super assistant powered by LLMs with autonomous task planning, long-term memory, skills system, multimodal messages, multiple model support, and multi-platform deployment.
|
||||
|
||||
CowAgent can proactively think and plan tasks, operate computers and external resources, create and execute Skills, and continuously grow with long-term memory. It supports flexible switching between multiple models, handles text, voice, images, files and other multimodal messages, and can be integrated into web, Feishu, DingTalk, WeCom, and WeChat Official Account. It runs 7x24 hours on your personal computer or server.
|
||||
|
||||
<Card title="GitHub" icon="github" href="https://github.com/zhayujie/chatgpt-on-wechat">
|
||||
github.com/zhayujie/chatgpt-on-wechat
|
||||
</Card>
|
||||
|
||||
## Core Capabilities
|
||||
|
||||
<CardGroup cols={2}>
|
||||
<Card title="Autonomous Task Planning" icon="brain" href="/en/intro/architecture">
|
||||
Understands complex tasks and autonomously plans execution, continuously thinking and invoking tools until goals are achieved. Supports accessing file systems, terminals, browsers, schedulers, and other system resources through tools.
|
||||
</Card>
|
||||
<Card title="Long-term Memory" icon="database" href="/en/memory">
|
||||
Automatically persists conversation memory to local files and databases, including core memory and daily memory, with keyword and vector retrieval support.
|
||||
</Card>
|
||||
<Card title="Skills System" icon="puzzle-piece" href="/en/skills/index">
|
||||
Implements a Skills creation and execution engine with built-in skills, and supports custom Skills development through natural language conversation.
|
||||
</Card>
|
||||
<Card title="Multimodal Messages" icon="image" href="/en/channels/web">
|
||||
Supports parsing, processing, generating, and sending text, images, voice, files, and other message types.
|
||||
</Card>
|
||||
<Card title="Multiple Model Support" icon="microchip" href="/en/models/index">
|
||||
Supports mainstream model providers including OpenAI, Claude, Gemini, DeepSeek, MiniMax, GLM, Qwen, Kimi, Doubao, and more.
|
||||
</Card>
|
||||
<Card title="Multi-platform Deployment" icon="server" href="/en/channels/web">
|
||||
Runs on local computers or servers, integrable into web, Feishu, DingTalk, WeChat Official Account, and WeCom applications.
|
||||
</Card>
|
||||
</CardGroup>
|
||||
|
||||
## Quick Experience
|
||||
|
||||
Run the following command in your terminal for one-click install, configuration, and startup:
|
||||
|
||||
```bash
|
||||
bash <(curl -sS https://cdn.link-ai.tech/code/cow/run.sh)
|
||||
```
|
||||
|
||||
By default, the Web service starts after running. Access `http://localhost:9899/chat` to chat in the web interface.
|
||||
|
||||
<CardGroup cols={2}>
|
||||
<Card title="Quick Start" icon="rocket" href="/en/guide/quick-start">
|
||||
Complete installation and run guide
|
||||
</Card>
|
||||
<Card title="Architecture" icon="sitemap" href="/en/intro/architecture">
|
||||
CowAgent system architecture design
|
||||
</Card>
|
||||
</CardGroup>
|
||||
|
||||
## Disclaimer
|
||||
|
||||
1. This project follows the [MIT License](https://github.com/zhayujie/chatgpt-on-wechat/blob/master/LICENSE) and is intended for technical research and learning. Users must comply with local laws, regulations, policies, and corporate bylaws. Any illegal or rights-infringing use is prohibited.
|
||||
2. Agent mode consumes more tokens than normal chat mode. Choose models based on effectiveness and cost. Agent has access to the host operating system — deploy with caution.
|
||||
3. CowAgent focuses on open-source development and does not participate in, authorize, or issue any cryptocurrency.
|
||||
|
||||
## Community
|
||||
|
||||
Add our assistant on WeChat to join the open-source community:
|
||||
|
||||
<img width="140" src="https://img-1317903499.cos.ap-guangzhou.myqcloud.com/docs/open-community.png" />
|
||||
@@ -3,17 +3,15 @@ title: Memory
|
||||
description: CowAgent long-term memory system
|
||||
---
|
||||
|
||||
# Long-term Memory
|
||||
|
||||
The memory system enables the Agent to remember important information over time, continuously accumulating experience, understanding user preferences, and achieving autonomous thinking and growth.
|
||||
The memory system enables the Agent to remember important information over time, continuously accumulating experience, understanding user preferences, and truly achieving autonomous thinking and continuous growth.
|
||||
|
||||
## How It Works
|
||||
|
||||
The Agent proactively stores memory in these scenarios:
|
||||
The Agent proactively stores memory in the following scenarios:
|
||||
|
||||
- **When users share important information** — Automatically identifies and stores preferences, decisions, facts, and other key information
|
||||
- **When conversations reach a certain length** — Automatically extracts summaries to prevent information loss
|
||||
- **When retrieval is needed** — Intelligently searches historical memory and combines it with context
|
||||
- **When user shares important information** — Automatically identifies and stores preferences, decisions, facts, and other key information
|
||||
- **When conversation reaches a certain length** — Automatically extracts summaries to prevent information loss
|
||||
- **When retrieval is needed** — Intelligently searches historical memory, combining context for responses
|
||||
|
||||
## Memory Types
|
||||
|
||||
@@ -23,16 +21,16 @@ Stored in `~/cow/memory/core.md`, containing long-term user preferences, importa
|
||||
|
||||
### Daily Memory
|
||||
|
||||
Stored in the `~/cow/memory/daily/` directory, organized by date, recording daily conversation summaries and key events.
|
||||
Stored in `~/cow/memory/daily/` directory, organized by date, recording daily conversation summaries and key events.
|
||||
|
||||
## First Startup
|
||||
## First Launch
|
||||
|
||||
On first startup, the Agent proactively asks the user for key information and records it in the workspace (default `~/cow`):
|
||||
On first launch, the Agent will proactively ask the user for key information and save it to the workspace (default `~/cow`):
|
||||
|
||||
| File | Description |
|
||||
| --- | --- |
|
||||
| `system.md` | Agent system prompt and behavior settings |
|
||||
| `user.md` | User identity and preferences |
|
||||
| `user.md` | User identity information and preferences |
|
||||
| `memory/core.md` | Core memory |
|
||||
| `memory/daily/` | Daily memory directory |
|
||||
|
||||
@@ -42,17 +40,15 @@ On first startup, the Agent proactively asks the user for key information and re
|
||||
|
||||
## Memory Retrieval
|
||||
|
||||
The memory system supports hybrid retrieval:
|
||||
The memory system supports hybrid retrieval modes:
|
||||
|
||||
- **Keyword Search** — Matches historical memory based on keywords
|
||||
- **Vector Search** — Semantic similarity search that finds related memories even with different wording
|
||||
- **Keyword retrieval** — Match historical memory based on keywords
|
||||
- **Vector retrieval** — Semantic similarity search, finds relevant memory even with different wording
|
||||
|
||||
The Agent automatically triggers memory retrieval during conversations, incorporating relevant historical information into the context.
|
||||
The Agent automatically triggers memory retrieval during conversation as needed, incorporating relevant historical information into context.
|
||||
|
||||
## Configuration
|
||||
|
||||
Adjust memory-related parameters in `config.json`:
|
||||
|
||||
```json
|
||||
{
|
||||
"agent_workspace": "~/cow",
|
||||
@@ -63,6 +59,6 @@ Adjust memory-related parameters in `config.json`:
|
||||
|
||||
| Parameter | Description | Default |
|
||||
| --- | --- | --- |
|
||||
| `agent_workspace` | Workspace path where memory files are stored | `~/cow` |
|
||||
| `agent_max_context_tokens` | Maximum context tokens, affects short-term memory capacity | `40000` |
|
||||
| `agent_max_context_turns` | Maximum context turns, older conversations are discarded when exceeded | `30` |
|
||||
| `agent_workspace` | Workspace path, memory files stored under this directory | `~/cow` |
|
||||
| `agent_max_context_tokens` | Max context tokens, affects short-term memory capacity | `40000` |
|
||||
| `agent_max_context_turns` | Max context turns, oldest conversations discarded when exceeded | `30` |
|
||||
|
||||
@@ -1,173 +0,0 @@
|
||||
---
|
||||
title: Models
|
||||
description: Supported models and configuration guide
|
||||
---
|
||||
|
||||
# Models
|
||||
|
||||
CowAgent supports major LLM providers from China and worldwide. Model implementations are in the `models/` directory.
|
||||
|
||||
<Note>
|
||||
Recommended models for Agent mode: MiniMax-M2.5, glm-5, kimi-k2.5, qwen3.5-plus, claude-sonnet-4-6, gemini-3.1-pro-preview. Choose based on effectiveness and cost.
|
||||
</Note>
|
||||
|
||||
## Model Configuration
|
||||
|
||||
Set the model name and corresponding API key in `config.json`.
|
||||
|
||||
### MiniMax
|
||||
|
||||
```json
|
||||
{
|
||||
"model": "MiniMax-M2.5",
|
||||
"minimax_api_key": "YOUR_API_KEY"
|
||||
}
|
||||
```
|
||||
|
||||
| Parameter | Description |
|
||||
| --- | --- |
|
||||
| `model` | `MiniMax-M2.5`, `MiniMax-M2.1`, `MiniMax-M2.1-lightning`, `MiniMax-M2`, etc. |
|
||||
| `minimax_api_key` | Create at [MiniMax Console](https://platform.minimaxi.com/user-center/basic-information/interface-key) |
|
||||
|
||||
### GLM (Zhipu AI)
|
||||
|
||||
```json
|
||||
{
|
||||
"model": "glm-5",
|
||||
"zhipu_ai_api_key": "YOUR_API_KEY"
|
||||
}
|
||||
```
|
||||
|
||||
| Parameter | Description |
|
||||
| --- | --- |
|
||||
| `model` | `glm-5`, `glm-4.7`, `glm-4-plus`, `glm-4-flash`, etc. See [model list](https://bigmodel.cn/dev/api/normal-model/glm-4) |
|
||||
| `zhipu_ai_api_key` | Create at [Zhipu AI Console](https://www.bigmodel.cn/usercenter/proj-mgmt/apikeys) |
|
||||
|
||||
### Qwen (Tongyi Qianwen)
|
||||
|
||||
```json
|
||||
{
|
||||
"model": "qwen3.5-plus",
|
||||
"dashscope_api_key": "YOUR_API_KEY"
|
||||
}
|
||||
```
|
||||
|
||||
| Parameter | Description |
|
||||
| --- | --- |
|
||||
| `model` | `qwen3.5-plus`, `qwen3-max`, `qwen-max`, `qwen-plus`, etc. |
|
||||
| `dashscope_api_key` | Create at [Bailian Console](https://bailian.console.aliyun.com/?tab=model#/api-key) |
|
||||
|
||||
### Kimi (Moonshot)
|
||||
|
||||
```json
|
||||
{
|
||||
"model": "kimi-k2.5",
|
||||
"moonshot_api_key": "YOUR_API_KEY"
|
||||
}
|
||||
```
|
||||
|
||||
| Parameter | Description |
|
||||
| --- | --- |
|
||||
| `model` | `kimi-k2.5`, `kimi-k2`, `moonshot-v1-8k`, `moonshot-v1-32k`, etc. |
|
||||
| `moonshot_api_key` | Create at [Moonshot Console](https://platform.moonshot.cn/console/api-keys) |
|
||||
|
||||
### Doubao (ByteDance)
|
||||
|
||||
```json
|
||||
{
|
||||
"model": "doubao-seed-2-0-code-preview-260215",
|
||||
"ark_api_key": "YOUR_API_KEY"
|
||||
}
|
||||
```
|
||||
|
||||
| Parameter | Description |
|
||||
| --- | --- |
|
||||
| `model` | `doubao-seed-2-0-code-preview-260215`, `doubao-seed-2-0-pro-260215`, etc. |
|
||||
| `ark_api_key` | Create at [Volcano Ark Console](https://console.volcengine.com/ark/region:ark+cn-beijing/apikey) |
|
||||
|
||||
### Claude
|
||||
|
||||
```json
|
||||
{
|
||||
"model": "claude-sonnet-4-6",
|
||||
"claude_api_key": "YOUR_API_KEY"
|
||||
}
|
||||
```
|
||||
|
||||
| Parameter | Description |
|
||||
| --- | --- |
|
||||
| `model` | `claude-sonnet-4-6`, `claude-opus-4-6`, `claude-sonnet-4-5`, etc. See [official models](https://docs.anthropic.com/en/docs/about-claude/models/overview) |
|
||||
| `claude_api_key` | Create at [Claude Console](https://console.anthropic.com/settings/keys) |
|
||||
| `claude_api_base` | Optional, defaults to `https://api.anthropic.com/v1` |
|
||||
|
||||
### Gemini
|
||||
|
||||
```json
|
||||
{
|
||||
"model": "gemini-3.1-pro-preview",
|
||||
"gemini_api_key": "YOUR_API_KEY"
|
||||
}
|
||||
```
|
||||
|
||||
| Parameter | Description |
|
||||
| --- | --- |
|
||||
| `model` | `gemini-3.1-pro-preview`, `gemini-3-flash-preview`, `gemini-2.5-pro`, etc. See [official docs](https://ai.google.dev/gemini-api/docs/models) |
|
||||
| `gemini_api_key` | Create at [Google AI Studio](https://aistudio.google.com/app/apikey) |
|
||||
|
||||
### OpenAI
|
||||
|
||||
```json
|
||||
{
|
||||
"model": "gpt-4.1-mini",
|
||||
"open_ai_api_key": "YOUR_API_KEY",
|
||||
"open_ai_api_base": "https://api.openai.com/v1"
|
||||
}
|
||||
```
|
||||
|
||||
| Parameter | Description |
|
||||
| --- | --- |
|
||||
| `model` | o-series, gpt-5.2, gpt-4.1, etc. See [model list](https://platform.openai.com/docs/models) |
|
||||
| `open_ai_api_key` | Create at [OpenAI Platform](https://platform.openai.com/api-keys) |
|
||||
| `open_ai_api_base` | Optional, modify to use third-party proxy |
|
||||
|
||||
### DeepSeek
|
||||
|
||||
```json
|
||||
{
|
||||
"model": "deepseek-chat",
|
||||
"open_ai_api_key": "YOUR_API_KEY",
|
||||
"open_ai_api_base": "https://api.deepseek.com/v1",
|
||||
"bot_type": "chatGPT"
|
||||
}
|
||||
```
|
||||
|
||||
| Parameter | Description |
|
||||
| --- | --- |
|
||||
| `model` | `deepseek-chat` (V3), `deepseek-reasoner` (R1) |
|
||||
| `bot_type` | OpenAI-compatible mode, set to `chatGPT` |
|
||||
|
||||
## OpenAI-Compatible Access
|
||||
|
||||
Most models also support OpenAI-compatible access. Set `bot_type` to `chatGPT` and configure the corresponding `open_ai_api_base` and `open_ai_api_key`.
|
||||
|
||||
## LinkAI Platform
|
||||
|
||||
[LinkAI](https://link-ai.tech) allows flexible model switching with knowledge base, workflow, and plugin support.
|
||||
|
||||
```json
|
||||
{
|
||||
"use_linkai": true,
|
||||
"linkai_api_key": "YOUR_API_KEY",
|
||||
"linkai_app_code": "YOUR_APP_CODE"
|
||||
}
|
||||
```
|
||||
|
||||
| Parameter | Description |
|
||||
| --- | --- |
|
||||
| `use_linkai` | Set to `true` to enable LinkAI |
|
||||
| `linkai_api_key` | Create at [console](https://link-ai.tech/console/interface) |
|
||||
| `linkai_app_code` | LinkAI agent code, optional |
|
||||
|
||||
<Tip>
|
||||
For all model names, see [`common/const.py`](https://github.com/zhayujie/chatgpt-on-wechat/blob/master/common/const.py) in the project.
|
||||
</Tip>
|
||||
17
docs/en/models/claude.mdx
Normal file
17
docs/en/models/claude.mdx
Normal file
@@ -0,0 +1,17 @@
|
||||
---
|
||||
title: Claude
|
||||
description: Claude model configuration
|
||||
---
|
||||
|
||||
```json
|
||||
{
|
||||
"model": "claude-sonnet-4-6",
|
||||
"claude_api_key": "YOUR_API_KEY"
|
||||
}
|
||||
```
|
||||
|
||||
| Parameter | Description |
|
||||
| --- | --- |
|
||||
| `model` | Options include `claude-sonnet-4-6`, `claude-opus-4-6`, `claude-sonnet-4-5`, `claude-sonnet-4-0`, `claude-3-5-sonnet-latest`, etc. See [official models](https://docs.anthropic.com/en/docs/about-claude/models/overview) |
|
||||
| `claude_api_key` | Create at [Claude Console](https://console.anthropic.com/settings/keys) |
|
||||
| `claude_api_base` | Optional. Defaults to `https://api.anthropic.com/v1`. Change to use third-party proxy |
|
||||
22
docs/en/models/deepseek.mdx
Normal file
22
docs/en/models/deepseek.mdx
Normal file
@@ -0,0 +1,22 @@
|
||||
---
|
||||
title: DeepSeek
|
||||
description: DeepSeek model configuration
|
||||
---
|
||||
|
||||
Use OpenAI-compatible configuration:
|
||||
|
||||
```json
|
||||
{
|
||||
"model": "deepseek-chat",
|
||||
"bot_type": "chatGPT",
|
||||
"open_ai_api_key": "YOUR_API_KEY",
|
||||
"open_ai_api_base": "https://api.deepseek.com/v1"
|
||||
}
|
||||
```
|
||||
|
||||
| Parameter | Description |
|
||||
| --- | --- |
|
||||
| `model` | `deepseek-chat` (DeepSeek-V3), `deepseek-reasoner` (DeepSeek-R1) |
|
||||
| `bot_type` | Must be `chatGPT` (OpenAI-compatible mode) |
|
||||
| `open_ai_api_key` | Create at [DeepSeek Platform](https://platform.deepseek.com/api_keys) |
|
||||
| `open_ai_api_base` | DeepSeek platform BASE URL |
|
||||
17
docs/en/models/doubao.mdx
Normal file
17
docs/en/models/doubao.mdx
Normal file
@@ -0,0 +1,17 @@
|
||||
---
|
||||
title: Doubao (ByteDance)
|
||||
description: Doubao (Volcano Ark) model configuration
|
||||
---
|
||||
|
||||
```json
|
||||
{
|
||||
"model": "doubao-seed-2-0-code-preview-260215",
|
||||
"ark_api_key": "YOUR_API_KEY"
|
||||
}
|
||||
```
|
||||
|
||||
| Parameter | Description |
|
||||
| --- | --- |
|
||||
| `model` | Options include `doubao-seed-2-0-code-preview-260215`, `doubao-seed-2-0-pro-260215`, `doubao-seed-2-0-lite-260215`, etc. |
|
||||
| `ark_api_key` | Create at [Volcano Ark Console](https://console.volcengine.com/ark/region:ark+cn-beijing/apikey) |
|
||||
| `ark_base_url` | Optional. Defaults to `https://ark.cn-beijing.volces.com/api/v3` |
|
||||
16
docs/en/models/gemini.mdx
Normal file
16
docs/en/models/gemini.mdx
Normal file
@@ -0,0 +1,16 @@
|
||||
---
|
||||
title: Gemini
|
||||
description: Google Gemini model configuration
|
||||
---
|
||||
|
||||
```json
|
||||
{
|
||||
"model": "gemini-3.1-pro-preview",
|
||||
"gemini_api_key": "YOUR_API_KEY"
|
||||
}
|
||||
```
|
||||
|
||||
| Parameter | Description |
|
||||
| --- | --- |
|
||||
| `model` | Options include `gemini-3.1-pro-preview`, `gemini-3-flash-preview`, `gemini-3-pro-preview`, `gemini-2.5-pro`, `gemini-2.0-flash`, etc. See [official docs](https://ai.google.dev/gemini-api/docs/models) |
|
||||
| `gemini_api_key` | Create at [Google AI Studio](https://aistudio.google.com/app/apikey) |
|
||||
27
docs/en/models/glm.mdx
Normal file
27
docs/en/models/glm.mdx
Normal file
@@ -0,0 +1,27 @@
|
||||
---
|
||||
title: GLM (Zhipu AI)
|
||||
description: Zhipu AI GLM model configuration
|
||||
---
|
||||
|
||||
```json
|
||||
{
|
||||
"model": "glm-5",
|
||||
"zhipu_ai_api_key": "YOUR_API_KEY"
|
||||
}
|
||||
```
|
||||
|
||||
| Parameter | Description |
|
||||
| --- | --- |
|
||||
| `model` | Options include `glm-5`, `glm-4.7`, `glm-4-plus`, `glm-4-flash`, `glm-4-air`, etc. See [model codes](https://bigmodel.cn/dev/api/normal-model/glm-4) |
|
||||
| `zhipu_ai_api_key` | Create at [Zhipu AI Console](https://www.bigmodel.cn/usercenter/proj-mgmt/apikeys) |
|
||||
|
||||
OpenAI-compatible configuration is also supported:
|
||||
|
||||
```json
|
||||
{
|
||||
"bot_type": "chatGPT",
|
||||
"model": "glm-5",
|
||||
"open_ai_api_base": "https://open.bigmodel.cn/api/paas/v4",
|
||||
"open_ai_api_key": "YOUR_API_KEY"
|
||||
}
|
||||
```
|
||||
55
docs/en/models/index.mdx
Normal file
55
docs/en/models/index.mdx
Normal file
@@ -0,0 +1,55 @@
|
||||
---
|
||||
title: Models Overview
|
||||
description: Supported models and recommended choices for CowAgent
|
||||
---
|
||||
|
||||
CowAgent supports mainstream LLMs from domestic and international providers. Model interfaces are implemented in the project's `models/` directory.
|
||||
|
||||
<Note>
|
||||
For Agent mode, the following models are recommended based on quality and cost: MiniMax-M2.5, glm-5, kimi-k2.5, qwen3.5-plus, claude-sonnet-4-6, gemini-3.1-pro-preview
|
||||
</Note>
|
||||
|
||||
## Configuration
|
||||
|
||||
Configure the model name and API key in `config.json` according to your chosen model. Each model also supports OpenAI-compatible access by setting `bot_type` to `chatGPT` and configuring `open_ai_api_base` and `open_ai_api_key`.
|
||||
|
||||
You can also use the [LinkAI](https://link-ai.tech) platform interface to flexibly switch between multiple models with support for knowledge base, workflows, and other Agent capabilities.
|
||||
|
||||
## Supported Models
|
||||
|
||||
<CardGroup cols={2}>
|
||||
<Card title="MiniMax" href="/en/models/minimax">
|
||||
MiniMax-M2.5 and other series models
|
||||
</Card>
|
||||
<Card title="GLM (Zhipu AI)" href="/en/models/glm">
|
||||
glm-5, glm-4.7 and other series models
|
||||
</Card>
|
||||
<Card title="Qwen (Tongyi Qianwen)" href="/en/models/qwen">
|
||||
qwen3.5-plus, qwen3-max and more
|
||||
</Card>
|
||||
<Card title="Kimi" href="/en/models/kimi">
|
||||
kimi-k2.5, kimi-k2 and more
|
||||
</Card>
|
||||
<Card title="Doubao (ByteDance)" href="/en/models/doubao">
|
||||
doubao-seed series models
|
||||
</Card>
|
||||
<Card title="Claude" href="/en/models/claude">
|
||||
claude-sonnet-4-6 and more
|
||||
</Card>
|
||||
<Card title="Gemini" href="/en/models/gemini">
|
||||
gemini-3.1-pro-preview and more
|
||||
</Card>
|
||||
<Card title="OpenAI" href="/en/models/openai">
|
||||
gpt-4.1, o-series and more
|
||||
</Card>
|
||||
<Card title="DeepSeek" href="/en/models/deepseek">
|
||||
deepseek-chat, deepseek-reasoner
|
||||
</Card>
|
||||
<Card title="LinkAI" href="/en/models/linkai">
|
||||
Unified multi-model interface + knowledge base
|
||||
</Card>
|
||||
</CardGroup>
|
||||
|
||||
<Tip>
|
||||
For a full list of model names, refer to the project's [`common/const.py`](https://github.com/zhayujie/chatgpt-on-wechat/blob/master/common/const.py) file.
|
||||
</Tip>
|
||||
27
docs/en/models/kimi.mdx
Normal file
27
docs/en/models/kimi.mdx
Normal file
@@ -0,0 +1,27 @@
|
||||
---
|
||||
title: Kimi (Moonshot)
|
||||
description: Kimi (Moonshot) model configuration
|
||||
---
|
||||
|
||||
```json
|
||||
{
|
||||
"model": "kimi-k2.5",
|
||||
"moonshot_api_key": "YOUR_API_KEY"
|
||||
}
|
||||
```
|
||||
|
||||
| Parameter | Description |
|
||||
| --- | --- |
|
||||
| `model` | Options include `kimi-k2.5`, `kimi-k2`, `moonshot-v1-8k`, `moonshot-v1-32k`, `moonshot-v1-128k` |
|
||||
| `moonshot_api_key` | Create at [Moonshot Console](https://platform.moonshot.cn/console/api-keys) |
|
||||
|
||||
OpenAI-compatible configuration is also supported:
|
||||
|
||||
```json
|
||||
{
|
||||
"bot_type": "chatGPT",
|
||||
"model": "kimi-k2.5",
|
||||
"open_ai_api_base": "https://api.moonshot.cn/v1",
|
||||
"open_ai_api_key": "YOUR_API_KEY"
|
||||
}
|
||||
```
|
||||
23
docs/en/models/linkai.mdx
Normal file
23
docs/en/models/linkai.mdx
Normal file
@@ -0,0 +1,23 @@
|
||||
---
|
||||
title: LinkAI
|
||||
description: Unified access to multiple models via LinkAI platform
|
||||
---
|
||||
|
||||
The [LinkAI](https://link-ai.tech) platform lets you flexibly switch between OpenAI, Claude, Gemini, DeepSeek, Qwen, Kimi, and other models, with support for knowledge base, workflows, plugins, and other Agent capabilities.
|
||||
|
||||
```json
|
||||
{
|
||||
"use_linkai": true,
|
||||
"linkai_api_key": "YOUR_API_KEY",
|
||||
"linkai_app_code": "YOUR_APP_CODE"
|
||||
}
|
||||
```
|
||||
|
||||
| Parameter | Description |
|
||||
| --- | --- |
|
||||
| `use_linkai` | Set to `true` to enable LinkAI interface |
|
||||
| `linkai_api_key` | Create at [LinkAI Console](https://link-ai.tech/console/interface) |
|
||||
| `linkai_app_code` | Optional. Code of the LinkAI agent (app or workflow) |
|
||||
| `model` | Leave empty to use the agent's default model. Can be switched flexibly on the platform. All models in the [model list](https://link-ai.tech/console/models) are supported |
|
||||
|
||||
See the [API documentation](https://docs.link-ai.tech/platform/api) for more details.
|
||||
27
docs/en/models/minimax.mdx
Normal file
27
docs/en/models/minimax.mdx
Normal file
@@ -0,0 +1,27 @@
|
||||
---
|
||||
title: MiniMax
|
||||
description: MiniMax model configuration
|
||||
---
|
||||
|
||||
```json
|
||||
{
|
||||
"model": "MiniMax-M2.5",
|
||||
"minimax_api_key": "YOUR_API_KEY"
|
||||
}
|
||||
```
|
||||
|
||||
| Parameter | Description |
|
||||
| --- | --- |
|
||||
| `model` | Options include `MiniMax-M2.5`, `MiniMax-M2.1`, `MiniMax-M2.1-lightning`, `MiniMax-M2`, etc. |
|
||||
| `minimax_api_key` | Create at [MiniMax Console](https://platform.minimaxi.com/user-center/basic-information/interface-key) |
|
||||
|
||||
OpenAI-compatible configuration is also supported:
|
||||
|
||||
```json
|
||||
{
|
||||
"bot_type": "chatGPT",
|
||||
"model": "MiniMax-M2.5",
|
||||
"open_ai_api_base": "https://api.minimaxi.com/v1",
|
||||
"open_ai_api_key": "YOUR_API_KEY"
|
||||
}
|
||||
```
|
||||
19
docs/en/models/openai.mdx
Normal file
19
docs/en/models/openai.mdx
Normal file
@@ -0,0 +1,19 @@
|
||||
---
|
||||
title: OpenAI
|
||||
description: OpenAI model configuration
|
||||
---
|
||||
|
||||
```json
|
||||
{
|
||||
"model": "gpt-4.1-mini",
|
||||
"open_ai_api_key": "YOUR_API_KEY",
|
||||
"open_ai_api_base": "https://api.openai.com/v1"
|
||||
}
|
||||
```
|
||||
|
||||
| Parameter | Description |
|
||||
| --- | --- |
|
||||
| `model` | Matches the [model parameter](https://platform.openai.com/docs/models) of the OpenAI API. Supports o-series, gpt-5.2, gpt-5.1, gpt-4.1, etc. |
|
||||
| `open_ai_api_key` | Create at [OpenAI Platform](https://platform.openai.com/api-keys) |
|
||||
| `open_ai_api_base` | Optional. Change to use third-party proxy |
|
||||
| `bot_type` | Not required for official OpenAI models. Set to `chatGPT` when using Claude or other non-OpenAI models via proxy |
|
||||
27
docs/en/models/qwen.mdx
Normal file
27
docs/en/models/qwen.mdx
Normal file
@@ -0,0 +1,27 @@
|
||||
---
|
||||
title: Qwen (Tongyi Qianwen)
|
||||
description: Tongyi Qianwen model configuration
|
||||
---
|
||||
|
||||
```json
|
||||
{
|
||||
"model": "qwen3.5-plus",
|
||||
"dashscope_api_key": "YOUR_API_KEY"
|
||||
}
|
||||
```
|
||||
|
||||
| Parameter | Description |
|
||||
| --- | --- |
|
||||
| `model` | Options include `qwen3.5-plus`, `qwen3-max`, `qwen-max`, `qwen-plus`, `qwen-turbo`, `qwq-plus`, etc. |
|
||||
| `dashscope_api_key` | Create at [Bailian Console](https://bailian.console.aliyun.com/?tab=model#/api-key). See [official docs](https://bailian.console.aliyun.com/?tab=api#/api) |
|
||||
|
||||
OpenAI-compatible configuration is also supported:
|
||||
|
||||
```json
|
||||
{
|
||||
"bot_type": "chatGPT",
|
||||
"model": "qwen3.5-plus",
|
||||
"open_ai_api_base": "https://dashscope.aliyuncs.com/compatible-mode/v1",
|
||||
"open_ai_api_key": "YOUR_API_KEY"
|
||||
}
|
||||
```
|
||||
@@ -1,120 +0,0 @@
|
||||
---
|
||||
title: Quick Start
|
||||
description: One-click install or manually deploy CowAgent
|
||||
---
|
||||
|
||||
# Quick Start
|
||||
|
||||
CowAgent supports Linux, macOS, and Windows. It can run on personal computers or servers and requires Python 3.7 ~ 3.12 (3.9 recommended).
|
||||
|
||||
## One-click Install
|
||||
|
||||
The project provides a script for one-click installation, configuration, startup, and management:
|
||||
|
||||
```bash
|
||||
bash <(curl -sS https://cdn.link-ai.tech/code/cow/run.sh)
|
||||
```
|
||||
|
||||
The script automatically:
|
||||
|
||||
1. Checks the Python environment (requires Python 3.7+)
|
||||
2. Installs necessary tools (git, curl, etc.)
|
||||
3. Clones the project to `~/chatgpt-on-wechat`
|
||||
4. Installs Python dependencies
|
||||
5. Guides configuration of AI models and channels
|
||||
6. Starts the service
|
||||
|
||||
### Management Commands
|
||||
|
||||
After installation, use the following commands to manage the service:
|
||||
|
||||
| Command | Description |
|
||||
| --- | --- |
|
||||
| `./run.sh start` | Start service |
|
||||
| `./run.sh stop` | Stop service |
|
||||
| `./run.sh restart` | Restart service |
|
||||
| `./run.sh status` | Check status |
|
||||
| `./run.sh logs` | View live logs |
|
||||
| `./run.sh config` | Reconfigure |
|
||||
| `./run.sh update` | Update project |
|
||||
|
||||
## Manual Installation
|
||||
|
||||
### 1. Clone the Repository
|
||||
|
||||
```bash
|
||||
git clone https://github.com/zhayujie/chatgpt-on-wechat
|
||||
cd chatgpt-on-wechat/
|
||||
```
|
||||
|
||||
<Tip>
|
||||
For users in China, use the mirror: https://gitee.com/zhayujie/chatgpt-on-wechat
|
||||
</Tip>
|
||||
|
||||
### 2. Install Dependencies
|
||||
|
||||
Core dependencies (required):
|
||||
|
||||
```bash
|
||||
pip3 install -r requirements.txt
|
||||
```
|
||||
|
||||
Extended dependencies (optional, recommended):
|
||||
|
||||
```bash
|
||||
pip3 install -r requirements-optional.txt
|
||||
```
|
||||
|
||||
### 3. Configuration
|
||||
|
||||
Copy the config template and edit:
|
||||
|
||||
```bash
|
||||
cp config-template.json config.json
|
||||
```
|
||||
|
||||
See [Configuration](/en/configuration) for detailed settings.
|
||||
|
||||
### 4. Run
|
||||
|
||||
**Local:**
|
||||
|
||||
```bash
|
||||
python3 app.py
|
||||
```
|
||||
|
||||
After starting, visit `http://localhost:9899/chat` to begin chatting.
|
||||
|
||||
**Server (background):**
|
||||
|
||||
```bash
|
||||
nohup python3 app.py & tail -f nohup.out
|
||||
```
|
||||
|
||||
## Docker Deployment
|
||||
|
||||
Docker deployment requires no source code download or dependency installation. Source code deployment is recommended in Agent mode for better system access.
|
||||
|
||||
<Note>
|
||||
Requires [Docker](https://docs.docker.com/engine/install/) and docker-compose.
|
||||
</Note>
|
||||
|
||||
**1. Download config file**
|
||||
|
||||
```bash
|
||||
wget https://cdn.link-ai.tech/code/cow/docker-compose.yml
|
||||
```
|
||||
|
||||
Edit `docker-compose.yml` to fill in required configuration.
|
||||
|
||||
**2. Start container**
|
||||
|
||||
```bash
|
||||
sudo docker compose up -d
|
||||
```
|
||||
|
||||
**3. View logs**
|
||||
|
||||
```bash
|
||||
sudo docker logs -f chatgpt-on-wechat
|
||||
```
|
||||
@@ -3,13 +3,12 @@ title: Changelog
|
||||
description: CowAgent version history
|
||||
---
|
||||
|
||||
# Changelog
|
||||
|
||||
| Version | Date | Description |
|
||||
| --- | --- | --- |
|
||||
| [2.0.1](/en/releases/v2.0.1) | 2026.02.27 | Built-in Web Search tool, smart context management, multiple fixes |
|
||||
| [2.0.0](/en/releases/v2.0.0) | 2026.02.03 | Full upgrade to AI super assistant |
|
||||
| 1.7.6 | 2025.05.23 | Web Channel optimization, AgentMesh plugin |
|
||||
| 1.7.5 | 2025.04.11 | wechatferry protocol, DeepSeek model |
|
||||
| 1.7.5 | 2025.04.11 | DeepSeek model |
|
||||
| 1.7.4 | 2024.12.13 | Gemini 2.0 model, Web Channel |
|
||||
| 1.7.3 | 2024.10.31 | Stability improvements, database features |
|
||||
| 1.7.2 | 2024.09.26 | One-click install script, o1 model |
|
||||
@@ -17,8 +16,6 @@ description: CowAgent version history
|
||||
| 1.6.9 | 2024.07.19 | gpt-4o-mini, Alibaba voice recognition |
|
||||
| 1.6.8 | 2024.07.05 | Claude 3.5, Gemini 1.5 Pro |
|
||||
| 1.6.0 | 2024.04.26 | Kimi integration, gpt-4-turbo upgrade |
|
||||
| 1.5.8 | 2024.03.26 | GLM-4, Claude-3, edge-tts |
|
||||
| 1.5.2 | 2023.11.10 | Feishu channel, image recognition |
|
||||
| 1.5.0 | 2023.11.10 | gpt-4-turbo, dall-e-3, tts multimodal |
|
||||
| 1.0.0 | 2022.12.12 | Project created, first ChatGPT integration |
|
||||
|
||||
|
||||
@@ -3,105 +3,61 @@ title: v2.0.0
|
||||
description: CowAgent 2.0 - Full upgrade from chatbot to AI super assistant
|
||||
---
|
||||
|
||||
# CowAgent 2.0
|
||||
|
||||
CowAgent 2.0 is a comprehensive upgrade from a chatbot to an **AI super assistant**! It can now autonomously think and plan tasks, has long-term memory, operates computers and external resources, and creates and executes skills — truly understanding you and growing alongside you.
|
||||
CowAgent 2.0 is a comprehensive upgrade from a chatbot to an **AI super assistant** — capable of autonomous thinking and task planning, long-term memory, operating computers, and creating and executing skills.
|
||||
|
||||
**Release Date**: 2026.02.03 | [GitHub Release](https://github.com/zhayujie/chatgpt-on-wechat/releases/tag/2.0.0)
|
||||
|
||||
## Key Updates
|
||||
|
||||
### Agent Core Capabilities
|
||||
### Agent Core
|
||||
|
||||
- **Complex Task Planning**: Understands complex tasks and autonomously plans execution, continuously thinking and calling tools until goals are achieved, with multi-turn reasoning and context understanding
|
||||
- **Long-term Memory**: Automatically persists conversation memory to local files and databases, including core memory and daily memory, with keyword and vector search support
|
||||
- **Built-in System Tools**: 10+ built-in tools including file operations, Bash terminal, browser, file sending, scheduled tasks, memory management, etc.
|
||||
- **Skills**: New Skill execution engine with built-in skills and support for custom skill development through natural language conversation
|
||||
- **Security and Cost**: Controls Agent access security through secret key management, prompt controls, and system permissions; limits token costs through max memory turns, max context tokens, and tool execution steps
|
||||
- **Complex Task Planning**: Autonomous planning with multi-turn reasoning
|
||||
- **Long-term Memory**: Persistent memory with keyword and vector search
|
||||
- **Built-in Tools**: 10+ tools including file ops, Bash, browser, scheduler
|
||||
- **Web search**: Built-in `web_search` tool, supports multiple search engines, configure corresponding API key to use
|
||||
- **Skills System**: Skill engine with built-in and custom skill support
|
||||
- **Security & Cost**: Secret management, prompt controls, token limits
|
||||
|
||||
### Other Updates
|
||||
### Other
|
||||
|
||||
- **Channel Improvements**: Feishu and DingTalk channels support WebSocket connections (no public IP needed), with image/file message support
|
||||
- **Model Updates**: Added claude-sonnet-4-5, gemini-3-pro-preview, glm-4.7, MiniMax-M2.1, qwen3-max, and other latest models
|
||||
- **Deployment**: Added one-click install, configure, run, and management script to simplify deployment
|
||||
- **Channels**: Feishu/DingTalk WebSocket support, image/file messages
|
||||
- **Models**: claude-sonnet-4-5, gemini-3-pro-preview, glm-4.7, MiniMax-M2.1, qwen3-max
|
||||
- **Deployment**: One-click install, configure, run, and management script
|
||||
|
||||
## Long-term Memory System
|
||||
|
||||
The Agent proactively stores information when users share important details, and automatically extracts summaries when conversations reach a certain length. Supports hybrid retrieval with semantic search and vector search.
|
||||
|
||||
On **first startup**, the Agent proactively asks for key information and records it in the workspace (default `~/cow`) including agent settings, user identity, and memory files.
|
||||
|
||||
During **long-term conversations**, the Agent intelligently records and retrieves memories, continuously updating its settings, user preferences, and summarizing experiences — achieving true autonomous thinking and continuous growth.
|
||||
## Long-term Memory
|
||||
|
||||
<Frame>
|
||||
<img src="https://cdn.link-ai.tech/doc/20260203000455.png" width="800" />
|
||||
</Frame>
|
||||
|
||||
## Task Planning and Tool Calling
|
||||
|
||||
The Agent intelligently selects and calls tools based on task requirements to complete various complex operations.
|
||||
|
||||
### Terminal and File Access
|
||||
|
||||
The most fundamental tool capabilities. Users can interact with the Agent from mobile devices to operate resources on personal computers or servers:
|
||||
## Task Planning & Tools
|
||||
|
||||
<Frame>
|
||||
<img src="https://cdn.link-ai.tech/doc/20260202181130.png" width="800" />
|
||||
</Frame>
|
||||
|
||||
### Application Programming
|
||||
|
||||
With programming and system access capabilities, the Agent can handle the complete **Vibecoding workflow** — from information search, asset generation, coding, testing, deployment, Nginx configuration, to publishing — all from a single mobile command.
|
||||
|
||||
<Frame>
|
||||
<img src="https://cdn.link-ai.tech/doc/20260203121008.png" width="800" />
|
||||
</Frame>
|
||||
|
||||
### Scheduled Tasks
|
||||
|
||||
Supports **one-time tasks, fixed intervals, and Cron expressions**, with two trigger modes: **fixed message sending** or **Agent dynamic task execution**:
|
||||
|
||||
<Frame>
|
||||
<img src="https://cdn.link-ai.tech/doc/20260202195402.png" width="800" />
|
||||
</Frame>
|
||||
|
||||
### Environment Variable Management
|
||||
|
||||
Manages skill-required secrets via the `env_config` tool, with conversational updates and built-in security protection and data masking:
|
||||
|
||||
<Frame>
|
||||
<img src="https://cdn.link-ai.tech/doc/20260202234939.png" width="800" />
|
||||
</Frame>
|
||||
|
||||
## Skills System
|
||||
|
||||
Each Skill consists of a description file, execution script (optional), and resources (optional), providing infinite extensibility.
|
||||
|
||||
### Skill Creator
|
||||
|
||||
Quickly create skills through conversation, codifying workflows or integrating with any third-party API:
|
||||
|
||||
<Frame>
|
||||
<img src="https://cdn.link-ai.tech/doc/20260202202247.png" width="800" />
|
||||
</Frame>
|
||||
|
||||
### Search and Image Recognition
|
||||
|
||||
- **Search Skill**: Built-in `bocha-search`, configure `BOCHA_SEARCH_API_KEY` to enable
|
||||
- **Image Recognition**: Supports `gpt-4.1-mini`, `gpt-4.1`, etc., configure `OPENAI_API_KEY` to enable
|
||||
|
||||
<Frame>
|
||||
<img src="https://cdn.link-ai.tech/doc/20260202213219.png" width="800" />
|
||||
</Frame>
|
||||
|
||||
### Third-party Knowledge Bases and Plugins
|
||||
|
||||
The `linkai-agent` skill integrates all agents from [LinkAI](https://link-ai.tech/) as Skills, enabling multi-agent decision-making:
|
||||
|
||||
<Frame>
|
||||
<img src="https://cdn.link-ai.tech/doc/20260202234350.png" width="750" />
|
||||
</Frame>
|
||||
|
||||
## Contributing
|
||||
|
||||
After version 2.0, the project will continue upgrading Agent capabilities, expanding channels, built-in tools, and the skills system, while reducing model costs and improving security. Welcome to [submit feedback](https://github.com/zhayujie/chatgpt-on-wechat/issues) and [contribute code](https://github.com/zhayujie/chatgpt-on-wechat/pulls).
|
||||
Welcome to [submit feedback](https://github.com/zhayujie/chatgpt-on-wechat/issues) and [contribute code](https://github.com/zhayujie/chatgpt-on-wechat/pulls).
|
||||
|
||||
36
docs/en/releases/v2.0.1.mdx
Normal file
36
docs/en/releases/v2.0.1.mdx
Normal file
@@ -0,0 +1,36 @@
|
||||
---
|
||||
title: v2.0.1
|
||||
description: CowAgent 2.0.1 - Built-in Web Search, smart context management, multiple fixes
|
||||
---
|
||||
|
||||
**Release Date**: 2026.02.27 | [Full Changelog](https://github.com/zhayujie/chatgpt-on-wechat/compare/2.0.0..2.0.1)
|
||||
|
||||
## New Features
|
||||
|
||||
- **Built-in Web Search tool**: Integrated web search as a built-in Agent tool, reducing decision cost ([4f0ea5d](https://github.com/zhayujie/chatgpt-on-wechat/commit/4f0ea5d7568d61db91ff69c91c429e785fd1b1c2))
|
||||
- **Claude Opus 4.6 model support**: Added support for Claude Opus 4.6 model ([#2661](https://github.com/zhayujie/chatgpt-on-wechat/pull/2661))
|
||||
- **WeCom image recognition**: Support image message recognition in WeCom channel ([#2667](https://github.com/zhayujie/chatgpt-on-wechat/pull/2667))
|
||||
|
||||
## Improvements
|
||||
|
||||
- **Smart context management**: Resolved chat context overflow with intelligent context trimming strategy to prevent token limits ([cea7fb7](https://github.com/zhayujie/chatgpt-on-wechat/commit/cea7fb7490c53454602bf05955a0e9f059bcf0fd), [8acf2db](https://github.com/zhayujie/chatgpt-on-wechat/commit/8acf2dbdfe713b84ad74b761b7f86674b1c1904d)) [#2663](https://github.com/zhayujie/chatgpt-on-wechat/issues/2663)
|
||||
- **Runtime info dynamic update**: Automatic update of timestamps and other runtime info in system prompts via dynamic functions ([#2655](https://github.com/zhayujie/chatgpt-on-wechat/pull/2655), [#2657](https://github.com/zhayujie/chatgpt-on-wechat/pull/2657))
|
||||
- **Skill prompt optimization**: Improved Skill system prompt generation, simplified tool descriptions for better Agent performance ([6c21833](https://github.com/zhayujie/chatgpt-on-wechat/commit/6c218331b1f1208ea8be6bf226936d3b556ade3e))
|
||||
- **GLM custom API Base URL**: Support custom API Base URL for GLM models ([#2660](https://github.com/zhayujie/chatgpt-on-wechat/pull/2660))
|
||||
- **Startup script optimization**: Improved `run.sh` script interaction and configuration flow ([#2656](https://github.com/zhayujie/chatgpt-on-wechat/pull/2656))
|
||||
- **Decision step logging**: Added Agent decision step logging for debugging ([cb303e6](https://github.com/zhayujie/chatgpt-on-wechat/commit/cb303e6109c50c8dfef1f5e6c1ec47223bf3cd11))
|
||||
|
||||
## Bug Fixes
|
||||
|
||||
- **Scheduler memory loss**: Fixed memory loss caused by Scheduler dispatcher ([a77a874](https://github.com/zhayujie/chatgpt-on-wechat/commit/a77a8741b500a408c6f5c8868856fb4b018fe9db))
|
||||
- **Empty tool calls & long results**: Fixed handling of empty tool calls and excessively long tool results ([0542700](https://github.com/zhayujie/chatgpt-on-wechat/commit/0542700f9091ebb08c1a56103b0f0f45f24aa621))
|
||||
- **OpenAI Function Call**: Fixed function call compatibility with OpenAI models ([158c87a](https://github.com/zhayujie/chatgpt-on-wechat/commit/158c87ab8b05bae054cc1b4eacdbb64fc1062ba9))
|
||||
- **Claude tool name field**: Removed extraneous tool name field from Claude model responses ([eec10cb](https://github.com/zhayujie/chatgpt-on-wechat/commit/eec10cb5db6a3d5bc12ef606606532237d2c5f6e))
|
||||
- **MiniMax reasoning**: Optimized MiniMax model reasoning content handling, hidden thinking process output ([c72cda3](https://github.com/zhayujie/chatgpt-on-wechat/commit/c72cda33864bd1542012ee6e0a8bd8c6c88cb5ed), [72b1cac](https://github.com/zhayujie/chatgpt-on-wechat/commit/72b1cacea1ba0d1f3dedacbab2e088e98fd7e172))
|
||||
- **GLM thinking process**: Hidden GLM model thinking process display ([72b1cac](https://github.com/zhayujie/chatgpt-on-wechat/commit/72b1cacea1ba0d1f3dedacbab2e088e98fd7e172))
|
||||
- **Feishu connection & SSL**: Fixed Feishu channel SSL certificate errors and connection issues ([229b14b](https://github.com/zhayujie/chatgpt-on-wechat/commit/229b14b6fcabe7123d53cab1dea39f38dab26d6d), [8674421](https://github.com/zhayujie/chatgpt-on-wechat/commit/867442155e7f095b4f38b0856f8c1d8312b5fcf7))
|
||||
- **model_type validation**: Fixed `AttributeError` caused by non-string `model_type` ([#2666](https://github.com/zhayujie/chatgpt-on-wechat/pull/2666))
|
||||
|
||||
## Platform Compatibility
|
||||
|
||||
- **Windows compatibility**: Fixed path handling, file encoding, and `os.getuid()` unavailability on Windows across multiple tool modules ([051ffd7](https://github.com/zhayujie/chatgpt-on-wechat/commit/051ffd78a372f71a967fd3259e37fe19131f83cf), [5264f7c](https://github.com/zhayujie/chatgpt-on-wechat/commit/5264f7ce18360ee4db5dcb4ebe67307977d40014))
|
||||
@@ -1,103 +0,0 @@
|
||||
---
|
||||
title: Skills
|
||||
description: CowAgent Skills System - infinite extensibility for the Agent
|
||||
---
|
||||
|
||||
# Skills System
|
||||
|
||||
The Skills system provides infinite extensibility for the Agent. Each Skill consists of a description file, an execution script (optional), and resources (optional), describing how to complete a specific type of task. Skills enable the Agent to follow instructions to complete complex workflows, call various tools, or integrate with third-party systems.
|
||||
|
||||
## Skill Types
|
||||
|
||||
### Built-in Skills
|
||||
|
||||
Located in the `skills/` directory of the project, automatically enabled based on dependency conditions (API keys, system commands, etc.).
|
||||
|
||||
| Skill | Description |
|
||||
| --- | --- |
|
||||
| `skill-creator` | Skill creator — create custom skills through conversation |
|
||||
| `bocha-search` | Web search capability |
|
||||
| `openai-image-vision` | Image recognition using OpenAI vision models |
|
||||
| `linkai-agent` | LinkAI agent integration for third-party knowledge bases and plugins |
|
||||
| `web-scraper` | Web page content extraction |
|
||||
|
||||
### Custom Skills
|
||||
|
||||
Created by users through conversation, stored in the workspace (`~/cow/skills/`). Custom skills can implement any complex business workflow or third-party system integration.
|
||||
|
||||
## Creating Skills
|
||||
|
||||
Use the built-in `skill-creator` to create skills through natural language conversation:
|
||||
|
||||
- Codify workflows into reusable skills
|
||||
- Send API documentation and examples to the Agent for automatic integration
|
||||
- Create customized automation pipelines
|
||||
|
||||
<Frame>
|
||||
<img src="https://cdn.link-ai.tech/doc/20260202202247.png" width="800" />
|
||||
</Frame>
|
||||
|
||||
## Web Search
|
||||
|
||||
The built-in `bocha-search` skill provides web search capability:
|
||||
|
||||
1. Create an API Key at [Bocha Open Platform](https://open.bochaai.com/)
|
||||
2. Configure `BOCHA_SEARCH_API_KEY` via the `env_config` tool or send it directly to the Agent
|
||||
|
||||
## Image Recognition
|
||||
|
||||
The `openai-image-vision` skill supports image recognition using models like `gpt-4.1-mini` and `gpt-4.1`.
|
||||
|
||||
Configure `OPENAI_API_KEY` via `config.json` or the `env_config` tool to enable.
|
||||
|
||||
<Frame>
|
||||
<img src="https://cdn.link-ai.tech/doc/20260202213219.png" width="800" />
|
||||
</Frame>
|
||||
|
||||
## LinkAI Agents
|
||||
|
||||
The `linkai-agent` skill integrates all agents from [LinkAI](https://link-ai.tech/) as Skills, enabling multi-agent decision-making.
|
||||
|
||||
### Configuration
|
||||
|
||||
1. Configure `LINKAI_API_KEY` (via `env_config` tool or `linkai_api_key` in `config.json`)
|
||||
2. Add agent descriptions in `skills/linkai-agent/config.json`:
|
||||
|
||||
```json
|
||||
{
|
||||
"apps": [
|
||||
{
|
||||
"app_code": "G7z6vKwp",
|
||||
"app_name": "LinkAI Support",
|
||||
"app_description": "Use this agent only for LinkAI platform questions"
|
||||
},
|
||||
{
|
||||
"app_code": "SFY5x7JR",
|
||||
"app_name": "Content Creator",
|
||||
"app_description": "Use this agent for image or video creation"
|
||||
}
|
||||
]
|
||||
}
|
||||
```
|
||||
|
||||
The Agent selects the appropriate agent based on name and description, and calls the corresponding app via `app_code`.
|
||||
|
||||
<Frame>
|
||||
<img src="https://cdn.link-ai.tech/doc/20260202234350.png" width="750" />
|
||||
</Frame>
|
||||
|
||||
## Skill File Structure
|
||||
|
||||
Each skill directory follows this structure:
|
||||
|
||||
```
|
||||
skills/
|
||||
├── my-skill/
|
||||
│ ├── SKILL.md # Skill description and instructions
|
||||
│ ├── run.py # Execution script (optional)
|
||||
│ └── resources/ # Additional resources (optional)
|
||||
```
|
||||
|
||||
<Tip>
|
||||
For custom skill development, see the [Skill Creator Guide](https://github.com/zhayujie/chatgpt-on-wechat/blob/master/skills/skill-creator/SKILL.md).
|
||||
</Tip>
|
||||
33
docs/en/skills/image-vision.mdx
Normal file
33
docs/en/skills/image-vision.mdx
Normal file
@@ -0,0 +1,33 @@
|
||||
---
|
||||
title: Image Vision
|
||||
description: Recognize images using OpenAI vision models
|
||||
---
|
||||
|
||||
# openai-image-vision
|
||||
|
||||
Analyze image content using OpenAI's GPT-4 Vision API, understanding objects, text, colors, and other elements in images.
|
||||
|
||||
## Dependencies
|
||||
|
||||
| Dependency | Description |
|
||||
| --- | --- |
|
||||
| `OPENAI_API_KEY` | OpenAI API key |
|
||||
| `curl`, `base64` | System commands (usually pre-installed) |
|
||||
|
||||
Configuration:
|
||||
|
||||
- Configure `OPENAI_API_KEY` via the `env_config` tool
|
||||
- Or set `open_ai_api_key` in `config.json`
|
||||
|
||||
## Supported Models
|
||||
|
||||
- `gpt-4.1-mini` (recommended, cost-effective)
|
||||
- `gpt-4.1`
|
||||
|
||||
## Usage
|
||||
|
||||
Once configured, send an image to the Agent to automatically trigger image recognition.
|
||||
|
||||
<Frame>
|
||||
<img src="https://cdn.link-ai.tech/doc/20260202213219.png" width="800" />
|
||||
</Frame>
|
||||
67
docs/en/skills/index.mdx
Normal file
67
docs/en/skills/index.mdx
Normal file
@@ -0,0 +1,67 @@
|
||||
---
|
||||
title: Skills Overview
|
||||
description: CowAgent skills system introduction
|
||||
---
|
||||
|
||||
Skills provide infinite extensibility for the Agent. Each Skill consists of a description file (`SKILL.md`), execution scripts (optional), and resources (optional), describing how to accomplish specific types of tasks.
|
||||
|
||||
The difference between Skills and Tools: Tools are atomic operations implemented in code (e.g., file read/write, command execution), while Skills are high-level workflows based on description files that can combine multiple Tools to complete complex tasks.
|
||||
|
||||
## Built-in Skills
|
||||
|
||||
Located in the project `skills/` directory, automatically enabled based on dependency conditions:
|
||||
|
||||
| Skill | Description | Dependencies |
|
||||
| --- | --- | --- |
|
||||
| [`skill-creator`](/en/skills/skill-creator) | Create custom skills through conversation | None |
|
||||
| [`openai-image-vision`](/en/skills/image-vision) | Recognize images using OpenAI vision models | `OPENAI_API_KEY` |
|
||||
| [`linkai-agent`](/en/skills/linkai-agent) | Integrate LinkAI platform agents | `LINKAI_API_KEY` |
|
||||
| [`web-fetch`](/en/skills/web-fetch) | Fetch web page text content | `curl` (enabled by default) |
|
||||
|
||||
## Custom Skills
|
||||
|
||||
Created by users through conversation, stored in workspace (`~/cow/skills/`), can implement any complex business process and third-party system integration.
|
||||
|
||||
## Skill Loading Priority
|
||||
|
||||
1. **Workspace skills** (highest): `~/cow/skills/`
|
||||
2. **Project built-in skills** (lowest): `skills/`
|
||||
|
||||
Skills with the same name are overridden by priority.
|
||||
|
||||
## Skill File Structure
|
||||
|
||||
```
|
||||
skills/
|
||||
├── my-skill/
|
||||
│ ├── SKILL.md # Skill description (frontmatter + instructions)
|
||||
│ ├── scripts/ # Execution scripts (optional)
|
||||
│ └── resources/ # Additional resources (optional)
|
||||
```
|
||||
|
||||
### SKILL.md Format
|
||||
|
||||
```markdown
|
||||
---
|
||||
name: my-skill
|
||||
description: Brief description of the skill
|
||||
metadata:
|
||||
emoji: 🔧
|
||||
requires:
|
||||
bins: ["curl"]
|
||||
env: ["MY_API_KEY"]
|
||||
primaryEnv: "MY_API_KEY"
|
||||
---
|
||||
|
||||
# My Skill
|
||||
|
||||
Detailed instructions...
|
||||
```
|
||||
|
||||
| Field | Description |
|
||||
| --- | --- |
|
||||
| `name` | Skill name, must match directory name |
|
||||
| `description` | Skill description, Agent decides whether to invoke based on this |
|
||||
| `metadata.requires.bins` | Required system commands |
|
||||
| `metadata.requires.env` | Required environment variables |
|
||||
| `metadata.always` | Always load (default false) |
|
||||
49
docs/en/skills/linkai-agent.mdx
Normal file
49
docs/en/skills/linkai-agent.mdx
Normal file
@@ -0,0 +1,49 @@
|
||||
---
|
||||
title: LinkAI Agent
|
||||
description: Integrate LinkAI platform multi-agent skill
|
||||
---
|
||||
|
||||
# linkai-agent
|
||||
|
||||
Use agents from the [LinkAI](https://link-ai.tech/) platform as Skills for multi-agent decision-making. The Agent intelligently selects based on agent names and descriptions, calling the corresponding application or workflow via `app_code`.
|
||||
|
||||
## Dependencies
|
||||
|
||||
| Dependency | Description |
|
||||
| --- | --- |
|
||||
| `LINKAI_API_KEY` | LinkAI platform API key, created in [Console](https://link-ai.tech/console/interface) |
|
||||
| `curl` | System command (usually pre-installed) |
|
||||
|
||||
Configuration:
|
||||
|
||||
- Configure `LINKAI_API_KEY` via the `env_config` tool
|
||||
- Or set `linkai_api_key` in `config.json`
|
||||
|
||||
## Configure Agents
|
||||
|
||||
Add available agents in `skills/linkai-agent/config.json`:
|
||||
|
||||
```json
|
||||
{
|
||||
"apps": [
|
||||
{
|
||||
"app_code": "G7z6vKwp",
|
||||
"app_name": "LinkAI Customer Support",
|
||||
"app_description": "Select this assistant only when the user needs help with LinkAI platform questions"
|
||||
},
|
||||
{
|
||||
"app_code": "SFY5x7JR",
|
||||
"app_name": "Content Creator",
|
||||
"app_description": "Use this assistant only when the user needs to create images or videos"
|
||||
}
|
||||
]
|
||||
}
|
||||
```
|
||||
|
||||
## Usage
|
||||
|
||||
Once configured, the Agent will automatically select the appropriate LinkAI agent based on the user's question.
|
||||
|
||||
<Frame>
|
||||
<img src="https://cdn.link-ai.tech/doc/20260202234350.png" width="750" />
|
||||
</Frame>
|
||||
33
docs/en/skills/skill-creator.mdx
Normal file
33
docs/en/skills/skill-creator.mdx
Normal file
@@ -0,0 +1,33 @@
|
||||
---
|
||||
title: Skill Creator
|
||||
description: Create custom skills through conversation
|
||||
---
|
||||
|
||||
# skill-creator
|
||||
|
||||
Quickly create, install, or update skills through natural language conversation.
|
||||
|
||||
## Dependencies
|
||||
|
||||
No extra dependencies, always available.
|
||||
|
||||
## Usage
|
||||
|
||||
- Codify workflows as skills: "Create a skill from this deployment process"
|
||||
- Integrate third-party APIs: "Create a skill based on this API documentation"
|
||||
- Install remote skills: "Install xxx skill for me"
|
||||
|
||||
## Creation Flow
|
||||
|
||||
1. Tell the Agent what skill you want to create
|
||||
2. Agent automatically generates `SKILL.md` description and execution scripts
|
||||
3. Skill is saved to the workspace `~/cow/skills/` directory
|
||||
4. Agent will automatically recognize and use the skill in future conversations
|
||||
|
||||
<Frame>
|
||||
<img src="https://cdn.link-ai.tech/doc/20260202202247.png" width="800" />
|
||||
</Frame>
|
||||
|
||||
<Tip>
|
||||
See the [Skill Creator documentation](https://github.com/zhayujie/chatgpt-on-wechat/blob/master/skills/skill-creator/SKILL.md) for details.
|
||||
</Tip>
|
||||
33
docs/en/skills/web-fetch.mdx
Normal file
33
docs/en/skills/web-fetch.mdx
Normal file
@@ -0,0 +1,33 @@
|
||||
---
|
||||
title: Web Fetch
|
||||
description: Fetch web page text content
|
||||
---
|
||||
|
||||
# web-fetch
|
||||
|
||||
Use curl to fetch web pages and extract readable text content. A lightweight web access method without browser automation.
|
||||
|
||||
## Dependencies
|
||||
|
||||
| Dependency | Description |
|
||||
| --- | --- |
|
||||
| `curl` | System command (usually pre-installed) |
|
||||
|
||||
This skill has `always: true` set, enabled by default as long as the system has the `curl` command.
|
||||
|
||||
## Usage
|
||||
|
||||
Automatically invoked when the Agent needs to fetch content from a URL, no extra configuration needed.
|
||||
|
||||
## Comparison with browser Tool
|
||||
|
||||
| Feature | web-fetch (skill) | browser (tool) |
|
||||
| --- | --- | --- |
|
||||
| Dependencies | curl only | browser-use + playwright |
|
||||
| JS rendering | Not supported | Supported |
|
||||
| Page interaction | Not supported | Supports click, type, etc. |
|
||||
| Best for | Static page text | Dynamic web pages |
|
||||
|
||||
<Tip>
|
||||
For most web content retrieval scenarios, web-fetch is sufficient. Only use the browser tool when you need JS rendering or page interaction.
|
||||
</Tip>
|
||||
30
docs/en/tools/bash.mdx
Normal file
30
docs/en/tools/bash.mdx
Normal file
@@ -0,0 +1,30 @@
|
||||
---
|
||||
title: bash - Terminal
|
||||
description: Execute system commands
|
||||
---
|
||||
|
||||
# bash
|
||||
|
||||
Execute Bash commands in the current working directory, returns stdout and stderr. API keys configured via `env_config` are automatically injected into the environment.
|
||||
|
||||
## Dependencies
|
||||
|
||||
No extra dependencies, available by default.
|
||||
|
||||
## Parameters
|
||||
|
||||
| Parameter | Type | Required | Description |
|
||||
| --- | --- | --- | --- |
|
||||
| `command` | string | Yes | Command to execute |
|
||||
| `timeout` | integer | No | Timeout in seconds |
|
||||
|
||||
## Use Cases
|
||||
|
||||
- Install packages and dependencies
|
||||
- Run code and tests
|
||||
- Deploy applications and services (Nginx config, process management, etc.)
|
||||
- System administration and troubleshooting
|
||||
|
||||
<Frame>
|
||||
<img src="https://cdn.link-ai.tech/doc/20260203121008.png" width="800" />
|
||||
</Frame>
|
||||
27
docs/en/tools/browser.mdx
Normal file
27
docs/en/tools/browser.mdx
Normal file
@@ -0,0 +1,27 @@
|
||||
---
|
||||
title: browser - Browser
|
||||
description: Access and interact with web pages
|
||||
---
|
||||
|
||||
# browser
|
||||
|
||||
Use a browser to access and interact with web pages, supports JavaScript-rendered dynamic pages.
|
||||
|
||||
## Dependencies
|
||||
|
||||
| Dependency | Install Command |
|
||||
| --- | --- |
|
||||
| `browser-use` ≥ 0.1.40 | `pip install browser-use` |
|
||||
| `markdownify` | `pip install markdownify` |
|
||||
| `playwright` + chromium | `pip install playwright && playwright install chromium` |
|
||||
|
||||
## Use Cases
|
||||
|
||||
- Access specific URLs to get page content
|
||||
- Interact with web page elements (click, type, etc.)
|
||||
- Verify deployed web pages
|
||||
- Scrape dynamic content requiring JS rendering
|
||||
|
||||
<Note>
|
||||
The browser tool has heavy dependencies. If not needed, skip installation. For lightweight web content retrieval, use the `web-fetch` skill instead.
|
||||
</Note>
|
||||
26
docs/en/tools/edit.mdx
Normal file
26
docs/en/tools/edit.mdx
Normal file
@@ -0,0 +1,26 @@
|
||||
---
|
||||
title: edit - File Edit
|
||||
description: Edit files via precise text replacement
|
||||
---
|
||||
|
||||
# edit
|
||||
|
||||
Edit files via precise text replacement. If `oldText` is empty, appends to the end of the file.
|
||||
|
||||
## Dependencies
|
||||
|
||||
No extra dependencies, available by default.
|
||||
|
||||
## Parameters
|
||||
|
||||
| Parameter | Type | Required | Description |
|
||||
| --- | --- | --- | --- |
|
||||
| `path` | string | Yes | File path |
|
||||
| `oldText` | string | Yes | Original text to replace (empty to append) |
|
||||
| `newText` | string | Yes | Replacement text |
|
||||
|
||||
## Use Cases
|
||||
|
||||
- Modify specific parameters in configuration files
|
||||
- Fix bugs in code
|
||||
- Insert content at specific positions in files
|
||||
38
docs/en/tools/env-config.mdx
Normal file
38
docs/en/tools/env-config.mdx
Normal file
@@ -0,0 +1,38 @@
|
||||
---
|
||||
title: env_config - Environment
|
||||
description: Manage API keys and secrets
|
||||
---
|
||||
|
||||
# env_config
|
||||
|
||||
Manage environment variables (API keys and secrets) in the workspace `.env` file, with secure conversational updates. Built-in security protection and desensitization.
|
||||
|
||||
## Dependencies
|
||||
|
||||
| Dependency | Install Command |
|
||||
| --- | --- |
|
||||
| `python-dotenv` ≥ 1.0.0 | `pip install python-dotenv>=1.0.0` |
|
||||
|
||||
Included when installing optional dependencies: `pip3 install -r requirements-optional.txt`
|
||||
|
||||
## Parameters
|
||||
|
||||
| Parameter | Type | Required | Description |
|
||||
| --- | --- | --- | --- |
|
||||
| `action` | string | Yes | Operation type: `get`, `set`, `list`, `delete` |
|
||||
| `key` | string | No | Environment variable name |
|
||||
| `value` | string | No | Environment variable value (only for `set`) |
|
||||
|
||||
## Usage
|
||||
|
||||
Tell the Agent what key you need to configure, and it will automatically invoke this tool:
|
||||
|
||||
- "Configure my BOCHA_API_KEY"
|
||||
- "Set OPENAI_API_KEY to sk-xxx"
|
||||
- "Show configured environment variables"
|
||||
|
||||
Configured keys are automatically injected into the `bash` tool's execution environment.
|
||||
|
||||
<Frame>
|
||||
<img src="https://cdn.link-ai.tech/doc/20260202234939.png" width="800" />
|
||||
</Frame>
|
||||
50
docs/en/tools/index.mdx
Normal file
50
docs/en/tools/index.mdx
Normal file
@@ -0,0 +1,50 @@
|
||||
---
|
||||
title: Tools Overview
|
||||
description: CowAgent built-in tools system
|
||||
---
|
||||
|
||||
Tools are the core capability for Agent to access operating system resources. The Agent intelligently selects and invokes tools based on task requirements, performing file operations, command execution, web search, scheduled tasks, and more. Tools are implemented in the `agent/tools/` directory.
|
||||
|
||||
## Built-in Tools
|
||||
|
||||
The following tools are available by default with no extra configuration:
|
||||
|
||||
<CardGroup cols={2}>
|
||||
<Card title="read - File Read" icon="file" href="/en/tools/read">
|
||||
Read file content, supports text, images, PDF
|
||||
</Card>
|
||||
<Card title="write - File Write" icon="pen" href="/en/tools/write">
|
||||
Create or overwrite files
|
||||
</Card>
|
||||
<Card title="edit - File Edit" icon="pen-to-square" href="/en/tools/edit">
|
||||
Edit files via precise text replacement
|
||||
</Card>
|
||||
<Card title="ls - Directory List" icon="folder-open" href="/en/tools/ls">
|
||||
List directory contents
|
||||
</Card>
|
||||
<Card title="bash - Terminal" icon="terminal" href="/en/tools/bash">
|
||||
Execute system commands
|
||||
</Card>
|
||||
<Card title="send - File Send" icon="paper-plane" href="/en/tools/send">
|
||||
Send files or images to user
|
||||
</Card>
|
||||
<Card title="memory - Memory" icon="brain" href="/en/tools/memory">
|
||||
Search and read long-term memory
|
||||
</Card>
|
||||
</CardGroup>
|
||||
|
||||
## Optional Tools
|
||||
|
||||
The following tools require additional dependencies or API key configuration:
|
||||
|
||||
<CardGroup cols={2}>
|
||||
<Card title="env_config - Environment" icon="key" href="/en/tools/env-config">
|
||||
Manage API keys and secrets
|
||||
</Card>
|
||||
<Card title="scheduler - Scheduler" icon="clock" href="/en/tools/scheduler">
|
||||
Create and manage scheduled tasks
|
||||
</Card>
|
||||
<Card title="web_search - Web Search" icon="magnifying-glass" href="/en/tools/web-search">
|
||||
Search the internet for real-time information
|
||||
</Card>
|
||||
</CardGroup>
|
||||
25
docs/en/tools/ls.mdx
Normal file
25
docs/en/tools/ls.mdx
Normal file
@@ -0,0 +1,25 @@
|
||||
---
|
||||
title: ls - Directory List
|
||||
description: List directory contents
|
||||
---
|
||||
|
||||
# ls
|
||||
|
||||
List directory contents, sorted alphabetically, directories suffixed with `/`, includes hidden files.
|
||||
|
||||
## Dependencies
|
||||
|
||||
No extra dependencies, available by default.
|
||||
|
||||
## Parameters
|
||||
|
||||
| Parameter | Type | Required | Description |
|
||||
| --- | --- | --- | --- |
|
||||
| `path` | string | Yes | Directory path, relative paths are based on workspace directory |
|
||||
| `limit` | integer | No | Maximum entries to return, default 500 |
|
||||
|
||||
## Use Cases
|
||||
|
||||
- Browse project structure
|
||||
- Find specific files
|
||||
- Check if a directory exists
|
||||
38
docs/en/tools/memory.mdx
Normal file
38
docs/en/tools/memory.mdx
Normal file
@@ -0,0 +1,38 @@
|
||||
---
|
||||
title: memory - Memory
|
||||
description: Search and read long-term memory
|
||||
---
|
||||
|
||||
# memory
|
||||
|
||||
The memory tool contains two sub-tools: `memory_search` (search memory) and `memory_get` (read memory files).
|
||||
|
||||
## Dependencies
|
||||
|
||||
No extra dependencies, available by default. Managed by the Agent Core memory system.
|
||||
|
||||
## memory_search
|
||||
|
||||
Search historical memory with hybrid keyword and vector retrieval.
|
||||
|
||||
| Parameter | Type | Required | Description |
|
||||
| --- | --- | --- | --- |
|
||||
| `query` | string | Yes | Search query |
|
||||
|
||||
## memory_get
|
||||
|
||||
Read the content of a specific memory file.
|
||||
|
||||
| Parameter | Type | Required | Description |
|
||||
| --- | --- | --- | --- |
|
||||
| `path` | string | Yes | Relative path to memory file (e.g. `MEMORY.md`, `memory/2026-01-01.md`) |
|
||||
| `start_line` | integer | No | Start line number |
|
||||
| `end_line` | integer | No | End line number |
|
||||
|
||||
## How It Works
|
||||
|
||||
The Agent automatically invokes memory tools in these scenarios:
|
||||
|
||||
- When the user shares important information → stores to memory
|
||||
- When historical context is needed → searches relevant memory
|
||||
- When conversation reaches a certain length → extracts summary for storage
|
||||
26
docs/en/tools/read.mdx
Normal file
26
docs/en/tools/read.mdx
Normal file
@@ -0,0 +1,26 @@
|
||||
---
|
||||
title: read - File Read
|
||||
description: Read file content
|
||||
---
|
||||
|
||||
# read
|
||||
|
||||
Read file content. Supports text files, PDF files, images (returns metadata), and more.
|
||||
|
||||
## Dependencies
|
||||
|
||||
No extra dependencies, available by default.
|
||||
|
||||
## Parameters
|
||||
|
||||
| Parameter | Type | Required | Description |
|
||||
| --- | --- | --- | --- |
|
||||
| `path` | string | Yes | File path, relative paths are based on workspace directory |
|
||||
| `offset` | integer | No | Start line number (1-indexed), negative values read from the end |
|
||||
| `limit` | integer | No | Number of lines to read |
|
||||
|
||||
## Use Cases
|
||||
|
||||
- View configuration files, log files
|
||||
- Read code files for analysis
|
||||
- Check image/video file info
|
||||
42
docs/en/tools/scheduler.mdx
Normal file
42
docs/en/tools/scheduler.mdx
Normal file
@@ -0,0 +1,42 @@
|
||||
---
|
||||
title: scheduler - Scheduler
|
||||
description: Create and manage scheduled tasks
|
||||
---
|
||||
|
||||
# scheduler
|
||||
|
||||
Create and manage dynamic scheduled tasks with flexible scheduling and execution modes.
|
||||
|
||||
## Dependencies
|
||||
|
||||
| Dependency | Install Command |
|
||||
| --- | --- |
|
||||
| `croniter` ≥ 2.0.0 | `pip install croniter>=2.0.0` |
|
||||
|
||||
Included in core dependencies: `pip3 install -r requirements.txt`
|
||||
|
||||
## Scheduling Modes
|
||||
|
||||
| Mode | Description |
|
||||
| --- | --- |
|
||||
| One-time | Execute once at a specified time |
|
||||
| Fixed interval | Repeat at fixed time intervals |
|
||||
| Cron expression | Define complex schedules using Cron syntax |
|
||||
|
||||
## Execution Modes
|
||||
|
||||
- **Fixed message**: Send a preset message when triggered
|
||||
- **Agent dynamic task**: Agent intelligently executes the task when triggered
|
||||
|
||||
## Usage
|
||||
|
||||
Create and manage scheduled tasks with natural language:
|
||||
|
||||
- "Send me a weather report every morning at 9 AM"
|
||||
- "Check server status every 2 hours"
|
||||
- "Remind me about the meeting tomorrow at 3 PM"
|
||||
- "Show all scheduled tasks"
|
||||
|
||||
<Frame>
|
||||
<img src="https://cdn.link-ai.tech/doc/20260202195402.png" width="800" />
|
||||
</Frame>
|
||||
25
docs/en/tools/send.mdx
Normal file
25
docs/en/tools/send.mdx
Normal file
@@ -0,0 +1,25 @@
|
||||
---
|
||||
title: send - File Send
|
||||
description: Send files to user
|
||||
---
|
||||
|
||||
# send
|
||||
|
||||
Send files to the user (images, videos, audio, documents, etc.), used when the user explicitly requests to send/share a file.
|
||||
|
||||
## Dependencies
|
||||
|
||||
No extra dependencies, available by default.
|
||||
|
||||
## Parameters
|
||||
|
||||
| Parameter | Type | Required | Description |
|
||||
| --- | --- | --- | --- |
|
||||
| `path` | string | Yes | File path, can be absolute or relative to workspace |
|
||||
| `message` | string | No | Accompanying message |
|
||||
|
||||
## Use Cases
|
||||
|
||||
- Send generated code or documents to the user
|
||||
- Send screenshots, charts
|
||||
- Share downloaded files
|
||||
34
docs/en/tools/web-search.mdx
Normal file
34
docs/en/tools/web-search.mdx
Normal file
@@ -0,0 +1,34 @@
|
||||
---
|
||||
title: web_search - Web Search
|
||||
description: Search the internet for real-time information
|
||||
---
|
||||
|
||||
# web_search
|
||||
|
||||
Search the internet for real-time information, news, research, and more. Supports two search backends with automatic fallback.
|
||||
|
||||
## Dependencies
|
||||
|
||||
Requires at least one search API key (configured via `env_config` tool or workspace `.env` file):
|
||||
|
||||
| Backend | Environment Variable | Priority | How to Get |
|
||||
| --- | --- | --- | --- |
|
||||
| Bocha Search | `BOCHA_API_KEY` | Primary | [Bocha Open Platform](https://open.bochaai.com/) |
|
||||
| LinkAI Search | `LINKAI_API_KEY` | Fallback | [LinkAI Console](https://link-ai.tech/console/interface) |
|
||||
|
||||
## Parameters
|
||||
|
||||
| Parameter | Type | Required | Description |
|
||||
| --- | --- | --- | --- |
|
||||
| `query` | string | Yes | Search keywords |
|
||||
| `count` | integer | No | Number of results (1-50, default 10) |
|
||||
| `freshness` | string | No | Time range: `noLimit`, `oneDay`, `oneWeek`, `oneMonth`, `oneYear`, or date range like `2025-01-01..2025-02-01` |
|
||||
| `summary` | boolean | No | Return page summaries (default false) |
|
||||
|
||||
## Use Cases
|
||||
|
||||
When the user asks about latest information, needs fact-checking, or real-time data, the Agent automatically invokes this tool.
|
||||
|
||||
<Note>
|
||||
If no search API key is configured, this tool will not be loaded.
|
||||
</Note>
|
||||
29
docs/en/tools/write.mdx
Normal file
29
docs/en/tools/write.mdx
Normal file
@@ -0,0 +1,29 @@
|
||||
---
|
||||
title: write - File Write
|
||||
description: Create or overwrite files
|
||||
---
|
||||
|
||||
# write
|
||||
|
||||
Write content to a file. Creates the file if it doesn't exist, overwrites if it does. Automatically creates parent directories.
|
||||
|
||||
## Dependencies
|
||||
|
||||
No extra dependencies, available by default.
|
||||
|
||||
## Parameters
|
||||
|
||||
| Parameter | Type | Required | Description |
|
||||
| --- | --- | --- | --- |
|
||||
| `path` | string | Yes | File path |
|
||||
| `content` | string | Yes | Content to write |
|
||||
|
||||
## Use Cases
|
||||
|
||||
- Create new code files or scripts
|
||||
- Generate configuration files
|
||||
- Save processing results
|
||||
|
||||
<Note>
|
||||
Single writes should not exceed 10KB. For large files, create a skeleton first, then use the edit tool to add content in chunks.
|
||||
</Note>
|
||||
Reference in New Issue
Block a user