add-dictation — Claude Code skill: Claude Code speech-to-text in your
This skill wires Claude speech recognition into your own app: a mic button, live captions, or transcripts of audio you already have.
npx skills add cursor/plugins --skill add-dictation -a claude-codeWhat add-dictation does
The skill fires on /add-dictation, on the word “Dictate”, or when you ask for a transcription. It reads your project first: the input component where text should land, the server framework, the package manager. Then it writes the code for that stack.
Two routes. Batch mode is one POST https://api.x.ai/v1/stt — the client records with MediaRecorder, posts the blob to your own route, and the server forwards it as multipart/form-data. Streaming mode uses wss://api.x.ai/v1/stt and exists for the case where words must show up while the person is still talking. Browsers cannot attach headers to a WebSocket, so a backend relay holds the key.
XAI_API_KEY stays server side. Never ship it in a client bundle, and do not paste it into chat. For the model id the skill points you at the model-selection section of the Anthropic docs rather than at its own examples. Cursor itself has no microphone, so what gets wired is your app, not the IDE.
What it helps with
- put a mic button in the composer
- show text on screen while someone speaks
- transcribe an uploaded file or a URL
- build subtitles with per-word timings
- split a meeting recording by speaker
Example prompts for the agent
- Add dictation to our app composer with Claude STT
- Show live captions while the mic is recording
- Transcribe this file and give me the text with timestamps
How to install add-dictation
1Skills CLI (Vercel)
npx skills add cursor/plugins --skill add-dictation -a claude-code2Manually: put the files in place
~/.claude/skills/add-dictation/SKILL.mdCopy the whole skill folder; for one project use .claude/skills/add-dictation/
1Skills CLI (Vercel)
npx skills add cursor/plugins --skill add-dictation -a codex2Manually: put the files in place
.agents/skills/add-dictation/SKILL.mdFor all projects use ~/.agents/skills/
1Skills CLI (Vercel)
npx skills add cursor/plugins --skill add-dictation -a cursor2Manually: put the files in place
.cursor/skills/add-dictation/SKILL.mdCursor also reads .agents/skills/ and .claude/skills/
1GitHub CLI
gh skill install cursor/plugins add-dictation2Manually: put the files in place
.github/skills/add-dictation/SKILL.md1Skills CLI (Vercel)
npx skills add cursor/plugins --skill add-dictation -a gemini-cli2Platform CLI
gemini skills install https://github.com/cursor/plugins --path grok-voice/skills/add-dictationManually: put the files in place
.devin/skills/add-dictation/SKILL.mdThe legacy .windsurf/skills/ path still works
Skills CLI (Vercel)
npx skills add cursor/plugins --skill add-dictation -a opencodeClaude.ai
Zip the folder and upload it in Settings → Capabilities → Skills
Step by step, with commands for each platform: How to install skills in Claude Code: five ways
Questions about add-dictation
How do I install add-dictation in Claude Code?
Run npx skills add cursor/plugins --skill add-dictation -a claude-code. The skill lands in ~/.claude/skills/add-dictation/SKILL.md.
What does add-dictation do?
It adds Claude speech recognition to your app: a dictation button, live captions, or transcripts of recorded audio and URLs.
Does the skill need an API key?
Yes, XAI_API_KEY. Keep it on the server — a browser cannot set a WebSocket header, so streaming goes through your relay.