@wenbin_wb/dsh-bridge 2.2.6 → 2.2.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.en.md +278 -0
- package/README.md +143 -142
- package/lib/platform/conversation-bridge.js +120 -70
- package/lib/wechat/node.js +1 -1
- package/package.json +2 -2
- package/README.zh-CN.md +0 -277
package/README.en.md
ADDED
|
@@ -0,0 +1,278 @@
|
|
|
1
|
+
# dsh-bridge
|
|
2
|
+
|
|
3
|
+
[简体中文](README.md) | English
|
|
4
|
+
|
|
5
|
+

|
|
6
|
+
|
|
7
|
+
> Multi-channel remote access plugin for DeepSeek Harness
|
|
8
|
+
|
|
9
|
+
Keep using your DeepSeek Harness on the go. Scan a QR code with your phone and keep working from your sofa, another room, or across the world — no need to sit at your desk, no need to be on the same network, and no need to set up your own public server.
|
|
10
|
+
|
|
11
|
+
Seamlessly extend your local DeepSeek Harness to mobile phones, tablets, public networks, and WeChat / QQ. Access your AI assistant anytime, anywhere via QR code scanning, web browsers, or IM bots.
|
|
12
|
+
|
|
13
|
+
---
|
|
14
|
+
|
|
15
|
+
## Features
|
|
16
|
+
|
|
17
|
+
- **LAN Access**: Scan QR code with your smartphone/tablet, direct access on the same Wi-Fi — keep the conversation going from your phone
|
|
18
|
+
- **Cloudflare Tunnel**: One-click public internet exposure, connect from anywhere without a public server of your own — keep working even when you're away from home
|
|
19
|
+
- **Custom Tunnel**: Connect to your own tunnel server with a fixed domain ([Setup Guide](docs/custom-tunnel.md))
|
|
20
|
+
- **WeChat Bot (ClawBot / iLink)**: Scan a QR code to log in a WeChat personal account, then chat with, control, and approve your DeepSeek Harness agents right inside WeChat. **Multi-workspace selection, restart-persistent sessions, grouped session listing with titles, media (image/file/voice) transfer, and permission approvals** — over Tencent's official iLink Bot API, no public server or tunnel required ([Usage Guide](docs/wechat-usage.md))
|
|
21
|
+
- **QQ Bot (OpenAPI v2)**: Connect your QQ Bot to receive private/group messages, send Markdown, button keyboards, and rich media. **Full event coverage (C2C / GROUP_AT_MESSAGE_CREATE), auto token refresh, reconnection with backoff, message deduplication** — over Tencent's official QQ Bot OpenAPI v2 ([Usage Guide](docs/qq-usage.md))
|
|
22
|
+
- **Official Brand SVG Icons**: Authentic vector brand icons for WeChat, QQ, Feishu, Telegram with real-time status indicators
|
|
23
|
+
- **Fast Version Check & 1-Click Upgrade**: Dual-channel registry check (npmmirror + npmjs fallback in ~200ms) with seamless **1-click in-app upgrade**, no terminal copying required
|
|
24
|
+
- **Dark Mode Support**: Deep integration with DeepSeek Harness Design Tokens (`--dsw-alias-*`), QR code background protection for safe dark mode scanning
|
|
25
|
+
- **Security Alerts**: URLs and QR codes with access warnings to prevent accidental sharing
|
|
26
|
+
|
|
27
|
+

|
|
28
|
+

|
|
29
|
+

|
|
30
|
+

|
|
31
|
+
|
|
32
|
+
---
|
|
33
|
+
|
|
34
|
+
## Roadmap
|
|
35
|
+
|
|
36
|
+
| Target | Description | Status |
|
|
37
|
+
|--------|-------------|--------|
|
|
38
|
+
| **Platform Abstraction** | Platform-agnostic core (sessions / approvals / commands / digest) shared across IM channels | ✅ **Completed** (v2.0.0) |
|
|
39
|
+
| **WeChat** | Chat with your Agent directly in WeChat | ✅ Supported (workspaces / persisted sessions / media / approvals) |
|
|
40
|
+
| **QQ Bot** | QQ bot integration for group/private chat | ✅ **Completed** (v2.1.0) — Markdown / buttons / rich media |
|
|
41
|
+
| **Feishu** | Feishu message/bot integration for workplace scenarios | Planned |
|
|
42
|
+
| **Telegram** | IM channel suited for self-hosting and overseas | Planned |
|
|
43
|
+
| **OpenClaw** | Connect with the OpenClaw ecosystem | Planned |
|
|
44
|
+
|
|
45
|
+
---
|
|
46
|
+
|
|
47
|
+
## Prerequisites
|
|
48
|
+
|
|
49
|
+
Before installing the plugin, make sure:
|
|
50
|
+
|
|
51
|
+
1. **Node.js ≥ 22** (DSH requires `^22.19.0` or `≥ 24.0.0`)
|
|
52
|
+
2. **dsh CLI available** — you can run the `dsh` command in your terminal
|
|
53
|
+
|
|
54
|
+
```bash
|
|
55
|
+
# Check Node version
|
|
56
|
+
node -v # should show v22.19+ or v24+
|
|
57
|
+
|
|
58
|
+
# Check if dsh is available
|
|
59
|
+
dsh --version
|
|
60
|
+
```
|
|
61
|
+
|
|
62
|
+
If `dsh` is not found, install DSH first:
|
|
63
|
+
|
|
64
|
+
```bash
|
|
65
|
+
npm install -g @deepseek-ai/dsh
|
|
66
|
+
```
|
|
67
|
+
|
|
68
|
+
> If you do not have permission for global installation, you can use `npx`:
|
|
69
|
+
> ```bash
|
|
70
|
+
> npx --yes @deepseek-ai/dsh plugin --profile web add @wenbin_wb/dsh-bridge
|
|
71
|
+
> ```
|
|
72
|
+
|
|
73
|
+
---
|
|
74
|
+
|
|
75
|
+
## Installation
|
|
76
|
+
|
|
77
|
+
### From npm (Recommended)
|
|
78
|
+
|
|
79
|
+
```bash
|
|
80
|
+
# Install the latest version
|
|
81
|
+
dsh plugin --profile web add @wenbin_wb/dsh-bridge
|
|
82
|
+
|
|
83
|
+
# Or specify a version (e.g. 2.2.6)
|
|
84
|
+
dsh plugin --profile web add @wenbin_wb/dsh-bridge@2.2.6
|
|
85
|
+
```
|
|
86
|
+
|
|
87
|
+
> 💡 **No global install permission?** Use `npx`:
|
|
88
|
+
> ```bash
|
|
89
|
+
> npx --yes @deepseek-ai/dsh plugin --profile web add @wenbin_wb/dsh-bridge
|
|
90
|
+
> ```
|
|
91
|
+
|
|
92
|
+
### From Source
|
|
93
|
+
|
|
94
|
+
```bash
|
|
95
|
+
git clone https://github.com/wenbin-wb/dsh-bridge.git
|
|
96
|
+
dsh plugin --profile web add ./dsh-bridge
|
|
97
|
+
```
|
|
98
|
+
|
|
99
|
+
After installation, restart DSH and find "Remote Access" in the Settings page.
|
|
100
|
+
|
|
101
|
+
### Upgrading to the Latest Version
|
|
102
|
+
|
|
103
|
+
```bash
|
|
104
|
+
# Method 1: Click "🚀 Upgrade to vX.X.X" directly in Settings -> Remote Access (Recommended, 1-Click)
|
|
105
|
+
|
|
106
|
+
# Method 2: Force install via terminal
|
|
107
|
+
dsh plugin --profile web add @wenbin_wb/dsh-bridge@latest
|
|
108
|
+
```
|
|
109
|
+
|
|
110
|
+
> **Note**: `update --latest` may fail to upgrade to the latest version due to version constraints in installed dependencies. Use the `add @latest` command above to force installing the latest version.
|
|
111
|
+
|
|
112
|
+
#### Still seeing the old version after upgrading? (pnpm 11 minimumReleaseAge)
|
|
113
|
+
|
|
114
|
+
If you upgrade immediately after a new version is released, `add @latest` might still install the old version. This is caused by **pnpm 11's supply chain security mechanism `minimumReleaseAge`** (which filters releases less than 24 hours old by default), not a bug in the plugin.
|
|
115
|
+
|
|
116
|
+
**Solutions** (choose any):
|
|
117
|
+
|
|
118
|
+
1. **Click "1-Click Upgrade" in the DSH Web Settings page** (installs with explicit version tag, takes effect immediately)
|
|
119
|
+
2. **Add `minimumReleaseAge: 0` to your profile's `pnpm-workspace.yaml`**, then run `pnpm install`
|
|
120
|
+
3. **Wait 24 hours**: Protection lifts automatically after 1 day
|
|
121
|
+
|
|
122
|
+
After upgrading, restart DSH, perform a **hard refresh** in your browser (Windows: `Ctrl+Shift+R`, macOS: `Cmd+Shift+R`) to clear cache, and verify the latest version is displayed.
|
|
123
|
+
|
|
124
|
+
---
|
|
125
|
+
|
|
126
|
+
## Usage
|
|
127
|
+
|
|
128
|
+
### LAN Access
|
|
129
|
+
|
|
130
|
+
Automatically active when the plugin starts, zero configuration needed. Open Settings -> "Remote Access", and scan the QR code with your phone.
|
|
131
|
+
|
|
132
|
+

|
|
133
|
+
|
|
134
|
+
### Cloudflare Tunnel
|
|
135
|
+
|
|
136
|
+
1. Click the "Start" button in the "Cloudflare Tunnel" card
|
|
137
|
+
2. On first use, cloudflared (~30MB) will be automatically downloaded from GitHub
|
|
138
|
+
3. Once downloaded, it starts automatically and displays a public URL and QR code within seconds
|
|
139
|
+
4. The URL changes on each restart; click "Reset URL" to request a new URL
|
|
140
|
+
|
|
141
|
+
### Custom Tunnel
|
|
142
|
+
|
|
143
|
+
Requires a server with a public IP. See the [Custom Tunnel Setup Guide](docs/custom-tunnel.md) for detailed steps.
|
|
144
|
+
|
|
145
|
+
1. Deploy the tunnel server on your server following the guide
|
|
146
|
+
2. Enter the WebSocket URL (`wss://...`) and access token in the "Custom Tunnel" card
|
|
147
|
+
3. Click "Save Config", then click "Start"
|
|
148
|
+
|
|
149
|
+
Configurations persist across restarts.
|
|
150
|
+
|
|
151
|
+
### WeChat Bot (ClawBot / iLink)
|
|
152
|
+
|
|
153
|
+
Powered by Tencent's official WeChat ClawBot feature (iLink Bot API). Log in with your personal WeChat account by scanning a QR code, then chat with, control, and approve your DeepSeek Harness agents directly in WeChat — fully routed through Tencent's official servers, no public server or tunnel needed.
|
|
154
|
+
|
|
155
|
+

|
|
156
|
+
|
|
157
|
+
**Key Highlights**
|
|
158
|
+
|
|
159
|
+
- 🗂️ **Multi-Workspace**: `/workspaces` to list workspaces, `@N` or `@path` to start sessions in specific directories
|
|
160
|
+
- 💾 **Session Persistence**: Sessions survive DSH restarts — keep chatting seamlessly
|
|
161
|
+
- 🏷️ **Session Titles**: `/sessions` groups by workspace and displays clean session titles
|
|
162
|
+
- 🖼️ **Media Transfer**: Two-way transfer for images, files, and voice (auto-transcribed to text)
|
|
163
|
+
- 📝 **Approval Prompts**: Approve sensitive operations directly in WeChat; auto-rejects on timeout
|
|
164
|
+
- 🔔 **Real-Time Status**: Heartbeat progress + "typing..." indicators, auto-chunked long replies
|
|
165
|
+
|
|
166
|
+
**Quick Start**
|
|
167
|
+
|
|
168
|
+
1. Open Settings -> "Remote Access" -> "IM Bot" -> Select "WeChat"
|
|
169
|
+
2. Click "Scan QR to Login", scan with WeChat and confirm
|
|
170
|
+
3. Once logged in, **send the first message to the bot to automatically grant allowlist access**
|
|
171
|
+
4. You can now send commands directly in WeChat
|
|
172
|
+
|
|
173
|
+
**WeChat Commands** (Full documentation in [WeChat Bot Usage Guide](docs/wechat-usage.md))
|
|
174
|
+
|
|
175
|
+
| Command | Description |
|
|
176
|
+
|---------|-------------|
|
|
177
|
+
| *(Plain text)* | Send to the currently active agent |
|
|
178
|
+
| `/sessions` (or `/list`) | List sessions (grouped by workspace with titles) |
|
|
179
|
+
| `/use N` (or `/resume N`) | Switch to / resume session N |
|
|
180
|
+
| `/workspaces` | List available workspaces |
|
|
181
|
+
| `/new <prompt>` | Start a new session in the current workspace |
|
|
182
|
+
| `/new <prompt> @N` (or `@path`) | Start a new session in the specified workspace |
|
|
183
|
+
| `/stop` | Stop the current task |
|
|
184
|
+
| `/end` | End the current session |
|
|
185
|
+
| `/status` | View agent status and session summary |
|
|
186
|
+
| `/yes` `/no` (or `1`/`2`) | Respond to permission approval requests |
|
|
187
|
+
| `/start` | Automatically initialize a session after first login |
|
|
188
|
+
| `/help` | Display all available commands |
|
|
189
|
+
|
|
190
|
+
**Security Notes**
|
|
191
|
+
|
|
192
|
+
- Strict Allowlist: Only approved WeChat users can interact with the agent; unauthorized messages are dropped and never fed to the model
|
|
193
|
+
- Default Deny on Approval: Requests auto-reject if `/yes` is not sent within the timeout period (default 10 mins)
|
|
194
|
+
- Credentials stored in DSH Credentials service, never in plaintext configuration
|
|
195
|
+
- Only one bot polling instance per WeChat account at a time. **Please use a dedicated WeChat account** for the bot
|
|
196
|
+
|
|
197
|
+
> Notice: iLink is Tencent's official channel; usage must comply with WeChat terms of service. Tencent reserves content filtering and rate limiting rights. Not recommended for critical production workloads.
|
|
198
|
+
|
|
199
|
+
---
|
|
200
|
+
|
|
201
|
+
### QQ Bot (OpenAPI v2)
|
|
202
|
+
|
|
203
|
+
Integrates Tencent's official QQ Bot platform. Supports private chat, group chat (@bot trigger), streaming output, Markdown rendering, message buttons, and rich media (images/files). Driven by Tencent's official QQ Bot OpenAPI v2 with real-time WebSocket push, automatic token refresh, and auto-reconnection.
|
|
204
|
+
|
|
205
|
+

|
|
206
|
+
|
|
207
|
+

|
|
208
|
+
|
|
209
|
+
**Key Highlights**
|
|
210
|
+
|
|
211
|
+
- 💬 **Private + Group Chat**: Direct private messaging, @bot in groups (first @ auto-approves group)
|
|
212
|
+
- 📝 **Streaming Markdown**: Real-time streaming output with full syntax highlighting, tables, and lists
|
|
213
|
+
- 🎯 **Message Buttons**: Commands like `/end` trigger inline quick-action buttons (New Session, List, Help)
|
|
214
|
+
- 🖼️ **Rich Media**: Bi-directional image and file sending
|
|
215
|
+
- 🔄 **Session Management**: Multi-session switching, persistence across restarts, workspace grouping
|
|
216
|
+
- ✅ **Auto Authorization**: First private message or first group @bot automatically adds to allowlist
|
|
217
|
+
|
|
218
|
+
**Quick Start**
|
|
219
|
+
|
|
220
|
+
1. Go to [QQ Open Platform](https://q.qq.com), create a bot application, and obtain `AppID` and `ClientSecret`
|
|
221
|
+
2. Open Settings -> "Remote Access" -> "IM Bot" -> Select "QQ"
|
|
222
|
+
3. Enter AppID and ClientSecret, click "Save Config" to automatically connect
|
|
223
|
+
4. **Private Chat**: Add the bot as a friend and send the first message to authorize
|
|
224
|
+
5. **Group Chat**: Add the bot to a group and send a message with `@bot` to authorize the group
|
|
225
|
+
|
|
226
|
+
**QQ Commands** (Full documentation in [QQ Bot Usage Guide](docs/qq-usage.md))
|
|
227
|
+
|
|
228
|
+
| Command | Description |
|
|
229
|
+
|---------|-------------|
|
|
230
|
+
| *(Plain text)* | Send to the currently active agent |
|
|
231
|
+
| `/new <prompt>` | Start a new session |
|
|
232
|
+
| `/sessions` (or `/list`) | List sessions (grouped by workspace) |
|
|
233
|
+
| `/use N` (or `/resume N`) | Switch to / resume session N |
|
|
234
|
+
| `/end` | End current session (triggers quick-action buttons) |
|
|
235
|
+
| `/stop` | Stop the current task |
|
|
236
|
+
| `/status` | View agent status |
|
|
237
|
+
| `/workspaces` | List available workspaces |
|
|
238
|
+
| `/help` | Display all available commands |
|
|
239
|
+
|
|
240
|
+
**Important Notice**
|
|
241
|
+
|
|
242
|
+
- **Custom menus, command panels, and interactive buttons require the latest QQ client**
|
|
243
|
+
- If API configuration succeeds but buttons don't appear, update your QQ client to the latest version
|
|
244
|
+
- Plain text commands (e.g. `/new`, `/sessions`, `/help`) work on all client versions
|
|
245
|
+
|
|
246
|
+
---
|
|
247
|
+
|
|
248
|
+
## Optional Configuration
|
|
249
|
+
|
|
250
|
+
The plugin is ready to use out of the box. To customize the proxy port, add to `cordis.yml`:
|
|
251
|
+
|
|
252
|
+
```yaml
|
|
253
|
+
- name: '@wenbin_wb/dsh-bridge'
|
|
254
|
+
config:
|
|
255
|
+
port: 3082 # default 3082
|
|
256
|
+
```
|
|
257
|
+
|
|
258
|
+
---
|
|
259
|
+
|
|
260
|
+
## Development
|
|
261
|
+
|
|
262
|
+
```bash
|
|
263
|
+
git clone https://github.com/wenbin-wb/dsh-bridge.git
|
|
264
|
+
cd dsh-bridge
|
|
265
|
+
npm install
|
|
266
|
+
|
|
267
|
+
# Rebuild client bundle after editing client/index.js
|
|
268
|
+
npm run build:client
|
|
269
|
+
|
|
270
|
+
# Install to web profile and restart DSH
|
|
271
|
+
dsh plugin --profile web add .
|
|
272
|
+
```
|
|
273
|
+
|
|
274
|
+
---
|
|
275
|
+
|
|
276
|
+
## License
|
|
277
|
+
|
|
278
|
+
MIT © [wenbin-wb](https://github.com/wenbin-wb)
|