Skip to main content

Sending User Feedback

Receiving in an integrated way the use feedback of voice recognition is very important to the improvement of the offered solution, better serving the specific needs of each user.

Sending a use feedback

A user feedback can be collected via feedbacks.submit(). This method waits a text field, which corresponds to the feedback properly said; a mood field, which is an object containing a text description and a user satisfying level correspondent emoji with a tool; and a subject field, which corresponds to the feedback topic, as accuracy or functionality request. The accepted values to the mood and subject fields are available in the properties feedbacks.MOODS and feedbacks.SUBJECTS respectively.

Observation: In your test environment, don't forget to assign the value true to the property mock of the object of feedbacks, sending the shipment of invalid feedbacks.

A basic feedback shipping example would be:

var recognition = new IaraSpeechRecognition();

recognition.feedbacks.mock = true;
recognition.init({
// ...
}).done(function(e) {
// Builds and sends an example feedback
recognition.feedbacks.submit(
'I'm very happy with Iara voice recognition!',
recognition.feedbacks.SUBJECTS.feedback,
recognition.feedbacks.MOODS.very_happy,
function() {
console.log('Feedback sent successfully!');
}
)
}).fail(function(e) {
// ...
});