cloudmersive-nlp-api-client 2.0.9 → 3.0.1

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. metadata +3 -154
  3. data/Gemfile +0 -7
  4. data/README.md +0 -160
  5. data/Rakefile +0 -8
  6. data/cloudmersive-nlp-api-client.gemspec +0 -45
  7. data/docs/AnalyticsApi.md +0 -283
  8. data/docs/CheckSentenceRequest.md +0 -8
  9. data/docs/CheckSentenceResponse.md +0 -9
  10. data/docs/CheckWordRequest.md +0 -8
  11. data/docs/CheckWordResponse.md +0 -9
  12. data/docs/CorrectWordInSentence.md +0 -10
  13. data/docs/Entity.md +0 -9
  14. data/docs/ExtractEntitiesApi.md +0 -63
  15. data/docs/ExtractEntitiesRequest.md +0 -8
  16. data/docs/ExtractEntitiesResponse.md +0 -9
  17. data/docs/GetWordsRequest.md +0 -8
  18. data/docs/GetWordsResponse.md +0 -8
  19. data/docs/HateSpeechAnalysisRequest.md +0 -8
  20. data/docs/HateSpeechAnalysisResponse.md +0 -10
  21. data/docs/LanguageDetectionApi.md +0 -63
  22. data/docs/LanguageDetectionRequest.md +0 -8
  23. data/docs/LanguageDetectionResponse.md +0 -10
  24. data/docs/LanguageTranslationApi.md +0 -228
  25. data/docs/LanguageTranslationRequest.md +0 -8
  26. data/docs/LanguageTranslationResponse.md +0 -10
  27. data/docs/ParseApi.md +0 -63
  28. data/docs/ParseRequest.md +0 -8
  29. data/docs/ParseResponse.md +0 -8
  30. data/docs/PosRequest.md +0 -8
  31. data/docs/PosResponse.md +0 -8
  32. data/docs/PosSentence.md +0 -8
  33. data/docs/PosTaggedWord.md +0 -9
  34. data/docs/PosTaggerApi.md +0 -338
  35. data/docs/ProfanityAnalysisRequest.md +0 -8
  36. data/docs/ProfanityAnalysisResponse.md +0 -10
  37. data/docs/RephraseApi.md +0 -63
  38. data/docs/RephraseRequest.md +0 -9
  39. data/docs/RephraseResponse.md +0 -10
  40. data/docs/RephrasedSentence.md +0 -10
  41. data/docs/RephrasedSentenceOption.md +0 -9
  42. data/docs/SegmentationApi.md +0 -118
  43. data/docs/SentenceSegmentationRequest.md +0 -8
  44. data/docs/SentenceSegmentationResponse.md +0 -10
  45. data/docs/SentimentAnalysisRequest.md +0 -8
  46. data/docs/SentimentAnalysisResponse.md +0 -11
  47. data/docs/SimilarityAnalysisRequest.md +0 -9
  48. data/docs/SimilarityAnalysisResponse.md +0 -10
  49. data/docs/SpellcheckApi.md +0 -118
  50. data/docs/SubjectivityAnalysisRequest.md +0 -8
  51. data/docs/SubjectivityAnalysisResponse.md +0 -10
  52. data/docs/WordPosition.md +0 -11
  53. data/git_push.sh +0 -55
  54. data/lib/cloudmersive-nlp-api-client.rb +0 -85
  55. data/lib/cloudmersive-nlp-api-client/api/analytics_api.rb +0 -298
  56. data/lib/cloudmersive-nlp-api-client/api/extract_entities_api.rb +0 -78
  57. data/lib/cloudmersive-nlp-api-client/api/language_detection_api.rb +0 -78
  58. data/lib/cloudmersive-nlp-api-client/api/language_translation_api.rb +0 -243
  59. data/lib/cloudmersive-nlp-api-client/api/parse_api.rb +0 -78
  60. data/lib/cloudmersive-nlp-api-client/api/pos_tagger_api.rb +0 -353
  61. data/lib/cloudmersive-nlp-api-client/api/rephrase_api.rb +0 -78
  62. data/lib/cloudmersive-nlp-api-client/api/segmentation_api.rb +0 -133
  63. data/lib/cloudmersive-nlp-api-client/api/spellcheck_api.rb +0 -133
  64. data/lib/cloudmersive-nlp-api-client/api_client.rb +0 -389
  65. data/lib/cloudmersive-nlp-api-client/api_error.rb +0 -38
  66. data/lib/cloudmersive-nlp-api-client/configuration.rb +0 -209
  67. data/lib/cloudmersive-nlp-api-client/models/check_sentence_request.rb +0 -189
  68. data/lib/cloudmersive-nlp-api-client/models/check_sentence_response.rb +0 -201
  69. data/lib/cloudmersive-nlp-api-client/models/check_word_request.rb +0 -188
  70. data/lib/cloudmersive-nlp-api-client/models/check_word_response.rb +0 -201
  71. data/lib/cloudmersive-nlp-api-client/models/correct_word_in_sentence.rb +0 -211
  72. data/lib/cloudmersive-nlp-api-client/models/entity.rb +0 -197
  73. data/lib/cloudmersive-nlp-api-client/models/extract_entities_request.rb +0 -189
  74. data/lib/cloudmersive-nlp-api-client/models/extract_entities_response.rb +0 -200
  75. data/lib/cloudmersive-nlp-api-client/models/get_words_request.rb +0 -188
  76. data/lib/cloudmersive-nlp-api-client/models/get_words_response.rb +0 -191
  77. data/lib/cloudmersive-nlp-api-client/models/hate_speech_analysis_request.rb +0 -189
  78. data/lib/cloudmersive-nlp-api-client/models/hate_speech_analysis_response.rb +0 -209
  79. data/lib/cloudmersive-nlp-api-client/models/language_detection_request.rb +0 -189
  80. data/lib/cloudmersive-nlp-api-client/models/language_detection_response.rb +0 -209
  81. data/lib/cloudmersive-nlp-api-client/models/language_translation_request.rb +0 -189
  82. data/lib/cloudmersive-nlp-api-client/models/language_translation_response.rb +0 -209
  83. data/lib/cloudmersive-nlp-api-client/models/parse_request.rb +0 -189
  84. data/lib/cloudmersive-nlp-api-client/models/parse_response.rb +0 -189
  85. data/lib/cloudmersive-nlp-api-client/models/pos_request.rb +0 -189
  86. data/lib/cloudmersive-nlp-api-client/models/pos_response.rb +0 -191
  87. data/lib/cloudmersive-nlp-api-client/models/pos_sentence.rb +0 -191
  88. data/lib/cloudmersive-nlp-api-client/models/pos_tagged_word.rb +0 -199
  89. data/lib/cloudmersive-nlp-api-client/models/profanity_analysis_request.rb +0 -189
  90. data/lib/cloudmersive-nlp-api-client/models/profanity_analysis_response.rb +0 -209
  91. data/lib/cloudmersive-nlp-api-client/models/rephrase_request.rb +0 -199
  92. data/lib/cloudmersive-nlp-api-client/models/rephrase_response.rb +0 -211
  93. data/lib/cloudmersive-nlp-api-client/models/rephrased_sentence.rb +0 -211
  94. data/lib/cloudmersive-nlp-api-client/models/rephrased_sentence_option.rb +0 -199
  95. data/lib/cloudmersive-nlp-api-client/models/sentence_segmentation_request.rb +0 -188
  96. data/lib/cloudmersive-nlp-api-client/models/sentence_segmentation_response.rb +0 -208
  97. data/lib/cloudmersive-nlp-api-client/models/sentiment_analysis_request.rb +0 -189
  98. data/lib/cloudmersive-nlp-api-client/models/sentiment_analysis_response.rb +0 -219
  99. data/lib/cloudmersive-nlp-api-client/models/similarity_analysis_request.rb +0 -199
  100. data/lib/cloudmersive-nlp-api-client/models/similarity_analysis_response.rb +0 -209
  101. data/lib/cloudmersive-nlp-api-client/models/subjectivity_analysis_request.rb +0 -189
  102. data/lib/cloudmersive-nlp-api-client/models/subjectivity_analysis_response.rb +0 -209
  103. data/lib/cloudmersive-nlp-api-client/models/word_position.rb +0 -219
  104. data/lib/cloudmersive-nlp-api-client/version.rb +0 -15
  105. data/spec/api/analytics_api_spec.rb +0 -95
  106. data/spec/api/extract_entities_api_spec.rb +0 -47
  107. data/spec/api/language_detection_api_spec.rb +0 -47
  108. data/spec/api/language_translation_api_spec.rb +0 -83
  109. data/spec/api/parse_api_spec.rb +0 -47
  110. data/spec/api/pos_tagger_api_spec.rb +0 -107
  111. data/spec/api/rephrase_api_spec.rb +0 -47
  112. data/spec/api/segmentation_api_spec.rb +0 -59
  113. data/spec/api/spellcheck_api_spec.rb +0 -59
  114. data/spec/api_client_spec.rb +0 -226
  115. data/spec/configuration_spec.rb +0 -42
  116. data/spec/models/check_sentence_request_spec.rb +0 -42
  117. data/spec/models/check_sentence_response_spec.rb +0 -48
  118. data/spec/models/check_word_request_spec.rb +0 -42
  119. data/spec/models/check_word_response_spec.rb +0 -48
  120. data/spec/models/correct_word_in_sentence_spec.rb +0 -54
  121. data/spec/models/entity_spec.rb +0 -48
  122. data/spec/models/extract_entities_request_spec.rb +0 -42
  123. data/spec/models/extract_entities_response_spec.rb +0 -48
  124. data/spec/models/get_words_request_spec.rb +0 -42
  125. data/spec/models/get_words_response_spec.rb +0 -42
  126. data/spec/models/hate_speech_analysis_request_spec.rb +0 -42
  127. data/spec/models/hate_speech_analysis_response_spec.rb +0 -54
  128. data/spec/models/language_detection_request_spec.rb +0 -42
  129. data/spec/models/language_detection_response_spec.rb +0 -54
  130. data/spec/models/language_translation_request_spec.rb +0 -42
  131. data/spec/models/language_translation_response_spec.rb +0 -54
  132. data/spec/models/parse_request_spec.rb +0 -42
  133. data/spec/models/parse_response_spec.rb +0 -42
  134. data/spec/models/pos_request_spec.rb +0 -42
  135. data/spec/models/pos_response_spec.rb +0 -42
  136. data/spec/models/pos_sentence_spec.rb +0 -42
  137. data/spec/models/pos_tagged_word_spec.rb +0 -48
  138. data/spec/models/profanity_analysis_request_spec.rb +0 -42
  139. data/spec/models/profanity_analysis_response_spec.rb +0 -54
  140. data/spec/models/rephrase_request_spec.rb +0 -48
  141. data/spec/models/rephrase_response_spec.rb +0 -54
  142. data/spec/models/rephrased_sentence_option_spec.rb +0 -48
  143. data/spec/models/rephrased_sentence_spec.rb +0 -54
  144. data/spec/models/sentence_segmentation_request_spec.rb +0 -42
  145. data/spec/models/sentence_segmentation_response_spec.rb +0 -54
  146. data/spec/models/sentiment_analysis_request_spec.rb +0 -42
  147. data/spec/models/sentiment_analysis_response_spec.rb +0 -60
  148. data/spec/models/similarity_analysis_request_spec.rb +0 -48
  149. data/spec/models/similarity_analysis_response_spec.rb +0 -54
  150. data/spec/models/subjectivity_analysis_request_spec.rb +0 -42
  151. data/spec/models/subjectivity_analysis_response_spec.rb +0 -54
  152. data/spec/models/word_position_spec.rb +0 -60
  153. data/spec/spec_helper.rb +0 -111
@@ -1,353 +0,0 @@
1
- =begin
2
- #nlpapiv2
3
-
4
- #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.
5
-
6
- OpenAPI spec version: v1
7
-
8
- Generated by: https://github.com/swagger-api/swagger-codegen.git
9
- Swagger Codegen version: 2.3.1
10
-
11
- =end
12
-
13
- require "uri"
14
-
15
- module CloudmersiveNlpApiClient
16
- class PosTaggerApi
17
- attr_accessor :api_client
18
-
19
- def initialize(api_client = ApiClient.default)
20
- @api_client = api_client
21
- end
22
-
23
- # Part-of-speech tag a string, filter to adjectives
24
- # Part-of-speech (POS) tag a string, find the adjectives, and return result as JSON
25
- # @param request Input string
26
- # @param [Hash] opts the optional parameters
27
- # @return [PosResponse]
28
- def pos_tagger_tag_adjectives(request, opts = {})
29
- data, _status_code, _headers = pos_tagger_tag_adjectives_with_http_info(request, opts)
30
- return data
31
- end
32
-
33
- # Part-of-speech tag a string, filter to adjectives
34
- # Part-of-speech (POS) tag a string, find the adjectives, and return result as JSON
35
- # @param request Input string
36
- # @param [Hash] opts the optional parameters
37
- # @return [Array<(PosResponse, Fixnum, Hash)>] PosResponse data, response status code and response headers
38
- def pos_tagger_tag_adjectives_with_http_info(request, opts = {})
39
- if @api_client.config.debugging
40
- @api_client.config.logger.debug "Calling API: PosTaggerApi.pos_tagger_tag_adjectives ..."
41
- end
42
- # verify the required parameter 'request' is set
43
- if @api_client.config.client_side_validation && request.nil?
44
- fail ArgumentError, "Missing the required parameter 'request' when calling PosTaggerApi.pos_tagger_tag_adjectives"
45
- end
46
- # resource path
47
- local_var_path = "/nlp-v2/pos/tag/adjectives"
48
-
49
- # query parameters
50
- query_params = {}
51
-
52
- # header parameters
53
- header_params = {}
54
- # HTTP header 'Accept' (if needed)
55
- header_params['Accept'] = @api_client.select_header_accept(['application/json'])
56
- # HTTP header 'Content-Type'
57
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json', 'text/json', 'application/xml', 'text/xml', 'application/x-www-form-urlencoded'])
58
-
59
- # form parameters
60
- form_params = {}
61
-
62
- # http body (model)
63
- post_body = @api_client.object_to_http_body(request)
64
- auth_names = ['Apikey']
65
- data, status_code, headers = @api_client.call_api(:POST, local_var_path,
66
- :header_params => header_params,
67
- :query_params => query_params,
68
- :form_params => form_params,
69
- :body => post_body,
70
- :auth_names => auth_names,
71
- :return_type => 'PosResponse')
72
- if @api_client.config.debugging
73
- @api_client.config.logger.debug "API called: PosTaggerApi#pos_tagger_tag_adjectives\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
74
- end
75
- return data, status_code, headers
76
- end
77
-
78
- # Part-of-speech tag a string, filter to adverbs
79
- # Part-of-speech (POS) tag a string, find the adverbs, and return result as JSON
80
- # @param request Input string
81
- # @param [Hash] opts the optional parameters
82
- # @return [PosResponse]
83
- def pos_tagger_tag_adverbs(request, opts = {})
84
- data, _status_code, _headers = pos_tagger_tag_adverbs_with_http_info(request, opts)
85
- return data
86
- end
87
-
88
- # Part-of-speech tag a string, filter to adverbs
89
- # Part-of-speech (POS) tag a string, find the adverbs, and return result as JSON
90
- # @param request Input string
91
- # @param [Hash] opts the optional parameters
92
- # @return [Array<(PosResponse, Fixnum, Hash)>] PosResponse data, response status code and response headers
93
- def pos_tagger_tag_adverbs_with_http_info(request, opts = {})
94
- if @api_client.config.debugging
95
- @api_client.config.logger.debug "Calling API: PosTaggerApi.pos_tagger_tag_adverbs ..."
96
- end
97
- # verify the required parameter 'request' is set
98
- if @api_client.config.client_side_validation && request.nil?
99
- fail ArgumentError, "Missing the required parameter 'request' when calling PosTaggerApi.pos_tagger_tag_adverbs"
100
- end
101
- # resource path
102
- local_var_path = "/nlp-v2/pos/tag/adverbs"
103
-
104
- # query parameters
105
- query_params = {}
106
-
107
- # header parameters
108
- header_params = {}
109
- # HTTP header 'Accept' (if needed)
110
- header_params['Accept'] = @api_client.select_header_accept(['application/json'])
111
- # HTTP header 'Content-Type'
112
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json', 'text/json', 'application/xml', 'text/xml', 'application/x-www-form-urlencoded'])
113
-
114
- # form parameters
115
- form_params = {}
116
-
117
- # http body (model)
118
- post_body = @api_client.object_to_http_body(request)
119
- auth_names = ['Apikey']
120
- data, status_code, headers = @api_client.call_api(:POST, local_var_path,
121
- :header_params => header_params,
122
- :query_params => query_params,
123
- :form_params => form_params,
124
- :body => post_body,
125
- :auth_names => auth_names,
126
- :return_type => 'PosResponse')
127
- if @api_client.config.debugging
128
- @api_client.config.logger.debug "API called: PosTaggerApi#pos_tagger_tag_adverbs\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
129
- end
130
- return data, status_code, headers
131
- end
132
-
133
- # Part-of-speech tag a string, filter to nouns
134
- # Part-of-speech (POS) tag a string, find the nouns, and return result as JSON
135
- # @param request Input string
136
- # @param [Hash] opts the optional parameters
137
- # @return [PosResponse]
138
- def pos_tagger_tag_nouns(request, opts = {})
139
- data, _status_code, _headers = pos_tagger_tag_nouns_with_http_info(request, opts)
140
- return data
141
- end
142
-
143
- # Part-of-speech tag a string, filter to nouns
144
- # Part-of-speech (POS) tag a string, find the nouns, and return result as JSON
145
- # @param request Input string
146
- # @param [Hash] opts the optional parameters
147
- # @return [Array<(PosResponse, Fixnum, Hash)>] PosResponse data, response status code and response headers
148
- def pos_tagger_tag_nouns_with_http_info(request, opts = {})
149
- if @api_client.config.debugging
150
- @api_client.config.logger.debug "Calling API: PosTaggerApi.pos_tagger_tag_nouns ..."
151
- end
152
- # verify the required parameter 'request' is set
153
- if @api_client.config.client_side_validation && request.nil?
154
- fail ArgumentError, "Missing the required parameter 'request' when calling PosTaggerApi.pos_tagger_tag_nouns"
155
- end
156
- # resource path
157
- local_var_path = "/nlp-v2/pos/tag/nouns"
158
-
159
- # query parameters
160
- query_params = {}
161
-
162
- # header parameters
163
- header_params = {}
164
- # HTTP header 'Accept' (if needed)
165
- header_params['Accept'] = @api_client.select_header_accept(['application/json'])
166
- # HTTP header 'Content-Type'
167
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json', 'text/json', 'application/xml', 'text/xml', 'application/x-www-form-urlencoded'])
168
-
169
- # form parameters
170
- form_params = {}
171
-
172
- # http body (model)
173
- post_body = @api_client.object_to_http_body(request)
174
- auth_names = ['Apikey']
175
- data, status_code, headers = @api_client.call_api(:POST, local_var_path,
176
- :header_params => header_params,
177
- :query_params => query_params,
178
- :form_params => form_params,
179
- :body => post_body,
180
- :auth_names => auth_names,
181
- :return_type => 'PosResponse')
182
- if @api_client.config.debugging
183
- @api_client.config.logger.debug "API called: PosTaggerApi#pos_tagger_tag_nouns\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
184
- end
185
- return data, status_code, headers
186
- end
187
-
188
- # Part-of-speech tag a string, filter to pronouns
189
- # Part-of-speech (POS) tag a string, find the pronouns, and return result as JSON
190
- # @param request Input string
191
- # @param [Hash] opts the optional parameters
192
- # @return [PosResponse]
193
- def pos_tagger_tag_pronouns(request, opts = {})
194
- data, _status_code, _headers = pos_tagger_tag_pronouns_with_http_info(request, opts)
195
- return data
196
- end
197
-
198
- # Part-of-speech tag a string, filter to pronouns
199
- # Part-of-speech (POS) tag a string, find the pronouns, and return result as JSON
200
- # @param request Input string
201
- # @param [Hash] opts the optional parameters
202
- # @return [Array<(PosResponse, Fixnum, Hash)>] PosResponse data, response status code and response headers
203
- def pos_tagger_tag_pronouns_with_http_info(request, opts = {})
204
- if @api_client.config.debugging
205
- @api_client.config.logger.debug "Calling API: PosTaggerApi.pos_tagger_tag_pronouns ..."
206
- end
207
- # verify the required parameter 'request' is set
208
- if @api_client.config.client_side_validation && request.nil?
209
- fail ArgumentError, "Missing the required parameter 'request' when calling PosTaggerApi.pos_tagger_tag_pronouns"
210
- end
211
- # resource path
212
- local_var_path = "/nlp-v2/pos/tag/pronouns"
213
-
214
- # query parameters
215
- query_params = {}
216
-
217
- # header parameters
218
- header_params = {}
219
- # HTTP header 'Accept' (if needed)
220
- header_params['Accept'] = @api_client.select_header_accept(['application/json'])
221
- # HTTP header 'Content-Type'
222
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json', 'text/json', 'application/xml', 'text/xml', 'application/x-www-form-urlencoded'])
223
-
224
- # form parameters
225
- form_params = {}
226
-
227
- # http body (model)
228
- post_body = @api_client.object_to_http_body(request)
229
- auth_names = ['Apikey']
230
- data, status_code, headers = @api_client.call_api(:POST, local_var_path,
231
- :header_params => header_params,
232
- :query_params => query_params,
233
- :form_params => form_params,
234
- :body => post_body,
235
- :auth_names => auth_names,
236
- :return_type => 'PosResponse')
237
- if @api_client.config.debugging
238
- @api_client.config.logger.debug "API called: PosTaggerApi#pos_tagger_tag_pronouns\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
239
- end
240
- return data, status_code, headers
241
- end
242
-
243
- # Part-of-speech tag a string
244
- # Part-of-speech (POS) tag a string and return result as JSON
245
- # @param request Input string
246
- # @param [Hash] opts the optional parameters
247
- # @return [PosResponse]
248
- def pos_tagger_tag_sentence(request, opts = {})
249
- data, _status_code, _headers = pos_tagger_tag_sentence_with_http_info(request, opts)
250
- return data
251
- end
252
-
253
- # Part-of-speech tag a string
254
- # Part-of-speech (POS) tag a string and return result as JSON
255
- # @param request Input string
256
- # @param [Hash] opts the optional parameters
257
- # @return [Array<(PosResponse, Fixnum, Hash)>] PosResponse data, response status code and response headers
258
- def pos_tagger_tag_sentence_with_http_info(request, opts = {})
259
- if @api_client.config.debugging
260
- @api_client.config.logger.debug "Calling API: PosTaggerApi.pos_tagger_tag_sentence ..."
261
- end
262
- # verify the required parameter 'request' is set
263
- if @api_client.config.client_side_validation && request.nil?
264
- fail ArgumentError, "Missing the required parameter 'request' when calling PosTaggerApi.pos_tagger_tag_sentence"
265
- end
266
- # resource path
267
- local_var_path = "/nlp-v2/pos/tag/sentence"
268
-
269
- # query parameters
270
- query_params = {}
271
-
272
- # header parameters
273
- header_params = {}
274
- # HTTP header 'Accept' (if needed)
275
- header_params['Accept'] = @api_client.select_header_accept(['application/json'])
276
- # HTTP header 'Content-Type'
277
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json', 'text/json', 'application/xml', 'text/xml', 'application/x-www-form-urlencoded'])
278
-
279
- # form parameters
280
- form_params = {}
281
-
282
- # http body (model)
283
- post_body = @api_client.object_to_http_body(request)
284
- auth_names = ['Apikey']
285
- data, status_code, headers = @api_client.call_api(:POST, local_var_path,
286
- :header_params => header_params,
287
- :query_params => query_params,
288
- :form_params => form_params,
289
- :body => post_body,
290
- :auth_names => auth_names,
291
- :return_type => 'PosResponse')
292
- if @api_client.config.debugging
293
- @api_client.config.logger.debug "API called: PosTaggerApi#pos_tagger_tag_sentence\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
294
- end
295
- return data, status_code, headers
296
- end
297
-
298
- # Part-of-speech tag a string, filter to verbs
299
- # Part-of-speech (POS) tag a string, find the verbs, and return result as JSON
300
- # @param request Input string
301
- # @param [Hash] opts the optional parameters
302
- # @return [PosResponse]
303
- def pos_tagger_tag_verbs(request, opts = {})
304
- data, _status_code, _headers = pos_tagger_tag_verbs_with_http_info(request, opts)
305
- return data
306
- end
307
-
308
- # Part-of-speech tag a string, filter to verbs
309
- # Part-of-speech (POS) tag a string, find the verbs, and return result as JSON
310
- # @param request Input string
311
- # @param [Hash] opts the optional parameters
312
- # @return [Array<(PosResponse, Fixnum, Hash)>] PosResponse data, response status code and response headers
313
- def pos_tagger_tag_verbs_with_http_info(request, opts = {})
314
- if @api_client.config.debugging
315
- @api_client.config.logger.debug "Calling API: PosTaggerApi.pos_tagger_tag_verbs ..."
316
- end
317
- # verify the required parameter 'request' is set
318
- if @api_client.config.client_side_validation && request.nil?
319
- fail ArgumentError, "Missing the required parameter 'request' when calling PosTaggerApi.pos_tagger_tag_verbs"
320
- end
321
- # resource path
322
- local_var_path = "/nlp-v2/pos/tag/verbs"
323
-
324
- # query parameters
325
- query_params = {}
326
-
327
- # header parameters
328
- header_params = {}
329
- # HTTP header 'Accept' (if needed)
330
- header_params['Accept'] = @api_client.select_header_accept(['application/json'])
331
- # HTTP header 'Content-Type'
332
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json', 'text/json', 'application/xml', 'text/xml', 'application/x-www-form-urlencoded'])
333
-
334
- # form parameters
335
- form_params = {}
336
-
337
- # http body (model)
338
- post_body = @api_client.object_to_http_body(request)
339
- auth_names = ['Apikey']
340
- data, status_code, headers = @api_client.call_api(:POST, local_var_path,
341
- :header_params => header_params,
342
- :query_params => query_params,
343
- :form_params => form_params,
344
- :body => post_body,
345
- :auth_names => auth_names,
346
- :return_type => 'PosResponse')
347
- if @api_client.config.debugging
348
- @api_client.config.logger.debug "API called: PosTaggerApi#pos_tagger_tag_verbs\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
349
- end
350
- return data, status_code, headers
351
- end
352
- end
353
- end
@@ -1,78 +0,0 @@
1
- =begin
2
- #nlpapiv2
3
-
4
- #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.
5
-
6
- OpenAPI spec version: v1
7
-
8
- Generated by: https://github.com/swagger-api/swagger-codegen.git
9
- Swagger Codegen version: 2.3.1
10
-
11
- =end
12
-
13
- require "uri"
14
-
15
- module CloudmersiveNlpApiClient
16
- class RephraseApi
17
- attr_accessor :api_client
18
-
19
- def initialize(api_client = ApiClient.default)
20
- @api_client = api_client
21
- end
22
-
23
- # Rephrase, paraphrase English text sentence-by-sentence using Deep Learning AI
24
- # Automatically rephrases or paraphrases input text in English sentence by sentence using advanced Deep Learning and Neural NLP. Creates multiple reprhasing candidates per input sentence, from 1 to 10 possible rephrasings of the original sentence. Seeks to preserve original semantic meaning in rephrased output candidates. Consumes 1-2 API calls per output rephrasing option generated, per sentence.
25
- # @param input Input rephrase request
26
- # @param [Hash] opts the optional parameters
27
- # @return [RephraseResponse]
28
- def rephrase_english_rephrase_sentence_by_sentence(input, opts = {})
29
- data, _status_code, _headers = rephrase_english_rephrase_sentence_by_sentence_with_http_info(input, opts)
30
- return data
31
- end
32
-
33
- # Rephrase, paraphrase English text sentence-by-sentence using Deep Learning AI
34
- # Automatically rephrases or paraphrases input text in English sentence by sentence using advanced Deep Learning and Neural NLP. Creates multiple reprhasing candidates per input sentence, from 1 to 10 possible rephrasings of the original sentence. Seeks to preserve original semantic meaning in rephrased output candidates. Consumes 1-2 API calls per output rephrasing option generated, per sentence.
35
- # @param input Input rephrase request
36
- # @param [Hash] opts the optional parameters
37
- # @return [Array<(RephraseResponse, Fixnum, Hash)>] RephraseResponse data, response status code and response headers
38
- def rephrase_english_rephrase_sentence_by_sentence_with_http_info(input, opts = {})
39
- if @api_client.config.debugging
40
- @api_client.config.logger.debug "Calling API: RephraseApi.rephrase_english_rephrase_sentence_by_sentence ..."
41
- end
42
- # verify the required parameter 'input' is set
43
- if @api_client.config.client_side_validation && input.nil?
44
- fail ArgumentError, "Missing the required parameter 'input' when calling RephraseApi.rephrase_english_rephrase_sentence_by_sentence"
45
- end
46
- # resource path
47
- local_var_path = "/nlp-v2/rephrase/rephrase/eng/by-sentence"
48
-
49
- # query parameters
50
- query_params = {}
51
-
52
- # header parameters
53
- header_params = {}
54
- # HTTP header 'Accept' (if needed)
55
- header_params['Accept'] = @api_client.select_header_accept(['application/json'])
56
- # HTTP header 'Content-Type'
57
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json', 'text/json', 'application/xml', 'text/xml', 'application/x-www-form-urlencoded'])
58
-
59
- # form parameters
60
- form_params = {}
61
-
62
- # http body (model)
63
- post_body = @api_client.object_to_http_body(input)
64
- auth_names = ['Apikey']
65
- data, status_code, headers = @api_client.call_api(:POST, local_var_path,
66
- :header_params => header_params,
67
- :query_params => query_params,
68
- :form_params => form_params,
69
- :body => post_body,
70
- :auth_names => auth_names,
71
- :return_type => 'RephraseResponse')
72
- if @api_client.config.debugging
73
- @api_client.config.logger.debug "API called: RephraseApi#rephrase_english_rephrase_sentence_by_sentence\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
74
- end
75
- return data, status_code, headers
76
- end
77
- end
78
- end
@@ -1,133 +0,0 @@
1
- =begin
2
- #nlpapiv2
3
-
4
- #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.
5
-
6
- OpenAPI spec version: v1
7
-
8
- Generated by: https://github.com/swagger-api/swagger-codegen.git
9
- Swagger Codegen version: 2.3.1
10
-
11
- =end
12
-
13
- require "uri"
14
-
15
- module CloudmersiveNlpApiClient
16
- class SegmentationApi
17
- attr_accessor :api_client
18
-
19
- def initialize(api_client = ApiClient.default)
20
- @api_client = api_client
21
- end
22
-
23
- # Extract sentences from string
24
- # Segment an input string into separate sentences, output result as a string.
25
- # @param input Input string
26
- # @param [Hash] opts the optional parameters
27
- # @return [SentenceSegmentationResponse]
28
- def segmentation_get_sentences(input, opts = {})
29
- data, _status_code, _headers = segmentation_get_sentences_with_http_info(input, opts)
30
- return data
31
- end
32
-
33
- # Extract sentences from string
34
- # Segment an input string into separate sentences, output result as a string.
35
- # @param input Input string
36
- # @param [Hash] opts the optional parameters
37
- # @return [Array<(SentenceSegmentationResponse, Fixnum, Hash)>] SentenceSegmentationResponse data, response status code and response headers
38
- def segmentation_get_sentences_with_http_info(input, opts = {})
39
- if @api_client.config.debugging
40
- @api_client.config.logger.debug "Calling API: SegmentationApi.segmentation_get_sentences ..."
41
- end
42
- # verify the required parameter 'input' is set
43
- if @api_client.config.client_side_validation && input.nil?
44
- fail ArgumentError, "Missing the required parameter 'input' when calling SegmentationApi.segmentation_get_sentences"
45
- end
46
- # resource path
47
- local_var_path = "/nlp-v2/segmentation/sentences"
48
-
49
- # query parameters
50
- query_params = {}
51
-
52
- # header parameters
53
- header_params = {}
54
- # HTTP header 'Accept' (if needed)
55
- header_params['Accept'] = @api_client.select_header_accept(['application/json'])
56
- # HTTP header 'Content-Type'
57
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json', 'text/json', 'application/xml', 'text/xml', 'application/x-www-form-urlencoded'])
58
-
59
- # form parameters
60
- form_params = {}
61
-
62
- # http body (model)
63
- post_body = @api_client.object_to_http_body(input)
64
- auth_names = ['Apikey']
65
- data, status_code, headers = @api_client.call_api(:POST, local_var_path,
66
- :header_params => header_params,
67
- :query_params => query_params,
68
- :form_params => form_params,
69
- :body => post_body,
70
- :auth_names => auth_names,
71
- :return_type => 'SentenceSegmentationResponse')
72
- if @api_client.config.debugging
73
- @api_client.config.logger.debug "API called: SegmentationApi#segmentation_get_sentences\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
74
- end
75
- return data, status_code, headers
76
- end
77
-
78
- # Get words in input string
79
- # Get the component words in an input string
80
- # @param input String to process
81
- # @param [Hash] opts the optional parameters
82
- # @return [GetWordsResponse]
83
- def segmentation_get_words(input, opts = {})
84
- data, _status_code, _headers = segmentation_get_words_with_http_info(input, opts)
85
- return data
86
- end
87
-
88
- # Get words in input string
89
- # Get the component words in an input string
90
- # @param input String to process
91
- # @param [Hash] opts the optional parameters
92
- # @return [Array<(GetWordsResponse, Fixnum, Hash)>] GetWordsResponse data, response status code and response headers
93
- def segmentation_get_words_with_http_info(input, opts = {})
94
- if @api_client.config.debugging
95
- @api_client.config.logger.debug "Calling API: SegmentationApi.segmentation_get_words ..."
96
- end
97
- # verify the required parameter 'input' is set
98
- if @api_client.config.client_side_validation && input.nil?
99
- fail ArgumentError, "Missing the required parameter 'input' when calling SegmentationApi.segmentation_get_words"
100
- end
101
- # resource path
102
- local_var_path = "/nlp-v2/segmentation/words"
103
-
104
- # query parameters
105
- query_params = {}
106
-
107
- # header parameters
108
- header_params = {}
109
- # HTTP header 'Accept' (if needed)
110
- header_params['Accept'] = @api_client.select_header_accept(['application/json'])
111
- # HTTP header 'Content-Type'
112
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json', 'text/json', 'application/xml', 'text/xml', 'application/x-www-form-urlencoded'])
113
-
114
- # form parameters
115
- form_params = {}
116
-
117
- # http body (model)
118
- post_body = @api_client.object_to_http_body(input)
119
- auth_names = ['Apikey']
120
- data, status_code, headers = @api_client.call_api(:POST, local_var_path,
121
- :header_params => header_params,
122
- :query_params => query_params,
123
- :form_params => form_params,
124
- :body => post_body,
125
- :auth_names => auth_names,
126
- :return_type => 'GetWordsResponse')
127
- if @api_client.config.debugging
128
- @api_client.config.logger.debug "API called: SegmentationApi#segmentation_get_words\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
129
- end
130
- return data, status_code, headers
131
- end
132
- end
133
- end