@weavetab/mcp 2.5.0-beta.1 → 2.5.0-beta.4
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/AGENTS.md +2 -1
- package/ARCHITECTURE.md +6 -6
- package/LICENSE +1 -1
- package/README.md +164 -802
- package/SECURITY.md +33 -22
- package/TROUBLESHOOTING.md +3 -3
- package/dist/cdp/bridge.d.ts +10 -0
- package/dist/cdp/bridge.js +285 -78
- package/dist/cdp/connector.d.ts +7 -3
- package/dist/cdp/connector.js +196 -75
- package/dist/cdp/helpers.d.ts +4 -0
- package/dist/cdp/helpers.js +181 -0
- package/dist/cdp/lock.d.ts +9 -6
- package/dist/cdp/lock.js +72 -59
- package/dist/cdp/omni_broker.d.ts +2 -1
- package/dist/cdp/omni_broker.js +13 -7
- package/dist/cdp/profiles.d.ts +10 -0
- package/dist/cdp/profiles.js +65 -0
- package/dist/cdp/walker.d.ts +25 -1
- package/dist/cdp/walker.js +354 -7
- package/dist/cli/plugin.d.ts +0 -2
- package/dist/cli/plugin.js +51 -696
- package/dist/cli/updater.d.ts +1 -1
- package/dist/cli/updater.js +27 -7
- package/dist/config/loader.d.ts +33 -6
- package/dist/config/loader.js +174 -22
- package/dist/desktop/discovery.d.ts +44 -0
- package/dist/desktop/discovery.js +364 -0
- package/dist/index.js +140 -64
- package/dist/intelligence/marks.d.ts +36 -0
- package/dist/intelligence/marks.js +30 -0
- package/dist/intelligence/patternCompiler.d.ts +118 -0
- package/dist/intelligence/patternCompiler.js +259 -0
- package/dist/intelligence/sessionMemory.d.ts +2 -0
- package/dist/intelligence/sessionMemory.js +18 -8
- package/dist/overlay/ghost.js +2 -2
- package/dist/overlay/injector.js +3 -5
- package/dist/plugin/extension_bridge.d.ts +40 -0
- package/dist/plugin/extension_bridge.js +158 -0
- package/dist/plugin/interface.d.ts +151 -15
- package/dist/plugin/loader.d.ts +19 -1
- package/dist/plugin/loader.js +331 -63
- package/dist/plugin/pipeline.d.ts +75 -0
- package/dist/plugin/pipeline.js +183 -0
- package/dist/plugin/registry.js +12 -1
- package/dist/plugin/storage.d.ts +51 -0
- package/dist/plugin/storage.js +164 -0
- package/dist/security/secrets.d.ts +1 -0
- package/dist/security/secrets.js +13 -0
- package/dist/sensors/actionability.js +1 -2
- package/dist/sensors/guard.js +4 -10
- package/dist/sensors/mutations.js +12 -0
- package/dist/sensors/operation_monitor.js +1 -0
- package/dist/server.d.ts +1 -1
- package/dist/server.js +600 -236
- package/dist/state/agent.d.ts +1 -0
- package/dist/state/agent.js +3 -0
- package/dist/state/delta.d.ts +12 -4
- package/dist/state/delta.js +67 -14
- package/dist/state/session.d.ts +8 -2
- package/dist/state/session.js +60 -13
- package/dist/tools/browser_detect.d.ts +16 -2
- package/dist/tools/browser_detect.js +54 -6
- package/dist/tools/burst.d.ts +17 -7
- package/dist/tools/burst.js +240 -83
- package/dist/tools/checkpoint.d.ts +38 -0
- package/dist/tools/checkpoint.js +271 -0
- package/dist/tools/click.d.ts +1 -0
- package/dist/tools/click.js +97 -98
- package/dist/tools/clipboard.js +31 -24
- package/dist/tools/design_extract.js +1 -1
- package/dist/tools/eval.js +1 -1
- package/dist/tools/fill.d.ts +20 -1
- package/dist/tools/fill.js +199 -40
- package/dist/tools/find.d.ts +16 -0
- package/dist/tools/find.js +67 -44
- package/dist/tools/github/index.d.ts +19 -4
- package/dist/tools/github/index.js +40 -4
- package/dist/tools/highlight.d.ts +6 -2
- package/dist/tools/highlight.js +158 -72
- package/dist/tools/inspect.js +1 -1
- package/dist/tools/key.js +65 -56
- package/dist/tools/navigate.d.ts +1 -1
- package/dist/tools/navigate.js +57 -44
- package/dist/tools/pdf.js +21 -13
- package/dist/tools/pointer.d.ts +18 -3
- package/dist/tools/pointer.js +89 -1
- package/dist/tools/read.d.ts +28 -8
- package/dist/tools/read.js +230 -56
- package/dist/tools/scrape.js +67 -13
- package/dist/tools/screenshot.js +21 -16
- package/dist/tools/scroll.js +6 -11
- package/dist/tools/select.js +8 -2
- package/dist/tools/snapshot.js +3 -34
- package/dist/tools/tabs.d.ts +10 -10
- package/dist/tools/tabs.js +55 -39
- package/dist/tools/thought.d.ts +2 -0
- package/dist/tools/thought.js +13 -14
- package/dist/tools/type.d.ts +2 -0
- package/dist/tools/type.js +109 -60
- package/dist/tools/type_secret.js +42 -76
- package/dist/tools/upload.js +1 -1
- package/dist/tools/video_compiler.d.ts +1 -1
- package/dist/tools/video_compiler.js +11 -12
- package/dist/version.d.ts +5 -0
- package/dist/version.js +5 -0
- package/docs/DOCUMENTATION.md +82 -36
- package/docs/PLUGINS.md +82 -499
- package/docs/TOOLS.md +51 -99
- package/docs/architecture/blind-injection.md +83 -0
- package/docs/architecture/dual-injection.md +32 -0
- package/docs/architecture/overview.md +49 -0
- package/docs/architecture/security.md +35 -0
- package/docs/architecture/transport.md +37 -0
- package/docs/captcha-stealth/captcha-solver.md +75 -0
- package/docs/captcha-stealth/stealth-physics.md +60 -0
- package/docs/cli/cli-commands.md +44 -0
- package/docs/cli/cli-flags.md +20 -0
- package/docs/cli/cli-introduction.md +20 -0
- package/docs/cli/cli-scripting.md +32 -0
- package/docs/cli/g-ide/ide-antigravity.md +24 -0
- package/docs/cli/g-ide/ide-claude-code.md +24 -0
- package/docs/cli/g-ide/ide-claude-desktop.md +32 -0
- package/docs/cli/g-ide/ide-cursor.md +31 -0
- package/docs/cli/g-ide/ide-generic.md +34 -0
- package/docs/cli/g-ide/ide-opencode.md +24 -0
- package/docs/cli/g-ide/ide-vscode-copilot.md +24 -0
- package/docs/cli/g-ide/ide-windsurf.md +24 -0
- package/docs/configuration/config-locations.md +24 -0
- package/docs/configuration/configuration.md +73 -0
- package/docs/configuration/env-variables.md +19 -0
- package/docs/configuration/folders.md +55 -0
- package/docs/desktop-automation/electron-apps.md +217 -0
- package/docs/get-started/installation.md +47 -0
- package/docs/get-started/introduction.md +60 -0
- package/docs/get-started/quickstart.md +54 -0
- package/docs/get-started/setup-wizard.md +26 -0
- package/docs/intelligence/site-profiles.md +151 -0
- package/docs/skills-ecosystem/skills-overview.md +35 -0
- package/docs/skills-ecosystem/skills-recipes.md +36 -0
- package/docs/tools/tools.md +631 -0
- package/docs/troubleshooting/trouble-browser.md +27 -0
- package/docs/troubleshooting/trouble-config.md +20 -0
- package/docs/troubleshooting/trouble-loop.md +31 -0
- package/ext-dist/background.js +10 -62
- package/ext-dist/content.js +333 -921
- package/ext-dist/hud/hud.js +9 -9
- package/ext-dist/manifest.json +2 -6
- package/ext-dist/styles.css +6 -1
- package/mcp.json +108 -72
- package/package.json +14 -9
- package/server.json +3 -3
- package/docs/DEV_MODE.md +0 -68
- package/docs/dev_plugin.md +0 -310
- package/ext-dist/sidepanel/sidepanel.js +0 -25
- package/ext-dist/sidepanel.html +0 -547
|
@@ -0,0 +1,217 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: "Desktop & Electron Apps"
|
|
3
|
+
description: "Native Layer 0 automation for VS Code, Discord, Figma, Slack, and any Electron app."
|
|
4
|
+
product: mcp
|
|
5
|
+
section: desktop-automation
|
|
6
|
+
badge: new
|
|
7
|
+
icon: AppWindow
|
|
8
|
+
slug: electron-apps
|
|
9
|
+
---
|
|
10
|
+
|
|
11
|
+
# Desktop & Electron Application Automation
|
|
12
|
+
|
|
13
|
+
Weavetab is a **universal Layer 0 agent runtime**. In addition to standard Chromium web browsing, Weavetab gives AI agents direct, native CDP control over **any desktop Electron application** — including Discord, VS Code, Figma, Slack, Obsidian, Postman, Notion, Spotify, and custom internal tools.
|
|
14
|
+
|
|
15
|
+
## How It Works
|
|
16
|
+
|
|
17
|
+
Because modern desktop applications are built on the Chromium/Electron framework, Weavetab can communicate with them directly over CDP WebSocket without requiring separate drivers or UI automation bridges.
|
|
18
|
+
|
|
19
|
+
```text
|
|
20
|
+
AI Agent (MCP) ──► withSecurity()
|
|
21
|
+
├── (Default) ─────────► CDP:9222 ──► Google Chrome / Chromium
|
|
22
|
+
├── (app: "discord") ──► CDP:9223 ──► Discord Desktop
|
|
23
|
+
├── (app: "figma") ──► CDP:9224 ──► Figma Desktop
|
|
24
|
+
└── (app: "vscode") ──► CDP:9225 ──► VS Code Desktop
|
|
25
|
+
```
|
|
26
|
+
|
|
27
|
+
### Dual-Port Concurrency & Multi-Target Sessions
|
|
28
|
+
- **Concurrent Execution**: Web browser sessions and Electron desktop app sessions run side-by-side on independent CDP ports (e.g. port `9222` for Chrome, `9223` for Discord, `9224` for Figma).
|
|
29
|
+
- **Zero Session Clobbering**: Switching between a browser tab and a desktop app does not close, disconnect, or reload either target.
|
|
30
|
+
- **Unified Tool Interface**: Pass `"app": "<appName>"` to any Weavetab tool to target that desktop application. Omit `app` to target the active web browser.
|
|
31
|
+
|
|
32
|
+
---
|
|
33
|
+
|
|
34
|
+
## Interactive App Configurator & Agent Generator
|
|
35
|
+
|
|
36
|
+
Use the interactive configurator below to customize your desktop applications. Select presets or add custom apps, toggle between executable path strings, remote debug ports, or advanced objects, and copy the ready-to-use JSON or an automated setup prompt for your AI coding agent:
|
|
37
|
+
|
|
38
|
+
```electron-configurator
|
|
39
|
+
```
|
|
40
|
+
|
|
41
|
+
---
|
|
42
|
+
|
|
43
|
+
## 1. Configuring Desktop Apps in `config.json`
|
|
44
|
+
|
|
45
|
+
Add an `"electron"` object to your local `./.weavetab/config.json` or global `~/.weavetab/config.json`:
|
|
46
|
+
|
|
47
|
+
```json
|
|
48
|
+
{
|
|
49
|
+
"electron": {
|
|
50
|
+
"discord": "C:\\Users\\username\\AppData\\Local\\Discord\\app-<version>\\Discord.exe",
|
|
51
|
+
"vscode": 9222,
|
|
52
|
+
"figma": {
|
|
53
|
+
"path": "C:\\Users\\username\\AppData\\Local\\Figma\\Figma.exe",
|
|
54
|
+
"port": 9224,
|
|
55
|
+
"url": "https://www.figma.com",
|
|
56
|
+
"args": ["--enable-features=WebRTCPipeWireCapturer"]
|
|
57
|
+
},
|
|
58
|
+
"slack": "/Applications/Slack.app/Contents/MacOS/Slack",
|
|
59
|
+
"obsidian": "/usr/bin/obsidian"
|
|
60
|
+
}
|
|
61
|
+
}
|
|
62
|
+
```
|
|
63
|
+
|
|
64
|
+
### Configuration Formats Supported
|
|
65
|
+
|
|
66
|
+
| Format | Example | Description |
|
|
67
|
+
|---|---|---|
|
|
68
|
+
| **Executable Path String** | `"discord": "C:\\path\\to\\Discord.exe"` | Automatically launches the binary on an isolated port and dedicated profile. |
|
|
69
|
+
| **Port Number** | `"vscode": 9222` | Attaches directly to an already-running instance started with `--remote-debugging-port=9222`. |
|
|
70
|
+
| **Full Configuration Object** | `"figma": { "path": "...", "port": 9224, "url": "..." }` | Custom control over binary path, debug port, initial launch URL, custom profile directory, and startup CLI args. |
|
|
71
|
+
|
|
72
|
+
---
|
|
73
|
+
|
|
74
|
+
## 2. Security & Profile Isolation
|
|
75
|
+
|
|
76
|
+
Weavetab enforces enterprise-grade sandbox separation for all desktop applications:
|
|
77
|
+
|
|
78
|
+
1. **Dedicated User Profiles**: Automated sessions are assigned isolated data profiles under `~/.weavetab-system/apps/<appName>/`.
|
|
79
|
+
2. **Real AppData Protection**: Weavetab strictly enforces `assertNotRealElectronProfile` — attempting to target your primary OS user data directories (`%APPDATA%`, `~/Library/Application Support`, or `~/.config`) is blocked to protect your personal logins and local databases from accidental automation corruption.
|
|
80
|
+
3. **Lock & Mutex Isolation**: Dedicated lockfiles (`~/.weavetab-system/locks/<appName>.lock`) ensure concurrent agent operations never conflict.
|
|
81
|
+
|
|
82
|
+
---
|
|
83
|
+
|
|
84
|
+
## 3. Supported Desktop Schemes & Protocols
|
|
85
|
+
|
|
86
|
+
Weavetab automatically allows and whitelist-bypasses desktop internal protocols:
|
|
87
|
+
- `app://` (Electron internal resources)
|
|
88
|
+
- `vscode-webview://` / `vscode-file://` (VS Code extensions and webviews)
|
|
89
|
+
- `discord://` / `slack://` (Deep-links)
|
|
90
|
+
- `devtools://` / `chrome://` / `about:`
|
|
91
|
+
- `file:///` (Local files)
|
|
92
|
+
|
|
93
|
+
---
|
|
94
|
+
|
|
95
|
+
## 4. How Agents Interact with Desktop Apps
|
|
96
|
+
|
|
97
|
+
To target an Electron application, simply pass the `app` argument to any Weavetab tool:
|
|
98
|
+
|
|
99
|
+
### A. Inspect Desktop DOM Tree
|
|
100
|
+
```json
|
|
101
|
+
{
|
|
102
|
+
"name": "browser_map",
|
|
103
|
+
"arguments": {
|
|
104
|
+
"app": "discord",
|
|
105
|
+
"scope": "main_content"
|
|
106
|
+
}
|
|
107
|
+
}
|
|
108
|
+
```
|
|
109
|
+
|
|
110
|
+
### B. Click & Type in Desktop Apps
|
|
111
|
+
```json
|
|
112
|
+
{
|
|
113
|
+
"name": "browser_click",
|
|
114
|
+
"arguments": {
|
|
115
|
+
"ref": "w:42",
|
|
116
|
+
"app": "discord"
|
|
117
|
+
}
|
|
118
|
+
}
|
|
119
|
+
```
|
|
120
|
+
|
|
121
|
+
```json
|
|
122
|
+
{
|
|
123
|
+
"name": "browser_type",
|
|
124
|
+
"arguments": {
|
|
125
|
+
"ref": "w:45",
|
|
126
|
+
"text": "Automated build passed successfully! 🚀",
|
|
127
|
+
"app": "discord"
|
|
128
|
+
}
|
|
129
|
+
}
|
|
130
|
+
```
|
|
131
|
+
|
|
132
|
+
### C. Multi-Target Burst Orchestration
|
|
133
|
+
```json
|
|
134
|
+
{
|
|
135
|
+
"name": "browser_burst",
|
|
136
|
+
"arguments": {
|
|
137
|
+
"app": "vscode",
|
|
138
|
+
"steps": [
|
|
139
|
+
{ "action": "click_and_wait", "selector": ".monaco-editor" },
|
|
140
|
+
{ "action": "type_and_send", "text": "npm test" }
|
|
141
|
+
]
|
|
142
|
+
}
|
|
143
|
+
}
|
|
144
|
+
```
|
|
145
|
+
|
|
146
|
+
---
|
|
147
|
+
|
|
148
|
+
## 5. Launching Existing Desktop Apps in Debug Mode
|
|
149
|
+
|
|
150
|
+
If you prefer to attach Weavetab to your existing desktop app instance:
|
|
151
|
+
|
|
152
|
+
```bash
|
|
153
|
+
# Launch VS Code with CDP debugging enabled
|
|
154
|
+
code --remote-debugging-port=9222
|
|
155
|
+
|
|
156
|
+
# Launch Obsidian with CDP debugging enabled
|
|
157
|
+
obsidian --remote-debugging-port=9225
|
|
158
|
+
|
|
159
|
+
# Launch Discord with CDP debugging enabled
|
|
160
|
+
discord --remote-debugging-port=9223
|
|
161
|
+
```
|
|
162
|
+
Then in your `config.json`, simply map `"vscode": 9222` or `"obsidian": 9225`.
|
|
163
|
+
|
|
164
|
+
---
|
|
165
|
+
|
|
166
|
+
## 6. Environment Discovery Handshake (`browser_detect`)
|
|
167
|
+
|
|
168
|
+
`browser_detect` is the foundational tool agents invoke upon initial engagement. It inspects local browsers and configured desktop applications, returning their real-time state:
|
|
169
|
+
|
|
170
|
+
```json
|
|
171
|
+
{
|
|
172
|
+
"available": [
|
|
173
|
+
{ "engine": "chromium", "name": "Google Chrome", "path": "C:\\Program Files\\...\\chrome.exe" }
|
|
174
|
+
],
|
|
175
|
+
"current": "chromium",
|
|
176
|
+
"configuredApps": [
|
|
177
|
+
{
|
|
178
|
+
"name": "discord",
|
|
179
|
+
"status": "running_no_debug",
|
|
180
|
+
"configuredPath": "C:\\Users\\username\\AppData\\Local\\Discord\\app-1.0.9256\\Discord.exe"
|
|
181
|
+
},
|
|
182
|
+
{
|
|
183
|
+
"name": "slack",
|
|
184
|
+
"status": "connected",
|
|
185
|
+
"port": 9222,
|
|
186
|
+
"configuredPath": "C:\\Users\\username\\AppData\\Local\\slack\\app-4.38.125\\slack.exe",
|
|
187
|
+
"activeTabs": [
|
|
188
|
+
{ "id": "PAGE_1", "title": "general - Slack", "url": "https://app.slack.com/client/..." }
|
|
189
|
+
]
|
|
190
|
+
},
|
|
191
|
+
{
|
|
192
|
+
"name": "vscode",
|
|
193
|
+
"status": "offline",
|
|
194
|
+
"configuredPath": "C:\\Users\\username\\AppData\\Local\\Programs\\Microsoft VS Code\\Code.exe"
|
|
195
|
+
}
|
|
196
|
+
]
|
|
197
|
+
}
|
|
198
|
+
```
|
|
199
|
+
|
|
200
|
+
### Application Lifecycle States:
|
|
201
|
+
- **`connected`**: The app is running with CDP remote debugging active and Weavetab is attached. Agents can immediately operate tabs/windows using `"app": "<name>"`.
|
|
202
|
+
- **`running_no_debug`**: The app process is currently running on the OS, but was opened by the user without `--remote-debugging-port`. Weavetab alerts the agent that DOM interactions are blocked until the app is launched or restarted with debugging flags.
|
|
203
|
+
- **`offline`**: The process is not running. Calling `browser_navigate(app: "<name>")` launches and connects the app automatically.
|
|
204
|
+
|
|
205
|
+
### Windows Squirrel Auto-Path Resolution:
|
|
206
|
+
On Windows, applications like Discord and Slack install inside versioned folders (e.g. `Discord\app-1.0.9256\Discord.exe`) that change on every background update. Weavetab dynamically resolves the newest `app-1.0.xxxx` version at launch time, eliminating broken path errors after silent background updates.
|
|
207
|
+
|
|
208
|
+
---
|
|
209
|
+
|
|
210
|
+
## 7. Smart Domain Routing & Sticky Context
|
|
211
|
+
|
|
212
|
+
To ensure external AI agents do not accidentally trigger a web browser launch when intending to control an Electron application:
|
|
213
|
+
|
|
214
|
+
1. **Automatic Domain Routing**: When `browser_navigate` or `browser_tabs(action: "open")` receives an app domain (e.g. `discord.com`, `slack.com`, `linear.app`, `notion.so`), Weavetab automatically routes the target to the configured desktop application.
|
|
215
|
+
2. **Sticky App Sessions**: When an agent operates inside an Electron app, the target session context remains sticky. Subsequent calls to `browser_tabs` or DOM tools stick to that active desktop app without spawning an unwanted Chrome window.
|
|
216
|
+
3. **Explicit Browser Targeting**: When the agent specifically intends to use the web browser, passing `"app": "browser"` overrides desktop routing and directs operations to the web browser.
|
|
217
|
+
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: "Installation"
|
|
3
|
+
description: "Install Weavetab globally or run it ad-hoc with npx."
|
|
4
|
+
product: mcp
|
|
5
|
+
section: get-started
|
|
6
|
+
icon: Download
|
|
7
|
+
slug: installation
|
|
8
|
+
---
|
|
9
|
+
|
|
10
|
+
# Installation
|
|
11
|
+
|
|
12
|
+
```bash
|
|
13
|
+
# Global installation (recommended)
|
|
14
|
+
npm install -g @weavetab/mcp@latest
|
|
15
|
+
|
|
16
|
+
# Or run directly without installation
|
|
17
|
+
npx -y @weavetab/mcp@latest
|
|
18
|
+
|
|
19
|
+
# Install Developer SDK as dev dependency in a project
|
|
20
|
+
npm install -D @weavetab/sdk@latest
|
|
21
|
+
|
|
22
|
+
# Verify installation
|
|
23
|
+
weavetab --version
|
|
24
|
+
# → @weavetab/mcp 2.5.0
|
|
25
|
+
```
|
|
26
|
+
|
|
27
|
+
## System Requirements
|
|
28
|
+
|
|
29
|
+
- **Node.js** >= 18.0.0 (Node 20 or 22 LTS recommended)
|
|
30
|
+
- **Chromium-based browser** (Google Chrome, Microsoft Edge, Brave, or Chromium)
|
|
31
|
+
- *Optional:* Firefox or Safari Technology Preview via `browserType` config
|
|
32
|
+
- *Optional for Desktop Automation:* Any Electron application (Discord, VS Code, Figma, Obsidian, Postman, etc.)
|
|
33
|
+
|
|
34
|
+
## CLI Binary Aliases
|
|
35
|
+
|
|
36
|
+
```bash
|
|
37
|
+
weavetab # standard binary
|
|
38
|
+
Weavetab # case-insensitive alias
|
|
39
|
+
```
|
|
40
|
+
|
|
41
|
+
## What Gets Configured
|
|
42
|
+
|
|
43
|
+
Weavetab ships as a single, self-contained Node package. On first run it:
|
|
44
|
+
|
|
45
|
+
1. Auto-detects an installed Chromium binary on `$PATH`
|
|
46
|
+
2. Creates `~/.weavetab/` for global configuration, secrets, and policy rules
|
|
47
|
+
3. Registers a local MCP entry point that clients launch over stdio or WebSocket
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: "Introduction"
|
|
3
|
+
description: "What Weavetab is, Layer 0 CDP architecture, and design tenets."
|
|
4
|
+
product: mcp
|
|
5
|
+
section: get-started
|
|
6
|
+
icon: BookOpen
|
|
7
|
+
slug: introduction
|
|
8
|
+
---
|
|
9
|
+
|
|
10
|
+
# Introduction
|
|
11
|
+
|
|
12
|
+
Weavetab is a production-grade, local **Model Context Protocol (MCP) server** that grants AI agents human-like control over Chromium browsers and native **Electron desktop applications** (VS Code, Discord, Slack, Figma, Obsidian, Postman, Antigravity IDE, etc.) — communicating directly over the **Chrome DevTools Protocol (CDP)** at Layer 0.
|
|
13
|
+
|
|
14
|
+
No WebDriver. No browser binary downloads. No Playwright or Puppeteer abstraction layer. No cloud dependency. Tool invocations resolve in **3–8 ms** of mean latency.
|
|
15
|
+
|
|
16
|
+
## Synchronized Ecosystem Releases
|
|
17
|
+
|
|
18
|
+
Both **`@weavetab/mcp`** and the **`@weavetab/sdk`** share synchronized release lines. Every capability introduced in the core runtime is immediately available in the developer SDK with 100% type safety and zero version mismatch.
|
|
19
|
+
|
|
20
|
+
```bash
|
|
21
|
+
# Install core Weavetab MCP server globally
|
|
22
|
+
npm install -g @weavetab/mcp@latest
|
|
23
|
+
|
|
24
|
+
# Or run directly via npx
|
|
25
|
+
npx -y @weavetab/mcp@latest
|
|
26
|
+
|
|
27
|
+
# Install Weavetab Developer SDK as a dev dependency
|
|
28
|
+
npm install -D @weavetab/sdk@latest
|
|
29
|
+
```
|
|
30
|
+
|
|
31
|
+
## Design Tenets
|
|
32
|
+
|
|
33
|
+
| Tenet | Implementation |
|
|
34
|
+
|---|---|
|
|
35
|
+
| **Ultra-Low Latency** | Sub-10 ms tool execution via direct CDP WebSocket connections |
|
|
36
|
+
| **Universal Control** | Native orchestration across Chromium web tabs and any Electron desktop app |
|
|
37
|
+
| **Autonomous CAPTCHA** | Zero-API solving (Cloudflare Turnstile, GeeTest, reCAPTCHA) via human Bézier mouse physics |
|
|
38
|
+
| **Security & RBAC** | 4-tier RBAC + domain policies + Blind Credential Injection + profile isolation |
|
|
39
|
+
| **Token Efficiency** | Semantic Delta diffing (up to 97% reduction) + intelligent DOM pruning |
|
|
40
|
+
| **Stealth & Physics** | Ghost Cursor (Bézier curves), human typing jitter, and CDP early-script fingerprint spoofing |
|
|
41
|
+
| **Self-Learning** | Per-domain session memory, framework detection, and automated loop recovery |
|
|
42
|
+
| **Zero Cloud** | Pure local computation. No external telemetry or cloud tracking unless explicitly opted in |
|
|
43
|
+
|
|
44
|
+
## What You Get
|
|
45
|
+
|
|
46
|
+
- **49 built-in MCP tools** covering DOM vision, input synthesis, desktop apps, tabs, network interception, office files, design extraction, and plugin lifecycle
|
|
47
|
+
- **Universal Desktop App Runtime** — control Chrome and native Electron apps (Discord, Figma, VS Code) side-by-side without port conflicts
|
|
48
|
+
- **Autonomous Zero-API CAPTCHA Solver** — solve Cloudflare Turnstile, GeeTest, and reCAPTCHA locally via CDP mouse physics with $0 API costs
|
|
49
|
+
- **Two transport modes** — stdio (Claude Desktop, Cursor, VS Code, Windsurf, Antigravity) and WebSocket (`--ws --port 3000`)
|
|
50
|
+
- **Four RBAC roles** — `admin`, `operator`, `viewer`, and `automation`
|
|
51
|
+
- **Per-domain policies** — ring-fences sensitive banking, internal, and production surfaces
|
|
52
|
+
- **Blind Injection** — credentials resolved server-side from `secrets.json` and never exposed to the LLM
|
|
53
|
+
- **Extensible Plugin System** — auto-discovers and mounts custom MCP tools from `node_modules`
|
|
54
|
+
|
|
55
|
+
## Next Steps
|
|
56
|
+
|
|
57
|
+
- **[Quickstart](quickstart.md)** — install and run a first mission in 60 seconds
|
|
58
|
+
- **[Desktop & Electron Apps](../desktop-automation/electron-apps.md)** — configure and control desktop apps
|
|
59
|
+
- **[Autonomous CAPTCHA Solver](../captcha-stealth/captcha-solver.md)** — zero-API anti-bot solving
|
|
60
|
+
- **[MCP Tools Reference](../tools/tools.md)** — full reference for all 49 built-in automation tools
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: "Quickstart"
|
|
3
|
+
description: "Install, configure, and run a first mission in under a minute."
|
|
4
|
+
product: mcp
|
|
5
|
+
section: get-started
|
|
6
|
+
icon: Zap
|
|
7
|
+
slug: quickstart
|
|
8
|
+
---
|
|
9
|
+
|
|
10
|
+
# Quickstart
|
|
11
|
+
|
|
12
|
+
Get Weavetab attached to your agent and running a real browser mission in three simple steps.
|
|
13
|
+
|
|
14
|
+
## 1. Install Weavetab
|
|
15
|
+
|
|
16
|
+
```bash
|
|
17
|
+
# Global installation (recommended)
|
|
18
|
+
npm install -g @weavetab/mcp@latest
|
|
19
|
+
|
|
20
|
+
# Or run directly with npx
|
|
21
|
+
npx -y @weavetab/mcp@latest
|
|
22
|
+
```
|
|
23
|
+
|
|
24
|
+
## 2. Wire to your MCP Client
|
|
25
|
+
|
|
26
|
+
Point any MCP-compatible client (Claude Desktop, Cursor, Windsurf, VS Code, Antigravity) at the binary:
|
|
27
|
+
|
|
28
|
+
```json
|
|
29
|
+
{
|
|
30
|
+
"mcpServers": {
|
|
31
|
+
"weavetab": {
|
|
32
|
+
"command": "weavetab"
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
```
|
|
37
|
+
|
|
38
|
+
## 3. Run a First Mission
|
|
39
|
+
|
|
40
|
+
Use `browser_burst` to chain multiple actions in a single round-trip:
|
|
41
|
+
|
|
42
|
+
```json
|
|
43
|
+
{
|
|
44
|
+
"name": "browser_burst",
|
|
45
|
+
"arguments": {
|
|
46
|
+
"steps": [
|
|
47
|
+
{ "action": "navigate_and_read", "url": "https://example.com" },
|
|
48
|
+
{ "action": "click_and_wait", "selector": "#login-btn" }
|
|
49
|
+
]
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
```
|
|
53
|
+
|
|
54
|
+
You will see the browser launch, the Ghost Cursor glide across the page along human Bézier curves, and the agent complete the task with sub-10ms CDP execution.
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: "Setup Wizard"
|
|
3
|
+
description: "Interactive wizard that writes a clean config.json."
|
|
4
|
+
product: mcp
|
|
5
|
+
section: get-started
|
|
6
|
+
icon: Wand2
|
|
7
|
+
slug: setup-wizard
|
|
8
|
+
---
|
|
9
|
+
|
|
10
|
+
# Setup Wizard
|
|
11
|
+
|
|
12
|
+
Run the interactive CLI configuration wizard:
|
|
13
|
+
|
|
14
|
+
```bash
|
|
15
|
+
weavetab config
|
|
16
|
+
```
|
|
17
|
+
|
|
18
|
+
The wizard walks through every option across 5 interactive phases. Re-run it at any time to update your saved config.
|
|
19
|
+
|
|
20
|
+
## Wizard Phases
|
|
21
|
+
|
|
22
|
+
1. **Phase 1 — Essentials:** Browser path, RBAC role (`admin`, `operator`, `viewer`, `automation`), headless mode, dev mode, max tabs, actionability timeout, domain block/allow lists.
|
|
23
|
+
2. **Phase 2 — Advanced:** Browser engine selection, navigation timeouts, dark mode preferences, telemetry opt-in, outbound HTTP/SOCKS proxy, domain policy modes.
|
|
24
|
+
3. **Phase 3 — Save Location:** Global (`~/.weavetab/config.json`) or Project-scoped (`./.weavetab/config.json`).
|
|
25
|
+
4. **Phase 4 — MCP Auto-Config:** Auto-detects installed IDEs (Claude Desktop, Cursor, Windsurf, VS Code, OpenCode, Claude Code, Antigravity) and merges Weavetab into their MCP configuration.
|
|
26
|
+
5. **Phase 5 — Summary:** Displays full configuration validation report.
|
|
@@ -0,0 +1,151 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: "Site Profiles and Intelligent Memory"
|
|
3
|
+
description: "Persistent cross-session workflow memory, pattern compilation, and quirk bypass in ~/.weavetab-system/memory/sites/."
|
|
4
|
+
product: mcp
|
|
5
|
+
section: intelligence
|
|
6
|
+
icon: Brain
|
|
7
|
+
slug: site-profiles
|
|
8
|
+
---
|
|
9
|
+
|
|
10
|
+
# Site Profiles and Intelligent Memory Engine
|
|
11
|
+
|
|
12
|
+
Every browser automation session normally starts from zero context. The agent re-inspects DOM trees, re-triggers cookie banners, and re-discovers login fields.
|
|
13
|
+
|
|
14
|
+
Weavetab solves this with a **Two-Tier Persistent Memory System** that accumulates knowledge about domains and workflows across sessions.
|
|
15
|
+
|
|
16
|
+
---
|
|
17
|
+
|
|
18
|
+
## Directory Hierarchy: System vs. User Space
|
|
19
|
+
|
|
20
|
+
| Directory | Purpose | Managed By |
|
|
21
|
+
| :--- | :--- | :--- |
|
|
22
|
+
| `~/.weavetab-system/memory/sites/` | **Persistent Site Profiles**: named workflow patterns, quirks, reliability scores | Weavetab Engine (autonomous) |
|
|
23
|
+
| `~/.weavetab-system/memory/` | **Selector Confidence Cache**: per-domain element selectors and strike counters | Weavetab Engine (autonomous) |
|
|
24
|
+
| `~/.weavetab-system/sessions/` | **Rolling Action Trails**: 50-step window for loop detection | Weavetab Engine (autonomous) |
|
|
25
|
+
| `~/.weavetab/` | **User Configuration**: `config.json`, `secrets.json`, `policy.json`, plugins | User / Developer (manual) |
|
|
26
|
+
|
|
27
|
+
> **Directory Law**: Machine-compiled memory profiles are strictly located in `~/.weavetab-system/memory/sites/`. User configuration in `~/.weavetab/` is never polluted by machine learning trails or dynamic decay counters.
|
|
28
|
+
|
|
29
|
+
---
|
|
30
|
+
|
|
31
|
+
## Site Profile Schema
|
|
32
|
+
|
|
33
|
+
Profiles are stored as `<sanitized-hostname>.json` under `~/.weavetab-system/memory/sites/`:
|
|
34
|
+
|
|
35
|
+
```json
|
|
36
|
+
{
|
|
37
|
+
"origin": "https://github.com",
|
|
38
|
+
"framework": "react",
|
|
39
|
+
"shadowDom": false,
|
|
40
|
+
"captcha_frequency": "rare",
|
|
41
|
+
"quirks": {
|
|
42
|
+
"cookie_banner": {
|
|
43
|
+
"selector": "#cookie-consent",
|
|
44
|
+
"action": "click .accept-all",
|
|
45
|
+
"appears": "first_visit"
|
|
46
|
+
},
|
|
47
|
+
"rate_limit": {
|
|
48
|
+
"threshold": "60req/min",
|
|
49
|
+
"recovery": "wait 30s"
|
|
50
|
+
}
|
|
51
|
+
},
|
|
52
|
+
"patterns": {
|
|
53
|
+
"login_flow": {
|
|
54
|
+
"name": "login_flow",
|
|
55
|
+
"steps": [
|
|
56
|
+
{ "tool": "browser_navigate", "target": "https://github.com/login" },
|
|
57
|
+
{ "tool": "browser_fill", "target": "#login_field", "value": "{{username}}" },
|
|
58
|
+
{ "tool": "browser_fill", "target": "#password", "value": "{{password}}" },
|
|
59
|
+
{ "tool": "browser_click", "target": "[type=submit]" }
|
|
60
|
+
],
|
|
61
|
+
"success_indicator": "a[aria-label='Homepage']",
|
|
62
|
+
"entry": "/login",
|
|
63
|
+
"avg_duration_ms": 3200,
|
|
64
|
+
"reliability": 0.96,
|
|
65
|
+
"strikes": 0,
|
|
66
|
+
"last_verified": "2026-09-16T08:00:00.000Z",
|
|
67
|
+
"total_executions": 12,
|
|
68
|
+
"successful_executions": 12
|
|
69
|
+
}
|
|
70
|
+
},
|
|
71
|
+
"visitCount": 15,
|
|
72
|
+
"updatedAt": "2026-09-16T08:00:00.000Z"
|
|
73
|
+
}
|
|
74
|
+
```
|
|
75
|
+
|
|
76
|
+
---
|
|
77
|
+
|
|
78
|
+
## The Pattern Compiler
|
|
79
|
+
|
|
80
|
+
When an agent executes an automation flow:
|
|
81
|
+
1. **Trail Capture**: Steps are tracked via the lightweight action trail.
|
|
82
|
+
2. **Selector Stabilization**: Volatile CSS hash classes (`[class*="hash-"]`), positional pseudos (`:nth-child`), and deep anonymous structural chains are filtered out. Only semantic selectors (`id`, `data-testid`, semantic attributes, roles) are persisted.
|
|
83
|
+
3. **Merge-on-Write**: Calling `browser_pattern_learn` updates existing patterns in place. Duplicate calls never create duplicate files or duplicate entries.
|
|
84
|
+
4. **Anti-Spam Guard**: If an incoming pattern is identical to stored disk state, the disk write is skipped entirely.
|
|
85
|
+
|
|
86
|
+
---
|
|
87
|
+
|
|
88
|
+
## Reliability Scoring and 3-Strike Degradation
|
|
89
|
+
|
|
90
|
+
Each pattern tracks a reliability score (`0.0` to `1.0`) computed via Exponentially Weighted Moving Average (EWMA with $\alpha = 0.15$):
|
|
91
|
+
|
|
92
|
+
$$\text{Reliability}_{t} = 0.85 \times \text{Reliability}_{t-1} + 0.15 \times (\text{Success} ? 1 : 0)$$
|
|
93
|
+
|
|
94
|
+
### Decision Thresholds
|
|
95
|
+
|
|
96
|
+
- **Fast-Path ($\ge 0.80$)**: Replay stored steps directly via `browser_burst` — skips exploratory DOM navigation entirely.
|
|
97
|
+
- **Cautious Replay ($0.50 - 0.79$)**: Replay steps, but verify `success_indicator` after critical steps.
|
|
98
|
+
- **Re-Learn ($< 0.50$ or $\ge 3$ consecutive strikes)**: Pattern is flagged `[RE-LEARN NEEDED]`. The agent falls back to fresh DOM exploration, then calls `browser_pattern_learn` to teach the updated steps.
|
|
99
|
+
|
|
100
|
+
---
|
|
101
|
+
|
|
102
|
+
## MCP Tools
|
|
103
|
+
|
|
104
|
+
### `browser_pattern_learn`
|
|
105
|
+
All site memory operations use a single tool. Use `action: "get"` to read a site profile, `action: "learn"` to register a workflow, `action: "record_execution"` to update reliability scores, and `action: "record_quirk"` to store site quirks:
|
|
106
|
+
|
|
107
|
+
```json
|
|
108
|
+
{ "action": "get", "origin": "https://github.com" }
|
|
109
|
+
```
|
|
110
|
+
|
|
111
|
+
```json
|
|
112
|
+
{
|
|
113
|
+
"origin": "https://github.com",
|
|
114
|
+
"action": "learn",
|
|
115
|
+
"name": "login_flow",
|
|
116
|
+
"steps": [
|
|
117
|
+
{ "tool": "browser_click", "target": ".btn-login" },
|
|
118
|
+
{ "tool": "browser_fill", "target": "#login_field", "value": "{{username}}" }
|
|
119
|
+
],
|
|
120
|
+
"success_indicator": "a[aria-label='Homepage']"
|
|
121
|
+
}
|
|
122
|
+
```
|
|
123
|
+
|
|
124
|
+
---
|
|
125
|
+
|
|
126
|
+
## SDK Plugin Integration (`ctx.memory`)
|
|
127
|
+
|
|
128
|
+
Plugin authors can interact with persistent site memory directly via the SDK:
|
|
129
|
+
|
|
130
|
+
```typescript
|
|
131
|
+
import { definePlugin } from "@weavetab/sdk";
|
|
132
|
+
|
|
133
|
+
export default definePlugin({
|
|
134
|
+
name: "custom-site-automator",
|
|
135
|
+
async onLoad(ctx) {
|
|
136
|
+
// Read current profile
|
|
137
|
+
const profile = await ctx.memory?.getSiteProfile("https://github.com");
|
|
138
|
+
|
|
139
|
+
// Check reliability
|
|
140
|
+
const reliability = await ctx.memory?.getReliability("https://github.com", "login_flow");
|
|
141
|
+
if (reliability && reliability >= 0.8) {
|
|
142
|
+
ctx.logger.info("Fast-path ready for login_flow");
|
|
143
|
+
}
|
|
144
|
+
|
|
145
|
+
// Teach a new pattern
|
|
146
|
+
await ctx.memory?.learnPattern("https://github.com", "quick_search", {
|
|
147
|
+
steps: [{ tool: "browser_fill", target: "input.header-search-input", value: "test" }]
|
|
148
|
+
});
|
|
149
|
+
}
|
|
150
|
+
});
|
|
151
|
+
```
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: "Skills Ecosystem"
|
|
3
|
+
description: "Drop-in agent skills and recipes from @weavetab/skills."
|
|
4
|
+
product: mcp
|
|
5
|
+
section: skills-ecosystem
|
|
6
|
+
icon: BrainCircuit
|
|
7
|
+
slug: skills-overview
|
|
8
|
+
---
|
|
9
|
+
|
|
10
|
+
# Weavetab Skills Ecosystem
|
|
11
|
+
|
|
12
|
+
The **`@weavetab/skills`** package provides drop-in operational directives and behavior skills for AI agents (Claude, Cursor, Windsurf, Copilot, Antigravity).
|
|
13
|
+
|
|
14
|
+
## Interactive Skills Installer
|
|
15
|
+
|
|
16
|
+
```bash
|
|
17
|
+
npx -y @weavetab/skills@latest
|
|
18
|
+
```
|
|
19
|
+
|
|
20
|
+
The interactive installer detects your IDE (`.agents`, `.cursorrules`, `.clinerules`, `.roocode`, etc.) and injects selected skills directly without workspace clutter.
|
|
21
|
+
|
|
22
|
+
---
|
|
23
|
+
|
|
24
|
+
## Available Skills Directory
|
|
25
|
+
|
|
26
|
+
- **CAPTCHA Evasion** (`general/captcha-evasion.md`) — Heuristics for resolving bot challenges and checkbox modals.
|
|
27
|
+
- **Context Awareness** (`general/context-awareness.md`) — Deep page analysis and landmark scoping.
|
|
28
|
+
- **Cookie Consent Banners** (`general/cookie-consent.md`) — Auto-dismissing GDPR and overlay modals.
|
|
29
|
+
- **Data Extraction** (`general/data-extraction.md`) — CSS & XPath tabular scraping.
|
|
30
|
+
- **Dynamic Interaction** (`general/dynamic-interaction.md`) — Precision hover, drag-and-drop, and flyout menus.
|
|
31
|
+
- **Error Recovery** (`general/error-recovery.md`) — Resolving 404s, stale elements, and network timeouts.
|
|
32
|
+
- **File Upload** (`general/file-upload.md`) — Direct CDP file attachments.
|
|
33
|
+
- **Form Filling** (`general/form-filling.md`) — Multi-field smart form batch completion.
|
|
34
|
+
- **Infinite Scroll** (`general/infinite-scroll.md`) — Pagination and dynamic lazy loading.
|
|
35
|
+
- **SPA Navigation** (`general/spa-navigation.md`) — Client-side route changes in React/Vue/Angular.
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: "Automation Recipes"
|
|
3
|
+
description: "Step-by-step recipes for common browser automation challenges."
|
|
4
|
+
product: mcp
|
|
5
|
+
section: skills-ecosystem
|
|
6
|
+
icon: BookOpenCheck
|
|
7
|
+
slug: skills-recipes
|
|
8
|
+
---
|
|
9
|
+
|
|
10
|
+
# Automation Skills Recipes
|
|
11
|
+
|
|
12
|
+
## Recipe 1: Handling Dynamic Cookie Consent Overlays
|
|
13
|
+
|
|
14
|
+
```markdown
|
|
15
|
+
1. Run browser_find({ query: "Accept all cookies" })
|
|
16
|
+
2. If found, call browser_click({ label: "Accept all" })
|
|
17
|
+
3. Wait for stability: browser_wait({ for: "stable", timeout: 2000 })
|
|
18
|
+
4. Read page with delta: browser_map({ delta: true, prune: true })
|
|
19
|
+
```
|
|
20
|
+
|
|
21
|
+
---
|
|
22
|
+
|
|
23
|
+
## Recipe 2: Autonomous Form Completion
|
|
24
|
+
|
|
25
|
+
```markdown
|
|
26
|
+
1. Map the form: browser_map({ scope: "form", query: "input" })
|
|
27
|
+
2. Batch fill fields in one round-trip:
|
|
28
|
+
browser_fill({
|
|
29
|
+
fields: [
|
|
30
|
+
{ ref: "w:12", value: "alex@company.com" },
|
|
31
|
+
{ ref: "w:14", value: "United States" }
|
|
32
|
+
],
|
|
33
|
+
submit: "w:16"
|
|
34
|
+
})
|
|
35
|
+
3. Wait for submission: browser_wait({ for: "network" })
|
|
36
|
+
```
|