open-agents-ai 0.103.95 → 0.103.97

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/dist/index.js CHANGED
@@ -9345,6 +9345,19 @@ import { execSync as execSync16, spawn as spawn7 } from "node:child_process";
9345
9345
  import { existsSync as existsSync19, readFileSync as readFileSync14 } from "node:fs";
9346
9346
  import { join as join22, dirname as dirname9 } from "node:path";
9347
9347
  import { fileURLToPath as fileURLToPath5 } from "node:url";
9348
+ function findScrapeScript() {
9349
+ const candidates = [
9350
+ // Published npm package: dist/scripts/web_scrape.py
9351
+ join22(__dirname3, "scripts", "web_scrape.py"),
9352
+ // Published npm package (from node_modules): node_modules/open-agents-ai/dist/scripts/
9353
+ join22(__dirname3, "..", "node_modules", "open-agents-ai", "dist", "scripts", "web_scrape.py"),
9354
+ // Dev monorepo: packages/execution/src/tools/../../scripts/
9355
+ join22(__dirname3, "..", "..", "scripts", "web_scrape.py"),
9356
+ // Dev monorepo alt: packages/execution/scripts/
9357
+ join22(__dirname3, "..", "scripts", "web_scrape.py")
9358
+ ];
9359
+ return candidates.find((p) => existsSync19(p)) || candidates[0];
9360
+ }
9348
9361
  async function probeService() {
9349
9362
  try {
9350
9363
  const controller = new AbortController();
@@ -9430,13 +9443,13 @@ async function apiCall(endpoint, method = "POST", body) {
9430
9443
  const res = await fetch(url, options);
9431
9444
  return await res.json();
9432
9445
  }
9433
- var __dirname3, SCRAPE_SCRIPT, DEFAULT_PORT, BASE_URL, serviceProcess, activeSessionId, BrowserActionTool;
9446
+ var __dirname3, DEFAULT_PORT, SCRAPE_SCRIPT, BASE_URL, serviceProcess, activeSessionId, BrowserActionTool;
9434
9447
  var init_browser_action = __esm({
9435
9448
  "packages/execution/dist/tools/browser-action.js"() {
9436
9449
  "use strict";
9437
9450
  __dirname3 = dirname9(fileURLToPath5(import.meta.url));
9438
- SCRAPE_SCRIPT = join22(__dirname3, "..", "..", "scripts", "web_scrape.py");
9439
9451
  DEFAULT_PORT = 8130;
9452
+ SCRAPE_SCRIPT = findScrapeScript();
9440
9453
  BASE_URL = `http://localhost:${DEFAULT_PORT}`;
9441
9454
  serviceProcess = null;
9442
9455
  activeSessionId = null;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "open-agents-ai",
3
- "version": "0.103.95",
3
+ "version": "0.103.97",
4
4
  "description": "AI coding agent powered by open-source models (Ollama/vLLM) — interactive TUI with agentic tool-calling loop",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
@@ -156,6 +156,7 @@ When you discover image files (png, jpg, gif, svg, webp, bmp) during codebase ex
156
156
  - Use file_edit for small changes instead of rewriting entire files
157
157
  - Keep tool calls focused — read only what you need
158
158
  - You MUST call task_complete when the task is done
159
+ - When you have gathered sufficient information from web tools, call task_complete IMMEDIATELY with a summary of your findings. Do NOT continue fetching more pages after you already have the answer. One good source is enough — stop and summarize.
159
160
 
160
161
  ## Self-Awareness & Introspection
161
162
 
@@ -54,7 +54,7 @@ Launch ALL sub_agent calls in ONE response. This saves your context window for o
54
54
  - If tests fail, read the FULL error. Fix the exact issue.
55
55
  - Do NOT give up after failure. Iterate until it passes.
56
56
  - Use file_edit for small changes, not full file rewrites
57
- - You MUST call task_complete when done
57
+ - You MUST call task_complete when done — when you have enough information from web tools, STOP fetching and call task_complete with a summary. Do not keep browsing after you have the answer.
58
58
  - Do NOT output long explanations. Focus on tool calls.
59
59
  - If file_read/list_directory returns ENOENT, use list_directory on the project root — do NOT guess parent paths
60
60
  - Directory listing entries are RELATIVE to the listed directory. If you list "parent/" and see "child", the full path is "parent/child" — NOT ".child" or just "child"
@@ -17,7 +17,7 @@ Rules:
17
17
  - ALWAYS call tools. NEVER just write text.
18
18
  - Read files before editing them.
19
19
  - Run tests after every change.
20
- - Call task_complete when done.
20
+ - Call task_complete when done. Once you have the answer from web tools, STOP and call task_complete immediately.
21
21
  - If ENOENT, list_directory on project root. Don't guess paths.
22
22
  - Directory entries are RELATIVE. If you list "parent/" and see "child", the path is "parent/child" — NOT ".child".
23
23
  - Use list_directory for directories, NOT file_read. Prefer list_directory over shell ls.