@weavetab/skills 1.0.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/README.md +108 -50
- package/ROUTER.md +43 -0
- package/bin/cli.js +232 -132
- package/browser/dom-strategy.md +119 -0
- package/browser/form-automation.md +87 -0
- package/browser/interaction-pipeline.md +216 -0
- package/browser/tab-and-window.md +136 -0
- package/desktop/desktop-targeting.md +85 -0
- package/desktop/electron-discovery.md +115 -0
- package/developer/github-forensics.md +74 -0
- package/dist/bundled/weavetab-all.md +1905 -0
- package/dist/bundled/weavetab-browser.md +501 -0
- package/dist/bundled/weavetab-desktop.md +176 -0
- package/dist/bundled/weavetab-developer.md +67 -0
- package/dist/bundled/weavetab-documents.md +142 -0
- package/dist/bundled/weavetab-memory.md +359 -0
- package/dist/bundled/weavetab-network-and-perf.md +223 -0
- package/dist/bundled/weavetab-plugins.md +78 -0
- package/dist/bundled/weavetab-resilience.md +216 -0
- package/dist/bundled/weavetab-security.md +87 -0
- package/dist/granular/browser_dom-strategy.md +119 -0
- package/dist/granular/browser_form-automation.md +87 -0
- package/dist/granular/browser_interaction-pipeline.md +216 -0
- package/dist/granular/browser_tab-and-window.md +136 -0
- package/dist/granular/desktop_desktop-targeting.md +85 -0
- package/dist/granular/desktop_electron-discovery.md +115 -0
- package/dist/granular/developer_github-forensics.md +74 -0
- package/dist/granular/documents_canvas-and-visual-capture.md +103 -0
- package/dist/granular/documents_office-document-ingestion.md +63 -0
- package/dist/granular/memory_selector-memory-system.md +127 -0
- package/dist/granular/memory_session-trail.md +95 -0
- package/dist/granular/memory_site-learning.md +180 -0
- package/dist/granular/network-and-perf_device-and-environment.md +87 -0
- package/dist/granular/network-and-perf_network-intercept-and-mock.md +84 -0
- package/dist/granular/network-and-perf_performance-and-vitals.md +84 -0
- package/dist/granular/plugins_hooks-and-overrides.md +36 -0
- package/dist/granular/plugins_plugin-runtime.md +60 -0
- package/dist/granular/resilience_loop-breaker.md +67 -0
- package/dist/granular/resilience_session-time-travel.md +131 -0
- package/dist/granular/resilience_stale-ref-recovery.md +53 -0
- package/dist/granular/security_rbac-and-policies.md +47 -0
- package/dist/granular/security_secret-containment-protocol.md +59 -0
- package/documents/canvas-and-visual-capture.md +103 -0
- package/documents/office-document-ingestion.md +63 -0
- package/evals/evaluator.js +146 -0
- package/evals/scenarios.json +238 -0
- package/memory/selector-memory-system.md +127 -0
- package/memory/session-trail.md +95 -0
- package/memory/site-learning.md +180 -0
- package/network-and-perf/device-and-environment.md +87 -0
- package/network-and-perf/network-intercept-and-mock.md +84 -0
- package/network-and-perf/performance-and-vitals.md +84 -0
- package/package.json +73 -42
- package/plugins/hooks-and-overrides.md +36 -0
- package/plugins/plugin-runtime.md +60 -0
- package/resilience/loop-breaker.md +67 -0
- package/resilience/session-time-travel.md +131 -0
- package/resilience/stale-ref-recovery.md +53 -0
- package/security/rbac-and-policies.md +47 -0
- package/security/secret-containment-protocol.md +59 -0
- package/skills.json +431 -308
- package/src/api.js +239 -128
- package/.github/FUNDING.yml +0 -2
- package/.github/ISSUE_TEMPLATE/bug_report.md +0 -28
- package/.github/ISSUE_TEMPLATE/skill_request.md +0 -24
- package/.github/PULL_REQUEST_TEMPLATE.md +0 -23
- package/CONTRIBUTING.md +0 -34
- package/SECURITY.md +0 -26
- package/advanced/README.md +0 -2
- package/automation/README.md +0 -2
- package/general/captcha-evasion.md +0 -13
- package/general/context-awareness.md +0 -13
- package/general/cookie-consent.md +0 -13
- package/general/data-extraction.md +0 -13
- package/general/dynamic-interaction.md +0 -13
- package/general/error-recovery.md +0 -13
- package/general/file-upload.md +0 -13
- package/general/form-filling.md +0 -16
- package/general/guardrails.md +0 -13
- package/general/iframe-handling.md +0 -13
- package/general/infinite-scroll.md +0 -13
- package/general/login-flow.md +0 -16
- package/general/multi-tab-management.md +0 -13
- package/general/spa-navigation.md +0 -13
- package/general/table-scraping.md +0 -13
- package/scripts/build.js +0 -48
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
---
|
|
2
|
+
id: device-and-environment
|
|
3
|
+
domain: network-and-perf
|
|
4
|
+
triggers:
|
|
5
|
+
- "emulate device"
|
|
6
|
+
- "mobile view"
|
|
7
|
+
- "throttle network"
|
|
8
|
+
- "geolocation override"
|
|
9
|
+
- "user agent"
|
|
10
|
+
- "responsive testing"
|
|
11
|
+
tools:
|
|
12
|
+
- "browser_emulate"
|
|
13
|
+
weavetab: ">=2.5.0-beta.4"
|
|
14
|
+
---
|
|
15
|
+
|
|
16
|
+
# Device Emulation & Environment Simulation
|
|
17
|
+
|
|
18
|
+
Auditing mobile responsive layouts, testing geographic restrictions, and simulating degraded network conditions can all be accomplished with `browser_emulate`.
|
|
19
|
+
|
|
20
|
+
---
|
|
21
|
+
|
|
22
|
+
## 1. Device Presets & Viewport Simulation
|
|
23
|
+
|
|
24
|
+
Switch from desktop to realistic mobile hardware profiles:
|
|
25
|
+
|
|
26
|
+
```json
|
|
27
|
+
{
|
|
28
|
+
"device": "iPhone 15 Pro",
|
|
29
|
+
"orientation": "portrait"
|
|
30
|
+
}
|
|
31
|
+
```
|
|
32
|
+
|
|
33
|
+
Or configure custom screen geometries:
|
|
34
|
+
|
|
35
|
+
```json
|
|
36
|
+
{
|
|
37
|
+
"viewport": {
|
|
38
|
+
"width": 393,
|
|
39
|
+
"height": 852,
|
|
40
|
+
"deviceScaleFactor": 3,
|
|
41
|
+
"isMobile": true,
|
|
42
|
+
"hasTouch": true
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
```
|
|
46
|
+
|
|
47
|
+
---
|
|
48
|
+
|
|
49
|
+
## 2. Network Throttling Simulation
|
|
50
|
+
|
|
51
|
+
Verify how web applications degrade under poor connectivity:
|
|
52
|
+
|
|
53
|
+
```json
|
|
54
|
+
{
|
|
55
|
+
"network": {
|
|
56
|
+
"offline": false,
|
|
57
|
+
"downloadThroughput": 1024 * 500, // 500 kb/s (Slow 3G)
|
|
58
|
+
"uploadThroughput": 1024 * 250,
|
|
59
|
+
"latency": 400 // ms
|
|
60
|
+
}
|
|
61
|
+
}
|
|
62
|
+
```
|
|
63
|
+
|
|
64
|
+
---
|
|
65
|
+
|
|
66
|
+
## 3. Geolocation & Timezone Overrides
|
|
67
|
+
|
|
68
|
+
Bypass localized IP redirects or verify localized content rendering:
|
|
69
|
+
|
|
70
|
+
```json
|
|
71
|
+
{
|
|
72
|
+
"geolocation": {
|
|
73
|
+
"latitude": 37.7749,
|
|
74
|
+
"longitude": -122.4194,
|
|
75
|
+
"accuracy": 100
|
|
76
|
+
},
|
|
77
|
+
"timezoneId": "America/Los_Angeles",
|
|
78
|
+
"locale": "en-US"
|
|
79
|
+
}
|
|
80
|
+
```
|
|
81
|
+
|
|
82
|
+
To reset all overrides back to default host system parameters:
|
|
83
|
+
```json
|
|
84
|
+
{
|
|
85
|
+
"reset": true
|
|
86
|
+
}
|
|
87
|
+
```
|
|
@@ -0,0 +1,84 @@
|
|
|
1
|
+
---
|
|
2
|
+
id: network-intercept-and-mock
|
|
3
|
+
domain: network-and-perf
|
|
4
|
+
triggers:
|
|
5
|
+
- "mock api"
|
|
6
|
+
- "intercept network"
|
|
7
|
+
- "stub request"
|
|
8
|
+
- "inspect tls"
|
|
9
|
+
- "ssl certificate"
|
|
10
|
+
- "network waterfall"
|
|
11
|
+
tools:
|
|
12
|
+
- "browser_network_intercept"
|
|
13
|
+
weavetab: ">=2.5.0-beta.4"
|
|
14
|
+
---
|
|
15
|
+
|
|
16
|
+
# Network Interception, Mocking & TLS Forensics
|
|
17
|
+
|
|
18
|
+
Autonomous testing and debugging often require simulating backend error states (e.g. 500 Internal Server Error, 429 Rate Limit), stubbing third-party analytics, or verifying TLS/SSL certificates.
|
|
19
|
+
|
|
20
|
+
`browser_network_intercept` provides fine-grained CDP request and response modification.
|
|
21
|
+
|
|
22
|
+
---
|
|
23
|
+
|
|
24
|
+
## 1. Mocking API Responses
|
|
25
|
+
|
|
26
|
+
Intercept outgoing HTTP requests matching a URL pattern and return custom mock data:
|
|
27
|
+
|
|
28
|
+
```json
|
|
29
|
+
{
|
|
30
|
+
"pattern": "*/api/v1/user/profile",
|
|
31
|
+
"response": {
|
|
32
|
+
"status": 200,
|
|
33
|
+
"headers": {
|
|
34
|
+
"Content-Type": "application/json"
|
|
35
|
+
},
|
|
36
|
+
"body": "{\"id\": \"usr_test\", \"role\": \"admin\", \"credits\": 9999}"
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
```
|
|
40
|
+
|
|
41
|
+
---
|
|
42
|
+
|
|
43
|
+
## 2. Blocking Unnecessary Traffic & Trackers
|
|
44
|
+
|
|
45
|
+
Accelerate page loads and eliminate token bloat by aborting non-essential requests:
|
|
46
|
+
|
|
47
|
+
```json
|
|
48
|
+
{
|
|
49
|
+
"pattern": "*google-analytics.com*",
|
|
50
|
+
"action": "abort",
|
|
51
|
+
"errorReason": "BlockedByClient"
|
|
52
|
+
}
|
|
53
|
+
```
|
|
54
|
+
|
|
55
|
+
---
|
|
56
|
+
|
|
57
|
+
## 3. TLS / SSL Forensics & Timing Waterfalls
|
|
58
|
+
|
|
59
|
+
Extract cryptographic handshake metadata, cipher suites, expiration dates, and microsecond network waterfalls (DNS lookup, TCP connect, SSL handshake, TTFB):
|
|
60
|
+
|
|
61
|
+
```json
|
|
62
|
+
{
|
|
63
|
+
"action": "auditTls",
|
|
64
|
+
"url": "https://weavetab.pages.dev"
|
|
65
|
+
}
|
|
66
|
+
```
|
|
67
|
+
|
|
68
|
+
### Response Example:
|
|
69
|
+
```json
|
|
70
|
+
{
|
|
71
|
+
"security": {
|
|
72
|
+
"protocol": "TLS 1.3",
|
|
73
|
+
"cipher": "AES_128_GCM",
|
|
74
|
+
"issuer": "Let's Encrypt",
|
|
75
|
+
"validTo": "2026-11-15T00:00:00.000Z"
|
|
76
|
+
},
|
|
77
|
+
"waterfall": {
|
|
78
|
+
"dnsMs": 1.4,
|
|
79
|
+
"tcpMs": 3.2,
|
|
80
|
+
"sslMs": 4.1,
|
|
81
|
+
"ttfbMs": 12.8
|
|
82
|
+
}
|
|
83
|
+
}
|
|
84
|
+
```
|
|
@@ -0,0 +1,84 @@
|
|
|
1
|
+
---
|
|
2
|
+
id: performance-and-vitals
|
|
3
|
+
domain: network-and-perf
|
|
4
|
+
triggers:
|
|
5
|
+
- "measure performance"
|
|
6
|
+
- "core web vitals"
|
|
7
|
+
- "lcp"
|
|
8
|
+
- "cls"
|
|
9
|
+
- "fcp"
|
|
10
|
+
- "wait condition"
|
|
11
|
+
- "page slow"
|
|
12
|
+
tools:
|
|
13
|
+
- "browser_performance"
|
|
14
|
+
- "browser_wait"
|
|
15
|
+
weavetab: ">=2.5.0-beta.4"
|
|
16
|
+
---
|
|
17
|
+
|
|
18
|
+
# Performance Forensics & Core Web Vitals
|
|
19
|
+
|
|
20
|
+
Optimizing agent execution and auditing client performance requires objective metrics rather than arbitrary sleep timers.
|
|
21
|
+
|
|
22
|
+
---
|
|
23
|
+
|
|
24
|
+
## 1. Core Web Vitals Auditing (`browser_performance`)
|
|
25
|
+
|
|
26
|
+
Retrieve Google Core Web Vitals, memory consumption, and frame rendering bottlenecks directly from the Chromium engine:
|
|
27
|
+
|
|
28
|
+
```json
|
|
29
|
+
{
|
|
30
|
+
"metrics": ["vitals", "memory", "navigationTiming"]
|
|
31
|
+
}
|
|
32
|
+
```
|
|
33
|
+
|
|
34
|
+
### Response Example:
|
|
35
|
+
```json
|
|
36
|
+
{
|
|
37
|
+
"vitals": {
|
|
38
|
+
"fcp": 320,
|
|
39
|
+
"lcp": 780,
|
|
40
|
+
"cls": 0.012,
|
|
41
|
+
"fid": 8,
|
|
42
|
+
"inp": 45
|
|
43
|
+
},
|
|
44
|
+
"memory": {
|
|
45
|
+
"jsHeapUsedSizeMb": 42.1,
|
|
46
|
+
"jsHeapTotalSizeMb": 68.4
|
|
47
|
+
}
|
|
48
|
+
}
|
|
49
|
+
```
|
|
50
|
+
|
|
51
|
+
---
|
|
52
|
+
|
|
53
|
+
## 2. Deterministic Synchronization (`browser_wait`)
|
|
54
|
+
|
|
55
|
+
> [!WARNING]
|
|
56
|
+
> NEVER call arbitrary fixed sleep timers (e.g. `sleep 5000`). Fixed sleeps waste user time and still fail when network latency spikes.
|
|
57
|
+
|
|
58
|
+
Always synchronize with deterministic browser conditions:
|
|
59
|
+
|
|
60
|
+
### Wait for Network Idle:
|
|
61
|
+
```json
|
|
62
|
+
{
|
|
63
|
+
"condition": "network_idle",
|
|
64
|
+
"timeout": 10000
|
|
65
|
+
}
|
|
66
|
+
```
|
|
67
|
+
|
|
68
|
+
### Wait for DOM Mutation Stability:
|
|
69
|
+
```json
|
|
70
|
+
{
|
|
71
|
+
"condition": "dom_stable",
|
|
72
|
+
"duration": 500,
|
|
73
|
+
"timeout": 10000
|
|
74
|
+
}
|
|
75
|
+
```
|
|
76
|
+
|
|
77
|
+
### Wait for a Specific Element to Appear:
|
|
78
|
+
```json
|
|
79
|
+
{
|
|
80
|
+
"condition": "element_visible",
|
|
81
|
+
"selector": "[data-testid=\"checkout-complete\"]",
|
|
82
|
+
"timeout": 15000
|
|
83
|
+
}
|
|
84
|
+
```
|
package/package.json
CHANGED
|
@@ -1,42 +1,73 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "@weavetab/skills",
|
|
3
|
-
"version": "
|
|
4
|
-
"description": "Supercharge your AI Agents with Weavetab MCP Skills.
|
|
5
|
-
"author":
|
|
6
|
-
|
|
7
|
-
"
|
|
8
|
-
"url": "https://
|
|
9
|
-
},
|
|
10
|
-
"
|
|
11
|
-
"
|
|
12
|
-
"
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
"
|
|
16
|
-
"
|
|
17
|
-
"
|
|
18
|
-
"
|
|
19
|
-
"
|
|
20
|
-
"
|
|
21
|
-
"
|
|
22
|
-
"
|
|
23
|
-
"
|
|
24
|
-
"
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
"
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
"
|
|
40
|
-
"
|
|
41
|
-
|
|
42
|
-
|
|
1
|
+
{
|
|
2
|
+
"name": "@weavetab/skills",
|
|
3
|
+
"version": "2.5.0-beta.4",
|
|
4
|
+
"description": "Supercharge your AI Agents with Weavetab MCP Skills. Domain-driven agent intelligence for Antigravity, Cursor, Cline, Windsurf, and more.",
|
|
5
|
+
"author": {
|
|
6
|
+
"name": "fy2ne",
|
|
7
|
+
"email": "hello@fy2ne.me",
|
|
8
|
+
"url": "https://fy2ne.me"
|
|
9
|
+
},
|
|
10
|
+
"license": "MIT",
|
|
11
|
+
"files": [
|
|
12
|
+
"bin",
|
|
13
|
+
"src",
|
|
14
|
+
"dist",
|
|
15
|
+
"ROUTER.md",
|
|
16
|
+
"browser",
|
|
17
|
+
"desktop",
|
|
18
|
+
"memory",
|
|
19
|
+
"resilience",
|
|
20
|
+
"security",
|
|
21
|
+
"plugins",
|
|
22
|
+
"network-and-perf",
|
|
23
|
+
"documents",
|
|
24
|
+
"developer",
|
|
25
|
+
"evals",
|
|
26
|
+
"skills.json"
|
|
27
|
+
],
|
|
28
|
+
"repository": {
|
|
29
|
+
"type": "git",
|
|
30
|
+
"url": "git+https://github.com/Weavetab/skills.git"
|
|
31
|
+
},
|
|
32
|
+
"homepage": "https://github.com/Weavetab/skills#readme",
|
|
33
|
+
"bugs": {
|
|
34
|
+
"url": "https://github.com/Weavetab/skills/issues"
|
|
35
|
+
},
|
|
36
|
+
"keywords": [
|
|
37
|
+
"weavetab",
|
|
38
|
+
"weavetab-mcp",
|
|
39
|
+
"weavetab-skills",
|
|
40
|
+
"weavetab-plugins",
|
|
41
|
+
"mcp",
|
|
42
|
+
"ai-agent",
|
|
43
|
+
"cursor",
|
|
44
|
+
"cline",
|
|
45
|
+
"antigravity",
|
|
46
|
+
"browser-automation",
|
|
47
|
+
"agent-skills",
|
|
48
|
+
"openclaw",
|
|
49
|
+
"plugins",
|
|
50
|
+
"skills",
|
|
51
|
+
"agentic"
|
|
52
|
+
],
|
|
53
|
+
"peerDependencies": {
|
|
54
|
+
"@weavetab/mcp": "2.5.0-beta.4"
|
|
55
|
+
},
|
|
56
|
+
"peerDependenciesMeta": {
|
|
57
|
+
"@weavetab/mcp": {
|
|
58
|
+
"optional": true
|
|
59
|
+
}
|
|
60
|
+
},
|
|
61
|
+
"main": "./src/api.js",
|
|
62
|
+
"bin": {
|
|
63
|
+
"skills": "bin/cli.js"
|
|
64
|
+
},
|
|
65
|
+
"scripts": {
|
|
66
|
+
"build": "node scripts/build.js",
|
|
67
|
+
"test": "node evals/evaluator.js"
|
|
68
|
+
},
|
|
69
|
+
"dependencies": {
|
|
70
|
+
"@inquirer/prompts": "^7.3.1",
|
|
71
|
+
"yaml": "^2.3.4"
|
|
72
|
+
}
|
|
73
|
+
}
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
---
|
|
2
|
+
id: hooks-and-overrides
|
|
3
|
+
domain: plugins
|
|
4
|
+
triggers:
|
|
5
|
+
- "plugin hooks"
|
|
6
|
+
- "before tool call"
|
|
7
|
+
- "after tool call"
|
|
8
|
+
- "telemetry interception"
|
|
9
|
+
- "sdk hooks"
|
|
10
|
+
tools:
|
|
11
|
+
- "list_plugins"
|
|
12
|
+
weavetab: ">=2.5.0-beta.4"
|
|
13
|
+
---
|
|
14
|
+
|
|
15
|
+
# Plugin Hooks & Lifecycle Overrides
|
|
16
|
+
|
|
17
|
+
Plugins built with `@weavetab/sdk` register lifecycle hooks that run before and after tool executions. Understanding these hooks helps agents interpret metadata and custom tool responses.
|
|
18
|
+
|
|
19
|
+
---
|
|
20
|
+
|
|
21
|
+
## 1. Supported Plugin Hooks
|
|
22
|
+
|
|
23
|
+
1. **`beforeToolCall(toolName, args)`**:
|
|
24
|
+
- Validates arguments against custom enterprise schemas.
|
|
25
|
+
- Injects tenant IDs, authentication headers, or proxy routing.
|
|
26
|
+
2. **`afterToolCall(toolName, result, durationMs)`**:
|
|
27
|
+
- Emits OpenTelemetry metrics and timing waterfalls to external APM platforms.
|
|
28
|
+
- Enriches return objects with contextual metadata.
|
|
29
|
+
3. **`onNavigate(url, targetId)`**:
|
|
30
|
+
- Triggers automated cookie injection or session setup upon page navigation.
|
|
31
|
+
|
|
32
|
+
---
|
|
33
|
+
|
|
34
|
+
## 2. Agent Operational Awareness
|
|
35
|
+
|
|
36
|
+
When plugins are active, tool return payloads may include an optional `_pluginMetadata` object containing trace IDs, custom metrics, or security audit timestamps. Agents should treat this object as informational telemetry.
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
---
|
|
2
|
+
id: plugin-runtime
|
|
3
|
+
domain: plugins
|
|
4
|
+
triggers:
|
|
5
|
+
- "list plugins"
|
|
6
|
+
- "load plugin"
|
|
7
|
+
- "install plugin"
|
|
8
|
+
- "weavetab plugin"
|
|
9
|
+
- "extend mcp"
|
|
10
|
+
tools:
|
|
11
|
+
- "list_plugins"
|
|
12
|
+
- "load_plugin"
|
|
13
|
+
weavetab: ">=2.5.0-beta.4"
|
|
14
|
+
---
|
|
15
|
+
|
|
16
|
+
# Plugin Runtime: Dynamic Extension Loading
|
|
17
|
+
|
|
18
|
+
Weavetab features an extensible plugin architecture powered by `@weavetab/sdk`. Agents can query loaded extensions and dynamically load community or official plugins into the live MCP runtime without restarting the server.
|
|
19
|
+
|
|
20
|
+
---
|
|
21
|
+
|
|
22
|
+
## 1. Inspecting Active Plugins (`list_plugins`)
|
|
23
|
+
|
|
24
|
+
Discover all installed plugins, their versions, and the tools or hooks they expose:
|
|
25
|
+
|
|
26
|
+
```json
|
|
27
|
+
{}
|
|
28
|
+
```
|
|
29
|
+
|
|
30
|
+
### Response Example:
|
|
31
|
+
```json
|
|
32
|
+
{
|
|
33
|
+
"plugins": [
|
|
34
|
+
{
|
|
35
|
+
"name": "@weavetab/plugin-recaptcha-solver",
|
|
36
|
+
"version": "1.2.0",
|
|
37
|
+
"status": "active",
|
|
38
|
+
"toolsProvided": ["captcha_solve_token"],
|
|
39
|
+
"hooks": ["beforeToolCall"]
|
|
40
|
+
}
|
|
41
|
+
]
|
|
42
|
+
}
|
|
43
|
+
```
|
|
44
|
+
|
|
45
|
+
---
|
|
46
|
+
|
|
47
|
+
## 2. Dynamic Runtime Loading (`load_plugin`)
|
|
48
|
+
|
|
49
|
+
Load a verified plugin package into the active runtime session:
|
|
50
|
+
|
|
51
|
+
```json
|
|
52
|
+
{
|
|
53
|
+
"name": "@weavetab/plugin-datadog-tracer"
|
|
54
|
+
}
|
|
55
|
+
```
|
|
56
|
+
|
|
57
|
+
### Plugin Verification Guarantees:
|
|
58
|
+
- Plugins must implement the `@weavetab/sdk` standard interface.
|
|
59
|
+
- Loaded tools become immediately callable by the agent in subsequent turns.
|
|
60
|
+
- If an agent is in the `viewer` RBAC tier, `load_plugin` is rejected with `PERMISSION_DENIED`.
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
---
|
|
2
|
+
id: loop-breaker
|
|
3
|
+
domain: resilience
|
|
4
|
+
triggers:
|
|
5
|
+
- "loop detected"
|
|
6
|
+
- "stuck in loop"
|
|
7
|
+
- "reset loop counter"
|
|
8
|
+
- "captcha detected"
|
|
9
|
+
- "hcaptcha"
|
|
10
|
+
- "recaptcha"
|
|
11
|
+
tools:
|
|
12
|
+
- "browser_map"
|
|
13
|
+
- "browser_console"
|
|
14
|
+
- "browser_captcha"
|
|
15
|
+
weavetab: ">=2.5.0-beta.4"
|
|
16
|
+
---
|
|
17
|
+
|
|
18
|
+
# Loop Breaker & CAPTCHA Escalation Protocol
|
|
19
|
+
|
|
20
|
+
Agents can get trapped in repetitive click loops when a button does not advance the state (e.g. failing silent validation, unhandled reCAPTCHA challenges, or modals swallowing events). Weavetab actively monitors repetitive patterns and provides circuit breakers.
|
|
21
|
+
|
|
22
|
+
---
|
|
23
|
+
|
|
24
|
+
## 1. Loop Detection & Strike Reset (`browser_map`)
|
|
25
|
+
|
|
26
|
+
Weavetab tracks the sequence of identical or near-identical tool invocations. If an agent calls `browser_click` or `browser_type` on the same selector or ref repeatedly without URL or major DOM mutations, the server raises a `STUCK_LOOP_WARNING`.
|
|
27
|
+
|
|
28
|
+
### How to Break the Loop:
|
|
29
|
+
1. **Analyze Why the Action Failed**: Check `browser_console` for JavaScript errors:
|
|
30
|
+
```json
|
|
31
|
+
{ "action": "read" }
|
|
32
|
+
```
|
|
33
|
+
Or use `browser_map` to see if a validation banner or unhandled modal appeared.
|
|
34
|
+
2. **Reset the Circuit Breaker**:
|
|
35
|
+
- Re-map with `force: true` to bypass the map skip guard, refresh the DOM view, and automatically clear loop strikes:
|
|
36
|
+
```json
|
|
37
|
+
{ "force": true }
|
|
38
|
+
```
|
|
39
|
+
|
|
40
|
+
---
|
|
41
|
+
|
|
42
|
+
## 2. CAPTCHA Handling Protocol (`browser_captcha`)
|
|
43
|
+
|
|
44
|
+
When an automated flow is blocked by Cloudflare Turnstile, Google reCAPTCHA, or hCaptcha, do NOT repeatedly click random coordinates.
|
|
45
|
+
|
|
46
|
+
Invoke `browser_captcha` to analyze and manage the challenge:
|
|
47
|
+
|
|
48
|
+
```json
|
|
49
|
+
{
|
|
50
|
+
"action": "detect"
|
|
51
|
+
}
|
|
52
|
+
```
|
|
53
|
+
|
|
54
|
+
### Response Example:
|
|
55
|
+
```json
|
|
56
|
+
{
|
|
57
|
+
"detected": true,
|
|
58
|
+
"type": "turnstile",
|
|
59
|
+
"provider": "cloudflare",
|
|
60
|
+
"interactive": true,
|
|
61
|
+
"ref": "w:99"
|
|
62
|
+
}
|
|
63
|
+
```
|
|
64
|
+
|
|
65
|
+
### Action Strategy:
|
|
66
|
+
1. If the challenge is interactive and requires human intervention (e.g. image classification), inform the user cleanly or request human bypass.
|
|
67
|
+
2. If the challenge is a simple checkbox Turnstile widget, pass `"action": "solve"` or click the detected widget ref with `browser_click`.
|
|
@@ -0,0 +1,131 @@
|
|
|
1
|
+
---
|
|
2
|
+
id: session-time-travel
|
|
3
|
+
domain: resilience
|
|
4
|
+
triggers:
|
|
5
|
+
- "time travel"
|
|
6
|
+
- "browser checkpoint"
|
|
7
|
+
- "rollback session"
|
|
8
|
+
- "save state"
|
|
9
|
+
- "restore cookies"
|
|
10
|
+
tools:
|
|
11
|
+
- "browser_checkpoint"
|
|
12
|
+
- "browser_cookies"
|
|
13
|
+
- "browser_storage"
|
|
14
|
+
weavetab: ">=2.5.0-beta.4"
|
|
15
|
+
---
|
|
16
|
+
|
|
17
|
+
# Session Time-Travel & Instant State Rollback
|
|
18
|
+
|
|
19
|
+
In complex multi-step workflows (e.g. checkout funnels, multi-page configuration wizards, onboarding questionnaires), an error at Step 7 traditionally forces an agent to reload the root URL, re-authenticate, and waste 10+ turns repeating steps.
|
|
20
|
+
|
|
21
|
+
`browser_checkpoint` enables instantaneous time-travel by snapshotting and restoring complete browser session state.
|
|
22
|
+
|
|
23
|
+
---
|
|
24
|
+
|
|
25
|
+
## 1. What a Checkpoint Captures
|
|
26
|
+
|
|
27
|
+
A single named checkpoint atomically preserves:
|
|
28
|
+
- **Cookies**: Full domain cookies including `HttpOnly`, `Secure`, and `SameSite` flags.
|
|
29
|
+
- **Web Storage**: Entire `localStorage` and `sessionStorage` key-value maps.
|
|
30
|
+
- **Navigation State**: Exact page URL, scroll positions (`x`, `y`), and page title.
|
|
31
|
+
|
|
32
|
+
---
|
|
33
|
+
|
|
34
|
+
## 2. Checkpoint Operations
|
|
35
|
+
|
|
36
|
+
### A. Saving a Checkpoint (`save`)
|
|
37
|
+
Create a checkpoint right before undertaking risky, branching, or destructive actions:
|
|
38
|
+
|
|
39
|
+
```json
|
|
40
|
+
{
|
|
41
|
+
"action": "save",
|
|
42
|
+
"name": "pre_checkout_authenticated"
|
|
43
|
+
}
|
|
44
|
+
```
|
|
45
|
+
|
|
46
|
+
### B. Restoring a Checkpoint (`restore`)
|
|
47
|
+
If a downstream step errors out, times out, or hits an invalid state, roll back immediately:
|
|
48
|
+
|
|
49
|
+
```json
|
|
50
|
+
{
|
|
51
|
+
"action": "restore",
|
|
52
|
+
"name": "pre_checkout_authenticated"
|
|
53
|
+
}
|
|
54
|
+
```
|
|
55
|
+
*Latency: ~15ms*. The page navigates back to the checkpoint URL with cookies and storage atomically injected.
|
|
56
|
+
|
|
57
|
+
### C. Listing Checkpoints (`list`)
|
|
58
|
+
Inspect all active checkpoints for the current page target:
|
|
59
|
+
|
|
60
|
+
```json
|
|
61
|
+
{
|
|
62
|
+
"action": "list"
|
|
63
|
+
}
|
|
64
|
+
```
|
|
65
|
+
|
|
66
|
+
### D. Cleaning Up (`delete`)
|
|
67
|
+
Free memory once a workflow has concluded:
|
|
68
|
+
|
|
69
|
+
```json
|
|
70
|
+
{
|
|
71
|
+
"action": "delete",
|
|
72
|
+
"name": "pre_checkout_authenticated"
|
|
73
|
+
}
|
|
74
|
+
```
|
|
75
|
+
|
|
76
|
+
---
|
|
77
|
+
|
|
78
|
+
## 3. High-Leverage Agent Pattern
|
|
79
|
+
|
|
80
|
+
```
|
|
81
|
+
1. Authenticate to Target Portal
|
|
82
|
+
2. browser_checkpoint({ action: "save", name: "auth_ready" })
|
|
83
|
+
3. Attempt automated action sequence (e.g. form filling or testing)
|
|
84
|
+
4. IF error occurs:
|
|
85
|
+
browser_checkpoint({ action: "restore", name: "auth_ready" })
|
|
86
|
+
-> Agent is immediately back at authenticated state without re-login!
|
|
87
|
+
```
|
|
88
|
+
|
|
89
|
+
---
|
|
90
|
+
|
|
91
|
+
## 4. Fine-Grained Cookie Management (`browser_cookies`)
|
|
92
|
+
|
|
93
|
+
Inspect, set, or delete individual browser session cookies without restoring an entire checkpoint:
|
|
94
|
+
|
|
95
|
+
```json
|
|
96
|
+
{
|
|
97
|
+
"action": "get",
|
|
98
|
+
"urls": ["https://example.com"]
|
|
99
|
+
}
|
|
100
|
+
```
|
|
101
|
+
|
|
102
|
+
Or inject an authentication cookie:
|
|
103
|
+
```json
|
|
104
|
+
{
|
|
105
|
+
"action": "set",
|
|
106
|
+
"cookies": [
|
|
107
|
+
{
|
|
108
|
+
"name": "session_token",
|
|
109
|
+
"value": "xyz123",
|
|
110
|
+
"domain": "example.com",
|
|
111
|
+
"httpOnly": true,
|
|
112
|
+
"secure": true
|
|
113
|
+
}
|
|
114
|
+
]
|
|
115
|
+
}
|
|
116
|
+
```
|
|
117
|
+
|
|
118
|
+
---
|
|
119
|
+
|
|
120
|
+
## 5. Web Storage Inspection & Injection (`browser_storage`)
|
|
121
|
+
|
|
122
|
+
Query or clear `localStorage` and `sessionStorage` keys:
|
|
123
|
+
|
|
124
|
+
```json
|
|
125
|
+
{
|
|
126
|
+
"storageType": "localStorage",
|
|
127
|
+
"action": "get",
|
|
128
|
+
"key": "authToken"
|
|
129
|
+
}
|
|
130
|
+
```
|
|
131
|
+
|