You already have a Machine Learning model, in addition, you created the running scenario all by yourself in just a few minutes. So… let’s take it to the next level. What will you do to categorize customers based on performance?
P.S. If you are looking for a quick, easy, and effective way to deploy your ML model, look here – we have described the whole process step by step 🙂
If you would like to try to categorize the scoring results with us, download the simple .py script we’ve prepared for you – we’ll be working on it today. Let’s start!
Open Scoring.One, go back to the scenario creation and add another item. Before the “End” tile, place the “Expressions” tile (drag it from the left to the scenario box) – this is where you can enter code in Python, R, or Groovy. The variables created here will be returned by the model along with the results.
When the variable “category” has been added by you, along with the final scoring score, you will also receive the category into which its value falls.
It’s time for an http query. Use any (http) client for this purpose. We will use the requests library for Python as an example.
In the space provided for entering the URL, insert:
How do you find the user key? It is hidden under the “Score Token”.
Now, enter the variables necessary in the model as the Body of the query. Below is an example of how to set all the necessary information during a query.
Run the script. A json with the query results will be returned. And that’s it, job well done!
As you can see, Machine Learning analytics-based operations present challenges when you use the right tools to do so. If you are looking for help with advanced questions, you can find our experts at email@example.com. Go ahead and leave a message 🙂