
Hey everyone, thanks for checking in again. This week, I’ll be covering my integration experience with Chatterbox. If you missed it, I covered Semantria last week, and AlchemyAPI the week before that. Again, I will try to be as objective as possible and highlight all aspects of the integration from my personal experience.
Chatterbox
The API is simple and supports only a few basic features, sentiment analysis being one of them. Chatterbox doesn’t have an SDK available, so I was forced to implement everything manually. This wasn’t a major problem, because of the simplicity of the implementation. Authentication was done through the custom header and a simple API key, so the entire code related to sentiment analysis requests looks like the following:
Dictionary<string, string> parameters = new Dictionary<string, string>(); parameters.Add("lang", LocaleHelper.GetDoubleLanguageAbbreviation(context.Language)); parameters.Add("text", Encoding.UTF8.GetString(Encoding.UTF8.GetBytes(document.Value.Source))); WebRequest request = WebRequest.Create("https://chatterbox-analytics-sentiment-analysis-free.p.mashape.com/sentiment/current/classify_text/"); request.Headers.Add("X-Mashape-Authorization", context.Key); request.ContentType = "application/x-www-form-urlencoded"; request.Method = "POST";
In order to work with native objects, I added a small auxiliary class that is used for deserialization of the Chatterbox response from their sentiment analysis end-point.
[DataContract(Name = "sentiment")]
public sealed class ChatterboxSentiment
{
[DataMember(Name = "language")] public string Language { get; set; } [DataMember(Name = "value")] public double Value { get; set; } [DataMember(Name = "sent")] public int Sent { get; set; }
}
After I had integrated with Chatterbox, the API worked as expected and analyzed documents asynchronously one by one.
Overall Opinion
Chatterbox doesn’t have its own infrastructure, so their API is published on Mashape API marketplace and because of this, an SDK is not available. However, Mashape offers sample code for easy integration. Integration itself is very straightforward and no specific configuration or settings are necessary.
Check in next week for my integration experience with Viralheat.
George Kozlov is a software engineering guru. He specializes in software research, architecture and maintenance. He co-founded Semantria, and is currently their CTO and go-to guy when things need improving.
January 18, 2015 at 1:56 am
Hi webmaster do you need unlimited content for your page ?
What if you could copy content from other websites, make it unique and publish
on your website – i know the right tool for you, just search
in google:
Ziakdra’s article tool
February 2, 2016 at 8:46 am
Your site can go viral, you need some initial traffic only.
But how to get initial traffic??? Search in google for: Leaghk’s method to go viral
July 28, 2016 at 7:30 pm
Crossing Frequency: again, if you’re using wingers to
get the ball into the box with crosses, you might have this order set to Always ‘ if you’re playing a traditional 4-4-2 formation and working the ball through the middle, you
would have this set to Rarely. Start an online blog with a free Google blogger account or WordPress and blog from your i – Phone with blogpress app or
Wordpress for iphone. You can play any European cup or participate
in your own competition.
November 12, 2016 at 8:26 am
The Marriage protection had a moment of dilemma that lead on Friday to the purpose of Landon Donovan. It was also the reply to the
Toyota Quints alternative of Ford. https://V.gd/car_service_provider_48605