SpeechRecognition 203 Error on iOS

Hi, I’ve got an Error with the SpeechRecognition on iOS that freaking me out…
Android works fine. iOS Emulator works with no problems. But on a real Device I always got an 203 Error

console.error: error: Error Domain=kAFAssistantErrorDomain Code=203 “Corrupt”
[app-scripts] UserInfo={NSLocalizedDescription=Corrupt, NSUnderlyingError=0x2830060a0 {Error Domain=SiriSpeechErrorDomain
[app-scripts] Code=102 “(null)”}}

can someone help ?

i’ve got the same problem… did you find a solution by now?

There was an problem using the speechrecog and speechsynthesis at the same time. Unfortunately i have to stop the speech output as soon as the user presses an button. But i didn‘t found a solution for this. So i only allow the users to press the button if the speech output is finished.

Thank you.
I have bypassed the problem differently, I have set the AudioSessionCategory to PlayAndRecord. The CategoryOptions but not on defaultToSpeaker, so the speech recognition works even if the audio output is interrupted, but the audio output does not run over the speakers. Therefore I use external speakers.

I actually figured out how to solve my problem. If you worked with the “Recognizing Speech in Live Audio” documentation like I did. Then you probably have the following code somewhere:

// Configure the audio session for the app.
let audioSession = AVAudioSession.sharedInstance()
try audioSession.setCategory(.record, mode: .measurement, options: .duckOthers)
try audioSession.setActive(true, options: .notifyOthersOnDeactivation)
let inputNode = audioEngine.inputNode

I had to replace line 3 with:

try audioSession.setCategory(.playAndRecord, mode: .measurement, options: .defaultToSpeaker)

now everything works fine.