Configuration
com.surpuissant.kws.sdk
Configuration Class
The Configuration
class is used to configure settings for Speech-to-Text and Keyword Spotting in an application using Surpuissant's KWS SDK.
Parameters
Parameter | Type | Description | Optional/Default Value |
---|---|---|---|
context | Context | The context of the application where the KWS will be used. This should always be an instance of Application . | Required |
apiKey | String | A unique API key provided by Surpuissant to authenticate requests. | Required |
keywords | List<String> | A list of keywords that trigger the KWS service. | Required |
group | String (default: "default") | The group name for the configuration. This is used to differentiate between different configurations in a single application. | Optional, default value: "default" |
notification | SPNotification | An instance of SPNotification that defines how notifications will be displayed when KWS matches are detected. | Required |
customUUID | String (default: random UUID) | A custom identifier for the configuration, used to differentiate between different configurations in a single application. | Optional, default value: generated using java.util.UUID.randomUUID().toString() |
soundFx | Boolean (default: true) | Whether sound effects should be played when KWS matches are detected. | Optional, default value: true |
enableTTS | Boolean (default: true) | Whether text-to-speech should be enabled for the transcriptions returned by the KWS service. | Optional, default value: true |
transcriptionOnly | Boolean (default: false) | Whether to enable only transcription mode without sound effects and TTS. | Optional, default value: false |
Return Values
The Configuration
class does not return any values. It is used as a data structure for configuration settings.