Semantria
  1. ProcessingDocuments
Semantria
  • Blacklist
    • Remove items from blacklist
      DELETE
    • Retrieve blacklisted items
      GET
    • Add items to blacklist
      POST
    • Update items in blacklist
      PUT
  • Categories
    • Remove user categories
      DELETE
    • Retrieve user categories
      GET
    • Add user categories
      POST
    • Updates user categories
      PUT
  • ProcessingCollections
    • Queue collection for analysis
      POST
    • Retrieve collections analysis
      GET
    • Cancel collection analysis
      DELETE
    • Retrieve collection analysis or its status in queue
      GET
  • Configuration
    • Remove user configurations
      DELETE
    • Retrieve user configurations
      GET
    • Create user configurations
      POST
    • Update user configurations
      PUT
  • ProcessingDocuments
    • Queue document for analysis
      POST
    • Queue batch of documents for analysis
      POST
    • Retrieve documents analysis
      GET
    • Cancel document analysis
      DELETE
    • Retrieve document analysis or its status in queue
      GET
  • Entities
    • Remove user entities
      DELETE
    • Retrieve user entities
      GET
    • Add user entities
      POST
    • Update user entities
      PUT
  • Features
    • Retrieve supported features
  • Phrases
    • Remove sentiment-bearing phrases
    • Retrieve sentiment-bearing phrases
    • Add sentiment-bearing phrases
    • Updates sentiment-bearing phrases
  • Queries
    • Remove queries
    • Retrieve queries
    • Add or update queries
    • Update queries
  • Statistics
    • Retrieve usage statistics
  • Status
    • Retrieve API status
  • Subscription
    • Retrieve subscription details
  • Taxonomy
    • Remove taxonomy nodes
    • Retrieve taxonomy
    • Add taxonomy nodes
    • Update taxonomy nodes
  1. ProcessingDocuments

Retrieve documents analysis

GET
/document/processed.{content_type}
This method retrieves analysis results for processed documents from Semantria. FAILED documents will have FAILED status in response. Semantria responds with limited amount of results per API call. If configuration ID provided, Semantria responds with the document, which were queued using the same configuration ID, in opposite Primary.
Request Request Example
Shell
JavaScript
Java
Swift
curl --location --request GET 'https://api.semantria.com//document/processed.'
Response Response Example
200 - Example 1
{
    "auto_categories": [
        {
            "categories": [
                {
                    "strength_score": 0,
                    "title": "string",
                    "type": "string"
                }
            ],
            "sentiment_polarity": "negative",
            "sentiment_score": 0,
            "strength_score": 0,
            "title": "string",
            "type": "string"
        }
    ],
    "config_id": "string",
    "details": [
        {
            "is_imperative": true,
            "is_polar": true,
            "words": [
                {
                    "is_negated": true,
                    "sentiment_score": 0,
                    "stemmed": "string",
                    "tag": "string",
                    "title": "string",
                    "type": "string"
                }
            ]
        }
    ],
    "entities": [
        {
            "count": 0,
            "entity_type": "string",
            "label": "string",
            "mentions": [
                {
                    "is_negated": true,
                    "label": "string",
                    "locations": [
                        {
                            "index": 0,
                            "length": 0,
                            "offset": 0
                        }
                    ],
                    "negating_phrase": "string"
                }
            ],
            "negative_count": 0,
            "neutral_count": 0,
            "positive_count": 0,
            "title": "string",
            "type": "named"
        }
    ],
    "id": "string",
    "intentions": [
        {
            "evidence_phrase": "string",
            "type": "string",
            "what": "string",
            "who": "string"
        }
    ],
    "job_id": "string",
    "language": "string",
    "language_score": 0,
    "model_sentiment": {
        "mixed_score": 0,
        "model_name": "string",
        "negative_score": 0,
        "neutral_score": 0,
        "positive_score": 0,
        "sentiment_polarity": "negative"
    },
    "opinions": [
        {
            "quotation": "string",
            "sentiment_polarity": "negative",
            "sentiment_score": 0,
            "speaker": 0,
            "topic": "string",
            "type": "named"
        }
    ],
    "phrases": [
        {
            "intensifying_phrase": "string",
            "is_intensified": true,
            "is_negated": true,
            "negating_phrase": "string",
            "sentiment_polarity": "negative",
            "sentiment_score": 0,
            "title": "string",
            "type": "string"
        }
    ],
    "relations": [
        {
            "confidence_score": 0,
            "entities": [
                {
                    "entity_type": "string",
                    "title": "string"
                }
            ],
            "extra": "string",
            "relation_type": "string",
            "type": "named"
        }
    ],
    "sentiment_polarity": "negative",
    "sentiment_score": 0,
    "source_text": "string",
    "status": "queued",
    "summary": "string",
    "taxonomy": [
        {
            "hitcount": 0,
            "id": "string",
            "sentiment_polarity": "negative",
            "sentiment_score": 0,
            "title": "string",
            "type": "concept"
        }
    ],
    "themes": [
        {
            "mentions": [
                {
                    "is_negated": true,
                    "label": "string",
                    "locations": [
                        {
                            "index": 0,
                            "length": 0,
                            "offset": 0
                        }
                    ],
                    "negating_phrase": "string"
                }
            ],
            "normalized": "string",
            "phrases_count": 0,
            "sentiment_polarity": "negative",
            "sentiment_score": 0,
            "stemmed": "string",
            "themes_count": 0,
            "title": "string"
        }
    ],
    "topics": [
        {
            "hitcount": 0,
            "id": "string",
            "sentiment_polarity": "negative",
            "sentiment_score": 0,
            "title": "string",
            "type": "concept"
        }
    ]
}

Request

Path Params
content_type
string 
required
Query Params
config_id
string 
optional
Identifier of configuration used for analysis.

Responses

🟢200Client request accepted and queued. Server responds with processed documents.
application/json
Body
auto_categories
array[object (AutoCategory) {6}] 
required
Auto-generated categories applicable for the document
categories
array[object (SubCategory) {3}] 
required
List of sub-categories of the current category if applicable
sentiment_polarity
enum<string> 
required
Verbal representation of sentiment score. Can be "negative", "positive" or "neutral"
Allowed values:
negativepositiveneutral
sentiment_score
number <double>
required
The sentiment score associated with this category
strength_score
number <double>
required
Strength of the category matches with the document content
title
string 
required
The category title, which is its label in the text
type
string 
required
Type of category; can be either "node" (root level) or "leaf" (nested) value
config_id
string 
required
Unique configuration identifier. Usually 36 alphanumeric characters
details
array[object (Details) {3}] 
required
Returns sentences from the original document with POS tags within
is_imperative
boolean 
required
Represents whether sentence (group of words) is imperative or not
is_polar
boolean 
required
Represents whether or not sentence content contains sentiment polarity
words
array[object (Word) {6}] 
required
Returns list of words grouped by the parent sentence
entities
array[object (Entity) {9}] 
required
Returns the named entities and user defined entities from the text
count
integer 
required
The count of occurrences of the entity across the documents
>= 0
entity_type
string 
required
Type of the entity (Company, Person, Place, Product, etc.)
label
string 
required
Descriptive label for the entity, if applicable
mentions
array[object (Mention) {4}] 
required
Returns the genuine forms of entity mentioned across the documents
negative_count
integer 
required
The count of negative occurrences of the entity across the documents
>= 0
neutral_count
integer 
required
The count of neutral occurrences of the entity across the documents
>= 0
positive_count
integer 
required
The count of positive occurrences of the entity across the documents
>= 0
title
string 
required
Normalized form of the entity. It is the normalized entity title
type
enum<string> 
required
Type of the entity; can be either “named” or “user” (reserved for future usage)
Allowed values:
nameduser
id
string 
required
Unique document identifier. Can be up to 36 alphanumeric characters
intentions
array[object (Intention) {4}] 
required
Returns intentions list detected by the engine
evidence_phrase
string 
required
The phrase which expressed the intention
type
string 
required
The classification of the intention detected (buy, quit, etc.)
what
string 
required
The object of the intention (if detected)
who
string 
required
The author of the intention (if detected)
job_id
string 
required
Specific marker of a job document belongs to, can be used for documents ordering on client side
language
string 
required
Determined language of source text
language_score
number <double>
required
The percentage score of the best match of language among detected languages
model_sentiment
object (ModelSentiment) 
required
mixed_score
number <double>
required
Mixed sentiment score associated with the document
model_name
string 
required
Name of the sentiment model used for scoring
negative_score
number <double>
required
Negative (probable negative score) sentiment score associated with the document
neutral_score
number <double>
required
Neutral (probable neutral score) sentiment score associated with the document
positive_score
number <double>
required
Positive (probable positive score) sentiment score associated with the document
sentiment_polarity
enum<string> 
required
Verbal representation of sentiment score that matches the best on the document. Can be "negative", "positive" or "neutral"
Allowed values:
negativepositiveneutral
opinions
array[object (Opinion) {6}] 
required
Returns the list of opinions extracted from the source text
quotation
string 
required
The text of the expressed opinion
sentiment_polarity
enum<string> 
required
Verbal representation of sentiment score. Can be "negative", "positive" or "neutral"
Allowed values:
negativepositiveneutral
sentiment_score
number <double>
required
The sentiment score associated with the opinion
speaker
number <float>
required
An entity title identifying the author of the opinion
topic
string 
required
An entity title identifying the subject of the opinion, if applicable
type
enum<string> 
required
Type of opinion according to extracted entity
Allowed values:
nameduser
phrases
array[object (Phrase) {8}] 
required
Returns sentiment-bearing phrases of the document
intensifying_phrase
string 
required
If the phrase has been intensified, this gives the intensifying phrase
is_intensified
boolean 
required
Specifies whether the phrase has been intensified or not
is_negated
boolean 
required
Specifies whether the phrase has been negated or not
negating_phrase
string 
required
If the phrase has been negated, this gives the negating phrase
sentiment_polarity
enum<string> 
required
Verbal representation of sentiment score. Can be "negative", "positive" or "neutral"
Allowed values:
negativepositiveneutral
sentiment_score
number <double>
required
The sentiment score associated with this phrase
title
string 
required
The text of the sentiment-bearing phrase
type
string 
required
Type of phrase; can be either "possible" or "detected" value
relations
array[object (Relation) {5}] 
required
Returns relations which represent a connection between one or more Entity objects
confidence_score
number <float>
required
A measure of confidence in the relationship extraction
entities
array[object (RelationEntity) {2}] 
required
Returns entities which presents parent relationship
extra
string 
required
Extra information that has been extracted about the relationship
relation_type
string 
required
A label describing the nature of the relationship
type
enum<string> 
required
Type of relation according to extracted entities
Allowed values:
nameduser
sentiment_polarity
enum<string> 
required
Verbal representation of sentiment score. Can be "negative", "positive" or "neutral"
Allowed values:
negativepositiveneutral
sentiment_score
number <double>
required
A sentiment analysis of the document text
source_text
string 
required
Original source text passed by client for this document
status
enum<string> 
required
Status of the document
Allowed values:
queuedprocessedfailed
summary
string 
required
A summary of the document text
taxonomy
array[object (Topic) {6}] 
required
Returns the taxonomy determined for the text
hitcount
integer 
required
The number of documents within the collection that match the topic
>= 0
id
string 
required
Unique topic identifier
sentiment_polarity
enum<string> 
required
Verbal representation of sentiment score. Can be "negative", "positive" or "neutral"
Allowed values:
negativepositiveneutral
sentiment_score
number <double>
required
The sentiment score for documents content associated with the topic
title
string 
required
The topic title, which is its label in the text
type
enum<string> 
required
Type of the topic; can be either "concept" or "query"
Allowed values:
conceptquery
themes
array[object (Theme) {8}] 
required
Returns themes of the document
mentions
array[object (Mention) {4}] 
required
Returns the concept and query defined topics determined for the text
normalized
string 
required
The normalized form of the theme
phrases_count
integer 
required
Count of sentiment-bearing phrases was used in calculating theme's sentiment
>= 0
sentiment_polarity
enum<string> 
required
Verbal representation of sentiment score. Can be "negative", "positive" or "neutral"
Allowed values:
negativepositiveneutral
sentiment_score
number <double>
required
Sentiment score for theme’s sentences across the documents
stemmed
string 
required
The stemmed form of the theme
themes_count
integer 
required
Count of themes across the documents that got rolled into this one
>= 0
title
string 
required
The text of the theme across the documents
topics
array[object (Topic) {6}] 
required
Returns the concept and query defined topics determined for the text
hitcount
integer 
required
The number of documents within the collection that match the topic
>= 0
id
string 
required
Unique topic identifier
sentiment_polarity
enum<string> 
required
Verbal representation of sentiment score. Can be "negative", "positive" or "neutral"
Allowed values:
negativepositiveneutral
sentiment_score
number <double>
required
The sentiment score for documents content associated with the topic
title
string 
required
The topic title, which is its label in the text
type
enum<string> 
required
Type of the topic; can be either "concept" or "query"
Allowed values:
conceptquery
🟢202Client request accepted, no processed documents found on the server.
🟠401Authentication failed.
🟠402Unauthorized. Limit of system calls is reached or subscription is expired.
🔴500Server side issue. Server may respond with the details in response body.
Modified at 2022-09-10 18:38:13
Previous
Queue batch of documents for analysis
Next
Cancel document analysis
Built with