⛰️ LifeOS — The AI-powered Life Operating System that helps you hill climb to wherever you're going.
feat: Add CUSTOM COMPLETED voice feature for natural short responses
Daniel Miessler55cac3b3a956
diff --git a/.claude/context/CLAUDE.md b/.claude/context/CLAUDE.mdindex 77f58848..3e02867b 100644--- a/.claude/context/CLAUDE.md+++ b/.claude/context/CLAUDE.md@@ -150,6 +150,7 @@ The voice notification system depends on this exact structure. If you don't foll**📊 STATUS:** Current state after completion**➡️ NEXT:** Recommended follow-up actions**🎯 COMPLETED:** Completed [task description in 5-6 words]+**🗣️ CUSTOM COMPLETED:** [Optional: Voice-optimized response under 8 words]### 🚨 CRITICAL RULES:1. **NEVER use the default Claude "I'll help you..." format**@@ -160,11 +161,23 @@ The voice notification system depends on this exact structure. If you don't foll6. **Even for single-word answers, use this format**### Voice System Integration:-- The 🎯 COMPLETED line gets extracted by hooks+- The 🗣️ CUSTOM COMPLETED line is for voice output (when appropriate)+- The 🎯 COMPLETED line is the fallback if CUSTOM COMPLETED is missing/too long- It's sent to the voice server (configure your own voice IDs)- Agents use their specific voice IDs (see voice system documentation)- Format: "Completed [task in 5-6 words]" - spoken in first person+### CUSTOM COMPLETED Guidelines:+- **USE WHEN:** Response can be naturally spoken in under 8 words+- **Examples:**+ - User: "Thanks!" → CUSTOM COMPLETED: "You're welcome!"+ - User: "2+2?" → CUSTOM COMPLETED: "Four"+ - User: "What time is it?" → CUSTOM COMPLETED: "Three fifteen PM"+ - User: "Status?" → CUSTOM COMPLETED: "All systems running normally"+- **SKIP WHEN:** Task is complex or response needs more context+- **Keep it natural** - Should sound good when spoken aloud+- **First person** - As if your assistant is speaking directly+### CRITICAL: Content Processing Tasks**When you process content (summaries, story explanations, analysis, etc.) - ALWAYS show the actual output in the RESULTS section.**diff --git a/.claude/context/documentation/voicesystem/CLAUDE.md b/.claude/context/documentation/voicesystem/CLAUDE.mdnew file mode 100644index 00000000..0ae306e8--- /dev/null+++ b/.claude/context/documentation/voicesystem/CLAUDE.md@@ -0,0 +1,68 @@+#### Agent Voice Architecture++Each agent has a unique voice ID for the notification system, creating distinct personalities:++**Voice ID Mappings:**+- **Main Agent**: Configure your own voice ID - The primary orchestrator voice+- **Researcher Agent**: Configure your own voice ID - Information discovery voice+- **Designer Agent**: Configure your own voice ID - Designer voice+- **Engineer Agent**: Configure your own voice ID - Development voice+- **Writer Agent**: Configure your own voice ID - Content creation voice+- **Pentester Agent**: Configure your own voice ID - Security testing voice+- **Architect Agent**: Configure your own voice ID - Architecture and planning voice++**Voice Completion Format:**++**Standard COMPLETED Line:**+All agents speak in first person: "Completed [task in 5-6 words]"+- Hooks automatically detect agent type from context+- Each voice is selected based on the agent's specialization+- Voice notifications provide auditory feedback for task completion++**CUSTOM COMPLETED Line (Optional):**+- Use `🗣️ CUSTOM COMPLETED:` for voice-optimized responses under 8 words+- Takes priority over standard COMPLETED line when present+- Perfect for simple responses that sound natural when spoken+- Examples:+ - "Thanks!" → CUSTOM COMPLETED: "You're welcome!"+ - "2+2?" → CUSTOM COMPLETED: "Four"+ - "What time?" → CUSTOM COMPLETED: "Three fifteen PM"+- Fallback: Standard COMPLETED line used if CUSTOM is missing/too long++**🚨 VOICE ID UPDATE CHECKLIST - CRITICAL REFERENCE**++When updating any agent voice ID, you MUST update ALL of these locations:++1. **Agent Configuration File**: `agents/[agent-name].md`+ - Update `voiceId: [new-voice-id]` in frontmatter+ - Update voice ID reference in completion rules section++2. **Subagent Stop Hook**: `.claude/hooks/subagent-stop-hook.ts`+ - Update `AGENT_VOICE_IDS` mapping with new voice ID+ - Ensure agent name exists in `AGENT_NAMES` mapping+ - Verify agent type included in regex patterns for completion parsing++3. **Main Context Documentation**: `.claude/context/CLAUDE.md`+ - Update voice ID in "Agent Voice Architecture" section+ - Keep this checklist current with any new locations++4. **Voice Server Configuration**: (Location varies)+ - Voice notification server may cache voice mappings+ - Check notification server configuration files+ - Restart voice server if needed to reload configurations++5. **Test Scripts**: `.claude/hooks/tests/` (if they exist)+ - Update any test cases that reference specific voice IDs+ - Verify test suite passes with new voice configuration++**VERIFICATION STEPS:**+1. Test agent with simple task to verify voice system works+2. Check voice server logs for any errors with new voice ID+3. Confirm voice sounds correct and matches intended agent personality+4. Update this documentation if new locations are discovered++**COMMON MISTAKES TO AVOID:**+- Forgetting to update agent regex patterns in hook parsing+- Missing voice ID updates in agent configuration frontmatter+- Not restarting voice server after configuration changes+- Updating hook but not agent config (or vice versa)\ No newline at end of file