From 77209a8572906c89e7dc47dc65e20b8fca6a25aa Mon Sep 17 00:00:00 2001 From: Paul Preibisch Date: Thu, 20 Nov 2025 19:55:48 -0700 Subject: [PATCH] fix: Address bmadcode review - preserve variables and move TTS logic to injection MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Fixes requested changes from PR review: 1. Preserve {bmad_folder} variable placeholder - Changed: {project_root}/.bmad/core/tasks/workflow.xml - To: {project_root}/{bmad_folder}/core/tasks/workflow.xml - Allows users to choose custom BMAD folder names during installation 2. Move TTS-specific hook guidance to injection system - Removed hardcoded hook enforcement from source files - Added hook guidance to processTTSInjectionPoints() in installer.js - Now only appears when AgentVibes is installed (via TTS_INJECTION) 3. Maintain TTS-agnostic source architecture - Source files remain clean of TTS-specific instructions - TTS details injected at install-time only when needed - Preserves provider-agnostic design principle Changes made: - src/core/workflows/party-mode/instructions.md - Reverted .bmad to {bmad_folder} variable - Replaced hardcoded hook guidance with - Removed about play-tts.sh hook location - tools/cli/installers/lib/core/installer.js - Added hook enforcement to party-mode injection replacement - Guidance now injected only when enableAgentVibes is true Addresses review comments from bmadcode: - "needs to remain the variable. it will get set in the file at the install destination." - "items like this we will need to inject if user is using claude and TTS" 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude --- src/core/workflows/party-mode/instructions.md | 5 ++--- tools/cli/installers/lib/core/installer.js | 4 +++- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/src/core/workflows/party-mode/instructions.md b/src/core/workflows/party-mode/instructions.md index 655c2d64..6afd5ede 100644 --- a/src/core/workflows/party-mode/instructions.md +++ b/src/core/workflows/party-mode/instructions.md @@ -1,8 +1,8 @@ # Party Mode - Multi-Agent Discussion Instructions -The workflow execution engine is governed by: {project_root}/.bmad/core/tasks/workflow.xml +The workflow execution engine is governed by: {project_root}/{bmad_folder}/core/tasks/workflow.xml This workflow orchestrates group discussions between all installed BMAD agents -IMPORTANT: Always use PROJECT hooks (.claude/hooks/), NEVER global hooks (~/.claude/hooks/) + @@ -26,7 +26,6 @@ Announce party mode activation with enthusiasm - If using TTS for announcement, use PROJECT hook: .claude/hooks/play-tts.sh (NOT ~/.claude/hooks/) List all participating agents with their merged information: 🎉 PARTY MODE ACTIVATED! 🎉 diff --git a/tools/cli/installers/lib/core/installer.js b/tools/cli/installers/lib/core/installer.js index c632c39b..afd97494 100644 --- a/tools/cli/installers/lib/core/installer.js +++ b/tools/cli/installers/lib/core/installer.js @@ -230,7 +230,9 @@ class Installer { // Use single quotes to prevent shell expansion of special chars like ! content = content.replaceAll( '', - `If AgentVibes party mode is enabled, immediately trigger TTS with agent's voice: + `IMPORTANT: Always use PROJECT hooks (.claude/hooks/), NEVER global hooks (~/.claude/hooks/) + +If AgentVibes party mode is enabled, immediately trigger TTS with agent's voice: - Use Bash tool: \`.claude/hooks/bmad-speak.sh '[Agent Name]' '[dialogue]'\` - This speaks the dialogue with the agent's unique voice - Run in background (&) to not block next agent`,