ox-ai-workers 1.1.2.7 → 1.1.2.9

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: c4d226c60e9c1564ce6e18c64dcafaba55adb3b3252915af7cf2b77eab9aee1e
4
- data.tar.gz: 9cc6665f3508f59d218cc15b8ac43c42eeed86fa1b0ba1fb8bbe7a656a2b9685
3
+ metadata.gz: 3d6c48bf58686ba65100f5d18a0cd3dea53e0af817fda56380df77964038828e
4
+ data.tar.gz: 3dabc31da873b233d2e9f74aebfb4d45f3ed83fd8513bad1b64817a56e5d4a88
5
5
  SHA512:
6
- metadata.gz: 0e73094799ba500c59cd6908819c0ad60f49e8c72dbd2703b1d1cd7e8f8b95d51ac8b3db3db727e96f0331cf7ab26a355ad98a2f4558999a85366d2fd4028f52
7
- data.tar.gz: 0c2aebab591c0dc431a7c9dc4989113da9ea691e46599f9547f97e61e36b37f9b69bf8f60d01a312e7733ea61dc577b3e1f6a78d5d17d5c51dadf40c4b0a6842
6
+ metadata.gz: 232cafcae6234bf5166de0e550747977ce23d50878cca0bff801a6ba74790b62b3bbf6aa53a288ea1f84ab79b544ddf3641df6727b5f1e27f75a386436b9c9be
7
+ data.tar.gz: 1898cd2b205cfb2e578bea503cc6419725ab73afd8d7d46f3df9367e3e8c29ff7d59fe9a8ae27bab4e52400be1139544830e9030092167ec7a2a02c78541fa5c
@@ -31,17 +31,22 @@ module OxAiWorkers
31
31
  puts "send_message to #{to_id}: #{message}".colorize(:red)
32
32
  puts " Result: #{result}"
33
33
  puts " Example: #{example}"
34
- context = context_for(to_id)
35
- @assistants[to_id].replace_context(context)
36
- @assistants[to_id].add_task message
37
- with_locale do
38
- @assistants[to_id].add_task "#{I18n.t('oxaiworkers.tool.pipeline.send_message.result')}: #{result}"
39
- unless example.nil?
40
- @assistants[to_id].add_task "#{I18n.t('oxaiworkers.tool.pipeline.send_message.example')}: #{example}"
34
+ if @assistants.key?(to_id)
35
+ context = context_for(to_id)
36
+ @assistants[to_id].replace_context(context)
37
+ @assistants[to_id].add_task message
38
+ with_locale do
39
+ @assistants[to_id].add_task "#{I18n.t('oxaiworkers.tool.pipeline.send_message.result')}: #{result}"
40
+ unless example.nil?
41
+ @assistants[to_id].add_task "#{I18n.t('oxaiworkers.tool.pipeline.send_message.example')}: #{example}"
42
+ end
41
43
  end
44
+ @assistants[to_id].execute
45
+ nil
46
+ else
47
+ OxAiWorkers.logger.error "Assistant #{to_id} not found"
48
+ "Assistant #{to_id} not found"
42
49
  end
43
- @assistants[to_id].execute
44
- nil
45
50
  end
46
51
 
47
52
  def add_assistant(assistant)
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module OxAiWorkers
4
- VERSION = '1.1.2.7'
4
+ VERSION = '1.1.2.9'
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ox-ai-workers
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.2.7
4
+ version: 1.1.2.9
5
5
  platform: ruby
6
6
  authors:
7
7
  - Denis Smolev