opener-chained-daemon 3.3.3 → 3.3.8
Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 226ff6ff3b95a801ca07c758a8588a0cf32f97f7c9238c9e0c26cfdc1c56dee9
|
4
|
+
data.tar.gz: bb7f9d673851ea5c06eba8419202331b7f6f0dbf2dd87311e68147faf73a898f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 6bb51d8f256fc0a2d4146d00f4290389ff30c8bb0ab75a0ab19acc74fd3360fda2c32f08058844ed4dcf84e430161d5394366b56c78c40343ed30cd2e819ce3a
|
7
|
+
data.tar.gz: 70af48950ae3906b4a8560fc6d826b595c9118fb488304e7479a434e81261d0f5f808a0ba367d243f5cf2f6b7785c642126a6c7c832846eebf039142d865b1f9
|
@@ -24,22 +24,12 @@ module Opener
|
|
24
24
|
def cache_update
|
25
25
|
puts "loading supported languages from url #{@url}" if ENV['DEBUG']
|
26
26
|
|
27
|
-
languages = SymMash.new JSON.parse http.get(@url).body
|
27
|
+
languages = SymMash.new JSON.parse ChainedDaemon.http.get(@url).body
|
28
28
|
@last_updated = Time.now
|
29
29
|
@cache = languages.data.each.with_object({}){ |l,h| h[l.code] = l }
|
30
30
|
@cache
|
31
31
|
end
|
32
32
|
|
33
|
-
def http
|
34
|
-
return @http if @http
|
35
|
-
|
36
|
-
@http = HTTPClient.new
|
37
|
-
@http.send_timeout = 120
|
38
|
-
@http.receive_timeout = 120
|
39
|
-
@http.connect_timeout = 120
|
40
|
-
@http
|
41
|
-
end
|
42
|
-
|
43
33
|
end
|
44
34
|
end
|
45
35
|
end
|
@@ -41,13 +41,16 @@ module Opener
|
|
41
41
|
kaf = KAF::Document.from_xml input
|
42
42
|
lang = LANGUAGES_CACHE.get[kaf.language]
|
43
43
|
env = params.cache_keys.environment
|
44
|
-
unless lang&.environments&.include? env or (
|
44
|
+
unless lang&.environments&.include? env or (params.cache_keys.merged and lang&.environments&.include? 'production')
|
45
|
+
raise Core::UnsupportedLanguageError.new kaf.language
|
46
|
+
end
|
47
|
+
if env == 'production' and !lang.supported_by_opener
|
45
48
|
raise Core::UnsupportedLanguageError.new kaf.language
|
46
49
|
end
|
47
50
|
|
48
51
|
input = kaf.raw
|
49
52
|
input = input.gsub(/\,[^\ ]/, ', ')
|
50
|
-
response =
|
53
|
+
response = ChainedDaemon.http.post BASE_URL, {lang: kaf.language, input: input}.to_query
|
51
54
|
raise Core::UnsupportedLanguageError, kaf.language if response.status == 406
|
52
55
|
raise response.body if response.status >= 400
|
53
56
|
sentences = JSON.parse response.body
|
@@ -28,15 +28,12 @@ Gem::Specification.new do |spec|
|
|
28
28
|
|
29
29
|
spec.add_dependency 'roda'
|
30
30
|
spec.add_dependency 'rack-timeout'
|
31
|
-
spec.add_dependency 'faraday'
|
32
31
|
spec.add_dependency 'opener-daemons', '~> 2.7.2'
|
33
32
|
spec.add_dependency 'opener-callback-handler', '~> 1.0'
|
34
33
|
|
35
34
|
spec.add_dependency 'opener-language-identifier', '>= 4.4.0'
|
36
|
-
spec.add_dependency 'opener-
|
37
|
-
spec.add_dependency 'opener-
|
38
|
-
spec.add_dependency 'opener-property-tagger', '>= 3.4.0'
|
39
|
-
spec.add_dependency 'opener-polarity-tagger', '>= 3.4.0'
|
35
|
+
spec.add_dependency 'opener-property-tagger', '>= 3.4.1'
|
36
|
+
spec.add_dependency 'opener-polarity-tagger', '>= 3.5.1'
|
40
37
|
spec.add_dependency 'opener-opinion-detector-basic', '>= 3.2.3'
|
41
38
|
|
42
39
|
spec.add_development_dependency 'bundler', '~> 1.3'
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: opener-chained-daemon
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 3.3.
|
4
|
+
version: 3.3.8
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- development@olery.com
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2021-02-
|
11
|
+
date: 2021-02-26 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activesupport
|
@@ -94,20 +94,6 @@ dependencies:
|
|
94
94
|
- - ">="
|
95
95
|
- !ruby/object:Gem::Version
|
96
96
|
version: '0'
|
97
|
-
- !ruby/object:Gem::Dependency
|
98
|
-
name: faraday
|
99
|
-
requirement: !ruby/object:Gem::Requirement
|
100
|
-
requirements:
|
101
|
-
- - ">="
|
102
|
-
- !ruby/object:Gem::Version
|
103
|
-
version: '0'
|
104
|
-
type: :runtime
|
105
|
-
prerelease: false
|
106
|
-
version_requirements: !ruby/object:Gem::Requirement
|
107
|
-
requirements:
|
108
|
-
- - ">="
|
109
|
-
- !ruby/object:Gem::Version
|
110
|
-
version: '0'
|
111
97
|
- !ruby/object:Gem::Dependency
|
112
98
|
name: opener-daemons
|
113
99
|
requirement: !ruby/object:Gem::Requirement
|
@@ -150,62 +136,34 @@ dependencies:
|
|
150
136
|
- - ">="
|
151
137
|
- !ruby/object:Gem::Version
|
152
138
|
version: 4.4.0
|
153
|
-
- !ruby/object:Gem::Dependency
|
154
|
-
name: opener-tokenizer
|
155
|
-
requirement: !ruby/object:Gem::Requirement
|
156
|
-
requirements:
|
157
|
-
- - ">="
|
158
|
-
- !ruby/object:Gem::Version
|
159
|
-
version: 2.2.0
|
160
|
-
type: :runtime
|
161
|
-
prerelease: false
|
162
|
-
version_requirements: !ruby/object:Gem::Requirement
|
163
|
-
requirements:
|
164
|
-
- - ">="
|
165
|
-
- !ruby/object:Gem::Version
|
166
|
-
version: 2.2.0
|
167
|
-
- !ruby/object:Gem::Dependency
|
168
|
-
name: opener-pos-tagger
|
169
|
-
requirement: !ruby/object:Gem::Requirement
|
170
|
-
requirements:
|
171
|
-
- - ">="
|
172
|
-
- !ruby/object:Gem::Version
|
173
|
-
version: 3.2.0
|
174
|
-
type: :runtime
|
175
|
-
prerelease: false
|
176
|
-
version_requirements: !ruby/object:Gem::Requirement
|
177
|
-
requirements:
|
178
|
-
- - ">="
|
179
|
-
- !ruby/object:Gem::Version
|
180
|
-
version: 3.2.0
|
181
139
|
- !ruby/object:Gem::Dependency
|
182
140
|
name: opener-property-tagger
|
183
141
|
requirement: !ruby/object:Gem::Requirement
|
184
142
|
requirements:
|
185
143
|
- - ">="
|
186
144
|
- !ruby/object:Gem::Version
|
187
|
-
version: 3.4.
|
145
|
+
version: 3.4.1
|
188
146
|
type: :runtime
|
189
147
|
prerelease: false
|
190
148
|
version_requirements: !ruby/object:Gem::Requirement
|
191
149
|
requirements:
|
192
150
|
- - ">="
|
193
151
|
- !ruby/object:Gem::Version
|
194
|
-
version: 3.4.
|
152
|
+
version: 3.4.1
|
195
153
|
- !ruby/object:Gem::Dependency
|
196
154
|
name: opener-polarity-tagger
|
197
155
|
requirement: !ruby/object:Gem::Requirement
|
198
156
|
requirements:
|
199
157
|
- - ">="
|
200
158
|
- !ruby/object:Gem::Version
|
201
|
-
version: 3.
|
159
|
+
version: 3.5.1
|
202
160
|
type: :runtime
|
203
161
|
prerelease: false
|
204
162
|
version_requirements: !ruby/object:Gem::Requirement
|
205
163
|
requirements:
|
206
164
|
- - ">="
|
207
165
|
- !ruby/object:Gem::Version
|
208
|
-
version: 3.
|
166
|
+
version: 3.5.1
|
209
167
|
- !ruby/object:Gem::Dependency
|
210
168
|
name: opener-opinion-detector-basic
|
211
169
|
requirement: !ruby/object:Gem::Requirement
|
@@ -307,10 +265,10 @@ dependencies:
|
|
307
265
|
description: OpeNER daemon for processing multiple queues at once
|
308
266
|
email:
|
309
267
|
executables:
|
310
|
-
- chained-daemon
|
268
|
+
- chained-daemon
|
311
269
|
- chained-daemon-csv
|
312
270
|
- console
|
313
|
-
- chained-daemon
|
271
|
+
- chained-daemon-daemon
|
314
272
|
extensions: []
|
315
273
|
extra_rdoc_files: []
|
316
274
|
files:
|
@@ -353,7 +311,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
353
311
|
version: '0'
|
354
312
|
requirements: []
|
355
313
|
rubyforge_project:
|
356
|
-
rubygems_version: 2.7.
|
314
|
+
rubygems_version: 2.7.8
|
357
315
|
signing_key:
|
358
316
|
specification_version: 4
|
359
317
|
summary: OpeNER daemon for processing multiple queues at once
|