omniai-anthropic 1.0.4 → 1.1.0

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: c7515c0b1b6a181ac412b204086d41063233ea946dcdffc20da6d7380b271597
4
- data.tar.gz: 50025d78d8e2e3fca15fdf285155da5c3bc4a71c76514a557eb154aa1eb83c73
3
+ metadata.gz: fa660597cc0de2cd00fa3629d04904cc4e66a0006c977bb34435f08609fb42da
4
+ data.tar.gz: 508b2098cd6c1c74325fcb6b8a4b41dec262023af319e2ba6c9024687975e51e
5
5
  SHA512:
6
- metadata.gz: 37c2635c4b2be5cb7279789bbce024e245b6187bd5cdcf7ee68ac58e730b6d0671e7d2aac2c647b67eaf2cec52d4bcad99d21891241915eb05710d4b1b1dd26b
7
- data.tar.gz: b8376c28bc58daecd5cf21d478bca2bfe85f11458290fc49f1a5894a5cb5ba71d4a48ff3d5932a7bbc22e177e69b45ef5d4a435034b08e521d4acc52904f1bb5
6
+ metadata.gz: ccf55f67c7fa7fbcdcaaf8ef2ef3c42aea55d73acf3eec786e4b242af0ddbdfa9693d506727f567475ae9b4186e2f70ac4cb7c8eb0a414c0ffa0a18ff1bce922
7
+ data.tar.gz: 61bbcff1cd4c44105b59a569fd054c3142e3b794f5fdb2b97cb83067a6409be4282bb3479d73e8994acddd347e4d6ab0c91f1fd2abe229169ac969fd03e5f5e2
data/README.md CHANGED
@@ -67,7 +67,7 @@ completion.choice.message.content # 'The capital of Canada is Ottawa.'
67
67
  `model` takes an optional string (default is `claude-3-haiku-20240307`):
68
68
 
69
69
  ```ruby
70
- completion = client.chat('Provide code for fibonacci', model: OmniAI::Anthropic::Chat::Model::OPUS)
70
+ completion = client.chat('Provide code for fibonacci', model: OmniAI::Anthropic::Chat::Model::CLAUDE_OPUS)
71
71
  completion.choice.message.content # 'def fibonacci(n)...end'
72
72
  ```
73
73
 
@@ -11,7 +11,7 @@ module OmniAI
11
11
  role = @data['role']
12
12
 
13
13
  @data['content'].map do |data, index|
14
- OmniAI::Chat::Choice.new(data: {
14
+ OmniAI::Chat::Choice.for(data: {
15
15
  'index' => index,
16
16
  'message' => { 'role' => role, 'content' => data['text'] },
17
17
  })
@@ -2,6 +2,6 @@
2
2
 
3
3
  module OmniAI
4
4
  module Anthropic
5
- VERSION = '1.0.4'
5
+ VERSION = '1.1.0'
6
6
  end
7
7
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: omniai-anthropic
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.4
4
+ version: 1.1.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Kevin Sylvestre
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2024-06-15 00:00:00.000000000 Z
11
+ date: 2024-06-19 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: event_stream_parser