You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am using both of your plugins for Bing Speech (Xamarin.Cognitive.BingSpeech and Plugin.AudioRecorder). They have been working very well. I have just gotten around to testing this plugin (Xamarin.Cognitive.BingSpeech) with UWP, and I have run into a bit of a problem (or mismatch) between this plugin and Plugin.AudioRecorder.
The result from Plugin.AudioRecorder's StartRecording method is the full path to the recorded file. This works well, and recording has no issues. However, when I try to pass that same path to the SpeechToTextSimple method of this plugin, I run into a problem. Plugin.AudioRecorder records to a temporary directory, which for UWP is the TempState folder. however, after looking through the code for this plugin, I can see that things are configured to use LocalStorage, which for UWP is LocalState. This results in an exception being thrown by SpeechToTextSimple in the form of PCLStorage.Exceptions.FileNotFoundException.
The lines of code to which I am referring are lines 222 & 223 in BingSpeechApiClient.cs
This problem doesn't affect iOS or Android, but I am assuming that the temporary storage used by Plugin.AudioRecorder and LocalStorage actually end up being the same directory (I haven't looked into it).
Would it be possible to modify this code to accept a full path using PCLStorage's GetFileFromPathAsync method instead of simply looking for the filename in LocalStorage? The only other option I can see would be to get the file in TempState using PCLStorage and move it to LocalState before sending the request to SpeechToTextSimple. Am I seeing things correctly? Thanks.
EDIT: Or, perhaps even an overload that takes an optional boolean specifying we are sending a full path (to keep the existing API intact)?
The text was updated successfully, but these errors were encountered:
@FlammableFork I knew not creating the UWP sample would come back to haunt me. Fixed the issue and added a UWP sample to the repo. Thanks for reporting & investigating.
I am using both of your plugins for Bing Speech (Xamarin.Cognitive.BingSpeech and Plugin.AudioRecorder). They have been working very well. I have just gotten around to testing this plugin (Xamarin.Cognitive.BingSpeech) with UWP, and I have run into a bit of a problem (or mismatch) between this plugin and Plugin.AudioRecorder.
The result from Plugin.AudioRecorder's StartRecording method is the full path to the recorded file. This works well, and recording has no issues. However, when I try to pass that same path to the SpeechToTextSimple method of this plugin, I run into a problem. Plugin.AudioRecorder records to a temporary directory, which for UWP is the TempState folder. however, after looking through the code for this plugin, I can see that things are configured to use LocalStorage, which for UWP is LocalState. This results in an exception being thrown by SpeechToTextSimple in the form of PCLStorage.Exceptions.FileNotFoundException.
The lines of code to which I am referring are lines 222 & 223 in BingSpeechApiClient.cs
This problem doesn't affect iOS or Android, but I am assuming that the temporary storage used by Plugin.AudioRecorder and LocalStorage actually end up being the same directory (I haven't looked into it).
Would it be possible to modify this code to accept a full path using PCLStorage's GetFileFromPathAsync method instead of simply looking for the filename in LocalStorage? The only other option I can see would be to get the file in TempState using PCLStorage and move it to LocalState before sending the request to SpeechToTextSimple. Am I seeing things correctly? Thanks.
EDIT: Or, perhaps even an overload that takes an optional boolean specifying we are sending a full path (to keep the existing API intact)?
The text was updated successfully, but these errors were encountered: