@superwhisper/opencode
v0.1.0
Published
SuperWhisper voice integration plugin for OpenCode - get voice notifications when tasks complete
Downloads
106
Maintainers
Readme
@superwhisper/opencode
SuperWhisper voice integration plugin for OpenCode.
Get voice notifications when your AI coding tasks complete, and respond with your voice. Your voice response is sent back to OpenCode as the next prompt, creating a hands-free coding loop.
Requirements
- OpenCode v1.0+
- SuperWhisper app for macOS
Installation
Add to your opencode.json:
{
"plugin": ["@superwhisper/opencode"]
}Or install locally:
mkdir -p ~/.config/opencode/plugin && curl -fsSL -o ~/.config/opencode/plugin/superwhisper.ts \
https://raw.githubusercontent.com/superwhisper/opencode-superwhisper/main/src/index.tsThe plugin auto-loads from ~/.config/opencode/plugin/ — no config changes needed.
How It Works
You speak → OpenCode works → Plugin notifies SuperWhisper → You speak back → loop- Task completes → OpenCode fires
session.idle - Plugin extracts the response → fetches the last assistant message
- Plugin notifies SuperWhisper → writes message to temp file, opens deeplink
- SuperWhisper shows notification → displays summary with voice recording UI
- You speak your response → SuperWhisper transcribes and writes to response file
- Plugin reads response → polls the response file, sends back to OpenCode
- OpenCode continues → processes your voice input as the next instruction
Events
| OpenCode Event | SuperWhisper Status | Description |
|----------------|---------------------|-------------|
| session.idle | completed | Task finished |
| session.error | error | An error occurred |
| permission.asked | permission | Tool needs approval |
| question.asked | question | Agent is asking a question |
Development
bun install
bun test
bun run typecheckLocal Testing
Build and install to your local OpenCode plugin folder:
bun run install-localOr watch for changes and auto-install on save:
bun run devBoth commands bundle the plugin into a single .js file and copy it to ~/.config/opencode/plugin/superwhisper.js. OpenCode picks it up on next session.
Project Structure
src/
index.ts # Plugin entry point and event handlers
types.ts # Types, interfaces, constants
deeplink.ts # Deeplink URL building
message.ts # Message extraction and summary
poll.ts # Response file polling
normalize.ts # Question/permission response normalization
index.test.ts # TestsLicense
MIT
