From 966e40e71b35d435a39e0deae0f3feb43844ed21 Mon Sep 17 00:00:00 2001 From: "Thomas G. Lopes" Date: Wed, 8 Apr 2026 20:06:50 +0100 Subject: [PATCH] anthropic fix --- openpeon/files.macos/config.json | 2 +- pi/files.macos/agent/settings.json | 4 ++-- .../agent/extensions/anthropic-subscription-fix.ts | 14 ++++++++++++++ 3 files changed, 17 insertions(+), 3 deletions(-) create mode 100644 pi/files/agent/extensions/anthropic-subscription-fix.ts diff --git a/openpeon/files.macos/config.json b/openpeon/files.macos/config.json index de0a431..982ca09 100644 --- a/openpeon/files.macos/config.json +++ b/openpeon/files.macos/config.json @@ -1,7 +1,7 @@ { "activePack": "solid_snake", "volume": 1.5, - "muted": false, + "muted": true, "enabledCategories": { "session.start": true, "task.acknowledge": true, diff --git a/pi/files.macos/agent/settings.json b/pi/files.macos/agent/settings.json index c2bbff4..b88b452 100644 --- a/pi/files.macos/agent/settings.json +++ b/pi/files.macos/agent/settings.json @@ -2,7 +2,7 @@ "lastChangelogVersion": "0.64.0", "defaultProvider": "anthropic", "defaultModel": "claude-opus-4-6", - "defaultThinkingLevel": "medium", + "defaultThinkingLevel": "xhigh", "theme": "matugen", "lsp": { "hookMode": "edit_write" @@ -12,4 +12,4 @@ "timeoutSeconds": 300, "enabled": true } -} +} \ No newline at end of file diff --git a/pi/files/agent/extensions/anthropic-subscription-fix.ts b/pi/files/agent/extensions/anthropic-subscription-fix.ts new file mode 100644 index 0000000..1614d4a --- /dev/null +++ b/pi/files/agent/extensions/anthropic-subscription-fix.ts @@ -0,0 +1,14 @@ +import type { ExtensionAPI } from "@mariozechner/pi-coding-agent"; + +const TARGET = "about pi itself, its SDK, extensions, themes, skills, or TUI"; +const REPLACEMENT = "about pi, its SDK, extensions, themes, skills, or TUI"; + +export default function(pi: ExtensionAPI) { + pi.on("before_agent_start", (event, ctx) => { + if (ctx.model?.provider !== "anthropic") return; + if (!event.systemPrompt.includes(TARGET)) return; + return { + systemPrompt: event.systemPrompt.replace(TARGET, REPLACEMENT), + }; + }); +}