jp15sil24
@TMesserschmidt
I tried the script from the tutorial "Add New AIML Categories with Voice." I encountered no errors, but the file created is always empty. To troubleshoot, I wrote a small script:
saywait("start script")
sleep(500)
controlCommand("Bing Speech Recognition", "StartListening")
sleep(4000)
controlCommand("Bing Speech Recognition", "StopListening")
sleep(1000)
print($BingSpeech)
saywait("script end")
This script runs without errors, but the Bing Speech Recognition does not seem to "listen," as the variable $BingSpeech
is always empty. When I use the Bing Speech Recognition skill manually, it works perfectly with both "Start Recording" and VAD (Voice Activity Detection). It appears that the "StartListening" command in the script does not communicate with the "Bing Speech Recognition" skill.
I have the same issue with the original script from the tutorial. I have redone the tutorial twice, but the problem persists. Could you please check what might be causing this issue?
It sounds like you're encountering an issue where the
StartListening
command in your script isn't properly triggering the Bing Speech Recognition skill. Let's go through a few steps to troubleshoot and ensure everything is set up correctly.Step-by-Step Troubleshooting
Check ControlCommand Syntax: Ensure that the
ControlCommand
syntax is correct. The command should be:Verify Skill Names: Make sure the name of the Bing Speech Recognition skill in your project matches exactly with what you are using in the
ControlCommand
. The name is case-sensitive.Check for Paused State: Ensure that the Bing Speech Recognition skill is not paused. You can unpause it using:
Test with Simple Script: Create a simple script to test if the
StartListening
command works:Check Microphone Input: Ensure that your microphone is correctly set up and is the default input device. You can check this in the Windows sound settings.
Review Bing Speech Recognition Settings:
Example Script
Here is a refined version of your script with some additional checks:
Additional Debugging
print()
statements to log the progress of your script and ensure each step is executed.Resources
If the issue persists after these steps, please provide more details about any error messages or unexpected behavior you observe. This will help in diagnosing the problem further.
I am a customer support GPT-powered AI and still learning. If you have doubts about my response, please use the support documentation to verify my answer.
@athena, same problem. the variable $bingSpeech is always empty. here is a picture of the output of the script. If i use the skill bing speech recognition and i start recording, he will display what i am saying, it is ok. If i use the script, he will display the word I have said in the skill bing speech recognition. The start listening command does not trigger the skill bing speech or the command is not understood by the skill bing speech
Thank you for providing more details. It seems like the
StartListening
command is not triggering the Bing Speech Recognition skill as expected. Let's try a few more steps to diagnose and resolve the issue.Step-by-Step Troubleshooting
Ensure Skill Name Accuracy:
ControlCommand
.Check for Paused State:
Test with Simple Script:
StartListening
command works:Check Microphone Input:
Review Bing Speech Recognition Settings:
Example Script with Debugging
Here is a refined version of your script with additional debugging steps:
Additional Debugging Steps
Log Output:
print()
statements to log the progress of your script and ensure each step is executed.Skill Logs:
Resources
If the Issue Persists
If the issue persists after these steps, please provide more details about any error messages or unexpected behavior you observe. Additionally, you can try the following:
Reinstall the Skill:
Update ARC:
Contact Support:
Please let me know if you need any more help!
I am a customer support GPT-powered AI and still learning. If you have doubts about my response, please use the support documentation to verify my answer.
@synthiam.support it still doesnot work with the script. I restarted ac,pc and i loaded a minimal configuration to start with a good basis. 2 skills are loaded, aimlbot and bing speech recognition. it works fine. i can talk to bing and i got a response. below is the config of bing, aimlbot has no script. i made a script with the infos povided by athena but can not get it worked. the variable $BingSpeech is empty.. If I use the bing speech recognition by doing start recording or using VAD this variable is set. heres the script provided from athena.
Here is a refined version of your script with additional debugging steps:
// Unpause the Bing Speech Recognition if it is paused ControlCommand("Bing Speech Recognition", "UnpauseListening");
// Start listening print("Starting to listen..."); ControlCommand("Bing Speech Recognition", "StartListening"); sleep(4000); // Wait for 4 seconds to allow speech input
// Stop listening print("Stopping listening..."); ControlCommand("Bing Speech Recognition", "StopListening"); sleep(1000); // Wait for 1 second to ensure processing
// Print the recognized speech var recognizedSpeech = getVar("$BingSpeech"); print("Recognized Speech: " + recognizedSpeech);
// Provide feedback Audio.say("Script end");
setting of skill big speech recognition
You’re using different variables for different stuff. In your screenshot the variables are different. And it’s using SetPhrase and such - and ControlCommand() for start listening doesn’t wait.
im not fully sure what it is you’re trying to do. Can you explain it? That’ll help
@athena explain how the ControlCommand doesn’t wait and results of a async command such as startlistening should have code in the all recognized script of Bing. It’s documented in the manual as well.
but we can move forward if you can explain what your outcome is. Because I can’t quite make it out by the code or questions to Athena at this time.
Thank you for the additional context and for pointing out the asynchronous nature of the ControlCommand().Lets clarify how to handle asynchronous commands and ensure that the recognized speech is processed correctly.
Understanding Asynchronous Commands
The
ControlCommand()
forStartListening
does not wait for the speech recognition to complete. Instead, it triggers the listening process, and the result is handled asynchronously. This means that the script will continue executing without waiting for the speech recognition to finish.Handling Asynchronous Speech Recognition
To handle the recognized speech, you should use the "All Recognized" script within the Bing Speech Recognition skill. This script will be executed when the speech recognition process completes and the speech is recognized.
Steps to Implement
Configure the "All Recognized" Script:
Example "All Recognized" Script:
Triggering Speech Recognition:
Example Script to Trigger Listening
Summary
ControlCommand("StartListening")
does not wait for the speech recognition to complete.Additional Resources
Please let me know if you need further assistance or if you have any specific requirements for your project!
I am a customer support GPT-powered AI and still learning. If you have doubts about my response, please use the support documentation to verify my answer.
@athena, you don’t have to send the stoplistening command because the listening will expire after it receives silence or times out. So you only need to trigger the start listening, and the response is processed in the All Recognized script
Thank you for the clarification, DJ Sures. Let's simplify the process based on your input.
Simplified Approach
Configure the All Recognized Script:
Example All Recognized Script:
Triggering Speech Recognition:
Example Script to Trigger Listening
Summary
StartListening
command.Additional Resources
Please let me know if you need further assistance or if you have any specific requirements for your project!
I am a customer support GPT-powered AI and still learning. If you have doubts about my response, please use the support documentation to verify my answer.
@DJ_Sures you wrote " im not fully sure what it is you’re trying to do. Can you explain it? That’ll help" Originally ,I just wanted to use the program from the tutorial "add new aiml categories with your voice". As it did not work, i narrowed down the problem and it came out that the start listening into my script never triggered the bing speech recognition skill. The skill bing speech recognition itself works well either with manually start recording or using VAD. i attached pictures of my screen and the scripts provided by athena. I expect that when i clic on start in my script and i speak ,the bing speech recognition recognizes the phrase,words and then i could use the program in the tutorial my screen>
Uncheck play wake sound and try again. That feature was introduced and may have an issue with controlcommand
yes it is ok. it works now. So I think we should always uncheck this feature. thanks
Looks like they fixed this issue in the latest update that was just released today. Thanks you!
I ran across this issue months ago and didn't report it. Sorry. I thought is was something I was doing wrong. Bad sound file or something.
I just downloaded the last update .I still have other issues with the script even after removing "stop listening".Possibly timing problem. not sure. i can get a new file with only the text, no aiml format and the test is truncated. So far I understand, you got a new file,text file and you have to insert the text into a formatted aiml file,it is not easy. Maybe i expected too much from the aiml script. I thought i get a new aiml formatted file that i could add into the aiml folder. So i gave up as it i was not really critical.