From a key tap to pasted text, in real open-source code
Short answer: a speech-to-text app records sound as numbers (16,000 samples a second in the app below), hands the model windows of up to 30 seconds, and the model, here OpenAI's Whisper, turns each window into text. Then the app throws out silence and made-up words and pastes the result where your cursor is. We traced that path through MetaWhisp, our open-source Mac app (MIT licence), at release 1.4.7. We read the code; we didn't benchmark anything.
Key takeaways
- After the microphone, every stage works in 16 kHz mono audio, up to the cloud upload.
- Whisper reads 30-second windows (480,000 samples), so longer audio is split, here at a silence.
- Whisper can write words nobody said, so MetaWhisp checks the audio before the model and the text after it.
- In MetaWhisp, pasting into another app takes the clipboard, a synthetic โV and macOS's Accessibility permission. Without that permission, the text waits on the clipboard.
- "On-device" depends on the mode. Dictation stays on the Mac by default; Pro or your own API key on the cloud engine, or a Deepgram or Gemini key for meetings, sends audio out.
How Does Speech to Text Work?
Speech-to-text models like OpenAI's Whisper don't hear words. They get audio as numbers. Whisper cuts it into 30-second chunks and turns each one into a log-Mel spectrogram, a map of which frequencies are loud at each moment. An encoder reads that map and a decoder writes text tokens, one after another.
OpenAI calls Whisper a Transformer sequence-to-sequence model trained on several speech tasks at once. Special tokens tell the one model whether to identify the language, transcribe, translate or decide there's no speech at all. Large-v3, the version MetaWhisp runs on the Mac, was trained on 1 million hours of weakly labeled audio plus 4 million hours of pseudo-labeled audio, and it uses 128 Mel frequency bins instead of 80.

How Does the App Know When to Start Listening?
It watches the modifier keys. In MetaWhisp's default toggle mode, a tap on Right Command (โ) shorter than 0.4 seconds starts recording and the next tap stops it. In push-to-talk mode, holding the key for 0.15 seconds starts it and letting go stops it. macOS only delivers these key events to apps you've allowed under Accessibility.
- How it listens:
NSEventglobal and local monitors on.flagsChanged, reading a device-specific bit (0x10) that tells Right โ from Left (HotkeyService.swift). - Shortcuts don't trigger it: in toggle mode, Right โ pressed together with another key is ignored.
- Accessibility: Apple's docs say key events "may only be monitored if accessibility is enabled". Without it, the app's own log line warns, every hotkey is silently dead.
At the start, the app also notes which app is in front, to paste back into it later. If your text lands somewhere else, see dictation going to the wrong window.
How Does the Microphone Signal Become 16 kHz Audio?
The app asks macOS for the microphone, opens the input through Core Audio and converts every buffer to the format Whisper expects: 16,000 samples a second, one channel, 32-bit floats. The whole dictation stays in memory until you stop, at 64 KB per second of audio, silence included.
Permission comes first, through AVAudioApplication.requestRecordPermission(). MetaWhisp used Apple's AVAudioEngine in earlier versions. The comment at the top of AudioRecordingService.swift says why it stopped: a reset loop with a Bluetooth headset's call profile, and a re-bind that held the main thread. Every recording now captures the input alone:
- InputOnlyCapture.swift opens the Core Audio HAL output unit with input switched on and output off, the setup Apple's Technical Note TN2091 describes.
- The unit delivers mono 32-bit float audio at the device's own sample rate, in 1,024-frame buffers. It converts channels and sample format but not the rate, and TN2091 says to use another converter for that.
- So every buffer goes through
AVAudioConverterto 16 kHz mono.

Which Model Turns the Audio Into Words, and on What Chip?
On the Mac, MetaWhisp runs Whisper large-v3 through WhisperKit 0.16.0, Argmax's Swift package that runs Whisper as Core ML models. The model files come from Argmax's Hugging Face repo, about 3.2 GB in all. The app tells WhisperKit to run the encoder and decoder on the CPU and GPU.
- Four models, not one: Argmax's build is MelSpectrogram, AudioEncoder, TextDecoder and TextDecoderContextPrefill. Its config.json reads openai/whisper-large-v3, with 32 decoder layers and 128 Mel bins.
- Not the turbo model: OpenAI's large-v3-turbo, the one Groq serves for the cloud path, is large-v3 pruned to 4 decoder layers and fine-tuned. Our large-v3-turbo explainer has more.
- A quick start: a small Base model downloads first; large-v3 then installs in the background and swaps in (ModelBootstrap.swift).
- Which chip: WhisperKit's own default for the encoder and decoder is
.cpuAndNeuralEngine. MetaWhisp overrides both to.cpuAndGPU(WhisperKitEngine.swift), and the file's header says it runs entirely on-device using Metal. - Decoding settings: the transcribe task, temperature 0 with at most two temperature fallbacks, a no-speech threshold of 0.6 and WhisperKit's voice-activity chunking. Language detection runs only when the language setting is auto.
- The prompt: only a built-in glossary of English brand names, and only when the language is set to English; on the default auto setting the model gets no prompt. Never your personal dictionary: a code comment says it made Whisper echo the list back on silence.
More on the choice of runtime and model in WhisperKit vs whisper.cpp and Whisper model sizes.
What Happens to Silence, Accidental Taps and Long Recordings?
Before the model runs, MetaWhisp drops anything shorter than 0.3 seconds as an accidental tap and stops if the audio is silent or too quiet. Audio longer than Whisper's 30-second window is split by WhisperKit's voice-activity chunker, which cuts in the middle of the longest silence it finds.
- 4,800 samples or fewer (0.3 seconds at 16 kHz): discarded.
- A signal level (RMS) of exactly 0: reported as a microphone delivering no audio.
- RMS under 0.0003: reported as too quiet and not transcribed.
- Longer than one window: WhisperKit's energy-based detector (threshold 0.02, 0.1-second frames) finds the longest silence in the second half of each window and splits in its middle.
Meetings work differently. Each channel is cut into chunks of about 150 seconds, at the quietest half-second within 15 seconds of each cut point. Each chunk's quiet edges are trimmed, gaps longer than 2 seconds are cut out with 0.25 seconds kept on each side, and a time map puts the words back on the real timeline. Chunks under half a second, or nearly silent, are skipped. More in why Whisper hallucinates when you're silent.
How Is the Raw Transcript Cleaned Before You See It?
OpenAI's model card warns that Whisper's output may include "texts that are not actually spoken". So MetaWhisp checks the text before pasting: it trims known phrases from video subtitles, removes repeated segments and scores the result with Whisper's own confidence numbers. Text flagged as invented is either dropped or put on the clipboard, never pasted.
- Known artifacts: phrases like "thanks for watching" and "subtitles by", and music notes, are trimmed or the result is dropped; repeated segments are removed (WhisperKitEngine.swift).
- Confidence gate: a result is suspect when its average log-probability is below -1.5; when its compression ratio is above 2.4 with low confidence and the text visibly loops; or when its no-speech probability is above 0.5 with low confidence (TranscriptionConfidenceGate.swift). That last check works only on the cloud path: WhisperKit 0.16.0 reports no-speech as 0, so it, and the 0.6 threshold above, never fire on the Mac.
- Suspect text isn't pasted. It goes to the clipboard with a note that โV pastes it anyway.
- The mode: Raw, the default, skips this step. Clean removes a fixed list of Russian filler words, on the Mac. Structured sends the text, not the audio, for an AI cleanup: to the on-device model if it's ready (dictations over 6,000 characters go to the cloud when one is available, and a local failure falls back to it), otherwise to our Pro server, otherwise to your own OpenAI or Cerebras key.
- Dictionary: built-in brand fixes, then your own Dictionary. Exact matches come first, longest first, then fuzzy ones for words of 4 or more ASCII letters, within one edit, or two for Dictionary entries of 8 or more letters.
The Dictionary also learns. After a paste, the app reads the field back through the Accessibility API, and when it sees the same edit twice, it saves it as a correction. Related: Whisper repeating words and custom vocabulary on Mac.
How Does the Text Get Into Another App?
Through the clipboard. MetaWhisp writes the text to the clipboard and reads it back to confirm, up to three tries. If it has Accessibility permission, it brings back the app you were in, waits 0.2 seconds and posts a synthetic โV. Without Accessibility, the text stays on the clipboard with a note to press โV yourself.
The keystroke is posted as CGEvents to the system's HID event tap (TextInsertionService.swift). One side effect: after a dictation, the clipboard holds the dictated text, in place of whatever you'd copied before. The code does have a snapshot routine that puts the old clipboard back. Other features use it (the keyboard-layout fix, selection translation), but dictation doesn't.
Our guide to Mac transcription permissions covers what Accessibility and Screen Recording allow.
Where Does the Audio Go When the Cloud Does the Work?
By default, nowhere: the engine setting starts as on-device. Dictation goes to the cloud only when the engine is set to cloud and you have Pro or your own API key. Then the app packs the 16 kHz audio into a 16-bit WAV and sends it to our server, which passes it to Groq, or, with your own key, straight to Groq or OpenAI.
- Pro: the WAV goes to api.metawhisp.com with your licence key. In our server's code (its October 24, 2026 commit), that endpoint sends it to Groq's whisper-large-v3-turbo, tries Groq up to three times and uses no other provider. Pro switches the engine to cloud once, the first time Pro is activated on a Mac; after that, your choice stays.
- Your own key, no Pro: the app calls Groq (whisper-large-v3-turbo) or OpenAI (whisper-1) directly, as a multipart upload asking for verbose_json. The request timeout grows with the audio, from 60 up to 600 seconds.
- Meetings: with a Deepgram key, the whole meeting goes to Deepgram first; next comes a Gemini key, which sends Google the two streams mixed into one file. Whisper runs on the two streams only if those fail or aren't set, whatever the engine setting says.
Groq's docs cap a file attached to the request at 25 MB; larger files, up to 100 MB on the dev tier, have to be passed by URL, and MetaWhisp attaches the file. A 16-bit, 16 kHz WAV is 32,000 bytes a second, so by our arithmetic 25 MB holds about 13 minutes. We didn't try what happens past that; see the Whisper API file size limit.

How Does a Meeting Recording Tell "Me" From "Them"?
It doesn't recognise voices. MetaWhisp records two streams: your microphone and the Mac's own audio through Apple's ScreenCaptureKit. On the Whisper path, they're transcribed separately and never mixed, so the mic becomes "Me", everything the Mac plays becomes "Them", and the two are merged by timestamp. In a room with one microphone, every voice is "Me".
Meeting Recording is off by default, and so is call auto-start. The system-audio side is an SCStream on the first display with its video shrunk to 2 ร 2 pixels at 1 frame a second, audio on at 48 kHz stereo, and the app's own sound excluded. The app averages the two channels to mono and resamples to 16 kHz, and macOS asks for Screen Recording permission.
If you dictate during a meeting, the meeting's mic pauses so the dictation doesn't land in the transcript. For real speaker labels, see speaker diarization for Zoom calls; for the bot-free approach, meeting transcription without a bot.
Can You Read and Reuse the Code?
Yes. MetaWhisp is MIT-licensed and public on GitHub, and every file named here is at the tag v1.4.7. It's a Mac app for macOS 14 or later, built for Apple silicon. Its packages are WhisperKit, Sparkle for updates, mlx-swift and swift-transformers, with no analytics package. If you want a library rather than an app, start from WhisperKit or OpenAI's Whisper directly.
| Stage | File | What to look at |
|---|---|---|
| Hotkey | HotkeyService.swift | Key monitors, tap and hold timing |
| Capture | InputOnlyCapture.swift | HAL unit, input on, output off |
| Resample | AudioRecordingService.swift | AVAudioConverter to 16 kHz |
| Guards | TranscriptionCoordinator.swift | Length and RMS checks, engine choice |
| Model | WhisperKitEngine.swift | Compute units, decoding options, artifact filter |
| Cloud | CloudWhisperEngine.swift | WAV upload, endpoints, timeout |
| Confidence | TranscriptionConfidenceGate.swift | Log-probability and compression thresholds |
| Cleanup | TextProcessor.swift, CorrectionDictionary.swift | Modes, fuzzy matching |
| Paste | TextInsertionService.swift | Verified clipboard write, โV |
| Meetings | SystemAudioCaptureService.swift, DualStreamMerger.swift | ScreenCaptureKit, the Me and Them merge |
The limits, in one place: Mac only; Accessibility needed for the hotkey and the auto-paste; a first large-v3 download of about 3.2 GB; the dictated text left on the clipboard; only "Me" and "Them" in meetings; no audio-file import; and the cloud routes above. Your own API keys are kept in the macOS Keychain.
FAQ
Does speech to text run on my Mac or in the cloud?
Both exist. In MetaWhisp, dictation runs on the Mac by default. Audio goes out only on the cloud engine: with Pro, which turns that engine on the first time Pro is activated on a Mac, it goes through our server to Groq; with your own Groq or OpenAI key, to that provider. A Deepgram or Gemini key sends meeting audio out.
What audio format does Whisper need?
Whisper works on 16 kHz mono audio. One 30-second window is 480,000 samples, which the Mel stage turns into a 128 by 3,000 grid of features. MetaWhisp converts every microphone buffer to 16 kHz mono with AVAudioConverter, and Groq's docs say its models downsample uploads to 16 kHz mono themselves.
How do apps handle recordings longer than 30 seconds?
They split them. WhisperKit's voice-activity chunker looks for the longest silence in the second half of each 30-second window and cuts in its middle. For meetings, MetaWhisp cuts each channel into chunks of about 150 seconds at the quietest half-second near each cut point, then maps the words back to the real timeline.
Why does Whisper sometimes write words nobody said?
OpenAI's model card says Whisper can output text that wasn't spoken and can repeat itself. Apps work around it. MetaWhisp drops audio that's silent or too quiet, trims known subtitle phrases, removes repeats and checks Whisper's own confidence numbers. Text flagged as invented is dropped or put on the clipboard, never pasted.
How does dictated text get typed into another app?
Through the clipboard. MetaWhisp writes the text to the clipboard, confirms it, brings back the app you were in and posts a synthetic Command-V. That needs the Accessibility permission. Without it, the text waits on the clipboard for you to paste. Either way, the dictated text stays on the clipboard afterwards.
Is WhisperKit the same as Whisper?
No. Whisper is OpenAI's speech recognition model. WhisperKit is Argmax's Swift package that runs Whisper on Apple devices as Core ML models, downloaded from Argmax's Hugging Face repo. It needs macOS 14 or later. Its default compute settings differ from MetaWhisp's, which runs the encoder and decoder on the CPU and GPU.
How we checked
On November 24, 2026, we read MetaWhisp's code at the release tag v1.4.7 (commit aab4df5) and our server's code at its October 24, 2026 commit, plus the OpenAI, Hugging Face, Argmax, Apple and Groq pages listed below. We read the code; we didn't build or run the app for this piece, didn't check what's deployed, and measured nothing.
Related reading
- WhisperKit vs whisper.cpp on Apple Silicon
- Whisper Model Sizes: Tiny to Turbo Compared
- Does Mac Dictation Send Voice to Apple?
Sources
- MetaWhisp: code at tag v1.4.7, licence, Package.swift, ModelBootstrap.swift, plus the files in the table above
- OpenAI: Whisper announcement, README, model card
- Hugging Face: whisper-large-v3, whisper-large-v3-turbo, argmaxinc/whisperkit-coreml
- Argmax: WhisperKit 0.16.0 README, compute defaults, VAD chunker
- Apple: global event monitors, TN2091, AVAudioConverter
- Groq: speech-to-text docs