Module: watson-speech/speech-to-text/recognize-microphone

(require("watson-speech/speech-to-text/recognize-microphone"))(options) → {RecognizeStream|FormatStream}

Create and return a RecognizeStream sourcing audio from the user's microphone

Parameters:
Name Type Description
options Object

Also passed to {RecognizeStream}, and {FormatStream} when applicable

Properties
Name Type Attributes Default Description
token String

Auth Token - see https://github.com/watson-developer-cloud/node-sdk#authorization

format Boolean <optional>
true

pipe the text through a {FormatStream} which performs light formatting. Also controls smart_formatting option unless explicitly set.

keepMicrophone Boolean <optional>
false

keeps an internal reference to the microphone stream to reuse in subsequent calls (prevents multiple permissions dialogs in firefox)

outputElement String | DOMElement <optional>

pipe the text to a WriteableElementStream targeting the specified element. Also defaults objectMode to true to enable interim results.

Source:
Returns:
Type
RecognizeStream | FormatStream

Methods

(inner) handleError(error)

Propagate error to new FormatStream

Parameters:
Name Type Description
error String

message

Source: