I Got Real Speech Recognition Running on a $10 Chip (Whistle)

12:352 min readBetter Stack10/19/2026Computing/Software · Consumer Electronics

Key Takeaway

Running the 9-megabyte Whistle speech-to-text model on a 10-dollar ESP32-S3 microcontroller is achieved by trimming decoder layers, optimizing matrix math for dual cores, and utilizing 8-bit integer vector calculations.

Highlights

  • Whistle is a 16.9 megabyte speech-to-text model released by Cactus Compute on October 2nd.

  • The model runs completely offline on an ESP32-S3 microcontroller costing 10 dollars with no Wi-Fi or Bluetooth connection.

  • Whistle supports English, German, French, Spanish, Italian, Dutch, and Polish while automatically detecting the spoken language.

  • A trimmed four-layer version of the decoder fits onto the microcontroller flash storage after stripping out extra layers and taking up about 9 megabytes.

  • Short spoken phrases achieve an 82 to 93 percent recognition rate, whereas single standalone words work only 44 percent of the time.

Timeline

  1. Overview of Whistle and Flash Memory Constraints

    Demonstrations show the microcontroller responding to spoken voice commands in multiple languages by changing built-in LED colors. Cactus Compute developed Whistle as a small speech-to-text model that supports word timestamps and direct audio embeddings without writing transcripts. Unlike pre-built engine packages for phones and laptops, running this model on an ESP32 chip requires custom implementation.

    • An ESP32-S3 microcontroller running offline processes offline voice commands via a tiny microphone and button.
    • Whistle is almost nine times smaller than OpenAI's WhisperBase model while beating it on LibriSpeech benchmarks.
    • The complete model file size is 16.9 megabytes, which exceeds the 16 megabytes of flash storage available on the board.
  2. Trimming the Model and Audio Processing Pipeline

    A custom tool strips unnecessary layers from the decoder to make the file fit inside the flash storage partition alongside firmware. The encoder processes 80 millisecond frames using eight layers where every frame references every other frame in the clip. The decoder writes out text sequentially using cross-attention to check against encoder outputs and n-gram memory tables.

    • The model decoder contains eight layers that can be cut down because each truncated version functions independently.
    • N-gram lookup tables consume 5.3 megabytes, representing nearly a third of the total file size.
    • Audio samples are recorded at 16,000 samples per second and chopped into 10 millisecond slices before convolution layers group them into 80 millisecond frames.
  3. Hardware Setup and Processing Optimization

    Holding the button activates white recording mode, pulses during processing, and executes the requested command. Heavy matrix multiplications are split across both chip cores and moved to 8-bit integers on the vector unit. Testing reveals that full phrases yield up to 93 percent accuracy compared to 44 percent for isolated single-word commands.

    • The hardware setup connects an INMP441 digital microphone and a push button to an ESP32-S3 board using eight wires.
    • Processing time dropped from nearly 24 seconds down to about 10 seconds per command through core load balancing and vector math optimization.
    • Short phrases achieve significantly higher recognition accuracy than single words because the model relies on conversational sentence context.
  4. Transcription Accuracy and Supplemental Performance Tricks

    Custom performance enhancements allow the trimmed microcontroller model to surpass full-size model accuracy benchmarks in specific test categories. Whistle is distributed under the Apache 2.0 license on Hugging Face for public developer tinkering.

    • English color commands achieve a 78 percent success rate that remains stable even with background microphone noise present.
    • Keyword biasing nudges the model toward expected color words whenever confidence drops.
    • A retry rule automatically re-evaluates failed attempts in alternative languages to verify high-confidence outputs.

Description

We ported Cactus Compute’s Whistle, a 16.9 MB speech-to-text model that understands seven languages, to a $10 ESP32-S3 microcontroller, where it runs completely offline with no Wi-Fi and no cloud. To make it fit, we trimmed the model’s decoder down to four layers and sped up the matrix math with 8-bit integers and both CPU cores, so you can hold a button, speak a command, and watch the onboard LED respond. We also break down how Whistle turns your voice into text, and the full project is on GitHub if you want to build one yourself. 🔗 Relevant Links Whistle: https://cactuscompute.com/blog/whistle Whistle on ESP32 S3: https://github.com/andrisgauracs/whistle-esp32 ❤️ More about us Radically better observability stack: https://betterstack.com/ Written tutorials: https://betterstack.com/community/ Example projects: https://github.com/BetterStackHQ 📱 Socials Twitter: https://twitter.com/betterstackhq Instagram: https://www.instagram.com/betterstackhq/ TikTok: https://www.tiktok.com/@betterstack LinkedIn: https://www.linkedin.com/company/betterstack 📌 Chapters: 0:00 Speech-to-text on a $10 chip 0:50 Meet Whistle by Cactus Compute 2:03 Whistle vs OpenAI Whisper 3:04 The model is bigger than the chip 3:45 Shrinking the model to fit 5:06 How speech becomes text 6:46 The hardware 7:59 Live demo 9:42 From 24 s to ~10 s 10:32 Accuracy 11:28 Recap and credits

Write about this video