Wordsets
See NLUaaS Wordsets for more information.
Wordsets occur in the use case of personalization.
A wordset is a set of words that customize the vocabulary used by an application at runtime. For example, an application might use wordsets to fetch identified user-specific information to add recognizable values into a grammar (such as the appropriate bank account information for a specific user). The Krypton recognition engine and NLE use wordsets for dynamic content injection.
You can specify either a .json
wordset that is passed along inline, or a compiled wordset resource with a URI.
To use an inline wordset, include the path to the wordset file with the wordset_path
parameter:
"nlu": {
"use_asr_results": true,
"model_uri": "urn:nuance-mix:tag:model/coffee_demo/mix.nlu?=language=eng-USA",
"wordset_path": "/path/to/your/wordset.json",
...
}
If using a compiled wordset, specify the URI of the compiled wordset resource with the wordset_uri
parameter:
"nlu": {
"use_asr_results": true,
"model_uri": "urn:nuance-mix:tag:model/coffee_demo/mix.nlu?=language=eng-USA",
"wordset_uri": "urn:nuance-mix:tag:wordset:lang/<companion_artifact_context_tag>/<wordset_tag>/eng-USA/mix.nlu",
...
}
Multiple compiled wordset URIs can be specified, up to a maximum of 5. Pass of list of strings with the wordset_uri
parmaeter to do so:
"nlu": {
"use_asr_results": true,
"model_uri": "urn:nuance-mix:tag:model/coffee_demo/mix.nlu?=language=eng-USA",
"wordset_uri": ["urn:nuance-mix:tag:wordset:lang/<companion_artifact_context_tag>/<wordset_tag_1>/eng-USA/mix.nlu",
"urn:nuance-mix:tag:wordset:lang/<companion_artifact_context_tag>/<wordset_tag_2>/eng-USA/mix.nlu",
"urn:nuance-mix:tag:wordset:lang/<companion_artifact_context_tag>/<wordset_tag_3>/eng-USA/mix.nlu"],
...
}
See the NLUaaS Wordset gRPC API for more information about creating and interacting with NLUaaS compiled wordset resources.