Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
Hi.
Can someone guide me on how to set up a connection to Text Analytics API using the Enterprise Gateway?
Thanks.
Hi @runski,
As Smoupre said, do you use API on the link below?
Please provide us more details about what you have done, so that we can make further analysis.
Regards,
Charlie Liao
Hi @v-caliao-msft@Greg_Deckler,
I work together with @runski. My post above explains our implementation approach and the error message the we see when we try to refresh our data using the Enterprise Gateway.
We do use the API from Microsoft Azure in the link provided by @v-caliao-msft.
We followed the method outlined in these blog posts. The only difference is that the text we analyse come from our on-premise SQL server instead of from Facebook.
http://community.powerbi.com/t5/Community-Blog/Sentiment-Analysis-in-Power-BI/ba-p/55898
http://datachant.com/2016/08/09/sentiment-analysis-power-bi-part-2/
Yesterday, we tried connecting to the .pibx file stored in OneDrive as opposed to publishing it to the Power BI Service. We were not able to refresh the data using this approach either.
Regards,
Ivar
I'm getting this as well it's very frustrating, has anyone found a work around or a fix yet?
{ "statusCode": 404, "message": "Resource not found" } when using the URL
https://westus.api.cognitive.microsoft.com/text/analytics/v2.0
Assuming that you are referring to the Text Analytics API in the Azure Data Marketplace, in looking at this article:
https://azure.microsoft.com/en-us/documentation/articles/machine-learning-apps-text-analytics/
I would think that what you need to do is implement this in "M" code. Is that what you are doing?
We implemented the API in a Blank Query using the following code
(Source as table) as any =>
let
JsonRecords = Text.FromBinary(Json.FromValue(Source)),
JsonRequest = "{""documents"": " & JsonRecords & "}",
JsonContent = Text.ToBinary(JsonRequest, TextEncoding.Ascii),
Response =
Web.Contents("https://westus.api.cognitive.microsoft.com/text/analytics/v2.0/sentiment",
[
Headers = [#"Ocp-Apim-Subscription-Key"= "Our API key",
#"Content-Type"="application/json", Accept="application/json"],
Content=JsonContent
]),
JsonResponse = Json.Document(Response,1252)
in
JsonResponse
We then call the Query from a table that contains the text we want to analyze. The text comes from our on-premise SQL server that we connect to through the Enterprise data gateway. When we try to enable refresh on the dataset we get the following error.
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
113 | |
97 | |
85 | |
70 | |
61 |
User | Count |
---|---|
151 | |
121 | |
104 | |
87 | |
67 |