Sentiment Analyzer: positive, negative and neutral scores
Pricing
from $3.60 / 1,000 text analyzeds
Sentiment Analyzer: positive, negative and neutral scores
Scores the sentiment of texts you supply or of a dataset in your account: positive, negative and neutral probabilities for each text, with optional sentence and aspect detail. The models run inside the actor; no outside service is called.
Give it texts, or pick a dataset in your account such as the output of a review scraper, and it returns the sentiment of each text: a label, the positive, neutral and negative probabilities, and a compound score from minus one to one.
The models run inside the actor. No outside service is called and no API key is needed.
- English:
cardiffnlp/twitter-roberta-base-sentiment-latest, trained on social media posts, released under CC BY 4.0 - Multilingual:
lxyuan/distilbert-base-multilingual-cased-sentiments-student, released under the Apache 2.0 license
Detail levels
- Document: one result per text. A text with several sentences is scored sentence by sentence, and the document score is the mean of its sentences, weighted by length.
- Sentences: the document result plus every sentence with its own label and scores.
- Aspects: the sentence detail plus a result for every aspect term you list, such as price, delivery or staff. Each term gets the scores of the sentences that mention it, and
mentions: 0when no sentence does.
Input
- Texts: one result per text
- Datasets to analyze: datasets in your account. The run gets read access to the datasets you pick and nothing else.
- Text field (default
text) and an optional ID field copied to each result asitemId - Maximum items per dataset (default 1,000)
- Model: English (default) or Multilingual
- Detail level and aspect terms
Output
Dataset: one item per text with index, source (input or the dataset ID), ok, model, text, label (positive, neutral or negative), scores, compound (positive minus negative), sentenceCount, and with more detail, sentences and aspects. Dataset items also carry itemNumber and itemId. A text that cannot be scored gets ok: false and an error, and the run carries on. Texts longer than 20,000 characters are scored on their first 20,000 characters, with a note.
Tested
- Short English reviews: positive, negative and neutral sentences each got the expected label from the English model
- A review that praises the food and criticizes the service: food scored positive, service negative, prices neutral, and an unmentioned term returned
mentions: 0 - Spanish, French and German sentences with the Multilingual model
- A dataset from an earlier run, read through the dataset picker, including an item without the text field
- A 24,000 character text, an empty text
- The maximum charge: texts it does not cover are left unprocessed
The Multilingual model is the weaker of the two. In testing it scored a neutral English sentence and the one word text "Awful." as positive, where the English model returned neutral and negative. Use the English model for English text.
Speed
With 1 GB of memory, a run that scored two typed texts and three dataset items took 10 seconds.
Pricing
Pay per event: one event per text scored, at any detail level. Texts that fail are not charged. The run stops scoring when it reaches the maximum charge you set, and the texts left get an error saying so.
Scope and conduct
Only the texts and datasets you supply are read. Nothing is collected from websites.
Support
Questions and problems: the Issues tab on this page. Replies are written by an AI assistant on behalf of the developer and reviewed by the developer.