Have hook runs point to the brief when it disagrees with memory
A hook run follows its brief over the bot's memory. When the two disagree, the run now reports the conflict and says the brief needs changing, rather than offering to fix its memory. In chat, a change to how a hook's calls are handled is proposed as a new brief, not saved to memory or promised. Co-Authored-By: Claude Opus 5.5 <[email protected]>
This commit is contained in:
@@ -63,7 +63,7 @@ export default function proposeHookTool({
|
||||
workspace_id ? "in this workspace" : "in your own chat"
|
||||
}, with what the caller sent attached as data, in this session, where the result is posted (the hook stays tied to this session even after the user starts another). Runs carry the brief out without asking the user, so write it as a full brief for a future you with no memory of this chat, saying exactly what to do with each call. ${
|
||||
computers.length ? `Your computers here: ${listed}.` : `You have no computer here, so it can't watch one.`
|
||||
} To change one of your hooks (ids from list_hooks), give hook_id and only what changes: title, instructions, watch_filter, or enabled true to switch a paused one back on; what calls it and where it runs can't change. Nothing is saved until the user presses Confirm on the card. A new hook's URL is shown to the user on the card, once: you never see it, never ask for it, and never set a signing secret (the user adds one from the Hooks menu). Check list_hooks first: if a hook already does the job, propose a change to it instead.`,
|
||||
} To change one of your hooks (ids from list_hooks), give hook_id and only what changes: title, instructions, watch_filter, or enabled true to switch a paused one back on; what calls it and where it runs can't change. Nothing is saved until the user presses Confirm on the card. A new hook's URL is shown to the user on the card, once: you never see it, never ask for it, and never set a signing secret (the user adds one from the Hooks menu). Check list_hooks first: if a hook already does the job, propose a change to it instead. When the user tells you to handle a hook's calls differently (often in reply to a run's report), tell them the hook's brief has to change for that and propose the new brief. Runs follow the brief over your memory, so don't save it to your memory or promise to do it from now on instead: neither changes what the next call does.`,
|
||||
schema: z.object({
|
||||
hook_id: z.number().int().positive().optional().describe("The hook to change; leave out for a new one"),
|
||||
title: z.string().trim().min(1).max(80).optional().describe(`A short name, e.g. "GitHub pushes"`),
|
||||
|
||||
Reference in New Issue
Block a user