import { Type } from "typebox"; import { stringEnum } from "../schema/typebox.js"; import {
describeUpdatePlanTool,
UPDATE_PLAN_TOOL_DISPLAY_SUMMARY,
} from "../tool-description-presets.js"; import { type AnyAgentTool, ToolInputError, readStringParam } from "./common.js";
const PLAN_STEP_STATUSES = ["pending", "in_progress", "completed"] as const;
const UpdatePlanToolSchema = Type.Object({
explanation: Type.Optional(
Type.String({
description: "Optional short note explaining what changed in the plan.",
}),
),
plan: Type.Array(
Type.Object(
{
step: Type.String({ description: "Short plan step." }),
status: stringEnum(PLAN_STEP_STATUSES, {
description: 'One of "pending", "in_progress", or "completed".',
}),
},
{ additionalProperties: true },
),
{
minItems: 1,
description: "Ordered list of plan steps. At most one step may be in_progress.",
},
),
});
type UpdatePlanStep = {
step: string;
status: (typeof PLAN_STEP_STATUSES)[number];
};
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.