I am using IBM Watson speech to text iOS SDK for transcribing the real-time audio. I have installed it through cocoa pods. I am stuck with an issue (authentication) while transcribing the audio to text.
The installed STT SDK version is 0.38.1
.
I have configured everything, created the service and credential correctly and also making sure SpeechToText
instantiated with proper apikey
and URL
. Whenever I call the startStreaming
method STT SDK prints some error log, which seems related to the authentication challenge.
Here is the code snippet.
let speechToText = SpeechToText(apiKey: Credentials.SpeechToTextAPIKey,iamUrl: Credentials.SpeechToTextURL)
var accumulator = SpeechRecognitionResultsAccumulator()
func startStreaming() {
var settings = RecognitionSettings(contentType: "audio/ogg;codecs=opus")
settings.interimResults = true
let failure = { (error: Error) in print(error) }
speechToText.recognizeMicrophone(settings: settings, failure: failure) { results in
accumulator.add(results: results)
print(accumulator.bestTranscript)
}
}
Error Logs
CredStore - performQuery - Error copying matching creds. Error=-25300,
query={
class = inet;
"m_Limit" = "m_LimitAll";
ptcl = htps;
"r_Attributes" = 1;
sdmn = "IBM Watson Gateway(Log-in)";
srvr = "gateway-syd.watsonplatform.net";
sync = syna;
}
I have dug into IBM Watson SDK documentation even googled around this issue but did not find any relevant answer.