Data Machines
...
Models Supported by Data Machi...
NLP Models
Tone Classification
4min
this model analyzes a given passage and identifies the tone present in the text it classifies a text input relative to the tone represented in the text (e g frustrated, sad, impolite, excited, sympathetic, satisfied, etc ) for instance, "i hate school school is bad " returns seven different results the first three of which are “frustrated” with a confidence score of 0 74309075, “sad” at 0 20021306, and “impolite” at 0 07343281 model input parameters parameter name parameter type required input text yes rest api input example var settings = { "url" "https //mlapi qualetics com/api/datamachine/init?id=\<datamachine id>", "method" "post", "headers" { //add authorization headers here "content type" "application/json" }, "data" json stringify({ "input" "it’s back! taco bell has announced the return of the double decker taco, which is now on the menu at restaurants nationwide for a limited time " }), }; $ ajax(settings) done(function (response) { console log(response); }); model output result parameter name parameter type classes identified json string rest api output example { "input" "it’s back! taco bell has announced the return of the double decker taco, which is now on the menu at restaurants nationwide for a limited time ", "original input" "it’s back! taco bell has announced the return of the double decker taco, which is now on the menu at restaurants nationwide for a limited time ", "classes identified" "\[{\\"classname\\" \\"frustrated\\", \\"confidence\\" 0 583574}, {\\"classname\\" \\"sad\\", \\"confidence\\" 0 2899403}, {\\"classname\\" \\"impolite\\", \\"confidence\\" 0 16715494}, {\\"classname\\" \\"polite\\", \\"confidence\\" 0 13063201}, {\\"classname\\" \\"excited\\", \\"confidence\\" 0 10055948}, {\\"classname\\" \\"sympathetic\\", \\"confidence\\" 0 032292116}, {\\"classname\\" \\"satisfied\\", \\"confidence\\" 0 025560096}]", "final result" "\[{\\"classname\\" \\"frustrated\\", \\"confidence\\" 0 583574}, {\\"classname\\" \\"sad\\", \\"confidence\\" 0 2899403}, {\\"classname\\" \\"impolite\\", \\"confidence\\" 0 16715494}, {\\"classname\\" \\"polite\\", \\"confidence\\" 0 13063201}, {\\"classname\\" \\"excited\\", \\"confidence\\" 0 10055948}, {\\"classname\\" \\"sympathetic\\", \\"confidence\\" 0 032292116}, {\\"classname\\" \\"satisfied\\", \\"confidence\\" 0 025560096}]", "sessionid" "08f19eb7 5570 4a19 90d0 b2c549c762a5", "status" "completed" } standard output parameters every model execution output consists of the following standard output parameters input the input string required for the model to extract the categories original input this is the input provided to the first step in model which is retained across multiple steps in a data machine workflow final result the result of the model executed in the final step of the data machine workflow sessionid a unique session id that is generated for every execution of a data machine which can be used to retain results across multiple sessions status the result of the data machine execution if all of the steps in a sequence are successfully executed, a value of "completed" is provided if the execution is interrupted at any point, a value of "terminated" is provided with the reason for termination