indico.io
A node.js wrapper for the indico API.
Installation
Install with npm
npm install indico.io
API Keys + Setup
For API key registration and setup, checkout our quickstart guide.
Supported APIs
Text
- Sentiment Analysis
- Text Tagging
- Political Analysis
- Keyword Detection
- Summarization
- Personality Detection
- People, Place, and Organizations Detection
- Text Relevance Analysis
- Language Detection
- Twitter Virality
- Intersectional Analysis
- Multi-API Analysis
Image
- Facial Emotion Recognition
- Image Feature Extraction
- Facial Feature Extraction
- Face Localization
- Content Filtering
- Image Recognition
- Multi-API Analysis
Custom Collections
- Train on your own data and make customized predictions
Full Documentation
Detailed documentation and further code examples are available at indico.io/docs.
Examples
var indico = require('indico.io');
indico.apiKey = "YOUR_API_KEY";
indico
.political('Guns don\'t kill people. People kill people.')
.then(function(res){
console.log(res);
})
.catch(function(err){
console.log('err: ', err);
})
.then(indico.sentiment)
indico
.sentiment('Worst movie ever.')
.then(function(){
console.log(res);
})
.catch(function(err){
console.log('err: ', err);
})
indico
.sentiment('Really enjoyed the movie.')
.then(function(){
console.log(res);
})
.catch(function(err){
console.log('err: ', err);
})
indico
.language('Quis custodiet ipsos custodes')
.then(function(){
console.log(res);
.texttags("This coconut green tea is amazing.");
})
.catch(function(err){
console.log('err: ', err);
})
indico
.imageFeatures(testImage)
.then(function(){
console.log(res);
})
.catch(function(err){
console.log('err: ', err);
})
indico
.fer(testImage)
.then(function(){
console.log(res);
})
.catch(function(err){
console.log('err: ', err);
});
###Batch
Batch requests allow you to process larger volumes of data more efficiently by grouping many examples into a single request. Simply call the batch method that corresponds to the API you'd like to use, and ensure your data is wrapped in an array.
var indico = require('indico.io')
indico
.batchSentiment(['Worst movie ever.', 'Best movie ever.'])
.then(function(res){
console.log(res)
})
.catch(function(err){
console.log('err: ', err);
})