How to use the ibm-watson/speech-to-text/v1 function in ibm-watson

To help you get started, we’ve selected a few ibm-watson examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github leon-ai / leon / server / src / stt / watson-stt / parser.js View on Github external
parser.init = () => {
  const credentials = JSON.parse(fs.readFileSync(`${__dirname}/../../config/voice/watson-stt.json`, 'utf8'))

  try {
    client = new Stt(credentials)

    log.success('Parser initialized')
  } catch (e) {
    log.error(`Watson STT: ${e}`)
  }
}