RecastAI 3.1.0 → 3.1.1

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
  SHA1:
3
- metadata.gz: 815462dab5fa1be22867b8da2f81cbc2e5273edd
4
- data.tar.gz: 990e593aa2e0ea07362f2af79b8453f7a3cd9641
3
+ metadata.gz: 9d475981de2a40b76f29ad3a39288de12feb3627
4
+ data.tar.gz: 359336db88d9408b7e3e2bab2af39f2ca2bc7884
5
5
  SHA512:
6
- metadata.gz: b74a8724a020b0477349acbae7e283f7c30408bd4b4594fd2b35ecbffc23e90cd8ea3a0cfc858f74b602bac1433fd18a2749719b387d45011e2bc9d0c86f66bc
7
- data.tar.gz: e5c2cfef93104bfff29eec219ce03e334a1c992251299885ba1a96569754332230a8acb86ab928afc660e75d4d6746a2fbf1b7a563d73e67023d87e350ac7a2a
6
+ metadata.gz: 37dcd2110c7246f9d47547e7dcb9354c30d12960c5d48d781a757b51b891fc8d5003e116c62d01f7ce842a06997d10fedb15d8155e532e90ad0866c4e526d9a3
7
+ data.tar.gz: b878159e1de59ce925601989bfad40049c0239d84fbc894e96d6ece7106f8394d4417f4341a8d6089a2d6a29fc26095a1da09c78e1b4b72234c72067fe14ee37
@@ -7,7 +7,7 @@ module RecastAI
7
7
  def initialize(request)
8
8
  request = JSON.parse(request)
9
9
  request.each do |k, v|
10
- k = k.gsub(/(.)([A-Z])/,'\1_\2').downcase
10
+ k = k.gsub(/(.)([A-Z])/, '\1_\2').downcase
11
11
  self.instance_variable_set("@#{k}", v)
12
12
  self.define_singleton_method(k.to_sym){ v }
13
13
  end
@@ -24,8 +24,8 @@ module RecastAI
24
24
  @action = response['action'] ? Action.new(response['action']) : nil
25
25
  @next_actions = response['next_actions'].map{ |i| Action.new(i) }
26
26
  @sentiment = response['sentiment']
27
- @memory = response['memory'].reject { |_, e| e.nil? }.map{ |n, e| Entity.new(n, e) }
28
- @entities = response['entities'].flat_map{ |_, e| e.map{ |ee| Entity.new(n, ee) } }
27
+ @memory = response['memory'].reject{ |_, e| e.nil? }.map{ |n, e| Entity.new(n, e) }
28
+ @entities = response['entities'].flat_map{ |n, e| e.map{ |ee| Entity.new(n, ee) } }
29
29
  @intents = response['intents'].map{ |i| Intent.new(i) }
30
30
  @conversation_token = response['conversation_token']
31
31
  @language = response['language']
@@ -92,7 +92,7 @@ module RecastAI
92
92
 
93
93
  response = JSON.parse(response.body)
94
94
  response = response['results']
95
- response['memory'].reject { |_, e| e.nil? }.map { |n, e| Entity.new(n, e) }
95
+ response['memory'].reject{ |_, e| e.nil? }.map{ |n, e| Entity.new(n, e) }
96
96
  end
97
97
 
98
98
  def reset_memory(name = nil)
@@ -108,7 +108,7 @@ module RecastAI
108
108
 
109
109
  response = JSON.parse(response.body)
110
110
  response = response['results']
111
- response['memory'].reject { |_, e| e.nil? }.map { |n, e| Entity.new(n, e) }
111
+ response['memory'].reject{ |_, e| e.nil? }.map{ |n, e| Entity.new(n, e) }
112
112
  end
113
113
 
114
114
  def reset_conversation
@@ -122,7 +122,7 @@ module RecastAI
122
122
 
123
123
  response = JSON.parse(response.body)
124
124
  response = response['results']
125
- response['memory'].reject { |_, e| e.nil? }.map { |n, e| Entity.new(n, e) }
125
+ response['memory'].reject{ |_, e| e.nil? }.map{ |n, e| Entity.new(n, e) }
126
126
  end
127
127
  end
128
128
  end
@@ -5,7 +5,7 @@ module RecastAI
5
5
  # Versioning
6
6
  MAJOR = '3'.freeze
7
7
  MINOR = '1'.freeze
8
- MICRO = '0'.freeze
8
+ MICRO = '1'.freeze
9
9
  VERSION = "#{MAJOR}.#{MINOR}.#{MICRO}".freeze
10
10
 
11
11
  # Endpoints
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: RecastAI
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.1.0
4
+ version: 3.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Paul Renvoisé
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-04-20 00:00:00.000000000 Z
11
+ date: 2017-05-15 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: httparty