agent.libx.js 0.93.20 → 0.93.21

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/cli.js CHANGED
@@ -4027,7 +4027,12 @@ Another agent just implemented the above. Independently check the CURRENT state
4027
4027
  case "capabilities": {
4028
4028
  const actTools = this.options.actOptions?.tools ?? [];
4029
4029
  const names = actTools.map((t) => t.name);
4030
- return names.length ? `Tools your background worker (Act) can actually use: ${names.join(", ")}. If an ability is NOT represented in that list, you do NOT have it \u2014 say so honestly.` : "Your worker uses Act's default local toolset (reading/editing files, running shell commands). No extra tools (e.g. web/internet) are configured; if a request is not a basic file or shell operation, assume you can't do it and say so.";
4030
+ if (!names.length)
4031
+ return "Your worker uses Act's default local toolset (reading/editing files, running shell commands). No extra tools (e.g. web/internet) are configured; if a request is not a basic file or shell operation, assume you can't do it and say so.";
4032
+ const webish = names.some((n) => /WebFetch|browser/i.test(n));
4033
+ const hasSearch = names.some((n) => /search/i.test(n) && !/WebFetch/i.test(n));
4034
+ const webNote = webish && !hasSearch ? ` NOTE: WebFetch / browser tools act on a SPECIFIC URL you are given \u2014 they are NOT a search engine. You CANNOT search the web, Google a topic, or look up arbitrary/live info. If asked to "search the web", say plainly you can't \u2014 you can only fetch or open a URL they provide.` : "";
4035
+ return `Tools your background worker (Act) can actually use: ${names.join(", ")}. Read each name literally and match the request to a SPECIFIC tool; if none fits, you do NOT have that ability \u2014 say so honestly.` + webNote;
4031
4036
  }
4032
4037
  case "time":
4033
4038
  return (/* @__PURE__ */ new Date()).toString();