cloudmersive-nlp-api-client 2.0.7 → 3.0.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile +1 -1
- data/README.md +16 -8
- data/cloudmersive-nlp-api-client.gemspec +3 -3
- data/docs/AnalyticsApi.md +113 -3
- data/docs/ExtractEntitiesApi.md +1 -1
- data/docs/HateSpeechAnalysisRequest.md +8 -0
- data/docs/HateSpeechAnalysisResponse.md +10 -0
- data/docs/LanguageDetectionApi.md +1 -1
- data/docs/LanguageTranslationApi.md +114 -4
- data/docs/ParseApi.md +1 -1
- data/docs/PosTaggerApi.md +6 -6
- data/docs/RephraseApi.md +1 -1
- data/docs/SegmentationApi.md +2 -2
- data/docs/SimilarityAnalysisRequest.md +9 -0
- data/docs/SimilarityAnalysisResponse.md +10 -0
- data/docs/SpellcheckApi.md +2 -2
- data/lib/cloudmersive-nlp-api-client.rb +5 -1
- data/lib/cloudmersive-nlp-api-client/api/analytics_api.rb +120 -15
- data/lib/cloudmersive-nlp-api-client/api/extract_entities_api.rb +6 -7
- data/lib/cloudmersive-nlp-api-client/api/language_detection_api.rb +6 -7
- data/lib/cloudmersive-nlp-api-client/api/language_translation_api.rb +124 -20
- data/lib/cloudmersive-nlp-api-client/api/parse_api.rb +6 -7
- data/lib/cloudmersive-nlp-api-client/api/pos_tagger_api.rb +26 -32
- data/lib/cloudmersive-nlp-api-client/api/rephrase_api.rb +6 -7
- data/lib/cloudmersive-nlp-api-client/api/segmentation_api.rb +10 -12
- data/lib/cloudmersive-nlp-api-client/api/spellcheck_api.rb +10 -12
- data/lib/cloudmersive-nlp-api-client/api_client.rb +11 -9
- data/lib/cloudmersive-nlp-api-client/api_error.rb +1 -1
- data/lib/cloudmersive-nlp-api-client/configuration.rb +2 -2
- data/lib/cloudmersive-nlp-api-client/models/check_sentence_request.rb +7 -10
- data/lib/cloudmersive-nlp-api-client/models/check_sentence_response.rb +7 -10
- data/lib/cloudmersive-nlp-api-client/models/check_word_request.rb +7 -11
- data/lib/cloudmersive-nlp-api-client/models/check_word_response.rb +7 -10
- data/lib/cloudmersive-nlp-api-client/models/correct_word_in_sentence.rb +7 -10
- data/lib/cloudmersive-nlp-api-client/models/entity.rb +7 -11
- data/lib/cloudmersive-nlp-api-client/models/extract_entities_request.rb +7 -10
- data/lib/cloudmersive-nlp-api-client/models/extract_entities_response.rb +7 -10
- data/lib/cloudmersive-nlp-api-client/models/get_words_request.rb +7 -11
- data/lib/cloudmersive-nlp-api-client/models/get_words_response.rb +7 -10
- data/lib/cloudmersive-nlp-api-client/models/hate_speech_analysis_request.rb +186 -0
- data/lib/cloudmersive-nlp-api-client/models/hate_speech_analysis_response.rb +206 -0
- data/lib/cloudmersive-nlp-api-client/models/language_detection_request.rb +7 -10
- data/lib/cloudmersive-nlp-api-client/models/language_detection_response.rb +7 -10
- data/lib/cloudmersive-nlp-api-client/models/language_translation_request.rb +7 -10
- data/lib/cloudmersive-nlp-api-client/models/language_translation_response.rb +7 -10
- data/lib/cloudmersive-nlp-api-client/models/parse_request.rb +7 -10
- data/lib/cloudmersive-nlp-api-client/models/parse_response.rb +7 -10
- data/lib/cloudmersive-nlp-api-client/models/pos_request.rb +7 -10
- data/lib/cloudmersive-nlp-api-client/models/pos_response.rb +7 -10
- data/lib/cloudmersive-nlp-api-client/models/pos_sentence.rb +7 -10
- data/lib/cloudmersive-nlp-api-client/models/pos_tagged_word.rb +7 -10
- data/lib/cloudmersive-nlp-api-client/models/profanity_analysis_request.rb +7 -10
- data/lib/cloudmersive-nlp-api-client/models/profanity_analysis_response.rb +7 -10
- data/lib/cloudmersive-nlp-api-client/models/rephrase_request.rb +7 -10
- data/lib/cloudmersive-nlp-api-client/models/rephrase_response.rb +7 -10
- data/lib/cloudmersive-nlp-api-client/models/rephrased_sentence.rb +7 -10
- data/lib/cloudmersive-nlp-api-client/models/rephrased_sentence_option.rb +7 -10
- data/lib/cloudmersive-nlp-api-client/models/sentence_segmentation_request.rb +7 -11
- data/lib/cloudmersive-nlp-api-client/models/sentence_segmentation_response.rb +7 -11
- data/lib/cloudmersive-nlp-api-client/models/sentiment_analysis_request.rb +7 -10
- data/lib/cloudmersive-nlp-api-client/models/sentiment_analysis_response.rb +7 -10
- data/lib/cloudmersive-nlp-api-client/models/similarity_analysis_request.rb +196 -0
- data/lib/cloudmersive-nlp-api-client/models/similarity_analysis_response.rb +206 -0
- data/lib/cloudmersive-nlp-api-client/models/subjectivity_analysis_request.rb +7 -10
- data/lib/cloudmersive-nlp-api-client/models/subjectivity_analysis_response.rb +7 -10
- data/lib/cloudmersive-nlp-api-client/models/word_position.rb +7 -11
- data/lib/cloudmersive-nlp-api-client/version.rb +2 -2
- data/spec/api/analytics_api_spec.rb +28 -4
- data/spec/api/extract_entities_api_spec.rb +2 -2
- data/spec/api/language_detection_api_spec.rb +2 -2
- data/spec/api/language_translation_api_spec.rb +29 -5
- data/spec/api/parse_api_spec.rb +2 -2
- data/spec/api/pos_tagger_api_spec.rb +7 -7
- data/spec/api/rephrase_api_spec.rb +2 -2
- data/spec/api/segmentation_api_spec.rb +3 -3
- data/spec/api/spellcheck_api_spec.rb +3 -3
- data/spec/api_client_spec.rb +52 -35
- data/spec/configuration_spec.rb +9 -9
- data/spec/models/check_sentence_request_spec.rb +2 -3
- data/spec/models/check_sentence_response_spec.rb +3 -4
- data/spec/models/check_word_request_spec.rb +2 -3
- data/spec/models/check_word_response_spec.rb +3 -4
- data/spec/models/correct_word_in_sentence_spec.rb +4 -5
- data/spec/models/entity_spec.rb +3 -4
- data/spec/models/extract_entities_request_spec.rb +2 -3
- data/spec/models/extract_entities_response_spec.rb +3 -4
- data/spec/models/get_words_request_spec.rb +2 -3
- data/spec/models/get_words_response_spec.rb +2 -3
- data/spec/models/hate_speech_analysis_request_spec.rb +41 -0
- data/spec/models/hate_speech_analysis_response_spec.rb +53 -0
- data/spec/models/language_detection_request_spec.rb +2 -3
- data/spec/models/language_detection_response_spec.rb +4 -5
- data/spec/models/language_translation_request_spec.rb +2 -3
- data/spec/models/language_translation_response_spec.rb +4 -5
- data/spec/models/parse_request_spec.rb +2 -3
- data/spec/models/parse_response_spec.rb +2 -3
- data/spec/models/pos_request_spec.rb +2 -3
- data/spec/models/pos_response_spec.rb +2 -3
- data/spec/models/pos_sentence_spec.rb +2 -3
- data/spec/models/pos_tagged_word_spec.rb +3 -4
- data/spec/models/profanity_analysis_request_spec.rb +2 -3
- data/spec/models/profanity_analysis_response_spec.rb +4 -5
- data/spec/models/rephrase_request_spec.rb +3 -4
- data/spec/models/rephrase_response_spec.rb +4 -5
- data/spec/models/rephrased_sentence_option_spec.rb +3 -4
- data/spec/models/rephrased_sentence_spec.rb +4 -5
- data/spec/models/sentence_segmentation_request_spec.rb +2 -3
- data/spec/models/sentence_segmentation_response_spec.rb +4 -5
- data/spec/models/sentiment_analysis_request_spec.rb +2 -3
- data/spec/models/sentiment_analysis_response_spec.rb +5 -6
- data/spec/models/similarity_analysis_request_spec.rb +47 -0
- data/spec/models/similarity_analysis_response_spec.rb +53 -0
- data/spec/models/subjectivity_analysis_request_spec.rb +2 -3
- data/spec/models/subjectivity_analysis_response_spec.rb +4 -5
- data/spec/models/word_position_spec.rb +5 -6
- data/spec/spec_helper.rb +1 -1
- metadata +14 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 89061ed6c299ee2c50a887fc52caa5d68899ef7120c6bc7148b0b3f318d84f5a
|
4
|
+
data.tar.gz: 571ad3efebfbc9667b38fe75ff6e4c8d633f1cb66ac90cacbb0a6afd53eab906
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 8b02082705e55fbadd9a3e75bdf486bc28615af59b122c5731e83c757c77e48856c31292cd7ac0a8a1b27b05c247eb8a0fbab094fd5ab217096eec6fb4c553f0
|
7
|
+
data.tar.gz: cf3a0e56b067af0802b75b874f299a96694f2f25be41fffa4360f3569878ea111173df94e4f33ea2b40bac823377239a68173094edbf4d947fc88155d91dcf56
|
data/Gemfile
CHANGED
data/README.md
CHANGED
@@ -7,7 +7,7 @@ The powerful Natural Language Processing APIs (v2) let you perform part of speec
|
|
7
7
|
This SDK is automatically generated by the [Swagger Codegen](https://github.com/swagger-api/swagger-codegen) project:
|
8
8
|
|
9
9
|
- API version: v1
|
10
|
-
- Package version:
|
10
|
+
- Package version: 3.0.3
|
11
11
|
- Build package: io.swagger.codegen.languages.RubyClientCodegen
|
12
12
|
|
13
13
|
## Installation
|
@@ -23,15 +23,15 @@ gem build cloudmersive-nlp-api-client.gemspec
|
|
23
23
|
Then either install the gem locally:
|
24
24
|
|
25
25
|
```shell
|
26
|
-
gem install ./cloudmersive-nlp-api-client-
|
26
|
+
gem install ./cloudmersive-nlp-api-client-3.0.3.gem
|
27
27
|
```
|
28
|
-
(for development, run `gem install --dev ./cloudmersive-nlp-api-client-
|
28
|
+
(for development, run `gem install --dev ./cloudmersive-nlp-api-client-3.0.3.gem` to install the development dependencies)
|
29
29
|
|
30
30
|
or publish the gem to a gem hosting service, e.g. [RubyGems](https://rubygems.org/).
|
31
31
|
|
32
32
|
Finally add this to the Gemfile:
|
33
33
|
|
34
|
-
gem 'cloudmersive-nlp-api-client', '~>
|
34
|
+
gem 'cloudmersive-nlp-api-client', '~> 3.0.3'
|
35
35
|
|
36
36
|
### Install from Git
|
37
37
|
|
@@ -64,15 +64,15 @@ end
|
|
64
64
|
|
65
65
|
api_instance = CloudmersiveNlpApiClient::AnalyticsApi.new
|
66
66
|
|
67
|
-
input = CloudmersiveNlpApiClient::
|
67
|
+
input = CloudmersiveNlpApiClient::HateSpeechAnalysisRequest.new # HateSpeechAnalysisRequest | Input hate speech analysis request
|
68
68
|
|
69
69
|
|
70
70
|
begin
|
71
|
-
#Perform
|
72
|
-
result = api_instance.
|
71
|
+
#Perform Hate Speech Analysis and Detection on Text
|
72
|
+
result = api_instance.analytics_hate_speech(input)
|
73
73
|
p result
|
74
74
|
rescue CloudmersiveNlpApiClient::ApiError => e
|
75
|
-
puts "Exception when calling AnalyticsApi->
|
75
|
+
puts "Exception when calling AnalyticsApi->analytics_hate_speech: #{e}"
|
76
76
|
end
|
77
77
|
|
78
78
|
```
|
@@ -83,14 +83,18 @@ All URIs are relative to *https://api.cloudmersive.com*
|
|
83
83
|
|
84
84
|
Class | Method | HTTP request | Description
|
85
85
|
------------ | ------------- | ------------- | -------------
|
86
|
+
*CloudmersiveNlpApiClient::AnalyticsApi* | [**analytics_hate_speech**](docs/AnalyticsApi.md#analytics_hate_speech) | **POST** /nlp-v2/analytics/hate-speech | Perform Hate Speech Analysis and Detection on Text
|
86
87
|
*CloudmersiveNlpApiClient::AnalyticsApi* | [**analytics_profanity**](docs/AnalyticsApi.md#analytics_profanity) | **POST** /nlp-v2/analytics/profanity | Perform Profanity and Obscene Language Analysis and Detection on Text
|
87
88
|
*CloudmersiveNlpApiClient::AnalyticsApi* | [**analytics_sentiment**](docs/AnalyticsApi.md#analytics_sentiment) | **POST** /nlp-v2/analytics/sentiment | Perform Sentiment Analysis and Classification on Text
|
89
|
+
*CloudmersiveNlpApiClient::AnalyticsApi* | [**analytics_similarity**](docs/AnalyticsApi.md#analytics_similarity) | **POST** /nlp-v2/analytics/similarity | Perform Semantic Similarity Comparison of Two Strings
|
88
90
|
*CloudmersiveNlpApiClient::AnalyticsApi* | [**analytics_subjectivity**](docs/AnalyticsApi.md#analytics_subjectivity) | **POST** /nlp-v2/analytics/subjectivity | Perform Subjectivity and Objectivity Analysis on Text
|
89
91
|
*CloudmersiveNlpApiClient::ExtractEntitiesApi* | [**extract_entities_post**](docs/ExtractEntitiesApi.md#extract_entities_post) | **POST** /nlp-v2/extract-entities | Extract entities from string
|
90
92
|
*CloudmersiveNlpApiClient::LanguageDetectionApi* | [**language_detection_get_language**](docs/LanguageDetectionApi.md#language_detection_get_language) | **POST** /nlp-v2/language/detect | Detect language of text
|
91
93
|
*CloudmersiveNlpApiClient::LanguageTranslationApi* | [**language_translation_translate_deu_to_eng**](docs/LanguageTranslationApi.md#language_translation_translate_deu_to_eng) | **POST** /nlp-v2/translate/language/deu/to/eng | Translate German to English text with Deep Learning AI
|
92
94
|
*CloudmersiveNlpApiClient::LanguageTranslationApi* | [**language_translation_translate_eng_to_deu**](docs/LanguageTranslationApi.md#language_translation_translate_eng_to_deu) | **POST** /nlp-v2/translate/language/eng/to/deu | Translate English to German text with Deep Learning AI
|
95
|
+
*CloudmersiveNlpApiClient::LanguageTranslationApi* | [**language_translation_translate_eng_to_fra**](docs/LanguageTranslationApi.md#language_translation_translate_eng_to_fra) | **POST** /nlp-v2/translate/language/eng/to/fra | Translate English to French text with Deep Learning AI
|
93
96
|
*CloudmersiveNlpApiClient::LanguageTranslationApi* | [**language_translation_translate_eng_to_rus**](docs/LanguageTranslationApi.md#language_translation_translate_eng_to_rus) | **POST** /nlp-v2/translate/language/eng/to/rus | Translate English to Russian text with Deep Learning AI
|
97
|
+
*CloudmersiveNlpApiClient::LanguageTranslationApi* | [**language_translation_translate_fra_to_eng**](docs/LanguageTranslationApi.md#language_translation_translate_fra_to_eng) | **POST** /nlp-v2/translate/language/fra/to/eng | Translate French to English text with Deep Learning AI
|
94
98
|
*CloudmersiveNlpApiClient::LanguageTranslationApi* | [**language_translation_translate_rus_to_eng**](docs/LanguageTranslationApi.md#language_translation_translate_rus_to_eng) | **POST** /nlp-v2/translate/language/rus/to/eng | Translate Russian to English text with Deep Learning AI
|
95
99
|
*CloudmersiveNlpApiClient::ParseApi* | [**parse_parse_string**](docs/ParseApi.md#parse_parse_string) | **POST** /nlp-v2/parse/tree | Parse string to syntax tree
|
96
100
|
*CloudmersiveNlpApiClient::PosTaggerApi* | [**pos_tagger_tag_adjectives**](docs/PosTaggerApi.md#pos_tagger_tag_adjectives) | **POST** /nlp-v2/pos/tag/adjectives | Part-of-speech tag a string, filter to adjectives
|
@@ -118,6 +122,8 @@ Class | Method | HTTP request | Description
|
|
118
122
|
- [CloudmersiveNlpApiClient::ExtractEntitiesResponse](docs/ExtractEntitiesResponse.md)
|
119
123
|
- [CloudmersiveNlpApiClient::GetWordsRequest](docs/GetWordsRequest.md)
|
120
124
|
- [CloudmersiveNlpApiClient::GetWordsResponse](docs/GetWordsResponse.md)
|
125
|
+
- [CloudmersiveNlpApiClient::HateSpeechAnalysisRequest](docs/HateSpeechAnalysisRequest.md)
|
126
|
+
- [CloudmersiveNlpApiClient::HateSpeechAnalysisResponse](docs/HateSpeechAnalysisResponse.md)
|
121
127
|
- [CloudmersiveNlpApiClient::LanguageDetectionRequest](docs/LanguageDetectionRequest.md)
|
122
128
|
- [CloudmersiveNlpApiClient::LanguageDetectionResponse](docs/LanguageDetectionResponse.md)
|
123
129
|
- [CloudmersiveNlpApiClient::LanguageTranslationRequest](docs/LanguageTranslationRequest.md)
|
@@ -138,6 +144,8 @@ Class | Method | HTTP request | Description
|
|
138
144
|
- [CloudmersiveNlpApiClient::SentenceSegmentationResponse](docs/SentenceSegmentationResponse.md)
|
139
145
|
- [CloudmersiveNlpApiClient::SentimentAnalysisRequest](docs/SentimentAnalysisRequest.md)
|
140
146
|
- [CloudmersiveNlpApiClient::SentimentAnalysisResponse](docs/SentimentAnalysisResponse.md)
|
147
|
+
- [CloudmersiveNlpApiClient::SimilarityAnalysisRequest](docs/SimilarityAnalysisRequest.md)
|
148
|
+
- [CloudmersiveNlpApiClient::SimilarityAnalysisResponse](docs/SimilarityAnalysisResponse.md)
|
141
149
|
- [CloudmersiveNlpApiClient::SubjectivityAnalysisRequest](docs/SubjectivityAnalysisRequest.md)
|
142
150
|
- [CloudmersiveNlpApiClient::SubjectivityAnalysisResponse](docs/SubjectivityAnalysisResponse.md)
|
143
151
|
- [CloudmersiveNlpApiClient::WordPosition](docs/WordPosition.md)
|
@@ -1,5 +1,5 @@
|
|
1
1
|
# -*- encoding: utf-8 -*-
|
2
|
-
|
2
|
+
|
3
3
|
=begin
|
4
4
|
#nlpapiv2
|
5
5
|
|
@@ -8,7 +8,7 @@
|
|
8
8
|
OpenAPI spec version: v1
|
9
9
|
|
10
10
|
Generated by: https://github.com/swagger-api/swagger-codegen.git
|
11
|
-
Swagger Codegen version: 2.
|
11
|
+
Swagger Codegen version: 2.4.14
|
12
12
|
|
13
13
|
=end
|
14
14
|
|
@@ -24,7 +24,7 @@ Gem::Specification.new do |s|
|
|
24
24
|
s.homepage = "https://www.cloudmersive.com/nlp-api"
|
25
25
|
s.summary = "The most powerful and cost-effective NLP AI APIs, continuously updated."
|
26
26
|
s.description = "The powerful Natural Language Processing APIs let you perform part of speech tagging, entity identification, sentence parsing, and much more to help you understand the meaning of unstructured text."
|
27
|
-
s.license =
|
27
|
+
s.license = 'Apache 2.0'
|
28
28
|
s.required_ruby_version = ">= 1.9"
|
29
29
|
|
30
30
|
s.add_runtime_dependency 'typhoeus', '~> 1.0', '>= 1.0.1'
|
data/docs/AnalyticsApi.md
CHANGED
@@ -4,11 +4,67 @@ All URIs are relative to *https://api.cloudmersive.com*
|
|
4
4
|
|
5
5
|
Method | HTTP request | Description
|
6
6
|
------------- | ------------- | -------------
|
7
|
+
[**analytics_hate_speech**](AnalyticsApi.md#analytics_hate_speech) | **POST** /nlp-v2/analytics/hate-speech | Perform Hate Speech Analysis and Detection on Text
|
7
8
|
[**analytics_profanity**](AnalyticsApi.md#analytics_profanity) | **POST** /nlp-v2/analytics/profanity | Perform Profanity and Obscene Language Analysis and Detection on Text
|
8
9
|
[**analytics_sentiment**](AnalyticsApi.md#analytics_sentiment) | **POST** /nlp-v2/analytics/sentiment | Perform Sentiment Analysis and Classification on Text
|
10
|
+
[**analytics_similarity**](AnalyticsApi.md#analytics_similarity) | **POST** /nlp-v2/analytics/similarity | Perform Semantic Similarity Comparison of Two Strings
|
9
11
|
[**analytics_subjectivity**](AnalyticsApi.md#analytics_subjectivity) | **POST** /nlp-v2/analytics/subjectivity | Perform Subjectivity and Objectivity Analysis on Text
|
10
12
|
|
11
13
|
|
14
|
+
# **analytics_hate_speech**
|
15
|
+
> HateSpeechAnalysisResponse analytics_hate_speech(input)
|
16
|
+
|
17
|
+
Perform Hate Speech Analysis and Detection on Text
|
18
|
+
|
19
|
+
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.
|
20
|
+
|
21
|
+
### Example
|
22
|
+
```ruby
|
23
|
+
# load the gem
|
24
|
+
require 'cloudmersive-nlp-api-client'
|
25
|
+
# setup authorization
|
26
|
+
CloudmersiveNlpApiClient.configure do |config|
|
27
|
+
# Configure API key authorization: Apikey
|
28
|
+
config.api_key['Apikey'] = 'YOUR API KEY'
|
29
|
+
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
|
30
|
+
#config.api_key_prefix['Apikey'] = 'Bearer'
|
31
|
+
end
|
32
|
+
|
33
|
+
api_instance = CloudmersiveNlpApiClient::AnalyticsApi.new
|
34
|
+
|
35
|
+
input = CloudmersiveNlpApiClient::HateSpeechAnalysisRequest.new # HateSpeechAnalysisRequest | Input hate speech analysis request
|
36
|
+
|
37
|
+
|
38
|
+
begin
|
39
|
+
#Perform Hate Speech Analysis and Detection on Text
|
40
|
+
result = api_instance.analytics_hate_speech(input)
|
41
|
+
p result
|
42
|
+
rescue CloudmersiveNlpApiClient::ApiError => e
|
43
|
+
puts "Exception when calling AnalyticsApi->analytics_hate_speech: #{e}"
|
44
|
+
end
|
45
|
+
```
|
46
|
+
|
47
|
+
### Parameters
|
48
|
+
|
49
|
+
Name | Type | Description | Notes
|
50
|
+
------------- | ------------- | ------------- | -------------
|
51
|
+
**input** | [**HateSpeechAnalysisRequest**](HateSpeechAnalysisRequest.md)| Input hate speech analysis request |
|
52
|
+
|
53
|
+
### Return type
|
54
|
+
|
55
|
+
[**HateSpeechAnalysisResponse**](HateSpeechAnalysisResponse.md)
|
56
|
+
|
57
|
+
### Authorization
|
58
|
+
|
59
|
+
[Apikey](../README.md#Apikey)
|
60
|
+
|
61
|
+
### HTTP request headers
|
62
|
+
|
63
|
+
- **Content-Type**: application/json, text/json, application/xml, text/xml, application/x-www-form-urlencoded
|
64
|
+
- **Accept**: application/json
|
65
|
+
|
66
|
+
|
67
|
+
|
12
68
|
# **analytics_profanity**
|
13
69
|
> ProfanityAnalysisResponse analytics_profanity(input)
|
14
70
|
|
@@ -59,7 +115,7 @@ Name | Type | Description | Notes
|
|
59
115
|
### HTTP request headers
|
60
116
|
|
61
117
|
- **Content-Type**: application/json, text/json, application/xml, text/xml, application/x-www-form-urlencoded
|
62
|
-
- **Accept**: application/json
|
118
|
+
- **Accept**: application/json
|
63
119
|
|
64
120
|
|
65
121
|
|
@@ -113,7 +169,61 @@ Name | Type | Description | Notes
|
|
113
169
|
### HTTP request headers
|
114
170
|
|
115
171
|
- **Content-Type**: application/json, text/json, application/xml, text/xml, application/x-www-form-urlencoded
|
116
|
-
- **Accept**: application/json
|
172
|
+
- **Accept**: application/json
|
173
|
+
|
174
|
+
|
175
|
+
|
176
|
+
# **analytics_similarity**
|
177
|
+
> SimilarityAnalysisResponse analytics_similarity(input)
|
178
|
+
|
179
|
+
Perform Semantic Similarity Comparison of Two Strings
|
180
|
+
|
181
|
+
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.
|
182
|
+
|
183
|
+
### Example
|
184
|
+
```ruby
|
185
|
+
# load the gem
|
186
|
+
require 'cloudmersive-nlp-api-client'
|
187
|
+
# setup authorization
|
188
|
+
CloudmersiveNlpApiClient.configure do |config|
|
189
|
+
# Configure API key authorization: Apikey
|
190
|
+
config.api_key['Apikey'] = 'YOUR API KEY'
|
191
|
+
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
|
192
|
+
#config.api_key_prefix['Apikey'] = 'Bearer'
|
193
|
+
end
|
194
|
+
|
195
|
+
api_instance = CloudmersiveNlpApiClient::AnalyticsApi.new
|
196
|
+
|
197
|
+
input = CloudmersiveNlpApiClient::SimilarityAnalysisRequest.new # SimilarityAnalysisRequest | Input similarity analysis request
|
198
|
+
|
199
|
+
|
200
|
+
begin
|
201
|
+
#Perform Semantic Similarity Comparison of Two Strings
|
202
|
+
result = api_instance.analytics_similarity(input)
|
203
|
+
p result
|
204
|
+
rescue CloudmersiveNlpApiClient::ApiError => e
|
205
|
+
puts "Exception when calling AnalyticsApi->analytics_similarity: #{e}"
|
206
|
+
end
|
207
|
+
```
|
208
|
+
|
209
|
+
### Parameters
|
210
|
+
|
211
|
+
Name | Type | Description | Notes
|
212
|
+
------------- | ------------- | ------------- | -------------
|
213
|
+
**input** | [**SimilarityAnalysisRequest**](SimilarityAnalysisRequest.md)| Input similarity analysis request |
|
214
|
+
|
215
|
+
### Return type
|
216
|
+
|
217
|
+
[**SimilarityAnalysisResponse**](SimilarityAnalysisResponse.md)
|
218
|
+
|
219
|
+
### Authorization
|
220
|
+
|
221
|
+
[Apikey](../README.md#Apikey)
|
222
|
+
|
223
|
+
### HTTP request headers
|
224
|
+
|
225
|
+
- **Content-Type**: application/json, text/json, application/xml, text/xml, application/x-www-form-urlencoded
|
226
|
+
- **Accept**: application/json
|
117
227
|
|
118
228
|
|
119
229
|
|
@@ -167,7 +277,7 @@ Name | Type | Description | Notes
|
|
167
277
|
### HTTP request headers
|
168
278
|
|
169
279
|
- **Content-Type**: application/json, text/json, application/xml, text/xml, application/x-www-form-urlencoded
|
170
|
-
- **Accept**: application/json
|
280
|
+
- **Accept**: application/json
|
171
281
|
|
172
282
|
|
173
283
|
|
data/docs/ExtractEntitiesApi.md
CHANGED
@@ -57,7 +57,7 @@ Name | Type | Description | Notes
|
|
57
57
|
### HTTP request headers
|
58
58
|
|
59
59
|
- **Content-Type**: application/json, text/json, application/xml, text/xml, application/x-www-form-urlencoded
|
60
|
-
- **Accept**: application/json
|
60
|
+
- **Accept**: application/json
|
61
61
|
|
62
62
|
|
63
63
|
|
@@ -0,0 +1,10 @@
|
|
1
|
+
# CloudmersiveNlpApiClient::HateSpeechAnalysisResponse
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
Name | Type | Description | Notes
|
5
|
+
------------ | ------------- | ------------- | -------------
|
6
|
+
**successful** | **BOOLEAN** | True if the profanity detection operation was successful, false otherwise | [optional]
|
7
|
+
**hate_speech_score_result** | **Float** | Hate speech classification score between 0.0 and 1.0 where scores closer to zero have a low probability of being hate speech language, while scores close to 1.0 have a high probability of being hate speech language. Values above 0.8 have a very high probability of being hate speech. | [optional]
|
8
|
+
**sentence_count** | **Integer** | Number of sentences in input text | [optional]
|
9
|
+
|
10
|
+
|
@@ -57,7 +57,7 @@ Name | Type | Description | Notes
|
|
57
57
|
### HTTP request headers
|
58
58
|
|
59
59
|
- **Content-Type**: application/json, text/json, application/xml, text/xml, application/x-www-form-urlencoded
|
60
|
-
- **Accept**: application/json
|
60
|
+
- **Accept**: application/json
|
61
61
|
|
62
62
|
|
63
63
|
|
@@ -6,7 +6,9 @@ Method | HTTP request | Description
|
|
6
6
|
------------- | ------------- | -------------
|
7
7
|
[**language_translation_translate_deu_to_eng**](LanguageTranslationApi.md#language_translation_translate_deu_to_eng) | **POST** /nlp-v2/translate/language/deu/to/eng | Translate German to English text with Deep Learning AI
|
8
8
|
[**language_translation_translate_eng_to_deu**](LanguageTranslationApi.md#language_translation_translate_eng_to_deu) | **POST** /nlp-v2/translate/language/eng/to/deu | Translate English to German text with Deep Learning AI
|
9
|
+
[**language_translation_translate_eng_to_fra**](LanguageTranslationApi.md#language_translation_translate_eng_to_fra) | **POST** /nlp-v2/translate/language/eng/to/fra | Translate English to French text with Deep Learning AI
|
9
10
|
[**language_translation_translate_eng_to_rus**](LanguageTranslationApi.md#language_translation_translate_eng_to_rus) | **POST** /nlp-v2/translate/language/eng/to/rus | Translate English to Russian text with Deep Learning AI
|
11
|
+
[**language_translation_translate_fra_to_eng**](LanguageTranslationApi.md#language_translation_translate_fra_to_eng) | **POST** /nlp-v2/translate/language/fra/to/eng | Translate French to English text with Deep Learning AI
|
10
12
|
[**language_translation_translate_rus_to_eng**](LanguageTranslationApi.md#language_translation_translate_rus_to_eng) | **POST** /nlp-v2/translate/language/rus/to/eng | Translate Russian to English text with Deep Learning AI
|
11
13
|
|
12
14
|
|
@@ -60,7 +62,7 @@ Name | Type | Description | Notes
|
|
60
62
|
### HTTP request headers
|
61
63
|
|
62
64
|
- **Content-Type**: application/json, text/json, application/xml, text/xml, application/x-www-form-urlencoded
|
63
|
-
- **Accept**: application/json
|
65
|
+
- **Accept**: application/json
|
64
66
|
|
65
67
|
|
66
68
|
|
@@ -114,7 +116,61 @@ Name | Type | Description | Notes
|
|
114
116
|
### HTTP request headers
|
115
117
|
|
116
118
|
- **Content-Type**: application/json, text/json, application/xml, text/xml, application/x-www-form-urlencoded
|
117
|
-
- **Accept**: application/json
|
119
|
+
- **Accept**: application/json
|
120
|
+
|
121
|
+
|
122
|
+
|
123
|
+
# **language_translation_translate_eng_to_fra**
|
124
|
+
> LanguageTranslationResponse language_translation_translate_eng_to_fra(input)
|
125
|
+
|
126
|
+
Translate English to French text with Deep Learning AI
|
127
|
+
|
128
|
+
Automatically translates input text in English to output text in French using advanced Deep Learning and Neural NLP. Consumes 1-2 API calls per input sentence.
|
129
|
+
|
130
|
+
### Example
|
131
|
+
```ruby
|
132
|
+
# load the gem
|
133
|
+
require 'cloudmersive-nlp-api-client'
|
134
|
+
# setup authorization
|
135
|
+
CloudmersiveNlpApiClient.configure do |config|
|
136
|
+
# Configure API key authorization: Apikey
|
137
|
+
config.api_key['Apikey'] = 'YOUR API KEY'
|
138
|
+
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
|
139
|
+
#config.api_key_prefix['Apikey'] = 'Bearer'
|
140
|
+
end
|
141
|
+
|
142
|
+
api_instance = CloudmersiveNlpApiClient::LanguageTranslationApi.new
|
143
|
+
|
144
|
+
input = CloudmersiveNlpApiClient::LanguageTranslationRequest.new # LanguageTranslationRequest | Input translation request
|
145
|
+
|
146
|
+
|
147
|
+
begin
|
148
|
+
#Translate English to French text with Deep Learning AI
|
149
|
+
result = api_instance.language_translation_translate_eng_to_fra(input)
|
150
|
+
p result
|
151
|
+
rescue CloudmersiveNlpApiClient::ApiError => e
|
152
|
+
puts "Exception when calling LanguageTranslationApi->language_translation_translate_eng_to_fra: #{e}"
|
153
|
+
end
|
154
|
+
```
|
155
|
+
|
156
|
+
### Parameters
|
157
|
+
|
158
|
+
Name | Type | Description | Notes
|
159
|
+
------------- | ------------- | ------------- | -------------
|
160
|
+
**input** | [**LanguageTranslationRequest**](LanguageTranslationRequest.md)| Input translation request |
|
161
|
+
|
162
|
+
### Return type
|
163
|
+
|
164
|
+
[**LanguageTranslationResponse**](LanguageTranslationResponse.md)
|
165
|
+
|
166
|
+
### Authorization
|
167
|
+
|
168
|
+
[Apikey](../README.md#Apikey)
|
169
|
+
|
170
|
+
### HTTP request headers
|
171
|
+
|
172
|
+
- **Content-Type**: application/json, text/json, application/xml, text/xml, application/x-www-form-urlencoded
|
173
|
+
- **Accept**: application/json
|
118
174
|
|
119
175
|
|
120
176
|
|
@@ -168,7 +224,61 @@ Name | Type | Description | Notes
|
|
168
224
|
### HTTP request headers
|
169
225
|
|
170
226
|
- **Content-Type**: application/json, text/json, application/xml, text/xml, application/x-www-form-urlencoded
|
171
|
-
- **Accept**: application/json
|
227
|
+
- **Accept**: application/json
|
228
|
+
|
229
|
+
|
230
|
+
|
231
|
+
# **language_translation_translate_fra_to_eng**
|
232
|
+
> LanguageTranslationResponse language_translation_translate_fra_to_eng(input)
|
233
|
+
|
234
|
+
Translate French to English text with Deep Learning AI
|
235
|
+
|
236
|
+
Automatically translates input text in French to output text in English using advanced Deep Learning and Neural NLP. Consumes 1-2 API calls per input sentence.
|
237
|
+
|
238
|
+
### Example
|
239
|
+
```ruby
|
240
|
+
# load the gem
|
241
|
+
require 'cloudmersive-nlp-api-client'
|
242
|
+
# setup authorization
|
243
|
+
CloudmersiveNlpApiClient.configure do |config|
|
244
|
+
# Configure API key authorization: Apikey
|
245
|
+
config.api_key['Apikey'] = 'YOUR API KEY'
|
246
|
+
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
|
247
|
+
#config.api_key_prefix['Apikey'] = 'Bearer'
|
248
|
+
end
|
249
|
+
|
250
|
+
api_instance = CloudmersiveNlpApiClient::LanguageTranslationApi.new
|
251
|
+
|
252
|
+
input = CloudmersiveNlpApiClient::LanguageTranslationRequest.new # LanguageTranslationRequest | Input translation request
|
253
|
+
|
254
|
+
|
255
|
+
begin
|
256
|
+
#Translate French to English text with Deep Learning AI
|
257
|
+
result = api_instance.language_translation_translate_fra_to_eng(input)
|
258
|
+
p result
|
259
|
+
rescue CloudmersiveNlpApiClient::ApiError => e
|
260
|
+
puts "Exception when calling LanguageTranslationApi->language_translation_translate_fra_to_eng: #{e}"
|
261
|
+
end
|
262
|
+
```
|
263
|
+
|
264
|
+
### Parameters
|
265
|
+
|
266
|
+
Name | Type | Description | Notes
|
267
|
+
------------- | ------------- | ------------- | -------------
|
268
|
+
**input** | [**LanguageTranslationRequest**](LanguageTranslationRequest.md)| Input translation request |
|
269
|
+
|
270
|
+
### Return type
|
271
|
+
|
272
|
+
[**LanguageTranslationResponse**](LanguageTranslationResponse.md)
|
273
|
+
|
274
|
+
### Authorization
|
275
|
+
|
276
|
+
[Apikey](../README.md#Apikey)
|
277
|
+
|
278
|
+
### HTTP request headers
|
279
|
+
|
280
|
+
- **Content-Type**: application/json, text/json, application/xml, text/xml, application/x-www-form-urlencoded
|
281
|
+
- **Accept**: application/json
|
172
282
|
|
173
283
|
|
174
284
|
|
@@ -222,7 +332,7 @@ Name | Type | Description | Notes
|
|
222
332
|
### HTTP request headers
|
223
333
|
|
224
334
|
- **Content-Type**: application/json, text/json, application/xml, text/xml, application/x-www-form-urlencoded
|
225
|
-
- **Accept**: application/json
|
335
|
+
- **Accept**: application/json
|
226
336
|
|
227
337
|
|
228
338
|
|