agent.libx.js 0.93.20 → 0.93.22
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 +9 -1
- package/dist/cli.js.map +1 -1
- package/dist/index.js +9 -1
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/cli.js
CHANGED
|
@@ -3652,6 +3652,7 @@ Today's date: ${(/* @__PURE__ */ new Date()).toDateString()}.`;
|
|
|
3652
3652
|
this.turnDispatched = false;
|
|
3653
3653
|
this.turnBriefs.clear();
|
|
3654
3654
|
this.spokeThisTurn = false;
|
|
3655
|
+
this.voice.options.toolChoice = void 0;
|
|
3655
3656
|
}
|
|
3656
3657
|
/** preToolUse guard on the reflex: once it has dispatched this turn, a dispatch is "said my piece,
|
|
3657
3658
|
* now wait for the push" (CC's Task model). Block the temptations — TaskStatus polling and identical
|
|
@@ -3964,6 +3965,7 @@ Another agent just implemented the above. Independently check the CURRENT state
|
|
|
3964
3965
|
run: async ({ brief, label }) => {
|
|
3965
3966
|
this.turnDispatched = true;
|
|
3966
3967
|
this.turnBriefs.add(String(brief ?? ""));
|
|
3968
|
+
this.voice.options.toolChoice = "none";
|
|
3967
3969
|
const id = await this.dispatch(String(brief ?? ""), "act", label ? String(label) : void 0);
|
|
3968
3970
|
return `Acting on task ${id}. Acknowledge briefly; the result will arrive as a [task ${id} completed] event.`;
|
|
3969
3971
|
}
|
|
@@ -3984,6 +3986,7 @@ Another agent just implemented the above. Independently check the CURRENT state
|
|
|
3984
3986
|
run: async ({ brief, label }) => {
|
|
3985
3987
|
this.turnDispatched = true;
|
|
3986
3988
|
this.turnBriefs.add(String(brief ?? ""));
|
|
3989
|
+
this.voice.options.toolChoice = "none";
|
|
3987
3990
|
const id = await this.dispatch(String(brief ?? ""), "think", label ? String(label) : void 0);
|
|
3988
3991
|
return `Thinking on task ${id}. Acknowledge briefly; the result will arrive as a [task ${id} completed] event.`;
|
|
3989
3992
|
}
|
|
@@ -4027,7 +4030,12 @@ Another agent just implemented the above. Independently check the CURRENT state
|
|
|
4027
4030
|
case "capabilities": {
|
|
4028
4031
|
const actTools = this.options.actOptions?.tools ?? [];
|
|
4029
4032
|
const names = actTools.map((t) => t.name);
|
|
4030
|
-
|
|
4033
|
+
if (!names.length)
|
|
4034
|
+
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.";
|
|
4035
|
+
const webish = names.some((n) => /WebFetch|browser/i.test(n));
|
|
4036
|
+
const hasSearch = names.some((n) => /search/i.test(n) && !/WebFetch/i.test(n));
|
|
4037
|
+
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.` : "";
|
|
4038
|
+
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
4039
|
}
|
|
4032
4040
|
case "time":
|
|
4033
4041
|
return (/* @__PURE__ */ new Date()).toString();
|