All URIs are relative to https://api.cloudmersive.com
Method | HTTP request | Description |
---|---|---|
analytics_hate_speech | POST /nlp-v2/analytics/hate-speech | Perform Hate Speech Analysis and Detection on Text |
analytics_profanity | POST /nlp-v2/analytics/profanity | Perform Profanity and Obscene Language Analysis and Detection on Text |
analytics_sentiment | POST /nlp-v2/analytics/sentiment | Perform Sentiment Analysis and Classification on Text |
analytics_similarity | POST /nlp-v2/analytics/similarity | Perform Semantic Similarity Comparison of Two Strings |
analytics_subjectivity | POST /nlp-v2/analytics/subjectivity | Perform Subjectivity and Objectivity Analysis on Text |
HateSpeechAnalysisResponse analytics_hate_speech(input)
Perform Hate Speech Analysis and Detection on Text
Analyze input text using advanced Hate Speech Analysis to determine if the input contains hate speech language. Supports English language input. Consumes 1-2 API calls per sentence.
from __future__ import print_function
import time
import cloudmersive_nlp_api_client
from cloudmersive_nlp_api_client.rest import ApiException
from pprint import pprint
# Configure API key authorization: Apikey
configuration = cloudmersive_nlp_api_client.Configuration()
configuration.api_key['Apikey'] = 'YOUR_API_KEY'
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['Apikey'] = 'Bearer'
# create an instance of the API class
api_instance = cloudmersive_nlp_api_client.AnalyticsApi(cloudmersive_nlp_api_client.ApiClient(configuration))
input = cloudmersive_nlp_api_client.HateSpeechAnalysisRequest() # HateSpeechAnalysisRequest | Input hate speech analysis request
try:
# Perform Hate Speech Analysis and Detection on Text
api_response = api_instance.analytics_hate_speech(input)
pprint(api_response)
except ApiException as e:
print("Exception when calling AnalyticsApi->analytics_hate_speech: %s\n" % e)
Name | Type | Description | Notes |
---|---|---|---|
input | HateSpeechAnalysisRequest | Input hate speech analysis request |
- Content-Type: application/json, text/json, application/xml, text/xml, application/x-www-form-urlencoded
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
ProfanityAnalysisResponse analytics_profanity(input)
Perform Profanity and Obscene Language Analysis and Detection on Text
Analyze input text using advanced Profanity and Obscene Language Analysis to determine if the input contains profane language. Supports English language input. Consumes 1-2 API calls per sentence.
from __future__ import print_function
import time
import cloudmersive_nlp_api_client
from cloudmersive_nlp_api_client.rest import ApiException
from pprint import pprint
# Configure API key authorization: Apikey
configuration = cloudmersive_nlp_api_client.Configuration()
configuration.api_key['Apikey'] = 'YOUR_API_KEY'
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['Apikey'] = 'Bearer'
# create an instance of the API class
api_instance = cloudmersive_nlp_api_client.AnalyticsApi(cloudmersive_nlp_api_client.ApiClient(configuration))
input = cloudmersive_nlp_api_client.ProfanityAnalysisRequest() # ProfanityAnalysisRequest | Input profanity analysis request
try:
# Perform Profanity and Obscene Language Analysis and Detection on Text
api_response = api_instance.analytics_profanity(input)
pprint(api_response)
except ApiException as e:
print("Exception when calling AnalyticsApi->analytics_profanity: %s\n" % e)
Name | Type | Description | Notes |
---|---|---|---|
input | ProfanityAnalysisRequest | Input profanity analysis request |
- Content-Type: application/json, text/json, application/xml, text/xml, application/x-www-form-urlencoded
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
SentimentAnalysisResponse analytics_sentiment(input)
Perform Sentiment Analysis and Classification on Text
Analyze input text using advanced Sentiment Analysis to determine if the input is positive, negative, or neutral. Supports English language input. Consumes 1-2 API calls per sentence.
from __future__ import print_function
import time
import cloudmersive_nlp_api_client
from cloudmersive_nlp_api_client.rest import ApiException
from pprint import pprint
# Configure API key authorization: Apikey
configuration = cloudmersive_nlp_api_client.Configuration()
configuration.api_key['Apikey'] = 'YOUR_API_KEY'
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['Apikey'] = 'Bearer'
# create an instance of the API class
api_instance = cloudmersive_nlp_api_client.AnalyticsApi(cloudmersive_nlp_api_client.ApiClient(configuration))
input = cloudmersive_nlp_api_client.SentimentAnalysisRequest() # SentimentAnalysisRequest | Input sentiment analysis request
try:
# Perform Sentiment Analysis and Classification on Text
api_response = api_instance.analytics_sentiment(input)
pprint(api_response)
except ApiException as e:
print("Exception when calling AnalyticsApi->analytics_sentiment: %s\n" % e)
Name | Type | Description | Notes |
---|---|---|---|
input | SentimentAnalysisRequest | Input sentiment analysis request |
- Content-Type: application/json, text/json, application/xml, text/xml, application/x-www-form-urlencoded
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
SimilarityAnalysisResponse analytics_similarity(input)
Perform Semantic Similarity Comparison of Two Strings
Analyze two input text strings, typically sentences, and determine the semantic similarity of each. Semantic similarity refers to the degree to which two sentences mean the same thing semantically. Uses advanced Deep Learning to perform the semantic similarity comparison. Consumes 1-2 API calls per sentence.
from __future__ import print_function
import time
import cloudmersive_nlp_api_client
from cloudmersive_nlp_api_client.rest import ApiException
from pprint import pprint
# Configure API key authorization: Apikey
configuration = cloudmersive_nlp_api_client.Configuration()
configuration.api_key['Apikey'] = 'YOUR_API_KEY'
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['Apikey'] = 'Bearer'
# create an instance of the API class
api_instance = cloudmersive_nlp_api_client.AnalyticsApi(cloudmersive_nlp_api_client.ApiClient(configuration))
input = cloudmersive_nlp_api_client.SimilarityAnalysisRequest() # SimilarityAnalysisRequest | Input similarity analysis request
try:
# Perform Semantic Similarity Comparison of Two Strings
api_response = api_instance.analytics_similarity(input)
pprint(api_response)
except ApiException as e:
print("Exception when calling AnalyticsApi->analytics_similarity: %s\n" % e)
Name | Type | Description | Notes |
---|---|---|---|
input | SimilarityAnalysisRequest | Input similarity analysis request |
- Content-Type: application/json, text/json, application/xml, text/xml, application/x-www-form-urlencoded
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
SubjectivityAnalysisResponse analytics_subjectivity(input)
Perform Subjectivity and Objectivity Analysis on Text
Analyze input text using advanced Subjectivity and Objectivity Language Analysis to determine if the input text is objective or subjective, and how much. Supports English language input. Consumes 1-2 API calls per sentence.
from __future__ import print_function
import time
import cloudmersive_nlp_api_client
from cloudmersive_nlp_api_client.rest import ApiException
from pprint import pprint
# Configure API key authorization: Apikey
configuration = cloudmersive_nlp_api_client.Configuration()
configuration.api_key['Apikey'] = 'YOUR_API_KEY'
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['Apikey'] = 'Bearer'
# create an instance of the API class
api_instance = cloudmersive_nlp_api_client.AnalyticsApi(cloudmersive_nlp_api_client.ApiClient(configuration))
input = cloudmersive_nlp_api_client.SubjectivityAnalysisRequest() # SubjectivityAnalysisRequest | Input subjectivity analysis request
try:
# Perform Subjectivity and Objectivity Analysis on Text
api_response = api_instance.analytics_subjectivity(input)
pprint(api_response)
except ApiException as e:
print("Exception when calling AnalyticsApi->analytics_subjectivity: %s\n" % e)
Name | Type | Description | Notes |
---|---|---|---|
input | SubjectivityAnalysisRequest | Input subjectivity analysis request |
- Content-Type: application/json, text/json, application/xml, text/xml, application/x-www-form-urlencoded
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]