agentvibes 2.0.8 → 2.0.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.claude/github-star-reminder.txt +1 -0
- package/.claude/hooks/check-output-style.sh +2 -2
- package/.claude/hooks/github-star-reminder.sh +94 -0
- package/.claude/hooks/personality-manager.sh +2 -2
- package/.claude/hooks/piper-installer.sh +144 -0
- package/.claude/hooks/play-tts-elevenlabs.sh +30 -3
- package/.claude/hooks/play-tts.sh +3 -0
- package/.claude/hooks/provider-commands.sh +30 -1
- package/.claude/hooks/voice-manager.sh +2 -2
- package/README.md +2 -2
- package/RELEASE_NOTES.md +236 -0
- package/package.json +1 -1
- package/src/installer.js +59 -33
- package/test/helpers/test-helper.bash +4 -2
- package/test/unit/personality-manager.bats +16 -4
- package/test/unit/personality-voice-mapping.bats +15 -6
- package/test/unit/play-tts.bats +0 -9
- package/agentvibes.org/.claude/commands/agent-vibes/add.md +0 -21
- package/agentvibes.org/.claude/commands/agent-vibes/agent-vibes.md +0 -68
- package/agentvibes.org/.claude/commands/agent-vibes/commands.json +0 -53
- package/agentvibes.org/.claude/commands/agent-vibes/get.md +0 -9
- package/agentvibes.org/.claude/commands/agent-vibes/list.md +0 -13
- package/agentvibes.org/.claude/commands/agent-vibes/personality.md +0 -79
- package/agentvibes.org/.claude/commands/agent-vibes/preview.md +0 -16
- package/agentvibes.org/.claude/commands/agent-vibes/provider.md +0 -54
- package/agentvibes.org/.claude/commands/agent-vibes/replay.md +0 -19
- package/agentvibes.org/.claude/commands/agent-vibes/sample.md +0 -12
- package/agentvibes.org/.claude/commands/agent-vibes/sentiment.md +0 -52
- package/agentvibes.org/.claude/commands/agent-vibes/set-language.md +0 -47
- package/agentvibes.org/.claude/commands/agent-vibes/set-pretext.md +0 -65
- package/agentvibes.org/.claude/commands/agent-vibes/switch.md +0 -53
- package/agentvibes.org/.claude/commands/agent-vibes/update.md +0 -20
- package/agentvibes.org/.claude/commands/agent-vibes/version.md +0 -10
- package/agentvibes.org/.claude/commands/agent-vibes/whoami.md +0 -7
- package/agentvibes.org/.claude/hooks/bmad-voice-manager.sh +0 -278
- package/agentvibes.org/.claude/hooks/language-manager.sh +0 -190
- package/agentvibes.org/.claude/hooks/personality-manager.sh +0 -279
- package/agentvibes.org/.claude/hooks/piper-download-voices.sh +0 -133
- package/agentvibes.org/.claude/hooks/piper-voice-manager.sh +0 -227
- package/agentvibes.org/.claude/hooks/play-tts-elevenlabs.sh +0 -201
- package/agentvibes.org/.claude/hooks/play-tts-piper.sh +0 -175
- package/agentvibes.org/.claude/hooks/play-tts.sh +0 -138
- package/agentvibes.org/.claude/hooks/provider-commands.sh +0 -374
- package/agentvibes.org/.claude/hooks/provider-manager.sh +0 -196
- package/agentvibes.org/.claude/hooks/sentiment-manager.sh +0 -163
- package/agentvibes.org/.claude/hooks/voice-manager.sh +0 -349
- package/agentvibes.org/.claude/hooks/voices-config.sh +0 -33
- package/agentvibes.org/.claude/journal/2025-10-07.html +0 -373
- package/agentvibes.org/.claude/journal/index.html +0 -91
- package/agentvibes.org/.claude/output-styles/agent-vibes.md +0 -203
- package/agentvibes.org/.claude/personalities/angry.md +0 -16
- package/agentvibes.org/.claude/personalities/annoying.md +0 -16
- package/agentvibes.org/.claude/personalities/crass.md +0 -16
- package/agentvibes.org/.claude/personalities/dramatic.md +0 -16
- package/agentvibes.org/.claude/personalities/dry-humor.md +0 -52
- package/agentvibes.org/.claude/personalities/flirty.md +0 -22
- package/agentvibes.org/.claude/personalities/funny.md +0 -16
- package/agentvibes.org/.claude/personalities/grandpa.md +0 -34
- package/agentvibes.org/.claude/personalities/millennial.md +0 -16
- package/agentvibes.org/.claude/personalities/moody.md +0 -16
- package/agentvibes.org/.claude/personalities/normal.md +0 -18
- package/agentvibes.org/.claude/personalities/pirate.md +0 -16
- package/agentvibes.org/.claude/personalities/poetic.md +0 -16
- package/agentvibes.org/.claude/personalities/professional.md +0 -16
- package/agentvibes.org/.claude/personalities/robot.md +0 -16
- package/agentvibes.org/.claude/personalities/sarcastic.md +0 -40
- package/agentvibes.org/.claude/personalities/sassy.md +0 -16
- package/agentvibes.org/.claude/personalities/surfer-dude.md +0 -16
- package/agentvibes.org/.claude/personalities/zen.md +0 -16
- package/agentvibes.org/.mcp-minimal.json +0 -60
- package/agentvibes.org/CHANGELOG.md +0 -56
- package/agentvibes.org/README.md +0 -93
- package/agentvibes.org/app/(auth)/layout.tsx +0 -15
- package/agentvibes.org/app/(auth)/reset-password/page.tsx +0 -45
- package/agentvibes.org/app/(auth)/signin/page.tsx +0 -82
- package/agentvibes.org/app/(auth)/signup/page.tsx +0 -104
- package/agentvibes.org/app/(default)/layout.tsx +0 -31
- package/agentvibes.org/app/(default)/page.tsx +0 -20
- package/agentvibes.org/app/api/hello/route.ts +0 -3
- package/agentvibes.org/app/css/additional-styles/theme.css +0 -82
- package/agentvibes.org/app/css/additional-styles/utility-patterns.css +0 -55
- package/agentvibes.org/app/css/style.css +0 -100
- package/agentvibes.org/app/layout.tsx +0 -63
- package/agentvibes.org/components/cta.tsx +0 -58
- package/agentvibes.org/components/features.tsx +0 -256
- package/agentvibes.org/components/hero-home.tsx +0 -133
- package/agentvibes.org/components/modal-video.tsx +0 -137
- package/agentvibes.org/components/page-illustration.tsx +0 -55
- package/agentvibes.org/components/spotlight.tsx +0 -77
- package/agentvibes.org/components/testimonials.tsx +0 -282
- package/agentvibes.org/components/ui/footer.tsx +0 -82
- package/agentvibes.org/components/ui/header.tsx +0 -53
- package/agentvibes.org/components/ui/logo.tsx +0 -10
- package/agentvibes.org/components/workflows.tsx +0 -176
- package/agentvibes.org/next.config.js +0 -4
- package/agentvibes.org/package-lock.json +0 -1974
- package/agentvibes.org/package.json +0 -30
- package/agentvibes.org/pnpm-lock.yaml +0 -1141
- package/agentvibes.org/postcss.config.js +0 -5
- package/agentvibes.org/public/audio/02-sarcastic.mp3 +0 -0
- package/agentvibes.org/public/audio/03-angry.mp3 +0 -0
- package/agentvibes.org/public/audio/04-grandpa.mp3 +0 -0
- package/agentvibes.org/public/audio/05-sarcastic-example2.mp3 +0 -0
- package/agentvibes.org/public/audio/french-rachel.mp3 +0 -0
- package/agentvibes.org/public/audio/spanish-antoni.mp3 +0 -0
- package/agentvibes.org/public/favicon.ico +0 -0
- package/agentvibes.org/public/fonts/nacelle-italic.woff2 +0 -0
- package/agentvibes.org/public/fonts/nacelle-regular.woff2 +0 -0
- package/agentvibes.org/public/fonts/nacelle-semibold.woff2 +0 -0
- package/agentvibes.org/public/fonts/nacelle-semibolditalic.woff2 +0 -0
- package/agentvibes.org/public/images/blurred-shape-gray.svg +0 -1
- package/agentvibes.org/public/images/blurred-shape.svg +0 -1
- package/agentvibes.org/public/images/client-logo-01.svg +0 -1
- package/agentvibes.org/public/images/client-logo-02.svg +0 -1
- package/agentvibes.org/public/images/client-logo-03.svg +0 -1
- package/agentvibes.org/public/images/client-logo-04.svg +0 -1
- package/agentvibes.org/public/images/client-logo-05.svg +0 -1
- package/agentvibes.org/public/images/client-logo-06.svg +0 -1
- package/agentvibes.org/public/images/client-logo-07.svg +0 -1
- package/agentvibes.org/public/images/client-logo-08.svg +0 -1
- package/agentvibes.org/public/images/client-logo-09.svg +0 -1
- package/agentvibes.org/public/images/features.png +0 -0
- package/agentvibes.org/public/images/footer-illustration.svg +0 -1
- package/agentvibes.org/public/images/hero-image-01.jpg +0 -0
- package/agentvibes.org/public/images/logo.svg +0 -1
- package/agentvibes.org/public/images/page-illustration.svg +0 -1
- package/agentvibes.org/public/images/secondary-illustration.svg +0 -1
- package/agentvibes.org/public/images/testimonial-01.jpg +0 -0
- package/agentvibes.org/public/images/testimonial-02.jpg +0 -0
- package/agentvibes.org/public/images/testimonial-03.jpg +0 -0
- package/agentvibes.org/public/images/testimonial-04.jpg +0 -0
- package/agentvibes.org/public/images/testimonial-05.jpg +0 -0
- package/agentvibes.org/public/images/testimonial-06.jpg +0 -0
- package/agentvibes.org/public/images/testimonial-07.jpg +0 -0
- package/agentvibes.org/public/images/testimonial-08.jpg +0 -0
- package/agentvibes.org/public/images/testimonial-09.jpg +0 -0
- package/agentvibes.org/public/images/workflow-01.png +0 -0
- package/agentvibes.org/public/images/workflow-02.png +0 -0
- package/agentvibes.org/public/images/workflow-03.png +0 -0
- package/agentvibes.org/public/videos/video.mp4 +0 -0
- package/agentvibes.org/tsconfig.json +0 -28
- package/agentvibes.org/utils/useMasonry.tsx +0 -67
- package/agentvibes.org/utils/useMousePosition.tsx +0 -27
|
@@ -1,47 +0,0 @@
|
|
|
1
|
-
# /agent-vibes:set-language
|
|
2
|
-
|
|
3
|
-
Set the language for TTS narration. AgentVibes will automatically use multilingual voices and speak in your chosen language.
|
|
4
|
-
|
|
5
|
-
## Usage
|
|
6
|
-
|
|
7
|
-
```bash
|
|
8
|
-
# Set language
|
|
9
|
-
/agent-vibes:set-language spanish
|
|
10
|
-
/agent-vibes:set-language french
|
|
11
|
-
/agent-vibes:set-language german
|
|
12
|
-
|
|
13
|
-
# Show current language
|
|
14
|
-
/agent-vibes:set-language
|
|
15
|
-
|
|
16
|
-
# Reset to English (default)
|
|
17
|
-
/agent-vibes:set-language english
|
|
18
|
-
/agent-vibes:set-language reset
|
|
19
|
-
```
|
|
20
|
-
|
|
21
|
-
## Supported Languages
|
|
22
|
-
|
|
23
|
-
Spanish, French, German, Italian, Portuguese, Chinese, Japanese, Korean, Polish, Dutch, Turkish, Russian, Arabic, Hindi, Swedish, Danish, Norwegian, Finnish, Czech, Romanian, Ukrainian, Greek, Bulgarian, Croatian, Slovak, and 20+ more.
|
|
24
|
-
|
|
25
|
-
## How It Works
|
|
26
|
-
|
|
27
|
-
1. **Sets Language**: Stores your language preference in `.claude/tts-language.txt`
|
|
28
|
-
2. **Voice Selection**: Automatically uses multilingual voices (Antoni, Rachel, Domi, Bella)
|
|
29
|
-
3. **BMAD Integration**: Works with BMAD plugin - agents speak in your language
|
|
30
|
-
4. **Personality Preserved**: Keeps your current personality/sentiment style
|
|
31
|
-
|
|
32
|
-
## Multilingual Voice Recommendations
|
|
33
|
-
|
|
34
|
-
- **Spanish**: Antoni, Matilda
|
|
35
|
-
- **French**: Rachel, Charlotte
|
|
36
|
-
- **German**: Domi, Charlotte
|
|
37
|
-
- **Italian**: Bella
|
|
38
|
-
- **Portuguese**: Matilda
|
|
39
|
-
- **Other Languages**: Antoni (best all-around multilingual)
|
|
40
|
-
|
|
41
|
-
## Implementation
|
|
42
|
-
|
|
43
|
-
This command tells Claude AI to:
|
|
44
|
-
1. Validate the language is supported
|
|
45
|
-
2. Save to `.claude/tts-language.txt`
|
|
46
|
-
3. Switch to an appropriate multilingual voice if needed
|
|
47
|
-
4. Inform user of the change
|
|
@@ -1,65 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
description: Set a pretext word/phrase that prefixes all TTS announcements
|
|
3
|
-
---
|
|
4
|
-
|
|
5
|
-
# Set TTS Pretext
|
|
6
|
-
|
|
7
|
-
Configure a word or phrase that will be spoken before every TTS message.
|
|
8
|
-
|
|
9
|
-
## Usage
|
|
10
|
-
|
|
11
|
-
```bash
|
|
12
|
-
/agent-vibes:set-pretext <word>
|
|
13
|
-
```
|
|
14
|
-
|
|
15
|
-
## Examples
|
|
16
|
-
|
|
17
|
-
Set "AgentVibes" as the pretext:
|
|
18
|
-
```bash
|
|
19
|
-
/agent-vibes:set-pretext AgentVibes
|
|
20
|
-
```
|
|
21
|
-
|
|
22
|
-
Set a phrase:
|
|
23
|
-
```bash
|
|
24
|
-
/agent-vibes:set-pretext "Project Alpha"
|
|
25
|
-
```
|
|
26
|
-
|
|
27
|
-
Clear the pretext:
|
|
28
|
-
```bash
|
|
29
|
-
/agent-vibes:set-pretext ""
|
|
30
|
-
```
|
|
31
|
-
|
|
32
|
-
## What It Does
|
|
33
|
-
|
|
34
|
-
When a pretext is set:
|
|
35
|
-
- **Without pretext**: "I'll do the task"
|
|
36
|
-
- **With pretext**: "AgentVibes: I'll do the task"
|
|
37
|
-
|
|
38
|
-
The pretext is saved locally in `.claude/config/agentvibes.json` and persists across sessions.
|
|
39
|
-
|
|
40
|
-
!bash
|
|
41
|
-
CONFIG_DIR="${CLAUDE_PROJECT_DIR:-.}/.claude/config"
|
|
42
|
-
CONFIG_FILE="$CONFIG_DIR/agentvibes.json"
|
|
43
|
-
|
|
44
|
-
# Get the pretext from arguments
|
|
45
|
-
PRETEXT="$ARGUMENTS"
|
|
46
|
-
|
|
47
|
-
# Create config directory if it doesn't exist
|
|
48
|
-
mkdir -p "$CONFIG_DIR"
|
|
49
|
-
|
|
50
|
-
# Initialize config file if it doesn't exist
|
|
51
|
-
if [ ! -f "$CONFIG_FILE" ]; then
|
|
52
|
-
echo '{}' > "$CONFIG_FILE"
|
|
53
|
-
fi
|
|
54
|
-
|
|
55
|
-
# Update or clear the pretext
|
|
56
|
-
if [ -z "$PRETEXT" ]; then
|
|
57
|
-
# Clear pretext
|
|
58
|
-
jq 'del(.pretext)' "$CONFIG_FILE" > "${CONFIG_FILE}.tmp" && mv "${CONFIG_FILE}.tmp" "$CONFIG_FILE"
|
|
59
|
-
echo "✅ Pretext cleared"
|
|
60
|
-
else
|
|
61
|
-
# Set pretext
|
|
62
|
-
jq --arg pretext "$PRETEXT" '.pretext = $pretext' "$CONFIG_FILE" > "${CONFIG_FILE}.tmp" && mv "${CONFIG_FILE}.tmp" "$CONFIG_FILE"
|
|
63
|
-
echo "✅ Pretext set to: $PRETEXT"
|
|
64
|
-
echo "📢 All TTS messages will now start with: \"$PRETEXT:\""
|
|
65
|
-
fi
|
|
@@ -1,53 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
description: Switch to a different ElevenLabs TTS voice
|
|
3
|
-
argument-hint: [voice_name_or_number] [--sentiment personality_name]
|
|
4
|
-
---
|
|
5
|
-
|
|
6
|
-
# Voice Selection
|
|
7
|
-
|
|
8
|
-
If no arguments provided, display this list:
|
|
9
|
-
|
|
10
|
-
## 🎤 Available ElevenLabs Voices
|
|
11
|
-
|
|
12
|
-
1. **Amy** - Young and friendly
|
|
13
|
-
2. **Aria** - Clear professional
|
|
14
|
-
3. **Cowboy Bob** - Western charm
|
|
15
|
-
4. **Demon Monster** - Deep and spooky
|
|
16
|
-
5. **Dr. Von Fusion** - Eccentric scientist
|
|
17
|
-
6. **Drill Sergeant** - Military authority
|
|
18
|
-
7. **Grandpa Spuds Oxley** - Wise elder
|
|
19
|
-
8. **Jessica Anne Bogart** - Wickedly eloquent
|
|
20
|
-
9. **Lutz Laugh** - Jovial and giggly
|
|
21
|
-
10. **Matthew Schmitz** - Deep baritone
|
|
22
|
-
11. **Michael** - British urban
|
|
23
|
-
12. **Ms. Walker** - Warm teacher
|
|
24
|
-
13. **Northern Terry** - Eccentric British
|
|
25
|
-
14. **Ralf Eisend** - International speaker
|
|
26
|
-
|
|
27
|
-
Then check current voice with: !bash .claude/hooks/voice-manager.sh get
|
|
28
|
-
|
|
29
|
-
And inform user: "To switch voices, use `/agent-vibes:switch <number>` or `/agent-vibes:switch <name>`"
|
|
30
|
-
|
|
31
|
-
If arguments ARE provided:
|
|
32
|
-
|
|
33
|
-
1. Parse arguments for --sentiment flag
|
|
34
|
-
2. If --sentiment is present:
|
|
35
|
-
- Extract voice name/number (everything before --sentiment)
|
|
36
|
-
- Extract sentiment name (after --sentiment)
|
|
37
|
-
- Execute: !bash .claude/hooks/voice-manager.sh switch <voice>
|
|
38
|
-
- Then execute: !bash .claude/hooks/sentiment-manager.sh set <sentiment>
|
|
39
|
-
3. If no --sentiment flag:
|
|
40
|
-
- Execute: !bash .claude/hooks/voice-manager.sh switch $ARGUMENTS
|
|
41
|
-
|
|
42
|
-
## Examples
|
|
43
|
-
|
|
44
|
-
```bash
|
|
45
|
-
# Switch voice only
|
|
46
|
-
/agent-vibes:switch Jessica Anne Bogart
|
|
47
|
-
|
|
48
|
-
# Switch voice and set sentiment
|
|
49
|
-
/agent-vibes:switch Aria --sentiment sarcastic
|
|
50
|
-
|
|
51
|
-
# Switch by number with sentiment
|
|
52
|
-
/agent-vibes:switch 5 --sentiment flirty
|
|
53
|
-
```
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
description: Update AgentVibes to the latest version
|
|
3
|
-
argument-hint: [--yes]
|
|
4
|
-
---
|
|
5
|
-
|
|
6
|
-
Updates AgentVibes to the latest version from the npm registry.
|
|
7
|
-
|
|
8
|
-
This will update:
|
|
9
|
-
- All slash commands
|
|
10
|
-
- TTS scripts and hooks
|
|
11
|
-
- Personality templates (new ones added, existing ones updated)
|
|
12
|
-
- Output styles
|
|
13
|
-
|
|
14
|
-
Your custom settings and voice configurations will be preserved.
|
|
15
|
-
|
|
16
|
-
Usage examples:
|
|
17
|
-
- `/agent-vibes:update` - Update with confirmation prompt
|
|
18
|
-
- `/agent-vibes:update --yes` - Update without confirmation
|
|
19
|
-
|
|
20
|
-
!bash npx agent-vibes update $ARGUMENTS
|
|
@@ -1,278 +0,0 @@
|
|
|
1
|
-
#!/bin/bash
|
|
2
|
-
|
|
3
|
-
PLUGIN_DIR=".claude/plugins"
|
|
4
|
-
PLUGIN_FILE="$PLUGIN_DIR/bmad-voices.md"
|
|
5
|
-
ENABLED_FLAG="$PLUGIN_DIR/bmad-voices-enabled.flag"
|
|
6
|
-
|
|
7
|
-
# Auto-enable plugin if BMAD is detected
|
|
8
|
-
auto_enable_if_bmad_detected() {
|
|
9
|
-
# Check if BMAD is installed
|
|
10
|
-
if [[ -f ".bmad-core/install-manifest.yaml" ]] && [[ ! -f "$ENABLED_FLAG" ]]; then
|
|
11
|
-
# BMAD detected but plugin not enabled - enable it silently
|
|
12
|
-
mkdir -p "$PLUGIN_DIR"
|
|
13
|
-
touch "$ENABLED_FLAG"
|
|
14
|
-
return 0
|
|
15
|
-
fi
|
|
16
|
-
return 1
|
|
17
|
-
}
|
|
18
|
-
|
|
19
|
-
# Parse markdown table to get voice mapping
|
|
20
|
-
get_agent_voice() {
|
|
21
|
-
local agent_id="$1"
|
|
22
|
-
|
|
23
|
-
# Auto-enable if BMAD is detected
|
|
24
|
-
auto_enable_if_bmad_detected
|
|
25
|
-
|
|
26
|
-
if [[ ! -f "$ENABLED_FLAG" ]]; then
|
|
27
|
-
echo "" # Plugin disabled
|
|
28
|
-
return
|
|
29
|
-
fi
|
|
30
|
-
|
|
31
|
-
if [[ ! -f "$PLUGIN_FILE" ]]; then
|
|
32
|
-
echo "" # Plugin file missing
|
|
33
|
-
return
|
|
34
|
-
fi
|
|
35
|
-
|
|
36
|
-
# Extract voice from markdown table
|
|
37
|
-
local voice=$(grep "^| $agent_id " "$PLUGIN_FILE" | \
|
|
38
|
-
awk -F'|' '{print $4}' | \
|
|
39
|
-
sed 's/^[[:space:]]*//;s/[[:space:]]*$//')
|
|
40
|
-
|
|
41
|
-
echo "$voice"
|
|
42
|
-
}
|
|
43
|
-
|
|
44
|
-
# Get personality for agent
|
|
45
|
-
get_agent_personality() {
|
|
46
|
-
local agent_id="$1"
|
|
47
|
-
|
|
48
|
-
if [[ ! -f "$PLUGIN_FILE" ]]; then
|
|
49
|
-
echo ""
|
|
50
|
-
return
|
|
51
|
-
fi
|
|
52
|
-
|
|
53
|
-
local personality=$(grep "^| $agent_id " "$PLUGIN_FILE" | \
|
|
54
|
-
awk -F'|' '{print $5}' | \
|
|
55
|
-
sed 's/^[[:space:]]*//;s/[[:space:]]*$//')
|
|
56
|
-
|
|
57
|
-
echo "$personality"
|
|
58
|
-
}
|
|
59
|
-
|
|
60
|
-
# Check if plugin is enabled
|
|
61
|
-
is_plugin_enabled() {
|
|
62
|
-
[[ -f "$ENABLED_FLAG" ]] && echo "true" || echo "false"
|
|
63
|
-
}
|
|
64
|
-
|
|
65
|
-
# Enable plugin
|
|
66
|
-
enable_plugin() {
|
|
67
|
-
mkdir -p "$PLUGIN_DIR"
|
|
68
|
-
|
|
69
|
-
# Save current settings before enabling
|
|
70
|
-
BACKUP_FILE="$PLUGIN_DIR/.bmad-previous-settings"
|
|
71
|
-
|
|
72
|
-
# Save current voice
|
|
73
|
-
if [[ -f ".claude/tts-voice.txt" ]]; then
|
|
74
|
-
CURRENT_VOICE=$(cat .claude/tts-voice.txt 2>/dev/null)
|
|
75
|
-
elif [[ -f "$HOME/.claude/tts-voice.txt" ]]; then
|
|
76
|
-
CURRENT_VOICE=$(cat "$HOME/.claude/tts-voice.txt" 2>/dev/null)
|
|
77
|
-
else
|
|
78
|
-
CURRENT_VOICE="Aria"
|
|
79
|
-
fi
|
|
80
|
-
|
|
81
|
-
# Save current personality
|
|
82
|
-
if [[ -f ".claude/tts-personality.txt" ]]; then
|
|
83
|
-
CURRENT_PERSONALITY=$(cat .claude/tts-personality.txt 2>/dev/null)
|
|
84
|
-
elif [[ -f "$HOME/.claude/tts-personality.txt" ]]; then
|
|
85
|
-
CURRENT_PERSONALITY=$(cat "$HOME/.claude/tts-personality.txt" 2>/dev/null)
|
|
86
|
-
else
|
|
87
|
-
CURRENT_PERSONALITY="normal"
|
|
88
|
-
fi
|
|
89
|
-
|
|
90
|
-
# Save current sentiment
|
|
91
|
-
if [[ -f ".claude/tts-sentiment.txt" ]]; then
|
|
92
|
-
CURRENT_SENTIMENT=$(cat .claude/tts-sentiment.txt 2>/dev/null)
|
|
93
|
-
elif [[ -f "$HOME/.claude/tts-sentiment.txt" ]]; then
|
|
94
|
-
CURRENT_SENTIMENT=$(cat "$HOME/.claude/tts-sentiment.txt" 2>/dev/null)
|
|
95
|
-
else
|
|
96
|
-
CURRENT_SENTIMENT=""
|
|
97
|
-
fi
|
|
98
|
-
|
|
99
|
-
# Write backup
|
|
100
|
-
cat > "$BACKUP_FILE" <<EOF
|
|
101
|
-
VOICE=$CURRENT_VOICE
|
|
102
|
-
PERSONALITY=$CURRENT_PERSONALITY
|
|
103
|
-
SENTIMENT=$CURRENT_SENTIMENT
|
|
104
|
-
EOF
|
|
105
|
-
|
|
106
|
-
touch "$ENABLED_FLAG"
|
|
107
|
-
echo "✅ BMAD voice plugin enabled"
|
|
108
|
-
echo "💾 Previous settings backed up:"
|
|
109
|
-
echo " Voice: $CURRENT_VOICE"
|
|
110
|
-
echo " Personality: $CURRENT_PERSONALITY"
|
|
111
|
-
[[ -n "$CURRENT_SENTIMENT" ]] && echo " Sentiment: $CURRENT_SENTIMENT"
|
|
112
|
-
echo ""
|
|
113
|
-
list_mappings
|
|
114
|
-
}
|
|
115
|
-
|
|
116
|
-
# Disable plugin
|
|
117
|
-
disable_plugin() {
|
|
118
|
-
BACKUP_FILE="$PLUGIN_DIR/.bmad-previous-settings"
|
|
119
|
-
|
|
120
|
-
# Check if we have a backup to restore
|
|
121
|
-
if [[ -f "$BACKUP_FILE" ]]; then
|
|
122
|
-
source "$BACKUP_FILE"
|
|
123
|
-
|
|
124
|
-
echo "❌ BMAD voice plugin disabled"
|
|
125
|
-
echo "🔄 Restoring previous settings:"
|
|
126
|
-
echo " Voice: $VOICE"
|
|
127
|
-
echo " Personality: $PERSONALITY"
|
|
128
|
-
[[ -n "$SENTIMENT" ]] && echo " Sentiment: $SENTIMENT"
|
|
129
|
-
|
|
130
|
-
# Restore voice
|
|
131
|
-
if [[ -n "$VOICE" ]]; then
|
|
132
|
-
echo "$VOICE" > .claude/tts-voice.txt 2>/dev/null || echo "$VOICE" > "$HOME/.claude/tts-voice.txt"
|
|
133
|
-
fi
|
|
134
|
-
|
|
135
|
-
# Restore personality
|
|
136
|
-
if [[ -n "$PERSONALITY" ]] && [[ "$PERSONALITY" != "normal" ]]; then
|
|
137
|
-
echo "$PERSONALITY" > .claude/tts-personality.txt 2>/dev/null || echo "$PERSONALITY" > "$HOME/.claude/tts-personality.txt"
|
|
138
|
-
fi
|
|
139
|
-
|
|
140
|
-
# Restore sentiment
|
|
141
|
-
if [[ -n "$SENTIMENT" ]]; then
|
|
142
|
-
echo "$SENTIMENT" > .claude/tts-sentiment.txt 2>/dev/null || echo "$SENTIMENT" > "$HOME/.claude/tts-sentiment.txt"
|
|
143
|
-
fi
|
|
144
|
-
|
|
145
|
-
# Clean up backup
|
|
146
|
-
rm -f "$BACKUP_FILE"
|
|
147
|
-
else
|
|
148
|
-
echo "❌ BMAD voice plugin disabled"
|
|
149
|
-
echo "⚠️ No previous settings found to restore"
|
|
150
|
-
echo "AgentVibes will use current voice/personality settings"
|
|
151
|
-
fi
|
|
152
|
-
|
|
153
|
-
rm -f "$ENABLED_FLAG"
|
|
154
|
-
}
|
|
155
|
-
|
|
156
|
-
# List all mappings
|
|
157
|
-
list_mappings() {
|
|
158
|
-
if [[ ! -f "$PLUGIN_FILE" ]]; then
|
|
159
|
-
echo "❌ Plugin file not found: $PLUGIN_FILE"
|
|
160
|
-
return 1
|
|
161
|
-
fi
|
|
162
|
-
|
|
163
|
-
echo "📊 BMAD Agent Voice Mappings:"
|
|
164
|
-
echo ""
|
|
165
|
-
|
|
166
|
-
grep "^| " "$PLUGIN_FILE" | grep -v "Agent ID" | grep -v "^|---" | \
|
|
167
|
-
while IFS='|' read -r _ agent_id name voice personality _; do
|
|
168
|
-
agent_id=$(echo "$agent_id" | sed 's/^[[:space:]]*//;s/[[:space:]]*$//')
|
|
169
|
-
name=$(echo "$name" | sed 's/^[[:space:]]*//;s/[[:space:]]*$//')
|
|
170
|
-
voice=$(echo "$voice" | sed 's/^[[:space:]]*//;s/[[:space:]]*$//')
|
|
171
|
-
personality=$(echo "$personality" | sed 's/^[[:space:]]*//;s/[[:space:]]*$//')
|
|
172
|
-
|
|
173
|
-
[[ -n "$agent_id" ]] && echo " $agent_id → $voice [$personality]"
|
|
174
|
-
done
|
|
175
|
-
}
|
|
176
|
-
|
|
177
|
-
# Set voice for agent
|
|
178
|
-
set_agent_voice() {
|
|
179
|
-
local agent_id="$1"
|
|
180
|
-
local voice="$2"
|
|
181
|
-
local personality="${3:-normal}"
|
|
182
|
-
|
|
183
|
-
if [[ ! -f "$PLUGIN_FILE" ]]; then
|
|
184
|
-
echo "❌ Plugin file not found: $PLUGIN_FILE"
|
|
185
|
-
return 1
|
|
186
|
-
fi
|
|
187
|
-
|
|
188
|
-
# Check if agent exists
|
|
189
|
-
if ! grep -q "^| $agent_id " "$PLUGIN_FILE"; then
|
|
190
|
-
echo "❌ Agent '$agent_id' not found in plugin"
|
|
191
|
-
return 1
|
|
192
|
-
fi
|
|
193
|
-
|
|
194
|
-
# Update the voice and personality in the table
|
|
195
|
-
sed -i.bak "s/^| $agent_id |.*| .* | .* |$/| $agent_id | $(grep "^| $agent_id " "$PLUGIN_FILE" | awk -F'|' '{print $3}') | $voice | $personality |/" "$PLUGIN_FILE"
|
|
196
|
-
|
|
197
|
-
echo "✅ Updated $agent_id → $voice [$personality]"
|
|
198
|
-
}
|
|
199
|
-
|
|
200
|
-
# Show status
|
|
201
|
-
show_status() {
|
|
202
|
-
# Check for BMAD installation
|
|
203
|
-
local bmad_installed="false"
|
|
204
|
-
if [[ -f ".bmad-core/install-manifest.yaml" ]]; then
|
|
205
|
-
bmad_installed="true"
|
|
206
|
-
fi
|
|
207
|
-
|
|
208
|
-
if [[ $(is_plugin_enabled) == "true" ]]; then
|
|
209
|
-
echo "✅ BMAD voice plugin: ENABLED"
|
|
210
|
-
if [[ "$bmad_installed" == "true" ]]; then
|
|
211
|
-
echo "🔍 BMAD detected: Auto-enabled"
|
|
212
|
-
fi
|
|
213
|
-
else
|
|
214
|
-
echo "❌ BMAD voice plugin: DISABLED"
|
|
215
|
-
if [[ "$bmad_installed" == "true" ]]; then
|
|
216
|
-
echo "⚠️ BMAD detected but plugin disabled (enable with: /agent-vibes-bmad enable)"
|
|
217
|
-
fi
|
|
218
|
-
fi
|
|
219
|
-
echo ""
|
|
220
|
-
list_mappings
|
|
221
|
-
}
|
|
222
|
-
|
|
223
|
-
# Edit plugin file
|
|
224
|
-
edit_plugin() {
|
|
225
|
-
if [[ ! -f "$PLUGIN_FILE" ]]; then
|
|
226
|
-
echo "❌ Plugin file not found: $PLUGIN_FILE"
|
|
227
|
-
return 1
|
|
228
|
-
fi
|
|
229
|
-
|
|
230
|
-
echo "Opening $PLUGIN_FILE for editing..."
|
|
231
|
-
echo "Edit the markdown table to change voice mappings"
|
|
232
|
-
}
|
|
233
|
-
|
|
234
|
-
# Main command dispatcher
|
|
235
|
-
case "${1:-help}" in
|
|
236
|
-
enable)
|
|
237
|
-
enable_plugin
|
|
238
|
-
;;
|
|
239
|
-
disable)
|
|
240
|
-
disable_plugin
|
|
241
|
-
;;
|
|
242
|
-
status)
|
|
243
|
-
show_status
|
|
244
|
-
;;
|
|
245
|
-
list)
|
|
246
|
-
list_mappings
|
|
247
|
-
;;
|
|
248
|
-
set)
|
|
249
|
-
if [[ -z "$2" ]] || [[ -z "$3" ]]; then
|
|
250
|
-
echo "Usage: bmad-voice-manager.sh set <agent-id> <voice> [personality]"
|
|
251
|
-
exit 1
|
|
252
|
-
fi
|
|
253
|
-
set_agent_voice "$2" "$3" "$4"
|
|
254
|
-
;;
|
|
255
|
-
get-voice)
|
|
256
|
-
get_agent_voice "$2"
|
|
257
|
-
;;
|
|
258
|
-
get-personality)
|
|
259
|
-
get_agent_personality "$2"
|
|
260
|
-
;;
|
|
261
|
-
edit)
|
|
262
|
-
edit_plugin
|
|
263
|
-
;;
|
|
264
|
-
*)
|
|
265
|
-
echo "Usage: bmad-voice-manager.sh {enable|disable|status|list|set|get-voice|get-personality|edit}"
|
|
266
|
-
echo ""
|
|
267
|
-
echo "Commands:"
|
|
268
|
-
echo " enable Enable BMAD voice plugin"
|
|
269
|
-
echo " disable Disable BMAD voice plugin"
|
|
270
|
-
echo " status Show plugin status and mappings"
|
|
271
|
-
echo " list List all agent voice mappings"
|
|
272
|
-
echo " set <id> <voice> Set voice for agent"
|
|
273
|
-
echo " get-voice <id> Get voice for agent"
|
|
274
|
-
echo " get-personality <id> Get personality for agent"
|
|
275
|
-
echo " edit Edit plugin configuration"
|
|
276
|
-
exit 1
|
|
277
|
-
;;
|
|
278
|
-
esac
|
|
@@ -1,190 +0,0 @@
|
|
|
1
|
-
#!/bin/bash
|
|
2
|
-
# Language Manager for AgentVibes
|
|
3
|
-
# Manages language settings and multilingual voice selection
|
|
4
|
-
|
|
5
|
-
# Determine project or global config
|
|
6
|
-
# Use logical path (not physical) to handle symlinked .claude directories
|
|
7
|
-
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
|
|
8
|
-
CLAUDE_DIR="$(cd "$SCRIPT_DIR/.." 2>/dev/null && pwd)"
|
|
9
|
-
|
|
10
|
-
# Check if we have a project-local .claude directory
|
|
11
|
-
if [[ -d "$CLAUDE_DIR" ]] && [[ "$CLAUDE_DIR" != "$HOME/.claude" ]]; then
|
|
12
|
-
LANGUAGE_FILE="$CLAUDE_DIR/tts-language.txt"
|
|
13
|
-
else
|
|
14
|
-
LANGUAGE_FILE="$HOME/.claude/tts-language.txt"
|
|
15
|
-
mkdir -p "$HOME/.claude"
|
|
16
|
-
fi
|
|
17
|
-
|
|
18
|
-
# Language to multilingual voice mapping
|
|
19
|
-
declare -A LANGUAGE_VOICES=(
|
|
20
|
-
["spanish"]="Antoni"
|
|
21
|
-
["french"]="Rachel"
|
|
22
|
-
["german"]="Domi"
|
|
23
|
-
["italian"]="Bella"
|
|
24
|
-
["portuguese"]="Matilda"
|
|
25
|
-
["chinese"]="Antoni"
|
|
26
|
-
["japanese"]="Antoni"
|
|
27
|
-
["korean"]="Antoni"
|
|
28
|
-
["russian"]="Domi"
|
|
29
|
-
["polish"]="Antoni"
|
|
30
|
-
["dutch"]="Rachel"
|
|
31
|
-
["turkish"]="Antoni"
|
|
32
|
-
["arabic"]="Antoni"
|
|
33
|
-
["hindi"]="Antoni"
|
|
34
|
-
["swedish"]="Rachel"
|
|
35
|
-
["danish"]="Rachel"
|
|
36
|
-
["norwegian"]="Rachel"
|
|
37
|
-
["finnish"]="Rachel"
|
|
38
|
-
["czech"]="Domi"
|
|
39
|
-
["romanian"]="Rachel"
|
|
40
|
-
["ukrainian"]="Domi"
|
|
41
|
-
["greek"]="Antoni"
|
|
42
|
-
["bulgarian"]="Domi"
|
|
43
|
-
["croatian"]="Domi"
|
|
44
|
-
["slovak"]="Domi"
|
|
45
|
-
)
|
|
46
|
-
|
|
47
|
-
# Supported languages list
|
|
48
|
-
SUPPORTED_LANGUAGES="spanish, french, german, italian, portuguese, chinese, japanese, korean, polish, dutch, turkish, russian, arabic, hindi, swedish, danish, norwegian, finnish, czech, romanian, ukrainian, greek, bulgarian, croatian, slovak"
|
|
49
|
-
|
|
50
|
-
# Function to set language
|
|
51
|
-
set_language() {
|
|
52
|
-
local lang="$1"
|
|
53
|
-
|
|
54
|
-
# Convert to lowercase
|
|
55
|
-
lang=$(echo "$lang" | tr '[:upper:]' '[:lower:]')
|
|
56
|
-
|
|
57
|
-
# Handle reset/english
|
|
58
|
-
if [[ "$lang" == "reset" ]] || [[ "$lang" == "english" ]] || [[ "$lang" == "en" ]]; then
|
|
59
|
-
if [[ -f "$LANGUAGE_FILE" ]]; then
|
|
60
|
-
rm "$LANGUAGE_FILE"
|
|
61
|
-
echo "✓ Language reset to English (default)"
|
|
62
|
-
else
|
|
63
|
-
echo "Already using English (default)"
|
|
64
|
-
fi
|
|
65
|
-
return 0
|
|
66
|
-
fi
|
|
67
|
-
|
|
68
|
-
# Check if language is supported
|
|
69
|
-
if [[ ! " ${!LANGUAGE_VOICES[@]} " =~ " ${lang} " ]]; then
|
|
70
|
-
echo "❌ Language '$lang' not supported"
|
|
71
|
-
echo ""
|
|
72
|
-
echo "Supported languages:"
|
|
73
|
-
echo "$SUPPORTED_LANGUAGES"
|
|
74
|
-
return 1
|
|
75
|
-
fi
|
|
76
|
-
|
|
77
|
-
# Save language
|
|
78
|
-
echo "$lang" > "$LANGUAGE_FILE"
|
|
79
|
-
|
|
80
|
-
# Get recommended voice
|
|
81
|
-
local recommended_voice="${LANGUAGE_VOICES[$lang]}"
|
|
82
|
-
|
|
83
|
-
echo "✓ Language set to: $lang"
|
|
84
|
-
echo "📢 Recommended multilingual voice: $recommended_voice"
|
|
85
|
-
echo ""
|
|
86
|
-
echo "TTS will now speak in $lang using multilingual voices."
|
|
87
|
-
echo "Switch voice with: /agent-vibes:switch \"$recommended_voice\""
|
|
88
|
-
}
|
|
89
|
-
|
|
90
|
-
# Function to get current language
|
|
91
|
-
get_language() {
|
|
92
|
-
if [[ -f "$LANGUAGE_FILE" ]]; then
|
|
93
|
-
local lang=$(cat "$LANGUAGE_FILE")
|
|
94
|
-
local recommended_voice="${LANGUAGE_VOICES[$lang]}"
|
|
95
|
-
echo "Current language: $lang"
|
|
96
|
-
echo "Recommended voice: $recommended_voice"
|
|
97
|
-
else
|
|
98
|
-
echo "Current language: english (default)"
|
|
99
|
-
echo "No multilingual voice required"
|
|
100
|
-
fi
|
|
101
|
-
}
|
|
102
|
-
|
|
103
|
-
# Function to get language for use in other scripts
|
|
104
|
-
get_language_code() {
|
|
105
|
-
if [[ -f "$LANGUAGE_FILE" ]]; then
|
|
106
|
-
cat "$LANGUAGE_FILE"
|
|
107
|
-
else
|
|
108
|
-
echo "english"
|
|
109
|
-
fi
|
|
110
|
-
}
|
|
111
|
-
|
|
112
|
-
# Function to check if current voice supports language
|
|
113
|
-
is_voice_multilingual() {
|
|
114
|
-
local voice="$1"
|
|
115
|
-
|
|
116
|
-
# List of multilingual voices
|
|
117
|
-
local multilingual_voices=("Antoni" "Rachel" "Domi" "Bella" "Charlotte" "Matilda")
|
|
118
|
-
|
|
119
|
-
for mv in "${multilingual_voices[@]}"; do
|
|
120
|
-
if [[ "$voice" == "$mv" ]]; then
|
|
121
|
-
return 0
|
|
122
|
-
fi
|
|
123
|
-
done
|
|
124
|
-
|
|
125
|
-
return 1
|
|
126
|
-
}
|
|
127
|
-
|
|
128
|
-
# Function to get best voice for current language
|
|
129
|
-
get_best_voice_for_language() {
|
|
130
|
-
local lang=$(get_language_code)
|
|
131
|
-
|
|
132
|
-
if [[ "$lang" == "english" ]]; then
|
|
133
|
-
# No specific multilingual voice needed for English
|
|
134
|
-
echo ""
|
|
135
|
-
return
|
|
136
|
-
fi
|
|
137
|
-
|
|
138
|
-
# Return recommended voice for language
|
|
139
|
-
echo "${LANGUAGE_VOICES[$lang]}"
|
|
140
|
-
}
|
|
141
|
-
|
|
142
|
-
# Main command handler
|
|
143
|
-
case "${1:-}" in
|
|
144
|
-
set)
|
|
145
|
-
if [[ -z "$2" ]]; then
|
|
146
|
-
echo "Usage: language-manager.sh set <language>"
|
|
147
|
-
exit 1
|
|
148
|
-
fi
|
|
149
|
-
set_language "$2"
|
|
150
|
-
;;
|
|
151
|
-
get)
|
|
152
|
-
get_language
|
|
153
|
-
;;
|
|
154
|
-
code)
|
|
155
|
-
get_language_code
|
|
156
|
-
;;
|
|
157
|
-
check-voice)
|
|
158
|
-
if [[ -z "$2" ]]; then
|
|
159
|
-
echo "Usage: language-manager.sh check-voice <voice-name>"
|
|
160
|
-
exit 1
|
|
161
|
-
fi
|
|
162
|
-
if is_voice_multilingual "$2"; then
|
|
163
|
-
echo "yes"
|
|
164
|
-
else
|
|
165
|
-
echo "no"
|
|
166
|
-
fi
|
|
167
|
-
;;
|
|
168
|
-
best-voice)
|
|
169
|
-
get_best_voice_for_language
|
|
170
|
-
;;
|
|
171
|
-
list)
|
|
172
|
-
echo "Supported languages and recommended voices:"
|
|
173
|
-
echo ""
|
|
174
|
-
for lang in "${!LANGUAGE_VOICES[@]}"; do
|
|
175
|
-
printf "%-15s → %s\n" "$lang" "${LANGUAGE_VOICES[$lang]}"
|
|
176
|
-
done | sort
|
|
177
|
-
;;
|
|
178
|
-
*)
|
|
179
|
-
echo "AgentVibes Language Manager"
|
|
180
|
-
echo ""
|
|
181
|
-
echo "Usage:"
|
|
182
|
-
echo " language-manager.sh set <language> Set language"
|
|
183
|
-
echo " language-manager.sh get Get current language"
|
|
184
|
-
echo " language-manager.sh code Get language code only"
|
|
185
|
-
echo " language-manager.sh check-voice <name> Check if voice is multilingual"
|
|
186
|
-
echo " language-manager.sh best-voice Get best voice for current language"
|
|
187
|
-
echo " language-manager.sh list List all supported languages"
|
|
188
|
-
exit 1
|
|
189
|
-
;;
|
|
190
|
-
esac
|