cloudmersive-nlp-api-client 3.0.2 → 3.0.3

Sign up to get free protection for your applications and to get access to all the features.
Files changed (153) hide show
  1. checksums.yaml +4 -4
  2. data/Gemfile +7 -0
  3. data/README.md +162 -0
  4. data/Rakefile +8 -0
  5. data/cloudmersive-nlp-api-client.gemspec +45 -0
  6. data/docs/AnalyticsApi.md +283 -0
  7. data/docs/CheckSentenceRequest.md +8 -0
  8. data/docs/CheckSentenceResponse.md +9 -0
  9. data/docs/CheckWordRequest.md +8 -0
  10. data/docs/CheckWordResponse.md +9 -0
  11. data/docs/CorrectWordInSentence.md +10 -0
  12. data/docs/Entity.md +9 -0
  13. data/docs/ExtractEntitiesApi.md +63 -0
  14. data/docs/ExtractEntitiesRequest.md +8 -0
  15. data/docs/ExtractEntitiesResponse.md +9 -0
  16. data/docs/GetWordsRequest.md +8 -0
  17. data/docs/GetWordsResponse.md +8 -0
  18. data/docs/HateSpeechAnalysisRequest.md +8 -0
  19. data/docs/HateSpeechAnalysisResponse.md +10 -0
  20. data/docs/LanguageDetectionApi.md +63 -0
  21. data/docs/LanguageDetectionRequest.md +8 -0
  22. data/docs/LanguageDetectionResponse.md +10 -0
  23. data/docs/LanguageTranslationApi.md +338 -0
  24. data/docs/LanguageTranslationRequest.md +8 -0
  25. data/docs/LanguageTranslationResponse.md +10 -0
  26. data/docs/ParseApi.md +63 -0
  27. data/docs/ParseRequest.md +8 -0
  28. data/docs/ParseResponse.md +8 -0
  29. data/docs/PosRequest.md +8 -0
  30. data/docs/PosResponse.md +8 -0
  31. data/docs/PosSentence.md +8 -0
  32. data/docs/PosTaggedWord.md +9 -0
  33. data/docs/PosTaggerApi.md +338 -0
  34. data/docs/ProfanityAnalysisRequest.md +8 -0
  35. data/docs/ProfanityAnalysisResponse.md +10 -0
  36. data/docs/RephraseApi.md +63 -0
  37. data/docs/RephraseRequest.md +9 -0
  38. data/docs/RephraseResponse.md +10 -0
  39. data/docs/RephrasedSentence.md +10 -0
  40. data/docs/RephrasedSentenceOption.md +9 -0
  41. data/docs/SegmentationApi.md +118 -0
  42. data/docs/SentenceSegmentationRequest.md +8 -0
  43. data/docs/SentenceSegmentationResponse.md +10 -0
  44. data/docs/SentimentAnalysisRequest.md +8 -0
  45. data/docs/SentimentAnalysisResponse.md +11 -0
  46. data/docs/SimilarityAnalysisRequest.md +9 -0
  47. data/docs/SimilarityAnalysisResponse.md +10 -0
  48. data/docs/SpellcheckApi.md +118 -0
  49. data/docs/SubjectivityAnalysisRequest.md +8 -0
  50. data/docs/SubjectivityAnalysisResponse.md +10 -0
  51. data/docs/WordPosition.md +11 -0
  52. data/git_push.sh +55 -0
  53. data/lib/cloudmersive-nlp-api-client.rb +85 -0
  54. data/lib/cloudmersive-nlp-api-client/api/analytics_api.rb +293 -0
  55. data/lib/cloudmersive-nlp-api-client/api/extract_entities_api.rb +77 -0
  56. data/lib/cloudmersive-nlp-api-client/api/language_detection_api.rb +77 -0
  57. data/lib/cloudmersive-nlp-api-client/api/language_translation_api.rb +347 -0
  58. data/lib/cloudmersive-nlp-api-client/api/parse_api.rb +77 -0
  59. data/lib/cloudmersive-nlp-api-client/api/pos_tagger_api.rb +347 -0
  60. data/lib/cloudmersive-nlp-api-client/api/rephrase_api.rb +77 -0
  61. data/lib/cloudmersive-nlp-api-client/api/segmentation_api.rb +131 -0
  62. data/lib/cloudmersive-nlp-api-client/api/spellcheck_api.rb +131 -0
  63. data/lib/cloudmersive-nlp-api-client/api_client.rb +391 -0
  64. data/lib/cloudmersive-nlp-api-client/api_error.rb +38 -0
  65. data/lib/cloudmersive-nlp-api-client/configuration.rb +209 -0
  66. data/lib/cloudmersive-nlp-api-client/models/check_sentence_request.rb +186 -0
  67. data/lib/cloudmersive-nlp-api-client/models/check_sentence_response.rb +198 -0
  68. data/lib/cloudmersive-nlp-api-client/models/check_word_request.rb +184 -0
  69. data/lib/cloudmersive-nlp-api-client/models/check_word_response.rb +198 -0
  70. data/lib/cloudmersive-nlp-api-client/models/correct_word_in_sentence.rb +208 -0
  71. data/lib/cloudmersive-nlp-api-client/models/entity.rb +193 -0
  72. data/lib/cloudmersive-nlp-api-client/models/extract_entities_request.rb +186 -0
  73. data/lib/cloudmersive-nlp-api-client/models/extract_entities_response.rb +197 -0
  74. data/lib/cloudmersive-nlp-api-client/models/get_words_request.rb +184 -0
  75. data/lib/cloudmersive-nlp-api-client/models/get_words_response.rb +188 -0
  76. data/lib/cloudmersive-nlp-api-client/models/hate_speech_analysis_request.rb +186 -0
  77. data/lib/cloudmersive-nlp-api-client/models/hate_speech_analysis_response.rb +206 -0
  78. data/lib/cloudmersive-nlp-api-client/models/language_detection_request.rb +186 -0
  79. data/lib/cloudmersive-nlp-api-client/models/language_detection_response.rb +206 -0
  80. data/lib/cloudmersive-nlp-api-client/models/language_translation_request.rb +186 -0
  81. data/lib/cloudmersive-nlp-api-client/models/language_translation_response.rb +206 -0
  82. data/lib/cloudmersive-nlp-api-client/models/parse_request.rb +186 -0
  83. data/lib/cloudmersive-nlp-api-client/models/parse_response.rb +186 -0
  84. data/lib/cloudmersive-nlp-api-client/models/pos_request.rb +186 -0
  85. data/lib/cloudmersive-nlp-api-client/models/pos_response.rb +188 -0
  86. data/lib/cloudmersive-nlp-api-client/models/pos_sentence.rb +188 -0
  87. data/lib/cloudmersive-nlp-api-client/models/pos_tagged_word.rb +196 -0
  88. data/lib/cloudmersive-nlp-api-client/models/profanity_analysis_request.rb +186 -0
  89. data/lib/cloudmersive-nlp-api-client/models/profanity_analysis_response.rb +206 -0
  90. data/lib/cloudmersive-nlp-api-client/models/rephrase_request.rb +196 -0
  91. data/lib/cloudmersive-nlp-api-client/models/rephrase_response.rb +208 -0
  92. data/lib/cloudmersive-nlp-api-client/models/rephrased_sentence.rb +208 -0
  93. data/lib/cloudmersive-nlp-api-client/models/rephrased_sentence_option.rb +196 -0
  94. data/lib/cloudmersive-nlp-api-client/models/sentence_segmentation_request.rb +184 -0
  95. data/lib/cloudmersive-nlp-api-client/models/sentence_segmentation_response.rb +204 -0
  96. data/lib/cloudmersive-nlp-api-client/models/sentiment_analysis_request.rb +186 -0
  97. data/lib/cloudmersive-nlp-api-client/models/sentiment_analysis_response.rb +216 -0
  98. data/lib/cloudmersive-nlp-api-client/models/similarity_analysis_request.rb +196 -0
  99. data/lib/cloudmersive-nlp-api-client/models/similarity_analysis_response.rb +206 -0
  100. data/lib/cloudmersive-nlp-api-client/models/subjectivity_analysis_request.rb +186 -0
  101. data/lib/cloudmersive-nlp-api-client/models/subjectivity_analysis_response.rb +206 -0
  102. data/lib/cloudmersive-nlp-api-client/models/word_position.rb +215 -0
  103. data/lib/cloudmersive-nlp-api-client/version.rb +15 -0
  104. data/spec/api/analytics_api_spec.rb +95 -0
  105. data/spec/api/extract_entities_api_spec.rb +47 -0
  106. data/spec/api/language_detection_api_spec.rb +47 -0
  107. data/spec/api/language_translation_api_spec.rb +107 -0
  108. data/spec/api/parse_api_spec.rb +47 -0
  109. data/spec/api/pos_tagger_api_spec.rb +107 -0
  110. data/spec/api/rephrase_api_spec.rb +47 -0
  111. data/spec/api/segmentation_api_spec.rb +59 -0
  112. data/spec/api/spellcheck_api_spec.rb +59 -0
  113. data/spec/api_client_spec.rb +243 -0
  114. data/spec/configuration_spec.rb +42 -0
  115. data/spec/models/check_sentence_request_spec.rb +41 -0
  116. data/spec/models/check_sentence_response_spec.rb +47 -0
  117. data/spec/models/check_word_request_spec.rb +41 -0
  118. data/spec/models/check_word_response_spec.rb +47 -0
  119. data/spec/models/correct_word_in_sentence_spec.rb +53 -0
  120. data/spec/models/entity_spec.rb +47 -0
  121. data/spec/models/extract_entities_request_spec.rb +41 -0
  122. data/spec/models/extract_entities_response_spec.rb +47 -0
  123. data/spec/models/get_words_request_spec.rb +41 -0
  124. data/spec/models/get_words_response_spec.rb +41 -0
  125. data/spec/models/hate_speech_analysis_request_spec.rb +41 -0
  126. data/spec/models/hate_speech_analysis_response_spec.rb +53 -0
  127. data/spec/models/language_detection_request_spec.rb +41 -0
  128. data/spec/models/language_detection_response_spec.rb +53 -0
  129. data/spec/models/language_translation_request_spec.rb +41 -0
  130. data/spec/models/language_translation_response_spec.rb +53 -0
  131. data/spec/models/parse_request_spec.rb +41 -0
  132. data/spec/models/parse_response_spec.rb +41 -0
  133. data/spec/models/pos_request_spec.rb +41 -0
  134. data/spec/models/pos_response_spec.rb +41 -0
  135. data/spec/models/pos_sentence_spec.rb +41 -0
  136. data/spec/models/pos_tagged_word_spec.rb +47 -0
  137. data/spec/models/profanity_analysis_request_spec.rb +41 -0
  138. data/spec/models/profanity_analysis_response_spec.rb +53 -0
  139. data/spec/models/rephrase_request_spec.rb +47 -0
  140. data/spec/models/rephrase_response_spec.rb +53 -0
  141. data/spec/models/rephrased_sentence_option_spec.rb +47 -0
  142. data/spec/models/rephrased_sentence_spec.rb +53 -0
  143. data/spec/models/sentence_segmentation_request_spec.rb +41 -0
  144. data/spec/models/sentence_segmentation_response_spec.rb +53 -0
  145. data/spec/models/sentiment_analysis_request_spec.rb +41 -0
  146. data/spec/models/sentiment_analysis_response_spec.rb +59 -0
  147. data/spec/models/similarity_analysis_request_spec.rb +47 -0
  148. data/spec/models/similarity_analysis_response_spec.rb +53 -0
  149. data/spec/models/subjectivity_analysis_request_spec.rb +41 -0
  150. data/spec/models/subjectivity_analysis_response_spec.rb +53 -0
  151. data/spec/models/word_position_spec.rb +59 -0
  152. data/spec/spec_helper.rb +111 -0
  153. metadata +154 -3
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: a79eeb50467efe00ff4ca18462522961a8696e69e04441ca7c92fb7115296a91
4
- data.tar.gz: ed778dd325f4dd30dd5623d9fbc539434a40f57ada95db40aae887a2fcba5fe5
3
+ metadata.gz: 89061ed6c299ee2c50a887fc52caa5d68899ef7120c6bc7148b0b3f318d84f5a
4
+ data.tar.gz: 571ad3efebfbc9667b38fe75ff6e4c8d633f1cb66ac90cacbb0a6afd53eab906
5
5
  SHA512:
6
- metadata.gz: 4fe1a99212d3a6e9f19642b9e3fcc8e9f37272f5e2216a2fff3abe715dc3f7bf5b2602ed5629a542ef0366e8fdf811be0f1cc5f66cd6a9348ae320097ee21c67
7
- data.tar.gz: b0178710da823b2fb734b31c4ea83e4d7274a1d7c361f19a91ae7c92aa1aea5d459c8ff4fc30d9563178224acad75dd0a19f67dba420aa4b08e65d0d814cac1f
6
+ metadata.gz: 8b02082705e55fbadd9a3e75bdf486bc28615af59b122c5731e83c757c77e48856c31292cd7ac0a8a1b27b05c247eb8a0fbab094fd5ab217096eec6fb4c553f0
7
+ data.tar.gz: cf3a0e56b067af0802b75b874f299a96694f2f25be41fffa4360f3569878ea111173df94e4f33ea2b40bac823377239a68173094edbf4d947fc88155d91dcf56
data/Gemfile ADDED
@@ -0,0 +1,7 @@
1
+ source 'https://rubygems.org'
2
+
3
+ gemspec
4
+
5
+ group :development, :test do
6
+ gem 'rake', '~> 12.3.3'
7
+ end
@@ -0,0 +1,162 @@
1
+ # cloudmersive-nlp-api-client
2
+
3
+ CloudmersiveNlpApiClient - the Ruby gem for the nlpapiv2
4
+
5
+ The powerful Natural Language Processing APIs (v2) let you perform part of speech tagging, entity identification, sentence parsing, and much more to help you understand the meaning of unstructured text.
6
+
7
+ This SDK is automatically generated by the [Swagger Codegen](https://github.com/swagger-api/swagger-codegen) project:
8
+
9
+ - API version: v1
10
+ - Package version: 3.0.3
11
+ - Build package: io.swagger.codegen.languages.RubyClientCodegen
12
+
13
+ ## Installation
14
+
15
+ ### Build a gem
16
+
17
+ To build the Ruby code into a gem:
18
+
19
+ ```shell
20
+ gem build cloudmersive-nlp-api-client.gemspec
21
+ ```
22
+
23
+ Then either install the gem locally:
24
+
25
+ ```shell
26
+ gem install ./cloudmersive-nlp-api-client-3.0.3.gem
27
+ ```
28
+ (for development, run `gem install --dev ./cloudmersive-nlp-api-client-3.0.3.gem` to install the development dependencies)
29
+
30
+ or publish the gem to a gem hosting service, e.g. [RubyGems](https://rubygems.org/).
31
+
32
+ Finally add this to the Gemfile:
33
+
34
+ gem 'cloudmersive-nlp-api-client', '~> 3.0.3'
35
+
36
+ ### Install from Git
37
+
38
+ If the Ruby gem is hosted at a git repository: https://github.com/GIT_USER_ID/GIT_REPO_ID, then add the following in the Gemfile:
39
+
40
+ gem 'cloudmersive-nlp-api-client', :git => 'https://github.com/GIT_USER_ID/GIT_REPO_ID.git'
41
+
42
+ ### Include the Ruby code directly
43
+
44
+ Include the Ruby code directly using `-I` as follows:
45
+
46
+ ```shell
47
+ ruby -Ilib script.rb
48
+ ```
49
+
50
+ ## Getting Started
51
+
52
+ Please follow the [installation](#installation) procedure and then run the following code:
53
+ ```ruby
54
+ # Load the gem
55
+ require 'cloudmersive-nlp-api-client'
56
+
57
+ # Setup authorization
58
+ CloudmersiveNlpApiClient.configure do |config|
59
+ # Configure API key authorization: Apikey
60
+ config.api_key['Apikey'] = 'YOUR API KEY'
61
+ # Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
62
+ #config.api_key_prefix['Apikey'] = 'Bearer'
63
+ end
64
+
65
+ api_instance = CloudmersiveNlpApiClient::AnalyticsApi.new
66
+
67
+ input = CloudmersiveNlpApiClient::HateSpeechAnalysisRequest.new # HateSpeechAnalysisRequest | Input hate speech analysis request
68
+
69
+
70
+ begin
71
+ #Perform Hate Speech Analysis and Detection on Text
72
+ result = api_instance.analytics_hate_speech(input)
73
+ p result
74
+ rescue CloudmersiveNlpApiClient::ApiError => e
75
+ puts "Exception when calling AnalyticsApi->analytics_hate_speech: #{e}"
76
+ end
77
+
78
+ ```
79
+
80
+ ## Documentation for API Endpoints
81
+
82
+ All URIs are relative to *https://api.cloudmersive.com*
83
+
84
+ Class | Method | HTTP request | Description
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
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
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
90
+ *CloudmersiveNlpApiClient::AnalyticsApi* | [**analytics_subjectivity**](docs/AnalyticsApi.md#analytics_subjectivity) | **POST** /nlp-v2/analytics/subjectivity | Perform Subjectivity and Objectivity Analysis on Text
91
+ *CloudmersiveNlpApiClient::ExtractEntitiesApi* | [**extract_entities_post**](docs/ExtractEntitiesApi.md#extract_entities_post) | **POST** /nlp-v2/extract-entities | Extract entities from string
92
+ *CloudmersiveNlpApiClient::LanguageDetectionApi* | [**language_detection_get_language**](docs/LanguageDetectionApi.md#language_detection_get_language) | **POST** /nlp-v2/language/detect | Detect language of text
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
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
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
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
99
+ *CloudmersiveNlpApiClient::ParseApi* | [**parse_parse_string**](docs/ParseApi.md#parse_parse_string) | **POST** /nlp-v2/parse/tree | Parse string to syntax tree
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
101
+ *CloudmersiveNlpApiClient::PosTaggerApi* | [**pos_tagger_tag_adverbs**](docs/PosTaggerApi.md#pos_tagger_tag_adverbs) | **POST** /nlp-v2/pos/tag/adverbs | Part-of-speech tag a string, filter to adverbs
102
+ *CloudmersiveNlpApiClient::PosTaggerApi* | [**pos_tagger_tag_nouns**](docs/PosTaggerApi.md#pos_tagger_tag_nouns) | **POST** /nlp-v2/pos/tag/nouns | Part-of-speech tag a string, filter to nouns
103
+ *CloudmersiveNlpApiClient::PosTaggerApi* | [**pos_tagger_tag_pronouns**](docs/PosTaggerApi.md#pos_tagger_tag_pronouns) | **POST** /nlp-v2/pos/tag/pronouns | Part-of-speech tag a string, filter to pronouns
104
+ *CloudmersiveNlpApiClient::PosTaggerApi* | [**pos_tagger_tag_sentence**](docs/PosTaggerApi.md#pos_tagger_tag_sentence) | **POST** /nlp-v2/pos/tag/sentence | Part-of-speech tag a string
105
+ *CloudmersiveNlpApiClient::PosTaggerApi* | [**pos_tagger_tag_verbs**](docs/PosTaggerApi.md#pos_tagger_tag_verbs) | **POST** /nlp-v2/pos/tag/verbs | Part-of-speech tag a string, filter to verbs
106
+ *CloudmersiveNlpApiClient::RephraseApi* | [**rephrase_english_rephrase_sentence_by_sentence**](docs/RephraseApi.md#rephrase_english_rephrase_sentence_by_sentence) | **POST** /nlp-v2/rephrase/rephrase/eng/by-sentence | Rephrase, paraphrase English text sentence-by-sentence using Deep Learning AI
107
+ *CloudmersiveNlpApiClient::SegmentationApi* | [**segmentation_get_sentences**](docs/SegmentationApi.md#segmentation_get_sentences) | **POST** /nlp-v2/segmentation/sentences | Extract sentences from string
108
+ *CloudmersiveNlpApiClient::SegmentationApi* | [**segmentation_get_words**](docs/SegmentationApi.md#segmentation_get_words) | **POST** /nlp-v2/segmentation/words | Get words in input string
109
+ *CloudmersiveNlpApiClient::SpellcheckApi* | [**spellcheck_check_sentence**](docs/SpellcheckApi.md#spellcheck_check_sentence) | **POST** /nlp-v2/spellcheck/check/sentence | Check if sentence is spelled correctly
110
+ *CloudmersiveNlpApiClient::SpellcheckApi* | [**spellcheck_correct_json**](docs/SpellcheckApi.md#spellcheck_correct_json) | **POST** /nlp-v2/spellcheck/check/word | Find spelling corrections
111
+
112
+
113
+ ## Documentation for Models
114
+
115
+ - [CloudmersiveNlpApiClient::CheckSentenceRequest](docs/CheckSentenceRequest.md)
116
+ - [CloudmersiveNlpApiClient::CheckSentenceResponse](docs/CheckSentenceResponse.md)
117
+ - [CloudmersiveNlpApiClient::CheckWordRequest](docs/CheckWordRequest.md)
118
+ - [CloudmersiveNlpApiClient::CheckWordResponse](docs/CheckWordResponse.md)
119
+ - [CloudmersiveNlpApiClient::CorrectWordInSentence](docs/CorrectWordInSentence.md)
120
+ - [CloudmersiveNlpApiClient::Entity](docs/Entity.md)
121
+ - [CloudmersiveNlpApiClient::ExtractEntitiesRequest](docs/ExtractEntitiesRequest.md)
122
+ - [CloudmersiveNlpApiClient::ExtractEntitiesResponse](docs/ExtractEntitiesResponse.md)
123
+ - [CloudmersiveNlpApiClient::GetWordsRequest](docs/GetWordsRequest.md)
124
+ - [CloudmersiveNlpApiClient::GetWordsResponse](docs/GetWordsResponse.md)
125
+ - [CloudmersiveNlpApiClient::HateSpeechAnalysisRequest](docs/HateSpeechAnalysisRequest.md)
126
+ - [CloudmersiveNlpApiClient::HateSpeechAnalysisResponse](docs/HateSpeechAnalysisResponse.md)
127
+ - [CloudmersiveNlpApiClient::LanguageDetectionRequest](docs/LanguageDetectionRequest.md)
128
+ - [CloudmersiveNlpApiClient::LanguageDetectionResponse](docs/LanguageDetectionResponse.md)
129
+ - [CloudmersiveNlpApiClient::LanguageTranslationRequest](docs/LanguageTranslationRequest.md)
130
+ - [CloudmersiveNlpApiClient::LanguageTranslationResponse](docs/LanguageTranslationResponse.md)
131
+ - [CloudmersiveNlpApiClient::ParseRequest](docs/ParseRequest.md)
132
+ - [CloudmersiveNlpApiClient::ParseResponse](docs/ParseResponse.md)
133
+ - [CloudmersiveNlpApiClient::PosRequest](docs/PosRequest.md)
134
+ - [CloudmersiveNlpApiClient::PosResponse](docs/PosResponse.md)
135
+ - [CloudmersiveNlpApiClient::PosSentence](docs/PosSentence.md)
136
+ - [CloudmersiveNlpApiClient::PosTaggedWord](docs/PosTaggedWord.md)
137
+ - [CloudmersiveNlpApiClient::ProfanityAnalysisRequest](docs/ProfanityAnalysisRequest.md)
138
+ - [CloudmersiveNlpApiClient::ProfanityAnalysisResponse](docs/ProfanityAnalysisResponse.md)
139
+ - [CloudmersiveNlpApiClient::RephraseRequest](docs/RephraseRequest.md)
140
+ - [CloudmersiveNlpApiClient::RephraseResponse](docs/RephraseResponse.md)
141
+ - [CloudmersiveNlpApiClient::RephrasedSentence](docs/RephrasedSentence.md)
142
+ - [CloudmersiveNlpApiClient::RephrasedSentenceOption](docs/RephrasedSentenceOption.md)
143
+ - [CloudmersiveNlpApiClient::SentenceSegmentationRequest](docs/SentenceSegmentationRequest.md)
144
+ - [CloudmersiveNlpApiClient::SentenceSegmentationResponse](docs/SentenceSegmentationResponse.md)
145
+ - [CloudmersiveNlpApiClient::SentimentAnalysisRequest](docs/SentimentAnalysisRequest.md)
146
+ - [CloudmersiveNlpApiClient::SentimentAnalysisResponse](docs/SentimentAnalysisResponse.md)
147
+ - [CloudmersiveNlpApiClient::SimilarityAnalysisRequest](docs/SimilarityAnalysisRequest.md)
148
+ - [CloudmersiveNlpApiClient::SimilarityAnalysisResponse](docs/SimilarityAnalysisResponse.md)
149
+ - [CloudmersiveNlpApiClient::SubjectivityAnalysisRequest](docs/SubjectivityAnalysisRequest.md)
150
+ - [CloudmersiveNlpApiClient::SubjectivityAnalysisResponse](docs/SubjectivityAnalysisResponse.md)
151
+ - [CloudmersiveNlpApiClient::WordPosition](docs/WordPosition.md)
152
+
153
+
154
+ ## Documentation for Authorization
155
+
156
+
157
+ ### Apikey
158
+
159
+ - **Type**: API key
160
+ - **API key parameter name**: Apikey
161
+ - **Location**: HTTP header
162
+
@@ -0,0 +1,8 @@
1
+ begin
2
+ require 'rspec/core/rake_task'
3
+
4
+ RSpec::Core::RakeTask.new(:spec)
5
+ task default: :spec
6
+ rescue LoadError
7
+ # no rspec available
8
+ end
@@ -0,0 +1,45 @@
1
+ # -*- encoding: utf-8 -*-
2
+
3
+ =begin
4
+ #nlpapiv2
5
+
6
+ #The powerful Natural Language Processing APIs (v2) let you perform part of speech tagging, entity identification, sentence parsing, and much more to help you understand the meaning of unstructured text.
7
+
8
+ OpenAPI spec version: v1
9
+
10
+ Generated by: https://github.com/swagger-api/swagger-codegen.git
11
+ Swagger Codegen version: 2.4.14
12
+
13
+ =end
14
+
15
+ $:.push File.expand_path("../lib", __FILE__)
16
+ require "cloudmersive-nlp-api-client/version"
17
+
18
+ Gem::Specification.new do |s|
19
+ s.name = "cloudmersive-nlp-api-client"
20
+ s.version = CloudmersiveNlpApiClient::VERSION
21
+ s.platform = Gem::Platform::RUBY
22
+ s.authors = ["Cloudmersive"]
23
+ s.email = [""]
24
+ s.homepage = "https://www.cloudmersive.com/nlp-api"
25
+ s.summary = "The most powerful and cost-effective NLP AI APIs, continuously updated."
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 = 'Apache 2.0'
28
+ s.required_ruby_version = ">= 1.9"
29
+
30
+ s.add_runtime_dependency 'typhoeus', '~> 1.0', '>= 1.0.1'
31
+ s.add_runtime_dependency 'json', '~> 2.1', '>= 2.1.0'
32
+
33
+ s.add_development_dependency 'rspec', '~> 3.6', '>= 3.6.0'
34
+ s.add_development_dependency 'vcr', '~> 3.0', '>= 3.0.1'
35
+ s.add_development_dependency 'webmock', '~> 1.24', '>= 1.24.3'
36
+ s.add_development_dependency 'autotest', '~> 4.4', '>= 4.4.6'
37
+ s.add_development_dependency 'autotest-rails-pure', '~> 4.1', '>= 4.1.2'
38
+ s.add_development_dependency 'autotest-growl', '~> 0.2', '>= 0.2.16'
39
+ s.add_development_dependency 'autotest-fsevent', '~> 0.2', '>= 0.2.12'
40
+
41
+ s.files = Dir['./**/*']
42
+ s.test_files = `find spec/*`.split("\n")
43
+ s.executables = []
44
+ s.require_paths = ["lib"]
45
+ end
@@ -0,0 +1,283 @@
1
+ # CloudmersiveNlpApiClient::AnalyticsApi
2
+
3
+ All URIs are relative to *https://api.cloudmersive.com*
4
+
5
+ Method | HTTP request | Description
6
+ ------------- | ------------- | -------------
7
+ [**analytics_hate_speech**](AnalyticsApi.md#analytics_hate_speech) | **POST** /nlp-v2/analytics/hate-speech | Perform Hate Speech Analysis and Detection on Text
8
+ [**analytics_profanity**](AnalyticsApi.md#analytics_profanity) | **POST** /nlp-v2/analytics/profanity | Perform Profanity and Obscene Language Analysis and Detection on Text
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
11
+ [**analytics_subjectivity**](AnalyticsApi.md#analytics_subjectivity) | **POST** /nlp-v2/analytics/subjectivity | Perform Subjectivity and Objectivity Analysis on Text
12
+
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
+
68
+ # **analytics_profanity**
69
+ > ProfanityAnalysisResponse analytics_profanity(input)
70
+
71
+ Perform Profanity and Obscene Language Analysis and Detection on Text
72
+
73
+ 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.
74
+
75
+ ### Example
76
+ ```ruby
77
+ # load the gem
78
+ require 'cloudmersive-nlp-api-client'
79
+ # setup authorization
80
+ CloudmersiveNlpApiClient.configure do |config|
81
+ # Configure API key authorization: Apikey
82
+ config.api_key['Apikey'] = 'YOUR API KEY'
83
+ # Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
84
+ #config.api_key_prefix['Apikey'] = 'Bearer'
85
+ end
86
+
87
+ api_instance = CloudmersiveNlpApiClient::AnalyticsApi.new
88
+
89
+ input = CloudmersiveNlpApiClient::ProfanityAnalysisRequest.new # ProfanityAnalysisRequest | Input profanity analysis request
90
+
91
+
92
+ begin
93
+ #Perform Profanity and Obscene Language Analysis and Detection on Text
94
+ result = api_instance.analytics_profanity(input)
95
+ p result
96
+ rescue CloudmersiveNlpApiClient::ApiError => e
97
+ puts "Exception when calling AnalyticsApi->analytics_profanity: #{e}"
98
+ end
99
+ ```
100
+
101
+ ### Parameters
102
+
103
+ Name | Type | Description | Notes
104
+ ------------- | ------------- | ------------- | -------------
105
+ **input** | [**ProfanityAnalysisRequest**](ProfanityAnalysisRequest.md)| Input profanity analysis request |
106
+
107
+ ### Return type
108
+
109
+ [**ProfanityAnalysisResponse**](ProfanityAnalysisResponse.md)
110
+
111
+ ### Authorization
112
+
113
+ [Apikey](../README.md#Apikey)
114
+
115
+ ### HTTP request headers
116
+
117
+ - **Content-Type**: application/json, text/json, application/xml, text/xml, application/x-www-form-urlencoded
118
+ - **Accept**: application/json
119
+
120
+
121
+
122
+ # **analytics_sentiment**
123
+ > SentimentAnalysisResponse analytics_sentiment(input)
124
+
125
+ Perform Sentiment Analysis and Classification on Text
126
+
127
+ 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.
128
+
129
+ ### Example
130
+ ```ruby
131
+ # load the gem
132
+ require 'cloudmersive-nlp-api-client'
133
+ # setup authorization
134
+ CloudmersiveNlpApiClient.configure do |config|
135
+ # Configure API key authorization: Apikey
136
+ config.api_key['Apikey'] = 'YOUR API KEY'
137
+ # Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
138
+ #config.api_key_prefix['Apikey'] = 'Bearer'
139
+ end
140
+
141
+ api_instance = CloudmersiveNlpApiClient::AnalyticsApi.new
142
+
143
+ input = CloudmersiveNlpApiClient::SentimentAnalysisRequest.new # SentimentAnalysisRequest | Input sentiment analysis request
144
+
145
+
146
+ begin
147
+ #Perform Sentiment Analysis and Classification on Text
148
+ result = api_instance.analytics_sentiment(input)
149
+ p result
150
+ rescue CloudmersiveNlpApiClient::ApiError => e
151
+ puts "Exception when calling AnalyticsApi->analytics_sentiment: #{e}"
152
+ end
153
+ ```
154
+
155
+ ### Parameters
156
+
157
+ Name | Type | Description | Notes
158
+ ------------- | ------------- | ------------- | -------------
159
+ **input** | [**SentimentAnalysisRequest**](SentimentAnalysisRequest.md)| Input sentiment analysis request |
160
+
161
+ ### Return type
162
+
163
+ [**SentimentAnalysisResponse**](SentimentAnalysisResponse.md)
164
+
165
+ ### Authorization
166
+
167
+ [Apikey](../README.md#Apikey)
168
+
169
+ ### HTTP request headers
170
+
171
+ - **Content-Type**: application/json, text/json, application/xml, text/xml, application/x-www-form-urlencoded
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
227
+
228
+
229
+
230
+ # **analytics_subjectivity**
231
+ > SubjectivityAnalysisResponse analytics_subjectivity(input)
232
+
233
+ Perform Subjectivity and Objectivity Analysis on Text
234
+
235
+ 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.
236
+
237
+ ### Example
238
+ ```ruby
239
+ # load the gem
240
+ require 'cloudmersive-nlp-api-client'
241
+ # setup authorization
242
+ CloudmersiveNlpApiClient.configure do |config|
243
+ # Configure API key authorization: Apikey
244
+ config.api_key['Apikey'] = 'YOUR API KEY'
245
+ # Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
246
+ #config.api_key_prefix['Apikey'] = 'Bearer'
247
+ end
248
+
249
+ api_instance = CloudmersiveNlpApiClient::AnalyticsApi.new
250
+
251
+ input = CloudmersiveNlpApiClient::SubjectivityAnalysisRequest.new # SubjectivityAnalysisRequest | Input subjectivity analysis request
252
+
253
+
254
+ begin
255
+ #Perform Subjectivity and Objectivity Analysis on Text
256
+ result = api_instance.analytics_subjectivity(input)
257
+ p result
258
+ rescue CloudmersiveNlpApiClient::ApiError => e
259
+ puts "Exception when calling AnalyticsApi->analytics_subjectivity: #{e}"
260
+ end
261
+ ```
262
+
263
+ ### Parameters
264
+
265
+ Name | Type | Description | Notes
266
+ ------------- | ------------- | ------------- | -------------
267
+ **input** | [**SubjectivityAnalysisRequest**](SubjectivityAnalysisRequest.md)| Input subjectivity analysis request |
268
+
269
+ ### Return type
270
+
271
+ [**SubjectivityAnalysisResponse**](SubjectivityAnalysisResponse.md)
272
+
273
+ ### Authorization
274
+
275
+ [Apikey](../README.md#Apikey)
276
+
277
+ ### HTTP request headers
278
+
279
+ - **Content-Type**: application/json, text/json, application/xml, text/xml, application/x-www-form-urlencoded
280
+ - **Accept**: application/json
281
+
282
+
283
+