I am currently trying to integrate an on-cloud ASR such that the wakeword model triggers a recording, which consequently is sent to the cloud, and then the response forwarded back into the pipeline triggering the NLU stage within Spokestack. I plan to record through Flutter after didActivate() has been called, and then once the response has been retrieved, pass the data into the NLU. I cannot however, figure out what syntax to follow for the data structure (JSON, simple , yaml, toml, text, inline text etc) and how to pass this data into the NLU.I am developing a Flutter plugin for this, so the implementation has to be done both on Android and iOS. Our NLU Model is being transitioned to Azure, which I’ve noticed is not supported by Spokestack hence the on-cloud alternative. Any feedback is highly appreciated!
Going through the source-code (spokestack-ios/NLUService.swift at master · spokestack/spokestack-ios · GitHub) I have found the following function def:
@objc func classify(utterance: String, context: [String : Any]) -> Void
I presume the parameter utterance, in this case, refers to a raw string output that would be coming from an ASR? Would I be correct to assume this is where I pass the data, and what/why do we need to pass a context alongide it?