Artyom.js 中文翻译
  • Artyom
  • FAQ
  • 翻译相关
  • 开始
    • 简介
    • 必要条件
    • Changelog
  • API
    • isObeying
    • addCommands
    • clearGarbageCollection
    • debug
    • detectErrors
    • device
    • emptyCommands
    • fatality
    • getAvailableCommands
    • getLanguage
    • getProperties
    • getVoices
    • initialize
    • isRecognizing
    • isSpeaking
    • newDictation
    • newPrompt
    • obey
    • on
    • recognizingSupported
    • redirectRecognizedTextOutput
    • remoteProcessorService
    • removeCommands
    • repeatLastSay
    • restart
    • say
    • sayRandom
    • setDebug
    • Shutup
    • simulateInstruction
    • speechSupported
    • when
Powered by GitBook
On this page

Was this helpful?

  1. API

redirectRecognizedTextOutput

通过 artyom 以你所希望的方式重定向识别到的文字。

有时候,你希望了解artyom 在文档中理解和展示了什么,除非在初始化时设定 debug 参数为 true,否则artyom的原始输出都会被隐藏起来(此时所有信息也都是不可回溯的,因为他们都只会被展示在console里)。

artyom.redirectRecognizedTextOutput((recognized,isFinal) => {
    if(isFinal){
        // Nothing
        $("#span-preview").text("");
    }else{
        $("#span-preview").text(recognized);
    }
});
PreviousrecognizingSupportedNextremoteProcessorService

Last updated 5 years ago

Was this helpful?