Spokestack
@objc
public class Spokestack : NSObject
extension Spokestack: SpokestackDelegate
This class combines all Spokestack modules into a single component to provide a unified interface to the library’s ASR, NLU, and TTS features. Like the individual modules, it is configurable using a fluent builder pattern, but it provides a default configuration; only a few parameters are required from the calling application, and those only for specific features noted in the documentation for the builder’s methods.
The default configuration of this class assumes that the client application wants to use all of Spokestack’s features, regardless of their implied dependencies or required configuration. If a prerequisite is missing at build time, the individual module may throw an error when called.
This class will run in the context of the caller. The subsystems themselves may use the configured dispatch queues where appropriate to perform intensive tasks.
-
This is the client entry point to the Spokestack voice input system.
Declaration
Swift
@objc public var pipeline: SpeechPipeline
-
This is the client entry point for the Spokestack Text to Speech (TTS) system.
Declaration
Swift
@objc public var tts: TextToSpeech
-
This is the client entry point for the Spokestack BERT NLU implementation.
Declaration
Swift
@objc public var nlu: NLUTensorflow
-
Maintains global state for the speech pipeline.
Declaration
Swift
@objc public var context: SpeechContext
-
Configuration properties for Spokestack modules.
Declaration
Swift
@objc public var configuration: SpeechConfiguration
-
A required function for
SpokestackDelegate
implementorsDeclaration
Swift
public func failure(error: Error)
Parameters
error
An error sent from a Spokestack module.
-
An event receiver used to fulfill automatic classification configuration.
Declaration
Swift
public func didRecognize(_ result: SpeechContext)
Parameters
result
Global state for the speech pipeline.