Suggestion: Expose "energy" to allow for volume monitoring

Author: followkimCreated Sep 15, 2025Updated Sep 15, 2025

Not an issue just a suggestions... please add "energy" as a public variable so that people can monitor it.

In my use case, I updated my local copy to expose "energy" and use it to show a volume meter as the speech is coming in.

            energy = audioop.rms(buffer, source.SAMPLE_WIDTH)  # energy of the audio signal
            self.current_energy = energy

then I pull sr.current_energy and set the volume indicator accordingly.

LOVE YOUR PRODUCT! Thank you very much!

Source: Uberi/speech_recognition