Skip to content

feat: add voice-mode plugin with /voice command#33918

Open
anmolp1 wants to merge 1 commit into
anthropics:mainfrom
anmolp1:fix/voice-command-plugin
Open

feat: add voice-mode plugin with /voice command#33918
anmolp1 wants to merge 1 commit into
anthropics:mainfrom
anmolp1:fix/voice-command-plugin

Conversation

@anmolp1

@anmolp1 anmolp1 commented Mar 13, 2026

Copy link
Copy Markdown

Summary

Adds a voice-mode plugin with a /voice command so the startup banner instruction actually works for plugin-enabled users.

The startup banner says ✻ Voice mode is now available · /voice to enable, but on some versions this returns "Unknown skill: voice". This plugin bridges that gap by providing a /voice command that manages voiceEnabled in ~/.claude/settings.local.json.

Closes #33914

What's included

  • plugins/voice-mode/commands/voice.md — Slash command supporting /voice, /voice on, /voice off, and /voice status
  • plugins/voice-mode/.claude-plugin/plugin.json — Plugin manifest
  • Marketplace registration — Added to .claude-plugin/marketplace.json under the accessibility category

Design decisions

  • Writes to settings.local.json (not settings.json) to respect the user-local / version-controlled split
  • Preserves existing settings via jq merge ('. + {"voiceEnabled": true}'), never overwrites the file
  • Falls back gracefully if jq is unavailable — provides manual instructions instead of failing
  • Uses model: haiku since the operation is simple (read JSON, toggle a boolean, write JSON)

Note on built-in /voice

Recent Claude Code versions (tested on v2.1.74) appear to have a built-in /voice command that writes to settings.json. This plugin serves as:

  • A fallback for versions where /voice is not yet recognized
  • A reference implementation showing how settings-toggling commands can be packaged as plugins
  • A discoverable workaround users can install today via /plugin install voice-mode

Test plan

  • Plugin JSON and marketplace JSON are valid
  • Command frontmatter parses correctly (description, allowed-tools, model)
  • Enable: jq '. + {"voiceEnabled": true}' sets the flag without dropping existing keys
  • Disable: jq '. + {"voiceEnabled": false}' sets the flag without dropping existing keys
  • Idempotent: enabling when already enabled is a no-op
  • Full toggle cycle preserves all original settings keys
  • Creating settings.local.json from scratch produces valid JSON
  • Marketplace entry points to a valid source directory
  • End-to-end: /plugin install voice-mode/voice enables voice mode (requires interactive session)

Validation results

# Test Result
1 Status check reads voiceEnabled PASS
2 Enable sets voiceEnabled: true PASS
3 Existing settings preserved after enable PASS
4 Idempotent enable (no-op when already on) PASS
5 Disable sets voiceEnabled: false PASS
6 Re-enable after disable PASS
7 All original keys survive full toggle cycle PASS
8 Create settings file from scratch PASS
9 Command frontmatter valid PASS
10 Marketplace entry valid and path exists PASS

🤖 Generated with Claude Code

The startup banner tells users to run /voice to enable voice mode, but
/voice is not a recognized command. This plugin adds a /voice command
that can enable, disable, or check the status of voice mode by managing
the voiceEnabled setting in ~/.claude/settings.local.json.

Closes anthropics#33914

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Startup message "/voice to enable" is misleading — /voice is not a valid command

1 participant