omniai 1.0.7 → 1.0.8
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile +2 -0
- data/README.md +4 -7
- data/lib/omniai/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 1971cb590311266b342596c44ff56398999b8657e9f6cf2b8d2afffb8b91257b
|
4
|
+
data.tar.gz: 7866818c3dd9c1af3b03a351ecdc38c527ef1d08bb877533a9f9159bce8d5ed5
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 2c93b8a97fc2ca09765e9c2c537c15491a7344cc505e6204addd972dbb2c7ee2219213d2892745df48bdd4c0193bf3d80391142da2462de437290fc3a6d442db
|
7
|
+
data.tar.gz: 0b7d13dfde39f89c78a57ea3b03549262fb7b9962d127a01e89ca3785402098b6c0e34fc957145615d279a14f4d644769c25a2d3f833aa9c1136397d6b7384b3
|
data/Gemfile
CHANGED
data/README.md
CHANGED
@@ -66,7 +66,7 @@ Clients that support chat (e.g. Anthropic w/ "Claude", Google w/ "Gemini", Mistr
|
|
66
66
|
|
67
67
|
```ruby
|
68
68
|
completion = client.chat('Tell me a joke.')
|
69
|
-
|
69
|
+
completion.choice.message.content # '...'
|
70
70
|
```
|
71
71
|
|
72
72
|
#### w/ a Collection of Messages
|
@@ -77,13 +77,10 @@ messages = [
|
|
77
77
|
role: 'system',
|
78
78
|
content: 'You are a helpful assistant with an expertise in geography.',
|
79
79
|
},
|
80
|
-
|
81
|
-
role: 'user',
|
82
|
-
content: 'What is the capital of Canada?',
|
83
|
-
},
|
80
|
+
'What is the capital of Canada?'
|
84
81
|
]
|
85
82
|
completion = client.chat(messages, model: '...', temperature: 0.7, format: :json)
|
86
|
-
|
83
|
+
completion.choice.message.content
|
87
84
|
```
|
88
85
|
|
89
86
|
#### w/ a Collection of Files
|
@@ -103,7 +100,7 @@ message = {
|
|
103
100
|
}
|
104
101
|
|
105
102
|
completion = client.chat(message)
|
106
|
-
|
103
|
+
completion.choice.message.content
|
107
104
|
```
|
108
105
|
|
109
106
|
#### Streaming
|
data/lib/omniai/version.rb
CHANGED