From 95af492ff0ebcc61c5ffaad978ec2ab2b4510a64 Mon Sep 17 00:00:00 2001 From: Paul Buetow Date: Wed, 11 Feb 2026 22:45:41 +0200 Subject: feat: add delete_prompt built-in meta-prompt MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Adds a third built-in meta-prompt for interactively deleting custom prompts with confirmation. This completes the prompt management trilogy (save, update, delete). Changes: - Add delete_prompt meta-prompt with prompt_name argument - Interactive workflow: show prompt → confirm → delete via delete_prompt tool - Update test to expect 3 built-in prompts (was 2) - Includes safety notes about built-in prompts and backups The meta-prompt ensures users see what they're deleting and must explicitly confirm before the delete_prompt tool is called. Co-Authored-By: Claude Sonnet 4.5 --- internal/promptstore/default_prompts.go | 36 +++++++++++++++++++++++++++++++++ 1 file changed, 36 insertions(+) (limited to 'internal/promptstore/default_prompts.go') diff --git a/internal/promptstore/default_prompts.go b/internal/promptstore/default_prompts.go index 09a998a..d985500 100644 --- a/internal/promptstore/default_prompts.go +++ b/internal/promptstore/default_prompts.go @@ -145,5 +145,41 @@ Start by fetching and showing me the current prompt, then ask clarifying questio Created: now, Updated: now, }, + { + Name: "delete_prompt", + Title: "Delete Custom Prompt", + Description: "Interactively delete an existing custom prompt with confirmation. Claude will show the current prompt, ask for confirmation, and only delete after explicit approval. Built-in prompts cannot be deleted.", + Arguments: []PromptArgument{ + { + Name: "prompt_name", + Description: "Name of the existing prompt to delete", + Required: true, + }, + }, + Messages: []PromptMessage{ + { + Role: "user", + Content: MessageContent{ + Type: "text", + Text: `I want to delete the existing prompt '{{prompt_name}}'. + +Please help me by: +1) First, show me the current prompt so I can confirm it's the right one +2) Ask me to explicitly confirm the deletion +3) Only after I explicitly confirm, use the delete_prompt tool to delete it + +IMPORTANT NOTES: +- Built-in prompts (save_prompt, update_prompt, delete_prompt) cannot be deleted +- Only custom prompts stored in user.jsonl can be deleted +- This action cannot be undone (though backups are automatically created) + +Start by showing me the prompt details.`, + }, + }, + }, + Tags: []string{"meta", "prompt-management", "interactive"}, + Created: now, + Updated: now, + }, } } -- cgit v1.2.3