Salesforce Einstein Intent: A Quick Overview

Salesforce Einstein Intent: A Quick Overview

Hi All, As Dreamforce is over and there are lots of new things in the market. but Einstein is on top of that. In my previous post I have already shared about Einstein Vision to predict the image. Today we will cover the basic of Einstein Intent A search Prediction.

You can use Einstein Intent to make a case prediction and route the case to different user  so that case can be solved much faster with less human intervention.


The process is same as we have done for Einstein Vision. First if you don’t have API key or access token then you need to create one. You can follow the same steps as previous post.
After that we first need to create sample Dataset. In this step, you define the labels that you want the model to output when text is sent into the model for prediction. Then you gather text data for each of those labels, and that text is used to create a model.

You can use sample CSV which I have used or can create your own as well.

Then you need to train that dataset. You can also make request to check status of training. and once training is completed you can make your first prediction.

The text which I used for prediction is “Why my shipping address is changed.” And the response which I get is

Prediction Result.png


Its related to Billing and it is Correct. You can create large dataset to make these prediction more accurate. And can play with it yourself.

Let me know what you like most about Einstein in comments. If you want to add something share with me in comments section.

Happy Programming 🙂


Salesforce Einstein Vision: Quick Overview

Salesforce Einstein Vision: Quick Overview

Einstein Vision is part of the Einstein Platform Services technologies, and you can use it to AI-enable your apps. Leverage pre-trained classifiers, or train your own custom classifiers to solve a vast array of specialized image-recognition use cases. Developers can bring the power of image recognition to CRM and third-party applications so that end users across sales, service, and marketing can discover new insights about their customers and predict outcomes that lead to smarter decisions.

Einstein Vision includes these APIs:

  • Einstein Image Classification—Enables developers to train deep learning models to recognize and classify images at scale.
  • Einstein Object Detection (Pilot)—Enables developers to train models to recognize and count multiple distinct objects within an image, providing granular details like the size and location of each object.


Today we will cover the Einstein Image Classification . As we have a very good Apex wrapper provided by Salesforce dev team here. Which you can use to make all request of Einstein while it handle all the heavy work in background for you.

But if you don’t want to install a full library to test these requests then I will share quick code sample which you can use to create your own request.

Before we start first you need to make sure that you have completed all prerequisite steps. You need a valid Einstein token to call API and few base classes to make request.

After all this setup our org is ready to make our first prediction. For our demo purpose we will use Bike vs Car model. Here I have commented Token Id, Dataset Id and Model Id you can enter your related Id there.

First  to make a request we need the access token, Here we take help of our base classes which we have included. To get the access token we will use JWT access token helper.


Then we need to make our Dataset: A data set is a folder which contains the images. Here we pass the data in multipart/form-data format.

Dataset can be created Asyn or syn. In our example we are creating Asynchronously.

Next we will train our dataset to identify the images. You will get Dataset ID from previous request.

this command train the Dataset and create a Model. Model creation process takes time based on number of images which you have provided. In our example number of picture is less so it will complete early.

You can also check the status

Once the Dataset is trained we are ready to make our first prediction.

For prediction we will use this image



And the response we get is



So we get Almost 100% for this image. You can make your own Dataset and can play with them.

Let me know what you like most about Einstein in comments. If you want to add something share with me in comments section.

Happy Programming 🙂

IOT And AI: The future is here

Salesforce with 3 release in a year also introduce many more products from time to time to use the latest technology  to keep it system updated and fast. While the current major thing is Lightning, Salesforce recently introduce two more products and actively working on them. They are Internet of Thing and Artificial Intelligence.

As everyone is aware these two things are major part of IT industry and in upcoming year so salesforce Introduce them for its CRM.  So I everyone should start learning these technology because they are the future and as a Developer we need to keep ourself updated.

IOT: Salesforce IoT Cloud is powered by Thunder, a scalable event processing engine, designed to ingest and analyze billions of events. Events are the data that comes from the networked devices and objects we talked about above. On top of that, Thunder lets you take personalized actions based on these events, which help your company create more enriching and focused customer experiences.


IoT Cloud’s way of taking in data and triggering actions to create experiences lets your company focus on creating engaging, individualized experiences for all your customers. These might be customized alerts, emails, or messages. Or the actions might be something else within Salesforce, like creating a service ticket, or customizing the information they access through an app.

Imagine a world where you can react to real-time information, quickly creating these interactions with all your customers, so that the experiences feel personal, specific, and at the right time. Well, imagine no more. Buckle up for a quick flight to the land of IoT.

Artificial Intelligence:  AI is the concept of having “machines think like humans.” You’re starting to see examples of AI in your everyday life because we’re at an evolutionary tipping point. AI isn’t a new concept—we’ve had the theoretical models for a long time—but it’s finally possible thanks to the access and increase in large amounts of data combined with the low cost of high-power computing.


AI has benefits for all parts of the business. Sales reps no longer have to enter sales data manually. Marketers no longer have to use manual A/B testing to select the best social media images for their next campaign. And customer service managers no longer have to sift through long lists of incoming service calls to prioritize their time.

AI will impact each and every part of CRM and with Einstein  it will make many thing smooth as well because in the bunch of leads it will show most important Leads on top, Notify you to follow from customer and send them reminder email and many other things as well. AI will act like personal Assistance available at anytime anywhere in your fingertip. AI with CRM make Salesforce CRM a smart CRM.

So this is a brief idea of what IOT and AI is but in near future they play an important part and this will make them a must learn thing. So include them in your learning or TO DO list and let me know in comments what things you like most about these and what improvement you want to see in them.