TrayConfig

class TrayConfig

Data class holding all configuration for the Spokestack Tray.

Types

Builder
Link copied to clipboard
data class Builder(orientation: TrayConfig.Orientation, haptic: Boolean, sayGreeting: Boolean, greeting: String, ttsMode: SynthesisRequest.Mode, voice: String, clientId: String?, clientSecret: String?, properties: HashMap<String, Any>, logLevel: Int, wakewordModelURL: String?, nluURL: String?, rasaOssURL: String?, refreshModels: Boolean, editTranscript: (String) -> String?, listener: SpokestackTrayListener?, transcriptEditor: TranscriptEditor?)
A fluent builder interface for creating a tray configuration.
Orientation
Link copied to clipboard
enum Orientation : Enum<TrayConfig.Orientation>
A simple enum representing the tray's affinity for a certain side of the screen.

Properties

clientId
Link copied to clipboard
val clientId: String
Client ID from your Spokestack account.
clientSecret
Link copied to clipboard
val clientSecret: String
Secret key from your Spokestack account.
greeting
Link copied to clipboard
val greeting: String
A message to display and/or read via TTS synthesis when the tray opens for the first time.
haptic
Link copied to clipboard
val haptic: Boolean
A flag determining whether haptic feedback is sent when the tray opens.
listener
Link copied to clipboard
val listener: SpokestackTrayListener?
A listener that will receive events from Spokestack Tray.
logLevel
Link copied to clipboard
val logLevel: Int
Level of Spokestack log messages that will be produced and passed to registered listeners.
nluURL
Link copied to clipboard
val nluURL: String?
The URL to the directory containing your NLU files.
orientation
Link copied to clipboard
val orientation: TrayConfig.Orientation
Determines the initial placement of the microphone button and the opening direction of the tray.
properties
Link copied to clipboard
val properties: Map<String, Any>
Configuration properties forwarded to the Spokestack builder.
rasaOssURL
Link copied to clipboard
val rasaOssURL: String?
The URL to the Rasa Open Source server.
refreshModels
Link copied to clipboard
val refreshModels: Boolean
Whether wakeword and NLU models should be forcibly (re-)downloaded on launch.
sayGreeting
Link copied to clipboard
val sayGreeting: Boolean
A flag determining whether the initial greeting message, if set, should be read allowed (it will always be displayed in the message stream).
spokestackBuilder
Link copied to clipboard
val spokestackBuilder: Spokestack.Builder
A preconfigured Spokestack builder instance for use with the tray.
transcriptEditor
Link copied to clipboard
val transcriptEditor: TranscriptEditor?
Used to edit the transcript before classification and displaying to the user.
ttsMode
Link copied to clipboard
val ttsMode: SynthesisRequest.Mode
Synthesis mode for TTS.
voice
Link copied to clipboard
val voice: String
Voice to use for TTS synthesis.
wakewordModelURL
Link copied to clipboard
val wakewordModelURL: String?
The URL to the directory containing your wakeword models.