SFTranscriptionSegment's timestamp is always 0

拈花ヽ惹草 提交于 2019-12-22 08:16:51

问题


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:


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

speechRecgzr.defaultTaskHint = SFSpeechRecognitionTaskHintDictation;


来源:https://stackoverflow.com/questions/39358599/sftranscriptionsegments-timestamp-is-always-0

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!