Speech recognition
: A bunch of people interested in speech recognition and voice control interfaces for Emacs hang out in the Emacslisten matrix room. Come join us!
I'm currently using Orukeet and my fork of natrys/whisper.el (upstream) so that I can transcribe segments of audio or continuously queue transcription, run the output through various functions, and save the audio. I use a custom local server (asr.py) to do voice activity detection with Silero to segment my speech and simulate continuous speech recognition, and I send the current audio segment to another local server (orukeet-server.py) that runs the speech recognition. I use phony.el to define speech commands using grammar and I also have some older commands defined via speech-input.
Why I'm interested in speech recognition: (more details)
- Sometimes I have a hard time remembering my train of thought. (Limitations of working memory!) It's useful to quickly capture my thoughts faster than I can type, even if the transcription has errors, and I can replay the recording if needed.
- Speech would be a great interface for mobile computing.
- Any number of reasons can make it difficult to type, either temporarily or permanently, such as accidents, disease, or physical decline. My mom has Parkinson's and her tremors make it hard for type most of the time. I know other people who've broken bones or gotten RSI. I enjoy writing and programming, so it makes sense to figure out alternative ways of input before I really need them.
- I'd like to be able to use my computer while my hands are busy with sewing or knitting.
- A voice interface could open up interesting possibilities. I'm not quite brave enough to give AI agents full access to my Emacs, but maybe someday.
Here's what I've figured out so far:
- ☑ Create Org tasks by voice
- ☑ Call M-x commands by voice: sacha-whisper-execute-extended-command
- ☑ Navigate to links in my favourites: sacha-whisper-open-favorite
- ☑ Keep track of when I say my target phrases: sacha-learn-lang-notice-bingo-words
- ☑ Control OBS so I can start/stop streaming/recording; use ffmpeg to save the last X minutes of the current recording to a clip
- ☑ Save the timestamped recordings and transcripts to allow review or assembly into other clips
- ☑ Automatically capture screenshots as well
- ☑ Save notes to an Org Mode task that isn't displayed on screen, such as my currently clocked in task or a new task in my inbox.
- ☑ Queue multiple speech recognition tasks to simulate continuous speech recognition with higher accuracy even on my older machine (Lenovo P52).
- ☑ Use Google Web Speech API or other speech recognition engines for real-time results if needed, despite lower accuracy. Direct other applications into it as input, and direct the output into Emacs buffers, IRC channels, Etherpad shared documents, and other targets. Streaming speech recognition into Emacs using Google Chrome Web Speech API
- ☑ Dictate short text into other applications outside Emacs using a global keyboard shortcut, while still being able to take advantage of the text substitution that I do in Emacs. (described in Emacs Carnival Oct 2026: Exploring keys and voice input in Emacs - see xdotool-emacs)
- ☑ Expand simple yasnippets by saying "Okay, expand (name of snippet)".
- ☑ Categorize Emacs News items by voice in Org Mode
- This is a test
- ☑ Cut, copy, and paste.
- ☑ Select and act on different logical elements such as sentences or paragraphs.
Some things I'd like to be able to do by voice:
- Support multiple wake words in addition to "Okay, …"
- Select a word or a range of text.
- Press keyboard shortcuts. I might need to use xdotool to simulate keypresses.
- Insert names of symbols, such as with-current-buffer.
- Answer yes or no prompts. This is a little tricky because y-or-n-p is a blocking function and Emacs is single-threaded, so I might need to have an external process that uses xdotool to simulate keystrokes.
- Select an option by number or letter. This is similar to the y-or-n-p problem, just with a wider range of choices.
- Monitor simultaneous EmacsConf BigBlueButton web conferences for keywords so I can tell when a speaker needs my help.
Related projects by other people: