How to analyse sentiment of a news article using AlchemyAPI? - sentiment-analysis

I want to analyse sentiment of a news article (input: text not URL) using AlchemyAPI. Please suggest me how Can I do that.
I tried with demo http://www.alchemyapi.com/products/demo/alchemylanguage/ but it provides sentiment for each entities separately, not for the whole article text.
Thanks for help.

You can get the sentiment for the whole document in the demo, (see screenshot):
If you want to do it programatically, the API call you are looking for is TextGetTextSentiment. You should first register for a free API key. Then to get the sentiment of the text "my great text", go to the following URL:
http://access.alchemyapi.com/calls/text/TextGetTextSentiment?apikey=<YOUR_API_KEY>&sentiment=1&showSourceText=1&text=my%20great%20text
As you see the text is url encoded at the end. For more details take a look at the documentation of TextGetTextSentiment.

Related

Wrong language of books when searching with ISBN on Google Books API

I'm using the Google Books JSON API to get information about books. But all responses I get back is in my local language, even if I query using an english title. Does anyone know if there's any parameter I can set to give results in a certain language? Or can I prevent Google from using my location to get the results in any way?
You can set the langRestrict parameter, in order to restrict results to books with the given language code.
Check out: https://developers.google.com/books/docs/v1/using#langRestrict
Hope that helps.

google-cloud-vision API gives fewer results

I was using ruby client of Google Cloud Vision, to extract the vehicle information on Automobile Original Titles.
Observations:
When I used the client API, i was getting 171 words.
But, when I used the google's API demo here: https://cloud.google.com/vision/, I got 459 words. It has much of the information I was looking for.
Can anyone please explain, how to get the most out of the API ?
I found the answer to my question,
thanks to #marlon-giona.
I was referring to the post: Google Vision API text detection strange behaviour - Javascript
When I used the image.document to extract dense text, I got the exact words I was looking for

Google plus api people.search query parameters documentation

I can't seem to find an official google plus people.search query parameters documentation. on the official page (https://developers.google.com/+/api/latest/people/search) there is only the ambivalent saying: "Specify a query string for full text search of public text in all profiles.".
But how? what about using some 'Geo', some 'by_name', a bit of 'gender'?
sorry if it's appear as a newbie question
Unfortunately, you currently cannot search by specifying metadata and scope to type on results. You can carefully craft your queries to find strings that match your target, however, and I don't recommend doing this. Please file an issue request on the Google+ issue tracker.

actual webpage using rdfa or microdata?

Where is there a webpage that I can load that is using rdfa or microdata? Or, where should I be looking.
I am not asking for a code example. An actual website that is, today, using rdfa or microdata.
For context, I am looking at the google structured data testing tool. I can more or less randomly try things to see what a search result would look like.
When I search in google and find a detailed result, when I look at the actual webpage, I can not find any rdfa or microdata.
Do you consider opengraph as RDFA? Or you mean rdfa except opengraph since OGP is very widely used?
Anyway here are some examples.
youtube (microdata, ogp): example
books.google.com (microdata, ogp): example
bestbuy (microdata, ogp): example
expedia (microdata, ogp, rdfa): example
booking.com (ogp, rdfa): example
curlingcalendar.com (ogp, rdfa): example
yandex.ru (microdata): example, example
I have a Rich Snippets test site at http://schema.openspring.net/, check out the 5 links on the left block "Schema.org examples", they all produce a rich snippet preview. All these pages are using RDFa with schema.org.
Many news web sites use microdata for articles. They are quite often incomplete or otherwise broken though. Some of the better examples are www.telegraph.co.uk, independent.co.uk. They use the schema.org vocabulary.

Can I get the word pronunciation data from Google AJAX Language API

is there a way to get a word pronunciation data from Google AJAX language API? I couldn't find any reference. Is it available at all?
Thanks.
Sure, try this:
http://www.google.com/dictionary/json?callback=dict_api.callbacks.id100&q=example&sl=en&tl=en
where "example" is the word you want the pronunciation for.

Resources