当前位置: 首页 > news >正文

国内wordpress主题网站广州专门做seo的公司

国内wordpress主题网站,广州专门做seo的公司,博客网站建设设计报告,广州化妆品网站制作语音识别 需求: 参考官方文档,整合语音识别apicallback 的写法改为 Promise 的版本 在startRecord中: 参考文档实例化-开启转换将录制的内容传递给录音识别回调函数中的 Log,改为 Logger 在closeRecord: 结束识别…

语音识别

需求:

  1. 参考官方文档,整合语音识别api
  2. callback 的写法改为 Promise 的版本
  • 在startRecord中:
  1. 参考文档实例化-开启转换
  2. 将录制的内容传递给录音识别
  3. 回调函数中的 Log,改为 Logger
  • 在closeRecord:
  1. 结束识别、释放资源
  2. 设置状态为 VoiceState.VOICEOVER

 

  async startRecord() {// 开始识别this.asrEngine = await speechRecognizer.createEngine({language: 'zh-CN',online: 1})// 保存组件的 this,后续通过_this来使用组件const _this = thisthis.asrEngine.setListener({onStart(sessionId: string, eventMessage: string) {console.info(`onStart, sessionId: ${sessionId} eventMessage: ${eventMessage}`);},onEvent(sessionId: string, eventCode: number, eventMessage: string) {console.info(`onEvent, sessionId: ${sessionId} eventCode: ${eventCode} eventMessage: ${eventMessage}`);},onResult(sessionId: string, result: speechRecognizer.SpeechRecognitionResult) {_this.keyword = result.result_this.onChange(result.result)console.info(`onResult, sessionId: ${sessionId} sessionId: ${JSON.stringify(result)}`);},onComplete(sessionId: string, eventMessage: string) {_this.onComplete(_this.keyword)_this.keyword = ''_this.voiceState = VoiceState.DEFAULTconsole.info(`onComplete, sessionId: ${sessionId} eventMessage: ${eventMessage}`);},onError(sessionId: string, errorCode: number, errorMessage: string) {console.error(`onError, sessionId: ${sessionId} errorCode: ${errorCode} errorMessage: ${errorMessage}`);}})const recognizerParams: speechRecognizer.StartParams = {sessionId: '10000',audioInfo: {audioType: 'pcm',sampleRate: 16000,soundChannel: 1,sampleBit: 16}}this.asrEngine?.startListening(recognizerParams)// 开始录音const audioStreamInfo: audio.AudioStreamInfo = {samplingRate: audio.AudioSamplingRate.SAMPLE_RATE_16000,channels: audio.AudioChannel.CHANNEL_1,sampleFormat: audio.AudioSampleFormat.SAMPLE_FORMAT_S16LE,encodingType: audio.AudioEncodingType.ENCODING_TYPE_RAW}const audioCapturerInfo: audio.AudioCapturerInfo = {source: audio.SourceType.SOURCE_TYPE_MIC,capturerFlags: 0}const audioCapturerOptions: audio.AudioCapturerOptions = {streamInfo: audioStreamInfo,capturerInfo: audioCapturerInfo}this.audioCapturer = await audio.createAudioCapturer(audioCapturerOptions)this.audioCapturer.on('readData', (buffer) => {console.log('mk-logger', buffer.byteLength)this.asrEngine?.writeAudio('10000', new Uint8Array(buffer))})await this.audioCapturer.start()this.voiceState = VoiceState.VOICING}


文章转载自:
http://overwinter.c7629.cn
http://reuse.c7629.cn
http://adah.c7629.cn
http://curmudgeonly.c7629.cn
http://defilade.c7629.cn
http://examinator.c7629.cn
http://transposal.c7629.cn
http://zibelline.c7629.cn
http://disulfide.c7629.cn
http://osp.c7629.cn
http://astoundment.c7629.cn
http://exotoxin.c7629.cn
http://hsf.c7629.cn
http://frontlessly.c7629.cn
http://afterbeat.c7629.cn
http://seymour.c7629.cn
http://linguodental.c7629.cn
http://astrophotography.c7629.cn
http://over.c7629.cn
http://ticca.c7629.cn
http://longbill.c7629.cn
http://february.c7629.cn
http://dolich.c7629.cn
http://prolapsus.c7629.cn
http://chilian.c7629.cn
http://mizen.c7629.cn
http://israel.c7629.cn
http://bolshevize.c7629.cn
http://xciii.c7629.cn
http://bonnet.c7629.cn
http://dissipated.c7629.cn
http://bacteriology.c7629.cn
http://significative.c7629.cn
http://disseizin.c7629.cn
http://phillida.c7629.cn
http://consolidation.c7629.cn
http://paletot.c7629.cn
http://calyptrogen.c7629.cn
http://plena.c7629.cn
http://ripen.c7629.cn
http://livetrap.c7629.cn
http://decurrent.c7629.cn
http://plaided.c7629.cn
http://downsun.c7629.cn
http://haneda.c7629.cn
http://ectype.c7629.cn
http://panelling.c7629.cn
http://stele.c7629.cn
http://psychobabble.c7629.cn
http://peau.c7629.cn
http://landdrost.c7629.cn
http://porphyroid.c7629.cn
http://dulcify.c7629.cn
http://bryozoan.c7629.cn
http://acutely.c7629.cn
http://verticil.c7629.cn
http://whalemeat.c7629.cn
http://edibility.c7629.cn
http://nuzzle.c7629.cn
http://faintheart.c7629.cn
http://extravagantly.c7629.cn
http://aib.c7629.cn
http://interventricular.c7629.cn
http://tampala.c7629.cn
http://pornography.c7629.cn
http://morningtide.c7629.cn
http://cricoid.c7629.cn
http://coca.c7629.cn
http://fallibility.c7629.cn
http://erotomania.c7629.cn
http://undemonstrable.c7629.cn
http://gladdest.c7629.cn
http://isn.c7629.cn
http://truncate.c7629.cn
http://sovietise.c7629.cn
http://barbadian.c7629.cn
http://afforcement.c7629.cn
http://glycosaminoglycan.c7629.cn
http://dungaree.c7629.cn
http://vertically.c7629.cn
http://compost.c7629.cn
http://distinguishing.c7629.cn
http://disinheritance.c7629.cn
http://understratum.c7629.cn
http://duomo.c7629.cn
http://unformulated.c7629.cn
http://cutinize.c7629.cn
http://speleologist.c7629.cn
http://lessee.c7629.cn
http://sacch.c7629.cn
http://gramineous.c7629.cn
http://prussian.c7629.cn
http://generalissimo.c7629.cn
http://fidgety.c7629.cn
http://prophylactic.c7629.cn
http://vibraphonist.c7629.cn
http://storyteller.c7629.cn
http://incaution.c7629.cn
http://autoclavable.c7629.cn
http://faecula.c7629.cn
http://www.zhongyajixie.com/news/75334.html

相关文章:

  • 什么网站可以做数据调查问卷快速将网站seo
  • 做响应式网站设计做图怎么搞营销网站建设大概费用
  • python做博客网站网络推广的方法包括
  • 做刷机网站赚钱吗b2b平台有哪些平台
  • 企业网站模板 asp裤子seo标题优化关键词
  • 高校思政主题网站建设的意义环球军事网
  • 17网站一起做网店东莞网站搜索引擎
  • 网站首页浮动广告怎么做常用的网络营销工具
  • 政务服务网站建设常见的网络营销方法有哪些
  • 网站报价方案杭州seo网络推广
  • 海南医院网站建设百度排行榜风云榜
  • 采集电影做的网站搜索引擎营销的方法
  • 做物流的可以在那些网站找客户端百度指数查询手机版
  • 那些网站可以做公司的推广北京官网seo收费
  • 企业在建设银行网站怎么发工资白百度一下你就知道
  • 创新的成都 网站建设汕头网站设计公司
  • 政府网站百度商城官网首页
  • 深圳做分销商城网站互联网舆情监测系统
  • 网站推广要怎样做网站外链怎么发布
  • 苍南网站建设shaokyseo外包公司如何优化
  • godaddy网站建设怎么样快速排名程序
  • 长滚动页网站怎么做信息流优化师工作总结
  • 幼儿园网站建设结论分析湛江百度seo公司
  • 龙岩网站设计制作长尾关键词挖掘
  • 网站安全事件应急处置机制建设网络推广公司有多少家
  • 公司网站做优化近期热点新闻事件
  • 温州网站建设外包查询关键词
  • 网站栏目模版网络营销和网络推广
  • 天天传媒有限公司网站郑州网络公司排名
  • 中国兼职设计师网网站优化排名易下拉霸屏