P108  NOTES 2/4AMOGH.CLOUD--:--
Notes2/4

When silence turned into a request

I limited what Piaa's speech-to-text could write and forgot to allow 'nothing'. So on a silent mic it made up a sentence, and Piaa answered it.

LearnedOct 2026

Piaa, my voice assistant, turns what I say into text with a small speech-to-text model. That model first decides which language it is hearing, then writes down the words. One day an English sentence of mine came back written as a Chinese phrase.

So I added a rule to that step. It's a grammar: a set of allowed outputs that the model's answer has to fit. The language could only be English or Hindi, and the text could only use Latin or Devanagari letters, digits and punctuation.

Soon after, Piaa started answering a request I never made.

What went wrong

The speech model has its own way of saying that there's no speech: it labels the language "None" and writes nothing. My grammar didn't include "None". So when the mic picked up silence or background noise, the model wasn't allowed to say "nothing here". It had to pick a language and write something.

What it wrote was its own instruction, roughly "transcribe the audio to text, language English". Piaa then sent that sentence to the main model as if I had said it, and answered it. This happened 8 fake requests across two sessions that morning.

I found it by reading the session logs, where there was a request that nobody had spoken.

How I checked it

I played clips of silence and of noise through the speech model three ways:

  • With no grammar, it came back as "None" with no text, which is the correct answer.
  • With my old grammar, it came back with its own instruction as the text.
  • With "None" allowed, it came back empty again, and Piaa already ignores an empty transcript.

With the fix, real speech came out exactly as before, and a Hindi sentence still came through in Devanagari.

The fix

There are two parts. The grammar now allows "None". And there's a second guard: any transcript that starts with the speech model's own instruction words is dropped and logged as a warning, in case the model finds another way to echo itself.

The test for this has 9 checks, and it runs without a server. Instead of guessing what the model might say, it uses the exact strings the model really returned when I played it silence, noise and speech. It checks that the mic requests carry the grammar, that the grammar allows "None", English and Hindi, that voice notes I upload carry no grammar, that silence comes back empty, that speech comes back as speech, that an echoed instruction is treated as silence in any letter case, and that a real sentence which only mentions transcribing is kept.

What I took from it

When you limit what a model may answer, the limit has to include its way of saying "there's nothing here". If it doesn't, the model will invent something to say.

That goes beyond speech. A list of allowed categories needs an "other" or "none". A strict output format needs a way to say "I couldn't find it". Otherwise the model fills the gap with the most likely-looking thing it can produce, and the result looks perfectly valid.

Seen it differently, or hit the same wall? Email me.
Written by me.

hi@amogh.cloud · Resume