Keep schedule_create for later or repeated work (#200)
A live check showed the agent answering a business-idea question by creating a schedule that would run the analysis later. The schedule_create description now says never to use it for work the user wants now, however long.
This commit is contained in:
parent
42eb420545
commit
d6835fe0b0
@ -951,7 +951,7 @@ export const builtinAgentTools: ConnectorTool[] = [
|
|||||||
{
|
{
|
||||||
name: "schedule_create",
|
name: "schedule_create",
|
||||||
description:
|
description:
|
||||||
'Create a reminder or recurring job for this bot. Use it whenever the user describes something that should happen later or again, even in passing ("remind me in 10 minutes", "every Sunday I plan the week"): create it right away instead of asking first; the user sees it in the conversation and can undo it. Without a time, use 08:00 for mornings, 19:00 for evenings and 09:00 otherwise. Reusing the name of an active repeating schedule changes that schedule instead of adding another. Repeats: cron or every/unit (min 1 minute). One-shot: runAt, delayMinutes, or delaySeconds.',
|
'Create a reminder or recurring job for this bot. Use it whenever the user describes something that should happen later or again, even in passing ("remind me in 10 minutes", "every Sunday I plan the week"): create it right away instead of asking first; the user sees it in the conversation and can undo it. Never use it for work the user wants now, however long: do that work in this turn. Without a time, use 08:00 for mornings, 19:00 for evenings and 09:00 otherwise. Reusing the name of an active repeating schedule changes that schedule instead of adding another. Repeats: cron or every/unit (min 1 minute). One-shot: runAt, delayMinutes, or delaySeconds.',
|
||||||
inputSchema: {
|
inputSchema: {
|
||||||
type: "object",
|
type: "object",
|
||||||
properties: {
|
properties: {
|
||||||
|
|||||||
@ -1,5 +1,6 @@
|
|||||||
import { ONCE_ROUTINE_CRON } from "@rakazo/core";
|
import { ONCE_ROUTINE_CRON } from "@rakazo/core";
|
||||||
import { describe, expect, it, vi } from "vitest";
|
import { describe, expect, it, vi } from "vitest";
|
||||||
|
import { builtinAgentTools } from "./builtin-tools.js";
|
||||||
import {
|
import {
|
||||||
cancelScheduleFromTool,
|
cancelScheduleFromTool,
|
||||||
createScheduleFromTool,
|
createScheduleFromTool,
|
||||||
@ -781,4 +782,9 @@ describe("scheduling on behalf of another bot", () => {
|
|||||||
expect(extended.inputSchema.required).toEqual(["name"]);
|
expect(extended.inputSchema.required).toEqual(["name"]);
|
||||||
expect(Object.keys(tool.inputSchema.properties)).toEqual(["name"]);
|
expect(Object.keys(tool.inputSchema.properties)).toEqual(["name"]);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
it("keeps schedule_create for later or repeated work, not work wanted now", () => {
|
||||||
|
const tool = builtinAgentTools.find((candidate) => candidate.name === "schedule_create");
|
||||||
|
expect(tool?.description).toContain("Never use it for work the user wants now");
|
||||||
|
});
|
||||||
});
|
});
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user