Author Topic: MSFS Agent  (Read 2805 times)

indiejone

  • Newbie
  • *
  • Posts: 7
MSFS Agent
« on: August 16, 2023, 06:25:46 PM »
I have setup a MSFS 2020 profile with over 500 commands and it works great. Recently I came across MSFS Agent and it looks like I have it all setup correctly (see screenshots) but when I do the landing gear check it comes back every time (whatever aircraft I use) that it does not have landing gear. I can't seem to change altitude, heading etc and it won't hear any of my "variables" * wildcards. I have the 64bit version of VA, I have 64bit Microsoft Speech Platform Runtime for 64bit installation of VoiceAttack. I have read every post on here about MSFS Agent and still can't get it to work. Please help!

Pfeil

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 4782
  • RTFM
Re: MSFS Agent
« Reply #1 on: August 16, 2023, 06:43:55 PM »
When you speak one of the wildcard commands, is there an "Unrecognized" entry in the log on VoiceAttack's main window?


Assuming you're using the example profile provided by the author of the third-party "MSFS Agent" plugin, the information returned, E.G. regarding landing gear status/availability, would be provided by the plugin, not VoiceAttack itself.

indiejone

  • Newbie
  • *
  • Posts: 7
Re: MSFS Agent
« Reply #2 on: August 16, 2023, 07:36:10 PM »
Thanks for your speedy reply. For example if I do the command on the screenshot (try to change altitude). I get a response of 0 feet. When I was at 1800+ and trying to set it to 2000. The second screenshot is of the log.

Pfeil

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 4782
  • RTFM
Re: MSFS Agent
« Reply #3 on: August 17, 2023, 08:36:55 AM »
Wildcards can only occur at the beginning or the end of a command phrase, not somewhere in-between.

E.G. "Set altitude *" would be a valid wildcard command phrase, but "Set altitude * feet" is not.

indiejone

  • Newbie
  • *
  • Posts: 7
Re: MSFS Agent
« Reply #4 on: August 17, 2023, 12:03:45 PM »
I really appreciate your help. I changed it to Set Altitude * and I get  back "Altitude set to zero." it seems that it's not hearing the height e.g. I use 2000.

Pfeil

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 4782
  • RTFM
Re: MSFS Agent
« Reply #5 on: August 17, 2023, 12:07:07 PM »
Have you changed any of the default recognition settings (aside from "Show Confidence Level")?

Did you perform the speech recognition training at least three times?

indiejone

  • Newbie
  • *
  • Posts: 7
Re: MSFS Agent
« Reply #6 on: August 17, 2023, 01:26:47 PM »
Yes I believe that I have the default minimum to 60%, see attachment. I have done the windows speech recognition at least 3 times. VA picks up a good 95+ of what I say MSFS Agent aside. From the previous screenshots, do you see that VA is actually communicating with SimConnect and vice versa? As I'm not sure how I can see the debug logs, I have set the MSFS Agent to true to do the debug. Again I really appreciate you helping me with this.

Pfeil

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 4782
  • RTFM
Re: MSFS Agent
« Reply #7 on: August 17, 2023, 01:51:17 PM »
The only "log" VoiceAttack itself provides is the one on VoiceAttack's main window. The fact that there are messages regarding the processing of the context provided to the plugin via the "Execute an External Plugin Function" action does suggest that debug variable is having an effect.

It's up to the plugin to provide information; that's not something VoiceAttack itself has direct any influence over.


To be clear: command recognition is not performed by the plugin; it's registering 0 because what is being recognized does not contain a number at all.

Wildcard command rely essentially on dictation, meaning that the speech recognition system doesn't match to a predefined phrase as with normal commands.
Because of that, speech recognition needs to be working very well in order for such commands to be recognized accurately and consistently.
An optimal configuration, including microphone, audio path, environment, training, pronunciation, and annunciation, is going to produce the best results in that scenario.

That is also why wildcards in command names are noted in the documentation to be "somewhat unsupported".


One thing you can try is to increase the "Recognized Speech Delay" option on the "Recognition" tab of the VoiceAttack options window.

You may also want to have a look at the microphone setup wizard, to make sure the volume is within the green area.
Said wizard can be started using the "Microphone Setup" entry in the context menu for the "Utilities >" button on the "Recognition" tab of the VoiceAttack options window.

Filtering of the microphone input signal (E.G. a noise gate filter) could also negatively impact recognition. This may be enabled by default in the software for your (onboard) sound card.

indiejone

  • Newbie
  • *
  • Posts: 7
Re: MSFS Agent
« Reply #8 on: August 17, 2023, 05:47:26 PM »
Thank you for your reply. I'm sure we are getting closer to figuring this out. I have done a bunch more tests and noticed that I get a "verbal" reply in the case of "set altitude 2000" I get the reply immediately after I say altitude and before I can state a number. In the Recognized Speech Delay I have it set to 2, is that in seconds? If it is, this should be plenty. I'll try with longer. I done the microphone setup and I was in the green even when I whispered.

I haven't found the noise gate filter on the onboard sound card yet but will look more later.

I feel more confident that VA is connecting with SimConnect and vice versa and I'm trying all the MSFS Agent default commands but so far haven't had any succeed but I'll stick with them before I start customizing my own. To be honest I still haven't been able to get the "Gear Down" to work.

Pfeil

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 4782
  • RTFM
Re: MSFS Agent
« Reply #9 on: August 17, 2023, 05:51:06 PM »
As the tooltip (on the label) mentions, and the documentation implies, that value is in milliseconds (E.G. 1000 is one second).

indiejone

  • Newbie
  • *
  • Posts: 7
Re: MSFS Agent
« Reply #10 on: August 17, 2023, 06:30:33 PM »
I guess I've never hovered over that to see the tooltip, what would you suggest 1000? I did look it up on VA website but it didn't mention it there. I'm guessing I need to say the numbers as 2-0-0-0 for 2,000 for altitude, so maybe 3000 milliseconds?

Pfeil

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 4782
  • RTFM
Re: MSFS Agent
« Reply #11 on: August 17, 2023, 06:38:04 PM »
You'd need to see whether any of those values allow the command to be recognized.

Under normal circumstances the speech recognition system should keep listening as long as it's receiving continuous input, as far as I'm aware, so this may just be a band-aid fix, even if it works (which is why I mentioned checking volume and filtering).

SemlerPDX

  • Global Moderator
  • Sr. Member
  • *****
  • Posts: 291
  • Upstanding Lunatic
    • My AVCS Homepage
Re: MSFS Agent
« Reply #12 on: August 19, 2023, 12:02:32 PM »
Since numbers increase the command count in a linear manner, such that 'set altitude [1..40000]` would be 40,000 command variations, you could consider that in flight simulators (and IRL), altitude can also be referred to as a Flight Level which is a standard altitude reference used by pilots and air traffic controllers.  It is defined as a vertical altitude in hundreds of feet above ground level (or sea level, depending).

So, you could create a command which has far fewer commands if you only used Flight Level, such as `set altitude [1..40]` ...which would be only 40 command variations.

Just for reference, the way these are stated is like this, "set altitude four zero" (would mean set altitude to 40,000 feet), or for altitudes below 10,000 feet, "set altitude nine" (would mean set altitude to 900 feet).