Voice Recognition extension without Google Dialogue


Hello everyone, I also want to try to make an extension :wink:
Community opinion is very important for me.

This is an alternate version of the Voice Recognition Component

New Features:

  • Ability to disable the Google dialogue,
  • Turn off the sound prompt signal,
  • Continuous listening (hands free),
    and other…

Can be used in robots, running Android; Voice assistants and etc.

New properties (default all is false):

EnableGoogleDialog (boolean) - if “true”, then the recognition works in normal mode. No additional features (described below) is working.

MuteAudio (boolean) - if is “true”, then Google prompt sound signal are disabled before and after recognition. In reality, all sounds are turned off, but only for the duration of the listening. That, after recognition, or recognition errors, the sound immediately turns on.

ContinuouslyRecognitionEnabled (boolean) – in case the “false”, if the user is silent, the component will return an empty string result and generate “No voice input” error. Otherwise, the audition just automatically resumes every time. A related error does not occur.

PreferOffLine (boolean) - if “true to indicate whether to only use an offline speech recognition engine. The default is false, meaning that either network or offline recognition engines may be used. (Starting with Android version 6.0).

LastError (String) read-only - A description of the errors is stored here, if they occurred during the last recognition. When you start a new service, this information is erased.

ExtraPrompt (String) - when the Google dialog is displayed, the inscription on it can be replaced with its own. If there is an empty line in its field, then the inscription remains Google.

New method:

StopASR () - used to forcefully stop the Continuously Recognition process.

New Event:

OnError () - when error of recognizing is occur, the user receive the description and saves it in LastError.

Possibles errors:

“Audio recording error”
“Client side error”
“Insufficient permissions”
“Network error”
“Network timeout”
“No speech input”, “No match” (automatic restart in the Continuously Recognition mode )
“RecognitionService busy”
“Error from server”
“Didn’t understand, please try again”
“Speech Recognizer not Available!”

ScSpeechRecognizerV2.aix (15.8 KB)
TestASR.aia (18.1 KB) Created by MIT App Inventor

New in the Version 3:

New Properties KeepScreenOn (Boolean, default is False) - If you app window is visible to the user, keep the device’s screen turned on and bright

New Event OnRmsChanged Event occurs when Microphone input is change. Gives an integer 0…10. It is used to dynamically indicate the microphone status in the voice recognition process.

ScSpeechRecognizerV3.aix (16.8 KB)
TEST_ASR_v3.aia (20.1 KB)

TextTo Speech with Attributes

Actually removing the dialog is not allowed. This is invading User Privacy, do you wanna be sued?


Never heard of it. Where is it written? The standard component uses the built-in Google service, and I use the API Android. What is the crime? :slight_smile:


As I said, invasion of User Privacy. Who knows what the App Maker could be doing, they could be recording someone’s conversation… Listening to other things while in the app, wouldn’t you be concerned if you know someone you didn’t know was collecting things you were saying and doing? If I were a User of your app, I’d delete it if I ever find out.


thank you for your contribution…
this sounds like a great extension…
you might want to provide a screenshot of the properties, methods and events the extension is providing…


Trying to push the limits! Snippets, Tutorials and Extensions from Pura Vida Apps by Taifun.


I use it for an autonomous voice-controled robot. It would be funny if I chased him to tap the screen.


Thank you very much! I can add pictures, but the use is very simple


By the way, I do not advise buying a smart speaker. They say they overhear!


That’s a nice extension. Good job.:+1:


Please upload a new aia. the name contains a space and that is not allowed in AppyBuilder. I tried to change it but i am unable to upload a new aia with the right name.


The problem is not the name. The example is made in the App Inventor. I’ll try in the AppyBuilder. Apparently they are not completely compatible.
gold.appybuilder.com not working now? Shows me a blank page.


You can export with a space in the name but you can not import with a space in the name.


Thank you very much for this extension, great job!
I also care about the User Privacy because someone might use this extension for wrong reason.


What’s your thoughts about SoundRecorder. It also records without a dialogue.


But you have to press a button and start recording so you know it’s recording. Without the user knowing their audio is being recorded, it’s again Invasion of User Privacy.


I think we all have 2 ears. Someone can use their ears to violate someone’s privacy. But this is not a problem of the ears, but a person who uses them for other purposes. Hope you understand me.


Im gonna say this again, how do you know that? Are you listening to what they’re doing, are you watching what they’re doing… How do you know?


Please stop this discussion. This topic is about the extension, not about what users might do with it. It might be good it might be bad fact is it is a nice addition to all the extensions around.


I would like to thank you very much for the enlargement!
I have been looking for such a way of speech input for my robot for a long time.
Could one still install that the extension reacts to a keyword.

So I imagine it like this:
“Robot” the extension waits for this keyword offline and then gives answer “Yes Master”.
“what time is it” is then retrieved from the Internet by my AI.

So the Smartphone would not have to evaluate always.

thx Alf


Nice Robot :slight_smile:
I could make this addition. But I believe that the Extension should not produce actions that we can implement using standard components.
It is important to know that the service, in Continuously Recognition mode, is restarted every 20 seconds. At the moment of the restart, there is a pause of about 0.5 seconds when the service is not listening.