omniai 0.1.2 → 0.1.3

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: '08e84fed0ec1535369239cec24e1ba320714b006d63c41c70a3fab4ad9b27448'
4
- data.tar.gz: 1b1c8c415873efad649481e9a54b2377e4a1aa3081c1fe17c03615f59d6c82e8
3
+ metadata.gz: 7214249d8bda8299971c31dace84132a52f64b1464ff4d28af27f4a0f93221f8
4
+ data.tar.gz: c52f1ef0038da9fc26901f1838d2497e26febcf564548101a96acf03c49c6aa4
5
5
  SHA512:
6
- metadata.gz: bcebbc73ba9c7fc02aac3c49485bca5c9beea176e53d160fbddfb787442bac4dca7d643b220ee67a156fd9b464af273a8bedcf8201e3120c6671caf5fc9740a8
7
- data.tar.gz: aa4a0d58e825d950b8241dfc1fb1da789a1efa3f81f7b7e67d09f8126696624f4a5d4f34dc50d913001ef1ee4f5b00e71f1ac6a478620aa8e0b38ed60d5f20b5
6
+ metadata.gz: a922ecde2f712428565fa4b0f4544c26249f9c0a85f5801c2b4029d15650d80edca3fae70fb81356c5c66ddce681ffca544c77d3255ac02c335071d9a5b7db4b
7
+ data.tar.gz: 53756ecbb1aa2cdbad35c36f9f8b25803e7065661ab2e02716f28f44d7cab3dd9e253bcf6d1fc94dcfaa8d57a27b5f25ed8447c3e50b9d884d1d08fae72ddc75
@@ -31,6 +31,11 @@ module OmniAI
31
31
  @data['model']
32
32
  end
33
33
 
34
+ # @return [Array<OmniAI::Chat::Choice>]
35
+ def choices
36
+ @choices ||= @data['choices'].map { |data| Choice.new(data:) }
37
+ end
38
+
34
39
  # @param [index] [Integer]
35
40
  # @return [OmniAI::Chat::Delta]
36
41
  def choice(index: 0)
@@ -38,7 +38,7 @@ module OmniAI
38
38
 
39
39
  # @return [Array<OmniAI::Chat::Choice>]
40
40
  def choices
41
- @choices ||= @data['choices'].map { |choice| Choice.new(data: choice) }
41
+ @choices ||= @data['choices'].map { |data| Choice.new(data:) }
42
42
  end
43
43
 
44
44
  # @param [index] [Integer] optional - default is 0
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module OmniAI
4
- VERSION = '0.1.2'
4
+ VERSION = '0.1.3'
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: omniai
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.2
4
+ version: 0.1.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Kevin Sylvestre