SFTranscriptionSegment's timestamp is always 0

2019-05-05 17:28发布

This is a questoin regarding new iOS 10 Speech framework. I get the speech recognition result using following method

 recognitionTask =   [speechRecgzr recognitionTaskWithRequest:recognitionRequest resultHandler:^(SFSpeechRecognitionResult * _Nullable result, NSError * _Nullable error) {

    }

But the timestamp of each SFTranscriptionSegment in result is 0 and also confidence is always 0

What can be the problem here? Have apple not implemented the API properly yet?

Thank you.

1条回答
贪生不怕死
2楼-- · 2019-05-05 18:10

After few weeks I found that by setting this I can get timestamp and confidence:

speechRecgzr.defaultTaskHint = SFSpeechRecognitionTaskHintDictation;
查看更多
登录 后发表回答