rird-ai 2.2.0 → 2.2.2
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/bin/rird +41 -6
- package/package.json +13 -13
- package/postinstall.mjs +14 -30
package/bin/rird
CHANGED
|
@@ -13,6 +13,35 @@ const fs = require("fs")
|
|
|
13
13
|
const path = require("path")
|
|
14
14
|
const os = require("os")
|
|
15
15
|
|
|
16
|
+
// Global error handler for uncaught exceptions
|
|
17
|
+
process.on("uncaughtException", (error) => {
|
|
18
|
+
console.error("")
|
|
19
|
+
console.error("Error [UNCAUGHT_EXCEPTION]: " + (error.message || String(error)))
|
|
20
|
+
console.error("")
|
|
21
|
+
if (error.stack) {
|
|
22
|
+
console.error("Stack trace:")
|
|
23
|
+
console.error(error.stack)
|
|
24
|
+
console.error("")
|
|
25
|
+
}
|
|
26
|
+
console.error("Support reference: RIRD-" + Date.now() + "-" + Math.random().toString(36).substring(2, 8).toUpperCase())
|
|
27
|
+
console.error("")
|
|
28
|
+
process.exit(1)
|
|
29
|
+
})
|
|
30
|
+
|
|
31
|
+
process.on("unhandledRejection", (reason) => {
|
|
32
|
+
console.error("")
|
|
33
|
+
console.error("Error [UNHANDLED_REJECTION]: " + (reason ? reason.message || String(reason) : "Unknown error"))
|
|
34
|
+
console.error("")
|
|
35
|
+
if (reason && typeof reason === "object" && "stack" in reason) {
|
|
36
|
+
console.error("Stack trace:")
|
|
37
|
+
console.error(reason.stack)
|
|
38
|
+
console.error("")
|
|
39
|
+
}
|
|
40
|
+
console.error("Support reference: RIRD-" + Date.now() + "-" + Math.random().toString(36).substring(2, 8).toUpperCase())
|
|
41
|
+
console.error("")
|
|
42
|
+
process.exit(1)
|
|
43
|
+
})
|
|
44
|
+
|
|
16
45
|
// Handle CLI commands before passing to binary
|
|
17
46
|
const command = process.argv[2]
|
|
18
47
|
|
|
@@ -67,7 +96,6 @@ if (command === "upgrade" || command === "update") {
|
|
|
67
96
|
{ stdio: "inherit", shell: true }
|
|
68
97
|
)
|
|
69
98
|
} else {
|
|
70
|
-
// Fallback to curl for Unix/macOS if npm is missing
|
|
71
99
|
console.log("Running: curl -fsSL https://rird.ai/install.sh | bash")
|
|
72
100
|
result = childProcess.spawnSync(
|
|
73
101
|
"bash",
|
|
@@ -77,8 +105,13 @@ if (command === "upgrade" || command === "update") {
|
|
|
77
105
|
}
|
|
78
106
|
|
|
79
107
|
if (result.error || result.status !== 0) {
|
|
80
|
-
console.error("
|
|
81
|
-
|
|
108
|
+
console.error("")
|
|
109
|
+
console.error("Error [INSTALLATION_ERROR]: Upgrade failed")
|
|
110
|
+
console.error("Suggestion: Ensure you have npm installed and internet connectivity")
|
|
111
|
+
console.error("")
|
|
112
|
+
console.error("Manual fix: npm install -g rird-ai@latest")
|
|
113
|
+
console.error("")
|
|
114
|
+
process.exit(500)
|
|
82
115
|
}
|
|
83
116
|
process.exit(0)
|
|
84
117
|
}
|
|
@@ -93,12 +126,14 @@ if (command === "activate") {
|
|
|
93
126
|
console.log("")
|
|
94
127
|
|
|
95
128
|
if (!key || key.length < 10) {
|
|
96
|
-
console.error("
|
|
97
|
-
console.
|
|
129
|
+
console.error("")
|
|
130
|
+
console.error("Error [LICENSE_ERROR]: Invalid license key format")
|
|
131
|
+
console.error("Suggestion: License key must be at least 10 characters")
|
|
132
|
+
console.error("")
|
|
98
133
|
console.log(" Usage: rird activate YOUR_LICENSE_KEY")
|
|
99
134
|
console.log(" Get your key at: https://rird.ai")
|
|
100
135
|
console.log("")
|
|
101
|
-
process.exit(
|
|
136
|
+
process.exit(401)
|
|
102
137
|
}
|
|
103
138
|
|
|
104
139
|
const rirdHome = process.env.RIRD_HOME || path.join(os.homedir(), ".rird")
|
package/package.json
CHANGED
|
@@ -1,24 +1,24 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "rird-ai",
|
|
3
|
-
"version": "2.2.
|
|
3
|
+
"version": "2.2.2",
|
|
4
4
|
"description": "AI agent for browser automation and computer use",
|
|
5
5
|
"bin": {
|
|
6
|
-
"rird": "
|
|
6
|
+
"rird": "bin/rird"
|
|
7
7
|
},
|
|
8
8
|
"scripts": {
|
|
9
9
|
"postinstall": "node ./postinstall.mjs"
|
|
10
10
|
},
|
|
11
11
|
"optionalDependencies": {
|
|
12
|
-
"rird-linux-arm64": "2.2.
|
|
13
|
-
"rird-linux-x64": "2.2.
|
|
14
|
-
"rird-linux-x64-baseline": "2.2.
|
|
15
|
-
"rird-linux-arm64-musl": "2.2.
|
|
16
|
-
"rird-linux-x64-musl": "2.2.
|
|
17
|
-
"rird-linux-x64-baseline-musl": "2.2.
|
|
18
|
-
"rird-darwin-arm64": "2.2.
|
|
19
|
-
"rird-darwin-x64": "2.2.
|
|
20
|
-
"rird-darwin-x64-baseline": "2.2.
|
|
21
|
-
"rird-windows-x64": "2.2.
|
|
22
|
-
"rird-windows-x64-baseline": "2.2.
|
|
12
|
+
"rird-linux-arm64": "2.2.2",
|
|
13
|
+
"rird-linux-x64": "2.2.2",
|
|
14
|
+
"rird-linux-x64-baseline": "2.2.2",
|
|
15
|
+
"rird-linux-arm64-musl": "2.2.2",
|
|
16
|
+
"rird-linux-x64-musl": "2.2.2",
|
|
17
|
+
"rird-linux-x64-baseline-musl": "2.2.2",
|
|
18
|
+
"rird-darwin-arm64": "2.2.2",
|
|
19
|
+
"rird-darwin-x64": "2.2.2",
|
|
20
|
+
"rird-darwin-x64-baseline": "2.2.2",
|
|
21
|
+
"rird-windows-x64": "2.2.2",
|
|
22
|
+
"rird-windows-x64-baseline": "2.2.2"
|
|
23
23
|
}
|
|
24
24
|
}
|
package/postinstall.mjs
CHANGED
|
@@ -311,28 +311,18 @@ function createConfig(pythonCmd) {
|
|
|
311
311
|
"",
|
|
312
312
|
"=== RESEARCH STRATEGY ===",
|
|
313
313
|
"For ANY task that asks to 'find URLs', 'output URLs', 'list profiles', or 'get X items':",
|
|
314
|
-
"1. ALWAYS START with
|
|
315
|
-
"2. Only fall back to
|
|
314
|
+
"1. ALWAYS START with web search - it is instant.",
|
|
315
|
+
"2. Only fall back to Chrome if search fails or task requires interaction (login, forms).",
|
|
316
316
|
"",
|
|
317
317
|
"=== TOOL PRIORITY ===",
|
|
318
|
-
"1.
|
|
319
|
-
"2.
|
|
320
|
-
"3.
|
|
318
|
+
"1. Web search: Use for finding URLs, profiles, and public info.",
|
|
319
|
+
"2. Chrome browser: Use for interaction, scrolling, and map searching.",
|
|
320
|
+
"3. Desktop control: Use for desktop applications when enabled.",
|
|
321
321
|
"",
|
|
322
322
|
"=== HOW I WORK ===",
|
|
323
|
-
"1. WEB SEARCH:",
|
|
324
|
-
"
|
|
325
|
-
"
|
|
326
|
-
"",
|
|
327
|
-
"2. BROWSER AUTOMATION:",
|
|
328
|
-
" - Navigating to websites and interacting with them",
|
|
329
|
-
" - Logging into accounts and filling forms",
|
|
330
|
-
" - Extracting content from web pages",
|
|
331
|
-
"",
|
|
332
|
-
"3. COMPUTER CONTROL:",
|
|
333
|
-
" - Desktop applications and system tasks",
|
|
334
|
-
" - Mouse and keyboard automation",
|
|
335
|
-
" - File and folder operations"
|
|
323
|
+
"1. WEB SEARCH: Finding URLs, quick facts, lists of companies or profiles",
|
|
324
|
+
"2. CHROME BROWSER: Navigating, logging in, filling forms, extracting content",
|
|
325
|
+
"3. DESKTOP CONTROL: Applications, mouse/keyboard automation, file operations"
|
|
336
326
|
]
|
|
337
327
|
: [
|
|
338
328
|
"=== RIRD AI - rird.ai ===",
|
|
@@ -346,22 +336,16 @@ function createConfig(pythonCmd) {
|
|
|
346
336
|
"",
|
|
347
337
|
"=== RESEARCH STRATEGY ===",
|
|
348
338
|
"For ANY task that asks to 'find URLs', 'output URLs', 'list profiles', or 'get X items':",
|
|
349
|
-
"1. ALWAYS START with
|
|
350
|
-
"2. Only fall back to
|
|
339
|
+
"1. ALWAYS START with web search - it is instant.",
|
|
340
|
+
"2. Only fall back to Chrome if search fails or task requires interaction (login, forms).",
|
|
351
341
|
"",
|
|
352
342
|
"=== TOOL PRIORITY ===",
|
|
353
|
-
"1.
|
|
354
|
-
"2.
|
|
343
|
+
"1. Web search: Use for finding URLs, profiles, and public info.",
|
|
344
|
+
"2. Chrome browser: Use for interaction, scrolling, and map searching.",
|
|
355
345
|
"",
|
|
356
346
|
"=== HOW I WORK ===",
|
|
357
|
-
"1. WEB SEARCH:",
|
|
358
|
-
"
|
|
359
|
-
" - Fast lookups that don't require visiting a page",
|
|
360
|
-
"",
|
|
361
|
-
"2. BROWSER AUTOMATION:",
|
|
362
|
-
" - Navigating to websites and interacting with them",
|
|
363
|
-
" - Logging into accounts and filling forms",
|
|
364
|
-
" - Extracting content from web pages"
|
|
347
|
+
"1. WEB SEARCH: Finding URLs, quick facts, lists of companies or profiles",
|
|
348
|
+
"2. CHROME BROWSER: Navigating, logging in, filling forms, extracting content"
|
|
365
349
|
]
|
|
366
350
|
|
|
367
351
|
const config = {
|