Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
4 years ago
Solved

AI Text Analytics fields returned

I would like to use the built in AI Insights, specifically Text Analytics for Sentiment Analysis in PBI.

However, it seems to respond differently than the equivalent Azure Cognative Services.

I would like it to return the "Document Label", described here: https://docs.microsoft.com/en-us/azure/cognitive-services/language-service/sentiment-opinion-mining/how-to/call-api

Positive, Mixed, Negative, Neutral.

 

I am able to accomplish this when creating my own function to use Azure Cog Services.

How can I do this with the PBI built in function?

 

Here is Azure, You can see I pick the "Sentiment" field to return.

It returns one of 4 words:

 

However, using the PBI function, I'm unsure if I can modify this to do the same?

 

  • Anonymous's avatar
    Anonymous
    4 years ago

    Hi Anonymous ,

     

    Azure will take a swift amount of time and create a new column named CognitiveServices.ScoreSentiment which now contains the sentiment value of the news. This was performed by the use of the Azure Cognitive Services - Score Sentiment feature which is integrated into the premium version of Power BI. Here, in the backend, the Power BI will make an API call by itself to Azure Cognitive Services Text Analysis Model which will return the Score Sentiment value on the Power BI automatically.

     

    As we can see, the values are between 0 and 1.

    The closer the Sentiment value is to 1- it can be recognized as more Positive News and the closer the sentiment of the news is to 0, it can be understood are more negative.

     

    You could add a Conditional Column to make this outcome more intuitive.Suppose if the sentiment value is above 0.5 the News is Positive, 0.5 precise as Neutral and below 0.5 as Negative.

     

    Refer to:

    A CLOSER LOOK AT TEXT ANALYTICS (SCORE SENTIMENT) IN POWER BI DESKTOP

    SENTIMENT ANALYSIS IN POWER BI DESKTOP

    Azure Text Analytics and Power BI

    Power BI Tutorial - Sentiment Analysis

     

     

    Best Regards,
    Eyelyn Qin
    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

4 Replies

  • Anonymous's avatar
    Anonymous
    Not applicable

    Hi Anonymous ,

     

    Azure will take a swift amount of time and create a new column named CognitiveServices.ScoreSentiment which now contains the sentiment value of the news. This was performed by the use of the Azure Cognitive Services - Score Sentiment feature which is integrated into the premium version of Power BI. Here, in the backend, the Power BI will make an API call by itself to Azure Cognitive Services Text Analysis Model which will return the Score Sentiment value on the Power BI automatically.

     

    As we can see, the values are between 0 and 1.

    The closer the Sentiment value is to 1- it can be recognized as more Positive News and the closer the sentiment of the news is to 0, it can be understood are more negative.

     

    You could add a Conditional Column to make this outcome more intuitive.Suppose if the sentiment value is above 0.5 the News is Positive, 0.5 precise as Neutral and below 0.5 as Negative.

     

    Refer to:

    A CLOSER LOOK AT TEXT ANALYTICS (SCORE SENTIMENT) IN POWER BI DESKTOP

    SENTIMENT ANALYSIS IN POWER BI DESKTOP

    Azure Text Analytics and Power BI

    Power BI Tutorial - Sentiment Analysis

     

     

    Best Regards,
    Eyelyn Qin
    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

    • Anonymous's avatar
      Anonymous
      Not applicable

      Thank you.

      So there's no way to return the same azure sentiments (ideally, "mixed" with the combination of phrases) in Power BI?

       

      Is it accurate then to do the exact values as you specified:

      < 0.5 = negative

      =0.5 = neutral

      >0.5 = positive

  • Anonymous's avatar
    Anonymous
    Not applicable

    Hi Anonymous ,

     

    Just based on my researching, you may specified the range by yourself , there seems to be no range for Mixed value.

     

    For example, as this video mentioned, it has been set to

    <=0.25  then negative, >=0.75 then positive, else neutral.

     

    Best Regards,
    Eyelyn Qin
    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

    • Anonymous's avatar
      Anonymous
      Not applicable

      Thank you.

      Looks like unfortunately the PBI call is not as detailed as the azure call.

      But I can't use azure directly without some credits.

       

      Thanks. Perhaps I'll submit an idea to improve the feature in PBI